1function setProportion(t, e, i, n) { 2 var s = getProportion(t, e, i, n); 3 t.find(".vid-bg").width(s * e), 4 t.find(".vid-bg").height(s * i), 5 t.find(".vid-bg video").width(s * e), 6 t.find(".vid-bg video").height(s * i); 7 var o = (t.width() >> 1) - (t.find(".vid-bg video").width() >> 1) | 0 8 , r = (t.height() >> 1) - (t.find(".vid-bg video").height() >> 1) | 0; 9 t.find(".vid-bg video").css({ 10 left: o, 11 top: r 12 }) 13} 14function getProportion(t, e, i, n) { 15 jQuery(window).width(), 16 jQuery(window).height(); 17 var s = t.width() 18 , o = t.height() 19 , r = o / i; 20 return e / i <= s / o ? r = s / e : n && o < jQuery(window).height() && (r = jQuery(window).height() / i), 21 r 22} 23function parallaxVideo(t) { 24 if (t.hasClass("horizontalinner") && (t = t.parent(".horizontalsection")), 25 t.visible(!0)) { 26 var e = -(parseInt(jQuery(t).offset().top) - jQuery(window).scrollTop()) / 1.5 + "px"; 27 t.find(".vid-bg video").css({ 28 top: e 29 }) 30 } 31} 32function createOpener() { 33 jQuery("#page-content").append('<div id="easy-opener-section"><div class="easy-opener-bg"></div><div class="easy-opener-content"></div></div>'), 34 jQuery("#easy-opener-section").css({ 35 height: jQuery("#page-content").height() + "px" 36 }) 37} 38function createVideo(t, e, i, n, s) { 39 maxProportion = t / e, 40 elProportion = i / n, 41 elProportion > maxProportion ? (finalElW = t, 42 finalElH = Math.ceil(t / i * n)) : (finalElH = e, 43 finalElW = Math.ceil(e / n * i)); 44 var o = Math.ceil(finalElW / 2); 45 jQuery(".easy-opener-content").css({ 46 width: finalElW + "px", 47 marginLeft: "-" + o + "px" 48 }), 49 jQuery(".easy-opener-content").html('<a class="easy-opener-close" href="#"></a><iframe src="' + s + '" width="' + i + '" height="' + n + '"></iframe>'), 50 jQuery("#easy-opener-section").fitVids(), 51 jQuery("#easy-opener-section").fadeIn(500, function() { 52 var t = jQuery(document).scrollTop() + Math.ceil((jQuery(window).height() - finalElH) / 2); 53 jQuery(".easy-opener-content").css({ 54 top: t + "px" 55 }).delay(1e3).animate({ 56 opacity: 1 57 }, 600) 58 }) 59} 60function createImage(t, i, e) { 61 maxProportion = t / i, 62 jQuery(".easy-opener-content").css({ 63 width: t + "px", 64 height: i + "px" 65 }), 66 jQuery(".easy-opener-content").html('<a class="easy-opener-close" href="#"></a><img src="' + e + '" />'), 67 jQuery("#easy-opener-section").fadeIn(500, function() { 68 jQuery(".easy-opener-content").css({ 69 width: jQuery(".easy-opener-content img").width() + "px", 70 height: jQuery(".easy-opener-content img").height() + "px" 71 }); 72 var t = jQuery(document).scrollTop() + Math.ceil((jQuery(window).height() - i) / 2) 73 , e = Math.ceil(jQuery(".easy-opener-content img").width() / 2); 74 jQuery(".easy-opener-content").css({ 75 top: t + "px", 76 marginLeft: "-" + e + "px" 77 }).delay(1e3).animate({ 78 opacity: 1 79 }, 600) 80 }) 81} 82function createNextPrev(t, e, i) { 83 var n = -1; 84 jQuery(".easy-opener[data-gallery='" + t + "']").each(function(t) { 85 jQuery(this).attr("data-galsort") && i || jQuery(this).attr("data-galsort", t), 86 n++ 87 }); 88 var s = jQuery(e).attr("data-galsort"); 89 i && (s = jQuery(e).attr("data-pseudosort")); 90 var o = parseInt(s) + 1 91 , r = parseInt(s) - 1; 92 r < 0 && (r = n), 93 n < o && (o = 0); 94 var a = jQuery(".easy-opener[data-galsort='" + o + "']").data("type"); 95 if ("video" == a) 96 var l = jQuery(".easy-opener[data-galsort='" + o + "']").data("width") 97 , c = jQuery(".easy-opener[data-galsort='" + o + "']").data("height") 98 , u = 'href="' + jQuery(".easy-opener[data-galsort='" + o + "']").attr("href") + '" data-pseudosort="' + jQuery(".easy-opener[data-galsort='" + o + "']").data("galsort") + '" data-type="video" data-width="' + l + '" data-height="' + c + '" data-gallery="' + t + '"'; 99 else if ("image" == a || !a) 100 u = 'href="' + jQuery(".easy-opener[data-galsort='" + o + "']").attr("href") + '" data-pseudosort="' + jQuery(".easy-opener[data-galsort='" + o + "']").data("galsort") + '" data-type="image" data-gallery="' + t + '"'; 101 var h = jQuery(".easy-opener[data-galsort='" + r + "']").data("type"); 102 if ("video" == h) 103 var d = jQuery(".easy-opener[data-galsort='" + r + "']").data("width") 104 , p = jQuery(".easy-opener[data-galsort='" + r + "']").data("height") 105 , f = 'href="' + jQuery(".easy-opener[data-galsort='" + r + "']").attr("href") + '" data-pseudosort="' + jQuery(".easy-opener[data-galsort='" + r + "']").data("galsort") + '" data-type="video" data-width="' + d + '" data-height="' + p + '" data-gallery="' + t + '"'; 106 else if ("image" == h || !h) 107 f = 'href="' + jQuery(".easy-opener[data-galsort='" + r + "']").attr("href") + '" data-pseudosort="' + jQuery(".easy-opener[data-galsort='" + r + "']").data("galsort") + '" data-type="image" data-gallery="' + t + '"'; 108 jQuery(".easy-opener-content").prepend('<a class="easy-opener easy-opener-next" ' + u + ' data-direction="next"></a>'), 109 jQuery(".easy-opener-content").prepend('<a class="easy-opener easy-opener-prev" ' + f + ' data-direction="prev"></a>') 110} 111function moveParallax(t) { 112 if (jQuery(t).visible(!0) && 1024 < jQuery(window).width()) {
113 var e = "50% " + -(parseInt(jQuery(t).offset().top) - jQuery(window).scrollTop()) / 1.7 + "px"; 114 jQuery(t).css({ 115 backgroundPosition: e 116 }) 117 } 118} 119function sizeDownHeader() { 120 var t = 150; 121 headeroverlay && (t = 300, 122 jQuery(document).scrollTop() > jQuery(window).height() - headerheight && 0 < jQuery(".fixed-header").length ? (jQuery("#overlay-logo").fadeOut(0), 123 jQuery("header").removeClass("header-overlay"), 124 jQuery("header").addClass("wasOverlay"), 125 jQuery(".header-shown").length < 1 && (jQuery("header").css({ 126 top: "-" + headerheight + "px" 127 }), 128 jQuery("header").animate({ 129 top: "0px" 130 }, 600, "easeInOutQuart")), 131 jQuery("header").addClass("header-shown")) : 0 < jQuery(".fixed-header").length && (0 < jQuery(".header-shown").length && jQuery("header").animate({ 132 top: "-" + headerheight + "px" 133 }, 600, function() { 134 jQuery("header").addClass("header-overlay"), 135 jQuery("header").removeClass("wasOverlay"), 136 jQuery("header").animate({ 137 top: "0px" 138 }, 600, "easeInOutQuart"), 139 jQuery("#overlay-logo").fadeIn(0) 140 }), 141 jQuery("header").removeClass("header-shown"))), 142 jQuery(window).width() < 767 ? (jQuery(".fixed-header nav#main-nav").fadeOut(0), 143 jQuery(".fixed-header nav#menu-controls").fadeOut(0), 144 jQuery(".fixed-header .open-responsive-nav").fadeIn(500)) : jQuery(document).scrollTop() > t && 0 < jQuery(".fixed-header").length ? jQuery(".fixed-header header").hasClass("smallheader") || (1023 < jQuery(window).width() ? (jQuery("header.no-resize").length < 1 && jQuery(".fixed-header header").addClass("smallheader"), 145 jQuery(".fixed-header .open-responsive-nav").fadeOut(0), 146 0 < jQuery(".fixed-header nav#menu-controls").length && jQuery(".fixed-header nav#main-nav").fadeOut(200, function() { 147 jQuery("nav#menu-controls").fadeIn(200) 148 })) : 767 < jQuery(window).width() && (jQuery(".fixed-header nav#main-nav").fadeOut(0), 149 0 < jQuery(".fixed-header nav#menu-controls").length && jQuery(".fixed-header .open-responsive-nav").fadeOut(200, function() { 150 jQuery("nav#menu-controls").fadeIn(200) 151 }))) : 0 < jQuery(".fixed-header").length && (1023 < jQuery(window).width() ? (jQuery(".fixed-header .open-responsive-nav").fadeOut(0), 152 jQuery(".fixed-header header").hasClass("smallheader") && jQuery(".fixed-header header").removeClass("smallheader"), 153 0 < jQuery(".fixed-header nav#menu-controls").length && jQuery(".fixed-header nav#menu-controls").fadeOut(200, function() { 154 jQuery("nav#main-nav").fadeIn(200) 155 })) : 767 < jQuery(window).width() && (jQuery(".fixed-header nav#main-nav").fadeOut(0), 156 0 < jQuery(".fixed-header nav#menu-controls").length && jQuery(".fixed-header nav#menu-controls").fadeOut(200, function() { 157 jQuery(".open-responsive-nav").fadeIn(200) 158 }))) 159} 160function portfolioPreviewHide() { 161 jQuery("#portfolio-single .project-title").css({ 162 top: "-60px", 163 opacity: 0 164 }), 165 jQuery("#portfolio-single .social-share li").css({ 166 top: "-30px", 167 opacity: 0 168 }), 169 jQuery("#portfolio-single .entry-media").css({ 170 top: "60px", 171 opacity: 0 172 }), 173 jQuery("#portfolio-single .entry-content").css({ 174 top: "60px", 175 opacity: 0 176 }), 177 jQuery("#portfolio-single .project-title .single-pagination .next").css({ 178 left: "60%", 179 opacity: 0 180 }), 181 jQuery("#portfolio-single .project-title .single-pagination .prev").css({ 182 left: "40%", 183 opacity: 0 184 }) 185} 186function portfolioShow() { 187 jQuery("#portfolio-single .project-title").animate({ 188 top: "0", 189 opacity: 1 190 }, 500, "easeOutQuart"), 191 jQuery(".social-share li").delay(400).each(function(t) { 192 var e = 80 * t; 193 jQuery(this).delay(e).animate({ 194 top: "0", 195 opacity: 1 196 }, 500, "easeOutBack") 197 }), 198 jQuery(".entry-media").delay(600).animate({ 199 top: "0", 200 opacity: 1 201 }, 500, "easeOutQuart"), 202 jQuery(".entry-content").delay(1e3).animate({ 203 top: "0", 204 opacity: 1 205 }, 500, "easeOutQuart"); 206 var t = parseInt(jQuery(".project-title").width() / 2) - parseInt(jQuery(".project-title .project-name").width() / 2) - 90 207 , e = jQuery(".project-title").width() - t - jQuery(".project-title .single-pagination .next a").width(); 208 if (jQuery(window).width() < 760) 209 t = -10, 210 e = 280; 211 jQuery(".project-title .single-pagination .next").delay(200).animate({ 212 left: e + "px", 213 opacity: 1 214 }, 600, "easeOutBack"), 215 jQuery(".project-title .single-pagination .prev").delay(200).animate({ 216 left: t + "px", 217 opacity: 1 218 }, 600, "easeOutBack"), 219 jQuery(".close-project").delay(1200).fadeIn(500) 220} 221function debug(t, e) { 222 debugOn && (e ? console.log("%c" + t + " ", "color: " + e) : console.log(t)) 223} 224function fireSkrollr() { 225 s = skrollr.init({ 226 smoothScrolling: !0, 227 mobileCheck: function() { 228 return !1 229 } 230 }) 231} 232function resetSkrollr() { 233 s.destroy(), 234 fireSkrollr() 235} 236(function() { 237 var s = this 238 , o = s._ 239 , y = function() { 240 // Underscore.js 1.13.8 241 // https://underscorejs.org
242 // (c) 2009-2026 Jeremy Ashkenas, Julian Gonggrijp, and DocumentCloud and Investigative Reporters & Editors 243 // Underscore may be freely distributed under the MIT license. 244
vendor: 19,130 bytes, line 244
244var n="1.13.8",r="object"==typeof self&&self.self===self&&self||"object"==typeof global&&global.global===global&&global||Function("return this")()||{},t=Array.prototype,e=Object.prototype,u="undefined"!=typeof Symbol?Symbol.prototype:null,i=t.push,o=t.slice,a=e.toString,f=e.hasOwnProperty,c="undefined"!=typeof ArrayBuffer,l="undefined"!=typeof DataView,s=Array.isArray,p=Object.keys,v=Object.create,h=c&&ArrayBuffer.isView,y=isNaN,d=isFinite,g=!{toString:null}.propertyIsEnumerable("toString"),b=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],m=Math.pow(2,53)-1;function j(n,r){return r=null==r?n.length-1:+r,function(){for(var t=Math.max(arguments.length-r,0),e=Array(t),u=0;u<t;u++)e[u]=arguments[u+r];switch(r){case 0:return n.call(this,e);case 1:return n.call(this,arguments[0],e);case 2:return n.call(this,arguments[0],arguments[1],e)}var i=Array(r+1);for(u=0;u<r;u++)i[u]=arguments[u];return i[r]=e,n.apply(this,i)}}function w(n){var r=typeof n;return"function"===r||"object"===r&&!!n}function _(n){return void 0===n}function A(n){return!0===n||!1===n||"[object Boolean]"===a.call(n)}function x(n){var r="[object "+n+"]";return function(n){return a.call(n)===r}}var S=x("String"),O=x("Number"),M=x("Date"),E=x("RegExp"),B=x("Error"),N=x("Symbol"),k=x("ArrayBuffer"),I=x("Function"),T=r.document&&r.document.childNodes;"function"!=typeof/./&&"object"!=typeof Int8Array&&"function"!=typeof T&&(I=function(n){return"function"==typeof n||!1});var D=I,R=x("Object"),V=l&&(!/\[native code\]/.test(String(DataView))||R(new DataView(new ArrayBuffer(8)))),F="undefined"!=typeof Map&&R(new Map),P=x("DataView");var q=V?function(n){return null!=n&&D(n.getInt8)&&k(n.buffer)}:P,U=s||x("Array");function W(n,r){return null!=n&&f.call(n,r)}var z=x("Arguments");!function(){z(arguments)||(z=function(n){return W(n,"callee")})}();var L=z;function $(n){return O(n)&&y(n)}function C(n){return function(){return n}}function K(n){return function(r){var t=n(r);return"number"==typeof t&&t>=0&&t<=m}}function J(n){return function(r){return null==r?void 0:r[n]}}var G=J("byteLength"),H=K(G),Q=/\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/;var X=c?function(n){return h?h(n)&&!q(n):H(n)&&Q.test(a.call(n))}:C(!1),Y=J("length");function Z(n,r){r=function(n){for(var r={},t=n.length,e=0;e<t;++e)r[n[e]]=!0;return{contains:function(n){return!0===r[n]},push:function(t){return r[t]=!0,n.push(t)}}}(r);var t=b.length,u=n.constructor,i=D(u)&&u.prototype||e,o="constructor";for(W(n,o)&&!r.contains(o)&&r.push(o);t--;)(o=b[t])in n&&n[o]!==i[o]&&!r.contains(o)&&r.push(o)}function nn(n){if(!w(n))return[];if(p)return p(n);var r=[];for(var t in n)W(n,t)&&r.push(t);return g&&Z(n,r),r}function rn(n,r){var t=nn(r),e=t.length;if(null==n)return!e;for(var u=Object(n),i=0;i<e;i++){var o=t[i];if(r[o]!==u[o]||!(o in u))return!1}return!0}function tn(n){return n instanceof tn?n:this instanceof tn?void(this._wrapped=n):new tn(n)}function en(n){return new Uint8Array(n.buffer||n,n.byteOffset||0,G(n))}tn.VERSION=n,tn.prototype.value=function(){return this._wrapped},tn.prototype.valueOf=tn.prototype.toJSON=tn.prototype.value,tn.prototype.toString=function(){return String(this._wrapped)};var un="[object DataView]";function on(n){if(!w(n))return[];var r=[];for(var t in n)r.push(t);return g&&Z(n,r),r}function an(n){var r=Y(n);return function(t){if(null==t)return!1;var e=on(t);if(Y(e))return!1;for(var u=0;u<r;u++)if(!D(t[n[u]]))return!1;return n!==vn||!D(t[fn])}}var fn="forEach",cn="has",ln=["clear","delete"],sn=["get",cn,"set"],pn=ln.concat(fn,sn),vn=ln.concat(sn),hn=["add"].concat(ln,fn,cn),yn=F?an(pn):x("Map"),dn=F?an(vn):x("WeakMap"),gn=F?an(hn):x("Set"),bn=x("WeakSet");function mn(n){for(var r=nn(n),t=r.length,e=Array(t),u=0;u<t;u++)e[u]=n[r[u]];return e}function jn(n){for(var r={},t=nn(n),e=0,u=t.length;e<u;e++)r[n[t[e]]]=t[e];return r}function wn(n){var r=[];for(var t in n)D(n[t])&&r.push(t);return r.sort()}function _n(n,r){return function(t){var e=arguments.length;if(r&&(t=Object(t)),e<2||null==t)return t;for(var u=1;u<e;u++)for(var i=arguments[u],o=n(i),a=o.length,f=0;f<a;f++){var c=o[f];r&&void 0!==t[c]||(t[c]=i[c])}return t}}var An=_n(on),xn=_n(nn),Sn=_n(on,!0);function On(n){if(!w(n))return{};if(v)return v(n);var r=function(){};r.prototype=n;var t=new r;return r.prototype=null,t}function Mn(n){return U(n)?n:[n]}function En(n){return tn.toPath(n)}function Bn(n,r){for(var t=r.length,e=0;e<t;e++){if(null==n)return;n=n[r[e]]}return t?n:void 0}function Nn(n,r,t){var e=Bn(n,En(r));return _(e)?t:e}function kn(n){return n}function In(n){return n=xn({},n),function(r){return rn(r,n)}}function Tn(n){return n=En(n),function(r){return Bn(r,n)}}function Dn(n,r,t){if(void 0===r)return n;switch(null==t?3:t){case 1:return function(t){return n.call(r,t)};case 3:return function(t,e,u){return n.call(r,t,e,u)};case 4:return function(t,e,u,i){return n.call(r,t,e,u,i)}}return function(){return n.apply(r,arguments)}}function Rn(n,r,t){return null==n?kn:D(n)?Dn(n,r,t):w(n)&&!U(n)?In(n):Tn(n)}function Vn(n,r){return Rn(n,r,1/0)}function Fn(n,r,t){return tn.iteratee!==Vn?tn.iteratee(n,r):Rn(n,r,t)}function Pn(){}function qn(n,r){return null==r&&(r=n,n=0),n+Math.floor(Math.random()*(r-n+1))}tn.toPath=Mn,tn.iteratee=Vn;var Un=Date.now||function(){return(new Date).getTime()};function Wn(n){var r=function(r){return n[r]},t="(?:"+nn(n).join("|")+")",e=RegExp(t),u=RegExp(t,"g");return function(n){return n=null==n?"":""+n,e.test(n)?n.replace(u,r):n}}var zn={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Ln=Wn(zn),$n=Wn(jn(zn)),Cn=tn.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g},Kn=/(.)^/,Jn={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},Gn=/\\|'|\r|\n|\u2028|\u2029/g;function Hn(n){return"\\"+Jn[n]}var Qn=/^\s*(\w|\$)+\s*$/;var Xn=0;function Yn(n,r,t,e,u){if(!(e instanceof r))return n.apply(t,u);var i=On(n.prototype),o=n.apply(i,u);return w(o)?o:i}var Zn=j((function(n,r){var t=Zn.placeholder,e=function(){for(var u=0,i=r.length,o=Array(i),a=0;a<i;a++)o[a]=r[a]===t?arguments[u++]:r[a];for(;u<arguments.length;)o.push(arguments[u++]);return Yn(n,e,this,this,o)};return e}));Zn.placeholder=tn;var nr=j((function(n,r,t){if(!D(n))throw new TypeError("Bind must be called on a function");var e=j((function(u){return Yn(n,e,r,this,t.concat(u))}));return e})),rr=K(Y);function tr(n,r,t){r||0===r||(r=1/0);for(var e=[],u=0,i=0,o=Y(n)||0,a=[];1;)if(i>=o){if(!a.length)break;var f=a.pop();i=f.i,n=f.v,o=Y(n)}else{var c=n[i++];a.length>=r?e[u++]=c:rr(c)&&(U(c)||L(c))?(a.push({i:i,v:n}),i=0,o=Y(n=c)):t||(e[u++]=c)}return e}var er=j((function(n,r){var t=(r=tr(r,!1,!1)).length;if(t<1)throw new Error("bindAll must be passed function names");for(;t--;){var e=r[t];n[e]=nr(n[e],n)}return n}));var ur=j((function(n,r,t){return setTimeout((function(){return n.apply(null,t)}),r)})),ir=Zn(ur,tn,1);function or(n){return function(){return!n.apply(this,arguments)}}function ar(n,r){var t;return function(){return--n>0&&(t=r.apply(this,arguments)),n<=1&&(r=null),t}}var fr=Zn(ar,2);function cr(n,r,t){r=Fn(r,t);for(var e,u=nn(n),i=0,o=u.length;i<o;i++)if(r(n[e=u[i]],e,n))return e}function lr(n){return function(r,t,e){t=Fn(t,e);for(var u=Y(r),i=n>0?0:u-1;i>=0&&i<u;i+=n)if(t(r[i],i,r))return i;return-1}}var sr=lr(1),pr=lr(-1);function vr(n,r,t,e){for(var u=(t=Fn(t,e,1))(r),i=0,o=Y(n);i<o;){var a=Math.floor((i+o)/2);t(n[a])<u?i=a+1:o=a}return i}function hr(n,r,t){return function(e,u,i){var a=0,f=Y(e);if("number"==typeof i)n>0?a=i>=0?i:Math.max(i+f,a):f=i>=0?Math.min(i+1,f):i+f+1;else if(t&&i&&f)return e[i=t(e,u)]===u?i:-1;if(u!=u)return(i=r(o.call(e,a,f),$))>=0?i+a:-1;for(i=n>0?a:f-1;i>=0&&i<f;i+=n)if(e[i]===u)return i;return-1}}var yr=hr(1,sr,vr),dr=hr(-1,pr);function gr(n,r,t){var e=(rr(n)?sr:cr)(n,r,t);if(void 0!==e&&-1!==e)return n[e]}function br(n,r,t){var e,u;if(r=Dn(r,t),rr(n))for(e=0,u=n.length;e<u;e++)r(n[e],e,n);else{var i=nn(n);for(e=0,u=i.length;e<u;e++)r(n[i[e]],i[e],n)}return n}function mr(n,r,t){r=Fn(r,t);for(var e=!rr(n)&&nn(n),u=(e||n).length,i=Array(u),o=0;o<u;o++){var a=e?e[o]:o;i[o]=r(n[a],a,n)}return i}function jr(n){var r=function(r,t,e,u){var i=!rr(r)&&nn(r),o=(i||r).length,a=n>0?0:o-1;for(u||(e=r[i?i[a]:a],a+=n);a>=0&&a<o;a+=n){var f=i?i[a]:a;e=t(e,r[f],f,r)}return e};return function(n,t,e,u){var i=arguments.length>=3;return r(n,Dn(t,u,4),e,i)}}var wr=jr(1),_r=jr(-1);function Ar(n,r,t){var e=[];return r=Fn(r,t),br(n,(function(n,t,u){r(n,t,u)&&e.push(n)})),e}function xr(n,r,t){r=Fn(r,t);for(var e=!rr(n)&&nn(n),u=(e||n).length,i=0;i<u;i++){var o=e?e[i]:i;if(!r(n[o],o,n))return!1}return!0}function Sr(n,r,t){r=Fn(r,t);for(var e=!rr(n)&&nn(n),u=(e||n).length,i=0;i<u;i++){var o=e?e[i]:i;if(r(n[o],o,n))return!0}return!1}function Or(n,r,t,e){return rr(n)||(n=mn(n)),("number"!=typeof t||e)&&(t=0),yr(n,r,t)>=0}var Mr=j((function(n,r,t){var e,u;return D(r)?u=r:(r=En(r),e=r.slice(0,-1),r=r[r.length-1]),mr(n,(function(n){var i=u;if(!i){if(e&&e.length&&(n=Bn(n,e)),null==n)return;i=n[r]}return null==i?i:i.apply(n,t)}))}));function Er(n,r){return mr(n,Tn(r))}function Br(n,r,t){var e,u,i=-1/0,o=-1/0;if(null==r||"number"==typeof r&&"object"!=typeof n[0]&&null!=n)for(var a=0,f=(n=rr(n)?n:mn(n)).length;a<f;a++)null!=(e=n[a])&&e>i&&(i=e);else r=Fn(r,t),br(n,(function(n,t,e){((u=r(n,t,e))>o||u===-1/0&&i===-1/0)&&(i=n,o=u)}));return i}var Nr=/[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g;function kr(n){return n?U(n)?o.call(n):S(n)?n.match(Nr):rr(n)?mr(n,kn):mn(n):[]}function Ir(n,r,t){if(null==r||t)return rr(n)||(n=mn(n)),n[qn(n.length-1)];var e=kr(n),u=Y(e);r=Math.max(Math.min(r,u),0);for(var i=u-1,o=0;o<r;o++){var a=qn(o,i),f=e[o];e[o]=e[a],e[a]=f}return e.slice(0,r)}function Tr(n,r){return function(t,e,u){var i=r?[[],[]]:{};return e=Fn(e,u),br(t,(function(r,u){var o=e(r,u,t);n(i,r,o)})),i}}var Dr=Tr((function(n,r,t){W(n,t)?n[t].push(r):n[t]=[r]})),Rr=Tr((function(n,r,t){n[t]=r})),Vr=Tr((function(n,r,t){W(n,t)?n[t]++:n[t]=1})),Fr=Tr((function(n,r,t){n[t?0:1].push(r)}),!0);function Pr(n,r,t){return r in t}var qr=j((function(n,r){var t={},e=r[0];if(null==n)return t;D(e)?(r.length>1&&(e=Dn(e,r[1])),r=on(n)):(e=Pr,r=tr(r,!1,!1),n=Object(n));for(var u=0,i=r.length;u<i;u++){var o=r[u],a=n[o];e(a,o,n)&&(t[o]=a)}return t})),Ur=j((function(n,r){var t,e=r[0];return D(e)?(e=or(e),r.length>1&&(t=r[1])):(r=mr(tr(r,!1,!1),String),e=function(n,t){return!Or(r,t)}),qr(n,e,t)}));function Wr(n,r,t){return o.call(n,0,Math.max(0,n.length-(null==r||t?1:r)))}function zr(n,r,t){return null==n||n.length<1?null==r||t?void 0:[]:null==r||t?n[0]:Wr(n,n.length-r)}function Lr(n,r,t){return o.call(n,null==r||t?1:r)}var $r=j((function(n,r){return r=tr(r,!0,!0),Ar(n,(function(n){return!Or(r,n)}))})),Cr=j((function(n,r){return $r(n,r)}));function Kr(n,r,t,e){A(r)||(e=t,t=r,r=!1),null!=t&&(t=Fn(t,e));for(var u=[],i=[],o=0,a=Y(n);o<a;o++){var f=n[o],c=t?t(f,o,n):f;r&&!t?(o&&i===c||u.push(f),i=c):t?Or(i,c)||(i.push(c),u.push(f)):Or(u,f)||u.push(f)}return u}var Jr=j((function(n){return Kr(tr(n,!0,!0))}));function Gr(n){for(var r=n&&Br(n,Y).length||0,t=Array(r),e=0;e<r;e++)t[e]=Er(n,e);return t}var Hr=j(Gr);function Qr(n,r){return n._chain?tn(r).chain():r}function Xr(n){return br(wn(n),(function(r){var t=tn[r]=n[r];tn.prototype[r]=function(){var n=[this._wrapped];return i.apply(n,arguments),Qr(this,t.apply(tn,n))}})),tn}br(["pop","push","reverse","shift","sort","splice","unshift"],(function(n){var r=t[n];tn.prototype[n]=function(){var t=this._wrapped;return null!=t&&(r.apply(t,arguments),"shift"!==n&&"splice"!==n||0!==t.length||delete t[0]),Qr(this,t)}})),br(["concat","join","slice"],(function(n){var r=t[n];tn.prototype[n]=function(){var n=this._wrapped;return null!=n&&(n=r.apply(n,arguments)),Qr(this,n)}}));var Yr=Xr({__proto__:null,VERSION:n,restArguments:j,isObject:w,isNull:function(n){return null===n},isUndefined:_,isBoolean:A,isElement:function(n){return!(!n||1!==n.nodeType)},isString:S,isNumber:O,isDate:M,isRegExp:E,isError:B,isSymbol:N,isArrayBuffer:k,isDataView:q,isArray:U,isFunction:D,isArguments:L,isFinite:function(n){return!N(n)&&d(n)&&!isNaN(parseFloat(n))},isNaN:$,isTypedArray:X,isEmpty:function(n){if(null==n)return!0;var r=Y(n);return"number"==typeof r&&(U(n)||S(n)||L(n))?0===r:0===Y(nn(n))},isMatch:rn,isEqual:function(n,r){for(var t=[{a:n,b:r}],e=[],i=[];t.length;){var o=t.pop();if(!0!==o){if((n=o.a)===(r=o.b)){if(0!==n||1/n==1/r)continue;return!1}if(null==n||null==r)return!1;if(n!=n){if(r!=r)continue;return!1}var f=typeof n;if("function"!==f&&"object"!==f&&"object"!=typeof r)return!1;n instanceof tn&&(n=n._wrapped),r instanceof tn&&(r=r._wrapped);var c=a.call(n);if(c!==a.call(r))return!1;if(V&&"[object Object]"==c&&q(n)){if(!q(r))return!1;c=un}switch(c){case"[object RegExp]":case"[object String]":if(""+n==""+r)continue;return!1;case"[object Number]":t.push({a:+n,b:+r});continue;case"[object Date]":case"[object Boolean]":if(+n==+r)continue;return!1;case"[object Symbol]":if(u.valueOf.call(n)===u.valueOf.call(r))continue;return!1;case"[object ArrayBuffer]":case un:t.push({a:en(n),b:en(r)});continue}var l="[object Array]"===c;if(!l&&X(n)){if(G(n)!==G(r))return!1;if(n.buffer===r.buffer&&n.byteOffset===r.byteOffset)continue;l=!0}if(!l){if("object"!=typeof n||"object"!=typeof r)return!1;var s=n.constructor,p=r.constructor;if(s!==p&&!(D(s)&&s instanceof s&&D(p)&&p instanceof p)&&"constructor"in n&&"constructor"in r)return!1}for(var v=e.length;v--;)if(e[v]===n){if(i[v]===r)break;return!1}if(!(v>=0))if(e.push(n),i.push(r),t.push(!0),l){if((v=n.length)!==r.length)return!1;for(;v--;)t.push({a:n[v],b:r[v]})}else{var h,y=nn(n);if(v=y.length,nn(r).length!==v)return!1;for(;v--;){if(!W(r,h=y[v]))return!1;t.push({a:n[h],b:r[h]})}}}else e.pop(),i.pop()}return!0},isMap:yn,isWeakMap:dn,isSet:gn,isWeakSet:bn,keys:nn,allKeys:on,values:mn,pairs:function(n){for(var r=nn(n),t=r.length,e=Array(t),u=0;u<t;u++)e[u]=[r[u],n[r[u]]];return e},invert:jn,functions:wn,methods:wn,extend:An,extendOwn:xn,assign:xn,defaults:Sn,create:function(n,r){var t=On(n);return r&&xn(t,r),t},clone:function(n){return w(n)?U(n)?n.slice():An({},n):n},tap:function(n,r){return r(n),n},get:Nn,has:function(n,r){for(var t=(r=En(r)).length,e=0;e<t;e++){var u=r[e];if(!W(n,u))return!1;n=n[u]}return!!t},mapObject:function(n,r,t){r=Fn(r,t);for(var e=nn(n),u=e.length,i={},o=0;o<u;o++){var a=e[o];i[a]=r(n[a],a,n)}return i},identity:kn,constant:C,noop:Pn,toPath:Mn,property:Tn,propertyOf:function(n){return null==n?Pn:function(r){return Nn(n,r)}},matcher:In,matches:In,times:function(n,r,t){var e=Array(Math.max(0,n));r=Dn(r,t,1);for(var u=0;u<n;u++)e[u]=r(u);return e},random:qn,now:Un,escape:Ln,unescape:$n,templateSettings:Cn,template:function(n,r,t){!r&&t&&(r=t),r=Sn({},r,tn.templateSettings);var e=RegExp([(r.escape||Kn).source,(r.interpolate||Kn).source,(r.evaluate||Kn).source].join("|")+"|$","g"),u=0,i="__p+='";n.replace(e,(function(r,t,e,o,a){return i+=n.slice(u,a).replace(Gn,Hn),u=a+r.length,t?i+="'+\n((__t=("+t+"))==null?'':_.escape(__t))+\n'":e?i+="'+\n((__t=("+e+"))==null?'':__t)+\n'":o&&(i+="';\n"+o+"\n__p+='"),r})),i+="';\n";var o,a=r.variable;if(a){if(!Qn.test(a))throw new Error("variable is not a bare identifier: "+a)}else i="with(obj||{}){\n"+i+"}\n",a="obj";i="var __t,__p='',__j=Array.prototype.join,"+"print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{o=new Function(a,"_",i)}catch(n){throw n.source=i,n}var f=function(n){return o.call(this,n,tn)};return f.source="function("+a+"){\n"+i+"}",f},result:function(n,r,t){var e=(r=En(r)).length;if(!e)return D(t)?t.call(n):t;for(var u=0;u<e;u++){var i=null==n?void 0:n[r[u]];void 0===i&&(i=t,u=e),n=D(i)?i.call(n):i}return n},uniqueId:function(n){var r=++Xn+"";return n?n+r:r},chain:function(n){var r=tn(n);return r._chain=!0,r},iteratee:Vn,partial:Zn,bind:nr,bindAll:er,memoize:function(n,r){var t=function(e){var u=t.cache,i=""+(r?r.apply(this,arguments):e);return W(u,i)||(u[i]=n.apply(this,arguments)),u[i]};return t.cache={},t},delay:ur,defer:ir,throttle:function(n,r,t){var e,u,i,o,a=0;t||(t={});var f=function(){a=!1===t.leading?0:Un(),e=null,o=n.apply(u,i),e||(u=i=null)},c=function(){var c=Un();a||!1!==t.leading||(a=c);var l=r-(c-a);return u=this,i=arguments,l<=0||l>r?(e&&(clearTimeout(e),e=null),a=c,o=n.apply(u,i),e||(u=i=null)):e||!1===t.trailing||(e=setTimeout(f,l)),o};return c.cancel=function(){clearTimeout(e),a=0,e=u=i=null},c},debounce:function(n,r,t){var e,u,i,o,a,f=function(){var c=Un()-u;r>c?e=setTimeout(f,r-c):(e=null,t||(o=n.apply(a,i)),e||(i=a=null))},c=j((function(c){return a=this,i=c,u=Un(),e||(e=setTimeout(f,r),t&&(o=n.apply(a,i))),o}));return c.cancel=function(){clearTimeout(e),e=i=a=null},c},wrap:function(n,r){return Zn(r,n)},negate:or,compose:function(){var n=arguments,r=n.length-1;return function(){for(var t=r,e=n[r].apply(this,arguments);t--;)e=n[t].call(this,e);return e}},after:function(n,r){return function(){if(--n<1)return r.apply(this,arguments)}},before:ar,once:fr,findKey:cr,findIndex:sr,findLastIndex:pr,sortedIndex:vr,indexOf:yr,lastIndexOf:dr,find:gr,detect:gr,findWhere:function(n,r){return gr(n,In(r))},each:br,forEach:br,map:mr,collect:mr,reduce:wr,foldl:wr,inject:wr,reduceRight:_r,foldr:_r,filter:Ar,select:Ar,reject:function(n,r,t){return Ar(n,or(Fn(r)),t)},every:xr,all:xr,some:Sr,any:Sr,contains:Or,includes:Or,include:Or,invoke:Mr,pluck:Er,where:function(n,r){return Ar(n,In(r))},max:Br,min:function(n,r,t){var e,u,i=1/0,o=1/0;if(null==r||"number"==typeof r&&"object"!=typeof n[0]&&null!=n)for(var a=0,f=(n=rr(n)?n:mn(n)).length;a<f;a++)null!=(e=n[a])&&e<i&&(i=e);else r=Fn(r,t),br(n,(function(n,t,e){((u=r(n,t,e))<o||u===1/0&&i===1/0)&&(i=n,o=u)}));return i},shuffle:function(n){return Ir(n,1/0)},sample:Ir,sortBy:function(n,r,t){var e=0;return r=Fn(r,t),Er(mr(n,(function(n,t,u){return{value:n,index:e++,criteria:r(n,t,u)}})).sort((function(n,r){var t=n.criteria,e=r.criteria;if(t!==e){if(t>e||void 0===t)return 1;if(t<e||void 0===e)return-1}return n.index-r.index})),"value")},groupBy:Dr,indexBy:Rr,countBy:Vr,partition:Fr,toArray:kr,size:function(n){return null==n?0:rr(n)?n.length:nn(n).length},pick:qr,omit:Ur,first:zr,head:zr,take:zr,initial:Wr,last:function(n,r,t){return null==n||n.length<1?null==r||t?void 0:[]:null==r||t?n[n.length-1]:Lr(n,Math.max(0,n.length-r))},rest:Lr,tail:Lr,drop:Lr,compact:function(n){return Ar(n,Boolean)},flatten:function(n,r){return tr(n,r,!1)},without:Cr,uniq:Kr,unique:Kr,union:Jr,intersection:function(n){for(var r=[],t=arguments.length,e=0,u=Y(n);e<u;e++){var i=n[e];if(!Or(r,i)){var o;for(o=1;o<t&&Or(arguments[o],i);o++);o===t&&r.push(i)}}return r},difference:$r,unzip:Gr,transpose:Gr,zip:Hr,object:function(n,r){for(var t={},e=0,u=Y(n);e<u;e++)r?t[n[e]]=r[e]:t[n[e][0]]=n[e][1];return t},range:function(n,r,t){null==r&&(r=n||0,n=0),t||(t=r<n?-1:1);for(var e=Math.max(Math.ceil((r-n)/t),0),u=Array(e),i=0;i<e;i++,n+=t)u[i]=n;return u},chunk:function(n,r){if(null==r||r<1)return[];for(var t=[],e=0,u=n.length;e<u;)t.push(o.call(n,e,e+=r));return t},mixin:Xr,default:tn});return Yr._=Yr,Yr
244 245 246 }(); 247 "undefined" != typeof exports ? ("undefined" != typeof module && module.exports && (exports = module.exports = y), 248 exports._ = y) : s._ = y, 249 y.noConflict = function() { 250 return s._ = o, 251 this 252 } 253 , 254 "function" == typeof define && define.amd && define("underscore", [], function() { 255 return y 256 }) 257} 258).call(this), 259function(n) { 260 var s = "object" == typeof self && self.self == self && self || "object" == typeof global && global.global == global && global; 261 if ("function" == typeof define && define.amd) 262 define(["underscore", "jquery", "exports"], function(t, e, i) { 263 s.Backbone = n(s, i, t, e) 264 }); 265 else if ("undefined" != typeof exports) { 266 var t, e = require("underscore"); 267 try { 268 t = require("jquery") 269 } catch (t) {} 270 n(s, exports, e, t) 271 } else 272 s.Backbone = n(s, {}, s._, s.jQuery || s.Zepto || s.ender || s.$) 273}(function(t, l, w, e) { 274 var i = t.Backbone 275 , o = Array.prototype.slice; 276 l.VERSION = "1.2.3", 277 l.$ = e, 278 l.noConflict = function() { 279 return t.Backbone = i, 280 this 281 } 282 , 283 l.emulateHTTP = !1, 284 l.emulateJSON = !1; 285 var n = function(i, t, n) { 286 w.each(t, function(t, e) { 287 w[e] && (i.prototype[e] = function(t, n, s) { 288 switch (t) { 289 case 1: 290 return function() { 291 return w[n](this[s]) 292 } 293 ; 294 case 2: 295 return function(t) { 296 return w[n](this[s], t) 297 } 298 ; 299 case 3: 300 return function(t, e) { 301 return w[n](this[s], r(t, this), e) 302 } 303 ; 304 case 4: 305 return function(t, e, i) { 306 return w[n](this[s], r(t, this), e, i) 307 } 308 ; 309 default: 310 return function() { 311 var t = o.call(arguments); 312 return t.unshift(this[s]), 313 w[n].apply(w, t) 314 } 315 } 316 }(t, e, n)) 317 }) 318 } 319 , r = function(e, t) { 320 return w.isFunction(e) ? e : w.isObject(e) && !t._isModel(e) ? s(e) : w.isString(e) ? function(t) { 321 return t.get(e) 322 } 323 : e 324 } 325 , s = function(t) { 326 var e = w.matches(t); 327 return function(t) { 328 return e(t.attributes) 329 } 330 } 331 , a = l.Events = {} 332 , c = /\s+/ 333 , u = function(t, e, i, n, s) { 334 var o, r = 0; 335 if (i && "object" == typeof i) { 336 void 0 !== n && "context"in s && void 0 === s.context && (s.context = n); 337 for (o = w.keys(i); r < o.length; r++) 338 e = u(t, e, o[r], i[o[r]], s) 339 } else if (i && c.test(i)) 340 for (o = i.split(c); r < o.length; r++) 341 e = t(e, o[r], n, s); 342 else 343 e = t(e, i, n, s); 344 return e 345 }; 346 a.on = function(t, e, i) { 347 return h(this, t, e, i) 348 } 349 ;
350 var h = function(t, e, i, n, s) { 351 (t._events = u(d, t._events || {}, e, i, { 352 context: n, 353 ctx: t, 354 listening: s 355 }), 356 s) && ((t._listeners || (t._listeners = {}))[s.id] = s); 357 return t 358 }; 359 a.listenTo = function(t, e, i) { 360 if (!t) 361 return this; 362 var n = t._listenId || (t._listenId = w.uniqueId("l")) 363 , s = this._listeningTo || (this._listeningTo = {}) 364 , o = s[n]; 365 if (!o) { 366 var r = this._listenId || (this._listenId = w.uniqueId("l")); 367 o = s[n] = { 368 obj: t, 369 objId: n, 370 id: r, 371 listeningTo: s, 372 count: 0 373 } 374 } 375 return h(t, e, i, this, o), 376 this 377 } 378 ; 379 var d = function(t, e, i, n) { 380 if (i) { 381 var s = t[e] || (t[e] = []) 382 , o = n.context 383 , r = n.ctx 384 , a = n.listening; 385 a && a.count++, 386 s.push({ 387 callback: i, 388 context: o, 389 ctx: o || r, 390 listening: a 391 }) 392 } 393 return t 394 }; 395 a.off = function(t, e, i) { 396 return this._events && (this._events = u(p, this._events, t, e, { 397 context: i, 398 listeners: this._listeners 399 })), 400 this 401 } 402 , 403 a.stopListening = function(t, e, i) { 404 var n = this._listeningTo; 405 if (!n) 406 return this; 407 for (var s = t ? [t._listenId] : w.keys(n), o = 0; o < s.length; o++) { 408 var r = n[s[o]]; 409 if (!r) 410 break; 411 r.obj.off(e, i, this) 412 } 413 return w.isEmpty(n) && (this._listeningTo = void 0), 414 this 415 } 416 ; 417 var p = function(t, e, i, n) { 418 if (t) { 419 var s, o = 0, r = n.context, a = n.listeners; 420 if (e || i || r) { 421 for (var l = e ? [e] : w.keys(t); o < l.length; o++) { 422 var c = t[e = l[o]]; 423 if (!c) 424 break; 425 for (var u = [], h = 0; h < c.length; h++) { 426 var d = c[h]; 427 i && i !== d.callback && i !== d.callback._callback || r && r !== d.context ? u.push(d) : (s = d.listening) && 0 == --s.count && (delete a[s.id], 428 delete s.listeningTo[s.objId]) 429 } 430 u.length ? t[e] = u : delete t[e] 431 } 432 return w.size(t) ? t : void 0 433 } 434 for (var p = w.keys(a); o < p.length; o++) 435 delete a[(s = a[p[o]]).id], 436 delete s.listeningTo[s.objId] 437 } 438 }; 439 a.once = function(t, e, i) { 440 var n = u(f, {}, t, e, w.bind(this.off, this)); 441 return this.on(n, void 0, i) 442 } 443 , 444 a.listenToOnce = function(t, e, i) { 445 var n = u(f, {}, e, i, w.bind(this.stopListening, this, t)); 446 return this.listenTo(t, n) 447 } 448 ; 449 var f = function(t, e, i, n) { 450 if (i) { 451 var s = t[e] = w.once(function() { 452 n(e, s), 453 i.apply(this, arguments) 454 }); 455 s._callback = i 456 } 457 return t 458 }; 459 a.trigger = function(t) { 460 if (!this._events) 461 return this; 462 for (var e = Math.max(0, arguments.length - 1), i = Array(e), n = 0; n < e; n++) 463 i[n] = arguments[n + 1]; 464 return u(g, this._events, t, void 0, i), 465 this 466 } 467 ; 468 var g = function(t, e, i, n) { 469 if (t) { 470 var s = t[e] 471 , o = t.all; 472 s && o && (o = o.slice()), 473 s && m(s, n), 474 o && m(o, [e].concat(n)) 475 } 476 return t 477 } 478 , m = function(t, e) { 479 var i, n = -1, s = t.length, o = e[0], r = e[1], a = e[2]; 480 switch (e.length) { 481 case 0: 482 for (; ++n < s; ) 483 (i = t[n]).callback.call(i.ctx); 484 return; 485 case 1: 486 for (; ++n < s; ) 487 (i = t[n]).callback.call(i.ctx, o); 488 return; 489 case 2: 490 for (; ++n < s; ) 491 (i = t[n]).callback.call(i.ctx, o, r); 492 return; 493 case 3: 494 for (; ++n < s; ) 495 (i = t[n]).callback.call(i.ctx, o, r, a); 496 return; 497 default: 498 for (; ++n < s; ) 499 (i = t[n]).callback.apply(i.ctx, e); 500 return 501 } 502 }; 503 a.bind = a.on, 504 a.unbind = a.off, 505 w.extend(l, a); 506 var v = l.Model = function(t, e) { 507 var i = t || {}; 508 e || (e = {}), 509 this.cid = w.uniqueId(this.cidPrefix), 510 this.attributes = {}, 511 e.collection && (this.collection = e.collection), 512 e.parse && (i = this.parse(i, e) || {}), 513 i = w.defaults({}, i, w.result(this, "defaults")), 514 this.set(i, e), 515 this.changed = {}, 516 this.initialize.apply(this, arguments) 517 } 518 ; 519 w.extend(v.prototype, a, { 520 changed: null, 521 validationError: null, 522 idAttribute: "id", 523 cidPrefix: "c", 524 initialize: function() {}, 525 toJSON: function() { 526 return w.clone(this.attributes) 527 }, 528 sync: function() { 529 return l.sync.apply(this, arguments) 530 }, 531 get: function(t) { 532 return this.attributes[t] 533 }, 534 escape: function(t) { 535 return w.escape(this.get(t)) 536 }, 537 has: function(t) { 538 return null != this.get(t) 539 }, 540 matches: function(t) { 541 return !!w.iteratee(t, this)(this.attributes) 542 }, 543 set: function(t, e, i) { 544 if (null == t) 545 return this; 546 var n; 547 if ("object" == typeof t ? (n = t, 548 i = e) : (n = {})[t] = e, 549 i || (i = {}),
550 !this._validate(n, i)) 551 return !1; 552 var s = i.unset 553 , o = i.silent 554 , r = [] 555 , a = this._changing; 556 this._changing = !0, 557 a || (this._previousAttributes = w.clone(this.attributes), 558 this.changed = {}); 559 var l = this.attributes 560 , c = this.changed 561 , u = this._previousAttributes; 562 for (var h in n) 563 e = n[h], 564 w.isEqual(l[h], e) || r.push(h), 565 w.isEqual(u[h], e) ? delete c[h] : c[h] = e, 566 s ? delete l[h] : l[h] = e; 567 if (this.id = this.get(this.idAttribute), 568 !o) { 569 r.length && (this._pending = i); 570 for (var d = 0; d < r.length; d++) 571 this.trigger("change:" + r[d], this, l[r[d]], i) 572 } 573 if (a) 574 return this; 575 if (!o) 576 for (; this._pending; ) 577 i = this._pending, 578 this._pending = !1, 579 this.trigger("change", this, i); 580 return this._pending = !1, 581 this._changing = !1, 582 this 583 }, 584 unset: function(t, e) { 585 return this.set(t, void 0, w.extend({}, e, { 586 unset: !0 587 })) 588 }, 589 clear: function(t) { 590 var e = {}; 591 for (var i in this.attributes) 592 e[i] = void 0; 593 return this.set(e, w.extend({}, t, { 594 unset: !0 595 })) 596 }, 597 hasChanged: function(t) { 598 return null == t ? !w.isEmpty(this.changed) : w.has(this.changed, t) 599 }, 600 changedAttributes: function(t) { 601 if (!t) 602 return !!this.hasChanged() && w.clone(this.changed); 603 var e = this._changing ? this._previousAttributes : this.attributes 604 , i = {}; 605 for (var n in t) { 606 var s = t[n]; 607 w.isEqual(e[n], s) || (i[n] = s) 608 } 609 return !!w.size(i) && i 610 }, 611 previous: function(t) { 612 return null != t && this._previousAttributes ? this._previousAttributes[t] : null 613 }, 614 previousAttributes: function() { 615 return w.clone(this._previousAttributes) 616 }, 617 fetch: function(i) { 618 i = w.extend({ 619 parse: !0 620 }, i); 621 var n = this 622 , s = i.success; 623 return i.success = function(t) { 624 var e = i.parse ? n.parse(t, i) : t; 625 if (!n.set(e, i)) 626 return !1; 627 s && s.call(i.context, n, t, i), 628 n.trigger("sync", n, t, i) 629 } 630 , 631 L(this, i), 632 this.sync("read", this, i) 633 }, 634 save: function(t, e, i) { 635 var n; 636 null == t || "object" == typeof t ? (n = t, 637 i = e) : (n = {})[t] = e; 638 var s = (i = w.extend({ 639 validate: !0, 640 parse: !0 641 }, i)).wait; 642 if (n && !s) { 643 if (!this.set(n, i)) 644 return !1 645 } else if (!this._validate(n, i)) 646 return !1; 647 var o = this 648 , r = i.success 649 , a = this.attributes; 650 i.success = function(t) { 651 o.attributes = a; 652 var e = i.parse ? o.parse(t, i) : t; 653 if (s && (e = w.extend({}, n, e)), 654 e && !o.set(e, i)) 655 return !1; 656 r && r.call(i.context, o, t, i), 657 o.trigger("sync", o, t, i) 658 } 659 , 660 L(this, i), 661 n && s && (this.attributes = w.extend({}, a, n)); 662 var l = this.isNew() ? "create" : i.patch ? "patch" : "update"; 663 "patch" !== l || i.attrs || (i.attrs = n); 664 var c = this.sync(l, this, i); 665 return this.attributes = a, 666 c 667 }, 668 destroy: function(e) { 669 e = e ? w.clone(e) : {}; 670 var i = this 671 , n = e.success 672 , s = e.wait 673 , o = function() { 674 i.stopListening(), 675 i.trigger("destroy", i, i.collection, e) 676 } 677 , t = !(e.success = function(t) { 678 s && o(), 679 n && n.call(e.context, i, t, e), 680 i.isNew() || i.trigger("sync", i, t, e) 681 } 682 ); 683 return this.isNew() ? w.defer(e.success) : (L(this, e), 684 t = this.sync("delete", this, e)), 685 s || o(), 686 t 687 }, 688 url: function() { 689 var t = w.result(this, "urlRoot") || w.result(this.collection, "url") || $(); 690 if (this.isNew()) 691 return t; 692 var e = this.get(this.idAttribute); 693 return t.replace(/[^\/]$/, "$&/") + encodeURIComponent(e) 694 }, 695 parse: function(t) { 696 return t 697 }, 698 clone: function() { 699 return new this.constructor(this.attributes) 700 }, 701 isNew: function() { 702 return !this.has(this.idAttribute) 703 }, 704 isValid: function(t) {
705 return this._validate({}, w.defaults({ 706 validate: !0 707 }, t)) 708 }, 709 _validate: function(t, e) { 710 if (!e.validate || !this.validate) 711 return !0; 712 t = w.extend({}, this.attributes, t); 713 var i = this.validationError = this.validate(t, e) || null; 714 return !i || (this.trigger("invalid", this, i, w.extend(e, { 715 validationError: i 716 })), 717 !1) 718 } 719 }); 720 n(v, { 721 keys: 1, 722 values: 1, 723 pairs: 1, 724 invert: 1, 725 pick: 0, 726 omit: 0, 727 chain: 1, 728 isEmpty: 1 729 }, "attributes"); 730 var y = l.Collection = function(t, e) { 731 e || (e = {}), 732 e.model && (this.model = e.model), 733 void 0 !== e.comparator && (this.comparator = e.comparator), 734 this._reset(), 735 this.initialize.apply(this, arguments), 736 t && this.reset(t, w.extend({ 737 silent: !0 738 }, e)) 739 } 740 , x = { 741 add: !0, 742 remove: !0, 743 merge: !0 744 } 745 , b = { 746 add: !0, 747 remove: !1 748 } 749 , _ = function(t, e, i) { 750 i = Math.min(Math.max(i, 0), t.length); 751 for (var n = Array(t.length - i), s = e.length, o = 0; o < n.length; o++) 752 n[o] = t[o + i]; 753 for (o = 0; o < s; o++) 754 t[o + i] = e[o]; 755 for (o = 0; o < n.length; o++) 756 t[o + s + i] = n[o] 757 }; 758 w.extend(y.prototype, a, { 759 model: v, 760 initialize: function() {}, 761 toJSON: function(e) { 762 return this.map(function(t) { 763 return t.toJSON(e) 764 }) 765 }, 766 sync: function() { 767 return l.sync.apply(this, arguments) 768 }, 769 add: function(t, e) { 770 return this.set(t, w.extend({ 771 merge: !1 772 }, e, b)) 773 }, 774 remove: function(t, e) { 775 e = w.extend({}, e); 776 var i = !w.isArray(t); 777 t = i ? [t] : w.clone(t); 778 var n = this._removeModels(t, e); 779 return !e.silent && n && this.trigger("update", this, e), 780 i ? n[0] : n 781 }, 782 set: function(t, e) { 783 if (null != t) { 784 (e = w.defaults({}, e, x)).parse && !this._isModel(t) && (t = this.parse(t, e)); 785 var i = !w.isArray(t); 786 t = i ? [t] : t.slice(); 787 var n = e.at; 788 null != n && (n = +n), 789 n < 0 && (n += this.length + 1); 790 for (var s, o = [], r = [], a = [], l = {}, c = e.add, u = e.merge, h = e.remove, d = !1, p = this.comparator && null == n && !1 !== e.sort, f = w.isString(this.comparator) ? this.comparator : null, g = 0; g < t.length; g++) { 791 s = t[g]; 792 var m = this.get(s); 793 if (m) { 794 if (u && s !== m) { 795 var v = this._isModel(s) ? s.attributes : s; 796 e.parse && (v = m.parse(v, e)), 797 m.set(v, e), 798 p && !d && (d = m.hasChanged(f)) 799 } 800 l[m.cid] || (l[m.cid] = !0, 801 o.push(m)), 802 t[g] = m 803 } else 804 c && (s = t[g] = this._prepareModel(s, e)) && (r.push(s), 805 this._addReference(s, e), 806 l[s.cid] = !0, 807 o.push(s)) 808 } 809 if (h) { 810 for (g = 0; g < this.length; g++) 811 l[(s = this.models[g]).cid] || a.push(s); 812 a.length && this._removeModels(a, e) 813 } 814 var y = !1 815 , b = !p && c && h; 816 if (o.length && b ? (y = this.length != o.length || w.some(this.models, function(t, e) { 817 return t !== o[e] 818 }), 819 this.models.length = 0, 820 _(this.models, o, 0), 821 this.length = this.models.length) : r.length && (p && (d = !0), 822 _(this.models, r, null == n ? this.length : n), 823 this.length = this.models.length), 824 d && this.sort({ 825 silent: !0 826 }), 827 !e.silent) { 828 for (g = 0; g < r.length; g++) 829 null != n && (e.index = n + g), 830 (s = r[g]).trigger("add", s, this, e); 831 (d || y) && this.trigger("sort", this, e), 832 (r.length || a.length) && this.trigger("update", this, e) 833 } 834 return i ? t[0] : t 835 } 836 }, 837 reset: function(t, e) { 838 e = e ? w.clone(e) : {}; 839 for (var i = 0; i < this.models.length; i++) 840 this._removeReference(this.models[i], e); 841 return e.previousModels = this.models, 842 this._reset(), 843 t = this.add(t, w.extend({ 844 silent: !0 845 }, e)), 846 e.silent || this.trigger("reset", this, e), 847 t 848 }, 849 push: function(t, e) { 850 return this.add(t, w.extend({ 851 at: this.length 852 }, e)) 853 }, 854 pop: function(t) { 855 var e = this.at(this.length - 1); 856 return this.remove(e, t) 857 }, 858 unshift: function(t, e) { 859 return this.add(t, w.extend({ 860 at: 0 861 }, e)) 862 }, 863 shift: function(t) { 864 var e = this.at(0); 865 return this.remove(e, t) 866 }, 867 slice: function() { 868 return o.apply(this.models, arguments) 869 }, 870 get: function(t) { 871 if (null != t) { 872 var e = this.modelId(this._isModel(t) ? t.attributes : t); 873 return this._byId[t] || this._byId[e] || this._byId[t.cid] 874 } 875 }, 876 at: function(t) { 877 return t < 0 && (t += this.length), 878 this.models[t] 879 }, 880 where: function(t, e) { 881 return this[e ? "find" : "filter"](t) 882 }, 883 findWhere: function(t) { 884 return this.where(t, !0) 885 }, 886 sort: function(t) { 887 var e = this.comparator; 888 if (!e) 889 throw new Error("Cannot sort a set without a comparator"); 890 t || (t = {}); 891 var i = e.length; 892 return w.isFunction(e) && (e = w.bind(e, this)), 893 1 === i || w.isString(e) ? this.models = this.sortBy(e) : this.models.sort(e), 894 t.silent || this.trigger("sort", this, t), 895 this 896 }, 897 pluck: function(t) { 898 return w.invoke(this.models, "get", t) 899 }, 900 fetch: function(i) { 901 var n = (i = w.extend({ 902 parse: !0 903 }, i)).success 904 , s = this; 905 return i.success = function(t) { 906 var e = i.reset ? "reset" : "set"; 907 s[e](t, i), 908 n && n.call(i.context, s, t, i), 909 s.trigger("sync", s, t, i) 910 } 911 , 912 L(this, i), 913 this.sync("read", this, i) 914 }, 915 create: function(t, e) { 916 var n = (e = e ? w.clone(e) : {}).wait; 917 if (!(t = this._prepareModel(t, e))) 918 return !1; 919 n || this.add(t, e); 920 var s = this 921 , o = e.success; 922 return e.success = function(t, e, i) { 923 n && s.add(t, i), 924 o && o.call(i.context, t, e, i) 925 } 926 , 927 t.save(null, e), 928 t 929 }, 930 parse: function(t) { 931 return t 932 }, 933 clone: function() { 934 return new this.constructor(this.models,{ 935 model: this.model, 936 comparator: this.comparator 937 }) 938 }, 939 modelId: function(t) { 940 return t[this.model.prototype.idAttribute || "id"] 941 }, 942 _reset: function() { 943 this.length = 0, 944 this.models = [], 945 this._byId = {} 946 }, 947 _prepareModel: function(t, e) { 948 if (this._isModel(t)) 949 return t.collection || (t.collection = this), 950 t; 951 var i = new (((e = e ? w.clone(e) : {}).collection = this).model)(t,e); 952 return i.validationError ? (this.trigger("invalid", this, i.validationError, e), 953 !1) : i 954 }, 955 _removeModels: function(t, e) { 956 for (var i = [], n = 0; n < t.length; n++) { 957 var s = this.get(t[n]); 958 if (s) { 959 var o = this.indexOf(s); 960 this.models.splice(o, 1), 961 this.length--, 962 e.silent || (e.index = o, 963 s.trigger("remove", s, this, e)), 964 i.push(s), 965 this._removeReference(s, e) 966 } 967 } 968 return !!i.length && i 969 }, 970 _isModel: function(t) { 971 return t instanceof v 972 }, 973 _addReference: function(t) { 974 this._byId[t.cid] = t; 975 var e = this.modelId(t.attributes); 976 null != e && (this._byId[e] = t), 977 t.on("all", this._onModelEvent, this) 978 }, 979 _removeReference: function(t) { 980 delete this._byId[t.cid]; 981 var e = this.modelId(t.attributes); 982 null != e && delete this._byId[e], 983 this === t.collection && delete t.collection, 984 t.off("all", this._onModelEvent, this) 985 }, 986 _onModelEvent: function(t, e, i, n) { 987 if ("add" !== t && "remove" !== t || i === this) { 988 if ("destroy" === t && this.remove(e, n), 989 "change" === t) { 990 var s = this.modelId(e.previousAttributes()) 991 , o = this.modelId(e.attributes); 992 s !== o && (null != s && delete this._byId[s], 993 null != o && (this._byId[o] = e)) 994 } 995 this.trigger.apply(this, arguments) 996 } 997 } 998 }); 999 n(y, {
1000 forEach: 3, 1001 each: 3, 1002 map: 3, 1003 collect: 3, 1004 reduce: 4, 1005 foldl: 4, 1006 inject: 4, 1007 reduceRight: 4, 1008 foldr: 4, 1009 find: 3, 1010 detect: 3, 1011 filter: 3, 1012 select: 3, 1013 reject: 3, 1014 every: 3, 1015 all: 3, 1016 some: 3, 1017 any: 3, 1018 include: 3, 1019 includes: 3, 1020 contains: 3, 1021 invoke: 0, 1022 max: 3, 1023 min: 3, 1024 toArray: 1, 1025 size: 1, 1026 first: 3, 1027 head: 3, 1028 take: 3, 1029 initial: 3, 1030 rest: 3, 1031 tail: 3, 1032 drop: 3, 1033 last: 3, 1034 without: 0, 1035 difference: 0, 1036 indexOf: 3, 1037 shuffle: 1, 1038 lastIndexOf: 3, 1039 isEmpty: 1, 1040 chain: 1, 1041 sample: 3, 1042 partition: 3, 1043 groupBy: 3, 1044 countBy: 3, 1045 sortBy: 3, 1046 indexBy: 3 1047 }, "models"); 1048 var k = l.View = function(t) { 1049 this.cid = w.uniqueId("view"), 1050 w.extend(this, w.pick(t, S)), 1051 this._ensureElement(), 1052 this.initialize.apply(this, arguments) 1053 } 1054 , C = /^(\S+)\s*(.*)$/ 1055 , S = ["model", "collection", "el", "id", "attributes", "className", "tagName", "events"]; 1056 w.extend(k.prototype, a, { 1057 tagName: "div", 1058 $: function(t) { 1059 return this.$el.find(t) 1060 }, 1061 initialize: function() {}, 1062 render: function() { 1063 return this 1064 }, 1065 remove: function() { 1066 return this._removeElement(), 1067 this.stopListening(), 1068 this 1069 }, 1070 _removeElement: function() { 1071 this.$el.remove() 1072 }, 1073 setElement: function(t) { 1074 return this.undelegateEvents(), 1075 this._setElement(t), 1076 this.delegateEvents(), 1077 this 1078 }, 1079 _setElement: function(t) { 1080 this.$el = t instanceof l.$ ? t : l.$(t), 1081 this.el = this.$el[0] 1082 }, 1083 delegateEvents: function(t) { 1084 if (t || (t = w.result(this, "events")), 1085 !t) 1086 return this; 1087 for (var e in this.undelegateEvents(), 1088 t) { 1089 var i = t[e]; 1090 if (w.isFunction(i) || (i = this[i]), 1091 i) { 1092 var n = e.match(C); 1093 this.delegate(n[1], n[2], w.bind(i, this)) 1094 } 1095 } 1096 return this 1097 }, 1098 delegate: function(t, e, i) { 1099 return this.$el.on(t + ".delegateEvents" + this.cid, e, i), 1100 this 1101 }, 1102 undelegateEvents: function() { 1103 return this.$el && this.$el.off(".delegateEvents" + this.cid), 1104 this 1105 }, 1106 undelegate: function(t, e, i) { 1107 return this.$el.off(t + ".delegateEvents" + this.cid, e, i), 1108 this 1109 }, 1110 _createElement: function(t) { 1111 return document.createElement(t) 1112 }, 1113 _ensureElement: function() { 1114 if (this.el) 1115 this.setElement(w.result(this, "el")); 1116 else { 1117 var t = w.extend({}, w.result(this, "attributes")); 1118 this.id && (t.id = w.result(this, "id")), 1119 this.className && (t.class = w.result(this, "className")), 1120 this.setElement(this._createElement(w.result(this, "tagName"))), 1121 this._setAttributes(t) 1122 } 1123 }, 1124 _setAttributes: function(t) { 1125 this.$el.attr(t) 1126 } 1127 }), 1128 l.sync = function(t, e, n) { 1129 var i = T[t]; 1130 w.defaults(n || (n = {}), { 1131 emulateHTTP: l.emulateHTTP, 1132 emulateJSON: l.emulateJSON 1133 }); 1134 var s = { 1135 type: i, 1136 dataType: "json" 1137 }; 1138 if (n.url || (s.url = w.result(e, "url") || $()), 1139 null != n.data || !e || "create" !== t && "update" !== t && "patch" !== t || (s.contentType = "application/json", 1140 s.data = JSON.stringify(n.attrs || e.toJSON(n))), 1141 n.emulateJSON && (s.contentType = "application/x-www-form-urlencoded", 1142 s.data = s.data ? { 1143 model: s.data 1144 } : {}), 1145 n.emulateHTTP && ("PUT" === i || "DELETE" === i || "PATCH" === i)) { 1146 s.type = "POST", 1147 n.emulateJSON && (s.data._method = i); 1148 var o = n.beforeSend; 1149 n.beforeSend = function(t) { 1150 if (t.setRequestHeader("X-HTTP-Method-Override", i), 1151 o) 1152 return o.apply(this, arguments) 1153 } 1154 } 1155 "GET" === s.type || n.emulateJSON || (s.processData = !1); 1156 var r = n.error; 1157 n.error = function(t, e, i) { 1158 n.textStatus = e, 1159 n.errorThrown = i, 1160 r && r.call(n.context, t, e, i) 1161 } 1162 ; 1163 var a = n.xhr = l.ajax(w.extend(s, n)); 1164 return e.trigger("request", e, a, n), 1165 a 1166 } 1167 ; 1168 var T = { 1169 create: "POST", 1170 update: "PUT", 1171 patch: "PATCH", 1172 delete: "DELETE", 1173 read: "GET" 1174 }; 1175 l.ajax = function() { 1176 return l.$.ajax.apply(l.$, arguments) 1177 } 1178 ; 1179 var I = l.Router = function(t) { 1180 t || (t = {}), 1181 t.routes && (this.routes = t.routes), 1182 this._bindRoutes(), 1183 this.initialize.apply(this, arguments) 1184 } 1185 , P = /\((.*?)\)/g 1186 , E = /(\(\?)?:\w+/g 1187 , M = /\*\w+/g 1188 , D = /[\-{}\[\]+?.,\\\^$|#\s]/g; 1189 w.extend(I.prototype, a, { 1190 initialize: function() {}, 1191 route: function(i, n, s) { 1192 w.isRegExp(i) || (i = this._routeToRegExp(i)), 1193 w.isFunction(n) && (s = n, 1194 n = ""), 1195 s || (s = this[n]); 1196 var o = this; 1197 return l.history.route(i, function(t) { 1198 var e = o._extractParameters(i, t); 1199 !1 !== o.execute(s, e, n) && (o.trigger.apply(o, ["route:" + n].concat(e)), 1200 o.trigger("route", n, e), 1201 l.history.trigger("route", o, n, e)) 1202 }), 1203 this 1204 }, 1205 execute: function(t, e) { 1206 t && t.apply(this, e) 1207 }, 1208 navigate: function(t, e) { 1209 return l.history.navigate(t, e), 1210 this 1211 }, 1212 _bindRoutes: function() { 1213 if (this.routes) { 1214 this.routes = w.result(this, "routes"); 1215 for (var t, e = w.keys(this.routes); null != (t = e.pop()); ) 1216 this.route(t, this.routes[t]) 1217 } 1218 }, 1219 _routeToRegExp: function(t) { 1220 return t = t.replace(D, "\\$&").replace(P, "(?:$1)?").replace(E, function(t, e) { 1221 return e ? t : "([^/?]+)" 1222 }).replace(M, "([^?]*?)"), 1223 new RegExp("^" + t + "(?:\\?([\\s\\S]*))?$") 1224 }, 1225 _extractParameters: function(t, e) { 1226 var i = t.exec(e).slice(1); 1227 return w.map(i, function(t, e) { 1228 return e === i.length - 1 ? t || null : t ? decodeURIComponent(t) : null 1229 }) 1230 } 1231 }); 1232 var A = l.History = function() { 1233 this.handlers = [], 1234 this.checkUrl = w.bind(this.checkUrl, this), 1235 "undefined" != typeof window && (this.location = window.location, 1236 this.history = window.history) 1237 } 1238 , j = /^[#\/]|\s+$/g 1239 , O = /^\/+|\/+$/g 1240 , z = /#.*$/; 1241 A.started = !1, 1242 w.extend(A.prototype, a, { 1243 interval: 50, 1244 atRoot: function() { 1245 return this.location.pathname.replace(/[^\/]$/, "$&/") === this.root && !this.getSearch() 1246 }, 1247 matchRoot: function() { 1248 return this.decodeFragment(this.location.pathname).slice(0, this.root.length - 1) + "/" === this.root 1249 }, 1250 decodeFragment: function(t) { 1251 return decodeURI(t.replace(/%25/g, "%2525")) 1252 }, 1253 getSearch: function() { 1254 var t = this.location.href.replace(/#.*/, "").match(/\?.+/); 1255 return t ? t[0] : "" 1256 }, 1257 getHash: function(t) { 1258 var e = (t || this).location.href.match(/#(.*)$/); 1259 return e ? e[1] : "" 1260 }, 1261 getPath: function() { 1262 var t = this.decodeFragment(this.location.pathname + this.get
1262Search()).slice(this.root.length - 1); 1263 return "/" === t.charAt(0) ? t.slice(1) : t 1264 }, 1265 getFragment: function(t) { 1266 return null == t && (t = this._usePushState || !this._wantsHashChange ? this.getPath() : this.getHash()), 1267 t.replace(j, "") 1268 }, 1269 start: function(t) { 1270 if (A.started) 1271 throw new Error("Backbone.history has already been started"); 1272 if (A.started = !0, 1273 this.options = w.extend({ 1274 root: "/" 1275 }, this.options, t), 1276 this.root = this.options.root, 1277 this._wantsHashChange = !1 !== this.options.hashChange, 1278 this._hasHashChange = "onhashchange"in window && (void 0 === document.documentMode || 7 < document.documentMode), 1279 this._useHashChange = this._wantsHashChange && this._hasHashChange, 1280 this._wantsPushState = !!this.options.pushState, 1281 this._hasPushState = !(!this.history || !this.history.pushState), 1282 this._usePushState = this._wantsPushState && this._hasPushState, 1283 this.fragment = this.getFragment(), 1284 this.root = ("/" + this.root + "/").replace(O, "/"), 1285 this._wantsHashChange && this._wantsPushState) { 1286 if (!this._hasPushState && !this.atRoot()) { 1287 var e = this.root.slice(0, -1) || "/"; 1288 return this.location.replace(e + "#" + this.getPath()), 1289 !0 1290 } 1291 this._hasPushState && this.atRoot() && this.navigate(this.getHash(), { 1292 replace: !0 1293 }) 1294 } 1295 if (!this._hasHashChange && this._wantsHashChange && !this._usePushState) { 1296 this.iframe = document.createElement("iframe"), 1297 this.iframe.src = "javascript:0", 1298 this.iframe.style.display = "none", 1299 this.iframe.tabIndex = -1; 1300 var i = document.body 1301 , n = i.insertBefore(this.iframe, i.firstChild).contentWindow; 1302 n.document.open(), 1303 n.document.close(), 1304 n.location.hash = "#" + this.fragment 1305 } 1306 var s = window.addEventListener || function(t, e) { 1307 return attachEvent("on" + t, e) 1308 } 1309 ; 1310 if (this._usePushState ? s("popstate", this.checkUrl, !1) : this._useHashChange && !this.iframe ? s("hashchange", this.checkUrl, !1) : this._wantsHashChange && (this._checkUrlInterval = setInterval(this.checkUrl, this.interval)), 1311 !this.options.silent) 1312 return this.loadUrl() 1313 }, 1314 stop: function() { 1315 var t = window.removeEventListener || function(t, e) { 1316 return detachEvent("on" + t, e) 1317 } 1318 ; 1319 this._usePushState ? t("popstate", this.checkUrl, !1) : this._useHashChange && !this.iframe && t("hashchange", this.checkUrl, !1), 1320 this.iframe && (document.body.removeChild(this.iframe), 1321 this.iframe = null), 1322 this._checkUrlInterval && clearInterval(this._checkUrlInterval), 1323 A.started = !1 1324 }, 1325 route: function(t, e) { 1326 this.handlers.unshift({ 1327 route: t, 1328 callback: e 1329 }) 1330 }, 1331 checkUrl: function() { 1332 var t = this.getFragment(); 1333 if (t === this.fragment && this.iframe && (t = this.getHash(this.iframe.contentWindow)), 1334 t === this.fragment) 1335 return !1; 1336 this.iframe && this.navigate(t), 1337 this.loadUrl() 1338 }, 1339 loadUrl: function(e) { 1340 return !!this.matchRoot() && (e = this.fragment = this.getFragment(e), 1341 w.some(this.handlers, function(t) { 1342 if (t.route.test(e)) 1343 return t.callback(e), 1344 !0 1345 })) 1346 }, 1347 navigate: function(t, e) { 1348 if (!A.started) 1349 return !1; 1350 e && !0 !== e || (e = { 1351 trigger: !!e 1352 }), 1353 t = this.getFragment(t || ""); 1354 var i = this.root; 1355 "" !== t && "?" !== t.charAt(0) || (i = i.slice(0, -1) || "/"); 1356 var n = i + t; 1357 if (t = this.decodeFragment(t.replace(z, "")), 1358 this.fragment !== t) { 1359 if (this.fragment = t, 1360 this._usePushState) 1361 this.history[e.replace ? "replaceState" : "pushState"]({}, document.title, n); 1362 else { 1363 if (!this._wantsHashChange) 1364 return this.location.assign(n); 1365 if (this._updateHash(this.location, t, e.replace), 1366 this.iframe && t !== this.getHash(this.iframe.contentWindow)) { 1367 var s = this.iframe.contentWindow; 1368 e.replace || (s.document.open(), 1369 s.document.close()), 1370 this._updateHash(s.location, t, e.replace) 1371 } 1372 } 1373 return e.trigger ? this.loadUrl(t) : void 0 1374 } 1375 }, 1376 _updateHash: function(t, e, i) { 1377 if (i) { 1378 var n = t.href.replace(/(javascript:|#).*$/, ""); 1379 t.replace(n + "#" + e) 1380 } else 1381 t.hash = "#" + e 1382 } 1383 }), 1384 l.history = new A; 1385 v.extend = y.extend = I.extend = k.extend = A.extend = function(t, e) { 1386 var i, n = this; 1387 i = t && w.has(t, "constructor") ? t.constructor : function() { 1388 return n.apply(this, arguments) 1389 } 1390 , 1391 w.extend(i, n, e); 1392 var s = function() { 1393 this.constructor = i 1394 }; 1395 return s.prototype = n.prototype, 1396 i.prototype = new s, 1397 t && w.extend(i.prototype, t), 1398 i.__super__ = n.prototype, 1399 i 1400 } 1401 ; 1402 var $ = function() { 1403 throw new Error('A "url" property or function must be specified') 1404 } 1405 , L = function(e, i) { 1406 var n = i.error; 1407 i.error = function(t) { 1408 n && n.call(i.context, e, t, i), 1409 e.trigger("error", e, t, i) 1410 } 1411 }; 1412 return l 1413}), 1414function() { 1415 var s, e = Object.prototype.toString; 1416 Array.isArray = Array.isArray || function(t) { 1417 return "[object Array]" == e.call(t) 1418 } 1419 ; 1420 var o, i, n, r = String.prototype.trim; 1421 r ? o = function(t) { 1422 return null == t ? "" : r.call(t) 1423 } 1424 : (/\S/.test("Â ") ? (i = /^[\s\xA0]+/,
1425 n = /[\s\xA0]+$/) : (i = /^\s+/, 1426 n = /\s+$/), 1427 o = function(t) { 1428 return null == t ? "" : t.toString().replace(i, "").replace(n, "") 1429 } 1430 ); 1431 var c = { 1432 "&": "&", 1433 "<": "<", 1434 ">": ">", 1435 '"': """, 1436 "'": "'" 1437 } 1438 , a = {} 1439 , l = function() {}; 1440 l.prototype = { 1441 otag: "{{", 1442 ctag: "}}", 1443 pragmas: {}, 1444 buffer: [], 1445 pragmas_implemented: { 1446 "IMPLICIT-ITERATOR": !0 1447 }, 1448 context: {}, 1449 render: function(t, e, i, n) { 1450 if (n || (this.context = e, 1451 this.buffer = []), 1452 this.includes("", t)) { 1453 t = this.render_pragmas(t); 1454 var s = this.render_section(t, e, i); 1455 if (!1 === s && (s = this.render_tags(t, e, i, n)), 1456 n) 1457 return s; 1458 this.sendLines(s) 1459 } else { 1460 if (n) 1461 return t; 1462 this.send(t) 1463 } 1464 }, 1465 send: function(t) { 1466 "" !== t && this.buffer.push(t) 1467 }, 1468 sendLines: function(t) { 1469 if (t) { 1470 t = t.split("\n"); 1471 for (var e = 0; e < t.length; e++) 1472 this.send(t[e]) 1473 } 1474 }, 1475 render_pragmas: function(t) { 1476 if (!this.includes("%", t)) 1477 return t; 1478 var n = this 1479 , e = this.getCachedRegex("render_pragmas", function(t, e) { 1480 return RegExp(t + "%([\\w-]+) ?([\\w]+=[\\w]+)?" + e, "g") 1481 }); 1482 return t.replace(e, function(t, e, i) { 1483 if (!n.pragmas_implemented[e]) 1484 throw { 1485 message: "This implementation of mustache doesn't understand the '" + e + "' pragma" 1486 }; 1487 return n.pragmas[e] = {}, 1488 i && (t = i.split("="), 1489 n.pragmas[e][t[0]] = t[1]), 1490 "" 1491 }) 1492 }, 1493 render_partial: function(t, e, i) { 1494 if (t = o(t), 1495 !i || void 0 === i[t]) 1496 throw { 1497 message: "unknown_partial '" + t + "'" 1498 }; 1499 return e && "object" == typeof e[t] ? this.render(i[t], e[t], i, !0) : this.render(i[t], e, i, !0) 1500 }, 1501 render_section: function(t, a, l) { 1502 if (!this.includes("#", t) && !this.includes("^", t)) 1503 return !1; 1504 var c = this 1505 , e = this.getCachedRegex("render_section", function(t, e) { 1506 return RegExp("^([\\s\\S]*?)" + t + "(\\^|\\#)\\s*(.+)\\s*" + e + "\n*([\\s\\S]*?)" + t + "\\/\\s*\\3\\s*" + e + "\\s*([\\s\\S]*)$", "g") 1507 }); 1508 return t.replace(e, function(t, e, i, n, s, o) { 1509 var r; 1510 return t = e ? c.render_tags(e, a, l, !0) : "", 1511 o = o ? c.render(o, a, l, !0) : "", 1512 n = c.find(n, a), 1513 "^" === i ? r = !n || Array.isArray(n) && 0 === n.length ? c.render(s, a, l, !0) : "" : "#" === i && (r = Array.isArray(n) ? c.map(n, function(t) { 1514 return c.render(s, c.create_context(t), l, !0) 1515 }).join("") : c.is_object(n) ? c.render(s, c.create_context(n), l, !0) : "function" == typeof n ? n.call(a, s, function(t) { 1516 return c.render(t, a, l, !0) 1517 }) : n ? c.render(s, a, l, !0) : ""), 1518 t + r + o 1519 }) 1520 }, 1521 render_tags: function(t, n, s, e) { 1522 var o = this 1523 , r = function() { 1524 return o.getCachedRegex("render_tags", function(t, e) { 1525 return RegExp(t + "(=|!|>|&|\\{|%)?([^#\\^]+?)\\1?" + e + "+", "g") 1526 }) 1527 } 1528 , a = r() 1529 , i = function(t, e, i) { 1530 switch (e) { 1531 case "!": 1532 return ""; 1533 case "=": 1534 return o.set_delimiters(i), 1535 a = r(), 1536 ""; 1537 case ">": 1538 return o.render_partial(i, n, s); 1539 case "{": 1540 case "&": 1541 return o.find(i, n); 1542 default: 1543 return t = o.find(i, n), 1544 String(t).replace(/&(?!\w+;)|[<>"']/g, function(t) { 1545 return c[t] || t 1546 }) 1547 } 1548 }; 1549 t = t.split("\n"); 1550 for (var l = 0; l < t.length; l++) 1551 t[l] = t[l].replace(a, i, this), 1552 e || this.send(t[l]); 1553 if (e) 1554 return t.join("\n") 1555 }, 1556 set_delimiters: function(t) { 1557 t = t.split(" "), 1558 this.otag = this.escape_regex(t[0]), 1559 this.ctag = this.escape_regex(t[1]) 1560 }, 1561 escape_regex: function(t) { 1562 return arguments.callee.sRE || (arguments.callee.sRE = RegExp("(\\/|\\.|\\*|\\+|\\?|\\||\\(|\\)|\\[|\\]|\\{|\\}|\\\\)", "g")), 1563 t.replace(arguments.callee.sRE, "\\$1") 1564 }, 1565 find: function(t, e) { 1566 var i; 1567 if ((t = o(t)).match(/([a-z_]+)\./gi)) { 1568 var n = this.walk_context(t, e); 1569 (!1 === n || 0 === n || n) && (i = n) 1570 } else 1571 !1 === e[t] || 0 === e[t] || e[t] ? i = e[t] : (!1 === this.context[t] || 0 === this.context[t] || this.context[t]) && (i = this.context[t]); 1572 return "function" == typeof i ? i.apply(e) : void 0 !== i ? i : "" 1573 }, 1574 walk_context: function(t, e) { 1575 for (var i = t.split("."), n = null != e[i[0]] ? e : this.context, s = n[i.shift()]; null != s && 0 < i.length; ) 1576 s = (n = s)[i.shift()]; 1577 return "function" == typeof s ? s.apply(n) : s 1578 }, 1579 includes: function(t, e) { 1580 return -1 != e.indexOf(this.otag + t) 1581 }, 1582 create_context: function(t) { 1583 if (this.is_object(t)) 1584 return t; 1585 var e = "."; 1586 this.pragmas["IMPLICIT-ITERATOR"] && (e = this.pragmas["IMPLICIT-ITERATOR"].iterator); 1587 var i = {}; 1588 return i[e] = t, 1589 i 1590 }, 1591 is_object: function(t) { 1592 return t && "object" == typeof t 1593 }, 1594 map: function(t, e) { 1595 if ("function" == typeof t.map) 1596 return t.map(e); 1597 for (var i = [], n = t.length, s = 0; s < n; s++) 1598 i.push(e(t[s])); 1599 return i 1600 }, 1601 getCachedRegex: function(t, e) { 1602 var i = a[this.otag]; 1603 i || (i = a[this.otag] = {}); 1604 var n = i[this.ctag]; 1605 return n || (n = i[this.ctag] = {}), 1606 (i = n[t]) || (i = n[t] = e(this.otag, this.ctag)), 1607 i 1608 } 1609 }, 1610 s = { 1611 name: "mustache.js", 1612 version: "0.4.0", 1613 to_html: function(t, e, i, n) { 1614 var s = new l; 1615 if (n && (s.send = n), 1616 s.render(t, e || {}, i), 1617 !n) 1618 return s.buffer.join("\n") 1619 } 1620 }, 1621 function() { 1622 function o(t) { 1623 return "".trim ? t.trim() : t.replace(/^\s+/, "").replace(/\s+$/, "") 1624 } 1625 var r = { 1626 VERSION: "0.10.2", 1627 templates: {}, 1628 $: "undefined" != typeof window && (window.jQuery || window.Zepto) || null, 1629 addTemplate: function(n, t) { 1630 if ("object" == typeof n) 1631 for (var e in n) 1632 this.addTemplate(e, n[e]); 1633 else 1634 r[n] ? console.error("Invalid name: " + n + ".") : r.templates[n] ? console.error('Template "' + n + ' " exists') : (r.templates[n] = t, 1635 r[n] = function(t, e) { 1636 t = t || {}; 1637 var i = s.to_html(r.templates[n], t, r.templates); 1638 return r.$ && !e ? r.$(o(i)) : i 1639 } 1640 ) 1641 }, 1642 clearAll: function() { 1643 for (var t in r.templates) 1644 delete r[t]; 1645 r.templates = {} 1646 }, 1647 refresh: function() { 1648 r.clearAll(), 1649 r.grabTemplates() 1650 }, 1651 grabTemplates: function() { 1652 var t, e, i, n = document.getElementsByTagName("script"), s = []; 1653 for (t = 0, 1654 e = n.length; t < e; t++) 1655 (i = n[t]) && i.innerHTML && i.id && ("text/html" === i.type || "text/x-icanhaz" === i.type) && (r.addTemplate(i.id, o(i.innerHTML)), 1656 s.unshift(i)); 1657 for (t = 0, 1658 e = s.length; t < e; t++) 1659 s[t].parentNode.removeChild(s[t]) 1660 } 1661 }; 1662 "undefined" != typeof exports ? ("undefined" != typeof module && module.exports && (exports = module.exports = r), 1663 exports.ich = r) : this.ich = r, 1664 "undefined" != typeof document && (r.$ ? r.$(function() { 1665 r.grabTemplates() 1666 }) : document.addEventListener("DOMContentLoaded", function() { 1667 r.grabTemplates() 1668 }, !0)) 1669 }() 1670}(), 1671jQuery.easing.jswing = jQuery.easing.swing, 1672jQuery.extend(jQuery.easing, { 1673 def: "easeOutQuad", 1674 swing: function(t, e, i, n, s) { 1675 return jQuery.easing[jQuery.easing.def](t, e, i, n, s) 1676 }, 1677 easeInQuad: function(t, e, i, n, s) { 1678 return n * (e /= s) * e + i 1679 }, 1680 easeOutQuad: function(t, e, i, n, s) { 1681 return -n * (e /= s) * (e - 2) + i 1682 }, 1683 easeInOutQuad: function(t, e, i, n, s) { 1684 return (e /= s / 2) < 1 ? n / 2 * e * e + i : -n / 2 * (--e * (e - 2) - 1) + i 1685 }, 1686 easeInCubic: function(t, e, i, n, s) { 1687 return n * (e /= s) * e * e + i 1688 }, 1689 easeOutCubic: function(t, e, i, n, s) { 1690 return n * ((e = e / s - 1) * e * e + 1) + i 1691 }, 1692 easeInOutCubic: function(t, e, i, n, s) { 1693 return (e /= s / 2) < 1 ? n / 2 * e * e * e + i : n / 2 * ((e -= 2) * e * e + 2) + i 1694 }, 1695 easeInQuart: function(t, e, i, n, s) { 1696 return n * (e /= s) * e * e * e + i 1697 }, 1698 easeOutQuart: function(t, e, i, n, s) { 1699 return -n * ((e = e / s - 1) * e * e * e - 1) + i 1700 }, 1701 easeInOutQuart: function(t, e, i, n, s) { 1702 return (e /= s / 2) < 1 ? n / 2 * e * e * e * e + i : -n / 2 * ((e -= 2) * e * e * e - 2) + i 1703 }, 1704 easeInQuint: function(t, e, i, n, s) { 1705 return n * (e /= s) * e * e * e * e + i 1706 }, 1707 easeOutQuint: function(t, e, i, n, s) { 1708 return n * ((e = e / s - 1) * e * e * e * e + 1) + i 1709 }, 1710 easeInOutQuint: function(t, e, i, n, s) { 1711 return (e /= s / 2) < 1 ? n / 2 * e * e * e * e * e + i : n / 2 * ((e -= 2) * e * e * e * e + 2) + i 1712 }, 1713 easeInSine: function(t, e, i, n, s) { 1714 return -n * Math.cos(e / s * (Math.PI / 2)) + n + i 1715 }, 1716 easeOutSine: function(t, e, i, n, s) { 1717 return n * Math.sin(e / s * (Math.PI / 2)) + i 1718 }, 1719 easeInOutSine: function(t, e, i, n, s) { 1720 return -n / 2 * (Math.cos(Math.PI * e / s) - 1) + i 1721 }, 1722 easeInExpo: function(t, e, i, n, s) { 1723 return 0 == e ? i : n * Math.pow(2, 10 * (e / s - 1)) + i 1724 }, 1725 easeOutExpo: function(t, e, i, n, s) { 1726 return e == s ? i + n : n * (1 - Math.pow(2, -10 * e / s)) + i 1727 }, 1728 easeInOutExpo: function(t, e, i, n, s) { 1729 return 0 == e ? i : e == s ? i + n : (e /= s / 2) < 1 ? n / 2 * Math.pow(2, 10 * (e - 1)) + i : n / 2 * (2 - Math.pow(2, -10 * --e)) + i 1730 }, 1731 easeInCirc: function(t, e, i, n, s) { 1732 return -n * (Math.sqrt(1 - (e /= s) * e) - 1) + i 1733 }, 1734 easeOutCirc: function(t, e, i, n, s) { 1735 return n * Math.sqrt(1 - (e = e / s - 1) * e) + i 1736 }, 1737 easeInOutCirc: function(t, e, i, n, s) { 1738 return (e /= s / 2) < 1 ? -n / 2 * (Math.sqrt(1 - e * e) - 1) + i : n / 2 * (Math.sqrt(1 - (e -= 2) * e) + 1) + i 1739 }, 1740 easeInElastic: function(t, e, i, n, s) { 1741 var o = 1.70158 1742 , r = 0 1743 , a = n; 1744 if (0 == e) 1745 return i; 1746 if (1 == (e /= s)) 1747 return i + n; 1748 if (r || (r = .3 * s), 1749 a < Math.abs(n)) { 1750 a = n; 1751 o = r / 4 1752 } else 1753 o = r / (2 * Math.PI) * Math.asin(n / a); 1754 return -a * Math.pow(2, 10 * (e -= 1)) * Math.sin((e * s - o) * (2 * Math.PI) / r) + i 1755 }, 1756 easeOutElastic: function(t, e, i, n, s) { 1757 var o = 1.70158 1758 , r = 0 1759 , a = n; 1760 if (0 == e) 1761 return i; 1762 if (1 == (e /= s)) 1763 return i + n; 1764 if (r || (r = .3 * s), 1765 a < Math.abs(n)) { 1766 a = n; 1767 o = r / 4 1768 } else 1769 o = r / (2 * Math.PI) * Math.asin(n / a); 1770 return a * Math.pow(2, -10 * e) * Math.sin((e * s - o) * (2 * Math.PI) / r) + n + i 1771 }, 1772 easeInOutElastic: function(t, e, i, n, s) { 1773 var o = 1.70158 1774 , r = 0 1775 , a = n; 1776 if (0 == e) 1777 return i; 1778 if (2 == (e /= s / 2)) 1779 return i + n; 1780 if (r || (r = s * (.3 * 1.5)), 1781 a < Math.abs(n)) { 1782 a = n; 1783 o = r / 4 1784 } else 1785 o = r / (2 * Math.PI) * Math.asin(n / a); 1786 return e < 1 ? a * Math.pow(2, 10 * (e -= 1)) * Math.sin((e * s - o) * (2 * Math.PI) / r) * -.5 + i : a * Math.pow(2, -10 * (e -= 1)) * Math.sin((e * s - o) * (2 * Math.PI) / r) * .5 + n + i 1787 }, 1788 easeInBack: function(t, e, i, n, s, o) { 1789 return null == o && (o = 1.70158), 1790 n * (e /= s) * e * ((o + 1) * e - o) + i 1791 }, 1792 easeOutBack: function(t, e, i, n, s, o) { 1793 return null == o && (o = 1.70158), 1794 n * ((e = e / s - 1) * e * ((o + 1) * e + o) + 1) + i 1795 }, 1796 easeInOutBack: function(t, e, i, n, s, o) { 1797 return null == o && (o = 1.70158), 1798 (e /= s / 2) < 1 ? n / 2 * (e * e * ((1 + (o *= 1.525)) * e - o)) + i : n / 2 * ((e -= 2) * e * ((1 + (o *= 1.525)) * e + o) + 2) + i 1799 }, 1800 easeInBounce: function(t, e, i, n, s) { 1801 return n - jQuery.easing.easeOutBounce(t, s - e, 0, n, s) + i 1802 }, 1803 easeOutBounce: function(t, e, i, n, s) { 1804 return (e /= s) < 1 / 2.75 ? n * (7.5625 * e * e) + i : e < 2 / 2.75 ? n * (7.5625 * (e -= 1.5 / 2.75) * e + .75) + i : e < 2.5 / 2.75 ? n * (7.5625 * (e -= 2.25 / 2.75) * e + .9375) + i : n * (7.5625 * (e -= 2.625 / 2.75) * e + .984375) + i 1805 }, 1806 easeInOutBounce: function(t, e, i, n, s) { 1807 return e < s / 2 ? .5 * jQuery.easing.easeInBounce(t, 2 * e, 0, n, s) + i : .5 * jQuery.easing.easeOutBounce(t, 2 * e - s, 0, n, s) + .5 * n + i 1808 } 1809}), 1810jQuery.extend(jQuery.easing, { 1811 easeIn: function(t, e, i, n, s) { 1812 return jQuery.easing.easeInQuad(t, e, i, n, s) 1813 }, 1814 easeOut: function(t, e, i, n, s) { 1815 return jQuery.easing.easeOutQuad(t, e, i, n, s) 1816 }, 1817 easeInOut: function(t, e, i, n, s) { 1818 return jQuery.easing.easeInOutQuad(t, e, i, n, s) 1819 }, 1820 expoin: function(t, e, i, n, s) { 1821 return jQuery.easing.easeInExpo(t, e, i, n, s) 1822 }, 1823 expoout: function(t, e, i, n, s) { 1824 return jQuery.easing.easeOutExpo(t, e, i, n, s) 1825 }, 1826 expoinout: function(t, e, i, n, s) { 1827 return jQuery.easing.easeInOutExpo(t, e, i, n, s) 1828 }, 1829 bouncein: function(t, e, i, n, s) { 1830 return jQuery.easing.easeInBounce(t, e, i, n, s) 1831 }, 1832 bounceout: function(t, e, i, n, s) { 1833 return jQuery.easing.easeOutBounce(t, e, i, n, s) 1834 }, 1835 bounceinout: function(t, e, i, n, s) { 1836 return jQuery.easing.easeInOutBounce(t, e, i, n, s) 1837 }, 1838 elasin: function(t, e, i, n, s) { 1839 return jQuery.easing.easeInElastic(t, e, i, n, s) 1840 }, 1841 elasout: function(t, e, i, n, s) { 1842 return jQuery.easing.easeOutElastic(t, e, i, n, s) 1843 }, 1844 elasinout: function(t, e, i, n, s) { 1845 return jQuery.easing.easeInOutElastic(t, e, i, n, s) 1846 }, 1847 backin: function(t, e, i, n, s) { 1848 return jQuery.easing.easeInBack(t, e, i, n, s) 1849 }, 1850 backout: function(t, e, i, n, s) { 1851 return jQuery.easing.easeOutBack(t, e, i, n, s) 1852 }, 1853 backinout: function(t, e, i, n, s) { 1854 return jQuery.easing.easeInOutBack(t, e, i, n, s) 1855 } 1856}), 1857function(r) { 1858 function e(t) { 1859 var e = t || window.event 1860 , i = [].slice.call(arguments, 1) 1861 , n = 0 1862 , s = 0 1863 , o = 0; 1864 return (t = r.event.fix(e)).type = "mousewheel", 1865 e.wheelDelta && (n = e.wheelDelta / 120), 1866 e.detail && (n = -e.detail / 3), 1867 o = n, 1868 void 0 !== e.axis && e.axis === e.HORIZONTAL_AXIS && (o = 0,
1869 s = -1 * n), 1870 void 0 !== e.wheelDeltaY && (o = e.wheelDeltaY / 120), 1871 void 0 !== e.wheelDeltaX && (s = -1 * e.wheelDeltaX / 120), 1872 i.unshift(t, n, s, o), 1873 (r.event.dispatch || r.event.handle).apply(this, i) 1874 } 1875 var i = ["DOMMouseScroll", "mousewheel"]; 1876 if (r.event.fixHooks) 1877 for (var t = i.length; t; ) 1878 r.event.fixHooks[i[--t]] = r.event.mouseHooks; 1879 r.event.special.mousewheel = { 1880 setup: function() { 1881 if (this.addEventListener) 1882 for (var t = i.length; t; ) 1883 this.addEventListener(i[--t], e, !1); 1884 else 1885 this.onmousewheel = e 1886 }, 1887 teardown: function() { 1888 if (this.removeEventListener) 1889 for (var t = i.length; t; ) 1890 this.removeEventListener(i[--t], e, !1); 1891 else 1892 this.onmousewheel = null 1893 } 1894 }, 1895 r.fn.extend({ 1896 mousewheel: function(t) { 1897 return t ? this.bind("mousewheel", t) : this.trigger("mousewheel") 1898 }, 1899 unmousewheel: function(t) { 1900 return this.unbind("mousewheel", t) 1901 } 1902 }) 1903}(jQuery), 1904jQuery.fn.extend({ 1905 bgVideo: function() { 1906 return this.each(function(t) { 1907 var e = jQuery(this) 1908 , i = { 1909 videomp4: e.data("videomp4"), 1910 videowebm: e.data("videowebm"), 1911 videooga: e.data("videooga"), 1912 videowidth: e.data("videowidth"), 1913 videoheight: e.data("videoheight"), 1914 videoposter: e.data("videoposter"), 1915 videoparallax: e.data("videoparallax"), 1916 videooverlaycolor: e.data("videooverlaycolor"), 1917 videooverlayopacity: e.data("videooverlayopacity"), 1918 videosound: e.data("sound") 1919 }; 1920 e.css({ 1921 overflow: "hidden" 1922 }); 1923 var n = ""; 1924 i.videooverlaycolor && (overlay = '<div class="vid-overlay" style="position:absolute;width:100%;height:100%;top:0;left:0;background:' + i.videooverlaycolor + ';z-index:-2;-webkit-backface-visibility: hidden;-webkit-transform: translateZ(0);" ></div>', 1925 e.prepend(overlay)), 1926 n += '<div class="vid-bg" style="position:absolute;width:100%;height:100%;top:0;left:0;z-index:-10;background: url(' + i.videoposter + ') center center; background-size: cover;">', 1927 1024 < jQuery(window).width() && (n += '<video id="video' + t + '" preload="auto" autoplay="autoplay" loop="loop"', 1928 i.videosound || (n += ' muted="muted" '), 1929 i.videoposter && (n += ' poster="' + i.videoposter + '" '), 1930 n += 'style="display:none;top:0;left:0;position: relative;z-index:-11;width:100%;height:100%;">', 1931 n += '<source src="' + i.videomp4 + '" type="video/mp4" />', 1932 n += '<source src="' + i.videowebm + '" type="video/webm" />', 1933 n += '<source src="' + i.videooga + '" type="video/ogg" />', 1934 n += "bgvideo</video>", 1935 n += "</div>", 1936 i.videosound && (n += '<a href="#" class="mute-video" style="position: absolute;z-index:50; bottom:20px;left:50%;margin-left: -10px;color:#ffffff;display:block;width: 20px;height: 20px;"><i class="fa fa-volume-up fa-fw"></i></a>')), 1937 e.append(n), 1938 e.find(".vid-overlay").css({ 1939 opacity: i.videooverlayopacity 1940 }), 1941 e.find(".vid-bg video").fadeIn(1e3), 1942 1024 < jQuery(window).width() && (setProportion(e, i.videowidth, i.videoheight, i.videoparallax), 1943 jQuery(window).resize(function() { 1944 setProportion(e, i.videowidth, i.videoheight, i.videoparallax), 1945 parallaxVideo(e) 1946 })), 1947 i.videoparallax && (parallaxVideo(e), 1948 jQuery(window).scroll(function() { 1949 parallaxVideo(e) 1950 })) 1951 }) 1952 } 1953}), 1954jQuery("body").on("click", ".mute-video", function() { 1955 var t = jQuery(this).siblings(".vid-bg").find("video").attr("id") 1956 , e = document.getElementById(t); 1957 return 0 == e.muted ? (e.muted = !0, 1958 jQuery(this).find("i").removeClass("fa-volume-up"), 1959 jQuery(this).find("i").addClass("fa-volume-off")) : (e.muted = !1, 1960 jQuery(this).find("i").removeClass("fa-volume-off"), 1961 jQuery(this).find("i").addClass("fa-volume-up")), 1962 !1 1963}), 1964jQuery.fn.extend({ 1965 count: function(e, i, n, t) { 1966 var s, o = this; 1967 0 < e - i && (n = -1), 1968 e -= n, 1969 s = setInterval(function() { 1970 var t = e += n; 1971 o.text(t),
1972 (n < 0 && e <= i || 0 < n && i <= e) && (o.text(i), 1973 clearInterval(s)) 1974 }, t || 80) 1975 } 1976}), 1977jQuery(window).load(function() { 1978 jQuery("body").on("click", ".easy-opener", function() { 1979 var t = jQuery(this) 1980 , e = jQuery(window).width() 1981 , i = jQuery(window).height() 1982 , n = Math.ceil(.6 * e) 1983 , s = Math.ceil(.8 * i); 1984 e < 760 && (n = 300); 1985 var o = jQuery(this).data("type"); 1986 o || (o = "image"); 1987 var r = jQuery(this).data("direction") 1988 , a = jQuery(this).data("gallery"); 1989 if (r ? jQuery(".easy-opener-content").animate({ 1990 opacity: 0 1991 }, 500, function() {}) : createOpener(), 1992 "video" == o) { 1993 var l = jQuery(this).data("width") 1994 , c = jQuery(this).data("height") 1995 , u = jQuery(this).attr("href"); 1996 if (!l || !c) 1997 return alert("Please enter a data-width AND data-height"), 1998 !1; 1999 createVideo(n, s, l, c, u) 2000 } else if ("image" == o) { 2001 createImage(n, s, jQuery(this).attr("href")) 2002 } 2003 return a && createNextPrev(a, t, r), 2004 !1 2005 }), 2006 jQuery("body").on("click", ".easy-opener-close", function() { 2007 return jQuery("#easy-opener-section").fadeOut(500, function() { 2008 jQuery(".easy-opener-content").html("").animate({ 2009 opacity: 0 2010 }, 50, function() { 2011 jQuery("#easy-opener-section").remove() 2012 }) 2013 }), 2014 !1 2015 }) 2016}), 2017function(s) { 2018 "use strict"; 2019 s.fn.fitVids = function(t) { 2020 var i = { 2021 customSelector: null, 2022 ignore: null 2023 }; 2024 if (!document.getElementById("fit-vids-style")) { 2025 var e = document.head || document.getElementsByTagName("head")[0] 2026 , n = document.createElement("div"); 2027 n.innerHTML = '<p>x</p><style id="fit-vids-style">.fluid-width-video-wrapper{width:100%;position:relative;padding:0;}.fluid-width-video-wrapper iframe,.fluid-width-video-wrapper object,.fluid-width-video-wrapper embed {position:absolute;top:0;left:0;width:100%;height:100%;}</style>', 2028 e.appendChild(n.childNodes[1]) 2029 } 2030 return t && s.extend(i, t), 2031 this.each(function() { 2032 var t = ['iframe[src*="player.vimeo.com"]', 'iframe[src*="youtube.com"]', 'iframe[src*="youtube-nocookie.com"]', 'iframe[src*="kickstarter.com"][src*="video.html"]', "object", "embed"]; 2033 i.customSelector && t.push(i.customSelector); 2034 var n = ".fitvidsignore"; 2035 i.ignore && (n = n + ", " + i.ignore); 2036 var e = s(this).find(t.join(",")); 2037 (e = (e = e.not("object object")).not(n)).each(function() { 2038 var t = s(this); 2039 if (!(0 < t.parents(n).length || "embed" === this.tagName.toLowerCase() && t.parent("object").length || t.parent(".fluid-width-video-wrapper").length)) { 2040 t.css("height") || t.css("width") || !isNaN(t.attr("height")) && !isNaN(t.attr("width")) || (t.attr("height", 9), 2041 t.attr("width", 16)); 2042 var e = ("object" === this.tagName.toLowerCase() || t.attr("height") && !isNaN(parseInt(t.attr("height"), 10)) ? parseInt(t.attr("height"), 10) : t.height()) / (isNaN(parseInt(t.attr("width"), 10)) ? t.width() : parseInt(t.attr("width"), 10)); 2043 if (!t.attr("name")) { 2044 var i = "fitvid" + s.fn.fitVids._count; 2045 t.attr("name", i), 2046 s.fn.fitVids._count++ 2047 } 2048 t.wrap('<div class="fluid-width-video-wrapper"></div>').parent(".fluid-width-video-wrapper").css("padding-top", 100 * e + "%"), 2049 t.removeAttr("height").removeAttr("width") 2050 } 2051 }) 2052 }) 2053 } 2054 , 2055 s.fn.fitVids._count = 0 2056}(window.jQuery || window.Zepto), 2057function(x) { 2058 x.flexslider = function(p, t) { 2059 var f = x(p); 2060 f.vars = x.extend({}, x.flexslider.defaults, t); 2061 var e, u = f.vars.namespace, g = window.navigator && window.navigator.msPointerEnabled && window.MSGesture, h = ("ontouchstart"in window || g || window.DocumentTouch && document instanceof DocumentTouch) && f.vars.touch, r = "click touchend MSPointerUp", a = "", m = "vertical" === f.vars.direction, v = f.vars.reverse, y = 0 < f.vars.itemWidth, b = "fade" === f.vars.animation, d = "" !== f.vars.asNavFor, w = {}; 2062 x.data(p, "flexslider", f), 2063 w = { 2064 init: function() { 2065 f.animating = !1, 2066 f.currentSlide = parseInt(f.vars.startAt ? f.vars.startAt : 0), 2067 isNaN(f.currentSlide) && (f.currentSlide = 0), 2068 f.animatingTo = f.currentSlide, 2069 f.atEnd = 0 === f.currentSlide || f.currentSlide === f.last, 2070 f.containerSelector = f.vars.selector.substr(0, f.vars.selector.search(" ")), 2071 f.slides = x(f.vars.selector, f), 2072 f.container = x(f.containerSelector, f), 2073 f.count = f.slides.length, 2074 f.syncExists = 0 < x(f.vars.sync).length, 2075 "slide" === f.vars.animation && (f.vars.animation = "swing"), 2076 f.prop = m ? "top" : "marginLeft", 2077 f.args = {}, 2078 f.manualPause = !1, 2079 f.stopped = !1, 2080 f.started = !1, 2081 f.startTimeout = null, 2082 f.transitions = !f.vars.video && !b && f.vars.useCSS && function() { 2083 var t = document.createElement("div") 2084 , e = ["perspectiveProperty", "WebkitPerspective", "MozPerspective", "OPerspective", "msPerspective"]; 2085 for (var i in e) 2086 if (void 0 !== t.style[e[i]]) 2087 return f.pfx = e[i].replace("Perspective", "").toLowerCase(), 2088 f.prop = "-" + f.pfx + "-transform", 2089 !0; 2090 return !1 2091 }(), 2092 "" !== f.vars.controlsContainer && (f.controlsContainer = 0 < x(f.vars.controlsContainer).length && x(f.vars.controlsContainer)), 2093 "" !== f.vars.manualControls && (f.manualControls = 0 < x(f.vars.manualControls).length && x(f.vars.manualControls)), 2094 f.vars.randomize && (f.slides.sort(function() { 2095 return Math.round(Math.random()) - .5 2096 }), 2097 f.container.empty().append(f.slides)), 2098 f.doMath(), 2099 f.setup("init"), 2100 f.vars.controlNav && w.controlNav.setup(), 2101 f.vars.directionNav && w.directionNav.setup(), 2102 f.vars.keyboard && (1 === x(f.containerSelector).length || f.vars.multipleKeyboard) && x(document).bind("keyup", function(t) {
2103 var e = t.keyCode; 2104 if (!f.animating && (39 === e || 37 === e)) { 2105 var i = 39 === e ? f.getTarget("next") : 37 === e && f.getTarget("prev"); 2106 f.flexAnimate(i, f.vars.pauseOnAction) 2107 } 2108 }), 2109 f.vars.mousewheel && f.bind("mousewheel", function(t, e) { 2110 t.preventDefault(); 2111 var i = e < 0 ? f.getTarget("next") : f.getTarget("prev"); 2112 f.flexAnimate(i, f.vars.pauseOnAction) 2113 }), 2114 f.vars.pausePlay && w.pausePlay.setup(), 2115 f.vars.slideshow && f.vars.pauseInvisible && w.pauseInvisible.init(), 2116 f.vars.slideshow && (f.vars.pauseOnHover && f.hover(function() { 2117 f.manualPlay || f.manualPause || f.pause() 2118 }, function() { 2119 f.manualPause || f.manualPlay || f.stopped || f.play() 2120 }), 2121 f.vars.pauseInvisible && w.pauseInvisible.isHidden() || (0 < f.vars.initDelay ? f.startTimeout = setTimeout(f.play, f.vars.initDelay) : f.play())), 2122 d && w.asNav.setup(), 2123 h && f.vars.touch && w.touch(), 2124 (!b || b && f.vars.smoothHeight) && x(window).bind("resize orientationchange focus", w.resize), 2125 f.find("img").attr("draggable", "false"), 2126 setTimeout(function() { 2127 f.vars.start(f) 2128 }, 200) 2129 }, 2130 asNav: { 2131 setup: function() { 2132 f.asNav = !0, 2133 f.animatingTo = Math.floor(f.currentSlide / f.move), 2134 f.currentItem = f.currentSlide, 2135 f.slides.removeClass(u + "active-slide").eq(f.currentItem).addClass(u + "active-slide"), 2136 g ? (p._slider = f).slides.each(function() { 2137 var t = this; 2138 t._gesture = new MSGesture, 2139 (t._gesture.target = t).addEventListener("MSPointerDown", function(t) { 2140 t.preventDefault(), 2141 t.currentTarget._gesture && t.currentTarget._gesture.addPointer(t.pointerId) 2142 }, !1), 2143 t.addEventListener("MSGestureTap", function(t) { 2144 t.preventDefault(); 2145 var e = x(this) 2146 , i = e.index(); 2147 x(f.vars.asNavFor).data("flexslider").animating || e.hasClass("active") || (f.direction = f.currentItem < i ? "next" : "prev", 2148 f.flexAnimate(i, f.vars.pauseOnAction, !1, !0, !0)) 2149 }) 2150 }) : f.slides.click(function(t) { 2151 t.preventDefault(); 2152 var e = x(this) 2153 , i = e.index(); 2154 e.offset().left - x(f).scrollLeft() <= 0 && e.hasClass(u + "active-slide") ? f.flexAnimate(f.getTarget("prev"), !0) : x(f.vars.asNavFor).data("flexslider").animating || e.hasClass(u + "active-slide") || (f.direction = f.currentItem < i ? "next" : "prev", 2155 f.flexAnimate(i, f.vars.pauseOnAction, !1, !0, !0)) 2156 }) 2157 } 2158 }, 2159 controlNav: { 2160 setup: function() { 2161 f.manualControls ? w.controlNav.setupManual() : w.controlNav.setupPaging() 2162 }, 2163 setupPaging: function() { 2164 var t, e, i = "thumbnails" === f.vars.controlNav ? "control-thumbs" : "control-paging", n = 1; 2165 if (f.controlNavScaffold = x('<ol class="' + u + "control-nav " + u + i + '"></ol>'), 2166 1 < f.pagingCount) 2167 for (var s = 0; s < f.pagingCount; s++) { 2168 if (e = f.slides.eq(s), 2169 t = "thumbnails" === f.vars.controlNav ? '<img src="' + e.attr("data-thumb") + '"/>' : "<a><span>" + n + "</span></a>", 2170 "thumbnails" === f.vars.controlNav && !0 === f.vars.thumbCaptions) { 2171 var o = e.attr("data-thumbcaption"); 2172 "" != o && null != o && (t += '<span class="' + u + 'caption">' + o + "</span>") 2173 } 2174 f.controlNavScaffold.append("<li>" + t + "</li>"), 2175 n++ 2176 } 2177 f.controlsContainer ? x(f.controlsContainer).append(f.controlNavScaffold) : f.append(f.controlNavScaffold), 2178 w.controlNav.set(), 2179 w.controlNav.active(), 2180 f.controlNavScaffold.delegate("a, img", r, function(t) { 2181 if (t.preventDefault(), 2182 "" === a || a === t.type) { 2183 var e = x(this) 2184 , i = f.controlNav.index(e); 2185 e.hasClass(u + "active") || (f.direction = i > f.currentSlide ? "next" : "prev", 2186 f.flexAnimate(i, f.vars.pauseOnAction)) 2187 } 2188 "" === a && (a = t.type), 2189 w.setToClearWatchedEvent() 2190 }) 2191 }, 2192 setupManual: function() { 2193 f.controlNav = f.manualControls, 2194 w.controlNav.active(), 2195 f.controlNav.bind(r, function(t) { 2196 if (t.preventDefault(), 2197 "" === a || a === t.type) { 2198 var e = x(this) 2199 , i = f.controlNav.index(e); 2200 e.hasClass(u + "active") || (i > f.currentSlide ? f.direction = "next" : f.direction = "prev", 2201 f.flexAnimate(i, f.vars.pauseOnAction)) 2202 } 2203 "" === a && (a = t.type), 2204 w.setToClearWatchedEvent() 2205 }) 2206 }, 2207 set: function() { 2208 var t = "thumbnails" === f.vars.controlNav ? "img" : "a"; 2209 f.controlNav = x("." + u + "control-nav li " + t, f.controlsContainer ? f.controlsContainer : f) 2210 }, 2211 active: function() { 2212 f.controlNav.removeClass(u + "active").eq(f.animatingTo).addClass(u + "active") 2213 }, 2214 update: function(t, e) { 2215 1 < f.pagingCount && "add" === t ? f.controlNavScaffold.append(x("<li><a>" + f.count + "</a></li>")) : 1 === f.pagingCount ? f.controlNavScaffold.find("li").remove() : f.controlNav.eq(e).closest("li").remove(), 2216 w.controlNav.set(), 2217 1 < f.pagingCount && f.pagingCount !== f.controlNav.length ? f.update(e, t) : w.controlNav.active() 2218 } 2219 }, 2220 directionNav: { 2221 setup: function() { 2222 var t = x('<ul class="' + u + 'direction-nav"><li><a class="' + u + 'prev" href="#">
2222' + f.vars.prevText + '</a></li><li><a class="' + u + 'next" href="#">' + f.vars.nextText + "</a></li></ul>"); 2223 f.controlsContainer ? (x(f.controlsContainer).append(t), 2224 f.directionNav = x("." + u + "direction-nav li a", f.controlsContainer)) : (f.append(t), 2225 f.directionNav = x("." + u + "direction-nav li a", f)), 2226 w.directionNav.update(), 2227 f.directionNav.bind(r, function(t) { 2228 var e; 2229 t.preventDefault(), 2230 "" !== a && a !== t.type || (e = x(this).hasClass(u + "next") ? f.getTarget("next") : f.getTarget("prev"), 2231 f.flexAnimate(e, f.vars.pauseOnAction)), 2232 "" === a && (a = t.type), 2233 w.setToClearWatchedEvent() 2234 }) 2235 }, 2236 update: function() { 2237 var t = u + "disabled"; 2238 1 === f.pagingCount ? f.directionNav.addClass(t).attr("tabindex", "-1") : f.vars.animationLoop ? f.directionNav.removeClass(t).removeAttr("tabindex") : 0 === f.animatingTo ? f.directionNav.removeClass(t).filter("." + u + "prev").addClass(t).attr("tabindex", "-1") : f.animatingTo === f.last ? f.directionNav.removeClass(t).filter("." + u + "next").addClass(t).attr("tabindex", "-1") : f.directionNav.removeClass(t).removeAttr("tabindex") 2239 } 2240 }, 2241 pausePlay: { 2242 setup: function() { 2243 var t = x('<div class="' + u + 'pauseplay"><a></a></div>'); 2244 f.controlsContainer ? (f.controlsContainer.append(t), 2245 f.pausePlay = x("." + u + "pauseplay a", f.controlsContainer)) : (f.append(t), 2246 f.pausePlay = x("." + u + "pauseplay a", f)), 2247 w.pausePlay.update(f.vars.slideshow ? u + "pause" : u + "play"), 2248 f.pausePlay.bind(r, function(t) { 2249 t.preventDefault(), 2250 "" !== a && a !== t.type || (x(this).hasClass(u + "pause") ? (f.manualPause = !0, 2251 f.manualPlay = !1, 2252 f.pause()) : (f.manualPause = !1, 2253 f.manualPlay = !0, 2254 f.play())), 2255 "" === a && (a = t.type), 2256 w.setToClearWatchedEvent() 2257 }) 2258 }, 2259 update: function(t) { 2260 "play" === t ? f.pausePlay.removeClass(u + "pause").addClass(u + "play").html(f.vars.playText) : f.pausePlay.removeClass(u + "play").addClass(u + "pause").html(f.vars.pauseText) 2261 } 2262 }, 2263 touch: function() { 2264 function i(t) { 2265 e = t.touches[0].pageX, 2266 h = t.touches[0].pageY, 2267 l = m ? s - h : s - e; 2268 (!(u = m ? Math.abs(l) < Math.abs(e - o) : Math.abs(l) < Math.abs(h - o)) || 500 < Number(new Date) - c) && (t.preventDefault(), 2269 !b && f.transitions && (f.vars.animationLoop || (l /= 0 === f.currentSlide && l < 0 || f.currentSlide === f.last && 0 < l ? Math.abs(l) / a + 2 : 1), 2270 f.setProps(r + l, "setTouch"))) 2271 } 2272 function n() { 2273 if (p.removeEventListener("touchmove", i, !1), 2274 f.animatingTo === f.currentSlide && !u && null !== l) { 2275 var t = v ? -l : l 2276 , e = 0 < t ? f.getTarget("next") : f.getTarget("prev"); 2277 f.canAdvance(e) && (Number(new Date) - c < 550 && 50 < Math.abs(t) || Math.abs(t) > a / 2) ? f.flexAnimate(e, f.vars.pauseOnAction) : b || f.flexAnimate(f.currentSlide, f.vars.pauseOnAction, !0) 2278 } 2279 p.removeEventListener("touchend", n, !1), 2280 r = l = o = s = null 2281 } 2282 var s, o, r, a, l, c, u = !1, e = 0, h = 0, d = 0; 2283 g ? (p.style.msTouchAction = "none", 2284 p._gesture = new MSGesture, 2285 (p._gesture.target = p).addEventListener("MSPointerDown", function(t) { 2286 t.stopPropagation(), 2287 f.animating ? t.preventDefault() : (f.pause(), 2288 p._gesture.addPointer(t.pointerId), 2289 d = 0, 2290 a = m ? f.h : f.w, 2291 c = Number(new Date), 2292 r = y && v && f.animatingTo === f.last ? 0 : y && v ? f.limit - (f.itemW + f.vars.itemMargin) * f.move * f.animatingTo : y && f.currentSlide === f.last ? f.limit : y ? (f.itemW + f.vars.itemMargin) * f.move * f.currentSlide : v ? (f.last - f.currentSlide + f.cloneOffset) * a : (f.currentSlide + f.cloneOffset) * a) 2293 }, !1), 2294 p._slider = f, 2295 p.addEventListener("MSGestureChange", function(t) { 2296 t.stopPropagation(); 2297 var e = t.target._slider; 2298 if (e) { 2299 var i = -t.translationX 2300 , n = -t.translationY; 2301 l = d += m ? n : i, 2302 u = m ? Math.abs(d) < Math.abs(-i) : Math.abs(d) < Math.abs(-n), 2303 t.detail !== t.MSGESTURE_FLAG_INERTIA ? (!u || 500 < Number(new Date) - c) && (t.preventDefault(), 2304 !b && e.transitions && (e.vars.animationLoop || (l = d / (0 === e.currentSlide && d < 0 || e.currentSlide === e.last && 0 < d ? Math.abs(d) / a + 2 : 1)), 2305 e.setProps(r + l, "setTouch"))) : setImmediate(function() { 2306 p._gesture.stop() 2307 }) 2308 } 2309 }, !1), 2310 p.addEventListener("MSGestureEnd", function(t) { 2311 t.stopPropagation(); 2312 var e = t.target._slider; 2313 if (e) { 2314 if (e.animatingTo === e.currentSlide && !u && null !== l) { 2315 var i = v ? -l : l 2316 , n = 0 < i ? e.getTarget("next") : e.getTarget("prev"); 2317 e.canAdvance(n) && (Number(new Date) - c < 550 && 50 < Math.abs(i) || Math.abs(i) > a / 2) ? e.flexAnimate(n, e.vars.pauseOnAction) : b || e.flexAnimate(e.currentSlide, e.vars.pauseOnAction, !0) 2318 } 2319 r = l = o = s = null, 2320 d = 0 2321 } 2322 }, !1)) : p.addEventListener("touchstart", function(t) { 2323 f.animating ? t.preventDefault() : (window.navigator.msPointerEnabled || 1 === t.touches.length) && (f.pause(), 2324 a = m ? f.h : f.w, 2325 c = Number(new Date), 2326 e = t.touches[0].pageX, 2327 h = t.touches[0].pageY, 2328 r = y && v && f.animatingTo === f.last ? 0 : y && v ? f.limit - (f.itemW + f.vars.itemMargin) * f.move * f.animatingTo : y && f.currentSlide === f.last ? f.limit : y ? (f.itemW + f.vars.itemMargin) * f.move * f.currentSlide : v ? (f.last - f.currentSlide + f.cloneOffset) * a : (f.currentSlide + f.cloneOffset) * a, 2329 s = m ? h : e, 2330 o = m ? e : h, 2331 p.addEventListener("touchmove", i, !1), 2332 p.addEventListener("touchend", n, !1)) 2333 }, !1) 2334 }, 2335 resize: function() { 2336 !f.animating && f.is(":visible") && (y || f.doMath(),
vendor: 10,917 bytes, lines 2337-2599
2337 b ? w.smoothHeight() : y ? (f.slides.width(f.computedW), 2338 f.update(f.pagingCount), 2339 f.setProps()) : m ? (f.viewport.height(f.h), 2340 f.setProps(f.h, "setTotal")) : (f.vars.smoothHeight && w.smoothHeight(), 2341 f.newSlides.width(f.computedW), 2342 f.setProps(f.computedW, "setTotal"))) 2343 }, 2344 smoothHeight: function(t) { 2345 if (!m || b) { 2346 var e = b ? f : f.viewport; 2347 t ? e.animate({ 2348 height: f.slides.eq(f.animatingTo).height() 2349 }, t) : e.height(f.slides.eq(f.animatingTo).height()) 2350 } 2351 }, 2352 sync: function(t) { 2353 var e = x(f.vars.sync).data("flexslider") 2354 , i = f.animatingTo; 2355 switch (t) { 2356 case "animate": 2357 e.flexAnimate(i, f.vars.pauseOnAction, !1, !0); 2358 break; 2359 case "play": 2360 e.playing || e.asNav || e.play(); 2361 break; 2362 case "pause": 2363 e.pause() 2364 } 2365 }, 2366 pauseInvisible: { 2367 visProp: null, 2368 init: function() { 2369 var t = ["webkit", "moz", "ms", "o"]; 2370 if ("hidden"in document) 2371 return "hidden"; 2372 for (var e = 0; e < t.length; e++) 2373 t[e] + "Hidden"in document && (w.pauseInvisible.visProp = t[e] + "Hidden"); 2374 if (w.pauseInvisible.visProp) { 2375 var i = w.pauseInvisible.visProp.replace(/[H|h]idden/, "") + "visibilitychange"; 2376 document.addEventListener(i, function() { 2377 w.pauseInvisible.isHidden() ? f.startTimeout ? clearTimeout(f.startTimeout) : f.pause() : f.started ? f.play() : 0 < f.vars.initDelay ? setTimeout(f.play, f.vars.initDelay) : f.play() 2378 }) 2379 } 2380 }, 2381 isHidden: function() { 2382 return document[w.pauseInvisible.visProp] || !1 2383 } 2384 }, 2385 setToClearWatchedEvent: function() { 2386 clearTimeout(e), 2387 e = setTimeout(function() { 2388 a = "" 2389 }, 3e3) 2390 } 2391 }, 2392 f.flexAnimate = function(t, e, i, n, s) { 2393 if (f.vars.animationLoop || t === f.currentSlide || (f.direction = t > f.currentSlide ? "next" : "prev"), 2394 d && 1 === f.pagingCount && (f.direction = f.currentItem < t ? "next" : "prev"), 2395 !f.animating && (f.canAdvance(t, s) || i) && f.is(":visible")) { 2396 if (d && n) { 2397 var o = x(f.vars.asNavFor).data("flexslider"); 2398 if (f.atEnd = 0 === t || t === f.count - 1, 2399 o.flexAnimate(t, !0, !1, !0, s), 2400 f.direction = f.currentItem < t ? "next" : "prev", 2401 o.direction = f.direction, 2402 Math.ceil((t + 1) / f.visible) - 1 === f.currentSlide || 0 === t) 2403 return f.currentItem = t, 2404 f.slides.removeClass(u + "active-slide").eq(t).addClass(u + "active-slide"), 2405 !1; 2406 f.currentItem = t, 2407 f.slides.removeClass(u + "active-slide").eq(t).addClass(u + "active-slide"), 2408 t = Math.floor(t / f.visible) 2409 } 2410 if (f.animating = !0, 2411 f.animatingTo = t, 2412 e && f.pause(), 2413 f.vars.before(f), 2414 f.syncExists && !s && w.sync("animate"), 2415 f.vars.controlNav && w.controlNav.active(), 2416 y || f.slides.removeClass(u + "active-slide").eq(t).addClass(u + "active-slide"), 2417 f.atEnd = 0 === t || t === f.last, 2418 f.vars.directionNav && w.directionNav.update(), 2419 t === f.last && (f.vars.end(f), 2420 f.vars.animationLoop || f.pause()), 2421 b) 2422 h ? (f.slides.eq(f.currentSlide).css({ 2423 opacity: 0, 2424 zIndex: 1 2425 }), 2426 f.slides.eq(t).css({ 2427 opacity: 1, 2428 zIndex: 2 2429 }), 2430 f.wrapup(c)) : (f.slides.eq(f.currentSlide).css({ 2431 zIndex: 1 2432 }).animate({ 2433 opacity: 0 2434 }, f.vars.animationSpeed, f.vars.easing), 2435 f.slides.eq(t).css({ 2436 zIndex: 2 2437 }).animate({ 2438 opacity: 1 2439 }, f.vars.animationSpeed, f.vars.easing, f.wrapup)); 2440 else { 2441 var r, a, l, c = m ? f.slides.filter(":first").height() : f.computedW; 2442 y ? (r = f.vars.itemMargin, 2443 a = (l = (f.itemW + r) * f.move * f.animatingTo) > f.limit && 1 !== f.visible ? f.limit : l) : a = 0 === f.currentSlide && t === f.count - 1 && f.vars.animationLoop && "next" !== f.direction ? v ? (f.count + f.cloneOffset) * c : 0 : f.currentSlide === f.last && 0 === t && f.vars.animationLoop && "prev" !== f.direction ? v ? 0 : (f.count + 1) * c : v ? (f.count - 1 - t + f.cloneOffset) * c : (t + f.cloneOffset) * c, 2444 f.setProps(a, "", f.vars.animationSpeed), 2445 f.transitions ? (f.vars.animationLoop && f.atEnd || (f.animating = !1, 2446 f.currentSlide = f.animatingTo), 2447 f.container.unbind("webkitTransitionEnd transitionend"), 2448 f.container.bind("webkitTransitionEnd transitionend", function() { 2449 f.wrapup(c) 2450 })) : f.container.animate(f.args, f.vars.animationSpeed, f.vars.easing, function() { 2451 f.wrapup(c) 2452 }) 2453 } 2454 f.vars.smoothHeight && w.smoothHeight(f.vars.animationSpeed) 2455 } 2456 } 2457 , 2458 f.wrapup = function(t) { 2459 b || y || (0 === f.currentSlide && f.animatingTo === f.last && f.vars.animationLoop ? f.setProps(t, "jumpEnd") : f.currentSlide === f.last && 0 === f.animatingTo && f.vars.animationLoop && f.setProps(t, "jumpStart")), 2460 f.animating = !1, 2461 f.currentSlide = f.animatingTo, 2462 f.vars.after(f) 2463 } 2464 , 2465 f.animateSlides = function() { 2466 f.animating || f.flexAnimate(f.getTarget("next")) 2467 } 2468 , 2469 f.pause = function() { 2470 clearInterval(f.animatedSlides), 2471 f.animatedSlides = null, 2472 f.playing = !1, 2473 f.vars.pausePlay && w.pausePlay.update("play"), 2474 f.syncExists && w.sync("pause") 2475 } 2476 , 2477 f.play = function() { 2478 f.playing && clearInterval(f.animatedSlides), 2479 f.animatedSlides = f.animatedSlides || setInterval(f.animateSlides, f.vars.slideshowSpeed), 2480 f.started = f.playing = !0, 2481 f.vars.pausePlay && w.pausePlay.update("pause"), 2482 f.syncExists && w.sync("play") 2483 } 2484 , 2485 f.stop = function() { 2486 f.pause(), 2487 f.stopped = !0 2488 } 2489 , 2490 f.canAdvance = function(t, e) { 2491 var i = d ? f.pagingCount - 1 : f.last; 2492 return !!e || (!(!d || f.currentItem !== f.count - 1 || 0 !== t || "prev" !== f.direction) || (!d || 0 !== f.currentItem || t !== f.pagingCount - 1 || "next" === f.direction) && (!(t === f.currentSlide && !d) && (!!f.vars.animationLoop || (!f.atEnd || 0 !== f.currentSlide || t !== i || "next" === f.direction) && (!f.atEnd || f.currentSlide !== i || 0 !== t || "next" !== f.direction)))) 2493 } 2494 , 2495 f.getTarget = function(t) { 2496 return "next" === (f.direction = t) ? f.currentSlide === f.last ? 0 : f.currentSlide + 1 : 0 === f.currentSlide ? f.last : f.currentSlide - 1 2497 } 2498 , 2499 f.setProps = function(t, e, i) { 2500 var n, s = (n = t || (f.itemW + f.vars.itemMargin) * f.move * f.animatingTo, 2501 -1 * function() { 2502 if (y) 2503 return "setTouch" === e ? t : v && f.animatingTo === f.last ? 0 : v ? f.limit - (f.itemW + f.vars.itemMargin) * f.move * f.animatingTo : f.animatingTo === f.last ? f.limit : n; 2504 switch (e) { 2505 case "setTotal": 2506 return v ? (f.count - 1 - f.currentSlide + f.cloneOffset) * t : (f.currentSlide + f.cloneOffset) * t; 2507 case "setTouch": 2508 return t; 2509 case "jumpEnd": 2510 return v ? t : f.count * t; 2511 case "jumpStart": 2512 return v ? f.count * t : t; 2513 default: 2514 return t 2515 } 2516 }() + "px"); 2517 f.transitions && (s = m ? "translate3d(0," + s + ",0)" : "translate3d(" + s + ",0,0)", 2518 i = void 0 !== i ? i / 1e3 + "s" : "0s", 2519 f.container.css("-" + f.pfx + "-transition-duration", i)), 2520 f.args[f.prop] = s, 2521 (f.transitions || void 0 === i) && f.container.css(f.args) 2522 } 2523 , 2524 f.setup = function(t) { 2525 var e, i; 2526 b ? (f.slides.css({ 2527 width: "100%", 2528 float: "left", 2529 marginRight: "-100%", 2530 position: "relative" 2531 }), 2532 "init" === t && (h ? f.slides.css({ 2533 opacity: 0, 2534 display: "block", 2535 webkitTransition: "opacity " + f.vars.animationSpeed / 1e3 + "s ease", 2536 zIndex: 1 2537 }).eq(f.currentSlide).css({ 2538 opacity: 1, 2539 zIndex: 2 2540 }) : f.slides.css({ 2541 opacity: 0, 2542 display: "block", 2543 zIndex: 1 2544 }).eq(f.currentSlide).css({ 2545 zIndex: 2 2546 }).animate({ 2547 opacity: 1 2548 }, f.vars.animationSpeed, f.vars.easing)), 2549 f.vars.smoothHeight && w.smoothHeight()) : ("init" === t && (f.viewport = x('<div class="' + u + 'viewport"></div>').css({ 2550 overflow: "hidden", 2551 position: "relative" 2552 }).appendTo(f).append(f.container), 2553 f.cloneCount = 0, 2554 f.cloneOffset = 0, 2555 v && (i = x.makeArray(f.slides).reverse(), 2556 f.slides = x(i), 2557 f.container.empty().append(f.slides))), 2558 f.vars.animationLoop && !y && (f.cloneCount = 2, 2559 f.cloneOffset = 1, 2560 "init" !== t && f.container.find(".clone").remove(), 2561 f.container.append(f.slides.first().clone().addClass("clone").attr("aria-hidden", "true")).prepend(f.slides.last().clone().addClass("clone").attr("aria-hidden", "true"))), 2562 f.newSlides = x(f.vars.selector, f), 2563 e = v ? f.count - 1 - f.currentSlide + f.cloneOffset : f.currentSlide + f.cloneOffset, 2564 m && !y ? (f.container.height(200 * (f.count + f.cloneCount) + "%").css("position", "absolute").width("100%"), 2565 setTimeout(function() { 2566 f.newSlides.css({ 2567 display: "block" 2568 }), 2569 f.doMath(), 2570 f.viewport.height(f.h), 2571 f.setProps(e * f.h, "init") 2572 }, "init" === t ? 100 : 0)) : (f.container.width(200 * (f.count + f.cloneCount) + "%"), 2573 f.setProps(e * f.computedW, "init"), 2574 setTimeout(function() { 2575 f.doMath(), 2576 f.newSlides.css({ 2577 width: f.computedW, 2578 float: "left", 2579 display: "block" 2580 }), 2581 f.vars.smoothHeight && w.smoothHeight() 2582 }, "init" === t ? 100 : 0))); 2583 y || f.slides.removeClass(u + "active-slide").eq(f.currentSlide).addClass(u + "active-slide") 2584 } 2585 , 2586 f.doMath = function() { 2587 var t = f.slides.first() 2588 , e = f.vars.itemMargin 2589 , i = f.vars.minItems 2590 , n = f.vars.maxItems; 2591 f.w = void 0 === f.viewport ? f.width() : f.viewport.width(), 2592 f.h = t.height(), 2593 f.boxPadding = t.outerWidth() - t.width(), 2594 y ? (f.itemT = f.vars.itemWidth + e, 2595 f.minW = i ? i * f.itemT : f.w, 2596 f.maxW = n ? n * f.itemT - e : f.w, 2597 f.itemW = f.minW > f.w ? (f.w - e * (i - 1)) / i : f.maxW < f.w ? (f.w - e * (n - 1)) / n : f.vars.itemWidth > f.w ? f.w : f.vars.itemWidth, 2598 f.visible = Math.floor(f.w / f.itemW), 2599 f.move = 0 < f.vars.move && f.vars.move < f.visible ? f.vars.move : f.visible,
2600 f.pagingCount = Math.ceil((f.count - f.visible) / f.move + 1), 2601 f.last = f.pagingCount - 1, 2602 f.limit = 1 === f.pagingCount ? 0 : f.vars.itemWidth > f.w ? f.itemW * (f.count - 1) + e * (f.count - 1) : (f.itemW + e) * f.count - f.w - e) : (f.itemW = f.w, 2603 f.pagingCount = f.count, 2604 f.last = f.count - 1), 2605 f.computedW = f.itemW - f.boxPadding 2606 } 2607 , 2608 f.update = function(t, e) { 2609 f.doMath(), 2610 y || (t < f.currentSlide ? f.currentSlide += 1 : t <= f.currentSlide && 0 !== t && (f.currentSlide -= 1), 2611 f.animatingTo = f.currentSlide), 2612 f.vars.controlNav && !f.manualControls && ("add" === e && !y || f.pagingCount > f.controlNav.length ? w.controlNav.update("add") : ("remove" === e && !y || f.pagingCount < f.controlNav.length) && (y && f.currentSlide > f.last && (f.currentSlide -= 1, 2613 f.animatingTo -= 1), 2614 w.controlNav.update("remove", f.last))), 2615 f.vars.directionNav && w.directionNav.update() 2616 } 2617 , 2618 f.addSlide = function(t, e) { 2619 var i = x(t); 2620 f.count += 1, 2621 f.last = f.count - 1, 2622 m && v ? void 0 !== e ? f.slides.eq(f.count - e).after(i) : f.container.prepend(i) : void 0 !== e ? f.slides.eq(e).before(i) : f.container.append(i), 2623 f.update(e, "add"), 2624 f.slides = x(f.vars.selector + ":not(.clone)", f), 2625 f.setup(), 2626 f.vars.added(f) 2627 } 2628 , 2629 f.removeSlide = function(t) { 2630 var e = isNaN(t) ? f.slides.index(x(t)) : t; 2631 f.count -= 1, 2632 f.last = f.count - 1, 2633 isNaN(t) ? x(t, f.slides).remove() : m && v ? f.slides.eq(f.last).remove() : f.slides.eq(t).remove(), 2634 f.doMath(), 2635 f.update(e, "remove"), 2636 f.slides = x(f.vars.selector + ":not(.clone)", f), 2637 f.setup(), 2638 f.vars.removed(f) 2639 } 2640 , 2641 w.init() 2642 } 2643 , 2644 x(window).blur(function() { 2645 focused = !1 2646 }).focus(function() { 2647 focused = !0 2648 }), 2649 x.flexslider.defaults = { 2650 namespace: "flex-", 2651 selector: ".slides > li", 2652 animation: "fade", 2653 easing: "swing", 2654 direction: "horizontal", 2655 reverse: !1, 2656 animationLoop: !0, 2657 smoothHeight: !1, 2658 startAt: 0, 2659 slideshow: !0, 2660 slideshowSpeed: 7e3, 2661 animationSpeed: 600, 2662 initDelay: 0, 2663 randomize: !1, 2664 thumbCaptions: !1, 2665 pauseOnAction: !0, 2666 pauseOnHover: !1, 2667 pauseInvisible: !0, 2668 useCSS: !0, 2669 touch: !0, 2670 video: !1, 2671 controlNav: !0, 2672 directionNav: !0, 2673 prevText: "Previous", 2674 nextText: "Next", 2675 keyboard: !0, 2676 multipleKeyboard: !1, 2677 mousewheel: !1, 2678 pausePlay: !1, 2679 pauseText: "Pause", 2680 playText: "Play", 2681 controlsContainer: "", 2682 manualControls: "", 2683 sync: "", 2684 asNavFor: "", 2685 itemWidth: 0, 2686 itemMargin: 0, 2687 minItems: 1, 2688 maxItems: 0, 2689 move: 0, 2690 allowOneSlide: !0, 2691 start: function() {}, 2692 before: function() {}, 2693 after: function() {}, 2694 end: function() {}, 2695 added: function() {}, 2696 removed: function() {} 2697 }, 2698 x.fn.flexslider = function(n) { 2699 if (void 0 === n && (n = {}), 2700 "object" == typeof n) 2701 return this.each(function() { 2702 var t = x(this) 2703 , e = n.selector ? n.selector : ".slides > li" 2704 , i = t.find(e); 2705 1 === i.length && !0 === n.allowOneSlide || 0 === i.length ? (i.fadeIn(400), 2706 n.start && n.start(t)) : void 0 === t.data("flexslider") && new x.flexslider(this,n) 2707 }); 2708 var t = x(this).data("flexslider"); 2709 switch (n) { 2710 case "play": 2711 t.play(); 2712 break; 2713 case "pause": 2714 t.pause(); 2715 break; 2716 case "stop": 2717 t.stop(); 2718 break; 2719 case "next": 2720 t.flexAnimate(t.getTarget("next"), !0); 2721 break; 2722 case "prev": 2723 case "previous": 2724 t.flexAnimate(t.getTarget("prev"), !0); 2725 break; 2726 default: 2727 "number" == typeof n && t.flexAnimate(n, !0) 2728 } 2729 } 2730}(jQuery), 2731function(a) { 2732 var l = function(t) { 2733 t.data("fliped", !0); 2734 var e = "rotate" + t.data("axis"); 2735 t.find(".front").css({ 2736 transform: e + (t.data("reverse") ? "(-180deg)" : "(180deg)") 2737 }), 2738 t.find(".back").css({ 2739 transform: e + "(0deg)" 2740 }) 2741 } 2742 , c = function(t) { 2743 t.data("fliped", !1); 2744 var e = "rotate" + t.data("axis"); 2745 t.find(".front").css({ 2746 transform: e + "(0deg)" 2747 }), 2748 t.find(".back").css({ 2749 transform: e + (t.data("reverse") ? "(180deg)" : "(-180deg)") 2750 }) 2751 }; 2752 a.fn.flip = function(r) { 2753 return this.each(function() { 2754 var t = a(this); 2755 if (void 0 !== r && "boolean" == typeof r) 2756 r ? l(t) : c(t); 2757 else { 2758 var e = a.extend({ 2759 axis: "y", 2760 reverse: !1, 2761 trigger: "click", 2762 speed: 500 2763 }, r); 2764 if (t.data("reverse", e.reverse), 2765 t.data("axis", e.axis), 2766 "x" == e.axis.toLowerCase()) 2767 var i = 2 * t.outerHeight() 2768 , n = "rotatex"; 2769 else 2770 i = 2 * t.outerWidth(), 2771 n = "rotatey"; 2772 t.find(".back").css({ 2773 transform: n + "(" + (e.reverse ? "180deg" : "-180deg") + ")" 2774 }), 2775 t.css({ 2776 perspective: i, 2777 position: "relative" 2778 }); 2779 var s = e.speed / 1e3 || .5; 2780 if (t.find(".front, .back").outerHeight(t.height()).outerWidth(t.width()).css({ 2781 "transform-style": "preserve-3d", 2782 position: "absolute", 2783 transition: "all " + s + "s ease-out", 2784 "backface-visibility": "hidden" 2785 }), 2786 "click" == e.trigger.toLowerCase()) 2787 t.find('button, a, input[type="submit"]').click(function(t) { 2788 t.stopPropagation() 2789 }), 2790 t.click(function() { 2791 t.data("fliped") ? c(t) : l(t) 2792 }); 2793 else if ("hover" == e.trigger.toLowerCase()) { 2794 var o = function() { 2795 c(t) 2796 }; 2797 t.mouseenter(function() { 2798 t.unbind("mouseleave", o), 2799 l(t), 2800 setTimeout(function() { 2801 t.bind("mouseleave", o), 2802 t.is(":hover") || c(t) 2803 }, e.speed + 150) 2804 }), 2805 t.mouseleave(o) 2806 } 2807 } 2808 }), 2809 this 2810 } 2811}(jQuery), 2812function() { 2813 function t() {} 2814 function o(t, e) { 2815 for (var i = t.length; i--; ) 2816 if (t[i].listener === e) 2817 return i; 2818 return -1 2819 } 2820 function e(t) { 2821 return function() { 2822 return this[t].apply(this, arguments) 2823 } 2824 } 2825 var i = t.prototype 2826 , n = this 2827 , s = n.EventEmitter; 2828 i.getListeners = function(t) { 2829 var e, i, n = this._getEvents(); 2830 if ("object" == typeof t) 2831 for (i in e = {}, 2832 n) 2833 n.hasOwnProperty(i) && t.test(i) && (e[i] = n[i]); 2834 else 2835 e = n[t] || (n[t] = []); 2836 return e 2837 } 2838 , 2839 i.flattenListeners = function(t) { 2840 var e, i = []; 2841 for (e = 0; t.length > e; e += 1) 2842 i.push(t[e].listener); 2843 return i 2844 } 2845 , 2846 i.getListenersAsObject = function(t) { 2847 var e, i = this.getListeners(t); 2848 return i instanceof Array && ((e = {})[t] = i), 2849 e || i 2850 } 2851 , 2852 i.addListener = function(t, e) { 2853 var i, n = this.getListenersAsObject(t), s = "object" == typeof e; 2854 for (i in n) 2855 n.hasOwnProperty(i) && -1 === o(n[i], e) && n[i].push(s ? e : { 2856 listener: e, 2857 once: !1 2858 }); 2859 return this 2860 } 2861 , 2862 i.on = e("addListener"), 2863 i.addOnceListener = function(t, e) { 2864 return this.addListener(t, { 2865 listener: e, 2866 once: !0 2867 }) 2868 } 2869 , 2870 i.once = e("addOnceListener"), 2871 i.defineEvent = function(t) { 2872 return this.getListeners(t), 2873 this 2874 } 2875 , 2876 i.defineEvents = function(t) { 2877 for (var e = 0; t.length > e; e += 1) 2878 this.defineEvent(t[e]); 2879 return this 2880 } 2881 , 2882 i.removeListener = function(t, e) { 2883 var i, n, s = this.getListenersAsObject(t); 2884 for (n in s) 2885 s.hasOwnProperty(n) && (-1 !== (i = o(s[n], e)) && s[n].splice(i, 1)); 2886 return this 2887 } 2888 , 2889 i.off = e("removeListener"), 2890 i.addListeners = function(t, e) { 2891 return this.manipulateListeners(!1, t, e) 2892 } 2893 , 2894 i.removeListeners = function(t, e) { 2895 return this.manipulateListeners(!0, t, e) 2896 } 2897 , 2898 i.manipulateListeners = function(t, e, i) { 2899 var n, s, o = t ? this.removeListener : this.addListener, r = t ? this.removeListeners : this.addListeners; 2900 if ("object" != typeof e || e instanceof RegExp) 2901 for (n = i.length; n--; ) 2902 o.call(this, e, i[n]); 2903 else 2904 for (n in e) 2905 e.hasOwnProperty(n) && (s = e[n]) && ("function" == typeof s ? o.call(this, n, s) : r.call(this, n, s)); 2906 return this 2907 } 2908 , 2909 i.removeEvent = function(t) { 2910 var e, i = typeof t, n = this._getEvents(); 2911 if ("string" === i) 2912 delete n[t]; 2913 else if ("object" === i) 2914 for (e in n) 2915 n.hasOwnProperty(e) && t.test(e) && delete n[e]; 2916 else 2917 delete this._events; 2918 return this 2919 } 2920 , 2921 i.removeAllListeners = e("removeEvent"), 2922 i.emitEvent = function(t, e) { 2923 var i, n, s, o = this.getListenersAsObject(t); 2924 for (s in o) 2925 if (o.hasOwnProperty(s)) 2926 for (n = o[s].length; n--; ) 2927 !0 === (i = o[s][n]).once && this.removeListener(t, i.listener), 2928 i.listener.apply(this, e || []) === this._getOnceReturnValue() && this.removeListener(t, i.listener); 2929 return this 2930 } 2931 , 2932 i.trigger = e("emitEvent"), 2933 i.emit = function(t) { 2934 var e = Array.prototype.slice.call(arguments, 1); 2935 return this.emitEvent(t, e) 2936 } 2937 , 2938 i.setOnceReturnValue = function(t) { 2939 return this._onceReturnValue = t, 2940 this 2941 } 2942 , 2943 i._getOnceReturnValue = function() { 2944 return !this.hasOwnProperty("_onceReturnValue") || this._onceReturnValue 2945 } 2946 , 2947 i._getEvents = function() { 2948 return this._events || (this._events = {}) 2949 } 2950 , 2951 t.noConflict = function() { 2952 return n.EventEmitter = s, 2953 t 2954 } 2955 , 2956 "function" == typeof define && define.amd ? define("eventEmitter/EventEmitter", [], function() { 2957 return t 2958 }) : "object" == typeof module && module.exports ? module.exports = t : this.EventEmitter = t 2959} 2960.call(this), 2961function(i) { 2962 function n(t) { 2963 var e = i.event; 2964 return e.target = e.target || e.srcElement || t, 2965 e 2966 } 2967 var t = document.documentElement 2968 , e = function() {}; 2969 t.addEventListener ? e = function(t, e, i) { 2970 t.addEventListener(e, i, !1) 2971 } 2972 : t.attachEvent && (e = function(e, t, i) { 2973 e[t + i] = i.handleEvent ? function() { 2974 var t = n(e); 2975 i.handleEvent.call(i, t) 2976 } 2977 : function() { 2978 var t = n(e); 2979 i.call(e, t) 2980 } 2981 , 2982 e.attachEvent("on" + t, e[t + i]) 2983 } 2984 ); 2985 var s = function() {}; 2986 t.removeEventListener ? s = function(t, e, i) { 2987 t.removeEventListener(e, i, !1) 2988 } 2989 : t.detachEvent && (s = function(e, i, n) { 2990 e.detachEvent("on" + i, e[i + n]); 2991 try { 2992 delete e[i + n] 2993 } catch (t) { 2994 e[i + n] = void 0 2995 } 2996 } 2997 ); 2998 var o = { 2999 bind: e, 3000 unbind: s 3001 }; 3002 "function" == typeof define && define.amd ? define("eventie/eventie", o) : i.eventie = o 3003}(this), 3004function(i, n) { 3005 "function" == typeof define && define.amd ? define(["eventEmitter/EventEmitter", "eventie/eventie"], function(t, e) { 3006 return n(i, t, e) 3007 }) : "object" == typeof exports ? module.exports = n(i, require("wolfy87-eventemitter"), require("eventie")) : i.imagesLoaded = n(i, i.EventEmitter, i.eventie) 3008}(window, function(t, e, i) { 3009 function s(t, e) { 3010 for (var i in e) 3011 t[i] = e[i]; 3012 return t 3013 } 3014 function o(t) { 3015 var e, i = []; 3016 if (e = t, 3017 "[object Array]" === h.call(e)) 3018 i = t; 3019 else if ("number" == typeof t.length) 3020 for (var n = 0, s = t.length; n < s; n++) 3021 i.push(t[n]); 3022 else 3023 i.push(t); 3024 return i 3025 } 3026 function r(t, e, i) { 3027 if (!(this instanceof r)) 3028 return new r(t,e); 3029 "string" == typeof t && (t = document.querySelectorAll(t)), 3030 this.elements = o(t), 3031 this.options = s({}, this.options), 3032 "function" == typeof e ? i = e : s(this.options, e), 3033 i && this.on("always", i), 3034 this.getImages(), 3035 l && (this.jqDeferred = new l.Deferred); 3036 var n = this; 3037 setTimeout(function() { 3038 n.check() 3039 }) 3040 } 3041 function n(t) { 3042 this.img = t 3043 } 3044 function a(t) { 3045 this.src = t, 3046 d[t] = this 3047 } 3048 var l = t.jQuery 3049 , c = t.console 3050 , u = void 0 !== c 3051 , h = Object.prototype.toString; 3052 r.prototype = new e, 3053 r.prototype.options = {}, 3054 r.prototype.getImages = function() { 3055 this.images = []; 3056 for (var t = 0, e = this.elements.length; t < e; t++) { 3057 var i = this.elements[t]; 3058 "IMG" === i.nodeName && this.addImage(i); 3059 var n = i.nodeType; 3060 if (n && (1 === n || 9 === n || 11 === n)) 3061 for (var s = i.querySelectorAll("img"), o = 0, r = s.length; o < r; o++) { 3062 var a = s[o]; 3063 this.addImage(a) 3064 } 3065 } 3066 } 3067 , 3068 r.prototype.addImage = function(t) { 3069 var e = new n(t); 3070 this.images.push(e) 3071 } 3072 ,
3073 r.prototype.check = function() { 3074 function t(t, e) { 3075 return i.options.debug && u && c.log("confirm", t, e), 3076 i.progress(t), 3077 ++n === s && i.complete(), 3078 !0 3079 } 3080 var i = this 3081 , n = 0 3082 , s = this.images.length; 3083 if (this.hasAnyBroken = !1, 3084 s) 3085 for (var e = 0; e < s; e++) { 3086 var o = this.images[e]; 3087 o.on("confirm", t), 3088 o.check() 3089 } 3090 else 3091 this.complete() 3092 } 3093 , 3094 r.prototype.progress = function(t) { 3095 this.hasAnyBroken = this.hasAnyBroken || !t.isLoaded; 3096 var e = this; 3097 setTimeout(function() { 3098 e.emit("progress", e, t), 3099 e.jqDeferred && e.jqDeferred.notify && e.jqDeferred.notify(e, t) 3100 }) 3101 } 3102 , 3103 r.prototype.complete = function() { 3104 var e = this.hasAnyBroken ? "fail" : "done"; 3105 this.isComplete = !0; 3106 var i = this; 3107 setTimeout(function() { 3108 if (i.emit(e, i), 3109 i.emit("always", i), 3110 i.jqDeferred) { 3111 var t = i.hasAnyBroken ? "reject" : "resolve"; 3112 i.jqDeferred[t](i) 3113 } 3114 }) 3115 } 3116 , 3117 l && (l.fn.imagesLoaded = function(t, e) { 3118 return new r(this,t,e).jqDeferred.promise(l(this)) 3119 } 3120 ), 3121 n.prototype = new e, 3122 n.prototype.check = function() { 3123 var t = d[this.img.src] || new a(this.img.src); 3124 if (t.isConfirmed) 3125 this.confirm(t.isLoaded, "cached was confirmed"); 3126 else if (this.img.complete && void 0 !== this.img.naturalWidth) 3127 this.confirm(0 !== this.img.naturalWidth, "naturalWidth"); 3128 else { 3129 var i = this; 3130 t.on("confirm", function(t, e) { 3131 return i.confirm(t.isLoaded, e), 3132 !0 3133 }), 3134 t.check() 3135 } 3136 } 3137 , 3138 n.prototype.confirm = function(t, e) { 3139 this.isLoaded = t, 3140 this.emit("confirm", this, e) 3141 } 3142 ; 3143 var d = {}; 3144 return a.prototype = new e, 3145 a.prototype.check = function() { 3146 if (!this.isChecked) { 3147 var t = new Image; 3148 i.bind(t, "load", this), 3149 i.bind(t, "error", this), 3150 t.src = this.src, 3151 this.isChecked = !0 3152 } 3153 } 3154 , 3155 a.prototype.handleEvent = function(t) { 3156 var e = "on" + t.type; 3157 this[e] && this[e](t) 3158 } 3159 , 3160 a.prototype.onload = function(t) { 3161 this.confirm(!0, "onload"), 3162 this.unbindProxyEvents(t) 3163 } 3164 , 3165 a.prototype.onerror = function(t) { 3166 this.confirm(!1, "onerror"), 3167 this.unbindProxyEvents(t) 3168 } 3169 , 3170 a.prototype.confirm = function(t, e) { 3171 this.isConfirmed = !0, 3172 this.isLoaded = t, 3173 this.emit("confirm", this, e) 3174 } 3175 , 3176 a.prototype.unbindProxyEvents = function(t) { 3177 i.unbind(t.target, "load", this), 3178 i.unbind(t.target, "error", this) 3179 } 3180 , 3181 r 3182}), 3183function(t) { 3184 function e() {} 3185 function i(c) { 3186 if (c) { 3187 var u = "undefined" == typeof console ? e : function(t) { 3188 console.error(t) 3189 } 3190 ; 3191 return c.bridget = function(t, e) { 3192 var a, l, i; 3193 (i = e).prototype.option || (i.prototype.option = function(t) { 3194 c.isPlainObject(t) && (this.options = c.extend(!0, this.options, t)) 3195 } 3196 ), 3197 a = t, 3198 l = e, 3199 c.fn[a] = function(e) { 3200 if ("string" == typeof e) { 3201 for (var t = h.call(arguments, 1), i = 0, n = this.length; i < n; i++) { 3202 var s = this[i] 3203 , o = c.data(s, a); 3204 if (o) 3205 if (c.isFunction(o[e]) && "_" !== e.charAt(0)) { 3206 var r = o[e].apply(o, t); 3207 if (void 0 !== r) 3208 return r 3209 } else 3210 u("no such method '" + e + "' for " + a + " instance"); 3211 else 3212 u("cannot call methods on " + a + " prior to initialization; attempted to call '" + e + "'") 3213 } 3214 return this 3215 } 3216 return this.each(function() { 3217 var t = c.data(this, a); 3218 t ? (t.option(e), 3219 t._init()) : (t = new l(this,e), 3220 c.data(this, a, t)) 3221 }) 3222 } 3223 } 3224 , 3225 c.bridget 3226 } 3227 } 3228 var h = Array.prototype.slice; 3229 "function" == typeof define && define.amd ? define("jquery-bridget/jquery.bridget", ["jquery"], i) : i("object" == typeof exports ? require("jquery") : t.jQuery) 3230}(window), 3231function(i) { 3232 function n(t) { 3233 var e = i.event; 3234 return e.target = e.target || e.srcElement || t, 3235 e 3236 } 3237 var t = document.documentElement 3238 , e = function() {}; 3239 t.addEventListener ? e = function(t, e, i) { 3240 t.addEventListener(e, i, !1) 3241 } 3242 : t.attachEvent && (e = function(e, t, i) { 3243 e[t + i] = i.handleEvent ? function() { 3244 var t = n(e); 3245 i.handleEvent.call(i, t) 3246 } 3247 : function() { 3248 var t = n(e); 3249 i.call(e, t) 3250 } 3251 , 3252 e.attachEvent("on" + t, e[t + i]) 3253 } 3254 ); 3255 var s = function() {}; 3256 t.removeEventListener ? s = function(t, e, i) { 3257 t.removeEventListener(e, i, !1) 3258 } 3259 : t.detachEvent && (s = function(e, i, n) { 3260 e.detachEvent("on" + i, e[i + n]); 3261 try { 3262 delete e[i + n] 3263 } catch (t) { 3264 e[i + n] = void 0 3265 } 3266 } 3267 ); 3268 var o = { 3269 bind: e, 3270 unbind: s 3271 }; 3272 "function" == typeof define && define.amd ? define("eventie/eventie", o) : "object" == typeof exports ? module.exports = o : i.eventie = o 3273}(window), 3274function() { 3275 "use strict"; 3276 function t() {} 3277 function o(t, e) { 3278 for (var i = t.length; i--; ) 3279 if (t[i].listener === e) 3280 return i; 3281 return -1 3282 } 3283 function e(t) { 3284 return function() { 3285 return this[t].apply(this, arguments) 3286 } 3287 } 3288 var i = t.prototype 3289 , n = this 3290 , s = n.EventEmitter; 3291 i.getListeners = function(t) { 3292 var e, i, n = this._getEvents(); 3293 if (t instanceof RegExp) 3294 for (i in e = {}, 3295 n) 3296 n.hasOwnProperty(i) && t.test(i) && (e[i] = n[i]); 3297 else 3298 e = n[t] || (n[t] = []); 3299 return e 3300 } 3301 , 3302 i.flattenListeners = function(t) { 3303 var e, i = []; 3304 for (e = 0; e < t.length; e += 1) 3305 i.push(t[e].listener); 3306 return i 3307 } 3308 , 3309 i.getListenersAsObject = function(t) { 3310 var e, i = this.getListeners(t); 3311 return i instanceof Array && ((e = {})[t] = i), 3312 e || i 3313 } 3314 , 3315 i.addListener = function(t, e) { 3316 var i, n = this.getListenersAsObject(t), s = "object" == typeof e; 3317 for (i in n) 3318 n.hasOwnProperty(i) && -1 === o(n[i], e) && n[i].push(s ? e : { 3319 listener: e, 3320 once: !1 3321 }); 3322 return this 3323 } 3324 , 3325 i.on = e("addListener"), 3326 i.addOnceListener = function(t, e) { 3327 return this.addListener(t, { 3328 listener: e, 3329 once: !0 3330 }) 3331 } 3332 , 3333 i.once = e("addOnceListener"), 3334 i.defineEvent = function(t) { 3335 return this.getListeners(t), 3336 this 3337 } 3338 , 3339 i.defineEvents = function(t) { 3340 for (var e = 0; e < t.length; e += 1) 3341 this.defineEvent(t[e]); 3342 return this 3343 } 3344 , 3345 i.removeListener = function(t, e) { 3346 var i, n, s = this.getListenersAsObject(t); 3347 for (n in s) 3348 s.hasOwnProperty(n) && (-1 !== (i = o(s[n], e)) && s[n].splice(i, 1)); 3349 return this 3350 } 3351 , 3352 i.off = e("removeListener"), 3353 i.addListeners = function(t, e) { 3354 return this.manipulateListeners(!1, t, e) 3355 } 3356 , 3357 i.removeListeners = function(t, e) { 3358 return this.manipulateListeners(!0, t, e) 3359 } 3360 , 3361 i.manipulateListeners = function(t, e, i) { 3362 var n, s, o = t ? this.removeListener : this.addListener, r = t ? this.removeListeners : this.addListeners; 3363 if ("object" != typeof e || e instanceof RegExp) 3364 for (n = i.length; n--; ) 3365 o.call(this, e, i[n]); 3366 else 3367 for (n in e) 3368 e.hasOwnProperty(n) && (s = e[n]) && ("function" == typeof s ? o.call(this, n, s) : r.call(this, n, s)); 3369 return this 3370 } 3371 , 3372 i.removeEvent = function(t) { 3373 var e, i = typeof t, n = this._getEvents(); 3374 if ("string" === i) 3375 delete n[t]; 3376 else if (t instanceof RegExp) 3377 for (e in n) 3378 n.hasOwnProperty(e) && t.test(e) && delete n[e]; 3379 else 3380 delete this._events; 3381 return this 3382 } 3383 , 3384 i.removeAllListeners = e("removeEvent"), 3385 i.emitEvent = function(t, e) { 3386 var i, n, s, o = this.getListenersAsObject(t); 3387 for (s in o) 3388 if (o.hasOwnProperty(s)) 3389 for (n = o[s].length; n--; ) 3390 !0 === (i = o[s][n]).once && this.removeListener(t, i.listener), 3391 i.listener.apply(this, e || []) === this._getOnceReturnValue() && this.removeListener(t, i.listener); 3392 return this 3393 } 3394 , 3395 i.trigger = e("emitEvent"), 3396 i.emit = function(t) { 3397 var e = Array.prototype.slice.call(arguments, 1); 3398 return this.emitEvent(t, e) 3399 } 3400 , 3401 i.setOnceReturnValue = function(t) { 3402 return this._onceReturnValue = t, 3403 this 3404 } 3405 , 3406 i._getOnceReturnValue = function() { 3407 return !this.hasOwnProperty("_onceReturnValue") || this._onceReturnValue 3408 } 3409 , 3410 i._getEvents = function() { 3411 return this._events || (this._events = {}) 3412 } 3413 , 3414 t.noConflict = function() { 3415 return n.EventEmitter = s, 3416 t 3417 } 3418 , 3419 "function" == typeof define && define.amd ? define("eventEmitter/EventEmitter", [], function() { 3420 return t 3421 }) : "object" == typeof module && module.exports ? module.exports = t : n.EventEmitter = t 3422} 3423.call(this), 3424function(t) { 3425 function e(t) { 3426 if (t) { 3427 if ("string" == typeof o[t]) 3428 return t; 3429 t = t.charAt(0).toUpperCase() + t.slice(1); 3430 for (var e, i = 0, n = s.length; i < n; i++) 3431 if (e = s[i] + t, 3432 "string" == typeof o[e]) 3433 return e 3434 } 3435 } 3436 var s = "Webkit Moz ms Ms O".split(" ") 3437 , o = document.documentElement.style; 3438 "function" == typeof define && define.amd ? define("get-style-property/get-style-property", [], function() { 3439 return e 3440 }) : "object" == typeof exports ? module.exports = e : t.getStyleProperty = e 3441}(window), 3442function(C) { 3443 function S(t) { 3444 var e = parseFloat(t); 3445 return -1 === t.indexOf("%") && !isNaN(e) && e 3446 } 3447 function t(y) { 3448 function b(t, e) { 3449 if (C.getComputedStyle || -1 === e.indexOf("%")) 3450 return e; 3451 var i = t.style 3452 , n = i.left 3453 , s = t.runtimeStyle 3454 , o = s && s.left; 3455 return o && (s.left = t.currentStyle.left), 3456 i.left = e, 3457 e = i.pixelLeft, 3458 i.left = n, 3459 o && (s.left = o), 3460 e 3461 } 3462 var w, x, _, k = !1; 3463 return function(t) { 3464 if (function() { 3465 if (!k) { 3466 k = !0; 3467 var e = C.getComputedStyle; 3468 if (s = e ? function(t) { 3469 return e(t, null) 3470 } 3471 : function(t) { 3472 return t.currentStyle 3473 } 3474 , 3475 w = function(t) { 3476 var e = s(t); 3477 return e || T("Style returned " + e + ". Are you running this code in a hidden iframe on Firefox? See http://bit.ly/getsizebug1"), 3478 e 3479 } 3480 , 3481 x = y("boxSizing")) { 3482 var t = document.createElement("div"); 3483 t.style.width = "200px", 3484 t.style.padding = "1px 2px 3px 4px", 3485 t.style.borderStyle = "solid", 3486 t.style.borderWidth = "1px 2px 3px 4px", 3487 t.style[x] = "border-box"; 3488 var i = document.body || document.documentElement; 3489 i.appendChild(t); 3490 var n = w(t); 3491 _ = 200 === S(n.width), 3492 i.removeChild(t) 3493 } 3494 } 3495 var s 3496 }(), 3497 "string" == typeof t && (t = document.querySelector(t)), 3498 t && "object" == typeof t && t.nodeType) { 3499 var e = w(t); 3500 if ("none" === e.display) 3501 return function() { 3502 for (var t = { 3503 width: 0, 3504 height: 0, 3505 innerWidth: 0, 3506 innerHeight: 0, 3507 outerWidth: 0, 3508 outerHeight: 0 3509 }, e = 0, i = I.length; e < i; e++) 3510 t[I[e]] = 0; 3511 return t 3512 }(); 3513 var i = {}; 3514 i.width = t.offsetWidth, 3515 i.height = t.offsetHeight; 3516 for (var n = i.isBorderBox = !(!x || !e[x] || "border-box" !== e[x]), s = 0, o = I.length; s < o; s++) { 3517 var r = I[s] 3518 , a = e[r]; 3519 a = b(t, a); 3520 var l = parseFloat(a); 3521 i[r] = isNaN(l) ? 0 : l 3522 } 3523 var c = i.paddingLeft + i.paddingRight 3524 , u = i.paddingTop + i.paddingBottom 3525 , h = i.marginLeft + i.marginRight 3526 , d = i.marginTop + i.marginBottom 3527 , p = i.borderLeftWidth + i.borderRightWidth 3528 , f = i.borderTopWidth + i.borderBottomWidth 3529 , g = n && _ 3530 , m = S(e.width); 3531 !1 !== m && (i.width = m + (g ? 0 : c + p)); 3532 var v = S(e.height); 3533 return !1 !== v && (i.height = v + (g ? 0 : u + f)), 3534 i.innerWidth = i.width - (c + p), 3535 i.innerHeight = i.height - (u + f), 3536 i.outerWidth = i.width + h, 3537 i.outerHeight = i.height + d, 3538 i 3539 } 3540 } 3541 } 3542 var T = "undefined" == typeof console ? function() {} 3543 : function(t) { 3544 console.error(t) 3545 } 3546 , I = ["paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "marginLeft", "marginRight", "marginTop", "marginBottom", "borderLeftWidth", "borderRightWidth", "borderTopWidth", "borderBottomWidth"]; 3547 "function" == typeof define && define.amd ? define("get-size/get-size", ["get-style-property/get-style-property"], t) : "object" == typeof exports ? module.exports = t(require("desandro-get-style-property")) : C.getSize = t(C.get
3547StyleProperty) 3548}(window), 3549function(e) { 3550 function i(t) { 3551 "function" == typeof t && (i.isReady ? t() : r.push(t)) 3552 } 3553 function n(t) { 3554 var e = "readystatechange" === t.type && "complete" !== o.readyState; 3555 i.isReady || e || s() 3556 } 3557 function s() { 3558 i.isReady = !0; 3559 for (var t = 0, e = r.length; t < e; t++) { 3560 (0, 3561 r[t])() 3562 } 3563 } 3564 function t(t) { 3565 return "complete" === o.readyState ? s() : (t.bind(o, "DOMContentLoaded", n), 3566 t.bind(o, "readystatechange", n), 3567 t.bind(e, "load", n)), 3568 i 3569 } 3570 var o = e.document 3571 , r = []; 3572 i.isReady = !1, 3573 "function" == typeof define && define.amd ? define("doc-ready/doc-ready", ["eventie/eventie"], t) : "object" == typeof exports ? module.exports = t(require("eventie")) : e.docReady = t(e.eventie) 3574}(window), 3575function(s) { 3576 "use strict"; 3577 function i(t, e) { 3578 return t[n](e) 3579 } 3580 function o(t) { 3581 t.parentNode || document.createDocumentFragment().appendChild(t) 3582 } 3583 var t, n = function() { 3584 if (s.matches) 3585 return "matches"; 3586 if (s.matchesSelector) 3587 return "matchesSelector"; 3588 for (var t = ["webkit", "moz", "ms", "o"], e = 0, i = t.length; e < i; e++) { 3589 var n = t[e] + "MatchesSelector"; 3590 if (s[n]) 3591 return n 3592 } 3593 }(); 3594 if (n) { 3595 var e = i(document.createElement("div"), "div"); 3596 t = e ? i : function(t, e) { 3597 return o(t), 3598 i(t, e) 3599 } 3600 } else 3601 t = function(t, e) { 3602 o(t); 3603 for (var i = t.parentNode.querySelectorAll(e), n = 0, s = i.length; n < s; n++) 3604 if (i[n] === t) 3605 return !0; 3606 return !1 3607 } 3608 ; 3609 "function" == typeof define && define.amd ? define("matches-selector/matches-selector", [], function() { 3610 return t 3611 }) : "object" == typeof exports ? module.exports = t : window.matchesSelector = t 3612}(Element.prototype), 3613function(i, n) { 3614 "use strict"; 3615 "function" == typeof define && define.amd ? define("fizzy-ui-utils/utils", ["doc-ready/doc-ready", "matches-selector/matches-selector"], function(t, e) { 3616 return n(i, t, e) 3617 }) : "object" == typeof exports ? module.exports = n(i, require("doc-ready"), require("desandro-matches-selector")) : i.fizzyUIUtils = n(i, i.docReady, i.matchesSelector) 3618}(window, function(d, t, c) { 3619 var i, p = { 3620 extend: function(t, e) { 3621 for (var i in e) 3622 t[i] = e[i]; 3623 return t 3624 }, 3625 modulo: function(t, e) { 3626 return (t % e + e) % e 3627 } 3628 }, e = Object.prototype.toString; 3629 p.isArray = function(t) { 3630 return "[object Array]" == e.call(t) 3631 } 3632 , 3633 p.makeArray = function(t) { 3634 var e = []; 3635 if (p.isArray(t)) 3636 e = t; 3637 else if (t && "number" == typeof t.length) 3638 for (var i = 0, n = t.length; i < n; i++) 3639 e.push(t[i]); 3640 else 3641 e.push(t); 3642 return e 3643 } 3644 , 3645 p.indexOf = Array.prototype.indexOf ? function(t, e) { 3646 return t.indexOf(e) 3647 } 3648 : function(t, e) { 3649 for (var i = 0, n = t.length; i < n; i++) 3650 if (t[i] === e) 3651 return i; 3652 return -1 3653 } 3654 , 3655 p.removeFrom = function(t, e) { 3656 var i = p.indexOf(t, e); 3657 -1 != i && t.splice(i, 1) 3658 } 3659 , 3660 p.isElement = "function" == typeof HTMLElement || "object" == typeof HTMLElement ? function(t) { 3661 return t instanceof HTMLElement 3662 } 3663 : function(t) { 3664 return t && "object" == typeof t && 1 == t.nodeType && "string" == typeof t.nodeName 3665 } 3666 , 3667 p.setText = function(t, e) { 3668 t[i = i || (void 0 !== document.documentElement.textContent ? "textContent" : "innerText")] = e 3669 } 3670 , 3671 p.getParent = function(t, e) { 3672 for (; t != document.body; ) 3673 if (t = t.parentNode, 3674 c(t, e)) 3675 return t 3676 } 3677 , 3678 p.getQueryElement = function(t) { 3679 return "string" == typeof t ? document.querySelector(t) : t 3680 } 3681 , 3682 p.handleEvent = function(t) { 3683 var e = "on" + t.type; 3684 this[e] && this[e](t) 3685 } 3686 , 3687 p.filterFindElements = function(t, e) { 3688 for (var i = [], n = 0, s = (t = p.makeArray(t)).length; n < s; n++) { 3689 var o = t[n]; 3690 if (p.isElement(o)) 3691 if (e) { 3692 c(o, e) && i.push(o); 3693 for (var r = o.querySelectorAll(e), a = 0, l = r.length; a < l; a++) 3694 i.push(r[a]) 3695 } else 3696 i.push(o) 3697 } 3698 return i 3699 } 3700 , 3701 p.debounceMethod = function(t, e, n) { 3702 var s = t.prototype[e] 3703 , o = e + "Timeout"; 3704 t.prototype[e] = function() { 3705 var t = this[o]; 3706 t && clearTimeout(t); 3707 var e = arguments 3708 , i = this; 3709 this[o] = setTimeout(function() { 3710 s.apply(i, e), 3711 delete i[o] 3712 }, n || 100) 3713 } 3714 } 3715 , 3716 p.toDashed = function(t) { 3717 return t.replace(/(.)([A-Z])/g, function(t, e, i) { 3718 return e + "-" + i 3719 }).toLowerCase() 3720 } 3721 ; 3722 var f = d.console; 3723 return p.htmlInit = function(u, h) { 3724 t(function() { 3725 for (var t = p.toDashed(h), e = document.querySelectorAll(".js-" + t), i = "data-" + t + "-options", n = 0, s = e.length; n < s; n++) { 3726 var o, r = e[n], a = r.getAttribute(i); 3727 try { 3728 o = a && JSON.parse(a) 3729 } catch (t) { 3730 f && f.error("Error parsing " + i + " on " + r.nodeName.toLowerCase() + (r.id ? "#" + r.id : "") + ": " + t); 3731 continue 3732 } 3733 var l = new u(r,o) 3734 , c = d.jQuery; 3735 c && c.data(r, h, l) 3736 } 3737 }) 3738 } 3739 , 3740 p 3741}), 3742function(s, o) { 3743 "use strict"; 3744 "function" == typeof define && define.amd ? define("outlayer/item", ["eventEmitter/EventEmitter", "get-size/get-size", "get-style-property/get-style-property", "fizzy-ui-utils/utils"], function(t, e, i, n) { 3745 return o(s, t, e, i, n) 3746 }) : "object" == typeof exports ? module.exports = o(s, require("wolfy87-eventemitter"), require("get-size"), require("desandro-get-style-property"), require("fizzy-ui-utils")) : (s.Outlayer = {}, 3747 s.Outlayer.Item = o(s, s.EventEmitter, s.getSize, s.getStyleProperty, s.fizzyUIUtils)) 3748}(window, function(t, e, i, o, n) { 3749 "use strict"; 3750 function s(t, e) { 3751 t && (this.element = t, 3752 this.layout = e, 3753 this.position = { 3754 x: 0, 3755 y: 0 3756 }, 3757 this._create()) 3758 } 3759 var r = t.getComputedStyle 3760 , c = r ? function(t) { 3761 return r(t, null) 3762 } 3763 : function(t) { 3764 return t.currentStyle 3765 } 3766 , a = o("transition") 3767 , l = o("transform") 3768 , u = a && l 3769 , h = !!o("perspective") 3770 , d = { 3771 WebkitTransition: "webkitTransitionEnd", 3772 MozTransition: "transitionend", 3773 OTransition: "otransitionend", 3774 transition: "transitionend" 3775 }[a] 3776 , p = ["transform", "transition", "transitionDuration", "transitionProperty"] 3777 , f = function() { 3778 for (var t = {}, e = 0, i = p.length; e < i; e++) { 3779 var n = p[e] 3780 , s = o(n); 3781 s && s !== n && (t[n] = s) 3782 } 3783 return t 3784 }(); 3785 n.extend(s.prototype, e.prototype), 3786 s.prototype._create = function() { 3787 this._transn = { 3788 ingProperties: {}, 3789 clean: {}, 3790 onEnd: {} 3791 }, 3792 this.css({ 3793 position: "absolute" 3794 }) 3795 } 3796 , 3797 s.prototype.handleEvent = function(t) { 3798 var e = "on" + t.type; 3799 this[e] && this[e](t) 3800 } 3801 , 3802 s.prototype.getSize = function() { 3803 this.size = i(this.element) 3804 } 3805 , 3806 s.prototype.css = function(t) { 3807 var e = this.element.style; 3808 for (var i in t) { 3809 e[f[i] || i] = t[i] 3810 } 3811 } 3812 , 3813 s.prototype.getPosition = function() { 3814 var t = c(this.element) 3815 , e = this.layout.options 3816 , i = e.isOriginLeft 3817 , n = e.isOriginTop 3818 , s = t[i ? "left" : "right"] 3819 , o = t[n ? "top" : "bottom"] 3820 , r = this.layout.size 3821 , a = -1 != s.indexOf("%") ? parseFloat(s) / 100 * r.width : parseInt(s, 10) 3822 , l = -1 != o.indexOf("%") ? parseFloat(o) / 100 * r.height : parseInt(o, 10); 3823 a = isNaN(a) ? 0 : a, 3824 l = isNaN(l) ? 0 : l, 3825 a -= i ? r.paddingLeft : r.paddingRight, 3826 l -= n ? r.paddingTop : r.paddingBottom, 3827 this.position.x = a, 3828 this.position.y = l 3829 } 3830 , 3831 s.prototype.layoutPosition = function() { 3832 var t = this.layout.size 3833 , e = this.layout.options 3834 , i = {} 3835 , n = e.isOriginLeft ? "paddingLeft" : "paddingRight" 3836 , s = e.isOriginLeft ? "left" : "right" 3837 , o = e.isOriginLeft ? "right" : "left" 3838 , r = this.position.x + t[n]; 3839 i[s] = this.getXValue(r), 3840 i[o] = ""; 3841 var a = e.isOriginTop ? "paddingTop" : "paddingBottom" 3842 , l = e.isOriginTop ? "top" : "bottom" 3843 , c = e.isOriginTop ? "bottom" : "top" 3844 , u = this.position.y + t[a]; 3845 i[l] = this.getYValue(u), 3846 i[c] = "", 3847 this.css(i), 3848 this.emitEvent("layout", [this]) 3849 } 3850 , 3851 s.prototype.getXValue = function(t) { 3852 var e = this.layout.options; 3853 return e.percentPosition && !e.isHorizontal ? t / this.layout.size.width * 100 + "%" : t + "px" 3854 } 3855 , 3856 s.prototype.getYValue = function(t) { 3857 var e = this.layout.options; 3858 return e.percentPosition && e.isHorizontal ? t / this.layout.size.height * 100 + "%" : t + "px" 3859 } 3860 ,
3861 s.prototype._transitionTo = function(t, e) { 3862 this.getPosition(); 3863 var i = this.position.x 3864 , n = this.position.y 3865 , s = parseInt(t, 10) 3866 , o = parseInt(e, 10) 3867 , r = s === this.position.x && o === this.position.y; 3868 if (this.setPosition(t, e), 3869 !r || this.isTransitioning) { 3870 var a = t - i 3871 , l = e - n 3872 , c = {}; 3873 c.transform = this.getTranslate(a, l), 3874 this.transition({ 3875 to: c, 3876 onTransitionEnd: { 3877 transform: this.layoutPosition 3878 }, 3879 isCleaning: !0 3880 }) 3881 } else 3882 this.layoutPosition() 3883 } 3884 , 3885 s.prototype.getTranslate = function(t, e) { 3886 var i = this.layout.options; 3887 return t = i.isOriginLeft ? t : -t, 3888 e = i.isOriginTop ? e : -e, 3889 h ? "translate3d(" + t + "px, " + e + "px, 0)" : "translate(" + t + "px, " + e + "px)" 3890 } 3891 , 3892 s.prototype.goTo = function(t, e) { 3893 this.setPosition(t, e), 3894 this.layoutPosition() 3895 } 3896 , 3897 s.prototype.moveTo = u ? s.prototype._transitionTo : s.prototype.goTo, 3898 s.prototype.setPosition = function(t, e) { 3899 this.position.x = parseInt(t, 10), 3900 this.position.y = parseInt(e, 10) 3901 } 3902 , 3903 s.prototype._nonTransition = function(t) { 3904 for (var e in this.css(t.to), 3905 t.isCleaning && this._removeStyles(t.to), 3906 t.onTransitionEnd) 3907 t.onTransitionEnd[e].call(this) 3908 } 3909 , 3910 s.prototype._transition = function(t) { 3911 if (parseFloat(this.layout.options.transitionDuration)) { 3912 var e = this._transn; 3913 for (var i in t.onTransitionEnd) 3914 e.onEnd[i] = t.onTransitionEnd[i]; 3915 for (i in t.to) 3916 e.ingProperties[i] = !0, 3917 t.isCleaning && (e.clean[i] = !0); 3918 if (t.from) { 3919 this.css(t.from); 3920 this.element.offsetHeight; 3921 null 3922 } 3923 this.enableTransition(t.to), 3924 this.css(t.to), 3925 this.isTransitioning = !0 3926 } else 3927 this._nonTransition(t) 3928 } 3929 ; 3930 var g = "opacity," + (f.transform || "transform").replace(/([A-Z])/g, function(t) { 3931 return "-" + t.toLowerCase() 3932 }); 3933 s.prototype.enableTransition = function() { 3934 this.isTransitioning || (this.css({ 3935 transitionProperty: g, 3936 transitionDuration: this.layout.options.transitionDuration 3937 }), 3938 this.element.addEventListener(d, this, !1)) 3939 } 3940 , 3941 s.prototype.transition = s.prototype[a ? "_transition" : "_nonTransition"], 3942 s.prototype.onwebkitTransitionEnd = function(t) { 3943 this.ontransitionend(t) 3944 } 3945 , 3946 s.prototype.onotransitionend = function(t) { 3947 this.ontransitionend(t) 3948 } 3949 ; 3950 var m = { 3951 "-webkit-transform": "transform", 3952 "-moz-transform": "transform", 3953 "-o-transform": "transform" 3954 }; 3955 s.prototype.ontransitionend = function(t) { 3956 if (t.target === this.element) { 3957 var e = this._transn 3958 , i = m[t.propertyName] || t.propertyName; 3959 if (delete e.ingProperties[i], 3960 function(t) { 3961 for (var e in t) 3962 return !1; 3963 return !0 3964 }(e.ingProperties) && this.disableTransition(), 3965 i in e.clean && (this.element.style[t.propertyName] = "", 3966 delete e.clean[i]), 3967 i in e.onEnd) 3968 e.onEnd[i].call(this), 3969 delete e.onEnd[i]; 3970 this.emitEvent("transitionEnd", [this]) 3971 } 3972 } 3973 , 3974 s.prototype.disableTransition = function() { 3975 this.removeTransitionStyles(), 3976 this.element.removeEventListener(d, this, !1), 3977 this.isTransitioning = !1 3978 } 3979 , 3980 s.prototype._removeStyles = function(t) { 3981 var e = {}; 3982 for (var i in t) 3983 e[i] = ""; 3984 this.css(e) 3985 } 3986 ; 3987 var v = { 3988 transitionProperty: "", 3989 transitionDuration: "" 3990 }; 3991 return s.prototype.removeTransitionStyles = function() { 3992 this.css(v) 3993 } 3994 , 3995 s.prototype.removeElem = function() { 3996 this.element.parentNode.removeChild(this.element), 3997 this.css({ 3998 display: "" 3999 }), 4000 this.emitEvent("remove", [this]) 4001 } 4002 , 4003 s.prototype.remove = function() { 4004 if (a && parseFloat(this.layout.options.transitionDuration)) { 4005 var t = this; 4006 this.once("transitionEnd", function() { 4007 t.removeElem() 4008 }), 4009 this.hide() 4010 } else 4011 this.removeElem() 4012 } 4013 , 4014 s.prototype.reveal = function() { 4015 delete this.isHidden, 4016 this.css({ 4017 display: "" 4018 }); 4019 var t = this.layout.options 4020 , e = {}; 4021 e[this.getHideRevealTransitionEndProperty("visibleStyle")] = this.onRevealTransitionEnd, 4022 this.transition({ 4023 from: t.hiddenStyle, 4024 to: t.visibleStyle, 4025 isCleaning: !0, 4026 onTransitionEnd: e 4027 }) 4028 } 4029 , 4030 s.prototype.onRevealTransitionEnd = function() { 4031 this.isHidden || this.emitEvent("reveal") 4032 } 4033 , 4034 s.prototype.getHideRevealTransitionEndProperty = function(t) { 4035 var e = this.layout.options[t]; 4036 if (e.opacity) 4037 return "opacity"; 4038 for (var i in e) 4039 return i 4040 } 4041 , 4042 s.prototype.hide = function() { 4043 this.isHidden = !0, 4044 this.css({ 4045 display: "" 4046 }); 4047 var t = this.layout.options 4048 , e = {}; 4049 e[this.getHideRevealTransitionEndProperty("hiddenStyle")] = this.onHideTransitionEnd, 4050 this.transition({ 4051 from: t.visibleStyle, 4052 to: t.hiddenStyle, 4053 isCleaning: !0, 4054 onTransitionEnd: e 4055 }) 4056 } 4057 , 4058 s.prototype.onHideTransitionEnd = function() { 4059 this.isHidden && (this.css({ 4060 display: "none" 4061 }), 4062 this.emitEvent("hide")) 4063 } 4064 , 4065 s.prototype.destroy = function() { 4066 this.css({ 4067 position: "", 4068 left: "", 4069 right: "", 4070 top: "", 4071 bottom: "", 4072 transition: "", 4073 transform: "" 4074 }) 4075 } 4076 , 4077 s 4078}), 4079function(o, r) { 4080 "use strict"; 4081 "function" == typeof define && define.amd ? define("outlayer/outlayer", ["eventie/eventie", "eventEmitter/EventEmitter", "get-size/get-size", "fizzy-ui-utils/utils", "./item"], function(t, e, i, n, s) { 4082 return r(o, t, e, i, n, s) 4083 }) : "object" == typeof exports ? module.exports = r(o, require("eventie"), require("wolfy87-eventemitter"), require("get-size"), require("fizzy-ui-utils"), require("./item")) : o.Outlayer = r(o, o.eventie, o.EventEmitter, o.getSize, o.fizzyUIUtils, o.Outlayer.Item) 4084}(window, function(t, e, i, s, r, n) { 4085 "use strict"; 4086 function o(t, e) { 4087 var i = r.getQueryElement(t); 4088 if (i) { 4089 this.element = i, 4090 l && (this.$element = l(this.element)), 4091 this.options = r.extend({}, this.constructor.defaults), 4092 this.option(e); 4093 var n = ++u; 4094 this.element.outlayerGUID = n, 4095 (h[n] = this)._create(), 4096 this.options.isInitLayout && this.layout() 4097 } else 4098 a && a.error("Bad element for " + this.constructor.namespace + ": " + (i || t)) 4099 } 4100 var a = t.console 4101 , l = t.jQuery 4102 , c = function() {} 4103 , u = 0 4104 , h = {}; 4105 return o.namespace = "outlayer", 4106 o.Item = n, 4107 o.defaults = { 4108 containerStyle: { 4109 position: "relative" 4110 }, 4111 isInitLayout: !0, 4112 isOriginLeft: !0, 4113 isOriginTop: !0, 4114 isResizeBound: !0, 4115 isResizingContainer: !0, 4116 transitionDuration: "0.4s", 4117 hiddenStyle: { 4118 opacity: 0, 4119 transform: "scale(0.001)" 4120 }, 4121 visibleStyle: { 4122 opacity: 1, 4123 transform: "scale(1)" 4124 } 4125 }, 4126 r.extend(o.prototype, i.prototype), 4127 o.prototype.option = function(t) { 4128 r.extend(this.options, t) 4129 } 4130 , 4131 o.prototype._create = function() { 4132 this.reloadItems(), 4133 this.stamps = [], 4134 this.stamp(this.options.stamp), 4135 r.extend(this.element.style, this.options.containerStyle), 4136 this.options.isResizeBound && this.bindResize() 4137 } 4138 , 4139 o.prototype.reloadItems = function() { 4140 this.items = this._itemize(this.element.children) 4141 } 4142 , 4143 o.prototype._itemize = function(t) { 4144 for (var e = this._filterFindItemElements(t), i = this.constructor.Item, n = [], s = 0, o = e.length; s < o; s++) { 4145 var r = new i(e[s],this); 4146 n.push(r) 4147 } 4148 return n 4149 } 4150 , 4151 o.prototype._filterFindItemElements = function(t) { 4152 return r.filterFindElements(t, this.options.itemSelector) 4153 } 4154 , 4155 o.prototype.getItemElements = function() { 4156 for (var t = [], e = 0, i = this.items.length; e < i; e++) 4157 t.push(this.items[e].element); 4158 return t 4159 } 4160 , 4161 o.prototype.layout = function() { 4162 this._resetLayout(), 4163 this._manageStamps(); 4164 var t = void 0 !== this.options.isLayoutInstant ? this.options.isLayoutInstant : !this._isLayoutInited; 4165 this.layoutItems(this.items, t), 4166 this._isLayoutInited = !0 4167 } 4168 , 4169 o.prototype._init = o.prototype.layout, 4170 o.prototype._resetLayout = function() {
4171 this.getSize() 4172 } 4173 , 4174 o.prototype.getSize = function() { 4175 this.size = s(this.element) 4176 } 4177 , 4178 o.prototype._getMeasurement = function(t, e) { 4179 var i, n = this.options[t]; 4180 n ? ("string" == typeof n ? i = this.element.querySelector(n) : r.isElement(n) && (i = n), 4181 this[t] = i ? s(i)[e] : n) : this[t] = 0 4182 } 4183 , 4184 o.prototype.layoutItems = function(t, e) { 4185 t = this._getItemsForLayout(t), 4186 this._layoutItems(t, e), 4187 this._postLayout() 4188 } 4189 , 4190 o.prototype._getItemsForLayout = function(t) { 4191 for (var e = [], i = 0, n = t.length; i < n; i++) { 4192 var s = t[i]; 4193 s.isIgnored || e.push(s) 4194 } 4195 return e 4196 } 4197 , 4198 o.prototype._layoutItems = function(t, e) { 4199 if (this._emitCompleteOnItems("layout", t), 4200 t && t.length) { 4201 for (var i = [], n = 0, s = t.length; n < s; n++) { 4202 var o = t[n] 4203 , r = this._getItemLayoutPosition(o); 4204 r.item = o, 4205 r.isInstant = e || o.isLayoutInstant, 4206 i.push(r) 4207 } 4208 this._processLayoutQueue(i) 4209 } 4210 } 4211 , 4212 o.prototype._getItemLayoutPosition = function() { 4213 return { 4214 x: 0, 4215 y: 0 4216 } 4217 } 4218 , 4219 o.prototype._processLayoutQueue = function(t) { 4220 for (var e = 0, i = t.length; e < i; e++) { 4221 var n = t[e]; 4222 this._positionItem(n.item, n.x, n.y, n.isInstant) 4223 } 4224 } 4225 , 4226 o.prototype._positionItem = function(t, e, i, n) { 4227 n ? t.goTo(e, i) : t.moveTo(e, i) 4228 } 4229 , 4230 o.prototype._postLayout = function() { 4231 this.resizeContainer() 4232 } 4233 , 4234 o.prototype.resizeContainer = function() { 4235 if (this.options.isResizingContainer) { 4236 var t = this._getContainerSize(); 4237 t && (this._setContainerMeasure(t.width, !0), 4238 this._setContainerMeasure(t.height, !1)) 4239 } 4240 } 4241 , 4242 o.prototype._getContainerSize = c, 4243 o.prototype._setContainerMeasure = function(t, e) { 4244 if (void 0 !== t) { 4245 var i = this.size; 4246 i.isBorderBox && (t += e ? i.paddingLeft + i.paddingRight + i.borderLeftWidth + i.borderRightWidth : i.paddingBottom + i.paddingTop + i.borderTopWidth + i.borderBottomWidth), 4247 t = Math.max(t, 0), 4248 this.element.style[e ? "width" : "height"] = t + "px" 4249 } 4250 } 4251 , 4252 o.prototype._emitCompleteOnItems = function(t, e) { 4253 function i() { 4254 s.dispatchEvent(t + "Complete", null, [e]) 4255 } 4256 function n() { 4257 ++r === o && i() 4258 } 4259 var s = this 4260 , o = e.length; 4261 if (e && o) 4262 for (var r = 0, a = 0, l = e.length; a < l; a++) { 4263 e[a].once(t, n) 4264 } 4265 else 4266 i() 4267 } 4268 , 4269 o.prototype.dispatchEvent = function(t, e, i) { 4270 var n = e ? [e].concat(i) : i; 4271 if (this.emitEvent(t, n), 4272 l) 4273 if (this.$element = this.$element || l(this.element), 4274 e) { 4275 var s = l.Event(e); 4276 s.type = t, 4277 this.$element.trigger(s, i) 4278 } else 4279 this.$element.trigger(t, i) 4280 } 4281 , 4282 o.prototype.ignore = function(t) { 4283 var e = this.getItem(t); 4284 e && (e.isIgnored = !0) 4285 } 4286 , 4287 o.prototype.unignore = function(t) { 4288 var e = this.getItem(t); 4289 e && delete e.isIgnored 4290 } 4291 , 4292 o.prototype.stamp = function(t) { 4293 if (t = this._find(t)) { 4294 this.stamps = this.stamps.concat(t); 4295 for (var e = 0, i = t.length; e < i; e++) { 4296 var n = t[e]; 4297 this.ignore(n) 4298 } 4299 } 4300 } 4301 , 4302 o.prototype.unstamp = function(t) { 4303 if (t = this._find(t)) 4304 for (var e = 0, i = t.length; e < i; e++) { 4305 var n = t[e]; 4306 r.removeFrom(this.stamps, n), 4307 this.unignore(n) 4308 } 4309 } 4310 , 4311 o.prototype._find = function(t) { 4312 return t ? ("string" == typeof t && (t = this.element.querySelectorAll(t)), 4313 t = r.makeArray(t)) : void 0 4314 } 4315 , 4316 o.prototype._manageStamps = function() { 4317 if (this.stamps && this.stamps.length) { 4318 this._getBoundingRect(); 4319 for (var t = 0, e = this.stamps.length; t < e; t++) { 4320 var i = this.stamps[t]; 4321 this._manageStamp(i) 4322 } 4323 } 4324 } 4325 , 4326 o.prototype._getBoundingRect = function() { 4327 var t = this.element.getBoundingClientRect() 4328 , e = this.size; 4329 this._boundingRect = { 4330 left: t.left + e.paddingLeft + e.borderLeftWidth, 4331 top: t.top + e.paddingTop + e.borderTopWidth, 4332 right: t.right - (e.paddingRight + e.borderRightWidth), 4333 bottom: t.bottom - (e.paddingBottom + e.borderBottomWidth) 4334 } 4335 } 4336 , 4337 o.prototype._manageStamp = c, 4338 o.prototype._getElementOffset = function(t) { 4339 var e = t.getBoundingClientRect() 4340 , i = this._boundingRect 4341 , n = s(t); 4342 return { 4343 left: e.left - i.left - n.marginLeft, 4344 top: e.top - i.top - n.marginTop, 4345 right: i.right - e.right - n.marginRight, 4346 bottom: i.bottom - e.bottom - n.marginBottom 4347 } 4348 } 4349 , 4350 o.prototype.handleEvent = function(t) { 4351 var e = "on" + t.type; 4352 this[e] && this[e](t) 4353 } 4354 , 4355 o.prototype.bindResize = function() { 4356 this.isResizeBound || (e.bind(t, "resize", this), 4357 this.isResizeBound = !0) 4358 } 4359 , 4360 o.prototype.unbindResize = function() { 4361 this.isResizeBound && e.unbind(t, "resize", this), 4362 this.isResizeBound = !1 4363 } 4364 , 4365 o.prototype.onresize = function() { 4366 this.resizeTimeout && clearTimeout(this.resizeTimeout); 4367 var t = this; 4368 this.resizeTimeout = setTimeout(function() { 4369 t.resize(), 4370 delete t.resizeTimeout 4371 }, 100) 4372 } 4373 , 4374 o.prototype.resize = function() { 4375 this.isResizeBound && this.needsResizeLayout() && this.layout() 4376 } 4377 , 4378 o.prototype.needsResizeLayout = function() { 4379 var t = s(this.element); 4380 return this.size && t && t.innerWidth !== this.size.innerWidth 4381 } 4382 , 4383 o.prototype.addItems = function(t) { 4384 var e = this._itemize(t); 4385 return e.length && (this.items = this.items.concat(e)), 4386 e 4387 } 4388 , 4389 o.prototype.appended = function(t) { 4390 var e = this.addItems(t); 4391 e.length && (this.layoutItems(e, !0), 4392 this.reveal(e)) 4393 } 4394 , 4395 o.prototype.prepended = function(t) { 4396 var e = this._itemize(t); 4397 if (e.length) { 4398 var i = this.items.slice(0); 4399 this.items = e.concat(i), 4400 this._resetLayout(), 4401 this._manageStamps(), 4402 this.layoutItems(e, !0), 4403 this.reveal(e), 4404 this.layoutItems(i) 4405 } 4406 } 4407 , 4408 o.prototype.reveal = function(t) { 4409 this._emitCompleteOnItems("reveal", t); 4410 for (var e = t && t.length, i = 0; e && i < e; i++) { 4411 t[i].reveal() 4412 } 4413 } 4414 , 4415 o.prototype.hide = function(t) { 4416 this._emitCompleteOnItems("hide", t); 4417 for (var e = t && t.length, i = 0; e && i < e; i++) { 4418 t[i].hide() 4419 } 4420 } 4421 , 4422 o.prototype.revealItemElements = function(t) { 4423 var e = this.getItems(t); 4424 this.reveal(e) 4425 } 4426 , 4427 o.prototype.hideItemElements = function(t) { 4428 var e = this.getItems(t); 4429 this.hide(e) 4430 } 4431 , 4432 o.prototype.getItem = function(t) { 4433 for (var e = 0, i = this.items.length; e < i; e++) { 4434 var n = this.items[e]; 4435 if (n.element === t) 4436 return n 4437 } 4438 } 4439 , 4440 o.prototype.getItems = function(t) { 4441 for (var e = [], i = 0, n = (t = r.makeArray(t)).length; i < n; i++) { 4442 var s = t[i] 4443 , o = this.getItem(s); 4444 o && e.push(o) 4445 } 4446 return e 4447 } 4448 , 4449 o.prototype.remove = function(t) { 4450 var e = this.getItems(t); 4451 if (this._emitCompleteOnItems("remove", e), 4452 e && e.length) 4453 for (var i = 0, n = e.length; i < n; i++) { 4454 var s = e[i]; 4455 s.remove(), 4456 r.removeFrom(this.items, s) 4457 } 4458 } 4459 , 4460 o.prototype.destroy = function() { 4461 var t = this.element.style; 4462 t.height = "", 4463 t.position = "", 4464 t.width = ""; 4465 for (var e = 0, i = this.items.length; e < i; e++) { 4466 this.items[e].destroy() 4467 } 4468 this.unbindResize(); 4469 var n = this.element.outlayerGUID; 4470 delete h[n], 4471 delete this.element.outlayerGUID, 4472 l && l.removeData(this.element, this.constructor.namespace) 4473 } 4474 , 4475 o.data = function(t) { 4476 var e = (t = r.getQueryElement(t)) && t.outlayerGUID; 4477 return e && h[e] 4478 } 4479 , 4480 o.create = function(t, e) { 4481 function i() { 4482 o.apply(this, arguments) 4483 } 4484 return Object.create ? i.prototype = Object.create(o.prototype) : r.extend(i.prototype, o.prototype), 4485 (i.prototype.constructor = i).defaults = r.extend({}, o.defaults), 4486 r.extend(i.defaults, e), 4487 i.prototype.settings = {}, 4488 i.namespace = t, 4489 i.data = o.data, 4490 i.Item = function() { 4491 n.apply(this, arguments) 4492 } 4493 , 4494 i.Item.prototype = new n, 4495 r.htmlInit(i, t), 4496 l && l.bridget && l.bridget(t, i), 4497 i 4498 } 4499 , 4500 o.Item = n, 4501 o 4502}), 4503function(t, e) { 4504 "use strict"; 4505 "function" == typeof define && define.amd ? define("isotope/js/item", ["outlayer/outlayer"], e) : "object" == typeof exports ? module.exports = e(require("outlayer")) : (t.Isotope = t.Isotope || {}, 4506 t.Isotope.Item = e(t.Outlayer)) 4507}(window, function(t) { 4508 "use strict"; 4509 function e() { 4510 t.Item.apply(this, arguments) 4511 } 4512 e.prototype = new t.Item, 4513 e.prototype._create = function() { 4514 this.id = this.layout.itemGUID++, 4515 t.Item.prototype._create.call(this), 4516 this.sortData = {} 4517 } 4518 , 4519 e.prototype.updateSortData = function() { 4520 if (!this.isIgnored) { 4521 this.sortData.id = this.id, 4522 this.sortData["original-order"] = this.id, 4523 this.sortData.random = Math.random(); 4524 var t = this.layout.options.getSortData 4525 , e = this.layout._sorters; 4526 for (var i in t) { 4527 var n = e[i]; 4528 this.sortData[i] = n(this.element, this) 4529 } 4530 } 4531 } 4532 ; 4533 var i = e.prototype.destroy; 4534 return e.prototype.destroy = function() { 4535 i.apply(this, arguments), 4536 this.css({ 4537 display: "" 4538 }) 4539 } 4540 , 4541 e 4542}), 4543function(t, e) { 4544 "use strict"; 4545 "function" == typeof define && define.amd ? define("isotope/js/layout-mode", ["get-size/get-size", "outlayer/outlayer"], e) : "object" == typeof exports ? module.exports = e(require("get-size"), require("outlayer")) : (t.Isotope = t.Isotope || {}, 4546 t.Isotope.LayoutMode = e(t.getSize, t.Outlayer)) 4547}(window, function(e, o) { 4548 "use strict"; 4549 function r(t) { 4550 (this.isotope = t) && (this.options = t.options[this.namespace], 4551 this.element = t.element, 4552 this.items = t.filteredItems, 4553 this.size = t.size) 4554 } 4555 return function() { 4556 function t(t) { 4557 return function() { 4558 return o.prototype[t].apply(this.isotope, arguments) 4559 } 4560 } 4561 for (var e = ["_resetLayout", "_getItemLayoutPosition", "_manageStamp", "_getContainerSize", "_getElementOffset", "needsResizeLayout"], i = 0, n = e.length; i < n; i++) { 4562 var s = e[i]; 4563 r.prototype[s] = t(s) 4564 } 4565 }(), 4566 r.prototype.needsVerticalResizeLayout = function() { 4567 var t = e(this.isotope.element);
4568 return this.isotope.size && t && t.innerHeight != this.isotope.size.innerHeight 4569 } 4570 , 4571 r.prototype._getMeasurement = function() { 4572 this.isotope._getMeasurement.apply(this, arguments) 4573 } 4574 , 4575 r.prototype.getColumnWidth = function() { 4576 this.getSegmentSize("column", "Width") 4577 } 4578 , 4579 r.prototype.getRowHeight = function() { 4580 this.getSegmentSize("row", "Height") 4581 } 4582 , 4583 r.prototype.getSegmentSize = function(t, e) { 4584 var i = t + e 4585 , n = "outer" + e; 4586 if (this._getMeasurement(i, n), 4587 !this[i]) { 4588 var s = this.getFirstItemSize(); 4589 this[i] = s && s[n] || this.isotope.size["inner" + e] 4590 } 4591 } 4592 , 4593 r.prototype.getFirstItemSize = function() { 4594 var t = this.isotope.filteredItems[0]; 4595 return t && t.element && e(t.element) 4596 } 4597 , 4598 r.prototype.layout = function() { 4599 this.isotope.layout.apply(this.isotope, arguments) 4600 } 4601 , 4602 r.prototype.getSize = function() { 4603 this.isotope.getSize(), 4604 this.size = this.isotope.size 4605 } 4606 , 4607 r.modes = {}, 4608 r.create = function(t, e) { 4609 function i() { 4610 r.apply(this, arguments) 4611 } 4612 return i.prototype = new r, 4613 e && (i.options = e), 4614 i.prototype.namespace = t, 4615 r.modes[t] = i 4616 } 4617 , 4618 r 4619}), 4620function(t, e) { 4621 "use strict"; 4622 "function" == typeof define && define.amd ? define("masonry/masonry", ["outlayer/outlayer", "get-size/get-size", "fizzy-ui-utils/utils"], e) : "object" == typeof exports ? module.exports = e(require("outlayer"), require("get-size"), require("fizzy-ui-utils")) : t.Masonry = e(t.Outlayer, t.getSize, t.fizzyUIUtils) 4623}(window, function(t, c, u) { 4624 var e = t.create("masonry"); 4625 return e.prototype._resetLayout = function() { 4626 this.getSize(), 4627 this._getMeasurement("columnWidth", "outerWidth"), 4628 this._getMeasurement("gutter", "outerWidth"), 4629 this.measureColumns(); 4630 var t = this.cols; 4631 for (this.colYs = []; t--; ) 4632 this.colYs.push(0); 4633 this.maxY = 0 4634 } 4635 , 4636 e.prototype.measureColumns = function() { 4637 if (this.getContainerWidth(), 4638 !this.columnWidth) { 4639 var t = this.items[0] 4640 , e = t && t.element; 4641 this.columnWidth = e && c(e).outerWidth || this.containerWidth 4642 } 4643 var i = this.columnWidth += this.gutter 4644 , n = this.containerWidth + this.gutter 4645 , s = n / i 4646 , o = i - n % i; 4647 s = Math[o && o < 1 ? "round" : "floor"](s), 4648 this.cols = Math.max(s, 1) 4649 } 4650 , 4651 e.prototype.getContainerWidth = function() { 4652 var t = this.options.isFitWidth ? this.element.parentNode : this.element 4653 , e = c(t); 4654 this.containerWidth = e && e.innerWidth 4655 } 4656 , 4657 e.prototype._getItemLayoutPosition = function(t) { 4658 t.getSize(); 4659 var e = t.size.outerWidth % this.columnWidth 4660 , i = Math[e && e < 1 ? "round" : "ceil"](t.size.outerWidth / this.columnWidth); 4661 i = Math.min(i, this.cols); 4662 for (var n = this._getColGroup(i), s = Math.min.apply(Math, n), o = u.indexOf(n, s), r = { 4663 x: this.columnWidth * o, 4664 y: s 4665 }, a = s + t.size.outerHeight, l = this.cols + 1 - n.length, c = 0; c < l; c++) 4666 this.colYs[o + c] = a; 4667 return r 4668 } 4669 , 4670 e.prototype._getColGroup = function(t) { 4671 if (t < 2) 4672 return this.colYs; 4673 for (var e = [], i = this.cols + 1 - t, n = 0; n < i; n++) { 4674 var s = this.colYs.slice(n, n + t); 4675 e[n] = Math.max.apply(Math, s) 4676 } 4677 return e 4678 } 4679 , 4680 e.prototype._manageStamp = function(t) { 4681 var e = c(t) 4682 , i = this._getElementOffset(t) 4683 , n = this.options.isOriginLeft ? i.left : i.right 4684 , s = n + e.outerWidth 4685 , o = Math.floor(n / this.columnWidth); 4686 o = Math.max(0, o); 4687 var r = Math.floor(s / this.columnWidth); 4688 r -= s % this.columnWidth ? 0 : 1, 4689 r = Math.min(this.cols - 1, r); 4690 for (var a = (this.options.isOriginTop ? i.top : i.bottom) + e.outerHeight, l = o; l <= r; l++) 4691 this.colYs[l] = Math.max(a, this.colYs[l]) 4692 } 4693 , 4694 e.prototype._getContainerSize = function() { 4695 this.maxY = Math.max.apply(Math, this.colYs); 4696 var t = { 4697 height: this.maxY 4698 }; 4699 return this.options.isFitWidth && (t.width = this._getContainerFitWidth()), 4700 t 4701 } 4702 , 4703 e.prototype._getContainerFitWidth = function() { 4704 for (var t = 0, e = this.cols; --e && 0 === this.colYs[e]; ) 4705 t++; 4706 return (this.cols - t) * this.columnWidth - this.gutter 4707 } 4708 , 4709 e.prototype.needsResizeLayout = function() { 4710 var t = this.containerWidth; 4711 return this.getContainerWidth(), 4712 t !== this.containerWidth 4713 } 4714 , 4715 e 4716}), 4717function(t, e) { 4718 "use strict"; 4719 "function" == typeof define && define.amd ? define("isotope/js/layout-modes/masonry", ["../layout-mode", "masonry/masonry"], e) : "object" == typeof exports ? module.exports = e(require("../layout-mode"), require("masonry-layout")) : e(t.Isotope.LayoutMode, t.Masonry) 4720}(window, function(t, e) { 4721 "use strict"; 4722 var i = t.create("masonry") 4723 , n = i.prototype._getElementOffset 4724 , s = i.prototype.layout 4725 , o = i.prototype._getMeasurement; 4726 (function(t, e) { 4727 for (var i in e) 4728 t[i] = e[i] 4729 } 4730 )(i.prototype, e.prototype), 4731 i.prototype._getElementOffset = n, 4732 i.prototype.layout = s, 4733 i.prototype._getMeasurement = o; 4734 var r = i.prototype.measureColumns; 4735 i.prototype.measureColumns = function() { 4736 this.items = this.isotope.filteredItems, 4737 r.call(this) 4738 } 4739 ; 4740 var a = i.prototype._manageStamp; 4741 return i.prototype._manageStamp = function() { 4742 this.options.isOriginLeft = this.isotope.options.isOriginLeft, 4743 this.options.isOriginTop = this.isotope.options.isOriginTop, 4744 a.apply(this, arguments) 4745 } 4746 , 4747 i 4748}), 4749function(t, e) { 4750 "use strict"; 4751 "function" == typeof define && define.amd ? define("isotope/js/layout-modes/fit-rows", ["../layout-mode"], e) : "object" == typeof exports ? module.exports = e(require("../layout-mode")) : e(t.Isotope.LayoutMode) 4752}(window, function(t) { 4753 "use strict"; 4754 var e = t.create("fitRows"); 4755 return e.prototype._resetLayout = function() { 4756 this.x = 0, 4757 this.y = 0, 4758 this.maxY = 0, 4759 this._getMeasurement("gutter", "outerWidth") 4760 } 4761 , 4762 e.prototype._getItemLayoutPosition = function(t) { 4763 t.getSize(); 4764 var e = t.size.outerWidth + this.gutter 4765 , i = this.isotope.size.innerWidth + this.gutter; 4766 0 !== this.x && e + this.x > i && (this.x = 0, 4767 this.y = this.maxY); 4768 var n = { 4769 x: this.x, 4770 y: this.y 4771 }; 4772 return this.maxY = Math.max(this.maxY, this.y + t.size.outerHeight), 4773 this.x += e, 4774 n 4775 } 4776 , 4777 e.prototype._getContainerSize = function() { 4778 return { 4779 height: this.maxY 4780 } 4781 } 4782 , 4783 e 4784}), 4785function(t, e) { 4786 "use strict"; 4787 "function" == typeof define && define.amd ? define("isotope/js/layout-modes/vertical", ["../layout-mode"], e) : "object" == typeof exports ? module.exports = e(require("../layout-mode")) : e(t.Isotope.LayoutMode) 4788}(window, function(t) { 4789 "use strict"; 4790 var e = t.create("vertical", { 4791 horizontalAlignment: 0 4792 }); 4793 return e.prototype._resetLayout = function() { 4794 this.y = 0 4795 } 4796 , 4797 e.prototype._getItemLayoutPosition = function(t) { 4798 t.getSize(); 4799 var e = (this.isotope.size.innerWidth - t.size.outerWidth) * this.options.horizontalAlignment 4800 , i = this.y; 4801 return this.y += t.size.outerHeight, 4802 { 4803 x: e, 4804 y: i 4805 } 4806 } 4807 , 4808 e.prototype._getContainerSize = function() { 4809 return { 4810 height: this.y 4811 } 4812 } 4813 , 4814 e 4815}), 4816function(r, a) { 4817 "use strict"; 4818 "function" == typeof define && define.amd ? define(["outlayer/outlayer", "get-size/get-size", "matches-selector/matches-selector", "fizzy-ui-utils/utils", "isotope/js/item", "isotope/js/layout-mode", "isotope/js/layout-modes/masonry", "isotope/js/layout-modes/fit-rows", "isotope/js/layout-modes/vertical"], function(t, e, i, n, s, o) { 4819 return a(r, t, e, i, n, s, o) 4820 }) : "object" == typeof exports ? module.exports = a(r, require("outlayer"), require("get-size"), require("desandro-matches-selector"), require("fizzy-ui-utils"), require("./item"), require("./layout-mode"), require("./layout-modes/masonry"), require("./layout-modes/fit-rows"), require("./layout-modes/vertical")) : r.Isotope = a(r, r.Outlayer, r.getSize, r.matchesSelector, r.fizzyUIUtils, r.Isotope.Item, r.Isotope.LayoutMode) 4821}(window, function(t, n, e, i, o, s, r) { 4822 var a = t.jQuery 4823 , c = String.prototype.trim ? function(t) { 4824 return t.trim() 4825 } 4826 : function(t) { 4827 return t.replace(/^\s+|\s+$/g, "") 4828 } 4829 , u = document.documentElement.textContent ? function(t) { 4830 return t.textContent 4831 } 4832 : function(t) { 4833 return t.innerText 4834 } 4835 , h = n.create("isotope", { 4836 layoutMode: "masonry", 4837 isJQueryFiltering: !0, 4838 sortAscending: !0 4839 }); 4840 h.Item = s, 4841 h.LayoutMode = r, 4842 h.prototype._create = function() { 4843 for (var t in this.itemGUID = 0, 4844 this._sorters = {}, 4845 this._getSorters(), 4846 n.prototype._create.call(this), 4847 this.modes = {}, 4848 this.filteredItems = this.items, 4849 this.sortHistory = ["original-order"], 4850 r.modes) 4851 this._initLayoutMode(t) 4852 } 4853 , 4854 h.prototype.reloadItems = function() { 4855 this.itemGUID = 0, 4856 n.prototype.reloadItems.call(this) 4857 } 4858 , 4859 h.prototype._itemize = function() { 4860 for (var t = n.prototype._itemize.apply(this, arguments), e = 0, i = t.length; e < i; e++) { 4861 t[e].id = this.itemGUID++ 4862 } 4863 return this._updateItemsSortData(t), 4864 t 4865 } 4866 , 4867 h.prototype._initLayoutMode = function(t) { 4868 var e = r.modes[t] 4869 , i = this.options[t] || {}; 4870 this.options[t] = e.options ? o.extend(e.options, i) : i, 4871 this.modes[t] = new e(this) 4872 } 4873 , 4874 h.prototype.layout = function() { 4875 return !this._isLayoutInited && this.options.isInitLayout ? void this.arrange() : void this._layout() 4876 } 4877 , 4878 h.prototype._layout = function() { 4879 var t = this._getIsInstant(); 4880 this._resetLayout(), 4881 this._manageStamps(), 4882 this.layoutItems(this.filteredItems, t), 4883 this._isLayoutInited = !0 4884 } 4885 , 4886 h.prototype.arrange = function(t) { 4887 function e() { 4888 n.reveal(i.needReveal), 4889 n.hide(i.needHide) 4890 } 4891 this.option(t), 4892 this._getIsInstant(); 4893 var i = this._filter(this.items); 4894 this.filteredItems = i.matches; 4895 var n = this; 4896 this._bindArrangeComplete(), 4897 this._isInstant ? this._noTransition(e) : e(), 4898 this._sort(), 4899 this._layout() 4900 } 4901 , 4902 h.prototype._init = h.prototype.arrange, 4903 h.prototype._getIsInstant = function() { 4904 var t = void 0 !== this.options.isLayoutInstant ? this.options.isLayoutInstant : !this._isLayoutInited; 4905 return this._isInstant = t 4906 } 4907 , 4908 h.prototype._bindArrangeComplete = function() { 4909 function t() { 4910 e && i && n && s.dispatchEvent("arrangeComplete", null, [s.filteredItems]) 4911 } 4912 var e, i, n, s = this; 4913 this.once("layoutComplete", function() { 4914 e = !0, 4915 t() 4916 }), 4917 this.once("hideComplete", function() { 4918 i = !0, 4919 t() 4920 }), 4921 this.once("revealComplete", function() { 4922 n = !0, 4923 t() 4924 }) 4925 } 4926 , 4927 h.prototype._filter = function(t) { 4928 var e = this.options.filter; 4929 e = e || "*"; 4930 for (var i = [], n = [], s = [], o = this._getFilterTest(e), r = 0, a = t.length; r < a; r++) { 4931 var l = t[r]; 4932 if (!l.isIgnored) { 4933 var c = o(l); 4934 c && i.push(l), 4935 c && l.isHidden ? n.push(l) : c || l.isHidden || s.push(l) 4936 } 4937 } 4938 return { 4939 matches: i, 4940 needReveal: n, 4941 needHide: s 4942 } 4943 } 4944 , 4945 h.prototype._getFilterTest = function(e) { 4946 return a && this.options.isJQueryFiltering ? function(t) { 4947 return a(t.element).is(e) 4948 } 4949 : "function" == typeof e ? function(t) { 4950 return e(t.element) 4951 } 4952 : function(t) { 4953 return i(t.element, e) 4954 } 4955 } 4956 , 4957 h.prototype.updateSortData = function(t) { 4958 var e; 4959 t ? (t = o.makeArray(t), 4960 e = this.getItems(t)) : e = this.items, 4961 this._getSorters(), 4962 this._updateItemsSortData(e) 4963 } 4964 , 4965 h.prototype._getSorters = function() { 4966 var t = this.options.getSortData; 4967 for (var e in t) { 4968 var i = t[e]; 4969 this._sorters[e] = l(i) 4970 } 4971 } 4972 , 4973 h.prototype._updateItemsSortData = function(t) { 4974 for (var e = t && t.length, i = 0; e && i < e; i++) { 4975 t[i].updateSortData() 4976 } 4977 } 4978 ; 4979 var l = function(t) { 4980 if ("string" != typeof t) 4981 return t; 4982 var e, i, n = c(t).split(" "), s = n[0], o = s.match(/^\[(.+)\]$/), r = o && o[1], a = (i = s, 4983 (e = r) ? function(t) { 4984 return t.getAttribute(e) 4985 } 4986 : function(t) { 4987 var e = t.querySelector(i); 4988 return e && u(e) 4989 } 4990 ), l = h.sortDataParsers[n[1]]; 4991 return l ? function(t) { 4992 return t && l(a(t)) 4993 } 4994 : function(t) { 4995 return t && a(t) 4996 } 4997 }; 4998 h.sortDataParsers = { 4999 parseInt: function(t) { 5000 return parseInt(t, 10) 5001 }, 5002 parseFloat: function(t) { 5003 return parseFloat(t) 5004 } 5005 }, 5006 h.prototype._sort = function() { 5007 var a, l, t = this.options.sortBy; 5008 if (t) { 5009 var e = [].concat.apply(t, this.sortHistory) 5010 , i = (a = e, 5011 l = this.options.sortAscending, 5012 function(t, e) { 5013 for (var i = 0, n = a.length; i < n; i++) { 5014 var s = a[i] 5015 , o = t.sortData[s] 5016 , r = e.sortData[s]; 5017 if (r < o || o < r) 5018 return (r < o ? 1 : -1) * ((void 0 !== l[s] ? l[s] : l) ? 1 : -1) 5019 } 5020 return 0 5021 } 5022 ); 5023 this.filteredItems.sort(i), 5024 t != this.sortHistory[0] && this.sortHistory.unshift(t) 5025 } 5026 } 5027 , 5028 h.prototype._mode = function() { 5029 var t = this.options.layoutMode 5030 , e = this.modes[t]; 5031 if (!e) 5032 throw new Error("No layout mode: " + t); 5033 return e.options = this.options[t], 5034 e 5035 } 5036 , 5037 h.prototype._resetLayout = function() { 5038 n.prototype._resetLayout.call(this), 5039 this._mode()._resetLayout() 5040 } 5041 , 5042 h.prototype._getItemLayoutPosition = function(t) { 5043 return this._mode()._getItemLayoutPosition(t) 5044 } 5045 , 5046 h.prototype._manageStamp = function(t) { 5047 this._mode()._manageStamp(t) 5048 } 5049 , 5050 h.prototype._getContainerSize = function() { 5051 return this._mode()._getContainerSize() 5052 } 5053 , 5054 h.prototype.needsResizeLayout = function() { 5055 return this._mode().needsResizeLayout() 5056 } 5057 , 5058 h.prototype.appended = function(t) { 5059 var e = this.addItems(t); 5060 if (e.length) { 5061 var i = this._filterRevealAdded(e); 5062 this.filteredItems = this.filteredItems.concat(i) 5063 } 5064 } 5065 , 5066 h.prototype.prepended = function(t) { 5067 var e = this._itemize(t); 5068 if (e.length) { 5069 this._resetLayout(), 5070 this._manageStamps(); 5071 var i = this._filterRevealAdded(e); 5072 this.layoutItems(this.filteredItems), 5073 this.filteredItems = i.concat(this.filteredItems), 5074 this.items = e.concat(this.items) 5075 } 5076 } 5077 , 5078 h.prototype._filterRevealAdded = function(t) { 5079 var e = this._filter(t); 5080 return this.hide(e.needHide), 5081 this.reveal(e.matches), 5082 this.layoutItems(e.matches, !0), 5083 e.matches 5084 } 5085 , 5086 h.prototype.insert = function(t) { 5087 var e = this.addItems(t); 5088 if (e.length) { 5089 var i, n, s = e.length; 5090 for (i = 0; i < s; i++) 5091 n = e[i], 5092 this.element.appendChild(n.element); 5093 var o = this._filter(e).matches; 5094 for (i = 0; i < s; i++) 5095 e[i].isLayoutInstant = !0; 5096 for (this.arrange(), 5097 i = 0; i < s; i++) 5098 delete e[i].isLayoutInstant; 5099 this.reveal(o) 5100 } 5101 } 5102 ; 5103 var d = h.prototype.remove; 5104 return h.prototype.remove = function(t) { 5105 t = o.makeArray(t); 5106 var e = this.getItems(t); 5107 d.call(this, t); 5108 var i = e && e.length; 5109 if (i) 5110 for (var n = 0; n < i; n++) { 5111 var s = e[n]; 5112 o.removeFrom(this.filteredItems, s) 5113 } 5114 } 5115 , 5116 h.prototype.shuffle = function() { 5117 for (var t = 0, e = this.items.length; t < e; t++) { 5118 this.items[t].sortData.random = Math.random() 5119 } 5120 this.options.sortBy = "random", 5121 this._sort(), 5122 this._layout() 5123 } 5124 , 5125 h.prototype._noTransition = function(t) { 5126 var e = this.options.transitionDuration; 5127 this.options.transitionDuration = 0; 5128 var i = t.call(this); 5129 return this.options.transitionDuration = e, 5130 i 5131 } 5132 , 5133 h.prototype.getFilteredItemElements = function() { 5134 for (var t = [], e = 0, i = this.filteredItems.length; e < i; e++) 5135 t.push(this.filteredItems[e].element); 5136 return t 5137 } 5138 , 5139 h 5140}), 5141eval(function(t, e, i, n, s, o) { 5142 if (s = function(t) { 5143 return (t < 62 ? "" : s(parseInt(t / 62))) + (35 < (t %=
514362) ? String.fromCharCode(t + 29) : t.toString(36)) 5144 } 5145 , 5146 !"".replace(/^/, String)) { 5147 for (; i--; ) 5148 o[s(i)] = n[i] || s(i); 5149 n = [function(t) { 5150 return o[t] 5151 } 5152 ], 5153 s = function() { 5154 return "\\w+" 5155 } 5156 , 5157 i = 1 5158 } 5159 for (; i--; ) 5160 n[i] && (t = t.replace(new RegExp("\\b" + s(i) + "\\b","g"), n[i])); 5161 return t 5162}('7(A 3c.3q!=="9"){3c.3q=9(e){9 t(){}t.5S=e;p 5R t}}(9(e,t,n){h r={1N:9(t,n){h r=c;r.$k=e(n);r.6=e.4M({},e.37.2B.6,r.$k.v(),t);r.2A=t;r.4L()},4L:9(){9 r(e){h n,r="";7(A t.6.33==="9"){t.6.33.R(c,[e])}l{1A(n 38 e.d){7(e.d.5M(n)){r+=e.d[n].1K}}t.$k.2y(r)}t.3t()}h t=c,n;7(A t.6.2H==="9"){t.6.2H.R(c,[t.$k])}7(A t.6.2O==="2Y"){n=t.6.2O;e.5K(n,r)}l{t.3t()}},3t:9(){h e=c;e.$k.v("d-4I",e.$k.2x("2w")).v("d-4F",e.$k.2x("H"));e.$k.z({2u:0});e.2t=e.6.q;e.4E();e.5v=0;e.1X=14;e.23()},23:9(){h e=c;7(e.$k.25().N===0){p b}e.1M();e.4C();e.$S=e.$k.25();e.E=e.$S.N;e.4B();e.$G=e.$k.17(".d-1K");e.$K=e.$k.17(".d-1p");e.3u="U";e.13=0;e.26=[0];e.m=0;e.4A();e.4z()},4z:9(){h e=c;e.2V();e.2W();e.4t();e.30();e.4r();e.4q();e.2p();e.4o();7(e.6.2o!==b){e.4n(e.6.2o)}7(e.6.O===j){e.6.O=4Q}e.19();e.$k.17(".d-1p").z("4i","4h");7(!e.$k.2m(":3n")){e.3o()}l{e.$k.z("2u",1)}e.5O=b;e.2l();7(A e.6.3s==="9"){e.6.3s.R(c,[e.$k])}},2l:9(){h e=c;7(e.6.1Z===j){e.1Z()}7(e.6.1B===j){e.1B()}e.4g();7(A e.6.3w==="9"){e.6.3w.R(c,[e.$k])}},3x:9(){h e=c;7(A e.6.3B==="9"){e.6.3B.R(c,[e.$k])}e.3o();e.2V();e.2W();e.4f();e.30();e.2l();7(A e.6.3D==="9"){e.6.3D.R(c,[e.$k])}},3F:9(){h e=c;t.1c(9(){e.3x()},0)},3o:9(){h e=c;7(e.$k.2m(":3n")===b){e.$k.z({2u:0});t.18(e.1C);t.18(e.1X)}l{p b}e.1X=t.4d(9(){7(e.$k.2m(":3n")){e.3F();e.$k.4b({2u:1},2M);t.18(e.1X)}},5x)},4B:9(){h e=c;e.$S.5n(\'<L H="d-1p">\').4a(\'<L H="d-1K"></L>\');e.$k.17(".d-1p").4a(\'<L H="d-1p-49">\');e.1H=e.$k.17(".d-1p-49");e.$k.z("4i","4h")},1M:9(){h e=c,t=e.$k.1I(e.6.1M),n=e.$k.1I(e.6.2i);7(!t){e.$k.I(e.6.1M)}7(!n){e.$k.I(e.6.2i)}},2V:9(){h t=c,n,r;7(t.6.2Z===b){p b}7(t.6.48===j){t.6.q=t.2t=1;t.6.1h=b;t.6.1s=b;t.6.1O=b;t.6.22=b;t.6.1Q=b;t.6.1R=b;p b}n=e(t.6.47).1f();7(n>(t.6.1s[0]||t.2t)){t.6.q=t.2t}7(t.6.1h!==b){t.6.1h.5g(9(e,t){p e[0]-t[0]});1A(r=0;r<t.6.1h.N;r+=1){7(t.6.1h[r][0]<=n){t.6.q=t.6.1h[r][1]}}}l{7(n<=t.6.1s[0]&&t.6.1s!==b){t.6.q=t.6.1s[1]}7(n<=t.6.1O[0]&&t.6.1O!==b){t.6.q=t.6.1O[1]}7(n<=t.6.22[0]&&t.6.22!==b){t.6.q=t.6.22[1]}7(n<=t.6.1Q[0]&&t.6.1Q!==b){t.6.q=t.6.1Q[1]}7(n<=t.6.1R[0]&&t.6.1R!==b){t.6.q=t.6.1R[1]}}7(t.6.q>t.E&&t.6.46===j){t.6.q=t.E}},4r:9(){h n=c,r,i;7(n.6.2Z!==j){p b}i=e(t).1f();n.3d=9(){7(e(t).1f()!==i){7(n.6.O!==b){t.18(n.1C)}t.5d(r);r=t.1c(9(){i=e(t).1f();n.3x()},n.6.45)}};e(t).44(n.3d)},4f:9(){h e=c;e.2g(e.m);7(e.6.O!==b){e.3j()}},43:9(){h t=c,n=0,r=t.E-t.6.q;t.$G.2f(9(i){h s=e(c);s.z({1f:t.M}).v("d-1K",3p(i));7(i%t.6.q===0||i===r){7(!(i>r)){n+=1}}s.v("d-24",n)})},42:9(){h e=c,t=e.$G.N*e.M;e.$K.z({1f:t*2,T:0});e.43()},2W:9(){h e=c;e.40();e.42();e.3Z();e.3v()},40:9(){h e=c;e.M=1F.4O(e.$k.1f()/e.6.q)},3v:9(){h e=c,t=(e.E*e.M-e.6.q*e.M)*-1;7(e.6.q>e.E){e.D=0;t=0;e.3z=0}l{e.D=e.E-e.6.q;e.3z=t}p t},3Y:9(){p 0},3Z:9(){h t=c,n=0,r=0,i,s,o;t.J=[0];t.3E=[];1A(i=0;i<t.E;i+=1){r+=t.M;t.J.2D(-r);7(t.6.12===j){s=e(t.$G[i]);o=s.v("d-24");7(o!==n){t.3E[n]=t.J[i];n=o}}}},4t:9(){h t=c;7(t.6.2a===j||t.6.1v===j){t.B=e(\'<L H="d-5A"/>\').5m("5l",!t.F.15).5c(t.$k)}7(t.6.1v===j){t.3T()}7(t.6.2a===j){t.3S()}},3S:9(){h t=c,n=e(\'<L H="d-4U"/>\');t.B.1o(n);t.1u=e("<L/>",{"H":"d-1n",2y:t.6.2U[0]||""});t.1q=e("<L/>",{"H":"d-U",2y:t.6.2U[1]||""});n.1o(t.1u).1o(t.1q);n.w("2X.B 21.B",\'L[H^="d"]\',9(e){e.1l()});n.w("2n.B 28.B",\'L[H^="d"]\',9(n){n.1l();7(e(c).1I("d-U")){t.U()}l{t.1n()}})},3T:9(){h t=c;t.1k=e(\'<L H="d-1v"/>\');t.B.1o(t.1k);t.1k.w("2n.B 28.B",".d-1j",9(n){n.1l();7(3p(e(c).v("d-1j"))!==t.m){t.1g(3p(e(c).v("d-1j")),j)}})},3P:9(){h t=c,n,r,i,s,o,u;7(t.6.1v===b){p b}t.1k.2y("");n=0;r=t.E-t.E%t.6.q;1A(s=0;s<t.E;s+=1){7(s%t.6.q===0){n+=1;7(r===s){i=t.E-t.6.q}o=e("<L/>",{"H":"d-1j"});u=e("<3N></3N>",{4R:t.6.39===j?n:"","H":t.6.39===j?"d-59":""});o.1o(u);o.v("d-1j",r===s?i:s);o.v("d-24",n);t.1k.1o(o)}}t.35()},35:9(){h t=c;7(t.6.1v===b){p b}t.1k.17(".d-1j").2f(9(){7(e(c).v("d-24")===e(t.$G[t.m]).v("d-24")){t.1k.17(".d-1j").Z("2d");e(c).I("2d")}})},3e:9(){h e=c;7(e.6.2a===b){p b}7(e.6.2e===b){7(e.m===0&&e.D===0){e.1u.I("1b");e.1q.I("1b")}l 7(e.m===0&&e.D!==0){e.1u.I("1b");e.1q.Z("1b")}l 7(e.m===e.D){e.1u.Z("1b");e.1q.I("1b")}l 7(e.m!==0&&e.m!==e.D){e.1u.Z("1b");e.1q.Z("1b")}}},30:9(){h e=c;e.3P();e.3e();7(e.B){7(e.6.q>=e.E){e.B.3K()}l{e.B.3J()}}},55:9(){h e=c;7(e.B){e.B.3k()}},U:9(e){h t=c;7(t.1E){p b}t.m+=t.6.12===j?t.6.q:1;7(t.m>t.D+(t.6.12===j?t.6.q-1:0)){7(t.6.2e===j){t.m=0;e="2k"}l{t.m=t.D;p b}}t.1g(t.m,e)},1n:9(e){h t=c;7(t.1E){p b}7(t.6.12===j&&t.m>0&&t.m<t.6.q){t.m=0}l{t.m-=t.6.12===j?t.6.q:1}7(t.m<0){7(t.6.2e===j){t.m=t.D;e="2k"}l{t.m=0;p b}}t.1g(t.m,e)},1g:9(e,n,r){h i=c,s;7(i.1E){p b}7(A i.6.1Y==="9"){i.6.1Y.R(c,[i.$k])}7(e>=i.D){e=i.D}l 7(e<=0){e=0}i.m=i.d.m=e;7(i.6.2o!==b&&r!=="4e"&&i.6.q===1&&i.F.1x===j){i.1t(0);7(i.F.1x===j){i.1L(i.J[e])}l{i.1r(i.J[e],1)}i.2r();i.4l();p b}s=i.J[e];7(i.F.1x===j){i.1T=b;7(n===j){i.1t("1w");t.1c(9(){i.1T=j},i.6.1w)}l 7(n==="2k"){i.1t(i.6.2v);t.1c(9(){i.1T=j},i.6.2v)}l{i.1t("1m");t.1c(9(){i.1T=j},i.6.1m)}i.1L(s)}l{7(n===j){i.1r(s,i.6.1w)}l 7(n==="2k"){i.1r(s,i.6.2v)}l{i.1r(s,i.6.1m)}}i.2r()},2g:9(e){h t=c;7(A t.6.1Y==="9"){t.6.1Y.R(c,[t.$k])}7(e>=t.D||e===-1){e=t.D}l 7(e<=0){e=0}t.1t(0);7(t.F.1x===j){t.1L(t.J[e])}l{t.1r(t.J[e],1)}t.m=t.d.m=e;t.2r()},2r:9(){h e=c;e.26.2D(e.m);e.13=e.d.13=e.26[e.26.N-2];e.26.5f(0);7(e.13!==e.m){e.35();e.3e();e.2l();7(e.6.O!==b){e.3j()}}7(A e.6.3y==="9"&&e.13!==e.m){e.6.3y.R(c,[e.$k])}},X:9(){h e=c;e.3A="X";t.18(e.1C)},3j:9(){h e=c;7(e.3A!=="X"){e.19()}},19:9(){h e=c;e.3A="19";7(e.6.O===b){p b}t.18(e.1C);e.1C=t.4d(9(){e.U(j)},e.6.O)},1t:9(e){h t=c;7(e==="1m"){t.$K.z(t.2z(t.6.1m))}l 7(e==="1w"){t.$K.z(t.2z(t.6.1w))}l 7(A e!=="2Y"){t.$K.z(t.2z(e))}},2z:9(e){p{"-1G-1a":"2C "+e+"1z 2s","-1W-1a":"2C "+e+"1z 2s","-o-1a":"2C "+e+"1z 2s",1a:"2C "+e+"1z 2s"}},3H:9(){p{"-1G-1a":"","-1W-1a":"","-o-1a":"",1a:""}},3I:9(e){p{"-1G-P":"1i("+e+"V, C, C)","-1W-P":"1i("+e+"V, C, C)","-o-P":"1i("+e+"V, C, C)","-1z-P":"1i("+e+"V, C, C)",P:"1i("+e+"V, C,C)"}},1L:9(e){h t=c;t.$K.z(t.3I(e))},3L:9(e){h t=c;t.$K.z({T:e})},1r:9(e,t){h n=c;n.29=b;n.$K.X(j,j).4b({T:e},{54:t||n.6.1m,3M:9(){n.29=j}})}
5162,4E:9(){h e=c,r="1i(C, C, C)",i=n.56("L"),s,o,u,a;i.2w.3O=" -1W-P:"+r+"; -1z-P:"+r+"; -o-P:"+r+"; -1G-P:"+r+"; P:"+r;s=/1i\\(C, C, C\\)/g;o=i.2w.3O.5i(s);u=o!==14&&o.N===1;a="5z"38 t||t.5Q.4P;e.F={1x:u,15:a}},4q:9(){h e=c;7(e.6.27!==b||e.6.1U!==b){e.3Q();e.3R()}},4C:9(){h e=c,t=["s","e","x"];e.16={};7(e.6.27===j&&e.6.1U===j){t=["2X.d 21.d","2N.d 3U.d","2n.d 3V.d 28.d"]}l 7(e.6.27===b&&e.6.1U===j){t=["2X.d","2N.d","2n.d 3V.d"]}l 7(e.6.27===j&&e.6.1U===b){t=["21.d","3U.d","28.d"]}e.16.3W=t[0];e.16.2K=t[1];e.16.2J=t[2]},3R:9(){h t=c;t.$k.w("5y.d",9(e){e.1l()});t.$k.w("21.3X",9(t){p e(t.1d).2m("5C, 5E, 5F, 5N")})},3Q:9(){9 s(e){7(e.2b!==W){p{x:e.2b[0].2c,y:e.2b[0].41}}7(e.2b===W){7(e.2c!==W){p{x:e.2c,y:e.41}}7(e.2c===W){p{x:e.52,y:e.53}}}}9 o(t){7(t==="w"){e(n).w(r.16.2K,a);e(n).w(r.16.2J,f)}l 7(t==="Q"){e(n).Q(r.16.2K);e(n).Q(r.16.2J)}}9 u(n){h u=n.3h||n||t.3g,a;7(u.5a===3){p b}7(r.E<=r.6.q){p}7(r.29===b&&!r.6.3f){p b}7(r.1T===b&&!r.6.3f){p b}7(r.6.O!==b){t.18(r.1C)}7(r.F.15!==j&&!r.$K.1I("3b")){r.$K.I("3b")}r.11=0;r.Y=0;e(c).z(r.3H());a=e(c).2h();i.2S=a.T;i.2R=s(u).x-a.T;i.2P=s(u).y-a.5o;o("w");i.2j=b;i.2L=u.1d||u.4c}9 a(o){h u=o.3h||o||t.3g,a,f;r.11=s(u).x-i.2R;r.2I=s(u).y-i.2P;r.Y=r.11-i.2S;7(A r.6.2E==="9"&&i.3C!==j&&r.Y!==0){i.3C=j;r.6.2E.R(r,[r.$k])}7((r.Y>8||r.Y<-8)&&r.F.15===j){7(u.1l!==W){u.1l()}l{u.5L=b}i.2j=j}7((r.2I>10||r.2I<-10)&&i.2j===b){e(n).Q("2N.d")}a=9(){p r.Y/5};f=9(){p r.3z+r.Y/5};r.11=1F.3v(1F.3Y(r.11,a()),f());7(r.F.1x===j){r.1L(r.11)}l{r.3L(r.11)}}9 f(n){h s=n.3h||n||t.3g,u,a,f;s.1d=s.1d||s.4c;i.3C=b;7(r.F.15!==j){r.$K.Z("3b")}7(r.Y<0){r.1y=r.d.1y="T"}l{r.1y=r.d.1y="3i"}7(r.Y!==0){u=r.4j();r.1g(u,b,"4e");7(i.2L===s.1d&&r.F.15!==j){e(s.1d).w("3a.4k",9(t){t.4S();t.4T();t.1l();e(t.1d).Q("3a.4k")});a=e.4N(s.1d,"4V").3a;f=a.4W();a.4X(0,0,f)}}o("Q")}h r=c,i={2R:0,2P:0,4Y:0,2S:0,2h:14,4Z:14,50:14,2j:14,51:14,2L:14};r.29=j;r.$k.w(r.16.3W,".d-1p",u)},4j:9(){h e=c,t=e.4m();7(t>e.D){e.m=e.D;t=e.D}l 7(e.11>=0){t=0;e.m=0}p t},4m:9(){h t=c,n=t.6.12===j?t.3E:t.J,r=t.11,i=14;e.2f(n,9(s,o){7(r-t.M/20>n[s+1]&&r-t.M/20<o&&t.34()==="T"){i=o;7(t.6.12===j){t.m=e.4p(i,t.J)}l{t.m=s}}l 7(r+t.M/20<o&&r+t.M/20>(n[s+1]||n[s]-t.M)&&t.34()==="3i"){7(t.6.12===j){i=n[s+1]||n[n.N-1];t.m=e.4p(i,t.J)}l{i=n[s+1];t.m=s+1}
5162}});p t.m},34:9(){h e=c,t;7(e.Y<0){t="3i";e.3u="U"}l{t="T";e.3u="1n"}p t},4A:9(){h e=c;e.$k.w("d.U",9(){e.U()});e.$k.w("d.1n",9(){e.1n()});e.$k.w("d.19",9(t,n){e.6.O=n;e.19();e.32="19"});e.$k.w("d.X",9(){e.X();e.32="X"});e.$k.w("d.1g",9(t,n){e.1g(n)});e.$k.w("d.2g",9(t,n){e.2g(n)})},2p:9(){h e=c;7(e.6.2p===j&&e.F.15!==j&&e.6.O!==b){e.$k.w("57",9(){e.X()});e.$k.w("58",9(){7(e.32!=="X"){e.19()}})}},1Z:9(){h t=c,n,r,i,s,o;7(t.6.1Z===b){p b}1A(n=0;n<t.E;n+=1){r=e(t.$G[n]);7(r.v("d-1e")==="1e"){4s}i=r.v("d-1K");s=r.17(".5b");7(A s.v("1J")!=="2Y"){r.v("d-1e","1e");4s}7(r.v("d-1e")===W){s.3K();r.I("4u").v("d-1e","5e")}7(t.6.4v===j){o=i>=t.m}l{o=j}7(o&&i<t.m+t.6.q&&s.N){t.4w(r,s)}}},4w:9(e,n){9 o(){e.v("d-1e","1e").Z("4u");n.5h("v-1J");7(r.6.4x==="4y"){n.5j(5k)}l{n.3J()}7(A r.6.2T==="9"){r.6.2T.R(c,[r.$k])}}9 u(){i+=1;7(r.2Q(n.3l(0))||s===j){o()}l 7(i<=2q){t.1c(u,2q)}l{o()}}h r=c,i=0,s;7(n.5p("5q")==="5r"){n.z("5s-5t","5u("+n.v("1J")+")");s=j}l{n[0].1J=n.v("1J")}u()},1B:9(){9 s(){h r=e(n.$G[n.m]).2G();n.1H.z("2G",r+"V");7(!n.1H.1I("1B")){t.1c(9(){n.1H.I("1B")},0)}}9 o(){i+=1;7(n.2Q(r.3l(0))){s()}l 7(i<=2q){t.1c(o,2q)}l{n.1H.z("2G","")}}h n=c,r=e(n.$G[n.m]).17("5w"),i;7(r.3l(0)!==W){i=0;o()}l{s()}},2Q:9(e){h t;7(!e.3M){p b}t=A e.4D;7(t!=="W"&&e.4D===0){p b}p j},4g:9(){h t=c,n;7(t.6.2F===j){t.$G.Z("2d")}t.1D=[];1A(n=t.m;n<t.m+t.6.q;n+=1){t.1D.2D(n);7(t.6.2F===j){e(t.$G[n]).I("2d")}}t.d.1D=t.1D},4n:9(e){h t=c;t.4G="d-"+e+"-5B";t.4H="d-"+e+"-38"},4l:9(){9 a(e){p{2h:"5D",T:e+"V"}}h e=c,t=e.4G,n=e.4H,r=e.$G.1S(e.m),i=e.$G.1S(e.13),s=1F.4J(e.J[e.m])+e.J[e.13],o=1F.4J(e.J[e.m])+e.M/2,u="5G 5H 5I 5J";e.1E=j;e.$K.I("d-1P").z({"-1G-P-1P":o+"V","-1W-4K-1P":o+"V","4K-1P":o+"V"});i.z(a(s,10)).I(t).w(u,9(){e.3m=j;i.Q(u);e.31(i,t)});r.I(n).w(u,9(){e.36=j;r.Q(u);e.31(r,n)})},31:9(e,t){h n=c;e.z({2h:"",T:""}).Z(t);7(n.3m&&n.36){n.$K.Z("d-1P");n.3m=b;n.36=b;n.1E=b}},4o:9(){h e=c;e.d={2A:e.2A,5P:e.$k,S:e.$S,G:e.$G,m:e.m,13:e.13,1D:e.1D,15:e.F.15,F:e.F,1y:e.1y}},3G:9(){h r=c;r.$k.Q(".d d 21.3X");e(n).Q(".d d");e(t).Q("44",r.3d)},1V:9(){h e=c;7(e.$k.25().N!==0){e.$K.3r();e.$S.3r().3r();7(e.B){e.B.3k()}}e.3G();e.$k.2x("2w",e.$k.v("d-4I")||"").2x("H",e.$k.v("d-4F"))},5T:9(){h e=c;e.X();t.18(e.1X);e.1V();e.$k.5U()},5V:9(t){h n=c,r=e.4M({},n.2A,t);n.1V();n.1N(r,n.$k)},5W:9(e,t){h n=c,r;7(!e){p b}7(n.$k.25().N===0){n.$k.1o(e);n.23();p b}n.1V();7(t===W||t===-1){r=-1}l{r=t}7(r>=n.$S.N||r===-1){n.$S.1S(-1).5X(e)}l{n.$S.1S(r).5Y(e)}n.23()},5Z:9(e){h t=c,n;7(t.$k.25().N===0){p b}7(e===W||e===-1){n=-1}l{n=e}t.1V();t.$S.1S(n).3k();t.23()}};e.37.2B=9(t){p c.2f(9(){7(e(c).v("d-1N")===j){p b}e(c).v("d-1N",j);h n=3c.3q(r);n.1N(t,c);e.v(c,"2B",n)})};e.37.2B.6={q:5,1h:b,1s:[60,4],1O:[61,3],22:[62,2],1Q:b,1R:[63,1],48:b,46:b,1m:2M,1w:64,2v:65,O:b,2p:b,2a:b,2U:["1n","U"],2e:j,12:b,1v:j,39:b,2Z:j,45:2M,47:t,1M:"d-66",2i:"d-2i",1Z:b,4v:j,4x:"4y",1B:b,2O:b,33:b,3f:j,27:j,1U:j,2F:b,2o:b,3B:b,3D:b,2H:b,3s:b,1Y:b,3y:b,3w:b,2E:b,2T:b}})(67,68,69)', 0, 382, "||||||options|if||function||false|this|owl||||var||true|elem|else|currentItem|||return|items|||||data|on|||css|typeof|owlControls|0px|maximumItem|itemsAmount|browser|owlItems|class|addClass|positionsInArray|owlWrapper|div|itemWidth|length|autoPlay|transform|off|apply|userItems|left|next|px|undefined|stop|newRelativeX|removeClass||newPosX|scrollPerPage|prevItem|null|isTouch|ev_types|find|clearInterval|play|transition|disabled|setTimeout|target|loaded|width|goTo|itemsCustom|translate3d|page|paginationWrapper|preventDefault|slideSpeed|prev|append|wrapper|buttonNext|css2slide|itemsDesktop|swapSpeed|buttonPrev|pagination|paginationSpeed|support3d|dragDirection|ms|for|autoHeight|autoPlayInterval|visibleItems|isTransition|Math|webkit|wrapperOuter|hasClass|src|item|transition3d|baseClass|init|itemsDesktopSmall|origin|itemsTabletSmall|itemsMobile|eq|isCss3Finish|touchDrag|unWrap|moz|checkVisible|beforeMove|lazyLoad||mousedown|itemsTablet|setVars|roundPages|children|prevArr|mouseDrag|mouseup|isCssFinish|navigation|touches|pageX|active|rewindNav|each|jumpTo|position|theme|sliding|rewind|eachMoveUpdate|is|touchend|transitionStyle|stopOnHover|100|afterGo|ease|orignalItems|opacity|rewindSpeed|style|attr|html|addCssSpeed|userOptions|owlCarousel|all|push|startDragging|addClassActive|height|beforeInit|newPosY|end|move|targetElement|200|touchmove|jsonPath|offsetY|completeImg|offsetX|relativePos|afterLazyLoad|navigationText|updateItems|calculateAll|touchstart|string|responsive|updateControls|clearTransStyle|hoverStatus|jsonSuccess|moveDirection|checkPagination|endCurrent|fn|in|paginationNumbers|click|grabbing|Object|resizer|checkNavigation|dragBeforeAnimFinish|event|originalEvent|right|checkAp|remove|get|endPrev|visible|watchVisibility|Number|create|unwrap|afterInit|logIn|playDirection|max|afterAction|updateVars|afterMove|maximumPixels|apStatus|beforeUpdate|dragging|afterUpdate|pagesInArray|reload|clearEvents|removeTransition|doTranslate|show|hide|css2move|complete|span|cssText|updatePagination|gestures|disabledEvents|buildButtons|buildPagination|mousemove|touchcancel|start|disableTextSelect|min|loops|calculateWidth|pageY|appendWrapperSizes|appendItemsSizes|resize|responsiveRefreshRate|itemsScaleUp|responsiveBaseWidth|singleItem|outer|wrap|animate|srcElement|setInterval|drag|updatePosition|onVisibleItems|block|display|getNewPosition|disable|singleItemTransition|closestItem|transitionTypes|owlStatus|inArray|moveEvents|response|continue|buildControls|loading|lazyFollow|lazyPreload|lazyEffect|fade|onStartup|customEvents|wrapItems|eventTypes|naturalWi
5162dth|checkBrowser|originalClasses|outClass|inClass|originalStyles|abs|perspective|loadContent|extend|_data|round|msMaxTouchPoints|5e3|text|stopImmediatePropagation|stopPropagation|buttons|events|pop|splice|baseElWidth|minSwipe|maxSwipe|dargging|clientX|clientY|duration|destroyControls|createElement|mouseover|mouseout|numbers|which|lazyOwl|appendTo|clearTimeout|checked|shift|sort|removeAttr|match|fadeIn|400|clickable|toggleClass|wrapAll|top|prop|tagName|DIV|background|image|url|wrapperWidth|img|500|dragstart|ontouchstart|controls|out|input|relative|textarea|select|webkitAnimationEnd|oAnimationEnd|MSAnimationEnd|animationend|getJSON|returnValue|hasOwnProperty|option|onstartup|baseElement|navigator|new|prototype|destroy|removeData|reinit|addItem|after|before|removeItem|1199|979|768|479|800|1e3|carousel|jQuery|window|document".split("|"), 0, {})), 5163function o(r, a, l) { 5164 function c(i, t) { 5165 if (!a[i]) { 5166 if (!r[i]) { 5167 var e = "function" == typeof require && require; 5168 if (!t && e) 5169 return e(i, !0); 5170 if (u) 5171 return u(i, !0); 5172 var n = new Error("Cannot find module '" + i + "'"); 5173 throw n.code = "MODULE_NOT_FOUND", 5174 n 5175 } 5176 var s = a[i] = { 5177 exports: {} 5178 }; 5179 r[i][0].call(s.exports, function(t) { 5180 var e = r[i][1][t]; 5181 return c(e || t) 5182 }, s, s.exports, o, r, a, l) 5183 } 5184 return a[i].exports 5185 } 5186 for (var u = "function" == typeof require && require, t = 0; t < l.length; t++) 5187 c(l[t]); 5188 return c 5189}({ 5190 1: [function(t, e) { 5191 "use strict"; 5192 function i(n) { 5193 n.fn.perfectScrollbar = function(i) { 5194 return this.each(function() { 5195 if ("object" == typeof i || void 0 === i) { 5196 var t = i; 5197 o.get(this) || s.initialize(this, t) 5198 } else { 5199 var e = i; 5200 "update" === e ? s.update(this) : "destroy" === e && s.destroy(this) 5201 } 5202 return n(this) 5203 }) 5204 } 5205 } 5206 var s = t("../main") 5207 , o = t("../plugin/instances"); 5208 if ("function" == typeof define && define.amd) 5209 define(["jquery"], i); 5210 else { 5211 var n = window.jQuery ? window.jQuery : window.$; 5212 void 0 !== n && i(n) 5213 } 5214 e.exports = i 5215 } 5216 , { 5217 "../main": 7, 5218 "../plugin/instances": 18 5219 }], 5220 2: [function(t, e, i) { 5221 "use strict"; 5222 i.add = function(t, e) { 5223 var i, n, s; 5224 t.classList ? t.classList.add(e) : (n = e, 5225 (s = (i = t).className.split(" ")).indexOf(n) < 0 && s.push(n), 5226 i.className = s.join(" ")) 5227 } 5228 , 5229 i.remove = function(t, e) { 5230 var i, n, s, o; 5231 t.classList ? t.classList.remove(e) : (n = e, 5232 s = (i = t).className.split(" "), 5233 0 <= (o = s.indexOf(n)) && s.splice(o, 1), 5234 i.className = s.join(" ")) 5235 } 5236 , 5237 i.list = function(t) { 5238 return t.classList ? Array.prototype.slice.apply(t.classList) : t.className.split(" ") 5239 } 5240 } 5241 , {}], 5242 3: [function(t, e) { 5243 "use strict"; 5244 var i = { 5245 e: function(t, e) { 5246 var i = document.createElement(t); 5247 return i.className = e, 5248 i 5249 }, 5250 appendTo: function(t, e) { 5251 return e.appendChild(t), 5252 t 5253 } 5254 }; 5255 i.css = function(t, e, i) { 5256 return "object" == typeof e ? function(t, e) { 5257 for (var i in e) { 5258 var n = e[i]; 5259 "number" == typeof n && (n = n.toString() + "px"), 5260 t.style[i] = n 5261 } 5262 return t 5263 }(t, e) : void 0 === i ? (r = t, 5264 a = e, 5265 window.getComputedStyle(r)[a]) : (n = t, 5266 s = e, 5267 "number" == typeof (o = i) && (o = o.toString() + "px"), 5268 n.style[s] = o, 5269 n); 5270 var n, s, o, r, a 5271 } 5272 , 5273 i.matches = function(t, e) { 5274 return void 0 !== t.matches ? t.matches(e) : void 0 !== t.matchesSelector ? t.matchesSelector(e) : void 0 !== t.webkitMatchesSelector ? t.webkitMatchesSelector(e) : void 0 !== t.mozMatchesSelector ? t.mozMatchesSelector(e) : void 0 !== t.msMatchesSelector ? t.msMatchesSelector(e) : void 0 5275 } 5276 , 5277 i.remove = function(t) { 5278 void 0 !== t.remove ? t.remove() : t.parentNode && t.parentNode.removeChild(t) 5279 } 5280 , 5281 i.queryChildren = function(t, e) { 5282 return Array.prototype.filter.call(t.childNodes, function(t) { 5283 return i.matches(t, e) 5284 }) 5285 } 5286 , 5287 e.exports = i 5288 } 5289 , {}], 5290 4: [function(t, e) { 5291 "use strict"; 5292 var i = function(t) { 5293 this.element = t, 5294 this.events = {} 5295 }; 5296 i.prototype.bind = function(t, e) { 5297 void 0 === this.events[t] && (this.events[t] = []), 5298 this.events[t].push(e), 5299 this.element.addEventListener(t, e, !1) 5300 } 5301 , 5302 i.prototype.unbind = function(e, i) { 5303 var n = void 0 !== i; 5304 this.events[e] = this.events[e].filter(function(t) { 5305 return !(!n || t === i) || (this.element.removeEventListener(e, t, !1), 5306 !1) 5307 }, this) 5308 } 5309 , 5310 i.prototype.unbindAll = function() { 5311 for (var t in this.events) 5312 this.unbind(t) 5313 } 5314 ; 5315 var n = function() { 5316 this.eventElements = [] 5317 }; 5318 n.prototype.eventElement = function(e) { 5319 var t = this.eventElements.filter(function(t) { 5320 return t.element === e 5321 })[0]; 5322 return void 0 === t && (t = new i(e), 5323 this.eventElements.push(t)), 5324 t 5325 } 5326 , 5327 n.prototype.bind = function(t, e, i) { 5328 this.eventElement(t).bind(e, i) 5329 } 5330 , 5331 n.prototype.unbind = function(t, e, i) { 5332 this.eventElement(t).unbind(e, i) 5333 } 5334 , 5335 n.prototype.unbindAll = function() { 5336 for (var t = 0; t < this.eventElements.length; t++) 5337 this.eventElements[t].unbindAll() 5338 } 5339 , 5340 n.prototype.once = function(t, e, i) { 5341 var n = this.eventElement(t) 5342 , s = function(t) { 5343 n.unbind(e, s), 5344 i(t) 5345 }; 5346 n.bind(e, s) 5347 } 5348 , 5349 e.exports = n 5350 } 5351 , {}], 5352 5: [function(t, e) { 5353 "use strict"; 5354 e.exports = function() { 5355 function t() { 5356 return Math.floor(65536 * (1 + Math.random())).toString(16).substring(1) 5357 } 5358 return function() { 5359 return t() + t() + "-" + t() + "-" + t() + "-" + t() + "-" + t() + t() + t() 5360 } 5361 }() 5362 } 5363 , {}], 5364 6: [function(t, e, i) { 5365 "use strict"; 5366 var s = t("./class") 5367 , n = t("./dom"); 5368 i.toInt = function(t) { 5369 return parseInt(t, 10) || 0 5370 } 5371 , 5372 i.clone = function(t) { 5373 if (null === t) 5374 return null; 5375 if ("object" == typeof t) { 5376 var e = {}; 5377 for (var i in t) 5378 e[i] = this.clone(t[i]); 5379 return e 5380 } 5381 return t 5382 } 5383 , 5384 i.extend = function(t, e) { 5385 var i = this.clone(t); 5386 for (var n in e) 5387 i[n] = this.clone(e[n]); 5388 return i 5389 } 5390 , 5391 i.isEditable = function(t) { 5392 return n.matches(t, "input,[contenteditable]") || n.matches(t, "select,[contenteditable]") || n.matches(t, "textarea,[contenteditable]") || n.matches(t, "button,[contenteditable]") 5393 } 5394 , 5395 i.removePsClasses = function(t) { 5396 for (var e = s.list(t), i = 0; i < e.length; i++) { 5397 var n = e[i]; 5398 0 === n.indexOf("ps-") && s.remove(t, n) 5399 } 5400 } 5401 , 5402 i.outerWidth = function(t) { 5403 return this.toInt(n.css(t, "width")) + this.toInt(n.css(t, "paddingLeft")) + this.toInt(n.css(t, "paddingRight")) + this.toInt(n.css(t, "borderLeftWidth")) + this.toInt(n.css(t, "borderRightWidth")) 5404 } 5405 , 5406 i.startScrolling = function(t, e) { 5407 s.add(t, "ps-in-scrolling"), 5408 void 0 !== e ? s.add(t, "ps-" + e) : (s.add(t, "ps-x"), 5409 s.add(t, "ps-y")) 5410 } 5411 , 5412 i.stopScrolling = function(t, e) { 5413 s.remove(t, "ps-in-scrolling"), 5414 void 0 !== e ? s.remove(t, "ps-" + e) : (s.remove(t, "ps-x"), 5415 s.remove(t, "ps-y")) 5416 } 5417 , 5418 i.env = { 5419 isWebKit: "WebkitAppearance"in document.documentElement.style, 5420 supportsTouch: "ontouchstart"in window || window.DocumentTouch && document instanceof window.DocumentTouch, 5421 supportsIePointer: null !== window.navigator.msMaxTouchPoints 5422 } 5423 } 5424 , { 5425 "./class": 2, 5426 "./dom": 3 5427 }], 5428 7: [function(t, e) { 5429 "use strict"; 5430 var i = t("./plugin/destroy") 5431 , n = t("./plugin/initialize") 5432 , s = t("./plugin/update"); 5433 e.exports = { 5434 initialize: n, 5435 update: s, 5436 destroy: i 5437 } 5438 } 5439 , { 5440 "./plugin/destroy": 9, 5441 "./plugin/initialize": 17, 5442 "./plugin/update": 21 5443 }], 5444 8: [function(t, e) { 5445 "use strict"; 5446 e.exports = { 5447 maxScrollbarLength: null, 5448 minScrollbarLength: null, 5449 scrollXMarginOffset: 0, 5450 scrollYMarginOffset: 0, 5451 stopPropagationOnClick: !0, 5452 suppressScrollX: !1, 5453 suppressScrollY: !1, 5454 swipePropagation: !0, 5455 useBothWheelAxes: !1, 5456 useKeyboard: !0, 5457 useSelectionScroll: !1, 5458 wheelPropagation: !1, 5459 wheelSpeed: 1 5460 } 5461 } 5462 , {}], 5463 9: [function(t, e) { 5464 "use strict"; 5465 var i = t("../lib/dom") 5466 , n = t("../lib/helper") 5467 , s = t("./instances"); 5468 e.exports = function(t) { 5469 var e = s.get(t); 5470 e && (e.event.unbindAll(), 5471 i.remove(e.scrollbarX), 5472 i.remove(e.scrollbarY), 5473 i.remove(e.scrollbarXRail), 5474 i.remove(e.scrollbarYRail), 5475 n.removePsClasses(t), 5476 s.remove(t)) 5477 } 5478 } 5479 , { 5480 "../lib/dom": 3, 5481 "../lib/helper": 6, 5482 "./instances": 18 5483 }], 5484 10: [function(t, e) { 5485 "use strict"; 5486 var r = t("../../lib/helper") 5487 , i = t("../instances") 5488 , a = t("../update-geometry") 5489 , l = t("../update-scroll"); 5490 e.exports = function(t) { 5491 !function(n, s) { 5492 function o(t) { 5493 return t.getBoundingClientRect() 5494 } 5495 var t = window.Event.prototype.stopPropagation.bind; 5496 s.settings.stopPropagationOnClick && s.event.bind(s.scrollbarY, "click", t), 5497 s.event.bind(s.scrollbarYRail, "click", function(t) { 5498 var e = r.toInt(s.scrollbarYHeight / 2) 5499 , i = s.railYRatio * (t.pageY - window.pageYOffset - o(s.scrollbarYRail).top - e) / (s.railYRatio * (s.railYHeight - s.scrollbarYHeight)); 5500 i < 0 ? i = 0 : 1 < i && (i = 1), 5501 l(n, "top", (s.contentHeight - s.containerHeight) * i), 5502 a(n), 5503 t.stopPropagation() 5504 }), 5505 s.settings.stopPropagationOnClick && s.event.bind(s.scrollbarX, "click", t), 5506 s.event.bind(s.scrollbarXRail, "click", function(t) { 5507 var e = r.toInt(s.scrollbarXWidth / 2) 5508 , i = s.railXRatio * (t.pageX - window.pageXOffset - o(s.scrollbarXRail).left - e) / (s.railXRatio * (s.railXWidth - s.scrollbarXWidth)); 5509 i < 0 ? i = 0 : 1 < i && (i = 1), 5510 l(n, "left", (s.contentWidth - s.containerWidth) * i - s.negativeScrollAdjustment), 5511 a(n), 5512 t.stopPropagation() 5513 }) 5514 }(t, i.get(t)) 5515 } 5516 } 5517 , { 5518 "../../lib/helper": 6, 5519 "../instances": 18, 5520 "../update-geometry": 19, 5521 "../update-scroll": 20 5522 }], 5523 11: [function(t, e) { 5524 "use strict"; 5525 function i(s, o) { 5526 var r = null 5527 , e = null 5528 , i = function(t) { 5529 (function(t) { 5530 var e = r + t * o.railXRatio 5531 , i = Math.max(0, o.scrollbarXRail.getBoundingClientRect().left) + o.railXRatio * (o.railXWidth - o.scrollbarXWidth); 5532 o.scrollbarXLeft = e < 0 ? 0 : i < e ? i : e; 5533 var n = l.toInt(o.scrollbarXLeft * (o.contentWidth - o.containerWidth) / (o.containerWidth - o.railXRatio * o.scrollbarXWidth)) - o.negativeScrollAdjustment; 5534 u(s, "left", n) 5535 } 5536 )(t.pageX - e), 5537 c(s), 5538 t.stopPropagation(), 5539 t.preventDefault() 5540 } 5541 , n = function() { 5542 l.stopScrolling(s, "x"), 5543 o.event.unbind(o.ownerDocument, "mousemove", i) 5544 }; 5545 o.event.bind(o.scrollbarX, "mousedown", function(t) { 5546 e = t.pageX, 5547 r = l.toInt(a.css(o.scrollbarX, "left")) * o.railXRatio, 5548 l.startScrolling(s, "x"), 5549 o.event.bind(o.ownerDocument, "mousemove", i), 5550 o.event.once(o.ownerDocument, "mouseup", n), 5551 t.stopPropagation(), 5552 t.preventDefault() 5553 }) 5554 } 5555 function n(s, o) { 5556 var r = null 5557 , e = null 5558 , i = function(t) { 5559 (function(t) { 5560 var e = r + t * o.railYRatio 5561 , i = Math.max(0, o.scrollbarYRail.getBoundingClientRect().top) + o.railYRatio * (o.railYHeight - o.scrollbarYHeight); 5562 o.scrollbarYTop = e < 0 ? 0 : i < e ? i : e; 5563 var n = l.toInt(o.scrollbarYTop * (o.contentHeight - o.containerHeight) / (o.containerHeight - o.railYRatio * o.scrollbarYHeight)); 5564 u(s, "top", n) 5565 } 5566 )(t.pageY - e), 5567 c(s), 5568 t.stopPropagation(), 5569 t.preventDefault() 5570 } 5571 , n = function() { 5572 l.stopScrolling(s, "y"), 5573 o.event.unbind(o.ownerDocument, "mousemove", i) 5574 }; 5575 o.event.bind(o.scrollbarY, "mousedown", function(t) { 5576 e = t.pageY, 5577 r = l.toInt(a.css(o.scrollbarY, "top")) * o.railYRatio, 5578 l.startScrolling(s, "y"), 5579 o.event.bind(o.ownerDocument, "mousemove", i), 5580 o.event.once(o.ownerDocument, "mouseup", n), 5581 t.stopPropagation(), 5582 t.preventDefault() 5583 }) 5584 } 5585 var a = t("../../lib/dom") 5586 , l = t("../../lib/helper") 5587 , s = t("../instances") 5588 , c = t("../update-geometry") 5589 , u = t("../update-scroll"); 5590 e.exports = function(t) { 5591 var e = s.get(t); 5592 i(t, e), 5593 n(t, e) 5594 } 5595 } 5596 , { 5597 "../../lib/dom": 3, 5598 "../../lib/helper": 6, 5599 "../instances": 18, 5600 "../update-geometry": 19, 5601 "../update-scroll": 20 5602 }], 5603 12: [function(t, e) { 5604 "use strict"; 5605 function i(s, o) { 5606 var r = !1; 5607 o.event.bind(s, "mouseenter", function() { 5608 r = !0 5609 }), 5610 o.event.bind(s, "mouseleave", function() { 5611 r = !1 5612 }); 5613 o.event.bind(o.ownerDocument, "keydown", function(t) { 5614 if ((!t.isDefaultPrevented || !t.isDefaultPrevented()) && r) { 5615 var e = document.activeElement ? document.activeElement : o.ownerDocument.activeElement; 5616 if (e) { 5617 for (; e.shadowRoot; ) 5618 e = e.shadowRoot.activeElement; 5619 if (a.isEditable(e)) 5620 return 5621 } 5622 var i = 0 5623 , n = 0; 5624 switch (t.which) { 5625 case 37: 5626 i = -30; 5627 break; 5628 case 38: 5629 n = 30; 5630 break; 5631 case 39: 5632 i = 30; 5633 break; 5634 case 40: 5635 n = -30; 5636 break; 5637 case 33: 5638 n = 90; 5639 break; 5640 case 32: 5641 n = t.shiftKey ? 90 : -90; 5642 break; 5643 case 34: 5644 n = -90; 5645 break; 5646 case 35: 5647 n = t.ctrlKey ? -o.contentHeight : -o.containerHeight; 5648 break; 5649 case 36: 5650 n = t.ctrlKey ? s.scrollTop : o.containerHeight; 5651 break; 5652 default: 5653 return 5654 } 5655 c(s, "top", s.scrollTop - n), 5656 c(s, "left", s.scrollLeft + i), 5657 l(s), 5658 function(t, e) { 5659 var i = s.scrollTop; 5660 if (0 === t) { 5661 if (!o.scrollbarYActive) 5662 return !1; 5663 if (0 === i && 0 < e || i >= o.contentHeight - o.containerHeight && e < 0) 5664 return !o.settings.wheelPropagation 5665 } 5666 var n = s.scrollLeft; 5667 if (0 === e) { 5668 if (!o.scrollbarXActive) 5669 return !1; 5670 if (0 === n && t < 0 || n >= o.contentWidth - o.containerWidth && 0 < t) 5671 return !o.settings.wheelPropagation 5672 } 5673 return !0 5674 }(i, n) && t.preventDefault() 5675 } 5676 }) 5677 } 5678 var a = t("../../lib/helper") 5679 , n = t("../instances") 5680 , l = t("../update-geometry") 5681 , c = t("../update-scroll"); 5682 e.exports = function(t) { 5683 i(t, n.get(t)) 5684 } 5685 } 5686 , { 5687 "../../lib/helper": 6, 5688 "../instances": 18, 5689 "../update-geometry": 19, 5690 "../update-scroll": 20 5691 }], 5692 13: [function(t, e) { 5693 "use strict"; 5694 function i(a, l) { 5695 function t(t) { 5696 var e, i, n, s = (i = (e = t).deltaX,
5697 n = -1 * e.deltaY, 5698 (void 0 === i || void 0 === n) && (i = -1 * e.wheelDeltaX / 6, 5699 n = e.wheelDeltaY / 6), 5700 e.deltaMode && 1 === e.deltaMode && (i *= 10, 5701 n *= 10), 5702 i != i && n != n && (i = 0, 5703 n = e.wheelDelta), 5704 [i, n]), o = s[0], r = s[1]; 5705 (function(t, e) { 5706 var i = a.querySelector("textarea:hover"); 5707 if (i) { 5708 var n = i.scrollHeight - i.clientHeight; 5709 if (0 < n && !(0 === i.scrollTop && 0 < e || i.scrollTop === n && e < 0)) 5710 return !0; 5711 var s = i.scrollLeft - i.clientWidth; 5712 if (0 < s && !(0 === i.scrollLeft && t < 0 || i.scrollLeft === s && 0 < t)) 5713 return !0 5714 } 5715 return !1 5716 } 5717 )(o, r) || (c = !1, 5718 l.settings.useBothWheelAxes ? l.scrollbarYActive && !l.scrollbarXActive ? (h(a, "top", r ? a.scrollTop - r * l.settings.wheelSpeed : a.scrollTop + o * l.settings.wheelSpeed), 5719 c = !0) : l.scrollbarXActive && !l.scrollbarYActive && (h(a, "left", o ? a.scrollLeft + o * l.settings.wheelSpeed : a.scrollLeft - r * l.settings.wheelSpeed), 5720 c = !0) : (h(a, "top", a.scrollTop - r * l.settings.wheelSpeed), 5721 h(a, "left", a.scrollLeft + o * l.settings.wheelSpeed)), 5722 u(a), 5723 (c = c || function(t, e) { 5724 var i = a.scrollTop; 5725 if (0 === t) { 5726 if (!l.scrollbarYActive) 5727 return !1; 5728 if (0 === i && 0 < e || i >= l.contentHeight - l.containerHeight && e < 0) 5729 return !l.settings.wheelPropagation 5730 } 5731 var n = a.scrollLeft; 5732 if (0 === e) { 5733 if (!l.scrollbarXActive) 5734 return !1; 5735 if (0 === n && t < 0 || n >= l.contentWidth - l.containerWidth && 0 < t) 5736 return !l.settings.wheelPropagation 5737 } 5738 return !0 5739 }(o, r)) && (t.stopPropagation(), 5740 t.preventDefault())) 5741 } 5742 var c = !1; 5743 void 0 !== window.onwheel ? l.event.bind(a, "wheel", t) : void 0 !== window.onmousewheel && l.event.bind(a, "mousewheel", t) 5744 } 5745 var n = t("../instances") 5746 , u = t("../update-geometry") 5747 , h = t("../update-scroll"); 5748 e.exports = function(t) { 5749 i(t, n.get(t)) 5750 } 5751 } 5752 , { 5753 "../instances": 18, 5754 "../update-geometry": 19, 5755 "../update-scroll": 20 5756 }], 5757 14: [function(t, e) { 5758 "use strict"; 5759 var n = t("../instances") 5760 , s = t("../update-geometry"); 5761 e.exports = function(t) { 5762 var e, i = n.get(t); 5763 e = t, 5764 i.event.bind(e, "scroll", function() { 5765 s(e) 5766 }) 5767 } 5768 } 5769 , { 5770 "../instances": 18, 5771 "../update-geometry": 19 5772 }], 5773 15: [function(t, e) { 5774 "use strict"; 5775 function i(a, t) { 5776 function l() { 5777 c && (clearInterval(c), 5778 c = null), 5779 d.stopScrolling(a) 5780 } 5781 var c = null 5782 , u = { 5783 top: 0, 5784 left: 0 5785 } 5786 , h = !1; 5787 t.event.bind(t.ownerDocument, "selectionchange", function() { 5788 var t; 5789 a.contains(0 === (t = window.getSelection ? window.getSelection() : document.getSelection ? document.getSelection() : "").toString().length ? null : t.getRangeAt(0).commonAncestorContainer) ? h = !0 : (h = !1, 5790 l()) 5791 }), 5792 t.event.bind(window, "mouseup", function() { 5793 h && (h = !1, 5794 l()) 5795 }), 5796 t.event.bind(window, "mousemove", function(t) { 5797 if (h) { 5798 var e = t.pageX 5799 , i = t.pageY 5800 , n = a.offsetLeft 5801 , s = a.offsetLeft + a.offsetWidth 5802 , o = a.offsetTop 5803 , r = a.offsetTop + a.offsetHeight; 5804 e < n + 3 ? (u.left = -5, 5805 d.startScrolling(a, "x")) : s - 3 < e ? (u.left = 5, 5806 d.startScrolling(a, "x")) : u.left = 0, 5807 i < o + 3 ? (u.top = o + 3 - i < 5 ? -5 : -20, 5808 d.startScrolling(a, "y")) : r - 3 < i ? (u.top = i - r + 3 < 5 ? 5 : 20, 5809 d.startScrolling(a, "y")) : u.top = 0, 5810 0 === u.top && 0 === u.left ? l() : c || (c = setInterval(function() { 5811 return p.get(a) ? (g(a, "top", a.scrollTop + u.top), 5812 g(a, "left", a.scrollLeft + u.left), 5813 void f(a)) : void clearInterval(c) 5814 }, 50)) 5815 } 5816 }) 5817 } 5818 var d = t("../../lib/helper") 5819 , p = t("../instances") 5820 , f = t("../update-geometry") 5821 , g = t("../update-scroll"); 5822 e.exports = function(t) { 5823 i(t, p.get(t)) 5824 } 5825 } 5826 , { 5827 "../../lib/helper": 6, 5828 "../instances": 18, 5829 "../update-geometry": 19, 5830 "../update-scroll": 20 5831 }], 5832 16: [function(t, e) { 5833 "use strict"; 5834 function n(a, l, t, e) { 5835 function c(t, e) { 5836 w(a, "top", a.scrollTop - e), 5837 w(a, "left", a.scrollLeft - t), 5838 b(a) 5839 } 5840 function i() { 5841 m = !0 5842 } 5843 function n() { 5844 m = !1 5845 } 5846 function u(t) { 5847 return t.targetTouches ? t.targetTouches[0] : t 5848 } 5849 function h(t) { 5850 return !(!t.targetTouches || 1 !== t.targetTouches.length) || !(!t.pointerType || "mouse" === t.pointerType || t.pointerType === t.MSPOINTER_TYPE_MOUSE) 5851 } 5852 function s(t) { 5853 if (h(t)) { 5854 v = !0; 5855 var e = u(t); 5856 d.pageX = e.pageX, 5857 d.pageY = e.pageY, 5858 p = (new Date).getTime(), 5859 null !== g && clearInterval(g), 5860 t.stopPropagation() 5861 } 5862 } 5863 function o(t) { 5864 if (!m && v && h(t)) { 5865 var e = u(t) 5866 , i = { 5867 pageX: e.pageX, 5868 pageY: e.pageY 5869 } 5870 , n = i.pageX - d.pageX 5871 , s = i.pageY - d.pageY; 5872 c(n, s), 5873 d = i; 5874 var o = (new Date).getTime() 5875 , r = o - p; 5876 0 < r && (f.x = n / r, 5877 f.y = s / r, 5878 p = o), 5879 function(t, e) { 5880 var i = a.scrollTop 5881 , n = a.scrollLeft 5882 , s = Math.abs(t) 5883 , o = Math.abs(e); 5884 if (s < o) { 5885 if (e < 0 && i === l.contentHeight - l.containerHeight || 0 < e && 0 === i) 5886 return !l.settings.swipePropagation 5887 } else if (o < s && (t < 0 && n === l.contentWidth - l.containerWidth || 0 < t && 0 === n)) 5888 return !l.settings.swipePropagation; 5889 return !0 5890 }(n, s) && (t.stopPropagation(), 5891 t.preventDefault()) 5892 } 5893 } 5894 function r() { 5895 !m && v && (v = !1, 5896 clearInterval(g), 5897 g = setInterval(function() { 5898 return y.get(a) ? Math.abs(f.x) < .01 && Math.abs(f.y) < .01 ? void clearInterval(g) : (c(30 * f.x, 30 * f.y), 5899 f.x *= .8, 5900 void (f.y *= .8)) : void clearInterval(g) 5901 }, 10)) 5902 } 5903 var d = {} 5904 , p = 0 5905 , f = {} 5906 , g = null 5907 , m = !1 5908 , v = !1; 5909 t && (l.event.bind(window, "touchstart", i), 5910 l.event.bind(window, "touchend", n), 5911 l.event.bind(a, "touchstart", s), 5912 l.event.bind(a, "touchmove", o), 5913 l.event.bind(a, "touchend", r)), 5914 e && (window.PointerEvent ? (l.event.bind(window, "pointerdown", i), 5915 l.event.bind(window, "pointerup", n), 5916 l.event.bind(a, "pointerdown", s), 5917 l.event.bind(a, "pointermove", o), 5918 l.event.bind(a, "pointerup", r)) : window.MSPointerEvent && (l.event.bind(window, "MSPointerDown", i), 5919 l.event.bind(window, "MSPointerUp", n), 5920 l.event.bind(a, "MSPointerDown", s), 5921 l.event.bind(a, "MSPointerMove", o), 5922 l.event.bind(a, "MSPointerUp", r))) 5923 } 5924 var y = t("../instances") 5925 , b = t("../update-geometry") 5926 , w = t("../update-scroll"); 5927 e.exports = function(t, e, i) { 5928 n(t, y.get(t), e, i) 5929 } 5930 } 5931 , { 5932 "../instances": 18, 5933 "../update-geometry": 19, 5934 "../update-scroll": 20 5935 }], 5936 17: [function(t, e) { 5937 "use strict"; 5938 var n = t("../lib/class") 5939 , s = t("../lib/helper") 5940 , o = t("./instances") 5941 , r = t("./update-geometry") 5942 , a = t("./handler/click-rail") 5943 , l = t("./handler/drag-scrollbar") 5944 , c = t("./handler/keyboard") 5945 , u = t("./handler/mouse-wheel") 5946 , h = t("./handler/native-scroll") 5947 , d = t("./handler/selection") 5948 , p = t("./handler/touch"); 5949 e.exports = function(t, e) { 5950 e = "object" == typeof e ? e : {}, 5951 n.add(t, "ps-container"); 5952 var i = o.add(t); 5953 i.settings = s.extend(i.settings, e), 5954 a(t), 5955 l(t), 5956 u(t), 5957 h(t), 5958 i.settings.useSelectionScroll && d(t), 5959 (s.env.supportsTouch || s.env.supportsIePointer) && p(t, s.env.supportsTouch, s.env.supportsIePointer), 5960 i.settings.useKeyboard && c(t), 5961 r(t) 5962 } 5963 } 5964 , { 5965 "../lib/class": 2, 5966 "../lib/helper": 6, 5967 "./handler/click-rail": 10, 5968 "./handler/drag-scrollbar": 11, 5969 "./handler/keyboard": 12, 5970 "./handler/mouse-wheel": 13, 5971 "./handler/native-scroll": 14, 5972 "./handler/selection": 15, 5973 "./handler/touch": 16, 5974 "./instances": 18, 5975 "./update-geometry": 19 5976 }], 5977 18: [function(t, e, i) { 5978 "use strict"; 5979 function n(t) { 5980 return void 0 === t.dataset ? t.getAttribute("data-ps-id") : t.dataset.psId 5981 } 5982 var s = t("../lib/dom") 5983 , o = t("./default-setting") 5984 , r = t("../lib/event-manager") 5985 , a = t("../lib/guid") 5986 , l = t("../lib/helper") 5987 , c = {}; 5988 i.add = function(t) { 5989 var e, i, n = a(); 5990 return i = n, 5991 void 0 === (e = t).dataset ? e.setAttribute("data-ps-id", i) : e.dataset.psId = i, 5992 c[n] = new function(t) { 5993 var e, i, n = this; 5994 n.settings = l.clone(o), 5995 n.containerWidth = null, 5996 n.containerHeight = null, 5997 n.contentWidth = null, 5998 n.contentHeight = null, 5999 n.isRtl = "rtl" === s.css(t, "direction"), 6000 n.isNegativeScroll = (i = t.scrollLeft, 6001 t.scrollLeft = -1, 6002 e = t.scrollLeft < 0, 6003 t.scrollLeft = i, 6004 e), 6005 n.negativeScrollAdjustment = n.isNegativeScroll ? t.scrollWidth - t.clientWidth : 0, 6006 n.event = new r, 6007 n.ownerDocument = t.ownerDocument || document, 6008 n.scrollbarXRail = s.appendTo(s.e("div", "ps-scrollbar-x-rail"), t), 6009 n.scrollbarX = s.appendTo(s.e("div", "ps-scrollbar-x"), n.scrollbarXRail), 6010 n.scrollbarX.setAttribute("tabindex", 0), 6011 n.scrollbarXActive = null, 6012 n.scrollbarXWidth = null, 6013 n.scrollbarXLeft = null, 6014 n.scrollbarXBottom = l.toInt(s.css(n.scrollbarXRail, "bottom")), 6015 n.isScrollbarXUsingBottom = n.scrollbarXBottom == n.scrollbarXBottom, 6016 n.scrollbarXTop = n.isScrollbarXUsingBottom ? null : l.toInt(s.css(n.scrollbarXRail, "top")), 6017 n.railBorderXWidth = l.toInt(s.css(n.scrollbarXRail, "borderLeftWidth")) + l.toInt(s.css(n.scrollbarXRail, "borderRightWidth")), 6018 s.css(n.scrollbarXRail, "display", "block"), 6019 n.railXMarginWidth = l.toInt(s.css(n.scrollbarXRail, "marginLeft")) + l.toInt(s.css(n.scrollbarXRail, "marginRight")), 6020 s.css(n.scrollbarXRail, "display", ""), 6021 n.railXWidth = null, 6022 n.railXRatio = null, 6023 n.scrollbarYRail = s.appendTo(s.e("div", "ps-scrollbar-y-rail"), t), 6024 n.scrollbarY = s.appendTo(s.e("div", "ps-scrollbar-y"), n.scrollbarYRail), 6025 n.scrollbarY.setAttribute("tabindex", 0), 6026 n.scrollbarYActive = null, 6027 n.scrollbarYHeight = null, 6028 n.scrollbarYTop = null, 6029 n.scrollbarYRight = l.toInt(s.css(n.scrollbarYRail, "right")), 6030 n.isScrollbarYUsingRight = n.scrollbarYRight == n.scrollbarYRight, 6031 n.scrollbarYLeft = n.isScrollbarYUsingRight ? null : l.toInt(s.css(n.scrollbarYRail, "left")), 6032 n.scrollbarYOuterWidth = n.isRtl ? l.outerWidth(n.scrollbarY) : null, 6033 n.railBorderYWidth = l.toInt(s.css(n.scrollbarYRail, "borderTopWidth")) + l.toInt(s.css(n.scrollbarYRail, "borderBottomWidth")), 6034 s.css(n.scrollbarYRail, "display", "block"), 6035 n.railYMarginHeight = l.toInt(s.css(n.scrollbarYRail, "marginTop")) + l.toInt(s.css(n.scrollbarYRail, "marginBottom")), 6036 s.css(n.scrollbarYRail, "display", ""), 6037 n.railYHeight = null, 6038 n.railYRatio = null 6039 } 6040 (t), 6041 c[n] 6042 } 6043 , 6044 i.remove = function(t) { 6045 var e; 6046 delete c[n(t)], 6047 void 0 === (e = t).dataset ? e.removeAttribute("data-ps-id") : delete e.dataset.psId 6048 } 6049 , 6050 i.get = function(t) { 6051 return c[n(t)] 6052 } 6053 } 6054 , { 6055 "../lib/dom": 3,
6056 "../lib/event-manager": 4, 6057 "../lib/guid": 5, 6058 "../lib/helper": 6, 6059 "./default-setting": 8 6060 }], 6061 19: [function(t, e) { 6062 "use strict"; 6063 function n(t, e) { 6064 return t.settings.minScrollbarLength && (e = Math.max(e, t.settings.minScrollbarLength)), 6065 t.settings.maxScrollbarLength && (e = Math.min(e, t.settings.maxScrollbarLength)), 6066 e 6067 } 6068 var s = t("../lib/class") 6069 , o = t("../lib/dom") 6070 , r = t("../lib/helper") 6071 , a = t("./instances") 6072 , l = t("./update-scroll"); 6073 e.exports = function(t) { 6074 var e, i = a.get(t); 6075 i.containerWidth = t.clientWidth, 6076 i.containerHeight = t.clientHeight, 6077 i.contentWidth = t.scrollWidth, 6078 i.contentHeight = t.scrollHeight, 6079 t.contains(i.scrollbarXRail) || (0 < (e = o.queryChildren(t, ".ps-scrollbar-x-rail")).length && e.forEach(function(t) { 6080 o.remove(t) 6081 }), 6082 o.appendTo(i.scrollbarXRail, t)), 6083 t.contains(i.scrollbarYRail) || (0 < (e = o.queryChildren(t, ".ps-scrollbar-y-rail")).length && e.forEach(function(t) { 6084 o.remove(t) 6085 }), 6086 o.appendTo(i.scrollbarYRail, t)), 6087 !i.settings.suppressScrollX && i.containerWidth + i.settings.scrollXMarginOffset < i.contentWidth ? (i.scrollbarXActive = !0, 6088 i.railXWidth = i.containerWidth - i.railXMarginWidth, 6089 i.railXRatio = i.containerWidth / i.railXWidth, 6090 i.scrollbarXWidth = n(i, r.toInt(i.railXWidth * i.containerWidth / i.contentWidth)), 6091 i.scrollbarXLeft = r.toInt((i.negativeScrollAdjustment + t.scrollLeft) * (i.railXWidth - i.scrollbarXWidth) / (i.contentWidth - i.containerWidth))) : i.scrollbarXActive = !1, 6092 !i.settings.suppressScrollY && i.containerHeight + i.settings.scrollYMarginOffset < i.contentHeight ? (i.scrollbarYActive = !0, 6093 i.railYHeight = i.containerHeight - i.railYMarginHeight, 6094 i.railYRatio = i.containerHeight / i.railYHeight, 6095 i.scrollbarYHeight = n(i, r.toInt(i.railYHeight * i.containerHeight / i.contentHeight)), 6096 i.scrollbarYTop = r.toInt(t.scrollTop * (i.railYHeight - i.scrollbarYHeight) / (i.contentHeight - i.containerHeight))) : i.scrollbarYActive = !1, 6097 i.scrollbarXLeft >= i.railXWidth - i.scrollbarXWidth && (i.scrollbarXLeft = i.railXWidth - i.scrollbarXWidth), 6098 i.scrollbarYTop >= i.railYHeight - i.scrollbarYHeight && (i.scrollbarYTop = i.railYHeight - i.scrollbarYHeight), 6099 function(t, e) { 6100 var i = { 6101 width: e.railXWidth 6102 }; 6103 e.isRtl ? i.left = e.negativeScrollAdjustment + t.scrollLeft + e.containerWidth - e.contentWidth : i.left = t.scrollLeft, 6104 e.isScrollbarXUsingBottom ? i.bottom = e.scrollbarXBottom - t.scrollTop : i.top = e.scrollbarXTop + t.scrollTop, 6105 o.css(e.scrollbarXRail, i); 6106 var n = { 6107 top: t.scrollTop, 6108 height: e.railYHeight 6109 }; 6110 e.isScrollbarYUsingRight ? e.isRtl ? n.right = e.contentWidth - (e.negativeScrollAdjustment + t.scrollLeft) - e.scrollbarYRight - e.scrollbarYOuterWidth : n.right = e.scrollbarYRight - t.scrollLeft : e.isRtl ? n.left = e.negativeScrollAdjustment + t.scrollLeft + 2 * e.containerWidth - e.contentWidth - e.scrollbarYLeft - e.scrollbarYOuterWidth : n.left = e.scrollbarYLeft + t.scrollLeft, 6111 o.css(e.scrollbarYRail, n), 6112 o.css(e.scrollbarX, { 6113 left: e.scrollbarXLeft, 6114 width: e.scrollbarXWidth - e.railBorderXWidth 6115 }), 6116 o.css(e.scrollbarY, { 6117 top: e.scrollbarYTop, 6118 height: e.scrollbarYHeight - e.railBorderYWidth 6119 }) 6120 }(t, i), 6121 i.scrollbarXActive ? s.add(t, "ps-active-x") : (s.remove(t, "ps-active-x"), 6122 i.scrollbarXWidth = 0, 6123 i.scrollbarXLeft = 0, 6124 l(t, "left", 0)), 6125 i.scrollbarYActive ? s.add(t, "ps-active-y") : (s.remove(t, "ps-active-y"), 6126 i.scrollbarYHeight = 0, 6127 i.scrollbarYTop = 0, 6128 l(t, "top", 0)) 6129 } 6130 } 6131 , { 6132 "../lib/class": 2, 6133 "../lib/dom": 3, 6134 "../lib/helper": 6, 6135 "./instances": 18, 6136 "./update-scroll": 20 6137 }], 6138 20: [function(t, e) { 6139 "use strict"; 6140 var s, o, r = t("./instances"), a = document.createEvent("Event"), l = document.createEvent("Event"), c = document.createEvent("Event"), u = document.createEvent("Event"), h = document.createEvent("Event"), d = document.createEvent("Event"), p = document.createEvent("Event"), f = document.createEvent("Event"), g = document.createEvent("Event"), m = document.createEvent("Event"); 6141 a.initEvent("ps-scroll-up", !0, !0), 6142 l.initEvent("ps-scroll-down", !0, !0), 6143 c.initEvent("ps-scroll-left", !0, !0), 6144 u.initEvent("ps-scroll-right", !0, !0), 6145 h.initEvent("ps-scroll-y", !0, !0), 6146 d.initEvent("ps-scroll-x", !0, !0), 6147 p.initEvent("ps-x-reach-start", !0, !0), 6148 f.initEvent("ps-x-reach-end", !0, !0), 6149 g.initEvent("ps-y-reach-start", !0, !0), 6150 m.initEvent("ps-y-reach-end", !0, !0), 6151 e.exports = function(t, e, i) { 6152 if (void 0 === t) 6153 throw "You must provide an element to the update-scroll function"; 6154 if (void 0 === e) 6155 throw "You must provide an axis to the update-scroll function"; 6156 if (void 0 === i) 6157 throw "You must provide a value to the update-scroll function"; 6158 if ("top" === e && i <= 0) 6159 return t.scrollTop = 0, 6160 void t.dispatchEvent(g); 6161 if ("left" === e && i <= 0) 6162 return t.scrollLeft = 0, 6163 void t.dispatchEvent(p); 6164 var n = r.get(t); 6165 return "top" === e && i >= n.contentHeight - n.containerHeight ? (t.scrollTop = n.contentHeight - n.containerHeight, 6166 void t.dispatchEvent(m)) : "left" === e && i >= n.contentWidth - n.containerWidth ? (t.scrollLeft = n.contentWidth - n.containerWidth, 6167 void t.dispatchEvent(f)) : (s || (s = t.scrollTop), 6168 o || (o = t.scrollLeft), 6169 "top" === e && i < s && t.dispatchEvent(a), 6170 "top" === e && s < i && t.dispatchEvent(l), 6171 "left" === e && i < o && t.dispatchEvent(c), 6172 "left" === e && o < i && t.dispatchEvent(u), 6173 "top" === e && (t.scrollTop = s = i, 6174 t.dispatchEvent(h)), 6175 void ("left" === e && (t.scrollLeft = o = i, 6176 t.dispatchEvent(d)))) 6177 } 6178 } 6179 , { 6180 "./instances": 18 6181 }], 6182 21: [function(t, e) { 6183 "use strict"; 6184 var i = t("../lib/dom") 6185 , n = t("../lib/helper") 6186 , s = t("./instances") 6187 , o = t("./update-geometry") 6188 , r = t("./update-scroll"); 6189 e.exports = function(t) { 6190 var e = s.get(t); 6191 e && (e.negativeScrollAdjustment = e.isNegativeScroll ? t.scrollWidth - t.clientWidth : 0, 6192 i.css(e.scrollbarXRail, "display", "block"), 6193 i.css(e.scrollbarYRail, "display", "block"), 6194 e.railXMarginWidth = n.toInt(i.css(e.scrollbarXRail, "marginLeft")) + n.toInt(i.css(e.scrollbarXRail, "marginRight")), 6195 e.railYMarginHeight = n.toInt(i.css(e.scrollbarYRail, "marginTop")) + n.toInt(i.css(e.scrollbarYRail, "marginBottom")), 6196 i.css(e.scrollbarXRail, "display", "none"), 6197 i.css(e.scrollbarYRail, "display", "none"), 6198 o(t), 6199 r(t, "top", t.scrollTop), 6200 r(t, "left", t.scrollLeft), 6201 i.css(e.scrollbarXRail, "display", ""), 6202 i.css(e.scrollbarYRail, "display", "")) 6203 } 6204 } 6205 , { 6206 "../lib/dom": 3, 6207 "../lib/helper": 6, 6208 "./instances": 18, 6209 "./update-geometry": 19, 6210 "./update-scroll": 20 6211 }] 6212}, {}, [1]), 6213function(l) { 6214 l.fn.visible = function(t, e) { 6215 var i = l(this).eq(0) 6216 , n = i.get(0) 6217 , s = l(window) 6218 , o = s.scrollTop(); 6219 s = o + s.height(); 6220 var r = i.offset().top 6221 , a = r + i.height(); 6222 return i = !0 === t ? a : r, 6223 r = !0 === t ? r : a, 6224 !!(!0 !== e || n.offsetWidth * n.offsetHeight) && r <= s && o <= i 6225 } 6226}(jQuery), 6227jQuery.fn.extend({ 6228 srParallax: function() { 6229 return this.each(function() { 6230 var t = jQuery(this); 6231 moveParallax(t), 6232 jQuery(window).scroll(function() { 6233 moveParallax(t) 6234 }) 6235 }) 6236 } 6237}), 6238function(r, o, s, a) { 6239 function l(t, e) { 6240 var i = this; 6241 "object" == typeof e && (delete e.refresh, 6242 delete e.render, 6243 r.extend(this, e)), 6244 this.$element = r(t), 6245 !this.imageSrc && this.$element.is("img") && (this.imageSrc = this.$element.attr("src")); 6246 var n = (this.position + "").toLowerCase().match(/\S+/g) || []; 6247 if (n.length < 1 && n.push("center"), 6248 1 == n.length && n.push(n[0]), 6249 ("top" == n[0] || "bottom" == n[0] || "left" == n[1] || "right" == n[1]) && (n = [n[1], n[0]]), 6250 this.positionX != a && (n[0] = this.positionX.toLowerCase()), 6251 this.positionY != a && (n[1] = this.positionY.toLowerCase()), 6252 i.positionX = n[0], 6253 i.positionY = n[1], 6254 "left" != this.positionX && "right" != this.positionX && (this.positionX = isNaN(parseInt(this.positionX)) ? "center" : parseInt(this.positionX)), 6255 "top" != this.positionY && "bottom" != this.positionY && (this.positionY = isNaN(parseInt(this.positionY)) ? "center" : parseInt(this.positionY)), 6256 this.position = this.positionX + (isNaN(this.positionX) ? "" : "px") + " " + this.positionY + (isNaN(this.positionY) ? "" : "px"), 6257 navigator.userAgent.match(/(iPod|iPhone|iPad)/)) 6258 return this.imageSrc && this.iosFix && !this.$element.is("img") && this.$element.css({ 6259 backgroundImage: "url(" + this.imageSrc + ")", 6260 backgroundSize: "cover", 6261 backgroundPosition: this.position 6262 }), 6263 this; 6264 if (navigator.userAgent.match(/(Android)/)) 6265 return this.imageSrc && this.androidFix && !this.$element.is("img") && this.$element.css({ 6266 backgroundImage: "url(" + this.imageSrc + ")", 6267 backgroundSize: "cover", 6268 backgroundPosition: this.position 6269 }), 6270 this; 6271 this.$mirror = r("<div />").prependTo("body"); 6272 var s = this.$element.find(">.parallax-slider") 6273 , o = !1; 6274 0 == s.length ? this.$slider = r("<img />").prependTo(this.$mirror) : (this.$slider = s.prependTo(this.$mirror), 6275 o = !0), 6276 this.$mirror.addClass("parallax-mirror").css({ 6277 visibility: "hidden", 6278 zIndex: this.zIndex, 6279 position: "fixed", 6280 top: 0, 6281 left: 0, 6282 overflow: "hidden" 6283 }), 6284 this.$slider.addClass("parallax-slider").one("load", function() {
6285 i.naturalHeight && i.naturalWidth || (i.naturalHeight = this.naturalHeight || this.height || 1, 6286 i.naturalWidth = this.naturalWidth || this.width || 1), 6287 i.aspectRatio = i.naturalWidth / i.naturalHeight, 6288 l.isSetup || l.setup(), 6289 l.sliders.push(i), 6290 l.isFresh = !1, 6291 l.requestRender() 6292 }), 6293 o || (this.$slider[0].src = this.imageSrc), 6294 (this.naturalHeight && this.naturalWidth || this.$slider[0].complete || 0 < s.length) && this.$slider.trigger("load") 6295 } 6296 !function() { 6297 for (var s = 0, t = ["ms", "moz", "webkit", "o"], e = 0; e < t.length && !o.requestAnimationFrame; ++e) 6298 o.requestAnimationFrame = o[t[e] + "RequestAnimationFrame"], 6299 o.cancelAnimationFrame = o[t[e] + "CancelAnimationFrame"] || o[t[e] + "CancelRequestAnimationFrame"]; 6300 o.requestAnimationFrame || (o.requestAnimationFrame = function(t) { 6301 var e = (new Date).getTime() 6302 , i = Math.max(0, 16 - (e - s)) 6303 , n = o.setTimeout(function() { 6304 t(e + i) 6305 }, i); 6306 return s = e + i, 6307 n 6308 } 6309 ), 6310 o.cancelAnimationFrame || (o.cancelAnimationFrame = function(t) { 6311 clearTimeout(t) 6312 } 6313 ) 6314 }(), 6315 r.extend(l.prototype, { 6316 speed: .2, 6317 bleed: 0, 6318 zIndex: -100, 6319 iosFix: !0, 6320 androidFix: !0, 6321 position: "center", 6322 overScrollFix: !1, 6323 refresh: function() { 6324 this.boxWidth = this.$element.outerWidth(), 6325 this.boxHeight = this.$element.outerHeight() + 2 * this.bleed, 6326 this.boxOffsetTop = this.$element.offset().top - this.bleed, 6327 this.boxOffsetLeft = this.$element.offset().left, 6328 this.boxOffsetBottom = this.boxOffsetTop + this.boxHeight; 6329 var t = l.winHeight 6330 , e = l.docHeight 6331 , i = Math.min(this.boxOffsetTop, e - t) 6332 , n = Math.max(this.boxOffsetTop + this.boxHeight - t, 0) 6333 , s = this.boxHeight + (i - n) * (1 - this.speed) | 0 6334 , o = (this.boxOffsetTop - i) * (1 - this.speed) | 0; 6335 if (s * this.aspectRatio >= this.boxWidth) { 6336 this.imageWidth = s * this.aspectRatio | 0, 6337 this.imageHeight = s, 6338 this.offsetBaseTop = o; 6339 var r = this.imageWidth - this.boxWidth; 6340 this.offsetLeft = "left" == this.positionX ? 0 : "right" == this.positionX ? -r : isNaN(this.positionX) ? -r / 2 | 0 : Math.max(this.positionX, -r) 6341 } else { 6342 this.imageWidth = this.boxWidth, 6343 this.imageHeight = this.boxWidth / this.aspectRatio | 0, 6344 this.offsetLeft = 0; 6345 r = this.imageHeight - s; 6346 this.offsetBaseTop = "top" == this.positionY ? o : "bottom" == this.positionY ? o - r : isNaN(this.positionY) ? o - r / 2 | 0 : o + Math.max(this.positionY, -r) 6347 } 6348 }, 6349 render: function() { 6350 var t = l.scrollTop 6351 , e = l.scrollLeft 6352 , i = this.overScrollFix ? l.overScroll : 0 6353 , n = t + l.winHeight; 6354 this.boxOffsetBottom > t && this.boxOffsetTop <= n ? (this.visibility = "visible", 6355 this.mirrorTop = this.boxOffsetTop - t, 6356 this.mirrorLeft = this.boxOffsetLeft - e, 6357 this.offsetTop = this.offsetBaseTop - this.mirrorTop * (1 - this.speed)) : this.visibility = "hidden", 6358 this.$mirror.css({ 6359 transform: "translate3d(0px, 0px, 0px)", 6360 visibility: this.visibility, 6361 top: this.mirrorTop - i, 6362 left: this.mirrorLeft, 6363 height: this.boxHeight, 6364 width: this.boxWidth 6365 }), 6366 this.$slider.css({ 6367 transform: "translate3d(0px, 0px, 0px)", 6368 position: "absolute", 6369 top: this.offsetTop, 6370 left: this.offsetLeft, 6371 height: this.imageHeight, 6372 width: this.imageWidth, 6373 maxWidth: "none" 6374 }) 6375 } 6376 }), 6377 r.extend(l, { 6378 scrollTop: 0, 6379 scrollLeft: 0, 6380 winHeight: 0, 6381 winWidth: 0, 6382 docHeight: 1 << 30, 6383 docWidth: 1 << 30, 6384 sliders: [], 6385 isReady: !1, 6386 isFresh: !1, 6387 isBusy: !1, 6388 setup: function() { 6389 if (!this.isReady) { 6390 var t = r(s) 6391 , n = r(o) 6392 , e = function() { 6393 l.winHeight = n.height(), 6394 l.winWidth = n.width(), 6395 l.docHeight = t.height(), 6396 l.docWidth = t.width() 6397 } 6398 , i = function() { 6399 var t = n.scrollTop() 6400 , e = l.docHeight - l.winHeight 6401 , i = l.docWidth - l.winWidth; 6402 l.scrollTop = Math.max(0, Math.min(e, t)), 6403 l.scrollLeft = Math.max(0, Math.min(i, n.scrollLeft())), 6404 l.overScroll = Math.max(t - e, Math.min(t, 0)) 6405 }; 6406 n.on("resize.px.parallax load.px.parallax", function() { 6407 e(), 6408 l.isFresh = !1, 6409 l.requestRender() 6410 }).on("scroll.px.parallax load.px.parallax", function() { 6411 i(), 6412 l.requestRender() 6413 }), 6414 e(), 6415 i(), 6416 this.isReady = !0 6417 } 6418 }, 6419 configure: function(t) { 6420 "object" == typeof t && (delete t.refresh, 6421 delete t.render, 6422 r.extend(this.prototype, t)) 6423 }, 6424 refresh: function() { 6425 r.each(this.sliders, function() { 6426 this.refresh() 6427 }), 6428 this.isFresh = !0 6429 }, 6430 render: function() { 6431 this.isFresh || this.refresh(), 6432 r.each(this.sliders, function() { 6433 this.render() 6434 }) 6435 }, 6436 requestRender: function() { 6437 var t = this; 6438 this.isBusy || (this.isBusy = !0, 6439 o.requestAnimationFrame(function() { 6440 t.render(), 6441 t.isBusy = !1 6442 })) 6443 }, 6444 destroy: function(t) { 6445 var e, i = r(t).data("px.parallax"); 6446 for (i.$mirror.remove(), 6447 e = 0; e < this.sliders.length; e += 1) 6448 this.sliders[e] == i && this.sliders.splice(e, 1); 6449 r(t).data("px.parallax", !1), 6450 0 === this.sliders.length && (r(o).off("scroll.px.parallax resize.px.parallax load.px.parallax"), 6451 this.isReady = !1, 6452 l.isSetup = !1) 6453 } 6454 }); 6455 var t = r.fn.parallax; 6456 r.fn.parallax = function(i) { 6457 return this.each(function() { 6458 var t = r(this) 6459 , e = "object" == typeof i && i; 6460 this == o || this == s || t.is("body") ? l.configure(e) : t.data("px.parallax") ? "object" == typeof i && r.extend(t.data("px.parallax"), e) : (e = r.extend({}, t.data(), e), 6461 t.data("px.parallax", new l(this,e))), 6462 "string" == typeof i && ("destroy" == i ? l.destroy(this) : l[i]()) 6463 }) 6464 } 6465 , 6466 r.fn.parallax.Constructor = l, 6467 r.fn.parallax.noConflict = function() { 6468 return r.fn.parallax = t, 6469 this 6470 } 6471 , 6472 r(s).on("ready.px.parallax.data-api", function() { 6473 r('[data-parallax="scroll"]').parallax() 6474 }) 6475}(jQuery, window, document), 6476function(t) { 6477 "function" == typeof define && define.amd ? define(["jquery"], t) : t("object" == typeof exports ? require("jquery") : window.jQuery || window.Zepto) 6478}(function(u) { 6479 var h, n, d, s, p, e, l = "Close", c = "BeforeClose", f = "MarkupParse", g = "Open", m = ".mfp", v = "mfp-ready", i = "mfp-removing", r = "mfp-prevent-close", t = function() {}, a = !!window.jQuery, y = u(window), b = function(t, e) { 6480 h.ev.on("mfp" + t + m, e) 6481 }, w = function(t, e, i, n) { 6482 var s = document.createElement("div"); 6483 return s.className = "mfp-" + t, 6484 i && (s.innerHTML = i), 6485 n ? e && e.appendChild(s) : (s = u(s), 6486 e && s.appendTo(e)), 6487 s 6488 }, x = function(t, e) { 6489 h.ev.triggerHandler("mfp" + t, e), 6490 h.st.callbacks && (t = t.charAt(0).toLowerCase() + t.slice(1), 6491 h.st.callbacks[t] && h.st.callbacks[t].apply(h, u.isArray(e) ? e : [e])) 6492 }, _ = function(t) { 6493 return t === e && h.currTemplate.closeBtn || (h.currTemplate.closeBtn = u(h.st.closeMarkup.replace("%title%", h.st.tClose)), 6494 e = t), 6495 h.currTemplate.closeBtn 6496 }, k = function() { 6497 u.magnificPopup.instance || ((h = new t).init(), 6498 u.magnificPopup.instance = h) 6499 }; 6500 t.prototype = { 6501 constructor: t, 6502 init: function() { 6503 var t = navigator.appVersion; 6504 h.isLowIE = h.isIE8 = document.all && !document.addEventListener, 6505 h.isAndroid = /android/gi.test(t), 6506 h.isIOS = /iphone|ipad|ipod/gi.test(t), 6507 h.supportsTransition = function() { 6508 var t = document.createElement("p").style 6509 , e = ["ms", "O", "Moz", "Webkit"]; 6510 if (void 0 !== t.transition) 6511 return !0; 6512 for (; e.length; ) 6513 if (e.pop() + "Transition"in t) 6514 return !0; 6515 return !1 6516 }(), 6517 h.probablyMobile = h.isAndroid || h.isIOS || /(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent), 6518 d = u(document), 6519 h.popupsCache = {} 6520 }, 6521 open: function(t) { 6522 var e; 6523 if (!1 === t.isObj) { 6524 h.items = t.items.toArray(), 6525 h.index = 0; 6526 var i, n = t.items; 6527 for (e = 0; e < n.length; e++)
6528 if ((i = n[e]).parsed && (i = i.el[0]), 6529 i === t.el[0]) { 6530 h.index = e; 6531 break 6532 } 6533 } else 6534 h.items = u.isArray(t.items) ? t.items : [t.items], 6535 h.index = t.index || 0; 6536 if (!h.isOpen) { 6537 h.types = [], 6538 p = "", 6539 t.mainEl && t.mainEl.length ? h.ev = t.mainEl.eq(0) : h.ev = d, 6540 t.key ? (h.popupsCache[t.key] || (h.popupsCache[t.key] = {}), 6541 h.currTemplate = h.popupsCache[t.key]) : h.currTemplate = {}, 6542 h.st = u.extend(!0, {}, u.magnificPopup.defaults, t), 6543 h.fixedContentPos = "auto" === h.st.fixedContentPos ? !h.probablyMobile : h.st.fixedContentPos, 6544 h.st.modal && (h.st.closeOnContentClick = !1, 6545 h.st.closeOnBgClick = !1, 6546 h.st.showCloseBtn = !1, 6547 h.st.enableEscapeKey = !1), 6548 h.bgOverlay || (h.bgOverlay = w("bg").on("click" + m, function() { 6549 h.close() 6550 }), 6551 h.wrap = w("wrap").attr("tabindex", -1).on("click" + m, function(t) { 6552 h._checkIfClose(t.target) && h.close() 6553 }), 6554 h.container = w("container", h.wrap)), 6555 h.contentContainer = w("content"), 6556 h.st.preloader && (h.preloader = w("preloader", h.container, h.st.tLoading)); 6557 var s = u.magnificPopup.modules; 6558 for (e = 0; e < s.length; e++) { 6559 var o = s[e]; 6560 o = o.charAt(0).toUpperCase() + o.slice(1), 6561 h["init" + o].call(h) 6562 } 6563 x("BeforeOpen"), 6564 h.st.showCloseBtn && (h.st.closeBtnInside ? (b(f, function(t, e, i, n) { 6565 i.close_replaceWith = _(n.type) 6566 }), 6567 p += " mfp-close-btn-in") : h.wrap.append(_())), 6568 h.st.alignTop && (p += " mfp-align-top"), 6569 h.fixedContentPos ? h.wrap.css({ 6570 overflow: h.st.overflowY, 6571 overflowX: "hidden", 6572 overflowY: h.st.overflowY 6573 }) : h.wrap.css({ 6574 top: y.scrollTop(), 6575 position: "absolute" 6576 }), 6577 (!1 === h.st.fixedBgPos || "auto" === h.st.fixedBgPos && !h.fixedContentPos) && h.bgOverlay.css({ 6578 height: d.height(), 6579 position: "absolute" 6580 }), 6581 h.st.enableEscapeKey && d.on("keyup" + m, function(t) { 6582 27 === t.keyCode && h.close() 6583 }), 6584 y.on("resize" + m, function() { 6585 h.updateSize() 6586 }), 6587 h.st.closeOnContentClick || (p += " mfp-auto-cursor"), 6588 p && h.wrap.addClass(p); 6589 var r = h.wH = y.height() 6590 , a = {}; 6591 if (h.fixedContentPos && h._hasScrollBar(r)) { 6592 var l = h._getScrollbarSize(); 6593 l && (a.marginRight = l) 6594 } 6595 h.fixedContentPos && (h.isIE7 ? u("body, html").css("overflow", "hidden") : a.overflow = "hidden"); 6596 var c = h.st.mainClass; 6597 return h.isIE7 && (c += " mfp-ie7"), 6598 c && h._addClassToMFP(c), 6599 h.updateItemHTML(), 6600 x("BuildControls"), 6601 u("html").css(a), 6602 h.bgOverlay.add(h.wrap).prependTo(h.st.prependTo || u(document.body)), 6603 h._lastFocusedEl = document.activeElement, 6604 setTimeout(function() { 6605 h.content ? (h._addClassToMFP(v), 6606 h._setFocus()) : h.bgOverlay.addClass(v), 6607 d.on("focusin" + m, h._onFocusIn) 6608 }, 16), 6609 h.isOpen = !0, 6610 h.updateSize(r), 6611 x(g), 6612 t 6613 } 6614 h.updateItemHTML() 6615 }, 6616 close: function() { 6617 h.isOpen && (x(c), 6618 h.isOpen = !1, 6619 h.st.removalDelay && !h.isLowIE && h.supportsTransition ? (h._addClassToMFP(i), 6620 setTimeout(function() { 6621 h._close() 6622 }, h.st.removalDelay)) : h._close()) 6623 }, 6624 _close: function() { 6625 x(l); 6626 var t = i + " " + v + " "; 6627 if (h.bgOverlay.detach(), 6628 h.wrap.detach(), 6629 h.container.empty(), 6630 h.st.mainClass && (t += h.st.mainClass + " "), 6631 h._removeClassFromMFP(t), 6632 h.fixedContentPos) { 6633 var e = { 6634 marginRight: "" 6635 }; 6636 h.isIE7 ? u("body, html").css("overflow", "") : e.overflow = "", 6637 u("html").css(e) 6638 } 6639 d.off("keyup.mfp focusin" + m), 6640 h.ev.off(m), 6641 h.wrap.attr("class", "mfp-wrap").removeAttr("style"), 6642 h.bgOverlay.attr("class", "mfp-bg"), 6643 h.container.attr("class", "mfp-container"), 6644 !h.st.showCloseBtn || h.st.closeBtnInside && !0 !== h.currTemplate[h.currItem.type] || h.currTemplate.closeBtn && h.currTemplate.closeBtn.detach(), 6645 h.st.autoFocusLast && h._lastFocusedEl && u(h._lastFocusedEl).focus(), 6646 h.currItem = null, 6647 h.content = null, 6648 h.currTemplate = null, 6649 h.prevHeight = 0, 6650 x("AfterClose") 6651 }, 6652 updateSize: function(t) { 6653 if (h.isIOS) { 6654 var e = document.documentElement.clientWidth / window.innerWidth 6655 , i = window.innerHeight * e; 6656 h.wrap.css("height", i), 6657 h.wH = i 6658 } else 6659 h.wH = t || y.height(); 6660 h.fixedContentPos || h.wrap.css("height", h.wH), 6661 x("Resize") 6662 }, 6663 updateItemHTML: function() { 6664 var t = h.items[h.index]; 6665 h.contentContainer.detach(), 6666 h.content && h.content.detach(), 6667 t.parsed || (t = h.parseEl(h.index)); 6668 var e = t.type; 6669 if (x("BeforeChange", [h.currItem ? h.currItem.type : "", e]), 6670 h.currItem = t, 6671 !h.currTemplate[e]) { 6672 var i = !!h.st[e] && h.st[e].markup; 6673 x("FirstMarkupParse", i), 6674 h.currTemplate[e] = !i || u(i) 6675 } 6676 s && s !== t.type && h.container.removeClass("mfp-" + s + "-holder"); 6677 var n = h["get" + e.charAt(0).toUpperCase() + e.slice(1)](t, h.
6677currTemplate[e]); 6678 h.appendContent(n, e), 6679 t.preloaded = !0, 6680 x("Change", t), 6681 s = t.type, 6682 h.container.prepend(h.contentContainer), 6683 x("AfterChange") 6684 }, 6685 appendContent: function(t, e) { 6686 (h.content = t) ? h.st.showCloseBtn && h.st.closeBtnInside && !0 === h.currTemplate[e] ? h.content.find(".mfp-close").length || h.content.append(_()) : h.content = t : h.content = "", 6687 x("BeforeAppend"), 6688 h.container.addClass("mfp-" + e + "-holder"), 6689 h.contentContainer.append(h.content) 6690 }, 6691 parseEl: function(t) { 6692 var e, i = h.items[t]; 6693 if (i.tagName ? i = { 6694 el: u(i) 6695 } : (e = i.type, 6696 i = { 6697 data: i, 6698 src: i.src 6699 }), 6700 i.el) { 6701 for (var n = h.types, s = 0; s < n.length; s++) 6702 if (i.el.hasClass("mfp-" + n[s])) { 6703 e = n[s]; 6704 break 6705 } 6706 i.src = i.el.attr("data-mfp-src"), 6707 i.src || (i.src = i.el.attr("href")) 6708 } 6709 return i.type = e || h.st.type || "inline", 6710 i.index = t, 6711 i.parsed = !0, 6712 h.items[t] = i, 6713 x("ElementParse", i), 6714 h.items[t] 6715 }, 6716 addGroup: function(e, i) { 6717 var t = function(t) { 6718 t.mfpEl = this, 6719 h._openClick(t, e, i) 6720 }; 6721 i || (i = {}); 6722 var n = "click.magnificPopup"; 6723 i.mainEl = e, 6724 i.items ? (i.isObj = !0, 6725 e.off(n).on(n, t)) : (i.isObj = !1, 6726 i.delegate ? e.off(n).on(n, i.delegate, t) : (i.items = e).off(n).on(n, t)) 6727 }, 6728 _openClick: function(t, e, i) { 6729 if ((void 0 !== i.midClick ? i.midClick : u.magnificPopup.defaults.midClick) || !(2 === t.which || t.ctrlKey || t.metaKey || t.altKey || t.shiftKey)) { 6730 var n = void 0 !== i.disableOn ? i.disableOn : u.magnificPopup.defaults.disableOn; 6731 if (n) 6732 if (u.isFunction(n)) { 6733 if (!n.call(h)) 6734 return !0 6735 } else if (y.width() < n) 6736 return !0; 6737 t.type && (t.preventDefault(), 6738 h.isOpen && t.stopPropagation()), 6739 i.el = u(t.mfpEl), 6740 i.delegate && (i.items = e.find(i.delegate)), 6741 h.open(i) 6742 } 6743 }, 6744 updateStatus: function(t, e) { 6745 if (h.preloader) { 6746 n !== t && h.container.removeClass("mfp-s-" + n), 6747 e || "loading" !== t || (e = h.st.tLoading); 6748 var i = { 6749 status: t, 6750 text: e 6751 }; 6752 x("UpdateStatus", i), 6753 t = i.status, 6754 e = i.text, 6755 h.preloader.html(e), 6756 h.preloader.find("a").on("click", function(t) { 6757 t.stopImmediatePropagation() 6758 }), 6759 h.container.addClass("mfp-s-" + t), 6760 n = t 6761 } 6762 }, 6763 _checkIfClose: function(t) { 6764 if (!u(t).hasClass(r)) { 6765 var e = h.st.closeOnContentClick 6766 , i = h.st.closeOnBgClick; 6767 if (e && i) 6768 return !0; 6769 if (!h.content || u(t).hasClass("mfp-close") || h.preloader && t === h.preloader[0]) 6770 return !0; 6771 if (t === h.content[0] || u.contains(h.content[0], t)) { 6772 if (e) 6773 return !0 6774 } else if (i && u.contains(document, t)) 6775 return !0; 6776 return !1 6777 } 6778 }, 6779 _addClassToMFP: function(t) { 6780 h.bgOverlay.addClass(t), 6781 h.wrap.addClass(t) 6782 }, 6783 _removeClassFromMFP: function(t) { 6784 this.bgOverlay.removeClass(t), 6785 h.wrap.removeClass(t) 6786 }, 6787 _hasScrollBar: function(t) { 6788 return (h.isIE7 ? d.height() : document.body.scrollHeight) > (t || y.height()) 6789 }, 6790 _setFocus: function() { 6791 (h.st.focus ? h.content.find(h.st.focus).eq(0) : h.wrap).focus() 6792 }, 6793 _onFocusIn: function(t) { 6794 return t.target === h.wrap[0] || u.contains(h.wrap[0], t.target) ? void 0 : (h._setFocus(), 6795 !1) 6796 }, 6797 _parseMarkup: function(s, t, e) { 6798 var o; 6799 e.data && (t = u.extend(e.data, t)), 6800 x(f, [s, t, e]), 6801 u.each(t, function(t, e) { 6802 if (void 0 === e || !1 === e) 6803 return !0; 6804 if (1 < (o = t.split("_")).length) { 6805 var i = s.find(m + "-" + o[0]); 6806 if (0 < i.length) { 6807 var n = o[1]; 6808 "replaceWith" === n ? i[0] !== e[0] && i.replaceWith(e) : "img" === n ? i.is("img") ? i.attr("src", e) : i.replaceWith(u("<img>").attr("src", e).attr("class", i.attr("class"))) : i.attr(o[1], e) 6809 } 6810 } else 6811 s.find(m + "-" + t).html(e) 6812 }) 6813 }, 6814 _getScrollbarSize: function() { 6815 if (void 0 === h.scrollbarSize) { 6816 var t = document.createElement("div"); 6817 t.style.cssText = "width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;", 6818 document.body.appendChild(t), 6819 h.scrollbarSize = t.offsetWidth - t.clientWidth, 6820 document.body.removeChild(t) 6821 } 6822 return h.scrollbarSize 6823 } 6824 }, 6825 u.magnificPopup = { 6826 instance: null, 6827 proto: t.prototype, 6828 modules: [], 6829 open: function(t, e) { 6830 return k(), 6831 (t = t ? u.extend(!0, {}, t) : {}).isObj = !0, 6832 t.index = e || 0, 6833 this.instance.open(t) 6834 }, 6835 close: function() { 6836 return u.magnificPopup.instance && u.magnificPopup.instance.close() 6837 }, 6838 registerModule: function(t, e) { 6839 e.options && (u.magnificPopup.defaults[t] = e.options), 6840 u.extend(this.proto, e.proto), 6841 this.modules.push(t) 6842 }, 6843 defaults: { 6844 disableOn: 0, 6845 key: null, 6846 midClick: !1, 6847 mainClass: "", 6848 preloader: !0, 6849 focus: "", 6850 closeOnContentClick: !1, 6851 closeOnBgClick: !0, 6852 closeBtnInside: !0, 6853 showCloseBtn: !0, 6854 enableEscapeKey: !0, 6855 modal: !1, 6856 alignTop: !1, 6857 removalDelay: 0, 6858 prependTo: null, 6859 fixedContentPos: "auto", 6860 fixedBgPos: "auto", 6861 overflowY: "auto", 6862 closeMarkup: '<button title="%title%" type="button" class="mfp-close">×</button>', 6863 tClose: "Close (Esc)", 6864 tLoading: "Loading...", 6865 autoFocusLast: !0 6866 } 6867 }, 6868 u.fn.magnificPopup = function(t, e) { 6869 k(); 6870 var i = u(this); 6871 if ("string" == typeof t) 6872 if ("open" === t) { 6873 var n, s = a ? i.data("magnificPopup") : i[0].magnificPopup, o = parseInt(e, 10) || 0; 6874 s.items ? n = s.items[o] : (n = i, 6875 s.delegate && (n = n.find(s.delegate)), 6876 n = n.eq(o)), 6877 h._openClick({ 6878 mfpEl: n 6879 }, i, s) 6880 } else 6881 h.isOpen && h[t].apply(h, Array.prototype.slice.call(arguments, 1)); 6882 else 6883 t = u.extend(!0, {}, t), 6884 a ? i.data("magnificPopup", t) : i[0].magnificPopup = t, 6885 h.addGroup(i, t); 6886 return i 6887 } 6888 ; 6889 var o, C, S, T = "inline", I = function() { 6890 S && (C.after(S.addClass(o)).detach(), 6891 S = null) 6892 }; 6893 u.magnificPopup.registerModule(T, { 6894 options: { 6895 hiddenClass: "hide", 6896 markup: "", 6897 tNotFound: "Content not found" 6898 }, 6899 proto: { 6900 initInline: function() {
6901 h.types.push(T), 6902 b(l + "." + T, function() { 6903 I() 6904 }) 6905 }, 6906 getInline: function(t, e) { 6907 if (I(), 6908 t.src) { 6909 var i = h.st.inline 6910 , n = u(t.src); 6911 if (n.length) { 6912 var s = n[0].parentNode; 6913 s && s.tagName && (C || (o = i.hiddenClass, 6914 C = w(o), 6915 o = "mfp-" + o), 6916 S = n.after(C).detach().removeClass(o)), 6917 h.updateStatus("ready") 6918 } else 6919 h.updateStatus("error", i.tNotFound), 6920 n = u("<div>"); 6921 return t.inlineElement = n 6922 } 6923 return h.updateStatus("ready"), 6924 h._parseMarkup(e, {}, t), 6925 e 6926 } 6927 } 6928 }); 6929 var P, E = "ajax", M = function() { 6930 P && u(document.body).removeClass(P) 6931 }, D = function() { 6932 M(), 6933 h.req && h.req.abort() 6934 }; 6935 u.magnificPopup.registerModule(E, { 6936 options: { 6937 settings: null, 6938 cursor: "mfp-ajax-cur", 6939 tError: '<a href="%url%">The content</a> could not be loaded.' 6940 }, 6941 proto: { 6942 initAjax: function() { 6943 h.types.push(E), 6944 P = h.st.ajax.cursor, 6945 b(l + "." + E, D), 6946 b("BeforeChange." + E, D) 6947 }, 6948 getAjax: function(s) { 6949 P && u(document.body).addClass(P), 6950 h.updateStatus("loading"); 6951 var t = u.extend({ 6952 url: s.src, 6953 success: function(t, e, i) { 6954 var n = { 6955 data: t, 6956 xhr: i 6957 }; 6958 x("ParseAjax", n), 6959 h.appendContent(u(n.data), E), 6960 s.finished = !0, 6961 M(), 6962 h._setFocus(), 6963 setTimeout(function() { 6964 h.wrap.addClass(v) 6965 }, 16), 6966 h.updateStatus("ready"), 6967 x("AjaxContentAdded") 6968 }, 6969 error: function() { 6970 M(), 6971 s.finished = s.loadError = !0, 6972 h.updateStatus("error", h.st.ajax.tError.replace("%url%", s.src)) 6973 } 6974 }, h.st.ajax.settings); 6975 return h.req = u.ajax(t), 6976 "" 6977 } 6978 } 6979 }); 6980 var A; 6981 u.magnificPopup.registerModule("image", { 6982 options: { 6983 markup: '<div class="mfp-figure"><div class="mfp-close"></div><figure><div class="mfp-img"></div><figcaption><div class="mfp-bottom-bar"><div class="mfp-title"></div><div class="mfp-counter"></div></div></figcaption></figure></div>', 6984 cursor: "mfp-zoom-out-cur", 6985 titleSrc: "title", 6986 verticalFit: !0, 6987 tError: '<a href="%url%">The image</a> could not be loaded.' 6988 }, 6989 proto: { 6990 initImage: function() { 6991 var t = h.st.image 6992 , e = ".image"; 6993 h.types.push("image"), 6994 b(g + e, function() { 6995 "image" === h.currItem.type && t.cursor && u(document.body).addClass(t.cursor) 6996 }), 6997 b(l + e, function() { 6998 t.cursor && u(document.body).removeClass(t.cursor), 6999 y.off("resize" + m) 7000 }), 7001 b("Resize" + e, h.resizeImage), 7002 h.isLowIE && b("AfterChange", h.resizeImage) 7003 }, 7004 resizeImage: function() { 7005 var t = h.currItem; 7006 if (t && t.img && h.st.image.verticalFit) { 7007 var e = 0; 7008 h.isLowIE && (e = parseInt(t.img.css("padding-top"), 10) + parseInt(t.img.css("padding-bottom"), 10)), 7009 t.img.css("max-height", h.wH - e) 7010 } 7011 }, 7012 _onImageHasSize: function(t) { 7013 t.img && (t.hasSize = !0, 7014 A && clearInterval(A), 7015 t.isCheckingImgSize = !1, 7016 x("ImageHasSize", t), 7017 t.imgHidden && (h.content && h.content.removeClass("mfp-loading"), 7018 t.imgHidden = !1)) 7019 }, 7020 findImageSize: function(e) { 7021 var i = 0 7022 , n = e.img[0] 7023 , s = function(t) { 7024 A && clearInterval(A), 7025 A = setInterval(function() { 7026 return 0 < n.naturalWidth ? void h._onImageHasSize(e) : (200 < i && clearInterval(A), 7027 void (3 === ++i ? s(10) : 40 === i ? s(50) : 100 === i && s(500))) 7028 }, t) 7029 }; 7030 s(1) 7031 }, 7032 getImage: function(t, e) { 7033 var i = 0 7034 , n = function() { 7035 t && (t.img[0].complete ? (t.img.off(".mfploader"), 7036 t === h.currItem && (h._onImageHasSize(t), 7037 h.updateStatus("ready")), 7038 t.hasSize = !0, 7039 t.loaded = !0, 7040 x("ImageLoadComplete")) : ++i < 200 ? setTimeout(n, 100) : s()) 7041 } 7042 , s = function() { 7043 t && (t.img.off(".mfploader"), 7044 t === h.currItem && (h._onImageHasSize(t), 7045 h.updateStatus("error", o.tError.replace("%url%", t.src))), 7046 t.hasSize = !0, 7047 t.loaded = !0, 7048 t.loadError = !0) 7049 } 7050 , o = h.st.image 7051 , r = e.find(".mfp-img"); 7052 if (r.length) { 7053 var a = document.createElement("img"); 7054 a.className = "mfp-img", 7055 t.el && t.el.find("img").length && (a.alt = t.el.find("img").attr("alt")), 7056 t.img = u(a).on("load.mfploader", n).on("error.mfploader", s), 7057 a.src = t.src, 7058 r.is("img") && (t.img = t.img.clone()),
7059 0 < (a = t.img[0]).naturalWidth ? t.hasSize = !0 : a.width || (t.hasSize = !1) 7060 } 7061 return h._parseMarkup(e, { 7062 title: function(t) { 7063 if (t.data && void 0 !== t.data.title) 7064 return t.data.title; 7065 var e = h.st.image.titleSrc; 7066 if (e) { 7067 if (u.isFunction(e)) 7068 return e.call(h, t); 7069 if (t.el) 7070 return t.el.attr(e) || "" 7071 } 7072 return "" 7073 }(t), 7074 img_replaceWith: t.img 7075 }, t), 7076 h.resizeImage(), 7077 t.hasSize ? (A && clearInterval(A), 7078 t.loadError ? (e.addClass("mfp-loading"), 7079 h.updateStatus("error", o.tError.replace("%url%", t.src))) : (e.removeClass("mfp-loading"), 7080 h.updateStatus("ready"))) : (h.updateStatus("loading"), 7081 t.loading = !0, 7082 t.hasSize || (t.imgHidden = !0, 7083 e.addClass("mfp-loading"), 7084 h.findImageSize(t))), 7085 e 7086 } 7087 } 7088 }); 7089 var j; 7090 u.magnificPopup.registerModule("zoom", { 7091 options: { 7092 enabled: !1, 7093 easing: "ease-in-out", 7094 duration: 300, 7095 opener: function(t) { 7096 return t.is("img") ? t : t.find("img") 7097 } 7098 }, 7099 proto: { 7100 initZoom: function() { 7101 var t, o = h.st.zoom, e = ".zoom"; 7102 if (o.enabled && h.supportsTransition) { 7103 var i, n, s = o.duration, r = function(t) { 7104 var e = t.clone().removeAttr("style").removeAttr("class").addClass("mfp-animated-image") 7105 , i = "all " + o.duration / 1e3 + "s " + o.easing 7106 , n = { 7107 position: "fixed", 7108 zIndex: 9999, 7109 left: 0, 7110 top: 0, 7111 "-webkit-backface-visibility": "hidden" 7112 } 7113 , s = "transition"; 7114 return n["-webkit-" + s] = n["-moz-" + s] = n["-o-" + s] = n[s] = i, 7115 e.css(n), 7116 e 7117 }, a = function() { 7118 h.content.css("visibility", "visible") 7119 }; 7120 b("BuildControls" + e, function() { 7121 if (h._allowZoom()) { 7122 if (clearTimeout(i), 7123 h.content.css("visibility", "hidden"), 7124 !(t = h._getItemToZoom())) 7125 return void a(); 7126 (n = r(t)).css(h._getOffset()), 7127 h.wrap.append(n), 7128 i = setTimeout(function() { 7129 n.css(h._getOffset(!0)), 7130 i = setTimeout(function() { 7131 a(), 7132 setTimeout(function() { 7133 n.remove(), 7134 t = n = null, 7135 x("ZoomAnimationEnded") 7136 }, 16) 7137 }, s) 7138 }, 16) 7139 } 7140 }), 7141 b(c + e, function() { 7142 if (h._allowZoom()) { 7143 if (clearTimeout(i), 7144 h.st.removalDelay = s, 7145 !t) { 7146 if (!(t = h._getItemToZoom())) 7147 return; 7148 n = r(t) 7149 } 7150 n.css(h._getOffset(!0)), 7151 h.wrap.append(n), 7152 h.content.css("visibility", "hidden"), 7153 setTimeout(function() { 7154 n.css(h._getOffset()) 7155 }, 16) 7156 } 7157 }), 7158 b(l + e, function() { 7159 h._allowZoom() && (a(), 7160 n && n.remove(), 7161 t = null) 7162 }) 7163 } 7164 }, 7165 _allowZoom: function() { 7166 return "image" === h.currItem.type 7167 }, 7168 _getItemToZoom: function() { 7169 return !!h.currItem.hasSize && h.currItem.img 7170 }, 7171 _getOffset: function(t) { 7172 var e, i = (e = t ? h.currItem.img : h.st.zoom.opener(h.currItem.el || h.currItem)).offset(), n = parseInt(e.css("padding-top"), 10), s = parseInt(e.css("padding-bottom"), 10); 7173 i.top -= u(window).scrollTop() - n; 7174 var o = { 7175 width: e.width(), 7176 height: (a ? e.innerHeight() : e[0].offsetHeight) - s - n 7177 }; 7178 return void 0 === j && (j = void 0 !== document.createElement("p").style.MozTransform), 7179 j ? o["-moz-transform"] = o.transform = "translate(" + i.left + "px," + i.top + "px)" : (o.left = i.left, 7180 o.top = i.top), 7181 o 7182 } 7183 } 7184 }); 7185 var O = "iframe" 7186 , z = function(t) { 7187 if (h.currTemplate[O]) { 7188 var e = h.currTemplate[O].find("iframe"); 7189 e.length && (t || (e[0].src = "//about:blank"), 7190 h.isIE8 && e.css("display", t ? "block" : "none")) 7191 } 7192 }; 7193 u.magnificPopup.registerModule(O, { 7194 options: { 7195 markup: '<div class="mfp-iframe-scaler"><div class="mfp-close"></div><iframe class="mfp-iframe" src="//about:blank" frameborder="0" allowfullscreen></iframe></div>', 7196 srcAction: "iframe_src", 7197 patterns: { 7198 youtube: { 7199 index: "youtube.com", 7200 id: "v=", 7201 src: "//www.youtube.com/embed/%id%?autoplay=1" 7202 }, 7203 vimeo: { 7204 index: "vimeo.com/", 7205 id: "/", 7206 src: "//player.vimeo.com/video/%id%?autoplay=1" 7207 }, 7208 gmaps: { 7209 index: "//maps.google.", 7210 src: "%id%&output=embed" 7211 } 7212 } 7213 }, 7214 proto: { 7215 initIframe: function() {
7216 h.types.push(O), 7217 b("BeforeChange", function(t, e, i) { 7218 e !== i && (e === O ? z() : i === O && z(!0)) 7219 }), 7220 b(l + "." + O, function() { 7221 z() 7222 }) 7223 }, 7224 getIframe: function(t, e) { 7225 var i = t.src 7226 , n = h.st.iframe; 7227 u.each(n.patterns, function() { 7228 return -1 < i.indexOf(this.index) ? (this.id && (i = "string" == typeof this.id ? i.substr(i.lastIndexOf(this.id) + this.id.length, i.length) : this.id.call(this, i)), 7229 i = this.src.replace("%id%", i), 7230 !1) : void 0 7231 }); 7232 var s = {}; 7233 return n.srcAction && (s[n.srcAction] = i), 7234 h._parseMarkup(e, s, t), 7235 h.updateStatus("ready"), 7236 e 7237 } 7238 } 7239 }); 7240 var $ = function(t) { 7241 var e = h.items.length; 7242 return e - 1 < t ? t - e : t < 0 ? e + t : t 7243 } 7244 , L = function(t, e, i) { 7245 return t.replace(/%curr%/gi, e + 1).replace(/%total%/gi, i) 7246 }; 7247 u.magnificPopup.registerModule("gallery", { 7248 options: { 7249 enabled: !1, 7250 arrowMarkup: '<button title="%title%" type="button" class="mfp-arrow mfp-arrow-%dir%"></button>', 7251 preload: [0, 2], 7252 navigateByImgClick: !0, 7253 arrows: !0, 7254 tPrev: "Previous (Left arrow key)", 7255 tNext: "Next (Right arrow key)", 7256 tCounter: "%curr% of %total%" 7257 }, 7258 proto: { 7259 initGallery: function() { 7260 var o = h.st.gallery 7261 , t = ".mfp-gallery"; 7262 return h.direction = !0, 7263 !(!o || !o.enabled) && (p += " mfp-gallery", 7264 b(g + t, function() { 7265 o.navigateByImgClick && h.wrap.on("click" + t, ".mfp-img", function() { 7266 return 1 < h.items.length ? (h.next(), 7267 !1) : void 0 7268 }), 7269 d.on("keydown" + t, function(t) { 7270 37 === t.keyCode ? h.prev() : 39 === t.keyCode && h.next() 7271 }) 7272 }), 7273 b("UpdateStatus" + t, function(t, e) { 7274 e.text && (e.text = L(e.text, h.currItem.index, h.items.length)) 7275 }), 7276 b(f + t, function(t, e, i, n) { 7277 var s = h.items.length; 7278 i.counter = 1 < s ? L(o.tCounter, n.index, s) : "" 7279 }), 7280 b("BuildControls" + t, function() { 7281 if (1 < h.items.length && o.arrows && !h.arrowLeft) { 7282 var t = o.arrowMarkup 7283 , e = h.arrowLeft = u(t.replace(/%title%/gi, o.tPrev).replace(/%dir%/gi, "left")).addClass(r) 7284 , i = h.arrowRight = u(t.replace(/%title%/gi, o.tNext).replace(/%dir%/gi, "right")).addClass(r); 7285 e.click(function() { 7286 h.prev() 7287 }), 7288 i.click(function() { 7289 h.next() 7290 }), 7291 h.container.append(e.add(i)) 7292 } 7293 }), 7294 b("Change" + t, function() { 7295 h._preloadTimeout && clearTimeout(h._preloadTimeout), 7296 h._preloadTimeout = setTimeout(function() { 7297 h.preloadNearbyImages(), 7298 h._preloadTimeout = null 7299 }, 16) 7300 }), 7301 void b(l + t, function() { 7302 d.off(t), 7303 h.wrap.off("click" + t), 7304 h.arrowRight = h.arrowLeft = null 7305 })) 7306 }, 7307 next: function() { 7308 h.direction = !0, 7309 h.index = $(h.index + 1), 7310 h.updateItemHTML() 7311 }, 7312 prev: function() { 7313 h.direction = !1, 7314 h.index = $(h.index - 1), 7315 h.updateItemHTML() 7316 }, 7317 goTo: function(t) { 7318 h.direction = t >= h.index, 7319 h.index = t, 7320 h.updateItemHTML() 7321 }, 7322 preloadNearbyImages: function() { 7323 var t, e = h.st.gallery.preload, i = Math.min(e[0], h.items.length), n = Math.min(e[1], h.items.length); 7324 for (t = 1; t <= (h.direction ? n : i); t++) 7325 h._preloadItem(h.index + t); 7326 for (t = 1; t <= (h.direction ? i : n); t++) 7327 h._preloadItem(h.index - t) 7328 }, 7329 _preloadItem: function(t) { 7330 if (t = $(t), 7331 !h.items[t].preloaded) { 7332 var e = h.items[t]; 7333 e.parsed || (e = h.parseEl(t)), 7334 x("LazyLoad", e), 7335 "image" === e.type && (e.img = u('<img class="mfp-img" />').on("load.mfploader", function() { 7336 e.hasSize = !0 7337 }).on("error.mfploader", function() { 7338 e.hasSize = !0, 7339 e.loadError = !0, 7340 x("LazyLoadError", e) 7341 }).attr("src", e.src)), 7342 e.preloaded = !0 7343 } 7344 } 7345 } 7346 }); 7347 var N = "retina"; 7348 u.magnificPopup.registerModule(N, { 7349 options: { 7350 replaceSrc: function(t) { 7351 return t.src.replace(/\.\w+$/, function(t) { 7352 return "@2x" + t 7353 }) 7354 }, 7355 ratio: 1 7356 }, 7357 proto: { 7358 initRetina: function() { 7359 if (1 < window.devicePixelRatio) { 7360 var i = h.st.retina 7361 , n = i.ratio; 7362 1 < (n = isNaN(n) ? n() : n) && (b("ImageHasSize." + N, function(t, e) { 7363 e.img.css({
7364 "max-width": e.img[0].naturalWidth / n, 7365 width: "100%" 7366 }) 7367 }), 7368 b("ElementParse." + N, function(t, e) { 7369 e.src = i.replaceSrc(e, n) 7370 })) 7371 } 7372 } 7373 } 7374 }), 7375 k() 7376}), 7377function(c, k, C) { 7378 "use strict"; 7379 function e(t) { 7380 if (x = k.documentElement, 7381 n = k.body, 7382 W(), 7383 J = this, 7384 st = (t = t || {}).constants || {}, 7385 t.easing) 7386 for (var e in t.easing) 7387 F[e] = t.easing[e]; 7388 ht = t.edgeStrategy || "set", 7389 it = { 7390 beforerender: t.beforerender, 7391 render: t.render, 7392 keyframe: t.keyframe 7393 }, 7394 (nt = !1 !== t.forceHeight) && (Pt = t.scale || 1), 7395 ot = t.mobileDeceleration || u, 7396 at = !1 !== t.smoothScrolling, 7397 lt = t.smoothScrollingDuration || d, 7398 ct = { 7399 targetTop: J.getScrollTop() 7400 }, 7401 ($t = (t.mobileCheck || function() { 7402 return /Android|iPhone|iPad|iPod|BlackBerry/i.test(navigator.userAgent || navigator.vendor || c.opera) 7403 } 7404 )()) ? ((et = k.getElementById(t.skrollrBody || h)) && Z(), 7405 Q(), 7406 _t(x, [o, l], [r])) : _t(x, [o, a], [r]), 7407 J.refresh(), 7408 ft(c, "resize orientationchange", function() { 7409 var t = x.clientWidth 7410 , e = x.clientHeight; 7411 (e !== jt || t !== At) && (jt = e, 7412 At = t, 7413 Ot = !0) 7414 }); 7415 var i = R(); 7416 return function t() { 7417 B(), 7418 pt = i(t) 7419 }(), 7420 J 7421 } 7422 var x, n, S = { 7423 get: function() { 7424 return J 7425 }, 7426 init: function(t) { 7427 return J || new e(t) 7428 }, 7429 VERSION: "0.6.30" 7430 }, T = Object.prototype.hasOwnProperty, _ = c.Math, s = c.getComputedStyle, I = "touchstart", P = "touchmove", E = "touchcancel", M = "touchend", D = "skrollable", A = D + "-before", j = D + "-between", O = D + "-after", o = "skrollr", r = "no-" + o, a = o + "-desktop", l = o + "-mobile", u = .004, h = "skrollr-body", d = 200, z = "___skrollable_id", $ = /^(?:input|textarea|button|select)$/i, i = /^\s+|\s+$/g, L = /^data(?:-(_\w+))?(?:-?(-?\d*\.?\d+p?))?(?:-?(start|end|top|center|bottom))?(?:-?(top|center|bottom))?$/, p = /\s*(@?[\w\-\[\]]+)\s*:\s*(.+?)\s*(?:;|$)/gi, f = /^(@?[a-z\-]+)\[(\w+)\]$/, N = /-([a-z0-9_])/g, H = function(t, e) { 7431 return e.toUpperCase() 7432 }
7432, g = /[\-+]?[\d]*\.?[\d]+/g, m = /\{\?\}/g, v = /rgba?\(\s*-?\d+\s*,\s*-?\d+\s*,\s*-?\d+/g, y = /[a-z\-]+-gradient/g, b = "", w = "", W = function() { 7433 var t = /^(?:O|Moz|webkit|ms)|(?:-(?:o|moz|webkit|ms)-)/; 7434 if (s) { 7435 var e = s(n, null); 7436 for (var i in e) 7437 if (b = i.match(t) || +i == i && e[i].match(t)) 7438 break; 7439 if (!b) 7440 return void (b = w = ""); 7441 "-" === (b = b[0]).slice(0, 1) ? b = { 7442 "-webkit-": "webkit", 7443 "-moz-": "Moz", 7444 "-ms-": "ms", 7445 "-o-": "O" 7446 }[w = b] : w = "-" + b.toLowerCase() + "-" 7447 } 7448 }, R = function() { 7449 var t = c.requestAnimationFrame || c[b.toLowerCase() + "RequestAnimationFrame"] 7450 , n = St(); 7451 return ($t || !t) && (t = function(t) { 7452 var e = St() - n 7453 , i = _.max(0, 1e3 / 60 - e); 7454 return c.setTimeout(function() { 7455 n = St(), 7456 t() 7457 }, i) 7458 } 7459 ), 7460 t 7461 }, F = { 7462 begin: function() { 7463 return 0 7464 }, 7465 end: function() { 7466 return 1 7467 }, 7468 linear: function(t) { 7469 return t 7470 }, 7471 quadratic: function(t) { 7472 return t * t 7473 }, 7474 cubic: function(t) { 7475 return t * t * t 7476 }, 7477 swing: function(t) { 7478 return -_.cos(t * _.PI) / 2 + .5 7479 }, 7480 sqrt: function(t) { 7481 return _.sqrt(t) 7482 }, 7483 outCubic: function(t) { 7484 return _.pow(t - 1, 3) + 1 7485 }, 7486 bounce: function(t) { 7487 var e; 7488 if (t <= .5083) 7489 e = 3; 7490 else if (t <= .8489) 7491 e = 9; 7492 else if (t <= .96208) 7493 e = 27; 7494 else { 7495 if (!(t <= .99981)) 7496 return 1; 7497 e = 91 7498 } 7499 return 1 - _.abs(3 * _.cos(t * e * 1.028) / e) 7500 } 7501 }; 7502 e.prototype.refresh = function(t) { 7503 var e, i, n = !1; 7504 for (t === C ? (n = !0, 7505 tt = [], 7506 zt = 0, 7507 t = k.getElementsByTagName("*")) : t.length === C && (t = [t]), 7508 e = 0, 7509 i = t.length; e < i; e++) { 7510 var s = t[e] 7511 , o = s 7512 , r = [] 7513 , a = at 7514 , l = ht 7515 , c = !1; 7516 if (n && z in s && delete s[z], 7517 s.attributes) { 7518 for (var u = 0, h = s.attributes.length; u < h; u++) { 7519 var d = s.attributes[u]; 7520 if ("data-anchor-target" !== d.name) 7521 if ("data-smooth-scrolling" !== d.name) 7522 if ("data-edge-strategy" !== d.name) 7523 if ("data-emit-events" !== d.name) { 7524 var p = d.name.match(L); 7525 if (null !== p) { 7526 var f = { 7527 props: d.value, 7528 element: s, 7529 eventType: d.name.replace(N, H) 7530 }; 7531 r.push(f); 7532 var g = p[1]; 7533 g && (f.constant = g.substr(1)); 7534 var m = p[2]; 7535 /p$/.test(m) ? (f.isPercentage = !0, 7536 f.offset = (0 | m.slice(0, -1)) / 100) : f.offset = 0 | m; 7537 var v = p[3] 7538 , y = p[4] || v; 7539 v && "start" !== v && "end" !== v ? (f.mode = "relative", 7540 f.anchors = [v, y]) : (f.mode = "absolute", 7541 "end" === v ? f.isEnd = !0 : f.isPercentage || (f.offset = f.offset * Pt)) 7542 } 7543 } else 7544 c = !0; 7545 else 7546 l = d.value; 7547 else 7548 a = "off" !== d.value; 7549 else if (null === (o = k.querySelector(d.value))) 7550 throw 'Unable to find anchor target "' + d.value + '"' 7551 } 7552 var b, w, x; 7553 if (r.length) 7554 !n && z in s ? (x = s[z], 7555 b = tt[x].styleAttr, 7556 w = tt[x].classAttr) : (x = s[z] = zt++, 7557 b = s.style.cssText, 7558 w = xt(s)), 7559 tt[x] = { 7560 element: s, 7561 styleAttr: b, 7562 classAttr: w, 7563 anchorTarget: o, 7564 keyFrames: r, 7565 smoothScrolling: a, 7566 edgeStrategy: l, 7567 emitEvents: c, 7568 lastFrameIndex: -1 7569 }, 7570 _t(s, [D], []) 7571 } 7572 } 7573 for (yt(), 7574 e = 0, 7575 i = t.length; e < i; e++) { 7576 var _ = tt[t[e][z]]; 7577 _ !== C && (q(_), 7578 X(_)) 7579 } 7580 return J 7581 } 7582 , 7583 e.prototype.relativeToAbsolute = function(t, e, i) { 7584 var n = x.clientHeight 7585 , s = t.getBoundingClientRect() 7586 , o = s.top 7587 , r = s.bottom - s.top; 7588 return "bottom" === e ? o -= n : "center" === e && (o -= n / 2), 7589 "bottom" === i ? o += r : "center" === i && (o += r / 2), 7590 (o += J.getScrollTop()) + .5 | 0 7591 } 7592 , 7593 e.prototype.animateTo = function(t, e) { 7594 e = e || {}; 7595 var i = St() 7596 , n = J.getScrollTop() 7597 , s = e.duration === C ? 1e3 : e.duration; 7598 return (rt = { 7599 startTop: n, 7600 topDiff: t - n, 7601 targetTop: t, 7602 duration: s, 7603 startTime: i, 7604 endTime: i + s, 7605 easing: F[e.easing || "linear"], 7606 done: e.done 7607 }).topDiff || (rt.done && rt.done.call(J, !1), 7608 rt = C), 7609 J 7610 } 7611 , 7612 e.prototype.stopAnimateTo = function() { 7613 rt && rt.done && rt.done.call(J, !0), 7614 rt = C 7615 } 7616 , 7617 e.prototype.isAnimatingTo = function() { 7618 return !!rt 7619 } 7620 , 7621 e.prototype.isMobile = function() { 7622 return $t 7623 } 7624 , 7625 e.prototype.setScrollTop = function(t, e) { 7626 return ut = !0 === e, 7627 $t ? Lt = _.min(_.max(t, 0), It) : c.scrollTo(0, t), 7628 J 7629 } 7630 , 7631 e.prototype.getScrollTop = function() { 7632 return $t ? Lt : c.pageYOffset || x.scrollTop || n.scrollTop || 0 7633 } 7634 , 7635 e.prototype.getMaxScrollTop = function() { 7636 return It 7637 } 7638 , 7639 e.prototype.on = function(t, e) { 7640 return it[t] = e, 7641 J 7642 } 7643 , 7644 e.prototype.off = function(t) { 7645 return delete it[t], 7646 J 7647 } 7648 , 7649 e.prototype.destroy = function() { 7650 var t; 7651 (t = c.cancelAnimationFrame || c[b.toLowerCase() + "CancelAnimationFrame"], 7652 ($t || !t) && (t = function(t) { 7653 return c.clearTimeout(t) 7654 } 7655 ), 7656 t)(pt), 7657 mt(), 7658 _t(x, [r], [o, a, l]); 7659 for (var e = 0, i = tt.length; e < i; e++) 7660 G(tt[e].element); 7661 x.style.overflow = n.style.overflow = "", 7662 x.style.height = n.style.height = "", 7663 et && S.setStyle(et, "transform", "none"), 7664 Et = "down", 7665 $t = Ot = !(Mt = -(Pt = 1)), 7666 Lt = zt = jt = At = It = 0, 7667 dt = ht = ut = ct = lt = at = rt = ot = st = nt = it = et = J = C 7668 } 7669 ; 7670 var Q = function() { 7671 var u, h, d, p, f, g, m, v, y, b, w; 7672 ft(x, [I, P, E, M].join(" "), function(t) { 7673 var e = t.changedTouches[0]; 7674 for (p = t.target; 3 === p.nodeType; ) 7675 p = p.parentNode; 7676 switch (f = e.clientY, 7677 g = e.clientX, 7678 y = t.timeStamp, 7679 $.test(p.tagName) || t.preventDefault(), 7680 t.type) { 7681 case I: 7682 u && u.blur(), 7683 J.stopAnimateTo(), 7684 u = p, 7685 h = m = f, 7686 d = g, 7687 y; 7688 break; 7689 case P: 7690 $.test(p.tagName) && k.activeElement !== p && t.preventDefault(), 7691 v = f - m, 7692 w = y - b, 7693 J.setScrollTop(Lt - v, !0), 7694 m = f, 7695 b = y; 7696 break; 7697 default: 7698 case E: 7699 case M: 7700 var i = h - f 7701 , n = d - g; 7702 if (n * n + i * i < 49) { 7703 if (!$.test(u.tagName)) { 7704 u.focus(); 7705 var s = k.createEvent("MouseEvents"); 7706 s.initMouseEvent("click", !0, !0, t.view, 1, e.screenX, e.screenY, e.clientX, e.clientY, t.ctrlKey, t.altKey, t.shiftKey, t.metaKey, 0, null), 7707 u.dispatchEvent(s) 7708 } 7709 return 7710 } 7711 u = C; 7712 var o = v / w; 7713 o = _.max(_.min(o, 3), -3); 7714 var r = _.abs(o / ot) 7715 , a = o * r + .5 * ot * r * r 7716 , l = J.getScrollTop() - a 7717 , c = 0; 7718 It < l ? (c = (It - l) / a, 7719 l = It) : l < 0 && (c = -l / a, 7720 l = 0), 7721 r *= 1 - c, 7722 J.animateTo(l + .5 | 0, { 7723 easing: "outCubic", 7724 duration: r 7725 }) 7726 } 7727 }), 7728 c.scrollTo(0, 0), 7729 x.style.overflow = n.style.overflow = "hidden" 7730 } 7731 , B = function() { 7732 Ot && (Ot = !1, 7733 yt()); 7734 var t, e, i = J.getScrollTop(), n = St(); 7735 if (rt) 7736 n >= rt.endTime ? (i = rt.targetTop, 7737 t = rt.done, 7738 rt = C) : (e = rt.easing((n - rt.startTime) / rt.duration), 7739 i = rt.startTop + e * rt.topDiff | 0), 7740 J.setScrollTop(i, !0); 7741 else if (!ut) { 7742 ct.targetTop - i && (ct = { 7743 startTop: Mt, 7744 topDiff: i - Mt, 7745 targetTop: i, 7746 startTime: Dt, 7747 endTime: Dt + lt 7748 }),
7749 n <= ct.endTime && (e = F.sqrt((n - ct.startTime) / lt), 7750 i = ct.startTop + e * ct.topDiff | 0) 7751 } 7752 if (ut || Mt !== i) { 7753 var s = { 7754 curTop: i, 7755 lastTop: Mt, 7756 maxTop: It, 7757 direction: Et = Mt < i ? "down" : i < Mt ? "up" : Et 7758 }; 7759 (ut = !1) !== (it.beforerender && it.beforerender.call(J, s)) && (function(t, e) { 7760 for (var i = 0, n = tt.length; i < n; i++) { 7761 var s, o, r = tt[i], a = r.element, l = r.smoothScrolling ? t : e, c = r.keyFrames, u = c.length, h = c[0], d = c[c.length - 1], p = l < h.frame, f = l > d.frame, g = p ? h : d, m = r.emitEvents, v = r.lastFrameIndex; 7762 if (p || f) { 7763 if (p && -1 === r.edge || f && 1 === r.edge) 7764 continue; 7765 switch (p ? (_t(a, [A], [O, j]), 7766 m && -1 < v && (vt(a, h.eventType, Et), 7767 r.lastFrameIndex = -1)) : (_t(a, [O], [A, j]), 7768 m && v < u && (vt(a, d.eventType, Et), 7769 r.lastFrameIndex = u)), 7770 r.edge = p ? -1 : 1, 7771 r.edgeStrategy) { 7772 case "reset": 7773 G(a); 7774 continue; 7775 case "ease": 7776 l = g.frame; 7777 break; 7778 default: 7779 case "set": 7780 var y = g.props; 7781 for (s in y) 7782 T.call(y, s) && (o = K(y[s].value), 7783 0 === s.indexOf("@") ? a.setAttribute(s.substr(1), o) : S.setStyle(a, s, o)); 7784 continue 7785 } 7786 } else 7787 0 !== r.edge && (_t(a, [D, j], [A, O]), 7788 r.edge = 0); 7789 for (var b = 0; b < u - 1; b++) 7790 if (l >= c[b].frame && l <= c[b + 1].frame) { 7791 var w = c[b] 7792 , x = c[b + 1]; 7793 for (s in w.props) 7794 if (T.call(w.props, s)) { 7795 var _ = (l - w.frame) / (x.frame - w.frame); 7796 _ = w.props[s].easing(_), 7797 o = U(w.props[s].value, x.props[s].value, _), 7798 o = K(o), 7799 0 === s.indexOf("@") ? a.setAttribute(s.substr(1), o) : S.setStyle(a, s, o) 7800 } 7801 m && v !== b && (vt(a, "down" === Et ? w.eventType : x.eventType, Et), 7802 r.lastFrameIndex = b); 7803 break 7804 } 7805 } 7806 }(i, J.getScrollTop()), 7807 $t && et && S.setStyle(et, "transform", "translate(0, " + -Lt + "px) " + dt), 7808 Mt = i, 7809 it.render && it.render.call(J, s)), 7810 t && t.call(J, !1) 7811 } 7812 Dt = n 7813 } 7814 , q = function(t) { 7815 for (var e = 0, i = t.keyFrames.length; e < i; e++) { 7816 for (var n, s, o, r, a = t.keyFrames[e], l = {}; null !== (r = p.exec(a.props)); ) 7817 o = r[1], 7818 s = r[2], 7819 null !== (n = o.match(f)) ? (o = n[1], 7820 n = n[2]) : n = "linear",
7821 s = s.indexOf("!") ? Y(s) : [s.slice(1)], 7822 l[o] = { 7823 value: s, 7824 easing: F[n] 7825 }; 7826 a.props = l 7827 } 7828 } 7829 , Y = function(t) { 7830 var e = []; 7831 return v.lastIndex = 0, 7832 t = t.replace(v, function(t) { 7833 return t.replace(g, function(t) { 7834 return t / 255 * 100 + "%" 7835 }) 7836 }), 7837 w && (y.lastIndex = 0, 7838 t = t.replace(y, function(t) { 7839 return w + t 7840 })), 7841 t = t.replace(g, function(t) { 7842 return e.push(+t), 7843 "{?}" 7844 }), 7845 e.unshift(t), 7846 e 7847 } 7848 , X = function(t) { 7849 var e, i, n = {}; 7850 for (e = 0, 7851 i = t.keyFrames.length; e < i; e++) 7852 V(t.keyFrames[e], n); 7853 for (n = {}, 7854 e = t.keyFrames.length - 1; 0 <= e; e--) 7855 V(t.keyFrames[e], n) 7856 } 7857 , V = function(t, e) { 7858 var i; 7859 for (i in e) 7860 T.call(t.props, i) || (t.props[i] = e[i]); 7861 for (i in t.props) 7862 e[i] = t.props[i] 7863 } 7864 , U = function(t, e, i) { 7865 var n, s = t.length; 7866 if (s !== e.length) 7867 throw "Can't interpolate between \"" + t[0] + '" and "' + e[0] + '"'; 7868 var o = [t[0]]; 7869 for (n = 1; n < s; n++) 7870 o[n] = t[n] + (e[n] - t[n]) * i; 7871 return o 7872 } 7873 , K = function(t) { 7874 var e = 1; 7875 return m.lastIndex = 0, 7876 t[0].replace(m, function() { 7877 return t[e++] 7878 }) 7879 } 7880 , G = function(t, e) { 7881 for (var i, n, s = 0, o = (t = [].concat(t)).length; s < o; s++) 7882 n = t[s], 7883 (i = tt[n[z]]) && (e ? (n.style.cssText = i.dirtyStyleAttr, 7884 _t(n, i.dirtyClassAttr)) : (i.dirtyStyleAttr = n.style.cssText, 7885 i.dirtyClassAttr = xt(n), 7886 n.style.cssText = i.styleAttr, 7887 _t(n, i.classAttr))) 7888 } 7889 , Z = function() { 7890 dt = "translateZ(0)", 7891 S.setStyle(et, "transform", dt); 7892 var t = s(et) 7893 , e = t.getPropertyValue("transform") 7894 , i = t.getPropertyValue(w + "transform"); 7895 e && "none" !== e || i && "none" !== i || (dt = "") 7896 }; 7897 S.setStyle = function(t, e, i) { 7898 var n = t.style; 7899 if ("zIndex" === (e = e.replace(N, H).replace("-", ""))) 7900 isNaN(i) ? n[e] = i : n[e] = "" + (0 | i); 7901 else if ("float" === e) 7902 n.styleFloat = n.cssFloat = i; 7903 else 7904 try { 7905 b && (n[b + e.slice(0, 1).toUpperCase() + e.slice(1)] = i), 7906 n[e] = i 7907 } catch (t) {} 7908 } 7909 ; 7910 var J, tt, et, it, nt, st, ot, rt, at, lt, ct, ut, ht, dt, pt, ft = S.addEvent = function(t, e, i) { 7911 for (var n, s = function(t) { 7912 return (t = t || c.event).target || (t.target = t.srcElement), 7913 t.preventDefault || (t.preventDefault = function() { 7914 t.returnValue = !1, 7915 t.defaultPrevented = !0 7916 } 7917 ), 7918 i.call(this, t) 7919 }, o = 0, r = (e = e.split(" ")).length; o < r; o++) 7920 n = e[o], 7921 t.addEventListener ? t.addEventListener(n, i, !1) : t.attachEvent("on" + n, s), 7922 Nt.push({ 7923 element: t, 7924 name: n, 7925 listener: i 7926 }) 7927 } 7928 , gt = S.removeEvent = function(t, e, i) { 7929 for (var n = 0, s = (e = e.split(" ")).length; n < s; n++) 7930 t.removeEventListener ? t.removeEventListener(e[n], i, !1) : t.detachEvent("on" + e[n], i) 7931 } 7932 , mt = function() { 7933 for (var t, e = 0, i = Nt.length; e < i; e++) 7934 t = Nt[e],
7935 gt(t.element, t.name, t.listener); 7936 Nt = [] 7937 }, vt = function(t, e, i) { 7938 it.keyframe && it.keyframe.call(J, t, e, i) 7939 }, yt = function() { 7940 var t = J.getScrollTop(); 7941 It = 0, 7942 nt && !$t && (n.style.height = ""), 7943 function() { 7944 var t, e, i, n, s, o, r, a, l, c, u, h = x.clientHeight, d = bt(); 7945 for (a = 0, 7946 l = tt.length; a < l; a++) 7947 for (e = (t = tt[a]).element, 7948 i = t.anchorTarget, 7949 s = 0, 7950 o = (n = t.keyFrames).length; s < o; s++) 7951 c = (r = n[s]).offset, 7952 u = d[r.constant] || 0, 7953 r.frame = c, 7954 r.isPercentage && (c *= h, 7955 r.frame = c), 7956 "relative" === r.mode && (G(e), 7957 r.frame = J.relativeToAbsolute(i, r.anchors[0], r.anchors[1]) - c, 7958 G(e, !0)), 7959 r.frame += u, 7960 nt && !r.isEnd && r.frame > It && (It = r.frame); 7961 for (It = _.max(It, wt()), 7962 a = 0, 7963 l = tt.length; a < l; a++) { 7964 for (s = 0, 7965 o = (n = (t = tt[a]).keyFrames).length; s < o; s++) 7966 u = d[(r = n[s]).constant] || 0, 7967 r.isEnd && (r.frame = It - r.offset + u); 7968 t.keyFrames.sort(Tt) 7969 } 7970 }(), 7971 nt && !$t && (n.style.height = It + x.clientHeight + "px"), 7972 $t ? J.setScrollTop(_.min(J.getScrollTop(), It)) : J.setScrollTop(t, !0), 7973 ut = !0 7974 }, bt = function() { 7975 var t, e, i = x.clientHeight, n = {}; 7976 for (t in st) 7977 "function" == typeof (e = st[t]) ? e = e.call(J) : /p$/.test(e) && (e = e.slice(0, -1) / 100 * i), 7978 n[t] = e; 7979 return n 7980 }, wt = function() { 7981 var t = 0; 7982 return et && (t = _.max(et.offsetHeight, et.scrollHeight)), 7983 _.max(t, n.scrollHeight, n.offsetHeight, x.scrollHeight, x.offsetHeight, x.clientHeight) - x.clientHeight 7984 }, xt = function(t) { 7985 var e = "className"; 7986 return c.SVGElement && t instanceof c.SVGElement && (t = t[e], 7987 e = "baseVal"), 7988 t[e] 7989 }, _t = function(t, e, i) { 7990 var n = "className"; 7991 if (c.SVGElement && t instanceof c.SVGElement && (t = t[n], 7992 n = "baseVal"), 7993 i !== C) { 7994 for (var s = t[n], o = 0, r = i.length; o < r; o++) 7995 s = Ct(s).replace(Ct(i[o]), " "); 7996 s = kt(s); 7997 for (var a = 0, l = e.length; a < l; a++) 7998 -1 === Ct(s).indexOf(Ct(e[a])) && (s += " " + e[a]); 7999 t[n] = kt(s) 8000 } else 8001 t[n] = e 8002 }, kt = function(t) { 8003 return t.replace(i, "") 8004 }, Ct = function(t) { 8005 return " " + t + " " 8006 }, St = Date.now || function() { 8007 return +new Date 8008 } 8009 , Tt = function(t, e) { 8010 return t.frame - e.frame 8011 }, It = 0, Pt = 1, Et = "down", Mt = -1, Dt = St(), At = 0, jt = 0, Ot = !1, zt = 0, $t = !1, Lt = 0, Nt = []; 8012 "function" == typeof define && define.amd ? define([], function() { 8013 return S 8014 }) : "undefined" != typeof module && module.exports ? module.exports = S : c.skrollr = S 8015}(window, document), 8016function(t) { 8017 var p, f, d = "hasOwnProperty", g = /[\.\/]/, m = /\s*,\s*/, v = function(t, e) { 8018 return t - e 8019 }, y = { 8020 n: {} 8021 }, b = function() { 8022 for (var t = 0, e = this.length; t < e; t++) 8023 if (void 0 !== this[t]) 8024 return this[t] 8025 }, w = function() { 8026 for (var t = this.length; --t; ) 8027 if (void 0 !== this[t]) 8028 return this[t] 8029 }, x = function(t, e) { 8030 t = String(t); 8031 var i, n = f, s = Array.prototype.slice.call(arguments, 2), o = x.listeners(t), r = 0, a = [], l = {}, c = [], u = p; 8032 c.firstDefined = b, 8033 c.lastDefined = w, 8034 p = t; 8035 for (var h = f = 0, d = o.length; h < d; h++) 8036 "zIndex"in o[h] && (a.push(o[h].zIndex), 8037 o[h].zIndex < 0 && (l[o[h].zIndex] = o[h])); 8038 for (a.sort(v); a[r] < 0; ) 8039 if (i = l[a[r++]], 8040 c.push(i.apply(e, s)), 8041 f) 8042 return f = n, 8043 c; 8044 for (h = 0; h < d; h++) 8045 if ("zIndex"in (i = o[h])) 8046 if (i.zIndex == a[r]) { 8047 if (c.push(i.apply(e, s)), 8048 f) 8049 break; 8050 do { 8051 if ((i = l[a[++r]]) && c.push(i.apply(e, s)), 8052 f) 8053 break 8054 } while (i) 8055 } else 8056 l[i.zIndex] = i; 8057 else if (c.push(i.apply(e, s)), 8058 f) 8059 break; 8060 return f = n, 8061 p = u, 8062 c 8063 }; 8064 x._events = y, 8065 x.listeners = function(t) { 8066 var e, i, n, s, o, r, a, l, c = t.split(g), u = y, h = [u], d = []; 8067 for (s = 0, 8068 o = c.length; s < o; s++) { 8069 for (l = [], 8070 r = 0, 8071 a = h.length; r < a; r++) 8072 for (i = [(u = h[r].n)[c[s]], u["*"]], 8073 n = 2; n--; ) 8074 (e = i[n]) && (l.push(e), 8075 d = d.concat(e.f || [])); 8076 h = l 8077 } 8078 return d 8079 } 8080 , 8081 x.on = function(t, o) { 8082 if (t = String(t), 8083 "function" != typeof o) 8084 return function() {} 8085 ; 8086 for (var r = t.split(m), a = 0, e = r.length; a < e; a++) 8087 !function() { 8088 for (var t, e = r[a].split(g), i = y, n = 0, s = e.length; n < s; n++) 8089 i = (i = i.n).hasOwnProperty(e[n]) && i[e[n]] || (i[e[n]] = { 8090 n: {} 8091 }); 8092 for (i.f = i.f || [], 8093 n = 0, 8094 s = i.f.length; n < s; n++) 8095 if (i.f[n] == o) { 8096 t = !0; 8097 break 8098 }
8099 !t && i.f.push(o) 8100 }(); 8101 return function(t) { 8102 +t == +t && (o.zIndex = +t) 8103 } 8104 } 8105 , 8106 x.f = function(t) { 8107 var e = [].slice.call(arguments, 1); 8108 return function() { 8109 x.apply(null, [t, null].concat(e).concat([].slice.call(arguments, 0))) 8110 } 8111 } 8112 , 8113 x.stop = function() { 8114 f = 1 8115 } 8116 , 8117 x.nt = function(t) { 8118 return t ? new RegExp("(?:\\.|\\/|^)" + t + "(?:\\.|\\/|$)").test(p) : p 8119 } 8120 , 8121 x.nts = function() { 8122 return p.split(g) 8123 } 8124 , 8125 x.off = x.unbind = function(t, e) { 8126 if (t) { 8127 var i = t.split(m); 8128 if (1 < i.length) 8129 for (var n = 0, s = i.length; n < s; n++) 8130 x.off(i[n], e); 8131 else { 8132 i = t.split(g); 8133 var o, r, a, l, c, u = [y]; 8134 for (n = 0, 8135 s = i.length; n < s; n++) 8136 for (l = 0; l < u.length; l += a.length - 2) { 8137 if (a = [l, 1], 8138 o = u[l].n, 8139 "*" != i[n]) 8140 o[i[n]] && a.push(o[i[n]]); 8141 else 8142 for (r in o) 8143 o[d](r) && a.push(o[r]); 8144 u.splice.apply(u, a) 8145 } 8146 for (n = 0, 8147 s = u.length; n < s; n++) 8148 for (o = u[n]; o.n; ) { 8149 if (e) { 8150 if (o.f) { 8151 for (l = 0, 8152 c = o.f.length; l < c; l++) 8153 if (o.f[l] == e) { 8154 o.f.splice(l, 1); 8155 break 8156 } 8157 !o.f.length && delete o.f 8158 } 8159 for (r in o.n) 8160 if (o.n[d](r) && o.n[r].f) { 8161 var h = o.n[r].f; 8162 for (l = 0, 8163 c = h.length; l < c; l++) 8164 if (h[l] == e) { 8165 h.splice(l, 1); 8166 break 8167 } 8168 !h.length && delete o.n[r].f 8169 } 8170 } else 8171 for (r in delete o.f, 8172 o.n) 8173 o.n[d](r) && o.n[r].f && delete o.n[r].f; 8174 o = o.n 8175 } 8176 } 8177 } else 8178 x._events = y = { 8179 n: {} 8180 } 8181 } 8182 , 8183 x.once = function(t, e) { 8184 var i = function() { 8185 return x.unbind(t, i), 8186 e.apply(this, arguments) 8187 }; 8188 return x.on(t, i) 8189 } 8190 , 8191 x.version = "0.4.2", 8192 x.toString = function() { 8193 return "You are running Eve 0.4.2" 8194 } 8195 , 8196 "undefined" != typeof module && module.exports ? module.exports = x : "function" == typeof define && define.amd ? define("eve", [], function() { 8197 return x 8198 }) : t.eve = x 8199}(this), 8200function(e, i) { 8201 if ("function" == typeof define && define.amd) 8202 define(["eve"], function(t) { 8203 return i(e, t) 8204 }); 8205 else if ("undefined" != typeof exports) { 8206 var t = require("eve"); 8207 module.exports = i(e, t) 8208 } else 8209 i(e, e.eve) 8210}(window || this, function(x, V) { 8211 var s, u, h, o, d, p, t, f, m, v, y, b, w, _, k, C, S = (s = void 0 === V ? function() {} 8212 : V, 8213 u = {}, 8214 h = x.requestAnimationFrame || x.webkitRequestAnimationFrame || x.mozRequestAnimationFrame || x.oRequestAnimationFrame || x.msRequestAnimationFrame || function(t) { 8215 setTimeout(t, 16) 8216 } 8217 , 8218 o = Array.isArray || function(t) { 8219 return t instanceof Array || "[object Array]" == Object.prototype.toString.call(t) 8220 } 8221 , 8222 d = 0, 8223 p = "M" + (+new Date).toString(36), 8224 t = Date.now || function() { 8225 return +new Date 8226 } 8227 , 8228 f = function(t) { 8229 if (null == t) 8230 return this.s; 8231 var e = this.s - t; 8232 this.b += this.dur * e, 8233 this.B += this.dur * e, 8234 this.s = t 8235 } 8236 , 8237 m = function(t) { 8238 return null == t ? this.spd : void (this.spd = t) 8239 } 8240 , 8241 v = function(t) { 8242 return null == t ? this.dur : (this.s = this.s * t / this.dur, 8243 void (this.dur = t)) 8244 } 8245 , 8246 y = function() { 8247 delete u[this.id], 8248 this.update(), 8249 s("mina.stop." + this.id, this) 8250 } 8251 , 8252 b = function() { 8253 this.pdif || (delete u[this.id], 8254 this.update(), 8255 this.pdif = this.get() - this.b) 8256 } 8257 , 8258 w = function() { 8259 this.pdif && (this.b = this.get() - this.pdif, 8260 delete this.pdif, 8261 u[this.id] = this) 8262 } 8263 , 8264 _ = function() { 8265 var t, e = this; 8266 if (o(e.start)) { 8267 t = []; 8268 for (var i = 0, n = e.start.length; i < n; i++) 8269 t[i] = +e.start[i] + (e.end[i] - e.start[i]) * e.easing(e.s) 8270 } else 8271 t = +e.start + (e.end - e.start) * e.easing(e.s); 8272 e.set(t) 8273 } 8274 , 8275 k = function() { 8276 var t = 0; 8277 for (var e in u) 8278 if (u.hasOwnProperty(e)) { 8279 var i = u[e] 8280 , n = i.get(); 8281 t++, 8282 i.s = (n - i.b) / (i.dur / i.spd), 8283 1 <= i.s && (delete u[e], 8284 i.s = 1, 8285 t--, 8286 function(t) { 8287 setTimeout(function() { 8288 s("mina.finish." + t.id, t) 8289 }) 8290 }(i)), 8291 i.update() 8292 } 8293 t && h(k) 8294 } 8295 , 8296 (C = function(t, e, i, n, s, o, r) { 8297 var a = { 8298 id: p + (d++).toString(36), 8299 start: t, 8300 end: e, 8301 b: i, 8302 s: 0, 8303 dur: n - i, 8304 spd: 1, 8305 get: s, 8306 set: o, 8307 easing: r || C.linear, 8308 status: f, 8309 speed: m, 8310 duration: v, 8311 stop: y, 8312 pause: b, 8313 resume: w, 8314 update: _ 8315 }; 8316 u[a.id] = a; 8317 var l, c = 0; 8318 for (l in u) 8319 if (u.hasOwnProperty(l) && 2 == ++c) 8320 break; 8321 return 1 == c && h(k), 8322 a 8323 } 8324 ).time = t, 8325 C.getById = function(t) { 8326 return u[t] || null 8327 } 8328 , 8329 C.linear = function(t) { 8330 return t 8331 } 8332 , 8333 C.easeout = function(t) { 8334 return Math.pow(t, 1.7) 8335 } 8336 , 8337 C.easein = function(t) { 8338 return Math.pow(t, .48) 8339 } 8340 , 8341 C.easeinout = function(t) { 8342 if (1 == t) 8343 return 1; 8344 if (0 == t) 8345 return 0; 8346 var e = .48 - t / 1.04 8347 , i = Math.sqrt(.1734 + e * e) 8348 , n = i - e 8349 , s = -i - e 8350 , o = Math.pow(Math.abs(n), 1 / 3) * (n < 0 ? -1 : 1) + Math.pow(Math.abs(s), 1 / 3) * (s < 0 ? -1 : 1) + .5; 8351 return 3 * (1 - o) * o * o + o * o * o 8352 } 8353 , 8354 C.backin = function(t) { 8355 return 1 == t ? 1 : t * t * (2.70158 * t - 1.70158) 8356 } 8357 , 8358 C.backout = function(t) { 8359 return 0 == t ? 0 : (t -= 1) * t * (2.70158 * t + 1.70158) + 1 8360 } 8361 , 8362 C.elastic = function(t) { 8363 return t == !!t ? t : Math.pow(2, -10 * t) * Math.sin(2 * (t - .075) * Math.PI / .3) + 1 8364 } 8365 , 8366 C.bounce = function(t) { 8367 var e = 7.5625; 8368 return t < 1 / 2.75 ? e * t * t : t < 2 / 2.75 ? e * (t -= 1.5 / 2.75) * t + .75 : t < 2.5 / 2.75 ? e * (t -= 2.25 / 2.75) * t + .9375 : e * (t -= 2.625 / 2.75) * t + .984375 8369 } 8370 , 8371 x.mina = C), e = function(t) { 8372 function m(t, e) { 8373 if (t) { 8374 if (t.nodeType) 8375 return f(t); 8376 if (u(t, "array") && m.set) 8377 return m.set.apply(m, t); 8378 if (t instanceof l) 8379 return t; 8380 if (null == e) 8381 return f(t = v.doc.querySelector(String(t))) 8382 } 8383 return new p(t = null == t ? "100%" : t,e = null == e ? "100%" : e) 8384 } 8385 function c(t, e) { 8386 if (e) { 8387 if ("#text" == t && (t = v.doc.createTextNode(e.text || e["#text"] || "")), 8388 "#comment" == t && (t = v.doc.createComment(e.text || e["#text"] || "")), 8389 "string" == typeof t && (t = c(t)), 8390 "string" == typeof e) 8391 return 1 == t.nodeType ? "xlink:" == e.substring(0, 6) ? t.getAttributeNS(L, e.substring(6)) : "xml:" == e.
8391substring(0, 4) ? t.getAttributeNS(N, e.substring(4)) : t.getAttribute(e) : "text" == e ? t.nodeValue : null; 8392 if (1 == t.nodeType) { 8393 for (var i in e) 8394 if (e[y](i)) { 8395 var n = b(e[i]); 8396 n ? "xlink:" == i.substring(0, 6) ? t.setAttributeNS(L, i.substring(6), n) : "xml:" == i.substring(0, 4) ? t.setAttributeNS(N, i.substring(4), n) : t.setAttribute(i, n) : t.removeAttribute(i) 8397 } 8398 } else 8399 "text"in e && (t.nodeValue = e.text) 8400 } else 8401 t = v.doc.createElementNS(N, t); 8402 return t 8403 } 8404 function u(t, e) { 8405 return "finite" == (e = b.prototype.toLowerCase.call(e)) ? isFinite(t) : !("array" != e || !(t instanceof Array || Array.isArray && Array.isArray(t))) || ("null" == e && null === t || e == typeof t && null !== t || "object" == e && t === Object(t) || n.call(t).slice(8, -1).toLowerCase() == e) 8406 } 8407 function e(o, r, a) { 8408 return function t() { 8409 var e = Array.prototype.slice.call(arguments, 0) 8410 , i = e.join("â") 8411 , n = t.cache = t.cache || {} 8412 , s = t.count = t.count || []; 8413 return n[y](i) ? function(t, e) { 8414 for (var i = 0, n = t.length; i < n; i++) 8415 if (t[i] === e) 8416 return t.push(t.splice(i, 1)[0]) 8417 }(s, i) : (1e3 <= s.length && delete n[s.shift()], 8418 s.push(i), 8419 n[i] = o.apply(r, e)), 8420 a ? a(n[i]) : n[i] 8421 } 8422 } 8423 function s(t) { 8424 return t % 360 * T / 180 8425 } 8426 function h(t) { 8427 return t.node.ownerSVGElement && f(t.node.ownerSVGElement) || m.select("svg") 8428 } 8429 function o(t) { 8430 u(t, "array") || (t = Array.prototype.slice.call(arguments, 0)); 8431 for (var e = 0, i = 0, n = this.node; this[e]; ) 8432 delete this[e++]; 8433 for (e = 0; e < t.length; e++) 8434 "set" == t[e].type ? t[e].forEach(function(t) { 8435 n.appendChild(t.node) 8436 }) : n.appendChild(t[e].node); 8437 var s = n.childNodes; 8438 for (e = 0; e < s.length; e++) 8439 this[i++] = f(s[e]); 8440 return this 8441 } 8442 function l(t) { 8443 if (t.snap in H) 8444 return H[t.snap]; 8445 var e; 8446 try { 8447 e = t.ownerSVGElement 8448 } catch (t) {} 8449 this.node = t, 8450 e && (this.paper = new p(e)), 8451 this.type = t.tagName || t.nodeName; 8452 var i = this.id = $(this); 8453 if (this.anims = {}, 8454 this._ = { 8455 transform: [] 8456 }, 8457 t.snap = i, 8458 "g" == (H[i] = this).type && (this.add = o), 8459 this.type in { 8460 g: 1, 8461 mask: 1, 8462 pattern: 1, 8463 symbol: 1 8464 }) 8465 for (var n in p.prototype) 8466 p.prototype[y](n) && (this[n] = p.prototype[n]) 8467 } 8468 function r(t) { 8469 this.node = t 8470 } 8471 function d(t, e) { 8472 var i = c(t); 8473 return e.appendChild(i), 8474 f(i) 8475 } 8476 function p(t, e) { 8477 var i, n, s, o = p.prototype; 8478 if (t && "svg" == t.tagName) { 8479 if (t.snap in H) 8480 return H[t.snap]; 8481 var r = t.ownerDocument; 8482 for (var a in i = new l(t), 8483 n = t.getElementsByTagName("desc")[0], 8484 s = t.getElementsByTagName("defs")[0], 8485 n || ((n = c("desc")).appendChild(r.createTextNode("Created with Snap")), 8486 i.node.appendChild(n)), 8487 s || (s = c("defs"), 8488 i.node.appendChild(s)), 8489 i.defs = s, 8490 o) 8491 o[y](a) && (i[a] = o[a]); 8492 i.paper = i.root = i 8493 } else 8494 c((i = d("svg", v.doc.body)).node, { 8495 height: e, 8496 version: 1.1, 8497 width: t, 8498 xmlns: N 8499 }); 8500 return i 8501 } 8502 function f(t) { 8503 return t ? t instanceof l || t instanceof r ? t : t.tagName && "svg" == t.tagName.toLowerCase() ? new p(t) : t.tagName && "object" == t.tagName.toLowerCase() && "image/svg+xml" == t.type ? new p(t.contentDocument.getElementsByTagName("svg")[0]) : new l(t) : t 8504 } 8505 m.version = "0.4.0", 8506 m.toString = function() { 8507 return "Snap v" + this.version 8508 } 8509 , 8510 m._ = {}; 8511 var v = { 8512 win: t.window, 8513 doc: t.window.document 8514 }; 8515 m._.glob = v; 8516 var i, a, y = "hasOwnProperty", b = String, w = parseFloat, x = parseInt, _ = Math, k = _.max, C = _.min, S = _.abs, T = (_.pow, 8517 _.PI), I = (_.round, 8518 ""), n = Object.prototype.toString, P = /^\s*((#[a-f\d]{6})|(#[a-f\d]{3})|rgba?\(\s*([\d\.]+%?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+%?(?:\s*,\s*[\d\.]+%?)?)\s*\)|hsba?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+(?:%?\s*,\s*[\d\.]+)?%?)\s*\)|hsla?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+(?:%?\s*,\s*[\d\.]+)?%?)\s*\))\s*$/i, E = (m._.separator = /[,\s]+/, 8519 /[\s]*,[\s]*/), M = { 8520 hs: 1, 8521 rg: 1 8522 }, D = /([a-z])[\s,]*((-?\d*\.?\d*(?:e[\-+]?\d+)?[\s]*,?[\s]*)+)/gi, A = /([rstm])[\s,]*((-?\d*\.?\d*(?:e[\-+]?\d+)?[\s]*,?[\s]*)+)/gi, j = /(-?\d*\.?\d*(?:e[\-+]?\\d+)?)[\s]*,?[\s]*/gi, O = 0, z = "S" + (+new Date).toString(36), $ = function(t) { 8523 return (t && t.type ? t.type : I) + z + (O++).toString(36) 8524 }, L = "http://www.w3.org/1999/xlink", N = "http://www.w3.org/2000/svg", H = {}; 8525 m.url = function(t) { 8526 return "url('#" + t + "')" 8527 } 8528 , 8529 m._.$ = c, 8530 m._.id = $, 8531 m.format = (i = /\{([^\}]+)\}/g, 8532 a = /(?:(?:^|\.)(.+?)(?=\[|\.|$|\()|\[('|")(.+?)\2\])(\(\))?/g, 8533 function(t, s) { 8534 return b(t).replace(i, function(t, e) { 8535 return i = t, 8536 o = n = s, 8537 e.replace(a, function(t, e, i, n, s) { 8538 e = e || n, 8539 o && (e in o && (o = o[e]), 8540 "function" == typeof o && s && (o = o())) 8541 }), 8542 o = (null == o || o == n ? i : o) + ""; 8543 var i, n, o 8544 }) 8545 } 8546 ), 8547 m._.clone = function t(e) {
8548 if ("function" == typeof e || Object(e) !== e) 8549 return e; 8550 var i = new e.constructor; 8551 for (var n in e) 8552 e[y](n) && (i[n] = t(e[n])); 8553 return i 8554 } 8555 , 8556 m._.cacher = e, 8557 m.rad = s, 8558 m.deg = function(t) { 8559 return 180 * t / T % 360 8560 } 8561 , 8562 m.sin = function(t) { 8563 return _.sin(m.rad(t)) 8564 } 8565 , 8566 m.tan = function(t) { 8567 return _.tan(m.rad(t)) 8568 } 8569 , 8570 m.cos = function(t) { 8571 return _.cos(m.rad(t)) 8572 } 8573 , 8574 m.asin = function(t) { 8575 return m.deg(_.asin(t)) 8576 } 8577 , 8578 m.acos = function(t) { 8579 return m.deg(_.acos(t)) 8580 } 8581 , 8582 m.atan = function(t) { 8583 return m.deg(_.atan(t)) 8584 } 8585 , 8586 m.atan2 = function(t) { 8587 return m.deg(_.atan2(t)) 8588 } 8589 , 8590 m.angle = function t(e, i, n, s, o, r) { 8591 if (null == o) { 8592 var a = e - n 8593 , l = i - s; 8594 return a || l ? (180 + 180 * _.atan2(-l, -a) / T + 360) % 360 : 0 8595 } 8596 return t(e, i, o, r) - t(n, s, o, r) 8597 } 8598 , 8599 m.len = function(t, e, i, n) { 8600 return Math.sqrt(m.len2(t, e, i, n)) 8601 } 8602 , 8603 m.len2 = function(t, e, i, n) { 8604 return (t - i) * (t - i) + (e - n) * (e - n) 8605 } 8606 , 8607 m.closestPoint = function(t, n, s) { 8608 function e(t) { 8609 var e = t.x - n 8610 , i = t.y - s; 8611 return e * e + i * i 8612 } 8613 for (var i, o, r, a, l = t.node, c = l.getTotalLength(), u = c / l.pathSegList.numberOfItems * .125, h = 1 / 0, d = 0; d <= c; d += u) 8614 (a = e(r = l.getPointAtLength(d))) < h && (i = r, 8615 o = d, 8616 h = a); 8617 for (u *= .5; .5 < u; ) { 8618 var p, f, g, m, v, y; 8619 0 <= (g = o - u) && (v = e(p = l.getPointAtLength(g))) < h ? (i = p, 8620 o = g, 8621 h = v) : (m = o + u) <= c && (y = e(f = l.getPointAtLength(m))) < h ? (i = f, 8622 o = m, 8623 h = y) : u *= .5 8624 } 8625 return { 8626 x: i.x, 8627 y: i.y, 8628 length: o, 8629 distance: Math.sqrt(h) 8630 } 8631 } 8632 , 8633 m.is = u, 8634 m.snapTo = function(t, e, i) { 8635 if (i = u(i, "finite") ? i : 10, 8636 u(t, "array")) { 8637 for (var n = t.length; n--; ) 8638 if (S(t[n] - e) <= i) 8639 return t[n] 8640 } else { 8641 var s = e % (t = +t); 8642 if (s < i) 8643 return e - s; 8644 if (t - i < s) 8645 return e - s + t 8646 } 8647 return e 8648 } 8649 , 8650 m.getRGB = e(function(t) { 8651 if (!t || (t = b(t)).indexOf("-") + 1) 8652 return { 8653 r: -1, 8654 g: -1, 8655 b: -1, 8656 hex: "none", 8657 error: 1, 8658 toString: Q 8659 }; 8660 if ("none" == t) 8661 return { 8662 r: -1, 8663 g: -1, 8664 b: -1, 8665 hex: "none", 8666 toString: Q 8667 }; 8668 if (!(M[y](t.toLowerCase().substring(0, 2)) || "#" == t.charAt()) && (t = W(t)), 8669 !t) 8670 return { 8671 r: -1, 8672 g: -1, 8673 b: -1, 8674 hex: "none", 8675 error: 1, 8676 toString: Q 8677 }; 8678 var e, i, n, s, o, r, a = t.match(P); 8679 return a ? (a[2] && (n = x(a[2].substring(5), 16), 8680 i = x(a[2].substring(3, 5), 16), 8681 e = x(a[2].substring(1, 3), 16)), 8682 a[3] && (n = x((o = a[3].charAt(3)) + o, 16), 8683 i = x((o = a[3].charAt(2)) + o, 16), 8684 e = x((o = a[3].charAt(1)) + o, 16)), 8685 a[4] && (r = a[4].split(E), 8686 e = w(r[0]), 8687 "%" == r[0].slice(-1) && (e *= 2.55), 8688 i = w(r[1]), 8689 "%" == r[1].slice(-1) && (i *= 2.55), 8690 n = w(r[2]), 8691 "%" == r[2].slice(-1) && (n *= 2.55), 8692 "rgba" == a[1].toLowerCase().slice(0, 4) && (s = w(r[3])), 8693 r[3] && "%" == r[3].slice(-1) && (s /= 100)), 8694 a[5] ? (r = a[5].split(E), 8695 e = w(r[0]), 8696 "%" == r[0].slice(-1) && (e /= 100), 8697 i = w(r[1]), 8698 "%" == r[1].slice(-1) && (i /= 100), 8699 n = w(r[2]), 8700 "%" == r[2].slice(-1) && (n /= 100), 8701 ("deg" == r[0].slice(-3) || "°" == r[0].slice(-1)) && (e /= 360), 8702 "hsba" == a[1].toLowerCase().slice(0, 4) && (s = w(r[3])), 8703 r[3] && "%" == r[3].slice(-1) && (s /= 100), 8704 m.hsb2rgb(e, i, n, s)) : a[6] ? (r = a[6].split(E), 8705 e = w(r[0]), 8706 "%" == r[0].slice(-1) && (e /= 100), 8707 i = w(r[1]), 8708 "%" == r[1].slice(-1) && (i /= 100), 8709 n = w(r[2]), 8710 "%" == r[2].slice(-1) && (n /= 100), 8711 ("deg" == r[0].slice(-3) || "°" == r[0].slice(-1)) && (e /= 360), 8712 "hsla" == a[1].toLowerCase().slice(0, 4) && (s = w(r[3])), 8713 r[3] && "%" == r[3].slice(-1) && (s /= 100), 8714 m.hsl2rgb(e, i, n, s)) : (e = C(_.round(e), 255), 8715 i = C(_.round(i), 255), 8716 n = C(_.round(n), 255), 8717 s = C(k(s, 0), 1), 8718 (a = { 8719 r: e, 8720 g: i, 8721 b: n, 8722 toString: Q 8723 }).hex = "#" + (16777216 | n | i << 8 | e << 16).toString(16).slice(1), 8724 a.opacity = u(s, "finite") ? s : 1, 8725 a)) : { 8726 r: -1, 8727 g: -1, 8728 b: -1, 8729 hex: "none", 8730 error: 1, 8731 toString: Q 8732 } 8733 }, m), 8734 m.hsb = e(function(t, e, i) { 8735 return m.hsb2rgb(t, e, i).hex 8736 }), 8737 m.hsl = e(function(t, e, i) { 8738 return m.hsl2rgb(t, e, i).hex 8739 }), 8740 m.rgb = e(function(t, e, i, n) { 8741 if (u(n, "finite")) { 8742 var s = _.round; 8743 return "rgba(" + [s(t), s(e), s(i), +n.toFixed(2)] + ")" 8744 } 8745 return "#" + (16777216 | i | e << 8 | t << 16).toString(16).slice(1) 8746 }); 8747 var W = function(t) { 8748 var i = v.doc.getElementsByTagName("head")[0] || v.doc.getElementsByTagName("svg")[0] 8749 , n = "rgb(255, 0, 0)"; 8750 return (W = e(function(t) { 8751 if ("red" == t.toLowerCase()) 8752 return n; 8753 i.style.color = n, 8754 i.style.color = t; 8755 var e = v.doc.defaultView.getComputedStyle(i, I).getPropertyValue("color"); 8756 return e == n ? null : e 8757 }))(t) 8758 } 8759 , R = function() { 8760 return "hsb(" + [this.h, this.s, this.b] + ")" 8761 } 8762 , F = function() { 8763 return "hsl(" + [this.h, this.s, this.l] + ")" 8764 } 8765 , Q = function() { 8766 return 1 == this.opacity || null == this.opacity ? this.hex : "rgba(" + [this.r, this.g, this.b, this.opacity] + ")" 8767 } 8768 , B = function(t, e, i) { 8769 if (null == e && u(t, "object") && "r"in t && "g"in t && "b"in t && (i = t.b, 8770 e = t.g, 8771 t = t.r), 8772 null == e && u(t, string)) { 8773 var n = m.getRGB(t); 8774 t = n.r, 8775 e = n.g, 8776 i = n.b 8777 } 8778 return (1 < t || 1 < e || 1 < i) && (t /= 255,
8779 e /= 255, 8780 i /= 255), 8781 [t, e, i] 8782 } 8783 , q = function(t, e, i, n) { 8784 var s = { 8785 r: t = _.round(255 * t), 8786 g: e = _.round(255 * e), 8787 b: i = _.round(255 * i), 8788 opacity: u(n, "finite") ? n : 1, 8789 hex: m.rgb(t, e, i), 8790 toString: Q 8791 }; 8792 return u(n, "finite") && (s.opacity = n), 8793 s 8794 }; 8795 m.color = function(t) { 8796 var e; 8797 return u(t, "object") && "h"in t && "s"in t && "b"in t ? (e = m.hsb2rgb(t), 8798 t.r = e.r, 8799 t.g = e.g, 8800 t.b = e.b, 8801 t.opacity = 1, 8802 t.hex = e.hex) : u(t, "object") && "h"in t && "s"in t && "l"in t ? (e = m.hsl2rgb(t), 8803 t.r = e.r, 8804 t.g = e.g, 8805 t.b = e.b, 8806 t.opacity = 1, 8807 t.hex = e.hex) : (u(t, "string") && (t = m.getRGB(t)), 8808 u(t, "object") && "r"in t && "g"in t && "b"in t && !("error"in t) ? (e = m.rgb2hsl(t), 8809 t.h = e.h, 8810 t.s = e.s, 8811 t.l = e.l, 8812 e = m.rgb2hsb(t), 8813 t.v = e.b) : ((t = { 8814 hex: "none" 8815 }).r = t.g = t.b = t.h = t.s = t.v = t.l = -1, 8816 t.error = 1)), 8817 t.toString = Q, 8818 t 8819 } 8820 , 8821 m.hsb2rgb = function(t, e, i, n) { 8822 var s, o, r, a, l; 8823 return u(t, "object") && "h"in t && "s"in t && "b"in t && (i = t.b, 8824 e = t.s, 8825 n = t.o, 8826 t = t.h), 8827 s = o = r = i - (l = i * e), 8828 s += [l, a = l * (1 - S((t = (t *= 360) % 360 / 60) % 2 - 1)), 0, 0, a, l][t = ~~t], 8829 o += [a, l, l, a, 0, 0][t], 8830 r += [0, 0, a, l, l, a][t], 8831 q(s, o, r, n) 8832 } 8833 , 8834 m.hsl2rgb = function(t, e, i, n) { 8835 var s, o, r, a, l; 8836 return u(t, "object") && "h"in t && "s"in t && "l"in t && (i = t.l, 8837 e = t.s, 8838 t = t.h), 8839 (1 < t || 1 < e || 1 < i) && (t /= 360, 8840 e /= 100, 8841 i /= 100), 8842 s = o = r = i - (l = 2 * e * (i < .5 ? i : 1 - i)) / 2, 8843 s += [l, a = l * (1 - S((t = (t *= 360) % 360 / 60) % 2 - 1)), 0, 0, a, l][t = ~~t], 8844 o += [a, l, l, a, 0, 0][t], 8845 r += [0, 0, a, l, l, a][t], 8846 q(s, o, r, n) 8847 } 8848 , 8849 m.rgb2hsb = function(t, e, i) { 8850 var n, s; 8851 return t = (i = B(t, e, i))[0], 8852 e = i[1], 8853 i = i[2], 8854 { 8855 h: ((0 == (s = (n = k(t, e, i)) - C(t, e, i)) ? null : n == t ? (e - i) / s : n == e ? (i - t) / s + 2 : (t - e) / s + 4) + 360) % 6 * 60 / 360, 8856 s: 0 == s ? 0 : s / n, 8857 b: n, 8858 toString: R 8859 } 8860 } 8861 , 8862 m.rgb2hsl = function(t, e, i) { 8863 var n, s, o, r; 8864 return t = (i = B(t, e, i))[0], 8865 e = i[1], 8866 i = i[2], 8867 n = ((s = k(t, e, i)) + (o = C(t, e, i))) / 2, 8868 { 8869 h: ((0 == (r = s - o) ? null : s == t ? (e - i) / r : s == e ? (i - t) / r + 2 : (t - e) / r + 4) + 360) % 6 * 60 / 360, 8870 s: 0 == r ? 0 : n < .5 ? r / (2 * n) : r / (2 - 2 * n), 8871 l: n, 8872 toString: F 8873 } 8874 } 8875 , 8876 m.parsePathString = function(t) { 8877 if (!t) 8878 return null; 8879 var e = m.path(t); 8880 if (e.arr) 8881 return m.path.clone(e.arr); 8882 var o = { 8883 a: 7, 8884 c: 6, 8885 o: 2, 8886 h: 1, 8887 l: 2, 8888 m: 2, 8889 r: 4, 8890 q: 4, 8891 s: 4, 8892 t: 2, 8893 v: 1, 8894 u: 3, 8895 z: 0 8896 } 8897 , r = []; 8898 return u(t, "array") && u(t[0], "array") && (r = m.path.clone(t)), 8899 r.length || b(t).replace(D, function(t, e, i) { 8900 var n = [] 8901 , s = e.toLowerCase(); 8902 if (i.replace(j, function(t, e) { 8903 e && n.push(+e) 8904 }), 8905 "m" == s && 2 < n.length && (r.push([e].concat(n.splice(0, 2))), 8906 s = "l", 8907 e = "m" == e ? "l" : "L"), 8908 "o" == s && 1 == n.length && r.push([e, n[0]]), 8909 "r" == s) 8910 r.push([e].concat(n)); 8911 else 8912 for (; n.length >= o[s] && (r.push([e].concat(n.splice(0, o[s]))), 8913 o[s]); ) 8914 ; 8915 }), 8916 r.toString = m.path.toString, 8917 e.arr = m.path.clone(r), 8918 r 8919 } 8920 ; 8921 var Y = m.parseTransformString = function(t) { 8922 if (!t) 8923 return null; 8924 var s = []; 8925 return u(t, "array") && u(t[0], "array") && (s = m.path.clone(t)), 8926 s.length || b(t).replace(A, function(t, e, i) { 8927 var n = []; 8928 e.toLowerCase(), 8929 i.replace(j, function(t, e) { 8930 e && n.push(+e) 8931 }), 8932 s.push([e].concat(n)) 8933 }), 8934 s.toString = m.path.toString, 8935 s 8936 } 8937 ; 8938 m._.svgTransform2string = function(t) { 8939 var n = []; 8940 return t = t.replace(/(?:^|\s)(\w+)\(([^)]+)\)/g, function(t, e, i) { 8941 return i = i.split(/\s*,\s*|\s+/), 8942 "rotate" == e && 1 == i.length && i.push(0, 0), 8943 "scale" == e && (2 < i.length ? i = i.slice(0, 2) : 2 ==
8943i.length && i.push(0, 0), 8944 1 == i.length && i.push(i[0], 0, 0)), 8945 n.push("skewX" == e ? ["m", 1, 0, _.tan(s(i[0])), 1, 0, 0] : "skewY" == e ? ["m", 1, _.tan(s(i[0])), 0, 1, 0, 0] : [e.charAt(0)].concat(i)), 8946 t 8947 }), 8948 n 8949 } 8950 , 8951 m._.rgTransform = /^[a-z][\s]*-?\.?\d/i, 8952 m._.transform2matrix = function(t, e) { 8953 var i = Y(t) 8954 , n = new m.Matrix; 8955 if (i) 8956 for (var s = 0, o = i.length; s < o; s++) { 8957 var r, a, l, c, u, h = i[s], d = h.length, p = b(h[0]).toLowerCase(), f = h[0] != p, g = f ? n.invert() : 0; 8958 "t" == p && 2 == d ? n.translate(h[1], 0) : "t" == p && 3 == d ? f ? (r = g.x(0, 0), 8959 a = g.y(0, 0), 8960 l = g.x(h[1], h[2]), 8961 c = g.y(h[1], h[2]), 8962 n.translate(l - r, c - a)) : n.translate(h[1], h[2]) : "r" == p ? 2 == d ? (u = u || e, 8963 n.rotate(h[1], u.x + u.width / 2, u.y + u.height / 2)) : 4 == d && (f ? (l = g.x(h[2], h[3]), 8964 c = g.y(h[2], h[3]), 8965 n.rotate(h[1], l, c)) : n.rotate(h[1], h[2], h[3])) : "s" == p ? 2 == d || 3 == d ? (u = u || e, 8966 n.scale(h[1], h[d - 1], u.x + u.width / 2, u.y + u.height / 2)) : 4 == d ? f ? (l = g.x(h[2], h[3]), 8967 c = g.y(h[2], h[3]), 8968 n.scale(h[1], h[1], l, c)) : n.scale(h[1], h[1], h[2], h[3]) : 5 == d && (f ? (l = g.x(h[3], h[4]), 8969 c = g.y(h[3], h[4]), 8970 n.scale(h[1], h[2], l, c)) : n.scale(h[1], h[2], h[3], h[4])) : "m" == p && 7 == d && n.add(h[1], h[2], h[3], h[4], h[5], h[6]) 8971 } 8972 return n 8973 } 8974 , 8975 m._unit2px = function(i, n, s) { 8976 function t(t) { 8977 if (null == t) 8978 return I; 8979 if (t == +t) 8980 return t; 8981 c(l, { 8982 width: t 8983 }); 8984 try { 8985 return l.getBBox().width 8986 } catch (t) { 8987 return 0 8988 } 8989 } 8990 function e(t) { 8991 if (null == t) 8992 return I; 8993 if (t == +t) 8994 return t; 8995 c(l, { 8996 height: t 8997 }); 8998 try { 8999 return l.getBBox().height 9000 } catch (t) { 9001 return 0 9002 } 9003 } 9004 function o(t, e) { 9005 null == n ? a[t] = e(i.attr(t) || 0) : t == n && (a = e(null == s ? i.attr(t) || 0 : s)) 9006 } 9007 var r = h(i).node 9008 , a = {} 9009 , l = r.querySelector(".svg---mgr"); 9010 switch (l || (c(l = c("rect"), { 9011 x: -9e9, 9012 y: -9e9, 9013 width: 10, 9014 height: 10, 9015 class: "svg---mgr", 9016 fill: "none" 9017 }), 9018 r.appendChild(l)), 9019 i.type) { 9020 case "rect": 9021 o("rx", t), 9022 o("ry", e); 9023 case "image": 9024 o("width", t), 9025 o("height", e); 9026 case "text": 9027 o("x", t), 9028 o("y", e); 9029 break; 9030 case "circle": 9031 o("cx", t), 9032 o("cy", e), 9033 o("r", t); 9034 break; 9035 case "ellipse": 9036 o("cx", t), 9037 o("cy", e), 9038 o("rx", t), 9039 o("ry", e); 9040 break; 9041 case "line": 9042 o("x1", t), 9043 o("x2", t), 9044 o("y1", e), 9045 o("y2", e); 9046 break; 9047 case "marker": 9048 o("refX", t), 9049 o("markerWidth", t), 9050 o("refY", e), 9051 o("markerHeight", e); 9052 break; 9053 case "radialGradient": 9054 o("fx", t), 9055 o("fy", e); 9056 break; 9057 case "tspan": 9058 o("dx", t), 9059 o("dy", e); 9060 break; 9061 default: 9062 o(n, t) 9063 } 9064 return r.removeChild(l), 9065 a 9066 } 9067 , 9068 v.doc.contains || v.doc.compareDocumentPosition, 9069 m._.getSomeDefs = function(t) { 9070 var e = t.node.ownerSVGElement && f(t.node.ownerSVGElement) || t.node.parentNode && f(t.node.parentNode) || m.select("svg") || m(0, 0) 9071 , i = e.select("defs") 9072 , n = null != i && i.node; 9073 return n || (n = d("defs", e.node).node), 9074 n 9075 } 9076 , 9077 m._.getSomeSVG = h, 9078 m.select = function(t) { 9079 return t = b(t).replace(/([^\\]):/g, "$1\\:"), 9080 f(v.doc.querySelector(t)) 9081 } 9082 , 9083 m.selectAll = function(t) { 9084 for (var e = v.doc.querySelectorAll(t), i = (m.set || Array)(), n = 0; n < e.length; n++) 9085 i.push(f(e[n])); 9086 return i 9087 } 9088 , 9089 setInterval(function() { 9090 for (var t in H) 9091 if (H[y](t)) { 9092 var e = H[t] 9093 , i = e.node; 9094 ("svg" != e.type && !i.ownerSVGElement || "svg" == e.type && (!i.parentNode || "ownerSVGElement"in i.parentNode && !i.ownerSVGElement)) && delete H[t] 9095 } 9096 }, 1e4), 9097 l.prototype.attr = function(t, e) { 9098 var i = this.node; 9099 if (!t) { 9100 if (1 != i.nodeType) 9101 return { 9102 text: i.nodeValue 9103 }; 9104 for (var n = i.attributes, s = {}, o = 0, r = n.length; o < r; o++) 9105 s[n[o].nodeName] = n[o].nodeValue; 9106 return s 9107 } 9108 if (u(t, "string")) { 9109 if (!(1 < arguments.length)) 9110 return V("snap.util.getattr." + t, this).firstDefined(); 9111 var a = {}; 9112 a[t] = e, 9113 t = a 9114 } 9115 for (var l in t) 9116 t[y](l) && V("snap.util.attr." + l, this, t[l]); 9117 return this 9118 } 9119 , 9120 m.parse = function(t) { 9121 var e = v.doc.createDocumentFragment() 9122 , i = !0 9123 , n = v.doc.createElement("div"); 9124 if ((t = b(t)).match(/^\s*<\s*svg(?:\s|>)/) || (t = "<svg>" + t + "</svg>", 9125 i = !1), 9126 n.innerHTML = t, 9127 t = n.getElementsByTagName("svg")[0]) 9128 if (i) 9129 e = t; 9130 else 9131 for (; t.firstChild; ) 9132 e.appendChild(t.firstChild); 9133 return new r(e) 9134 } 9135 , 9136 m.fragment = function() { 9137 for (var t = Array.prototype.slice.call(arguments, 0), e = v.doc.createDocumentFragment(), i = 0, n = t.length; i < n; i++) { 9138 var s = t[i]; 9139 s.node && s.node.nodeType && e.appendChild(s.node), 9140 s.nodeType && e.appendChild(s), 9141 "string" == typeof s && e.appendChild(m.parse(s).node) 9142 } 9143 return new r(e) 9144 } 9145 , 9146 m._.make = d, 9147 m._.wrap = f, 9148 p.prototype.el = function(t, e) { 9149 var i = d(t, this.node); 9150 return e && i.attr(e), 9151 i 9152 } 9153 , 9154 l.prototype.children = function() { 9155 for (var t = [], e = this.node.childNodes, i = 0, n = e.length; i < n; i++) 9156 t[i] = m(e[i]); 9157 return t 9158 } 9159 , 9160 l.prototype.toJSON = function() { 9161 var t = []; 9162 return function t(e, i) { 9163 for (var n = 0, s = e.length; n < s; n++) { 9164 var o = { 9165 type: e[n].type, 9166 attr: e[n].attr() 9167 } 9168 , r = e[n].children(); 9169 i.push(o), 9170 r.length && t(r, o.childNodes = []) 9171 } 9172 }([this], t), 9173 t[0] 9174 } 9175 , 9176 V.on("snap.util.getattr", function() { 9177 var t = V.nt() 9178 , e = (t = t.substring(t.lastIndexOf(".") + 1)).replace(/[A-Z]/g, function(t) { 9179 return "-" + t.toLowerCase() 9180 }); 9181 return X[y](e) ? this.node.ownerDocument.defaultView.getComputedStyle(this.node, null).getPropertyValue(e) : c(this.node, t) 9182 }); 9183 var X = { 9184 "alignment-baseline": 0, 9185 "baseline-shift": 0, 9186 clip: 0, 9187 "clip-path": 0, 9188 "clip-rule": 0, 9189 color: 0, 9190 "color-interpolation": 0, 9191 "color-interpolation-filters": 0, 9192 "color-profile": 0, 9193 "color-rendering": 0, 9194 cursor: 0, 9195 direction: 0, 9196 display: 0, 9197 "dominant-baseline": 0, 9198 "enable-background": 0, 9199 fill: 0, 9200 "fill-opacity": 0, 9201 "fill-rule": 0, 9202 filter: 0, 9203 "flood-color": 0, 9204 "flood-opacity": 0, 9205 font: 0, 9206 "font-family": 0, 9207 "font-size": 0, 9208 "font-size-adjust": 0, 9209 "font-stretch": 0, 9210 "font-style": 0, 9211 "font-variant": 0, 9212 "font-weight": 0, 9213 "glyph-orientation-horizontal": 0, 9214 "glyph-orientation-vertical": 0, 9215 "image-rendering": 0, 9216 kerning: 0, 9217 "letter-spacing": 0, 9218 "lighting-color": 0, 9219 marker: 0, 9220 "marker-end": 0, 9221 "marker-mid": 0, 9222 "marker-start": 0, 9223 mask: 0, 9224 opacity: 0, 9225 overflow: 0, 9226 "pointer-events": 0, 9227 "shape-rendering": 0, 9228 "stop-color": 0, 9229 "stop-opacity": 0, 9230 stroke: 0, 9231 "stroke-dasharray": 0, 9232 "stroke-dashoffset": 0, 9233 "stroke-linecap": 0, 9234 "stroke-linejoin": 0, 9235 "stroke-miterlimit": 0, 9236 "stroke-opacity": 0, 9237 "stroke-width": 0, 9238 "text-anchor": 0, 9239 "text-decoration": 0, 9240 "text-rendering": 0,
9241 "unicode-bidi": 0, 9242 visibility: 0, 9243 "word-spacing": 0, 9244 "writing-mode": 0 9245 }; 9246 V.on("snap.util.attr", function(t) { 9247 var e = V.nt() 9248 , i = {}; 9249 i[e = e.substring(e.lastIndexOf(".") + 1)] = t; 9250 var n = e.replace(/-(\w)/gi, function(t, e) { 9251 return e.toUpperCase() 9252 }) 9253 , s = e.replace(/[A-Z]/g, function(t) { 9254 return "-" + t.toLowerCase() 9255 }); 9256 X[y](s) ? this.node.style[n] = null == t ? I : t : c(this.node, i) 9257 }), 9258 p.prototype, 9259 m.ajax = function(t, e, i, n) { 9260 var s = new XMLHttpRequest 9261 , o = $(); 9262 if (s) { 9263 if (u(e, "function")) 9264 n = i, 9265 i = e, 9266 e = null; 9267 else if (u(e, "object")) { 9268 var r = []; 9269 for (var a in e) 9270 e.hasOwnProperty(a) && r.push(encodeURIComponent(a) + "=" + encodeURIComponent(e[a])); 9271 e = r.join("&") 9272 } 9273 return s.open(e ? "POST" : "GET", t, !0), 9274 e && (s.setRequestHeader("X-Requested-With", "XMLHttpRequest"), 9275 s.setRequestHeader("Content-type", "application/x-www-form-urlencoded")), 9276 i && (V.once("snap.ajax." + o + ".0", i), 9277 V.once("snap.ajax." + o + ".200", i), 9278 V.once("snap.ajax." + o + ".304", i)), 9279 s.onreadystatechange = function() { 9280 4 == s.readyState && V("snap.ajax." + o + "." + s.status, n, s) 9281 } 9282 , 9283 4 == s.readyState || s.send(e), 9284 s 9285 } 9286 } 9287 , 9288 m.load = function(t, i, n) { 9289 m.ajax(t, function(t) { 9290 var e = m.parse(t.responseText); 9291 n ? i.call(n, e) : i(e) 9292 }) 9293 } 9294 ; 9295 return m.getElementByPoint = function(t, e) { 9296 var i, n, s, o, r, a, l, c = (this.canvas, 9297 v.doc.elementFromPoint(t, e)); 9298 if (v.win.opera && "svg" == c.tagName) { 9299 var u = (n = (i = c).getBoundingClientRect(), 9300 s = i.ownerDocument, 9301 o = s.body, 9302 r = s.documentElement, 9303 a = r.clientTop || o.clientTop || 0, 9304 l = r.clientLeft || o.clientLeft || 0, 9305 { 9306 y: n.top + (g.win.pageYOffset || r.scrollTop || o.scrollTop) - a, 9307 x: n.left + (g.win.pageXOffset || r.scrollLeft || o.scrollLeft) - l 9308 }) 9309 , h = c.createSVGRect(); 9310 h.x = t - u.x, 9311 h.y = e - u.y, 9312 h.width = h.height = 1; 9313 var d = c.getIntersectionList(h, null); 9314 d.length && (c = d[d.length - 1]) 9315 } 9316 return c ? f(c) : null 9317 } 9318 , 9319 m.plugin = function(t) { 9320 t(m, l, p, v, r) 9321 } 9322 , 9323 v.win.Snap = m 9324 }(x || this); 9325 return e.plugin(function(u, t, e, i, n) { 9326 function h(t, e) { 9327 if (null == e) { 9328 var i = !0; 9329 if (!(e = t.node.getAttribute("linearGradient" == t.type || "radialGradient" == t.type ? "gradientTransform" : "pattern" == t.type ? "patternTransform" : "transform"))) 9330 return new u.Matrix; 9331 e = u._.svgTransform2string(e) 9332 } else 9333 e = u._.rgTransform.test(e) ? y(e).replace(/\.{3}|\u2026/g, t._.transform || "") : u._.svgTransform2string(e), 9334 v(e, "array") && (e = u.path ? u.path.toString.call(e) : y(e)), 9335 t._.transform = e; 9336 var n = u._.transform2matrix(e, t.getBBox(1)); 9337 return i ? n : void (t.matrix = n) 9338 } 9339 function m(i, n, s) { 9340 return function(t) { 9341 var e = t.slice(i, n); 9342 return 1 == e.length && (e = e[0]), 9343 s ? s(e) : e 9344 } 9345 } 9346 function s(o) { 9347 return function() { 9348 var t = o ? "<" + this.type : "" 9349 , e = this.node.attributes 9350 , i = this.node.childNodes; 9351 if (o) 9352 for (var n = 0, s = e.length; n < s; n++) 9353 t += " " + e[n].name + '="' + e[n].value.replace(/"/g, '\\"') + '"'; 9354 if (i.length) { 9355 for (o && (t += ">"), 9356 n = 0, 9357 s = i.length; n < s; n++) 9358 3 == i[n].nodeType ? t += i[n].nodeValue : 1 == i[n].nodeType && (t += c(i[n]).toString()); 9359 o && (t += "</" + this.type + ">") 9360 } else 9361 o && (t += "/>"); 9362 return t 9363 } 9364 } 9365 var o = t.prototype 9366 , v = u.is 9367 , y = String 9368 , r = u._unit2px 9369 , f = u._.$ 9370 , a = u._.make 9371 , l = u._.getSomeDefs 9372 , b = "hasOwnProperty" 9373 , c = u._.wrap; 9374 o.getBBox = function(t) { 9375 if (!u.Matrix || !u.path) 9376 return this.node.getBBox(); 9377 var e = this 9378 , i = new u.Matrix; 9379 if (e.removed) 9380 return u._.box(); 9381 for (; "use" == e.type; ) 9382 if (t || (i = i.add(e.transform().localMatrix.translate(e.attr("x") || 0, e.attr("y") || 0))), 9383 e.original) 9384 e = e.original; 9385 else { 9386 var n = e.attr("xlink:href"); 9387 e = e.original = e.node.ownerDocument.getElementById(n.substring(n.indexOf("#") + 1)) 9388 } 9389 var s = e._ 9390 , o = u.path.get[e.type] || u.path.get.deflt;
9391 try { 9392 return t ? (s.bboxwt = o ? u.path.getBBox(e.realPath = o(e)) : u._.box(e.node.getBBox()), 9393 u._.box(s.bboxwt)) : (e.realPath = o(e), 9394 e.matrix = e.transform().localMatrix, 9395 s.bbox = u.path.getBBox(u.path.map(e.realPath, i.add(e.matrix))), 9396 u._.box(s.bbox)) 9397 } catch (t) { 9398 return u._.box() 9399 } 9400 } 9401 ; 9402 var d = function() { 9403 return this.string 9404 }; 9405 o.transform = function(t) { 9406 var e = this._; 9407 if (null == t) { 9408 for (var i, n = this, s = new u.Matrix(this.node.getCTM()), o = h(this), r = [o], a = new u.Matrix, l = o.toTransformString(), c = y(o) == y(this.matrix) ? y(e.transform) : l; "svg" != n.type && (n = n.parent()); ) 9409 r.push(h(n)); 9410 for (i = r.length; i--; ) 9411 a.add(r[i]); 9412 return { 9413 string: c, 9414 globalMatrix: s, 9415 totalMatrix: a, 9416 localMatrix: o, 9417 diffMatrix: s.clone().add(o.invert()), 9418 global: s.toTransformString(), 9419 total: a.toTransformString(), 9420 local: l, 9421 toString: d 9422 } 9423 } 9424 return t instanceof u.Matrix ? (this.matrix = t, 9425 this._.transform = t.toTransformString()) : h(this, t), 9426 this.node && ("linearGradient" == this.type || "radialGradient" == this.type ? f(this.node, { 9427 gradientTransform: this.matrix 9428 }) : "pattern" == this.type ? f(this.node, { 9429 patternTransform: this.matrix 9430 }) : f(this.node, { 9431 transform: this.matrix 9432 })), 9433 this 9434 } 9435 , 9436 o.parent = function() { 9437 return c(this.node.parentNode) 9438 } 9439 , 9440 o.append = o.add = function(t) { 9441 if (t) { 9442 if ("set" == t.type) { 9443 var e = this; 9444 return t.forEach(function(t) { 9445 e.add(t) 9446 }), 9447 this 9448 } 9449 t = c(t), 9450 this.node.appendChild(t.node), 9451 t.paper = this.paper 9452 } 9453 return this 9454 } 9455 , 9456 o.appendTo = function(t) { 9457 return t && (t = c(t)).append(this), 9458 this 9459 } 9460 , 9461 o.prepend = function(t) { 9462 if (t) { 9463 if ("set" == t.type) { 9464 var e, i = this; 9465 return t.forEach(function(t) { 9466 e ? e.after(t) : i.prepend(t), 9467 e = t 9468 }), 9469 this 9470 } 9471 var n = (t = c(t)).parent(); 9472 this.node.insertBefore(t.node, this.node.firstChild), 9473 this.add && this.add(), 9474 t.paper = this.paper, 9475 this.parent() && this.parent().add(), 9476 n && n.add() 9477 } 9478 return this 9479 } 9480 , 9481 o.prependTo = function(t) { 9482 return (t = c(t)).prepend(this), 9483 this 9484 } 9485 , 9486 o.before = function(t) { 9487 if ("set" == t.type) { 9488 var i = this; 9489 return t.forEach(function(t) { 9490 var e = t.parent(); 9491 i.node.parentNode.insertBefore(t.node, i.node), 9492 e && e.add() 9493 }), 9494 this.parent().add(), 9495 this 9496 } 9497 var e = (t = c(t)).parent(); 9498 return this.node.parentNode.insertBefore(t.node, this.node), 9499 this.parent() && this.parent().add(), 9500 e && e.add(), 9501 t.paper = this.paper, 9502 this 9503 } 9504 , 9505 o.after = function(t) { 9506 var e = (t = c(t)).parent(); 9507 return this.node.nextSibling ? this.node.parentNode.insertBefore(t.node, this.node.nextSibling) : this.node.parentNode.appendChild(t.node), 9508 this.parent() && this.parent().add(), 9509 e && e.add(), 9510 t.paper = this.paper, 9511 this 9512 } 9513 , 9514 o.insertBefore = function(t) { 9515 t = c(t); 9516 var e = this.parent(); 9517 return t.node.parentNode.insertBefore(this.node, t.node), 9518 this.paper = t.paper, 9519 e && e.add(), 9520 t.parent() && t.parent().add(), 9521 this 9522 } 9523 , 9524 o.insertAfter = function(t) { 9525 t = c(t); 9526 var e = this.parent(); 9527 return t.node.parentNode.insertBefore(this.node, t.node.nextSibling), 9528 this.paper = t.paper, 9529 e && e.add(), 9530 t.parent() && t.parent().add(), 9531 this 9532 } 9533 , 9534 o.remove = function() { 9535 var t = this.parent(); 9536 return this.node.parentNode && this.node.parentNode.removeChild(this.node), 9537 delete this.paper, 9538 this.removed = !0, 9539 t && t.add(), 9540 this 9541 } 9542 , 9543 o.select = function(t) { 9544 return c(this.node.querySelector(t)) 9545 } 9546 , 9547 o.selectAll = function(t) { 9548 for (var e = this.node.querySelectorAll(t), i = (u.set || Array)(), n = 0; n < e.length; n++) 9549 i.push(c(e[n])); 9550 return i 9551 } 9552 , 9553 o.asPX = function(t, e) { 9554 return null == e && (e = this.attr(t)), 9555 +r(this, t, e) 9556 } 9557 , 9558 o.use = function() { 9559 var t, e = this.node.id; 9560 return e || (e = this.id, 9561 f(this.node, { 9562 id: e 9563 })), 9564 t = "linearGradient" == this.type || "radialGradient" == this.type || "pattern" == this.type ? a(this.type, this.node.parentNode) : a("use", this.node.parentNode), 9565 f(t.node, { 9566 "xlink:href": "#" + e 9567 }), 9568 t.original = this, 9569 t 9570 } 9571 , 9572 o.clone = function() { 9573 var t = c(this.node.cloneNode(!0)); 9574 return f(t.node, "id") && f(t.node, { 9575 id: t.id 9576 }), 9577 function(t) { 9578 function e(i, n) { 9579 var t = f(i.node, n);
9580 (t = (t = t && t.match(o)) && t[2]) && "#" == t.charAt() && (t = t.substring(1)) && (a[t] = (a[t] || []).concat(function(t) { 9581 var e = {}; 9582 e[n] = URL(t), 9583 f(i.node, e) 9584 })) 9585 } 9586 function i(e) { 9587 var t = f(e.node, "xlink:href"); 9588 t && "#" == t.charAt() && (t = t.substring(1)) && (a[t] = (a[t] || []).concat(function(t) { 9589 e.attr("xlink:href", "#" + t) 9590 })) 9591 } 9592 for (var n, s = t.selectAll("*"), o = /^\s*url\(("|'|)(.*)\1\)\s*$/, r = [], a = {}, l = 0, c = s.length; l < c; l++) { 9593 e(n = s[l], "fill"), 9594 e(n, "stroke"), 9595 e(n, "filter"), 9596 e(n, "mask"), 9597 e(n, "clip-path"), 9598 i(n); 9599 var u = f(n.node, "id"); 9600 u && (f(n.node, { 9601 id: n.id 9602 }), 9603 r.push({ 9604 old: u, 9605 id: n.id 9606 })) 9607 } 9608 for (l = 0, 9609 c = r.length; l < c; l++) { 9610 var h = a[r[l].old]; 9611 if (h) 9612 for (var d = 0, p = h.length; d < p; d++) 9613 h[d](r[l].id) 9614 } 9615 }(t), 9616 t.insertAfter(this), 9617 t 9618 } 9619 , 9620 o.toDefs = function() { 9621 return l(this).appendChild(this.node), 9622 this 9623 } 9624 , 9625 o.pattern = o.toPattern = function(t, e, i, n) { 9626 var s = a("pattern", l(this)); 9627 return null == t && (t = this.getBBox()), 9628 v(t, "object") && "x"in t && (e = t.y, 9629 i = t.width, 9630 n = t.height, 9631 t = t.x), 9632 f(s.node, { 9633 x: t, 9634 y: e, 9635 width: i, 9636 height: n, 9637 patternUnits: "userSpaceOnUse", 9638 id: s.id,
9639 viewBox: [t, e, i, n].join(" ") 9640 }), 9641 s.node.appendChild(this.node), 9642 s 9643 } 9644 , 9645 o.marker = function(t, e, i, n, s, o) { 9646 var r = a("marker", l(this)); 9647 return null == t && (t = this.getBBox()), 9648 v(t, "object") && "x"in t && (e = t.y, 9649 i = t.width, 9650 n = t.height, 9651 s = t.refX || t.cx, 9652 o = t.refY || t.cy, 9653 t = t.x), 9654 f(r.node, { 9655 viewBox: [t, e, i, n].join(" "), 9656 markerWidth: i, 9657 markerHeight: n, 9658 orient: "auto", 9659 refX: s || 0, 9660 refY: o || 0, 9661 id: r.id 9662 }), 9663 r.node.appendChild(this.node), 9664 r 9665 } 9666 ; 9667 var w = function(t, e, i, n) { 9668 "function" != typeof i || i.length || (n = i, 9669 i = S.linear), 9670 this.attr = t, 9671 this.dur = e, 9672 i && (this.easing = i), 9673 n && (this.callback = n) 9674 }; 9675 u._.Animation = w, 9676 u.animation = function(t, e, i, n) { 9677 return new w(t,e,i,n) 9678 } 9679 , 9680 o.inAnim = function() { 9681 var t = []; 9682 for (var e in this.anims) 9683 this.anims[b](e) && function(e) { 9684 t.push({ 9685 anim: new w(e._attrs,e.dur,e.easing,e._callback), 9686 mina: e, 9687 curStatus: e.status(), 9688 status: function(t) { 9689 return e.status(t) 9690 }, 9691 stop: function() { 9692 e.stop() 9693 } 9694 }) 9695 }(this.anims[e]); 9696 return t 9697 } 9698 , 9699 u.animate = function(t, e, i, n, s, o) { 9700 "function" != typeof s || s.length || (o = s, 9701 s = S.linear); 9702 var r = S.time() 9703 , a = S(t, e, r, r + n, S.time, i, s); 9704 return o && V.once("mina.finish." + a.id, o), 9705 a 9706 } 9707 , 9708 o.stop = function() { 9709 for (var t = this.inAnim(), e = 0, i = t.length; e < i; e++) 9710 t[e].stop(); 9711 return this 9712 } 9713 , 9714 o.animate = function(t, e, i, n) { 9715 "function" != typeof i || i.length || (n = i, 9716 i = S.linear), 9717 t instanceof w && (n = t.callback, 9718 i = t.easing, 9719 e = t.dur, 9720 t = t.attr); 9721 var s, o, r, a, l = [], c = [], u = {}, h = this; 9722 for (var d in t) 9723 if (t[b](d)) { 9724 h.equal ? (s = (a = h.equal(d, y(t[d]))).from, 9725 o = a.to, 9726 r = a.f) : (s = +h.attr(d), 9727 o = +t[d]); 9728 var p = v(s, "array") ? s.length : 1; 9729 u[d] = m(l.length, l.length + p, r), 9730 l = l.concat(s), 9731 c = c.concat(o) 9732 } 9733 var f = S.time() 9734 , g = S(l, c, f, f + e, S.time, function(t) { 9735 var e = {}; 9736 for (var i in u) 9737 u[b](i) && (e[i] = u[i](t)); 9738 h.attr(e) 9739 }, i); 9740 return (h.anims[g.id] = g)._attrs = t, 9741 g._callback = n, 9742 V("snap.animcreated." + h.id, g), 9743 V.once("mina.finish." + g.id, function() { 9744 delete h.anims[g.id], 9745 n && n.call(h) 9746 }), 9747 V.once("mina.stop." + g.id, function() { 9748 delete h.anims[g.id] 9749 }), 9750 h 9751 } 9752 ; 9753 var p = {}; 9754 o.data = function(t, e) { 9755 var i = p[this.id] = p[this.id] || {}; 9756 if (0 == arguments.length) 9757 return V("snap.data.get." + this.id, this, i, null), 9758 i; 9759 if (1 == arguments.length) { 9760 if (u.is(t, "object")) { 9761 for (var n in t) 9762 t[b](n) && this.data(n, t[n]); 9763 return this 9764 } 9765 return V("snap.data.get." + this.id, this, i[t], t), 9766 i[t] 9767 } 9768 return i[t] = e, 9769 V("snap.data.set." + this.id, this, e, t), 9770 this 9771 } 9772 , 9773 o.removeData = function(t) { 9774 return null == t ? p[this.id] = {} : p[this.id] && delete p[this.id][t], 9775 this 9776 } 9777 , 9778 o.outerSVG = o.toString = s(1), 9779 o.innerSVG = s(), 9780 o.toDataURL = function() { 9781 if (x && x.btoa) { 9782 var t = this.getBBox() 9783 , e = u.format('<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="{width}" height="{height}" viewBox="{x} {y} {width} {height}">{contents}</svg>', { 9784 x: +t.x.toFixed(3), 9785 y: +t.y.toFixed(3), 9786 width: +t.width.toFixed(3), 9787 height: +t.height.toFixed(3), 9788 contents: this.outerSVG() 9789 }); 9790 return "data:image/svg+xml;base64," + btoa(unescape(encodeURIComponent(e))) 9791 } 9792 } 9793 , 9794 n.prototype.select = o.select, 9795 n.prototype.selectAll = o.selectAll 9796 }), 9797 e.plugin(function(r) { 9798 function p(t, e, i, n, s, o) { 9799 return null == e && "[object SVGMatrix]" == a.call(t) ? (this.a = t.a, 9800 this.b = t.b, 9801 this.c = t.c, 9802 this.d = t.d, 9803 this.e = t.e, 9804 void (this.f = t.f)) : void (null != t ? (this.a = +t, 9805 this.b = +e, 9806 this.c = +i, 9807 this.d = +n,
9808 this.e = +s, 9809 this.f = +o) : (this.a = 1, 9810 this.b = 0, 9811 this.c = 0, 9812 this.d = 1, 9813 this.e = 0, 9814 this.f = 0)) 9815 } 9816 var a = Object.prototype.toString 9817 , e = String 9818 , l = Math; 9819 !function(t) { 9820 function s(t) { 9821 return t[0] * t[0] + t[1] * t[1] 9822 } 9823 function o(t) { 9824 var e = l.sqrt(s(t)); 9825 t[0] && (t[0] /= e), 9826 t[1] && (t[1] /= e) 9827 } 9828 t.add = function(t, e, i, n, s, o) { 9829 var r, a, l, c, u = [[], [], []], h = [[this.a, this.c, this.e], [this.b, this.d, this.f], [0, 0, 1]], d = [[t, i, s], [e, n, o], [0, 0, 1]]; 9830 for (t && t instanceof p && (d = [[t.a, t.c, t.e], [t.b, t.d, t.f], [0, 0, 1]]), 9831 r = 0; r < 3; r++) 9832 for (a = 0; a < 3; a++) { 9833 for (l = c = 0; l < 3; l++) 9834 c += h[r][l] * d[l][a]; 9835 u[r][a] = c 9836 } 9837 return this.a = u[0][0], 9838 this.b = u[1][0], 9839 this.c = u[0][1], 9840 this.d = u[1][1], 9841 this.e = u[0][2], 9842 this.f = u[1][2], 9843 this 9844 } 9845 , 9846 t.invert = function() { 9847 var t = this 9848 , e = t.a * t.d - t.b * t.c; 9849 return new p(t.d / e,-t.b / e,-t.c / e,t.a / e,(t.c * t.f - t.d * t.e) / e,(t.b * t.e - t.a * t.f) / e) 9850 } 9851 , 9852 t.clone = function() { 9853 return new p(this.a,this.b,this.c,this.d,this.e,this.f) 9854 } 9855 , 9856 t.translate = function(t, e) { 9857 return this.add(1, 0, 0, 1, t, e) 9858 } 9859 , 9860 t.scale = function(t, e, i, n) { 9861 return null == e && (e = t), 9862 (i || n) && this.add(1, 0, 0, 1, i, n), 9863 this.add(t, 0, 0, e, 0, 0), 9864 (i || n) && this.add(1, 0, 0, 1, -i, -n), 9865 this 9866 } 9867 , 9868 t.rotate = function(t, e, i) { 9869 t = r.rad(t), 9870 e = e || 0, 9871 i = i || 0; 9872 var n = +l.cos(t).toFixed(9) 9873 , s = +l.sin(t).toFixed(9); 9874 return this.add(n, s, -s, n, e, i), 9875 this.add(1, 0, 0, 1, -e, -i) 9876 } 9877 , 9878 t.x = function(t, e) { 9879 return t * this.a + e * this.c + this.e 9880 } 9881 , 9882 t.y = function(t, e) { 9883 return t * this.b + e * this.d + this.f 9884 } 9885 , 9886 t.get = function(t) { 9887 return +this[e.fromCharCode(97 + t)].toFixed(4) 9888 } 9889 , 9890 t.toString = function() { 9891 return "matrix(" + [this.get(0), this.get(1), this.get(2), this.get(3), this.get(4), this.get(5)].join() + ")" 9892 } 9893 , 9894 t.offset = function() { 9895 return [this.e.toFixed(4), this.f.toFixed(4)] 9896 } 9897 , 9898 t.determinant = function() { 9899 return this.a * this.d - this.b * this.c 9900 } 9901 , 9902 t.split = function() { 9903 var t = {}; 9904 t.dx = this.e, 9905 t.dy = this.f; 9906 var e = [[this.a, this.c], [this.b, this.d]]; 9907 t.scalex = l.sqrt(s(e[0])), 9908 o(e[0]), 9909 t.shear = e[0][0] * e[1][0] + e[0][1] * e[1][1], 9910 e[1] = [e[1][0] - e[0][0] * t.shear, e[1][1] - e[0][1] * t.shear], 9911 t.scaley = l.sqrt(s(e[1])), 9912 o(e[1]), 9913 t.shear /= t.scaley, 9914 this.determinant() < 0 && (t.scalex = -t.scalex); 9915 var i = -e[0][1] 9916 , n = e[1][1]; 9917 return n < 0 ? (t.rotate = r.deg(l.acos(n)), 9918 i < 0 && (t.rotate = 360 - t.rotate)) : t.rotate = r.deg(l.asin(i)), 9919 t.isSimple = !(+t.shear.toFixed(9) || t.scalex.toFixed(9) != t.scaley.toFixed(9) && t.rotate), 9920 t.isSuperSimple = !+t.shear.toFixed(9) && t.scalex.toFixed(9) == t.scaley.toFixed(9) && !t.rotate, 9921 t.noRotation = !+t.shear.toFixed(9) && !t.rotate, 9922 t 9923 } 9924 , 9925 t.toTransformString = function(t) { 9926 var e = t || this.split(); 9927 return +e.shear.toFixed(9) ? "m" + [this.get(0), this.get(1), this.get(2), this.get(3), this.get(4), this.get(5)] : (e.scalex = +e.scalex.toFixed(4), 9928 e.scaley = +e.scaley.toFixed(4), 9929 e.rotate = +e.rotate.toFixed(4), 9930 (e.dx || e.dy ? "t" + [+e.dx.toFixed(4), +e.dy.toFixed(4)] : "") + (1 != e.scalex || 1 != e.scaley ? "s" + [e.scalex, e.scaley, 0, 0] : "") + (e.rotate ? "r" + [+e.rotate.toFixed(4), 0, 0] : "")) 9931 } 9932 }(p.prototype), 9933 r.Matrix = p, 9934 r.matrix = function(t, e, i, n, s, o) { 9935 return new p(t,e,i,n,s,o) 9936 } 9937 }), 9938 e.plugin(function(o, r, t, s, a) { 9939 function e(s) { 9940 return function(t) { 9941 if (V.stop(), 9942 t instanceof a && 1 == t.node.childNodes.length && ("radialGradient" == t.node.firstChild.tagName || "linearGradient" == t.node.firstChild.tagName || "pattern" == t.node.firstChild.tagName) && (t = t.node.firstChild, 9943 d(this).appendChild(t), 9944 t = u(t)), 9945 t instanceof r) 9946 if ("radialGradient" == t.type || "linearGradient" == t.type || "pattern" == t.type) { 9947 t.node.id || f(t.node, { 9948 id: t.id 9949 }); 9950 var e = g(t.node.id) 9951 } else 9952 e = t.attr(s); 9953 else if ((e = o.color(t)).error) { 9954 var i = o(d(this).ownerSVGElement).gradient(t); 9955 i ? (i.node.id || f(i.node, { 9956 id: i.id 9957 }), 9958 e = g(i.node.id)) : e = t 9959 } else 9960 e = m(e); 9961 var n = {}; 9962 n[s] = e, 9963 f(this.node, n), 9964 this.node.style[s] = y 9965 } 9966 } 9967 function i(t) { 9968 V.stop(), 9969 t == +t && (t += "px"), 9970 this.node.style.fontSize = t 9971 } 9972 function n() { 9973 return V.stop(), 9974 this.node.style.fontSize 9975 } 9976 var l, c = o._.make, u = o._.wrap, h = o.is, d = o._.getSomeDefs, p = /^url\(#?([^)]+)\)$/, f = o._.$, g = o.url, m = String, v = o._.separator, y = ""; 9977 V.on("snap.util.attr.mask", function(t) { 9978 if (t instanceof r || t instanceof a) { 9979 if (V.stop(), 9980 t instanceof a && 1 == t.node.childNodes.length && (t = t.node.firstChild, 9981 d(this).appendChild(t), 9982 t = u(t)), 9983 "mask" == t.type) 9984 var e = t; 9985 else 9986 (e = c("mask", d(this))).node.appendChild(t.node); 9987 !e.node.id && f(e.node, { 9988 id: e.id 9989 }), 9990 f(this.node, { 9991 mask: g(e.id) 9992 }) 9993 } 9994 }), 9995 l = function(t) { 9996 if (t instanceof r || t instanceof a) { 9997 if (V.stop(), 9998 "clipPath" == t.type) 9999 var e = t; 10000 else 10001 (e = c("clipPath", d(this))).node.appendChild(t.node), 10002 !e.node.id && f(e.node, { 10003 id: e.id 10004 }); 10005 f(this.node, { 10006 "clip-path": g(e.node.id || e.id) 10007 }) 10008 } 10009 } 10010 , 10011 V.on("snap.util.attr.clip", l), 10012 V.on("snap.util.attr.clip-path", l), 10013 V.on("snap.util.attr.clipPath", l), 10014 V.on("snap.util.attr.fill", e("fill")), 10015 V.on("snap.util.attr.stroke", e("stroke")); 10016 var b = /^([lr])(?:\(([^)]*)\))?(.*)$/i; 10017 V.on("snap.util.grad.parse", function(t) { 10018 var e = (t = m(t)).match(b); 10019 if (!e) 10020 return null; 10021 var i = e[1] 10022 , n = e[2] 10023 , s = e[3]; 10024 return 1 == (n = n.split(/\s*,\s*/).map(function(t) { 10025 return +t == t ? +t : t 10026 })).length && 0 == n[0] && (n = []), 10027 { 10028 type: i, 10029 params: n, 10030 stops: s = (s = s.split("-")).map(function(t) { 10031 var e = { 10032 color: (t = t.split(":"))[0] 10033 }; 10034 return t[1] && (e.offset = parseFloat(t[1])), 10035 e 10036 }) 10037 } 10038 }), 10039 V.on("snap.util.attr.d", function(t) { 10040 V.stop(), 10041 h(t, "array") && h(t[0], "array") && (t = o.path.toString.call(t)), 10042 (t = m(t)).match(/[ruo]/i) && (t = o.path.toAbsolute(t)), 10043 f(this.node, { 10044 d: t 10045 }) 10046 })(-1), 10047 V.on("snap.util.attr.#text", function(t) { 10048 V.stop(), 10049 t = m(t); 10050 for (var e = s.doc.createTextNode(t); this.node.firstChild; ) 10051 this.node.removeChild(this.node.firstChild); 10052 this.node.appendChild(e) 10053 })(-1), 10054 V.on("snap.util.attr.path", function(t) { 10055 V.stop(), 10056 this.attr({ 10057 d: t 10058 }) 10059 })(-1), 10060 V.on("snap.util.attr.class", function(t) { 10061 V.stop(), 10062 this.node.className.baseVal = t 10063 })(-1), 10064 V.on("snap.util.attr.viewBox", function(t) { 10065 var e; 10066 e = h(t, "object") && "x"in t ? [t.x, t.y, t.width, t.height].join(" ") : h(t, "array") ? t.join(" ") : t, 10067 f(this.node, {
10068 viewBox: e 10069 }), 10070 V.stop() 10071 })(-1), 10072 V.on("snap.util.attr.transform", function(t) { 10073 this.transform(t), 10074 V.stop() 10075 })(-1), 10076 V.on("snap.util.attr.r", function(t) { 10077 "rect" == this.type && (V.stop(), 10078 f(this.node, { 10079 rx: t, 10080 ry: t 10081 })) 10082 })(-1), 10083 V.on("snap.util.attr.textpath", function(t) { 10084 if (V.stop(), 10085 "text" == this.type) { 10086 var e, i, n; 10087 if (!t && this.textPath) { 10088 for (i = this.textPath; i.node.firstChild; ) 10089 this.node.appendChild(i.node.firstChild); 10090 return i.remove(), 10091 void delete this.textPath 10092 } 10093 if (h(t, "string")) { 10094 var s = d(this) 10095 , o = u(s.parentNode).path(t); 10096 s.appendChild(o.node), 10097 e = o.id, 10098 o.attr({ 10099 id: e 10100 }) 10101 } else 10102 (t = u(t))instanceof r && ((e = t.attr("id")) || (e = t.id, 10103 t.attr({ 10104 id: e 10105 }))); 10106 if (e) 10107 if (i = this.textPath, 10108 n = this.node, 10109 i) 10110 i.attr({ 10111 "xlink:href": "#" + e 10112 }); 10113 else { 10114 for (i = f("textPath", { 10115 "xlink:href": "#" + e 10116 }); n.firstChild; ) 10117 i.appendChild(n.firstChild); 10118 n.appendChild(i), 10119 this.textPath = u(i) 10120 } 10121 } 10122 })(-1), 10123 V.on("snap.util.attr.text", function(t) { 10124 if ("text" == this.type) { 10125 for (var e = this.node, n = function(t) { 10126 var e = f("tspan"); 10127 if (h(t, "array")) 10128 for (var i = 0; i < t.length; i++) 10129 e.appendChild(n(t[i])); 10130 else 10131 e.appendChild(s.doc.createTextNode(t)); 10132 return e.normalize && e.normalize(), 10133 e 10134 }; e.firstChild; ) 10135 e.removeChild(e.firstChild); 10136 for (var i = n(t); i.firstChild; ) 10137 e.appendChild(i.firstChild) 10138 } 10139 V.stop() 10140 })(-1), 10141 V.on("snap.util.attr.fontSize", i)(-1), 10142 V.on("snap.util.attr.font-size", i)(-1), 10143 V.on("snap.util.getattr.transform", function() { 10144 return V.stop(), 10145 this.transform() 10146 })(-1), 10147 V.on("snap.util.getattr.textpath", function() { 10148 return V.stop(), 10149 this.textPath 10150 })(-1), 10151 function() { 10152 function t(e) { 10153 return function() { 10154 V.stop(); 10155 var t = s.doc.defaultView.getComputedStyle(this.node, null).getPropertyValue("marker-" + e); 10156 return "none" == t ? t : o(s.doc.getElementById(t.match(p)[1])) 10157 } 10158 } 10159 function e(n) { 10160 return function(t) { 10161 V.stop(); 10162 var e = "marker" + n.charAt(0).toUpperCase() + n.substring(1); 10163 if ("" != t && t) { 10164 if ("marker" == t.type) { 10165 var i = t.node.id; 10166 return i || f(t.node, { 10167 id: t.id 10168 }), 10169 void (this.node.style[e] = g(i)) 10170 } 10171 } else 10172 this.node.style[e] = "none" 10173 } 10174 } 10175 V.on("snap.util.getattr.marker-end", t("end"))(-1), 10176 V.on("snap.util.getattr.markerEnd", t("end"))(-1), 10177 V.on("snap.util.getattr.marker-start", t("start"))(-1), 10178 V.on("snap.util.getattr.markerStart", t("start"))(-1), 10179 V.on("snap.util.getattr.marker-mid", t("mid"))(-1), 10180 V.on("snap.util.getattr.markerMid", t("mid"))(-1), 10181 V.on("snap.util.attr.marker-end", e("end"))(-1), 10182 V.on("snap.util.attr.markerEnd", e("end"))(-1), 10183 V.on("snap.util.attr.marker-start", e("start"))(-1), 10184 V.on("snap.util.attr.markerStart", e("start"))(-1), 10185 V.on("snap.util.attr.marker-mid", e("mid"))(-1), 10186 V.on("snap.util.attr.markerMid", e("mid"))(-1) 10187 }(), 10188 V.on("snap.util.getattr.r", function() { 10189 return "rect" == this.type && f(this.node, "rx") == f(this.node, "ry") ? (V.stop(), 10190 f(this.node, "rx")) : void 0 10191 })(-1), 10192 V.on("snap.util.getattr.text", function() { 10193 if ("text" == this.type || "tspan" == this.type) { 10194 V.stop(); 10195 var t = function t(e) { 10196 for (var i = [], n = e.childNodes, s = 0, o = n.length; s < o; s++) { 10197 var r = n[s]; 10198 3 == r.nodeType && i.push(r.nodeValue), 10199 "tspan" == r.tagName && i.push(1 == r.childNodes.length && 3 == r.firstChild.nodeType ? r.firstChild.nodeValue : t(r)) 10200 } 10201 return i 10202 }(this.node); 10203 return 1 == t.length ? t[0] : t 10204 } 10205 })(-1), 10206 V.on("snap.util.getattr.#text", function() { 10207 return this.node.textContent 10208 })(-1), 10209 V.on("snap.util.getattr.viewBox", function() { 10210 V.stop(); 10211 var t = f(this.node, "viewBox"); 10212 return t ? (t = t.split(v), 10213 o._.box(+t[0], +t[1], +t[2], +t[3])) : void 0 10214 })(-1), 10215 V.on("snap.util.getattr.points", function() { 10216 var t = f(this.node, "points"); 10217 return V.stop(), 10218 t ? t.split(v) : void 0 10219 })(-1), 10220 V.on("snap.util.getattr.path", function() { 10221 var t = f(this.node, "d"); 10222 return V.stop(), 10223 t 10224 })(-1), 10225 V.on("snap.util.getattr.class", function() { 10226 return this.node.className.baseVal 10227 })(-1), 10228 V.on("snap.util.getattr.fontSize", n)(-1), 10229 V.on("snap.util.getattr.font-size", n)(-1) 10230 }), 10231 e.plugin(function(t, e) { 10232 var u = /\S+/g 10233 , c = String 10234 , i = e.prototype; 10235 i.addClass = function(t) { 10236 var e, i, n, s = c(t || "").match(u) || [], o = this.node, r = o.className.baseVal, a = r.match(u) || []; 10237 if (s.length) { 10238 for (e = 0; i = s[e++]; ) 10239 ~a.indexOf(i) || a.push(i); 10240 r != (n = a.join(" ")) && (o.className.baseVal = n) 10241 } 10242 return this 10243 } 10244 , 10245 i.removeClass = function(t) { 10246 var e, i, n, s, o = c(t || "").match(u) || [], r = this.node, a = r.className.baseVal, l = a.match(u) || []; 10247 if (l.length) { 10248 for (e = 0; n = o[e++]; ) 10249 ~(i = l.indexOf(n)) && l.splice(i, 1); 10250 a != (s = l.join(" ")) && (r.className.baseVal = s) 10251 } 10252 return this 10253 } 10254 , 10255 i.hasClass = function(t) {
10256 return !!~(this.node.className.baseVal.match(u) || []).indexOf(t) 10257 } 10258 , 10259 i.toggleClass = function(t, e) { 10260 if (null != e) 10261 return e ? this.addClass(t) : this.removeClass(t); 10262 var i, n, s, o, r = (t || "").match(u) || [], a = this.node, l = a.className.baseVal, c = l.match(u) || []; 10263 for (i = 0; s = r[i++]; ) 10264 ~(n = c.indexOf(s)) ? c.splice(n, 1) : c.push(s); 10265 return l != (o = c.join(" ")) && (a.className.baseVal = o), 10266 this 10267 } 10268 }), 10269 e.plugin(function() { 10270 function l(t) { 10271 return t 10272 } 10273 var c = { 10274 "+": function(t, e) { 10275 return t + e 10276 }, 10277 "-": function(t, e) { 10278 return t - e 10279 }, 10280 "/": function(t, e) { 10281 return t / e 10282 }, 10283 "*": function(t, e) { 10284 return t * e 10285 } 10286 } 10287 , u = String 10288 , h = /[a-z]+$/i 10289 , d = /^\s*([+\-\/*])\s*=\s*([\d.eE+\-]+)\s*([^\d\s]+)?\s*$/; 10290 V.on("snap.util.attr", function(t) { 10291 var e = u(t).match(d); 10292 if (e) { 10293 var i = V.nt() 10294 , n = i.substring(i.lastIndexOf(".") + 1) 10295 , s = this.attr(n) 10296 , o = {}; 10297 V.stop(); 10298 var r = e[3] || "" 10299 , a = s.match(h) 10300 , l = c[e[1]]; 10301 if (a && a == r ? t = l(parseFloat(s), +e[2]) : (s = this.asPX(n), 10302 t = l(this.asPX(n), this.asPX(n, e[2] + r))), 10303 isNaN(s) || isNaN(t)) 10304 return; 10305 o[n] = t, 10306 this.attr(o) 10307 } 10308 })(-10), 10309 V.on("snap.util.equal", function(t, e) { 10310 var i, n = u(this.attr(t) || ""), s = u(e).match(d); 10311 if (s) { 10312 V.stop(); 10313 var o = s[3] || "" 10314 , r = n.match(h) 10315 , a = c[s[1]]; 10316 return r && r == o ? { 10317 from: parseFloat(n), 10318 to: a(parseFloat(n), +s[2]), 10319 f: (i = r, 10320 function(t) { 10321 return +t.toFixed(3) + i 10322 } 10323 ) 10324 } : { 10325 from: n = this.asPX(t), 10326 to: a(n, this.asPX(t, s[2] + o)), 10327 f: l 10328 } 10329 } 10330 })(-10) 10331 }), 10332 e.plugin(function(u, e, t, o) { 10333 var i = t.prototype 10334 , c = u.is; 10335 i.rect = function(t, e, i, n, s, o) { 10336 var r; 10337 return null == o && (o = s), 10338 c(t, "object") && "[object Object]" == t ? r = t : null != t && (r = { 10339 x: t, 10340 y: e, 10341 width: i, 10342 height: n 10343 }, 10344 null != s && (r.rx = s, 10345 r.ry = o)), 10346 this.el("rect", r) 10347 } 10348 , 10349 i.circle = function(t, e, i) { 10350 var n; 10351 return c(t, "object") && "[object Object]" == t ? n = t : null != t && (n = { 10352 cx: t, 10353 cy: e, 10354 r: i 10355 }), 10356 this.el("circle", n) 10357 } 10358 ; 10359 var a = function() { 10360 function s() { 10361 this.parentNode.removeChild(this) 10362 } 10363 return function(t, e) { 10364 var i = o.doc.createElement("img") 10365 , n = o.doc.body; 10366 i.style.cssText = "position:absolute;left:-9999em;top:-9999em", 10367 i.onload = function() { 10368 e.call(i), 10369 i.onload = i.onerror = null, 10370 n.removeChild(i) 10371 } 10372 , 10373 i.onerror = s, 10374 n.appendChild(i), 10375 i.src = t 10376 } 10377 }(); 10378 i.image = function(t, e, i, n, s) { 10379 var o = this.el("image"); 10380 if (c(t, "object") && "src"in t) 10381 o.attr(t); 10382 else if (null != t) { 10383 var r = { 10384 "xlink:href": t, 10385 preserveAspectRatio: "none" 10386 }; 10387 null != e && null != i && (r.x = e, 10388 r.y = i), 10389 null != n && null != s ? (r.width = n, 10390 r.height = s) : a(t, function() { 10391 u._.$(o.node, { 10392 width: this.offsetWidth, 10393 height: this.offsetHeight 10394 }) 10395 }), 10396 u._.$(o.node, r) 10397 } 10398 return o 10399 } 10400 , 10401 i.ellipse = function(t, e, i, n) { 10402 var s; 10403 return c(t, "object") && "[object Object]" == t ? s = t : null != t && (s = { 10404 cx: t, 10405 cy: e, 10406 rx: i, 10407 ry: n 10408 }), 10409 this.el("ellipse", s) 10410 } 10411 , 10412 i.path = function(t) { 10413 var e; 10414 return c(t, "object") && !c(t, "array") ? e = t : t && (e = { 10415 d: t 10416 }), 10417 this.el("path", e) 10418 } 10419 , 10420 i.group = i.g = function(t) { 10421 var e = this.el("g"); 10422 return 1 == arguments.length && t && !t.type ? e.attr(t) : arguments.length && e.add(Array.prototype.slice.call(arguments, 0)), 10423 e 10424 } 10425 , 10426 i.svg = function(t, e, i, n, s, o, r, a) { 10427 var l = {}; 10428 return c(t, "object") && null == e ? l = t : (null != t && (l.x = t), 10429 null != e && (l.y = e), 10430 null != i && (l.width = i), 10431 null != n && (l.height = n), 10432 null != s && null != o && null != r && null != a && (l.viewBox = [s, o, r, a])), 10433 this.el("svg", l) 10434 } 10435 , 10436 i.mask = function(t) { 10437 var e = this.el("mask"); 10438 return 1 == arguments.length && t && !t.type ? e.attr(t) : arguments.length && e.add(Array.prototype.slice.call(arguments, 0)), 10439 e 10440 } 10441 , 10442 i.ptrn = function(t, e, i, n, s, o, r, a) { 10443 if (c(t, "object")) 10444 var l = t; 10445 else 10446 l = { 10447 patternUnits: "userSpaceOnUse" 10448 }, 10449 t && (l.x = t), 10450 e && (l.y = e), 10451 null != i && (l.width = i), 10452 null != n && (l.height = n), 10453 l.viewBox = null != s && null != o && null != r && null != a ? [s, o, r, a] : [t || 0, e || 0, i || 0, n || 0]; 10454 return this.el("pattern", l) 10455 } 10456 , 10457 i.use = function(t) { 10458 return null != t ? (t instanceof e && (t.attr("id") || t.attr({ 10459 id: u._.id(t) 10460 }), 10461 t = t.attr("id")), 10462 "#" == String(t).charAt() && (t = t.substring(1)), 10463 this.el("use", { 10464 "xlink:href": "#" + t 10465 })) : e.prototype.use.call(this) 10466 } 10467 , 10468 i.symbol = function(t, e, i, n) { 10469 var s = {}; 10470 return null != t && null != e && null != i && null != n && (s.viewBox = [t, e, i, n]), 10471 this.el("symbol", s) 10472 } 10473 , 10474 i.text = function(t, e, i) { 10475 var n = {}; 10476 return c(t, "object") ? n = t : null != t && (n = { 10477 x: t, 10478 y: e, 10479 text: i || "" 10480 }), 10481 this.el("text", n) 10482 } 10483 , 10484 i.line = function(t, e, i, n) { 10485 var s = {}; 10486 return c(t, "object") ? s = t : null != t && (s = { 10487 x1: t, 10488 x2: i, 10489 y1: e, 10490 y2: n 10491 }), 10492 this.el("line", s) 10493 } 10494 , 10495 i.polyline = function(t) { 10496 1 < arguments.length && (t = Array.prototype.slice.call(arguments, 0)); 10497 var e = {}; 10498 return c(t, "object") && !c(t, "array") ? e = t : null != t && (e = { 10499 points: t 10500 }), 10501 this.el("polyline", e) 10502 } 10503 , 10504 i.polygon = function(t) { 10505 1 < arguments.length && (t = Array.prototype.slice.call(arguments, 0)); 10506 var e = {}; 10507 return c(t, "object") && !c(t, "array") ? e = t : null != t && (e = { 10508 points: t 10509 }), 10510 this.el("polygon", e) 10511 } 10512 , 10513 function() { 10514 function a() { 10515 return this.selectAll("stop") 10516 } 10517 function l(t, e) { 10518 var i = p("stop") 10519 , n = { 10520 offset: +e + "%" 10521 }; 10522 return t = u.color(t), 10523 n["stop-color"] = t.hex, 10524 t.opacity < 1 && (n["stop-opacity"] = t.opacity), 10525 p(i, n), 10526 this.node.appendChild(i), 10527 this 10528 } 10529 function c() { 10530 if ("linearGradient" == this.type) { 10531 var t = p(this.node, "x1") || 0 10532 , e = p(this.node, "x2") || 1 10533 , i = p(this.node, "y1") || 0 10534 , n = p(this.node, "y2") || 0; 10535 return u._.box(t, i, math.abs(e - t), math.abs(n - i)) 10536 } 10537 var s = this.node.cx || .5 10538 , o = this.node.cy || .5 10539 , r = this.node.r || 0; 10540 return u._.box(s - r, o - r, 2 * r, 2 * r) 10541 } 10542 function h(t, e, i, n, s) { 10543 var o = u._.make("linearGradient", t); 10544 return o.stops = a, 10545 o.addStop = l, 10546 o.getBBox = c, 10547 null != e && p(o.node, { 10548 x1: e, 10549 y1: i, 10550 x2: n, 10551 y2: s 10552 }), 10553 o 10554 } 10555 function d(t, e, i, n, s, o) { 10556 var r = u._.make("radialGradient", t); 10557 return r.stops = a, 10558 r.addStop = l, 10559 r.getBBox = c, 10560 null != e && p(r.node, { 10561 cx: e, 10562 cy: i, 10563 r: n 10564 }), 10565 null != s && null != o && p(r.node, { 10566 fx: s, 10567 fy: o 10568 }), 10569 r 10570 } 10571 var p = u._.$; 10572 i.gradient = function(t) { 10573 return function(t, e) { 10574 function i(t, e) { 10575 for (var i = (e - a) / (t - l), n = l; n < t; n++) 10576 o[n].offset = +(+a + i * (n - l)).toFixed(2); 10577 l = t, 10578 a = e 10579 } 10580 var n, s = V("snap.util.grad.parse", null, e).firstDefined(); 10581 if (!s) 10582 return null; 10583 s.params.unshift(t), 10584 n = "l" == s.type.toLowerCase() ? h.apply(0, s.params) : d.apply(0, s.params), 10585 s.type != s.type.toLowerCase() && p(n.node, { 10586 gradientUnits: "userSpaceOnUse" 10587 }); 10588 var o = s.stops 10589 , r = o.length 10590 , a = 0 10591 , l = 0; 10592 r--; 10593 for (var c = 0; c < r; c++) 10594 "offset"in o[c] && i(c, o[c].offset); 10595 for (o[r].offset = o[r].offset || 100, 10596 i(r, o[r].offset), 10597 c = 0; c <= r; c++) { 10598 var u = o[c]; 10599 n.addStop(u.color, u.offset) 10600 } 10601 return n 10602 }(this.defs, t) 10603 } 10604 , 10605 i.gradientLinear = function(t, e, i, n) { 10606 return h(this.defs, t, e, i, n) 10607 } 10608 , 10609 i.gradientRadial = function(t, e, i, n, s) { 10610 return d(this.defs, t, e, i, n, s) 10611 } 10612 , 10613 i.toString = function() { 10614 var t, e = this.node.ownerDocument, i = e.createDocumentFragment(), n = e.createElement("div"), s = this.node.cloneNode(!0); 10615 return i.appendChild(n), 10616 n.appendChild(s), 10617 u._.$(s, { 10618 xmlns: "http://www.w3.org/2000/svg" 10619 }), 10620 t = n.innerHTML, 10621 i.removeChild(i.firstChild), 10622 t 10623 } 10624 , 10625 i.toDataURL = function() { 10626 return x && x.btoa ? "data:image/svg+xml;base64," + btoa(unescape(encodeURIComponent(this))) : void 0 10627 } 10628 , 10629 i.clear = function() { 10630 for (var t, e = this.node.firstChild; e; ) 10631 t = e.nextSibling, 10632 "defs" != e.tagName ? e.parentNode.removeChild(e) : i.clear.call({ 10633 node: e 10634 }), 10635 e = t 10636 } 10637 }() 10638 }), 10639 e.plugin(function(B, m) { 10640 function w(e) { 10641 var i = w.ps = w.ps || {}; 10642 return i[e] ? i[e].sleep = 100 : i[e] = { 10643 sleep: 100 10644 }, 10645 setTimeout(function() {
10646 for (var t in i) 10647 i[n](t) && t != e && (i[t].sleep--, 10648 !i[t].sleep && delete i[t]) 10649 }), 10650 i[e] 10651 } 10652 function g(t, e, i, n) { 10653 return null == t && (t = e = i = n = 0), 10654 null == e && (e = t.y, 10655 i = t.width, 10656 n = t.height, 10657 t = t.x), 10658 { 10659 x: t, 10660 y: e, 10661 width: i, 10662 w: i, 10663 height: n, 10664 h: n, 10665 x2: t + i, 10666 y2: e + n, 10667 cx: t + i / 2, 10668 cy: e + n / 2, 10669 r1: q.min(i, n) / 2, 10670 r2: q.max(i, n) / 2, 10671 r0: q.sqrt(i * i + n * n) / 2, 10672 path: r(t, e, i, n), 10673 vb: [t, e, i, n].join(" ") 10674 } 10675 } 10676 function b() { 10677 return this.join(",").replace(i, "$1") 10678 } 10679 function x(t) { 10680 var e = f(t); 10681 return e.toString = b, 10682 e 10683 } 10684 function v(t, e, i, n, s, o, r, a, l) { 10685 return null == l ? T(t, e, i, n, s, o, r, a) : _(t, e, i, n, s, o, r, a, function(t, e, i, n, s, o, r, a, l) { 10686 if (!(l < 0 || T(t, e, i, n, s, o, r, a) < l)) { 10687 var c, u = .5, h = 1 - u; 10688 for (c = T(t, e, i, n, s, o, r, a, h); .01 < X(c - l); ) 10689 c = T(t, e, i, n, s, o, r, a, h += (c < l ? 1 : -1) * (u /= 2)); 10690 return h 10691 } 10692 }(t, e, i, n, s, o, r, a, l)) 10693 } 10694 function t(p, f) { 10695 function g(t) { 10696 return +(+t).toFixed(3) 10697 } 10698 return B._.cacher(function(t, e, i) { 10699 t instanceof m && (t = t.attr("d")); 10700 for (var n, s, o, r, a, l = "", c = {}, u = 0, h = 0, d = (t = j(t)).length; h < d; h++) { 10701 if ("M" == (o = t[h])[0]) 10702 n = +o[1], 10703 s = +o[2]; 10704 else { 10705 if (e < u + (r = v(n, s, o[1], o[2], o[3], o[4], o[5], o[6]))) { 10706 if (f && !c.start) { 10707 if (l += ["C" + g((a = v(n, s, o[1], o[2], o[3], o[4], o[5], o[6], e - u)).start.x), g(a.start.y), g(a.m.x), g(a.m.y), g(a.x), g(a.y)], 10708 i) 10709 return l; 10710 c.start = l, 10711 l = ["M" + g(a.x), g(a.y) + "C" + g(a.n.x), g(a.n.y), g(a.end.x), g(a.end.y), g(o[5]), g(o[6])].join(), 10712 u += r, 10713 n = +o[5], 10714 s = +o[6]; 10715 continue 10716 } 10717 if (!p && !f) 10718 return v(n, s, o[1], o[2], o[3], o[4], o[5], o[6], e - u) 10719 } 10720 u += r, 10721 n = +o[5], 10722 s = +o[6] 10723 } 10724 l += o.shift() + o 10725 } 10726 return c.end = l, 10727 p ? u : f ? c : _(n, s, o[0], o[1], o[2], o[3], o[4], o[5], 1) 10728 }, null, B._.clone) 10729 } 10730 function _(t, e, i, n, s, o, r, a, l) { 10731 var c = 1 - l 10732 , u = H(c, 3) 10733 , h = H(c, 2) 10734 , d = l * l 10735 , p = d * l 10736 , f = t + 2 * l * (i - t) + d * (s - 2 * i + t) 10737 , g = e + 2 * l * (n - e) + d * (o - 2 * n + e) 10738 , m = i + 2 * l * (s - i) + d * (r - 2 * s + i) 10739 , v = n + 2 * l * (o - n) + d * (a - 2 * o + n); 10740 return { 10741 x: u * t + 3 * h * l * i + 3 * c * l * l * s + p * r, 10742 y: u * e + 3 * h * l * n + 3 * c * l * l * o + p * a, 10743 m: { 10744 x: f, 10745 y: g 10746 }, 10747 n: { 10748 x: m, 10749 y: v 10750 }, 10751 start: { 10752 x: c * t + l * i, 10753 y: c * e + l * n 10754 }, 10755 end: { 10756 x: c * s + l * r, 10757 y: c * o + l * a 10758 }, 10759 alpha: 90 - 180 * q.atan2(f - m, g - v) / Y 10760 } 10761 } 10762 function k(t, e, i, n, s, o, r, a) { 10763 B.is(t, "array") || (t = [t, e, i, n, s, o, r, a]); 10764 var l = p.apply(null, t); 10765 return g(l.min.x, l.min.y, l.max.x - l.min.x, l.max.y - l.min.y) 10766 } 10767 function y(t, e, i) { 10768 return e >= t.x && e <= t.x + t.width && i >= t.y && i <= t.y + t.height 10769 } 10770 function C(t, e) { 10771 return t = g(t), 10772 y(e = g(e), t.x, t.y) || y(e, t.x2, t.y) || y(e, t.x, t.y2) || y(e, t.x2, t.y2) || y(t, e.x, e.y) || y(t, e.x2, e.y) || y(t, e.x, e.y2) || y(t, e.x2, e.y2) || (t.x < e.x2 && t.x > e.x || e.x < t.x2 && e.x > t.x) && (t.y < e.y2 && t.y > e.y || e.y < t.y2 && e.y > t.y) 10773 } 10774 function S(t, e, i, n, s) { 10775 return t * (t * (-3 * e + 9 * i - 9 * n + 3 * s) + 6 * e - 12 * i + 6 * n) - 3 * e + 3 * i 10776 } 10777 function T(t, e, i, n, s, o, r, a, l) { 10778 null == l && (l = 1); 10779 for (var c = (l = 1 < l ? 1 : l < 0 ? 0 : l) / 2, u = [-.1252, .1252, -.3678, .3678, -.5873, .5873, -.7699, .7699, -.9041, .9041, -.9816, .9816], h = [.2491, .2491, .2335, .2335, .2032, .2032, .1601, .1601, .1069, .1069, .0472, .0472], d = 0, p = 0; p < 12; p++) { 10780 var f = c * u[p] + c 10781 , g = S(f, t, i, s, r) 10782 , m = S(f, e, n, o, a) 10783 , v = g * g + m * m; 10784 d += h[p] * q.sqrt(v) 10785 } 10786 return c * d 10787 } 10788 function I(t, e, i, n, s, o, r, a) { 10789 if (!(N(t, i) < L(s, r) || L(t, i) > N(s, r) || N(e, n) < L(o, a) || L(e, n) > N(o, a))) { 10790 var l = (t - i) * (o - a) - (e - n) * (s - r); 10791 if (l) { 10792 var c = ((t * n - e * i) * (s - r) - (t - i) * (s * a - o * r)) / l 10793 , u = ((t * n - e * i) * (o - a) - (e - n) * (s * a - o * r)) / l 10794 , h = +c.toFixed(2) 10795 , d = +u.toFixed(2); 10796 if (!(h < +L(t, i).toFixed(2) || h > +N(t, i).toFixed(2) || h < +L(s, r).toFixed(2) || h > +N(s, r).toFixed(2) || d < +L(e, n).toFixed(2) || d > +N(e, n).toFixed(2) || d < +L(o, a).toFixed(2) || d > +N(o, a).toFixed(2))) 10797 return { 10798 x: c, 10799 y: u 10800 } 10801 } 10802 } 10803 } 10804 function P(t, e, i) { 10805 if (!C(k(t), k(e))) 10806 return i ? 0 : []; 10807 for (var n = ~~(T.apply(0, t) / 8), s = ~~(T.apply(0, e) / 8), o = [], r = [], a = {}, l = i ? 0 : [], c = 0; c < n + 1; c++) { 10808 var u = _.apply(0, t.concat(c / n)); 10809 o.push({ 10810 x: u.x, 10811 y: u.y, 10812 t: c / n 10813 }) 10814 } 10815 for (c = 0; c < s + 1; c++) 10816 u = _.apply(0, e.concat(c / s)), 10817 r.push({ 10818 x: u.x, 10819 y: u.y, 10820 t: c / s 10821 }); 10822 for (c = 0; c < n; c++) 10823 for (var h = 0; h < s; h++) { 10824 var d = o[c] 10825 , p = o[c + 1] 10826 , f = r[h] 10827 , g = r[h + 1] 10828 , m = X(p.x - d.x) < .001 ? "y" : "x" 10829 , v = X(g.x - f.x) < .001 ? "y" : "x" 10830 , y = I(d.x, d.y, p.x, p.y, f.x, f.y, g.x, g.y); 10831 if (y) { 10832 if (a[y.x.toFixed(4)] == y.y.toFixed(4)) 10833 continue; 10834 a[y.x.toFixed(4)] = y.y.toFixed(4); 10835 var b = d.t + X((y[m] - d[m]) / (p[m] - d[m])) * (p.t - d.t) 10836 , w = f.t + X((y[v] - f[v]) / (g[v] - f[v])) * (g.t - f.t); 10837 0 <= b && b <= 1 && 0 <= w && w <= 1 && (i ? l++ : l.push({ 10838 x: y.x, 10839 y: y.y, 10840 t1: b, 10841 t2: w 10842 })) 10843 } 10844 } 10845 return l 10846 } 10847 function s(t, e, i) { 10848 t = j(t), 10849 e = j(e); 10850 for (var n, s, o, r, a, l, c, u, h, d, p = i ? 0 : [], f = 0, g = t.length; f < g; f++) { 10851 var m = t[f]; 10852 if ("M" == m[0]) 10853 n = a = m[1], 10854 s = l = m[2]; 10855 else {
10856 "C" == m[0] ? (n = (h = [n, s].concat(m.slice(1)))[6], 10857 s = h[7]) : (h = [n, s, n, s, a, l, a, l], 10858 n = a, 10859 s = l); 10860 for (var v = 0, y = e.length; v < y; v++) { 10861 var b = e[v]; 10862 if ("M" == b[0]) 10863 o = c = b[1], 10864 r = u = b[2]; 10865 else { 10866 "C" == b[0] ? (o = (d = [o, r].concat(b.slice(1)))[6], 10867 r = d[7]) : (d = [o, r, o, r, c, u, c, u], 10868 o = c, 10869 r = u); 10870 var w = P(h, d, i); 10871 if (i) 10872 p += w; 10873 else { 10874 for (var x = 0, _ = w.length; x < _; x++) 10875 w[x].segment1 = f, 10876 w[x].segment2 = v, 10877 w[x].bez1 = h, 10878 w[x].bez2 = d; 10879 p = p.concat(w) 10880 } 10881 } 10882 } 10883 } 10884 } 10885 return p 10886 } 10887 function o(t) { 10888 var e = w(t); 10889 if (e.bbox) 10890 return f(e.bbox); 10891 if (!t) 10892 return g(); 10893 for (var i, n = 0, s = 0, o = [], r = [], a = 0, l = (t = j(t)).length; a < l; a++) 10894 if ("M" == (i = t[a])[0]) 10895 n = i[1], 10896 s = i[2], 10897 o.push(n), 10898 r.push(s); 10899 else { 10900 var c = p(n, s, i[1], i[2], i[3], i[4], i[5], i[6]); 10901 o = o.concat(c.min.x, c.max.x), 10902 r = r.concat(c.min.y, c.max.y), 10903 n = i[5], 10904 s = i[6] 10905 } 10906 var u = L.apply(0, o) 10907 , h = L.apply(0, r) 10908 , d = g(u, h, N.apply(0, o) - u, N.apply(0, r) - h); 10909 return e.bbox = f(d), 10910 d 10911 } 10912 function r(t, e, i, n, s) { 10913 if (s) 10914 return [["M", +t + +s, e], ["l", i - 2 * s, 0], ["a", s, s, 0, 0, 1, s, s], ["l", 0, n - 2 * s], ["a", s, s, 0, 0, 1, -s, s], ["l", 2 * s - i, 0], ["a", s, s, 0, 0, 1, -s, -s], ["l", 0, 2 * s - n], ["a", s, s, 0, 0, 1, s, -s], ["z"]]; 10915 var o = [["M", t, e], ["l", i, 0], ["l", 0, n], ["l", -i, 0], ["z"]]; 10916 return o.toString = b, 10917 o 10918 } 10919 function E(t, e, i, n, s) { 10920 if (null == s && null == n && (n = i), 10921 t = +t, 10922 e = +e, 10923 i = +i, 10924 n = +n, 10925 null != s) 10926 var o = Math.PI / 180 10927 , r = t + i * Math.cos(-n * o) 10928 , a = t + i * Math.cos(-s * o) 10929 , l = [["M", r, e + i * Math.sin(-n * o)], ["A", i, i, 0, +(180 < s - n), 0, a, e + i * Math.sin(-s * o)]]; 10930 else 10931 l = [["M", t, e], ["m", 0, -n], ["a", i, n, 0, 1, 1, 0, 2 * n], ["a", i, n, 0, 1, 1, 0, -2 * n], ["z"]]; 10932 return l.toString = b, 10933 l 10934 } 10935 function M(t) { 10936 var e = w(t); 10937 if (e.abs) 10938 return x(e.abs); 10939 if (z(t, "array") && z(t && t[0], "array") || (t = B.parsePathString(t)), 10940 !t || !t.length) 10941 return [["M", 0, 0]]; 10942 var i, n = [], s = 0, o = 0, r = 0, a = 0, l = 0; 10943 "M" == t[0][0] && (r = s = +t[0][1], 10944 a = o = +t[0][2], 10945 l++, 10946 n[0] = ["M", s, o]); 10947 for (var c, u, h = 3 == t.length && "M" == t[0][0] && "R" == t[1][0].toUpperCase() && "Z" == t[2][0].toUpperCase(), d = l, p = t.length; d < p; d++) { 10948 if (n.push(c = []), 10949 (i = (u = t[d])[0]) != i.toUpperCase()) 10950 switch (c[0] = i.toUpperCase(), 10951 c[0]) { 10952 case "A": 10953 c[1] = u[1], 10954 c[2] = u[2], 10955 c[3] = u[3], 10956 c[4] = u[4], 10957 c[5] = u[5], 10958 c[6] = +u[6] + s, 10959 c[7] = +u[7] + o; 10960 break; 10961 case "V": 10962 c[1] = +u[1] + o; 10963 break; 10964 case "H": 10965 c[1] = +u[1] + s; 10966 break; 10967 case "R": 10968 for (var f = [s, o].concat(u.slice(1)), g = 2, m = f.length; g < m; g++) 10969 f[g] = +f[g] + s, 10970 f[++g] = +f[g] + o; 10971 n.pop(), 10972 n = n.concat(O(f, h)); 10973 break; 10974 case "O": 10975 n.pop(), 10976 (f = E(s, o, u[1], u[2])).push(f[0]), 10977 n = n.concat(f); 10978 break; 10979 case "U": 10980 n.pop(), 10981 n = n.concat(E(s, o, u[1], u[2], u[3])), 10982 c = ["U"].concat(n[n.length - 1].slice(-2)); 10983 break; 10984 case "M": 10985 r = +u[1] + s, 10986 a = +u[2] + o; 10987 default: 10988 for (g = 1, 10989 m = u.length; g < m; g++) 10990 c[g] = +u[g] + (g % 2 ? s : o) 10991 } 10992 else if ("R" == i) 10993 f = [s, o].concat(u.slice(1)), 10994 n.pop(), 10995 n = n.concat(O(f, h)), 10996 c = ["R"].concat(u.slice(-2)); 10997 else if ("O" == i) 10998 n.pop(), 10999 (f = E(s, o, u[1], u[2])).push(f[0]), 11000 n = n.concat(f); 11001 else if ("U" == i) 11002 n.pop(), 11003 n = n.concat(E(s, o, u[1], u[2], u[3])), 11004 c = ["U"].concat(n[n.length - 1].slice(-2)); 11005 else 11006 for (var v = 0, y = u.length; v < y; v++) 11007 c[v] = u[v]; 11008 if ("O" != (i = i.toUpperCase())) 11009 switch (c[0]) { 11010 case "Z": 11011 s = +r, 11012 o = +a; 11013 break; 11014 case "H": 11015 s = c[1]; 11016 break; 11017 case "V": 11018 o = c[1]; 11019 break; 11020 case "M": 11021 r = c[c.length - 2], 11022 a = c[c.length - 1]; 11023 default: 11024 s = c[c.length - 2], 11025 o = c[c.length - 1] 11026 } 11027 } 11028 return n.toString = b, 11029 e.abs = x(n), 11030 n 11031 } 11032 function D(t, e, i, n) { 11033 return [t, e, i, n, i, n] 11034 } 11035 function A(t, e, i, n, s, o) { 11036 return [1 / 3 * t + 2 / 3 * i, 1 / 3 * e + 2 / 3 * n, 1 / 3 * s + 2 / 3 * i, 1 / 3 * o + 2 / 3 * n, s, o] 11037 } 11038 function p(t, e, i, n, s, o, r, a) { 11039 for (var l, c, u, h, d, p, f, g, m = [], v = [[], []], y = 0; y < 2; ++y)
11040 if (0 == y ? (c = 6 * t - 12 * i + 6 * s, 11041 l = -3 * t + 9 * i - 9 * s + 3 * r, 11042 u = 3 * i - 3 * t) : (c = 6 * e - 12 * n + 6 * o, 11043 l = -3 * e + 9 * n - 9 * o + 3 * a, 11044 u = 3 * n - 3 * e), 11045 X(l) < 1e-12) { 11046 if (X(c) < 1e-12) 11047 continue; 11048 0 < (h = -u / c) && h < 1 && m.push(h) 11049 } else 11050 f = c * c - 4 * u * l, 11051 g = q.sqrt(f), 11052 f < 0 || (0 < (d = (-c + g) / (2 * l)) && d < 1 && m.push(d), 11053 0 < (p = (-c - g) / (2 * l)) && p < 1 && m.push(p)); 11054 for (var b, w = m.length, x = w; w--; ) 11055 b = 1 - (h = m[w]), 11056 v[0][w] = b * b * b * t + 3 * b * b * h * i + 3 * b * h * h * s + h * h * h * r, 11057 v[1][w] = b * b * b * e + 3 * b * b * h * n + 3 * b * h * h * o + h * h * h * a; 11058 return v[0][x] = t, 11059 v[1][x] = e, 11060 v[0][x + 1] = r, 11061 v[1][x + 1] = a, 11062 v[0].length = v[1].length = x + 2, 11063 { 11064 min: { 11065 x: L.apply(0, v[0]), 11066 y: L.apply(0, v[1]) 11067 }, 11068 max: { 11069 x: N.apply(0, v[0]), 11070 y: N.apply(0, v[1]) 11071 } 11072 } 11073 } 11074 function j(t, e) { 11075 var i = !e && w(t); 11076 if (!e && i.curve) 11077 return x(i.curve); 11078 for (var o = M(t), r = e && M(e), n = { 11079 x: 0, 11080 y: 0, 11081 bx: 0, 11082 by: 0, 11083 X: 0, 11084 Y: 0, 11085 qx: null, 11086 qy: null 11087 }, s = { 11088 x: 0, 11089 y: 0, 11090 bx: 0, 11091 by: 0, 11092 X: 0, 11093 Y: 0, 11094 qx: null, 11095 qy: null 11096 }, a = function(t, e, i) { 11097 var n, s; 11098 if (!t) 11099 return ["C", e.x, e.y, e.x, e.y, e.x, e.y]; 11100 switch (!(t[0]in { 11101 T: 1, 11102 Q: 1 11103 }) && (e.qx = e.qy = null), 11104 t[0]) { 11105 case "M": 11106 e.X = t[1], 11107 e.Y = t[2]; 11108 break; 11109 case "A": 11110 t = ["C"].concat(function t(e, i, n, s, o, r, a, l, c, u) { 11111 var h, d = 120 * Y / 180, p = Y / 180 * (+o || 0), f = [], g = B._.cacher(function(t, e, i) { 11112 return { 11113 x: t * q.cos(i) - e * q.sin(i), 11114 y: t * q.sin(i) + e * q.cos(i) 11115 } 11116 }); 11117 if (u) 11118 C = u[0], 11119 S = u[1], 11120 _ = u[2], 11121 k = u[3]; 11122 else { 11123 e = (h = g(e, i, -p)).x, 11124 i = h.y, 11125 l = (h = g(l, c, -p)).x, 11126 c = h.y; 11127 var m = (q.cos(Y / 180 * o), 11128 q.sin(Y / 180 * o), 11129 (e - l) / 2) 11130 , v = (i - c) / 2 11131 , y = m * m / (n * n) + v * v / (s * s); 11132 1 < y && (n *= y = q.sqrt(y), 11133 s *= y); 11134 var b = n * n 11135 , w = s * s 11136 , x = (r == a ? -1 : 1) * q.sqrt(X((b * w - b * v * v - w * m * m) / (b * v * v + w * m * m))) 11137 , _ = x * n * v / s + (e + l) / 2 11138 , k = x * -s * m / n + (i + c) / 2 11139 , C = q.asin(((i - k) / s).toFixed(9)) 11140 , S = q.asin(((c - k) / s).toFixed(9)); 11141 (C = e < _ ? Y - C : C) < 0 && (C = 2 * Y + C), 11142 (S = l < _ ? Y - S : S) < 0 && (S = 2 * Y + S), 11143 a && S < C && (C -= 2 * Y), 11144 !a && C < S && (S -= 2 * Y) 11145 } 11146 var T = S - C; 11147 if (X(T) > d) { 11148 var I = S 11149 , P = l 11150 , E = c; 11151 S = C + d * (a && C < S ? 1 : -1), 11152 f = t(l = _ + n * q.cos(S), c = k + s * q.sin(S), n, s, o, 0, a, P, E, [S, I, _, k]) 11153 } 11154 T = S - C; 11155 var M = q.cos(C) 11156 , D = q.sin(C) 11157 , A = q.cos(S) 11158 , j = q.sin(S) 11159 , O = q.tan(T / 4) 11160 , z = 4 / 3 * n * O 11161 , $ = 4 / 3 * s * O 11162 , L = [e, i] 11163 , N = [e + z * D, i - $ * M] 11164 , H = [l + z * j, c - $ * A] 11165 , W = [l, c]; 11166 if (N[0] = 2 * L[0] - N[0], 11167 N[1] = 2 * L[1] - N[1], 11168 u) 11169 return [N, H, W].concat(f); 11170 for (var R = [], F = 0, Q = (f = [N, H, W].concat(f).join().split(",")).length; F < Q; F++) 11171 R[F] = F % 2 ? g(f[F - 1], f[F], p).y : g(f[F], f[F + 1], p).x; 11172 return R 11173 } 11174 .apply(0, [e.x, e.y].concat(t.slice(1)))); 11175 break; 11176 case "S": 11177 "C" == i || "S" == i ? (n = 2 * e.x - e.bx, 11178 s = 2 * e.y - e.by) : (n = e.x, 11179 s = e.y), 11180 t = ["C", n, s].concat(t.slice(1)); 11181 break; 11182 case "T": 11183 "Q" == i || "T" == i ? (e.qx = 2 * e.x - e.qx, 11184 e.qy = 2 * e.y - e.qy) : (e.qx = e.x, 11185 e.qy = e.y), 11186 t = ["C"].concat(A(e.x, e.y, e.qx, e.qy, t[1], t[2])); 11187 break; 11188 case "Q": 11189 e.qx = t[1], 11190 e.qy = t[2], 11191 t = ["C"].concat(A(e.x, e.y, t[1], t[2], t[3], t[4])); 11192 break; 11193 case "L": 11194 t = ["C"].concat(D(e.x, e.y, t[1], t[2])); 11195 break; 11196 case "H": 11197 t = ["C"].concat(D(e.x, e.y, t[1], e.y)); 11198 break; 11199 case "V": 11200 t = ["C"].concat(D(e.x, e.y, e.x, t[1])); 11201 break; 11202 case "Z": 11203 t = ["C"].concat(D(e.x, e.y, e.X, e.Y)) 11204 } 11205 return t 11206 }, l = function(t, e) { 11207 if (7 < t[e].length) { 11208 t[e].shift(); 11209 for (var i = t[e]; i.length; ) 11210 u[e] = "A", 11211 r && (h[e] = "A"), 11212 t.splice(e++, 0, ["C"].concat(i.splice(0, 6))); 11213 t.splice(e, 1), 11214 g = N(o.length, r && r.length || 0) 11215 } 11216 }, c = function(t, e, i, n, s) { 11217 t && e && "M" == t[s][0] && "M" != e[s][0] && (e.splice(s, 0, ["M", n.x, n.y]), 11218 i.bx = 0, 11219 i.by = 0, 11220 i.x = t[s][1], 11221 i.y = t[s][2], 11222 g = N(o.length, r && r.length || 0)) 11223 }, u = [], h = [], d = "", p = "", f = 0, g = N(o.length, r && r.length || 0); f < g; f++) { 11224 o[f] && (d = o[f][0]), 11225 "C" != d && (u[f] = d,
11226 f && (p = u[f - 1])), 11227 o[f] = a(o[f], n, p), 11228 "A" != u[f] && "C" == d && (u[f] = "C"), 11229 l(o, f), 11230 r && (r[f] && (d = r[f][0]), 11231 "C" != d && (h[f] = d, 11232 f && (p = h[f - 1])), 11233 r[f] = a(r[f], s, p), 11234 "A" != h[f] && "C" == d && (h[f] = "C"), 11235 l(r, f)), 11236 c(o, r, n, s, f), 11237 c(r, o, s, n, f); 11238 var m = o[f] 11239 , v = r && r[f] 11240 , y = m.length 11241 , b = r && v.length; 11242 n.x = m[y - 2], 11243 n.y = m[y - 1], 11244 n.bx = $(m[y - 4]) || n.x, 11245 n.by = $(m[y - 3]) || n.y, 11246 s.bx = r && ($(v[b - 4]) || s.x), 11247 s.by = r && ($(v[b - 3]) || s.y), 11248 s.x = r && v[b - 2], 11249 s.y = r && v[b - 1] 11250 } 11251 return r || (i.curve = x(o)), 11252 r ? [o, r] : o 11253 } 11254 function O(t, e) { 11255 for (var i = [], n = 0, s = t.length; n < s - 2 * !e; n += 2) { 11256 var o = [{ 11257 x: +t[n - 2], 11258 y: +t[n - 1] 11259 }, { 11260 x: +t[n], 11261 y: +t[n + 1] 11262 }, { 11263 x: +t[n + 2], 11264 y: +t[n + 3] 11265 }, { 11266 x: +t[n + 4], 11267 y: +t[n + 5] 11268 }]; 11269 e ? n ? s - 4 == n ? o[3] = { 11270 x: +t[0], 11271 y: +t[1] 11272 } : s - 2 == n && (o[2] = { 11273 x: +t[0], 11274 y: +t[1] 11275 }, 11276 o[3] = { 11277 x: +t[2], 11278 y: +t[3] 11279 }) : o[0] = { 11280 x: +t[s - 2], 11281 y: +t[s - 1] 11282 } : s - 4 == n ? o[3] = o[2] : n || (o[0] = { 11283 x: +t[n], 11284 y: +t[n + 1] 11285 }), 11286 i.push(["C", (-o[0].x + 6 * o[1].x + o[2].x) / 6, (-o[0].y + 6 * o[1].y + o[2].y) / 6, (o[1].x + 6 * o[2].x - o[3].x) / 6, (o[1].y + 6 * o[2].y - o[3].y) / 6, o[2].x, o[2].y]) 11287 } 11288 return i 11289 } 11290 var e = m.prototype 11291 , z = B.is 11292 , f = B._.clone 11293 , n = "hasOwnProperty" 11294 , i = /,?([a-z]),?/gi 11295 , $ = parseFloat 11296 , q = Math 11297 , Y = q.PI 11298 , L = q.min 11299 , N = q.max 11300 , H = q.pow 11301 , X = q.abs 11302 , a = t(1) 11303 , l = t() 11304 , c = t(0, 1) 11305 , u = B._unit2px 11306 , h = { 11307 path: function(t) { 11308 return t.attr("path") 11309 }, 11310 circle: function(t) { 11311 var e = u(t); 11312 return E(e.cx, e.cy, e.r) 11313 }, 11314 ellipse: function(t) { 11315 var e = u(t); 11316 return E(e.cx || 0, e.cy || 0, e.rx, e.ry) 11317 }, 11318 rect: function(t) { 11319 var e = u(t); 11320 return r(e.x || 0, e.y || 0, e.width, e.height, e.rx, e.ry) 11321 }, 11322 image: function(t) { 11323 var e = u(t); 11324 return r(e.x || 0, e.y || 0, e.width, e.height) 11325 }, 11326 line: function(t) { 11327 return "M" + [t.attr("x1") || 0, t.attr("y1") || 0, t.attr("x2"), t.attr("y2")] 11328 }, 11329 polyline: function(t) { 11330 return "M" + t.attr("points") 11331 }, 11332 polygon: function(t) { 11333 return "M" + t.attr("points") + "z" 11334 }, 11335 deflt: function(t) { 11336 var e = t.node.getBBox(); 11337 return r(e.x, e.y, e.width, e.height) 11338 } 11339 }; 11340 B.path = w, 11341 B.path.getTotalLength = a, 11342 B.path.getPointAtLength = l, 11343 B.path.getSubpath = function(t, e, i) { 11344 if (this.getTotalLength(t) - i < 1e-6) 11345 return c(t, e).end; 11346 var n = c(t, i, 1); 11347 return e ? c(n, e).end : n 11348 } 11349 , 11350 e.getTotalLength = function() { 11351 return this.node.getTotalLength ? this.node.getTotalLength() : void 0 11352 } 11353 , 11354 e.getPointAtLength = function(t) { 11355 return l(this.attr("d"), t) 11356 } 11357 , 11358 e.getSubpath = function(t, e) { 11359 return B.path.getSubpath(this.attr("d"), t, e) 11360 } 11361 , 11362 B._.box = g, 11363 B.path.findDotsAtSegment = _, 11364 B.path.bezierBBox = k, 11365 B.path.isPointInsideBBox = y, 11366 B.closest = function(t, e, i, n) { 11367 for (var s = 100, o = g(t - s / 2, e - s / 2, s, s), r = [], a = i[0].hasOwnProperty("x") ? function(t) { 11368 return { 11369 x: i[t].x, 11370 y: i[t].y 11371 } 11372 } 11373 : function(t) { 11374 return { 11375 x: i[t], 11376 y: n[t] 11377 } 11378 } 11379 , l = 0; s <= 1e6 && !l; ) { 11380 for (var c = 0, u = i.length; c < u; c++) { 11381 var h = a(c); 11382 if (y(o, h.x, h.y)) { 11383 l++, 11384 r.push(h); 11385 break 11386 } 11387 } 11388 l || (o = g(t - (s *= 2) / 2, e - s / 2, s, s)) 11389 } 11390 if (1e6 != s) { 11391 var d, p = 1 / 0; 11392 for (c = 0, 11393 u = r.length; c < u; c++) { 11394 var f = B.len(t, e, r[c].x, r[c].y); 11395 f < p && (p = f, 11396 r[c].len = f, 11397 d = r[c]) 11398 } 11399 return d 11400 } 11401 } 11402 , 11403 B.path.isBBoxIntersect = C, 11404 B.path.intersection = function(t, e) { 11405 return s(t, e) 11406 } 11407 , 11408 B.path.intersectionNumber = function(t, e) { 11409 return s(t, e, 1) 11410 } 11411 , 11412 B.path.isPointInside = function(t, e, i) { 11413 var n = o(t); 11414 return y(n, e, i) && s(t, [["M", e, i], ["H", n.x2 + 10]], 1) % 2 == 1 11415 } 11416 , 11417 B.path.getBBox = o, 11418 B.path.get = h, 11419 B.path.toRelative = function(t) { 11420 var e = w(t) 11421 , i = String.prototype.toLowerCase; 11422 if (e.rel) 11423 return x(e.rel); 11424 B.is(t, "array") && B.is(t && t[0], "array") || (t = B.parsePathString(t)); 11425 var n = [] 11426 , s = 0 11427 , o = 0 11428 , r = 0 11429 , a = 0 11430 , l = 0; 11431 "M" == t[0][0] && (r = s = t[0][1], 11432 a = o = t[0][2], 11433 l++, 11434 n.push(["M", s, o])); 11435 for (var c = l, u = t.length; c < u; c++) { 11436 var h = n[c] = [] 11437 , d = t[c]; 11438 if (d[0] != i.call(d[0])) 11439 switch (h[0] = i.call(d[0]), 11440 h[0]) { 11441 case "a": 11442 h[1] = d[1], 11443 h[2] = d[2], 11444 h[3] = d[3], 11445 h[4] = d[4], 11446 h[5] = d[5], 11447 h[6] = +(d[6] - s).toFixed(3), 11448 h[7] = +(d[7] - o).toFixed(3); 11449 break; 11450 case "v": 11451 h[1] = +(d[1] - o).toFixed(3); 11452 break; 11453 case "m": 11454 r = d[1], 11455 a = d[2]; 11456 default: 11457 for (var p = 1, f = d.length; p < f; p++) 11458 h[p] = +(d[p] - (p % 2 ? s : o)).toFixed(3) 11459 } 11460 else { 11461 h = n[c] = [], 11462 "m" == d[0] && (r = d[1] + s, 11463 a = d[2] + o); 11464 for (var g = 0, m = d.length; g < m; g++) 11465 n[c][g] = d[g] 11466 }
11467 var v = n[c].length; 11468 switch (n[c][0]) { 11469 case "z": 11470 s = r, 11471 o = a; 11472 break; 11473 case "h": 11474 s += +n[c][v - 1]; 11475 break; 11476 case "v": 11477 o += +n[c][v - 1]; 11478 break; 11479 default: 11480 s += +n[c][v - 2], 11481 o += +n[c][v - 1] 11482 } 11483 } 11484 return n.toString = b, 11485 e.rel = x(n), 11486 n 11487 } 11488 , 11489 B.path.toAbsolute = M, 11490 B.path.toCubic = j, 11491 B.path.map = function(t, e) { 11492 if (!e) 11493 return t; 11494 var i, n, s, o, r, a, l; 11495 for (s = 0, 11496 r = (t = j(t)).length; s < r; s++) 11497 for (o = 1, 11498 a = (l = t[s]).length; o < a; o += 2) 11499 i = e.x(l[o], l[o + 1]), 11500 n = e.y(l[o], l[o + 1]), 11501 l[o] = i, 11502 l[o + 1] = n; 11503 return t 11504 } 11505 , 11506 B.path.toString = b, 11507 B.path.clone = x 11508 }), 11509 e.plugin(function(h) { 11510 var a = Math.max 11511 , l = Math.min 11512 , c = function(t) { 11513 if (this.items = [], 11514 this.bindings = {}, 11515 this.length = 0, 11516 this.type = "set", 11517 t) 11518 for (var e = 0, i = t.length; e < i; e++) 11519 t[e] && (this[this.items.length] = this.items[this.items.length] = t[e], 11520 this.length++) 11521 } 11522 , t = c.prototype; 11523 t.push = function() { 11524 for (var t, e, i = 0, n = arguments.length; i < n; i++) 11525 (t = arguments[i]) && (this[e = this.items.length] = this.items[e] = t, 11526 this.length++); 11527 return this 11528 } 11529 , 11530 t.pop = function() { 11531 return this.length && delete this[this.length--], 11532 this.items.pop() 11533 } 11534 , 11535 t.forEach = function(t, e) { 11536 for (var i = 0, n = this.items.length; i < n; i++) 11537 if (!1 === t.call(e, this.items[i], i)) 11538 return this; 11539 return this 11540 } 11541 , 11542 t.animate = function(i, n, s, t) { 11543 "function" != typeof s || s.length || (t = s, 11544 s = S.linear), 11545 i instanceof h._.Animation && (t = i.callback, 11546 s = i.easing, 11547 n = s.dur, 11548 i = i.attr); 11549 var o = arguments; 11550 if (h.is(i, "array") && h.is(o[o.length - 1], "array")) 11551 var r = !0; 11552 var e, a = function() { 11553 e ? this.b = e : e = this.b 11554 }, l = 0, c = this, u = t && function() { 11555 ++l == c.length && t.call(this) 11556 } 11557 ; 11558 return this.forEach(function(t, e) { 11559 V.once("snap.animcreated." + t.id, a), 11560 r ? o[e] && t.animate.apply(t, o[e]) : t.animate(i, n, s, u) 11561 }) 11562 } 11563 , 11564 t.remove = function() { 11565 for (; this.length; ) 11566 this.pop().remove(); 11567 return this 11568 } 11569 , 11570 t.bind = function(t, e, i) { 11571 var n = {}; 11572 if ("function" == typeof e) 11573 this.bindings[t] = e; 11574 else { 11575 var s = i || t; 11576 this.bindings[t] = function(t) { 11577 n[s] = t, 11578 e.attr(n) 11579 } 11580 } 11581 return this 11582 } 11583 , 11584 t.attr = function(t) { 11585 var e = {}; 11586 for (var i in t) 11587 this.bindings[i] ? this.bindings[i](t[i]) : e[i] = t[i]; 11588 for (var n = 0, s = this.items.length; n < s; n++) 11589 this.items[n].attr(e); 11590 return this 11591 } 11592 , 11593 t.clear = function() { 11594 for (; this.length; ) 11595 this.pop() 11596 } 11597 , 11598 t.splice = function(t, e) { 11599 t = t < 0 ? a(this.length + t, 0) : t, 11600 e = a(0, l(this.length - t, e)); 11601 var i, n = [], s = [], o = []; 11602 for (i = 2; i < arguments.length; i++) 11603 o.push(arguments[i]); 11604 for (i = 0; i < e; i++) 11605 s.push(this[t + i]); 11606 for (; i < this.length - t; i++) 11607 n.push(this[t + i]); 11608 var r = o.length; 11609 for (i = 0; i < r + n.length; i++) 11610 this.items[t + i] = this[t + i] = i < r ? o[i] : n[i - r]; 11611 for (i = this.items.length = this.length -= e - r; this[i]; ) 11612 delete this[i++]; 11613 return new c(s) 11614 } 11615 , 11616 t.exclude = function(t) { 11617 for (var e = 0, i = this.length; e < i; e++) 11618 if (this[e] == t) 11619 return this.splice(e, 1), 11620 !0; 11621 return !1 11622 } 11623 , 11624 t.insertAfter = function(t) { 11625 for (var e = this.items.length; e--; ) 11626 this.items[e].insertAfter(t); 11627 return this 11628 } 11629 , 11630 t.getBBox = function() { 11631 for (var t = [], e = [], i = [], n = [], s = this.items.length; s--; ) 11632 if (!this.items[s].removed) { 11633 var o = this.items[s].getBBox(); 11634 t.push(o.x), 11635 e.push(o.y), 11636 i.push(o.x + o.width), 11637 n.push(o.y + o.height) 11638 } 11639 return { 11640 x: t = l.apply(0, t), 11641 y: e = l.apply(0, e), 11642 x2: i = a.apply(0, i), 11643 y2: n = a.apply(0, n), 11644 width: i - t, 11645 height: n - e, 11646 cx: t + (i - t) / 2, 11647 cy: e + (n - e) / 2 11648 } 11649 } 11650 , 11651 t.clone = function(t) { 11652 t = new c; 11653 for (var e = 0, i = this.items.length; e < i; e++) 11654 t.push(this.items[e].clone()); 11655 return t 11656 } 11657 , 11658 t.toString = function() { 11659 return "Snapâs set" 11660 } 11661 , 11662 t.type = "set", 11663 h.Set = c, 11664 h.set = function() { 11665 var t = new c; 11666 return arguments.length && t.push.apply(t, Array.prototype.slice.call(arguments, 0)), 11667 t 11668 } 11669 }), 11670 e.plugin(function(h, t) { 11671 function d(t) { 11672 var e = t[0]; 11673 switch (e.toLowerCase()) { 11674 case "t": 11675 return [e, 0, 0]; 11676 case "m": 11677 return [e, 1, 0, 0, 1, 0, 0]; 11678 case "r": 11679 return 4 == t.length ? [e, 0, t[2], t[3]] : [e, 0]; 11680 case "s": 11681 return 5 == t.length ? [e, 1, 1, t[3], t[4]] : 3 == t.length ? [e, 1, 1] : [e, 1] 11682 } 11683 } 11684 function p(t) { 11685 return t 11686 } 11687 function f(t) { 11688 return t.join(" ") 11689 } 11690 function g(t) { 11691 return h.rgb(t[0], t[1], t[2]) 11692 } 11693 function m(t) { 11694 var e, i, n, s, o, r, a = 0, l = []; 11695 for (e = 0, 11696 i = t.length; e < i; e++) { 11697 for (o = "[", 11698 r = ['"' + t[e][0] + '"'], 11699 n = 1, 11700 s = t[e].length; n < s; n++) 11701 r[n] = "val[" + a++ + "]"; 11702 o += r + "]", 11703 l[e] = o 11704 } 11705 return Function("val", "return Snap.path.toString.call([" + l + "])") 11706 } 11707 function v(t) { 11708 for (var e = [], i = 0, n = t.length; i < n; i++) 11709 for (var s = 1, o = t[i].length; s < o; s++) 11710 e.push(t[i][s]); 11711 return e 11712 } 11713 function y(t) { 11714 return isFinite(parseFloat(t)) 11715 } 11716 var b = {} 11717 , w = /[a-z]+$/i 11718 , x = String; 11719 b.stroke = b.fill = "colour", 11720 t.prototype.equal = function(t, e) { 11721 return V("snap.util.equal", this, t, e).firstDefined() 11722 } 11723 , 11724 V.on("snap.util.equal", function(t, e) { 11725 var i, n, s = x(this.attr(t) || ""), o = this; 11726 if (y(s) && y(e)) 11727 return { 11728 from: parseFloat(s), 11729 to: parseFloat(e), 11730 f: p 11731 }; 11732 if ("colour" == b[t]) 11733 return i = h.color(s), 11734 n = h.color(e), 11735 { 11736 from: [i.r, i.g, i.b, i.opacity], 11737 to: [n.r, n.g, n.b, n.opacity], 11738 f: g 11739 }; 11740 if ("viewBox" == t) 11741 return { 11742 from: i = this.attr(t).vb.split(" ").map(Number), 11743 to: n = e.split(" ").map(Number), 11744 f: f 11745 }; 11746 if ("transform" == t || "gradientTransform" == t || "patternTransform" == t) 11747 return e instanceof h.Matrix && (e = e.toTransformString()), 11748 h._.rgTransform.test(e) || (e = h._.svgTransform2string(e)), 11749 function(t, e, i) { 11750 e = x(e).replace(/\.{3}|\u2026/g, t), 11751 t = h.parseTransformString(t) || [], 11752 e = h.parseTransformString(e) || []; 11753 for (var n, s, o, r, a = Math.max(t.length, e.length), l = [], c = [], u = 0; u < a; u++) { 11754 if (o = t[u] || d(e[u]), 11755 r = e[u] || d(o), 11756 o[0] != r[0] || "r" == o[0].toLowerCase() && (o[2] != r[2] || o[3] != r[3]) || "s" == o[0].toLowerCase() && (o[3] != r[3] || o[4] != r[4])) { 11757 t = h._.transform2matrix(t, i()), 11758 e = h._.transform2matrix(e, i()), 11759 l = [["m", t.a, t.b, t.c, t.d, t.e, t.f]], 11760 c = [["m", e.a, e.b, e.c, e.d, e.e, e.f]]; 11761 break 11762 } 11763 for (l[u] = [], 11764 c[u] = [], 11765 n = 0, 11766 s = Math.max(o.length, r.length); n < s; n++) 11767 n in o && (l[u][n] = o[n]), 11768 n in r && (c[u][n] = r[n]) 11769 } 11770 return { 11771 from: v(l), 11772 to: v(c), 11773 f: m(l) 11774 } 11775 }(s, e, function() { 11776 return o.getBBox(1) 11777 }); 11778 if ("d" == t || "path" == t) 11779 return { 11780 from: v((i = h.path.toCubic(s, e))[0]), 11781 to: v(i[1]), 11782 f: m(i[0]) 11783 }; 11784 if ("points" == t) 11785 return { 11786 from: i = x(s).split(h._.separator), 11787 to: n = x(e).split(h._.separator), 11788 f: function(t) { 11789 return t 11790 } 11791 }; 11792 var r, a, l, c = s.match(w), u = x(e).match(w); 11793 return c && (a = c, 11794 l = u, 11795 h.is(a, "array") && h.is(l, "array") && a.toString() == l.toString()) ? { 11796 from: parseFloat(s), 11797 to: parseFloat(e), 11798 f: (r = c, 11799 function(t) { 11800 return +t.toFixed(3) + r 11801 } 11802 ) 11803 } : { 11804 from: this.asPX(t), 11805 to: this.asPX(t, e), 11806 f: p 11807 } 11808 }) 11809 }), 11810 e.plugin(function(d, t, e, s) { 11811 for (var i = t.prototype, p = ("createTouch"in s.doc), n = ["click", "dblclick", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "touchstart", "touchmove", "touchend", "touchcancel"], f = { 11812 mousedown: "touchstart", 11813 mousemove: "touchmove", 11814 mouseup: "touchend" 11815 }, g = function(t, e) { 11816 var i = "y" == t ? "scrollTop" : "scrollLeft" 11817 , n = e && e.node ? e.node.ownerDocument : s.doc; 11818 return n[i in n.documentElement ? "documentElement" : "body"][i] 11819 }, m = function() { 11820 return this.originalEvent.preventDefault() 11821 }, v = function() { 11822 return this.originalEvent.stopPropagation() 11823 }, u = [], h = function(t) { 11824 for (var e, i = t.clientX, n = t.clientY, s = g("y"), o = g("x"), r = u.length; r--; ) { 11825 if (e = u[r], 11826 p) { 11827 for (var a, l = t.touches && t.touches.length; l--; ) 11828 if ((a = t.touches[l]).identifier == e.el._drag.id || e.el.node.contains(a.target)) { 11829 i = a.clientX, 11830 n = a.clientY, 11831 (t.originalEvent ? t.originalEvent : t).preventDefault(); 11832 break 11833 } 11834 } else 11835 t.preventDefault(); 11836 var c = e.el.node;
11837 c.nextSibling, 11838 c.parentNode, 11839 c.style.display, 11840 i += o, 11841 n += s, 11842 V("snap.drag.move." + e.el.id, e.move_scope || e.el, i - e.el._drag.x, n - e.el._drag.y, i, n, t) 11843 } 11844 }, y = function(t) { 11845 d.unmousemove(h).unmouseup(y); 11846 for (var e, i = u.length; i--; ) 11847 (e = u[i]).el._drag = {}, 11848 V("snap.drag.end." + e.el.id, e.end_scope || e.start_scope || e.move_scope || e.el, t), 11849 V.off("snap.drag.*." + e.el.id); 11850 u = [] 11851 }, o = n.length; o--; ) 11852 !function(r) { 11853 d[r] = i[r] = function(t, e) { 11854 if (d.is(t, "function")) 11855 this.events = this.events || [], 11856 this.events.push({ 11857 name: r, 11858 f: t, 11859 unbind: (l = this.node || document, 11860 c = r, 11861 u = t, 11862 h = e || this, 11863 s = p && f[c] ? f[c] : c, 11864 o = function(t) { 11865 var e = g("y", h) 11866 , i = g("x", h); 11867 if (p && f.hasOwnProperty(c)) 11868 for (var n = 0, s = t.targetTouches && t.targetTouches.length; n < s; n++) 11869 if (t.targetTouches[n].target == l || l.contains(t.targetTouches[n].target)) { 11870 var o = t; 11871 (t = t.targetTouches[n]).originalEvent = o, 11872 t.preventDefault = m, 11873 t.stopPropagation = v; 11874 break 11875 } 11876 var r = t.clientX + i 11877 , a = t.clientY + e; 11878 return u.call(h, t, r, a) 11879 } 11880 , 11881 c !== s && l.addEventListener(c, o, !1), 11882 l.addEventListener(s, o, !1), 11883 function() { 11884 return c !== s && l.removeEventListener(c, o, !1), 11885 l.removeEventListener(s, o, !1), 11886 !0 11887 } 11888 ) 11889 }); 11890 else 11891 for (var i = 0, n = this.events.length; i < n; i++) 11892 if (this.events[i].name == r) 11893 try { 11894 this.events[i].f.call(this) 11895 } catch (t) {} 11896 var l, c, u, h, s, o; 11897 return this 11898 } 11899 , 11900 d["un" + r] = i["un" + r] = function(t) { 11901 for (var e = this.events || [], i = e.length; i--; ) 11902 if (e[i].name == r && (e[i].f == t || !t)) 11903 return e[i].unbind(), 11904 e.splice(i, 1), 11905 !e.length && delete this.events, 11906 this; 11907 return this 11908 } 11909 }(n[o]); 11910 i.hover = function(t, e, i, n) { 11911 return this.mouseover(t, i).mouseout(e, n || i) 11912 } 11913 , 11914 i.unhover = function(t, e) { 11915 return this.unmouseover(t).unmouseout(e) 11916 } 11917 ; 11918 var b = []; 11919 i.drag = function(n, s, o, r, a, l) { 11920 function t(t, e, i) { 11921 (t.originalEvent || t).preventDefault(), 11922 c._drag.x = e, 11923 c._drag.y = i, 11924 c._drag.id = t.identifier, 11925 !u.length && d.mousemove(h).mouseup(y), 11926 u.push({ 11927 el: c, 11928 move_scope: r, 11929 start_scope: a, 11930 end_scope: l 11931 }), 11932 s && V.on("snap.drag.start." + c.id, s), 11933 n && V.on("snap.drag.move." + c.id, n), 11934 o && V.on("snap.drag.end." + c.id, o), 11935 V("snap.drag.start." + c.id, a || r || c, e, i, t) 11936 } 11937 function e(t, e, i) { 11938 V("snap.draginit." + c.id, c, t, e, i) 11939 } 11940 var i, c = this; 11941 return arguments.length ? (V.on("snap.draginit." + c.id, t), 11942 c._drag = {}, 11943 b.push({ 11944 el: c, 11945 start: t, 11946 init: e 11947 }), 11948 c.mousedown(e), 11949 c) : c.drag(function(t, e) { 11950 this.attr({ 11951 transform: i + (i ? "T" : "t") + [t, e] 11952 }) 11953 }, function() { 11954 i = this.transform().local 11955 }) 11956 } 11957 , 11958 i.undrag = function() { 11959 for (var t = b.length; t--; ) 11960 b[t].el == this && (this.unmousedown(b[t].init), 11961 b.splice(t, 1), 11962 V.unbind("snap.drag.*." + this.id), 11963 V.unbind("snap.draginit." + this.id)); 11964 return !b.length && d.unmousemove(h).unmouseup(y), 11965 this 11966 } 11967 }), 11968 e.plugin(function(o, r, t) { 11969 var e = (r.prototype, 11970 t.prototype) 11971 , i = /^\s*url\((.+)\)/ 11972 , a = String 11973 , l = o._.$; 11974 o.filter = {}, 11975 e.filter = function(t) { 11976 var e = this; 11977 "svg" != e.type && (e = e.paper); 11978 var i = o.parse(a(t)) 11979 , n = o._.id() 11980 , s = (e.node.offsetWidth, 11981 e.node.offsetHeight, 11982 l("filter")); 11983 return l(s, { 11984 id: n, 11985 filterUnits: "userSpaceOnUse" 11986 }), 11987 s.appendChild(i.node), 11988 e.defs.appendChild(s), 11989 new r(s) 11990 } 11991 , 11992 V.on("snap.util.getattr.filter", function() { 11993 V.stop(); 11994 var t = l(this.node, "filter"); 11995 if (t) { 11996 var e = a(t).match(i); 11997 return e && o.select(e[1]) 11998 } 11999 }), 12000 V.on("snap.util.attr.filter", function(t) { 12001 if (t instanceof r && "filter" == t.type) { 12002 V.stop(); 12003 var e = t.node.id; 12004 e || (l(t.node, { 12005 id: t.id 12006 }), 12007 e = t.id), 12008 l(this.node, { 12009 filter: o.url(e) 12010 }) 12011 } 12012 t && "none" != t || (V.stop(), 12013 this.node.removeAttribute("filter")) 12014 }), 12015 o.filter.blur = function(t, e) { 12016 null == t && (t = 2); 12017 var i = null == e ? t : [t, e]; 12018 return o.format('<feGaussianBlur stdDeviation="{def}"/>', { 12019 def: i 12020 }) 12021 } 12022 , 12023 o.filter.blur.toString = function() { 12024 return this() 12025 } 12026 , 12027 o.filter.shadow = function(t, e, i, n, s) { 12028 return "string" == typeof i && (s = n = i, 12029 i = 4), 12030 "string" != typeof n && (s = n, 12031 n = "#000"), 12032 n = n || "#000", 12033 null == i && (i = 4), 12034 null == s && (s = 1), 12035 null == t && (t = 0, 12036 e = 2), 12037 null == e && (e = t), 12038 n = o.color(n), 12039 o.format('<feGaussianBlur in="SourceAlpha" stdDeviation="{blur}"/><feOffset dx="{dx}" dy="{dy}" result="offsetblur"/><feFlood flood-color="{color}"/><feComposite in2="offsetblur" operator="in"/><feComponentTransfer><feFuncA type="linear" slope="{opacity}"/></feComponentTransfer><feMerge><feMergeNode/><feMergeNode in="SourceGraphic"/></feMerge>', { 12040 color: n, 12041 dx: t, 12042 dy: e, 12043 blur: i, 12044 opacity: s 12045 }) 12046 } 12047 , 12048 o.filter.shadow.toString = function() { 12049 return this() 12050 } 12051 , 12052 o.filter.grayscale = function(t) { 12053 return null == t && (t = 1), 12054 o.format('<feColorMatrix type="matrix" values="{a} {b} {c} 0 0 {d} {e} {f} 0 0 {g} {b} {h} 0 0 0 0 0 1 0"/>', { 12055 a: .2126 + .7874 * (1 - t), 12056 b: .7152 - .7152 * (1 - t), 12057 c: .0722 - .0722 * (1 - t), 12058 d: .2126 - .2126 * (1 - t), 12059 e: .7152 + .2848 * (1 - t), 12060 f: .0722 - .0722 * (1 - t), 12061 g: .2126 - .2126 * (1 - t), 12062 h: .0722 + .9278 * (1 - t) 12063 }) 12064 } 12065 , 12066 o.filter.grayscale.toString = function() { 12067 return this() 12068 } 12069 , 12070 o.filter.sepia = function(t) { 12071 return null == t && (t = 1), 12072 o.format('<feColorMatrix type="matrix" values="{a} {b} {c} 0 0 {d} {e} {f} 0 0 {g} {h} {i} 0 0 0 0 0 1 0"/>', { 12073 a: .393 + .607 * (1 - t), 12074 b: .769 - .769 * (1 - t), 12075 c: .189 - .189 * (1 - t), 12076 d: .349 - .349 * (1 - t), 12077 e: .686 + .314 * (1 - t), 12078 f: .168 - .168 * (1 - t), 12079 g: .272 - .272 * (1 - t), 12080 h: .534 - .534 * (1 - t), 12081 i: .131 + .869 * (1 - t) 12082 }) 12083 } 12084 , 12085 o.filter.sepia.toString = function() { 12086 return this() 12087 } 12088 , 12089 o.filter.saturate = function(t) { 12090 return null == t && (t = 1), 12091 o.format('<feColorMatrix type="saturate" values="{amount}"/>', { 12092 amount: 1 - t 12093 }) 12094 } 12095 , 12096 o.filter.saturate.toString = function() { 12097 return this() 12098 } 12099 , 12100 o.filter.hueRotate = function(t) { 12101 return t = t || 0, 12102 o.format('<feColorMatrix type="hueRotate" values="{angle}"/>', { 12103 angle: t 12104 }) 12105 } 12106 , 12107 o.filter.hueRotate.toString = function() { 12108 return this() 12109 } 12110 , 12111 o.filter.invert = function(t) { 12112 return null == t && (t = 1), 12113 o.format('<feComponentTransfer><feFuncR type="table" tableValues="{amount} {amount2}"/><feFuncG type="table" tableValues="{amount} {amount2}"/><feFuncB type="table" tableValues="{amount} {amount2}"/></feComponentTransfer>', { 12114 amount: t, 12115 amount2: 1 - t 12116 }) 12117 } 12118 , 12119 o.filter.invert.toString = function() { 12120 return this() 12121 } 12122 , 12123 o.filter.brightness = function(t) { 12124 return null == t && (t = 1), 12125 o.format('<feComponentTransfer><feFuncR type="linear" slope="{amount}"/><feFuncG type="linear" slope="{amount}"/><feFuncB type="linear" slope="{amount}"/></feComponentTransfer>', { 12126 amount: t 12127 }) 12128 } 12129 , 12130 o.filter.brightness.toString = function() { 12131 return this() 12132 } 12133 , 12134 o.filter.contrast = function(t) { 12135 return null == t && (t = 1), 12136 o.format('<feComponentTransfer><feFuncR type="linear" slope="{amount}" intercept="{amount2}"/><feFuncG type="linear" slope="{amount}" intercept="{amount2}"/><feFuncB type="linear" slope="{amount}" intercept="{amount2}"/></feComponentTransfer>', { 12137 amount: t, 12138 amount2: .5 - t / 2 12139 }) 12140 } 12141 , 12142 o.filter.contrast.toString = function() { 12143 return this() 12144 } 12145 }), 12146 e.plugin(function(t, e) { 12147 var o = t._.box 12148 , r = t.is 12149 , a = /^[^a-z]*([tbmlrc])/i 12150 , l = function() { 12151 return "T" + this.dx + "," + this.dy 12152 }; 12153 e.prototype.getAlign = function(t, e) { 12154 null == e && r(t, "string") && (e = t, 12155 t = null); 12156 var i = (t = t || this.paper).getBBox ? t.getBBox() : o(t) 12157 , n = this.getBBox() 12158 , s = {}; 12159 switch (e = (e = e && e.match(a)) ? e[1].toLowerCase() : "c") { 12160 case "t": 12161 s.dx = 0, 12162 s.dy = i.y - n.y; 12163 break; 12164 case "b": 12165 s.dx = 0, 12166 s.dy = i.y2 - n.y2; 12167 break; 12168 case "m": 12169 s.dx = 0, 12170 s.dy = i.cy - n.cy; 12171 break; 12172 case "l": 12173 s.dx = i.x - n.x, 12174 s.dy = 0; 12175 break; 12176 case "r": 12177 s.dx = i.x2 - n.x2, 12178 s.dy = 0; 12179 break; 12180 default: 12181 s.dx = i.cx - n.cx, 12182 s.dy = 0 12183 } 12184 return s.toString = l, 12185 s 12186 } 12187 , 12188 e.prototype.align = function(t, e) { 12189 return this.transform("..." + this.getAlign(t, e)) 12190 } 12191 }), 12192 e 12193}), 12194function(s) { 12195 "use strict"; 12196 var o = function(t, e) { 12197 this.el = s(t), 12198 this.options = s.extend({}, s.fn.typed.defaults, e), 12199 this.isInput = this.el.is("input"), 12200 this.attr = this.options.attr, 12201 this.showCursor = !this.isInput && this.options.showCursor, 12202 this.elContent = this.attr ? this.el.attr(this.attr) : this.el.text(), 12203 this.contentType = this.options.contentType, 12204 this.typeSpeed = this.options.typeSpeed, 12205 this.startDelay = this.options.startDelay, 12206 this.backSpeed = this.options.backSpeed, 12207 this.backDelay = this.options.backDelay, 12208 this.stringsElement = this.options.stringsElement, 12209 this.strings = this.options.strings, 12210 this.strPos = 0, 12211 this.arrayPos = 0, 12212 this.stopNum = 0, 12213 this.loop = this.options.loop, 12214 this.loopCount = this.options.loopCount, 12215 this.curLoop = 0, 12216 this.stop = !1, 12217 this.cursorChar = this.options.cursorChar, 12218 this.shuffle = this.options.shuffle, 12219 this.sequence = [], 12220 this.build() 12221 }; 12222 o.prototype = { 12223 constructor: o, 12224 init: function() { 12225 var e = this; 12226 e.timeout = setTimeout(function() { 12227 for (var t = 0; t < e.strings.length; ++t) 12228 e.sequence[t] = t; 12229 e.shuffle && (e.sequence = e.shuffleArray(e.sequence)),
12230 e.typewrite(e.strings[e.sequence[e.arrayPos]], e.strPos) 12231 }, e.startDelay) 12232 }, 12233 build: function() { 12234 var i = this; 12235 if (!0 === this.showCursor && (this.cursor = s('<span class="typed-cursor">' + this.cursorChar + "</span>"), 12236 this.el.after(this.cursor)), 12237 this.stringsElement) { 12238 i.strings = [], 12239 this.stringsElement.hide(); 12240 var t = this.stringsElement.find("p"); 12241 s.each(t, function(t, e) { 12242 i.strings.push(s(e).html()) 12243 }) 12244 } 12245 this.init() 12246 }, 12247 typewrite: function(o, r) { 12248 if (!0 !== this.stop) { 12249 var t = Math.round(70 * Math.random()) + this.typeSpeed 12250 , a = this; 12251 a.timeout = setTimeout(function() { 12252 var t = 0 12253 , e = o.substr(r); 12254 if ("^" === e.charAt(0)) { 12255 var i = 1; 12256 /^\^\d+/.test(e) && (i += (e = /\d+/.exec(e)[0]).length, 12257 t = parseInt(e)), 12258 o = o.substring(0, r) + o.substring(r + i) 12259 } 12260 if ("html" === a.contentType) { 12261 var n = o.substr(r).charAt(0); 12262 if ("<" === n || "&" === n) { 12263 var s; 12264 for (s = "<" === n ? ">" : ";"; o.substr(r).charAt(0) !== s; ) 12265 o.substr(r).charAt(0), 12266 r++; 12267 r++, 12268 s 12269 } 12270 } 12271 a.timeout = setTimeout(function() { 12272 if (r === o.length) { 12273 if (a.options.onStringTyped(a.arrayPos), 12274 a.arrayPos === a.strings.length - 1 && (a.options.callback(), 12275 a.curLoop++, 12276 !1 === a.loop || a.curLoop === a.loopCount)) 12277 return; 12278 a.timeout = setTimeout(function() { 12279 a.backspace(o, r) 12280 }, a.backDelay) 12281 } else { 12282 0 === r && a.options.preStringTyped(a.arrayPos); 12283 var t = o.substr(0, r + 1); 12284 a.attr ? a.el.attr(a.attr, t) : a.isInput ? a.el.val(t) : "html" === a.contentType ? a.el.html(t) : a.el.text(t), 12285 r++, 12286 a.typewrite(o, r) 12287 } 12288 }, t) 12289 }, t) 12290 } 12291 }, 12292 backspace: function(e, i) { 12293 if (!0 !== this.stop) { 12294 var t = Math.round(70 * Math.random()) + this.backSpeed 12295 , n = this; 12296 n.timeout = setTimeout(function() { 12297 if ("html" === n.contentType && ">" === e.substr(i).charAt(0)) { 12298 for (; "<" !== e.substr(i).charAt(0); ) 12299 e.substr(i).charAt(0), 12300 i--; 12301 i--, 12302 "<" 12303 } 12304 var t = e.substr(0, i); 12305 n.attr ? n.el.attr(n.attr, t) : n.isInput ? n.el.val(t) : "html" === n.contentType ? n.el.html(t) : n.el.text(t), 12306 i > n.stopNum ? (i--, 12307 n.backspace(e, i)) : i <= n.stopNum && (n.arrayPos++, 12308 n.arrayPos === n.strings.length ? (n.arrayPos = 0, 12309 n.shuffle && (n.sequence = n.shuffleArray(n.sequence)), 12310 n.init()) : n.typewrite(n.strings[n.sequence[n.arrayPos]], i)) 12311 }, t) 12312 } 12313 }, 12314 shuffleArray: function(t) { 12315 var e, i, n = t.length; 12316 if (n) 12317 for (; --n; ) 12318 e = t[i = Math.floor(Math.random() * (n + 1))], 12319 t[i] = t[n], 12320 t[n] = e; 12321 return t 12322 }, 12323 reset: function() { 12324 clearInterval(this.timeout); 12325 var t = this.el.attr("id"); 12326 this.el.after('<span id="' + t + '"/>'), 12327 this.el.remove(), 12328 void 0 !== this.cursor && this.cursor.remove(), 12329 this.options.resetCallback() 12330 } 12331 }, 12332 s.fn.typed = function(n) { 12333 return this.each(function() { 12334 var t = s(this) 12335 , e = t.data("typed") 12336 , i = "object" == typeof n && n; 12337 e || t.data("typed", e = new o(this,i)), 12338 "string" == typeof n && e[n]() 12339 }) 12340 } 12341 , 12342 s.fn.typed.defaults = { 12343 strings: ["These are the default values...", "You know what you should do?", "Use your own!", "Have a great day!"], 12344 stringsElement: null, 12345 typeSpeed: 0, 12346 startDelay: 0, 12347 backSpeed: 0, 12348 shuffle: !1, 12349 backDelay: 500, 12350 loop: !1, 12351 loopCount: !1, 12352 showCursor: !0, 12353 cursorChar: "|", 12354 attr: null, 12355 contentType: "html", 12356 callback: function() {}, 12357 preStringTyped: function() {}, 12358 onStringTyped: function() {}, 12359 resetCallback: function() {} 12360 } 12361}(window.jQuery), 12362function(r) { 12363 function e(t, e, i, n) { 12364 var s = t.text().split(e) 12365 , o = ""; 12366 s.length && (r(s).each(function(t, e) { 12367 o += '<span class="' + i + (t + 1) + '">' + e + "</span>" + n 12368 }), 12369 t.empty().append(o)) 12370 } 12371 var i = { 12372 init: function() { 12373 return this.each(function() { 12374 e(r(this), "", "char", "") 12375 }) 12376 }, 12377 words: function() { 12378 return this.each(function() {
12379 e(r(this), " ", "word", " ") 12380 }) 12381 }, 12382 lines: function() { 12383 return this.each(function() { 12384 var t = "eefec303079ad17405c889e092e105b0"; 12385 e(r(this).children("br").replaceWith(t).end(), t, "line", "") 12386 }) 12387 } 12388 }; 12389 r.fn.lettering = function(t) { 12390 return t && i[t] ? i[t].apply(this, [].slice.call(arguments, 1)) : "letters" !== t && t ? (r.error("Method " + t + " does not exist on jQuery.lettering"), 12391 this) : i.init.apply(this, [].slice.call(arguments, 0)) 12392 } 12393}(jQuery), 12394function(l) { 12395 "use strict"; 12396 function c(t) { 12397 return /In/.test(t) || 0 <= l.inArray(t, l.fn.textillate.defaults.inEffects) 12398 } 12399 function u(t) { 12400 return /Out/.test(t) || 0 <= l.inArray(t, l.fn.textillate.defaults.outEffects) 12401 } 12402 function s(t) { 12403 return "true" !== t && "false" !== t ? t : "true" === t 12404 } 12405 function r(t) { 12406 var e = t.attributes || [] 12407 , n = {}; 12408 return e.length && l.each(e, function(t, e) { 12409 var i = e.nodeName.replace(/delayscale/, "delayScale"); 12410 /^data-in-*/.test(i) ? (n.in = n.in || {}, 12411 n.in[i.replace(/data-in-/, "")] = s(e.nodeValue)) : /^data-out-*/.test(i) ? (n.out = n.out || {}, 12412 n.out[i.replace(/data-out-/, "")] = s(e.nodeValue)) : /^data-*/.test(i) && (n[i.replace(/data-/, "")] = s(e.nodeValue)) 12413 }), 12414 n 12415 } 12416 function a(t, o, r) { 12417 var a = t.length; 12418 a ? (o.shuffle && (t = function(t) { 12419 for (var e, i, n = t.length; n; e = parseInt(Math.random() * n), 12420 i = t[--n], 12421 t[n] = t[e], 12422 t[e] = i) 12423 ; 12424 return t 12425 }(t)), 12426 o.reverse && (t = t.toArray().reverse()), 12427 l.each(t, function(t, e) { 12428 function n() { 12429 c(o.effect) ? s.css("visibility", "visible") : u(o.effect) && s.css("visibility", "hidden"), 12430 !(a -= 1) && r && r() 12431 } 12432 var s = l(e) 12433 , i = o.sync ? o.delay : o.delay * t * o.delayScale; 12434 s.text() ? setTimeout(function() { 12435 var t, e, i; 12436 t = s, 12437 e = o.effect, 12438 i = n, 12439 t.addClass("animated " + e).css("visibility", "visible").show(), 12440 t.one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", function() { 12441 t.removeClass("animated " + e), 12442 i && i() 12443 }) 12444 }, i) : n() 12445 })) : r && r() 12446 } 12447 l.fn.textillate = function(n, s) { 12448 return this.each(function() { 12449 var t = l(this) 12450 , e = t.data("textillate") 12451 , i = l.extend(!0, {}, l.fn.textillate.defaults, r(this), "object" == typeof n && n); 12452 e ? "string" == typeof n ? e[n].apply(e, [].concat(s)) : e.setOptions.call(e, i) : t.data("textillate", e = new function(t, e) { 12453 var o = this 12454 , i = l(t); 12455 o.init = function() { 12456 o.$texts = i.find(e.selector), 12457 o.$texts.length || (o.$texts = l('<ul class="texts"><li>' + i.html() + "</li></ul>"), 12458 i.html(o.$texts)), 12459 o.$texts.hide(), 12460 o.$current = l("<span>").html(o.$texts.find(":first-child").html()).prependTo(i), 12461 c(e.in.effect) ? o.$current.css("visibility", "hidden") : u(e.out.effect) && o.$current.css("visibility", "visible"), 12462 o.setOptions(e), 12463 o.timeoutRun = null, 12464 setTimeout(function() { 12465 o.options.autoStart && o.start() 12466 }, o.options.initialDelay) 12467 } 12468 , 12469 o.setOptions = function(t) { 12470 o.options = t 12471 } 12472 , 12473 o.triggerEvent = function(t) { 12474 var e = l.Event(t + ".tlt"); 12475 return i.trigger(e, o), 12476 e 12477 } 12478 , 12479 o.in = function(t, e) { 12480 t = t || 0; 12481 var i, n = o.$texts.find(":nth-child(" + ((t || 0) + 1) + ")"), s = l.extend(!0, {}, o.options, n.length ? r(n[0]) : {}); 12482 n.addClass("current"), 12483 o.triggerEvent("inAnimationBegin"), 12484 o.$current.html(n.html()).lettering("words"), 12485 "char" == o.options.type && o.$current.find('[class^="word"]').css({ 12486 display: "inline-block", 12487 "-webkit-transform": "translate3d(0,0,0)", 12488 "-moz-transform": "translate3d(0,0,0)",
12489 "-o-transform": "translate3d(0,0,0)", 12490 transform: "translate3d(0,0,0)" 12491 }).each(function() { 12492 l(this).lettering() 12493 }), 12494 i = o.$current.find('[class^="' + o.options.type + '"]').css("display", "inline-block"), 12495 c(s.in.effect) ? i.css("visibility", "hidden") : u(s.in.effect) && i.css("visibility", "visible"), 12496 o.currentIndex = t, 12497 a(i, s.in, function() { 12498 o.triggerEvent("inAnimationEnd"), 12499 s.in.callback && s.in.callback(), 12500 e && e(o) 12501 }) 12502 } 12503 , 12504 o.out = function(t) { 12505 var e = o.$texts.find(":nth-child(" + ((o.currentIndex || 0) + 1) + ")") 12506 , i = o.$current.find('[class^="' + o.options.type + '"]') 12507 , n = l.extend(!0, {}, o.options, e.length ? r(e[0]) : {}); 12508 o.triggerEvent("outAnimationBegin"), 12509 a(i, n.out, function() { 12510 e.removeClass("current"), 12511 o.triggerEvent("outAnimationEnd"), 12512 n.out.callback && n.out.callback(), 12513 t && t(o) 12514 }) 12515 } 12516 , 12517 o.start = function(t) { 12518 setTimeout(function() { 12519 o.triggerEvent("start"), 12520 function e(i) { 12521 o.in(i, function() { 12522 var t = o.$texts.children().length; 12523 i += 1, 12524 !o.options.loop && t <= i ? (o.options.callback && o.options.callback(), 12525 o.triggerEvent("end")) : (i %= t, 12526 o.timeoutRun = setTimeout(function() { 12527 o.out(function() { 12528 e(i) 12529 }) 12530 }, o.options.minDisplayTime)) 12531 }) 12532 }(t || 0) 12533 }, o.options.initialDelay) 12534 } 12535 , 12536 o.stop = function() { 12537 o.timeoutRun && (clearInterval(o.timeoutRun), 12538 o.timeoutRun = null) 12539 } 12540 , 12541 o.init() 12542 } 12543 (this,i)) 12544 }) 12545 } 12546 , 12547 l.fn.textillate.defaults = { 12548 selector: ".texts", 12549 loop: !1, 12550 minDisplayTime: 2e3, 12551 initialDelay: 0, 12552 in: { 12553 effect: "fadeInLeftBig", 12554 delayScale: 1.5, 12555 delay: 50, 12556 sync: !1, 12557 reverse: !1, 12558 shuffle: !1, 12559 callback: function() {} 12560 }, 12561 out: { 12562 effect: "hinge", 12563 delayScale: 1.5, 12564 delay: 50, 12565 sync: !1, 12566 reverse: !1, 12567 shuffle: !1, 12568 callback: function() {} 12569 }, 12570 autoStart: !0, 12571 inEffects: [], 12572 outEffects: ["hinge"], 12573 callback: function() {}, 12574 type: "char" 12575 } 12576}(jQuery); 12577var headeroverlay = !1 12578 , headerheight = jQuery("header").height(); 12579jQuery(window).load(function() { 12580 jQuery(".header-overlay").length < 1 ? (jQuery("body").append('<div id="pseudo-header"></div>'), 12581 jQuery("#pseudo-header").css({ 12582 height: headerheight + "px", 12583 position: "absolute", 12584 top: 0, 12585 left: 0, 12586 opacity: 0 12587 }), 12588 0 < jQuery(".fixed-header").length && jQuery(".page-body").css({ 12589 "margin-top": headerheight + "px" 12590 })) : headeroverlay = !0, 12591 sizeDownHeader() 12592}), 12593jQuery(window).scroll(function() { 12594 sizeDownHeader() 12595}), 12596jQuery(window).resize(function() { 12597 headerheight = jQuery("header").height(), 12598 jQuery(".fixed-header nav#main-nav").fadeIn(0), 12599 jQuery(".header-overlay").length < 1 && jQuery(window).width() < 1023 && jQuery(".wasOverlay").length < 1 && (jQuery("#pseudo-header").css({ 12600 height: headerheight + "px", 12601 position: "absolute", 12602 top: 0, 12603 left: 0, 12604 opacity: 0 12605 }), 12606 0 < jQuery(".fixed-header").length && jQuery(".page-body").css({ 12607 "margin-top": headerheight + "px" 12608 })), 12609 sizeDownHeader() 12610}), 12611jQuery(window).load(function($) { 12612 function loadcontent(url, type, id, slug, activeProject, ajaxSection) { 12613 var scrolltop = jQuery("header").height() - 1; 12614 jQuery.ajax({ 12615 type: "POST", 12616 url: srvars.ajaxurl, 12617 data: { 12618 action: "sr_get_content", 12619 id: id, 12620 type: type 12621 }, 12622 success: function(response, status) { 12623 jQuery(ajaxSection + " .ajax-content").html(response), 12624 jQuery(ajaxSection + " .ajax-content").css({ 12625 opacity: 1 12626 }), 12627 jQuery(ajaxSection + " .ajax-content").find("script").each(function(i) { 12628 eval(jQuery(this).html()) 12629 }), 12630 "success" == status && (activeProject ? (jQuery(ajaxSection + " #ajax-loader").css({ 12631 top: "70px" 12632 }), 12633 jQuery(ajaxSection + " #ajax-loader").delay(1e3).fadeOut(500, function() { 12634 jQuery().fitVids && jQuery(ajaxSection).fitVids(), 12635 portfolioPreviewHide(), 12636 jQuery(ajaxSection + " .ajax-content").fadeIn(400, "easeOutQuart", function() { 12637 jQuery(ajaxSection + " .ajax-content").find(".jp-interface").each(function() { 12638 var t = jQuery(this).width() - 175; 12639 jQuery(this).find(".jp-progress-container").css({ 12640 width: t + "px" 12641 }) 12642 }), 12643 flexInit(ajaxSection), 12644 setTimeout(portfolioShow, 600), 12645 jQuery(ajaxSection).animate({ 12646 "min-height": "0" 12647 }, 700, "easeOutQuart") 12648 }) 12649 })) : jQuery(ajaxSection + " #ajax-loader").delay(1e3).fadeOut(500, function() { 12650 jQuery().fitVids && jQuery(ajaxSection).fitVids(), 12651 portfolioPreviewHide(), 12652 jQuery(ajaxSection + " .ajax-content").slideDown(700, "easeInQuart", function() { 12653 jQuery(ajaxSection + " .ajax-content").find(".jp-interface").each(function() { 12654 var t = jQuery(this).width() - 175; 12655 jQuery(this).find(".jp-progress-container").css({ 12656 width: t + "px" 12657 }) 12658 }), 12659 flexInit(ajaxSection), 12660 setTimeout(portfolioShow, 600) 12661 }) 12662 })) 12663 } 12664 }) 12665 } 12666 jQuery("body").on("click", "a.load-content", function() { 12667 var t = jQuery("header").height() - 1 12668 , e = jQuery(this).attr("href") 12669 , i = jQuery(this).data("type") 12670 , n = jQuery(this).data("id") 12671 , s = jQuery(this).data("slug") 12672 , o = jQuery(this).closest(".portfolio-entries").data("ajax"); 12673 o = o ? "#" + o : "#" + jQuery(this).closest(".ajax-section").attr("id"); 12674 var r = jQuery(o).css("display"); 12675 if (r = "block" == r) 12676 if (r == e) 12677 jQuery("html,body").animate({ 12678 scrollTop: jQuery(o).offset().top - t 12679 }, 700, "easeOutQuart"); 12680 else { 12681 a = 0; 12682 jQuery("html,body").animate({ 12683 scrollTop: jQuery(o).offset().top - t 12684 }, 500, "easeOutQuart", function() { 12685 if (0 == a) { 12686 var t = jQuery(o).height(); 12687 jQuery(o).css({ 12688 "min-height": t + "px" 12689 }), 12690 jQuery(o + " .close-project").fadeOut(500), 12691 jQuery(o + " #portfolio-single .project-title").animate({ 12692 top: "-60px" 12693 }, 600, "easeOutQuart"), 12694 jQuery(o + " #portfolio-single .social-share li").animate({ 12695 top: "-30px" 12696 }, 600, "easeOutQuart"), 12697 jQuery(o + " #portfolio-single .entry-media").animate({ 12698 top: "60px" 12699 }, 600, "easeOutQuart"), 12700 jQuery(o + " #portfolio-single .entry-content").animate({ 12701 top: "60px" 12702 }, 600, "easeOutQuart"), 12703 jQuery(o + " .ajax-content").fadeOut(600, function() { 12704 jQuery(o + " #ajax-loader").fadeIn(500), 12705 loadcontent(e, i, n, s, r, o) 12706 }) 12707 } 12708 a++ 12709 }) 12710 } 12711 else { 12712 jQuery(o).slideDown(500); 12713 var a = 0; 12714 jQuery("html,body").animate({ 12715 scrollTop: jQuery(o).offset().top - t 12716 }, 700, "easeOutQuart", function() { 12717 0 == a && (jQuery(o + " #ajax-loader").fadeIn(500), 12718 loadcontent(e, i, n, s, r, o)), 12719 a++ 12720 }) 12721 } 12722 return !1 12723 }), 12724 jQuery(".ajax-content").on("click", ".close-project a", function() { 12725 jQuery(this).attr("href"); 12726 var t = jQuery(this).parents("section").attr("id") 12727 , e = jQuery("header").height() - 1; 12728 return jQuery(".close-project").fadeOut(500), 12729 jQuery(".ajax-content").animate({ 12730 opacity: 0 12731 }, 500, function() { 12732 jQuery(this).slideUp(700, "easeOutQuart", function() {}),
12733 jQuery(".ajax-section").slideUp(700, function() { 12734 jQuery(".ajax-content").html("") 12735 }), 12736 jQuery("html,body").animate({ 12737 scrollTop: jQuery("#" + t).offset().top - e 12738 }, 700, "easeOutQuart") 12739 }), 12740 !1 12741 }) 12742}), 12743jQuery(window).load(function() { 12744 jQuery("body").on("click", 'input[type="submit"]', function() { 12745 if ($form = jQuery(this).parents("form"), 12746 form_action = $form.attr("target"), 12747 form_class = $form.attr("class"), 12748 id = $form.attr("id"), 12749 "checkform" == form_class) { 12750 var e = !0; 12751 if ($form.find("label.req").each(function() { 12752 var t = jQuery(this).attr("for"); 12753 if (defaultvalue = jQuery(this).html(), 12754 value = $form.find("." + t).val(), 12755 formtype = $form.find("." + t).attr("type"), 12756 "radio" == formtype || "checkbox" == formtype) 12757 0 == jQuery("." + t + ":checked").length ? (jQuery(this).siblings("div").find(".checkfalse").fadeIn(200), 12758 e = !1) : jQuery(this).siblings("div").find(".checkfalse").fadeOut(200); 12759 else if ("email" == t) { 12760 value.match(/^[\w-]+(\.[\w-]+)*@([\w-]+\.)+[a-zA-Z]{2,7}$/) ? $form.find("." + t).removeClass("false") : ($form.find("." + t).addClass("false"), 12761 e = !1) 12762 } else 12763 "" == value || value == defaultvalue ? ($form.find("." + t).addClass("false"), 12764 e = !1) : $form.find("." + t).removeClass("false") 12765 }), 12766 e) { 12767 if ($form.find("#form-note").fadeOut(200), 12768 form_action && "" !== form_action) { 12769 var t = $form.serialize(); 12770 return jQuery.ajax({ 12771 type: "POST", 12772 url: form_action, 12773 data: t, 12774 success: function(t) { 12775 $form.find("#form-note").html(t), 12776 $form.find("#form-note").delay(200).fadeIn(200) 12777 } 12778 }), 12779 !1 12780 } 12781 return !0 12782 } 12783 return $form.find("#form-note").fadeIn(200), 12784 !1 12785 } 12786 }) 12787}), 12788function(e, n) { 12789 n.App = { 12790 Models: {}, 12791 Collections: {}, 12792 Views: {} 12793 }, 12794 n.template = function(t) { 12795 return _.template(e("#" + t).html()) 12796 } 12797 , 12798 n.storage = function() { 12799 var t, e, i = new Date; 12800 try { 12801 return (t = n.localStorage).setItem(i, i), 12802 e = t.getItem(i) == i, 12803 t.removeItem(i), 12804 e && t 12805 } catch (t) {} 12806 }() 12807}(jQuery, this), 12808App.Models.Video = Backbone.Model.extend({ 12809 defaults: { 12810 title: "", 12811 image: "", 12812 date: "", 12813 youtubeId: "" 12814 } 12815}), 12816App.Models.SocialItem = Backbone.Model.extend({ 12817 defaults: {} 12818}), 12819App.Models.Playlist = Backbone.Model.extend({ 12820 defaults: { 12821 title: "", 12822 url: "", 12823 videos: null 12824 }, 12825 initialize: function() { 12826 console.log("[Playlist] intialize") 12827 }, 12828 loadVideos: function(t) { 12829 this.get("videos") && (t.url = srvars.ajaxurl + "?action=tcc_load_videos&playlist_id=" + this.get("id"), 12830 this.get("videos").fetch(t || {})) 12831 }, 12832 clear: function() { 12833 this.get("videos").reset(), 12834 this.destroy() 12835 } 12836}), 12837function(s) { 12838 App.Collections.Videos = Backbone.Collection.extend({ 12839 model: App.Models.Video, 12840 initialize: function(t, e) { 12841 var i = e || {}; 12842 this.url = i.url 12843 }, 12844 parse: function(t) { 12845 return t.videos 12846 }, 12847 sync: function(t, e, i) { 12848 var n = _.extend({ 12849 type: "GET", 12850 url: this.url, 12851 processData: !1 12852 }, i); 12853 return s.ajax(n) 12854 } 12855 }) 12856}(jQuery), 12857function(e) { 12858 App.Views.TabsView = Backbone.View.extend({ 12859 events: { 12860 "click .js-tab": "changeTab" 12861 }, 12862 initialize: function(t) { 12863 if (console.log("[TabsView] initialization"), 12864 this.setElement(t[0]), 12865 this.$el.data("active-tab")) { 12866 var e = this.$el.data("active-tab"); 12867 this.$(".tab-" + e + ",.tab--" + e).addClass("active") 12868 } else 12869 this.$(".tab--control:first, .tab:first").addClass("active"); 12870 this.render() 12871 }, 12872 render: function() { 12873 return this.$("#socialTab").each(function() { 12874 new App.Views.SocialNewsView 12875 }), 12876 this 12877 }, 12878 changeTab: function(t) { 12879 t.preventDefault(), 12880 this.openTab(e(t.target).parents("a")) 12881 }, 12882 openTab: function(t) { 12883 var e = t.attr("href"); 12884 return this.$(".tab--control, .tabs--area .tab").removeClass("active"), 12885 this.$(".tab--" + t.data("name")).addClass("active"), 12886 t.addClass("active"), 12887 /^#/.test(e) || history.pushState(null, null, e), 12888 app.events.trigger("TabsView.tabChanged", t.data("name")), 12889 this 12890 } 12891 }) 12892}(jQuery, window, document), 12893function(n, s, o) { 12894 App.Views.Player = Backbone.View.extend({ 12895 el: "#player", 12896 currentVideo: null, 12897 currentPlaylist: null, 12898 currentVideoTemplate: null, 12899 navTemplate: null, 12900 events: { 12901 "click .currently-playing .label": "browse", 12902 "click .js-playlist": "loadPlaylist", 12903 "click .js-play-video": "play" 12904 }, 12905 initialize: function(t) { 12906 console.log("[App.Views.Player] initialize"); 12907 var e = this; 12908 this.options = t || {},
12909 this.fragment = o.createDocumentFragment(), 12910 this.currentVideoTemplate = template("playerVideoTemplate"), 12911 this.navTemplate = template("playerNavTemplate"); 12912 var i = this.$(".js-playlist:first"); 12913 this.currentPlaylist = new App.Models.Playlist({ 12914 id: i.data("youtube"), 12915 title: i.find(".title").text(), 12916 videos: new App.Collections.Videos 12917 }), 12918 this.currentPlaylist.loadVideos({ 12919 success: function() { 12920 var t = e.currentPlaylist.get("videos"); 12921 DefaultVideo && t.add(new App.Models.Video(DefaultVideo), { 12922 at: 0 12923 }), 12924 e.loadVideo(t.first()), 12925 e.currentPlaylist.trigger("loaded") 12926 }, 12927 error: function() { 12928 console.log("Failed to fetch!") 12929 } 12930 }), 12931 this.tabsView = new App.Views.TabsView(this.$(".tabs")), 12932 imagesLoaded(e.$(".tab--playlists")[0]).on("always", function() { 12933 e.updateScroll(e.$(".tab--playlists")) 12934 }), 12935 this.listenTo(app.events, "TabsView.tabChanged", this.dummy), 12936 this.listenTo(app.events, "Player.loadPlaylist", this.loadPlaylist), 12937 this.listenTo(app.events, "Player.addVideo", this.addVideo), 12938 this.listenTo(app.events, "Player.next", this.next), 12939 this.listenTo(this, "videoChanged", this.render), 12940 this.listenTo(this.currentPlaylist, "loaded", _.debounce(this.renderPlaylist, 1)) 12941 }, 12942 addVideo: function(t) { 12943 var e = n(t.currentTarget).closest(".vd") 12944 , i = new App.Models.Video({ 12945 title: e.data("title"), 12946 image: e.find(".video--image").attr("src"), 12947 date: "", 12948 youtubeId: e.data("youtube") 12949 }); 12950 console.log("[App.Views.Player] addVideo", e.data()), 12951 this.currentPlaylist.get("videos").add(i, { 12952 at: 0 12953 }), 12954 this.currentVideo = i, 12955 this.tabsView.openTab(this.$(".tab-now-playing")), 12956 this.trigger("videoChanged") 12957 }, 12958 loadVideo: function(t) { 12959 console.log("[App.Views.Player] loadVideo", t.get("youtubeId"), t.get("title")), 12960 this.currentVideo = t, 12961 this.trigger("videoChanged") 12962 }, 12963 render: function() { 12964 this.renderNav(); 12965 var t = this 12966 , e = n(s).height() - 40; 12967 return e -= this.$(".tv--footer").height(), 12968 e -= 2 * this.$(".tabs--control").height(), 12969 e -= n("#header").height(), 12970 t.$(".current-video").css({}).html(t.currentVideoTemplate(t.currentVideo.toJSON())).removeClass("hidden").fitVids(), 12971 this.player && this.player.destroy(), 12972 setTimeout(function() { 12973 t.player = new YT.Player("youtube",{ 12974 events: { 12975 onReady: t.onPlayerReady, 12976 onStateChange: t.onPlayerStateChange, 12977 onError: t.onPlayerError 12978 } 12979 }) 12980 }, 1), 12981 this.$(".articles-inner").css({ 12982 maxHeight: e 12983 }), 12984 imagesLoaded(this.$el).on("always", function() { 12985 app.events.trigger("Player.loaded", !0) 12986 }), 12987 this 12988 }, 12989 renderPlaylist: function() { 12990 console.log("[Player.renderPlaylist]"); 12991 var t = this; 12992 return this.$(".current-playlist").html(template("playerVideosTemplate")({ 12993 playlist: this.currentPlaylist.toJSON() 12994 })), 12995 imagesLoaded(t.$(".current-playlist")[0]).on("always", function() { 12996 t.updateScroll(t.$(".current-playlist")) 12997 }), 12998 this 12999 }, 13000 renderNav: function() { 13001 var t = this.currentPlaylist.get("videos") 13002 , e = t.indexOf(this.currentVideo); 13003 return this.$(".navbar").html(this.navTemplate({ 13004 playlist: this.currentPlaylist.toJSON(), 13005 current: this.currentVideo.toJSON(), 13006 next: t.at(e + 1) ? t.at(e + 1).toJSON() : null 13007 })), 13008 this 13009 }, 13010 updateScroll: function(t) { 13011 var e = parseInt(n("html").css("fontSize")); 13012 t.find(".scrollbar").each(function() { 13013 n(this).data("ps-id") ? n(this).perfectScrollbar("update") : n(this).perfectScrollbar({ 13014 suppressScrollX: !0, 13015 minScrollbarLength: 3.5 * e, 13016 maxScrollbarLength: 3.5 * e 13017 }) 13018 }) 13019 }, 13020 subscribe: function() { 13021 s.AEJSWP && AEJSWP.aeJS.trigger.flow() 13022 }, 13023 browse: function() { 13024 var t = this; 13025 n("html, body").animate({ 13026 scrollTop: this.$el.offset().top - n("#header").height() - 50 13027 }, 1e3, "easeInOutQuart", function() { 13028 t.tabsView.openTab(t.$(".tab-play-queue")) 13029 }) 13030 }, 13031 play: function(t) { 13032 var e = n(t.currentTarget) 13033 , i = this.currentPlaylist.get("videos").find(function(t) { 13034 return t.get("youtubeId") === e.data("youtube") 13035 }); 13036 t.preventDefault(), 13037 this.loadVideo(i), 13038 this.tabsView.openTab(this.$(".tab-now-playing")) 13039 }, 13040 next: function() { 13041 var t = this 13042 , e = this.currentPlaylist.get("videos") 13043 , i = e.indexOf(this.currentVideo) 13044 , n = e.at(i + 1) ? e.at(i + 1) : null; 13045 n && (s.autoplay = !0, 13046 this.$("#youtube").removeClass("animated fadeInRight").addClass("animated fadeOutLeft"), 13047 setTimeout(function() { 13048 t.loadVideo(n) 13049 }, 1e3)) 13050 }, 13051 loadPlaylist: function(t) { 13052 var e = this 13053 , i = n(t.currentTarget); 13054 t.preventDefault(), 13055 console.log("[PlayerView] loadPlaylist", i.data()), 13056 this.currentPlaylist.get("videos").reset(), 13057 this.currentPlaylist.set({ 13058 id: i.data("youtube"), 13059 title: i.data("title") 13060 }), 13061 this.currentPlaylist.loadVideos({ 13062 success: function() { 13063 e.loadVideo(e.currentPlaylist.get("videos").first()), 13064 e.currentPlaylist.trigger("loaded"), 13065 e.tabsView.openTab(e.$(".tab-play-queue")) 13066 }, 13067 error: function() { 13068 console.log("Failed to fetch!") 13069 } 13070 }) 13071 }, 13072 dummy: function(t) { 13073 this.$(".tab--" + t + " .scrollbar").perfectScrollbar("update") 13074 }, 13075 onPlayerReady: function(t) { 13076 Modernizr.touch || !s.autoplay && !n("body").hasClass("tv") || t.target.playVideo(), 13077 app.events.trigger("Player.ready", t) 13078 }, 13079 onPlayerStateChange: function(t) { 13080 switch (t.data) { 13081 case YT.PlayerState.ENDED: 13082 app.events.trigger("Player.next", t) 13083 } 13084 }, 13085 onPlayerError: function(t) { 13086 console.log("onPlayerError", t) 13087 } 13088 }) 13089}(jQuery, window, document), 13090function(t) { 13091 App.Views.HeaderView = Backbone.View.extend({ 13092 el: "#header", 13093 events: { 13094 "click .audio a": "toggleAudioPlayer" 13095 }, 13096 initialize: function() { 13097 this.$player = t("#audioPlayer") 13098 }, 13099 render: function() {}, 13100 toggleAudioPlayer: function() { 13101 this.$player.toggleClass("closed") 13102 } 13103 }) 13104}(jQuery, window, document), 13105function(c, e) { 13106 App.Views.BodyView = Backbone.View.extend({ 13107 el: "body", 13108 initialize: function() { 13109 var t = this; 13110 this.subviews = {}, 13111 this.listenTo(app.events, "Player.loaded", function() {}), 13112 this.listenTo(app.events, "Skrollr", function(t) { 13113 if (void 0 !== t) 13114 switch (t) { 13115 case "reset": 13116 this.resetSkrollr() 13117 } 13118 }), 13119 0 < this.$("#player").length && (this.subviews.player = new App.Views.Player), 13120 0 < this.$("#social-grid").length && (this.subviews.social = new App.Views.SocialNewsView), 13121 c(e).load(function() { 13122 setTimeout(function() { 13123 t.homeAnimation().initSkrollr() 13124 }, 100) 13125 }), 13126 this.render() 13127 }, 13128 render: function() { 13129 var a = 0 <= navigator.platform.toUpperCase().indexOf("MAC") 13130 , l = !(null == e.mozInnerScreenX);
13131 this.$("#page-content").prepend(c('<div class="page-bg-img"></div>')), 13132 this.$("#page-content").prepend(c('<div class="page-bg"></div>')), 13133 this.$(".logomask").each(function() { 13134 var t = c(this) 13135 , e = Snap(".logomask .mask") 13136 , i = e.rect(0, 0, t.width(), t.height()).addClass("mask__bg") 13137 , n = e.rect(0, 0, t.width(), t.height()).attr({ 13138 fill: "#fff", 13139 fillOpacity: .95 13140 }) 13141 , s = a && l ? Math.min(1.36 * t.height(), 256) : 1.36 * t.height() 13142 , o = e.text("50%", "50%", "DUALIPA").attr({ 13143 fontSize: 768 < wwidth ? s : "10em", 13144 fill: "#000", 13145 dy: ".366em" 13146 }) 13147 , r = e.g(n, o); 13148 i.attr({ 13149 mask: r 13150 }) 13151 }) 13152 }, 13153 initSkrollr: function() { 13154 this.skrollr = skrollr.init({ 13155 smoothScrolling: !0, 13156 forceHeight: !1, 13157 mobileCheck: function() { 13158 return !1 13159 } 13160 }) 13161 }, 13162 resetSkrollr: function() { 13163 this.skrollr && (console.log("[resetSkrollr]"), 13164 this.skrollr.destroy(), 13165 this.initSkrollr()) 13166 }, 13167 setSkrollr: function(t, e) { 13168 for (var i = 0, n = e.length; i < n; i++) { 13169 var s = e[i] 13170 , o = s[0]; 13171 css = s[1], 13172 c(t).attr("data-" + o, css) 13173 } 13174 }, 13175 homeAnimation: function() { 13176 return this.setSkrollr(c(".page-bg-img"), [[0, "bottom:0px;"], ["220-end", "bottom:0px;"], ["end", "bottom:-220px;"]]), 13177 this.$el.hasClass("home") && (this.setSkrollr(c("#section-promo .title"), [[0, "transform[quadratic]:translateX(0%);opacity:1;"], ["-50p-top-bottom", "transform[quadratic]:translateX(100%);opacity:0;"]]), 13178 this.setSkrollr(c("#section-promo .extra"), [[0, "transform[quadratic]:translateX(0%);opacity:1;"], ["-50p-top-bottom", "transform[quadratic]:translateX(-100%);opacity:0;"]]), 13179 this.setSkrollr(c(".bottom-strip"), [[0, "opacity:1;"], ["center", "opacity:0;"]])), 13180 this 13181 } 13182 }) 13183}(jQuery, window, document), 13184function(t) { 13185 "use strict"; 13186 "function" == typeof define && define.amd ? define(["jquery"], t) : "undefined" != typeof exports ? module.exports = t(require("jquery")) : t(jQuery) 13187}(function(u) { 13188 "use strict"; 13189 var s, r = window.Slick || {}; 13190 s = 0, 13191 (r = function(t, e) { 13192 var i, n = this; 13193 n.defaults = { 13194 accessibility: !0, 13195 adaptiveHeight: !1, 13196 appendArrows: u(t), 13197 appendDots: u(t), 13198 arrows: !0, 13199 asNavFor: null, 13200 prevArrow: '<button class="slick-prev" aria-label="Previous" type="button">Previous</button>', 13201 nextArrow: '<button class="slick-next" aria-label="Next" type="button">Next</button>', 13202 autoplay: !1, 13203 autoplaySpeed: 3e3, 13204 centerMode: !1, 13205 centerPadding: "50px", 13206 cssEase: "ease", 13207 customPaging: function(t, e) { 13208 return u('<button type="button" />').text(e + 1) 13209 }, 13210 dots: !1, 13211 dotsClass: "slick-dots", 13212 draggable: !0, 13213 easing: "linear", 13214 edgeFriction: .35, 13215 fade: !1, 13216 focusOnSelect: !1, 13217 focusOnChange: !1, 13218 infinite: !0, 13219 initialSlide: 0, 13220 lazyLoad: "ondemand", 13221 mobileFirst: !1, 13222 pauseOnHover: !0, 13223 pauseOnFocus: !0, 13224 pauseOnDotsHover: !1, 13225 respondTo: "window", 13226 responsive: null, 13227 rows: 1, 13228 rtl: !1, 13229 slide: "", 13230 slidesPerRow: 1, 13231 slidesToShow: 1, 13232 slidesToScroll: 1, 13233 speed: 500, 13234 swipe: !0, 13235 swipeToSlide: !1, 13236 touchMove: !0, 13237 touchThreshold: 5, 13238 useCSS: !0, 13239 useTransform: !0, 13240 variableWidth: !1, 13241 vertical: !1, 13242 verticalSwiping: !1, 13243 waitForAnimate: !0, 13244 zIndex: 1e3 13245 }, 13246 n.initials = { 13247 animating: !1, 13248 dragging: !1, 13249 autoPlayTimer: null, 13250 currentDirection: 0, 13251 currentLeft: null, 13252 currentSlide: 0, 13253 direction: 1, 13254 $dots: null, 13255 listWidth: null, 13256 listHeight: null, 13257 loadIndex: 0, 13258 $nextArrow: null, 13259 $prevArrow: null, 13260 scrolling: !1, 13261 slideCount: null, 13262 slideWidth: null, 13263 $slideTrack: null, 13264 $slides: null, 13265 sliding: !1, 13266 slideOffset: 0, 13267 swipeLeft: null, 13268 swiping: !1, 13269 $list: null, 13270 touchObject: {}, 13271 transformsEnabled: !1, 13272 unslicked: !1 13273 }, 13274 u.extend(n, n.initials), 13275 n.activeBreakpoint = null, 13276 n.animType = null, 13277 n.animProp = null, 13278 n.breakpoints = [], 13279 n.breakpointSettings = [], 13280 n.cssTransitions = !1, 13281 n.focussed = !1, 13282 n.interrupted = !1, 13283 n.hidden = "hidden", 13284 n.paused = !0, 13285 n.positionProp = null, 13286 n.respondTo = null, 13287 n.rowCount = 1, 13288 n.shouldClick = !0, 13289 n.$slider = u(t), 13290 n.$slidesCache = null, 13291 n.transformType = null, 13292 n.transitionType = null, 13293 n.visibilityChange = "visibilitychange", 13294 n.windowWidth = 0, 13295 n.windowTimer = null, 13296 i = u(t).data("slick") || {}, 13297 n.options = u.extend({}, n.defaults, e, i), 13298 n.currentSlide = n.options.initialSlide, 13299 n.originalSettings = n.options, 13300 void 0 !== document.mozHidden ? (n.hidden = "mozHidden", 13301 n.visibilityChange = "mozvisibilitychange") : void 0 !== document.webkitHidden && (n.hidden = "webkitHidden", 13302 n.visibilityChange = "webkitvisibilitychange"), 13303 n.autoPlay = u.proxy(n.autoPlay, n), 13304 n.autoPlayClear = u.proxy(n.autoPlayClear, n), 13305 n.autoPlayIterator = u.proxy(n.autoPlayIterator, n), 13306 n.changeSlide = u.proxy(n.changeSlide, n), 13307 n.clickHandler = u.proxy(n.clickHandler, n), 13308 n.selectHandler = u.proxy(n.selectHandler, n), 13309 n.setPosition = u.proxy(n.setPosition, n), 13310 n.swipeHandler = u.proxy(n.swipeHandler, n), 13311 n.dragHandler = u.proxy(n.dragHandler, n), 13312 n.keyHandler = u.proxy(n.keyHandler, n), 13313 n.instanceUid = s++, 13314 n.htmlExpr = /^(?:\s*(<[\w\W]+>)[^>]*)$/, 13315 n.registerBreakpoints(), 13316 n.init(!0) 13317 } 13318 ).prototype.activateADA = function() { 13319 this.$slideTrack.find(".slick-active").attr({ 13320 "aria-hidden": "false" 13321 }).find("a, input, button, select").attr({ 13322 tabindex: "0" 13323 }) 13324 } 13325 , 13326 r.prototype.addSlide = r.prototype.slickAdd = function(t, e, i) { 13327 var n = this; 13328 if ("boolean" == typeof e) 13329 i = e, 13330 e = null; 13331 else if (e < 0 || e >= n.slideCount) 13332 return !1; 13333 n.unload(), 13334 "number" == typeof e ? 0 === e && 0 === n.$slides.length ? u(t).appendTo(n.$slideTrack) : i ? u(t).insertBefore(n.$slides.eq(e)) : u(t).insertAfter(n.$slides.eq(e)) : !0 === i ? u(t).prependTo(n.$slideTrack) : u(t).appendTo(n.$slideTrack), 13335 n.$slides = n.$slideTrack.children(this.options.slide), 13336 n.$slideTrack.children(this.options.slide).detach(), 13337 n.$slideTrack.append(n.$slides), 13338 n.$slides.each(function(t, e) { 13339 u(e).attr("data-slick-index", t) 13340 }), 13341 n.$slidesCache = n.$slides, 13342 n.reinit() 13343 } 13344 , 13345 r.prototype.animateHeight = function() { 13346 if (1 === this.options.slidesToShow && !0 === this.options.adaptiveHeight && !1 === this.options.vertical) { 13347 var t = this.$slides.eq(this.currentSlide).outerHeight(!0); 13348 this.$list.animate({ 13349 height: t 13350 }, this.options.speed) 13351 } 13352 } 13353 , 13354 r.prototype.animateSlide = function(t, e) { 13355 var i = {} 13356 , n = this; 13357 n.animateHeight(), 13358 !0 === n.options.rtl && !1 === n.options.vertical && (t = -t), 13359 !1 === n.transformsEnabled ? !1 === n.options.vertical ? n.$slideTrack.animate({ 13360 left: t 13361 }, n.options.speed, n.options.easing, e) : n.$slideTrack.animate({ 13362 top: t 13363 }, n.options.speed, n.options.easing, e) : !1 === n.cssTransitions ? (!0 === n.options.rtl && (n.currentLeft = -n.currentLeft), 13364 u({ 13365 animStart: n.currentLeft 13366 }).animate({ 13367 animStart: t 13368 }, {
vendor: 17,178 bytes, lines 13369-13749
13369 duration: n.options.speed, 13370 easing: n.options.easing, 13371 step: function(t) { 13372 t = Math.ceil(t), 13373 !1 === n.options.vertical ? i[n.animType] = "translate(" + t + "px, 0px)" : i[n.animType] = "translate(0px," + t + "px)", 13374 n.$slideTrack.css(i) 13375 }, 13376 complete: function() { 13377 e && e.call() 13378 } 13379 })) : (n.applyTransition(), 13380 t = Math.ceil(t), 13381 !1 === n.options.vertical ? i[n.animType] = "translate3d(" + t + "px, 0px, 0px)" : i[n.animType] = "translate3d(0px," + t + "px, 0px)", 13382 n.$slideTrack.css(i), 13383 e && setTimeout(function() { 13384 n.disableTransition(), 13385 e.call() 13386 }, n.options.speed)) 13387 } 13388 , 13389 r.prototype.getNavTarget = function() { 13390 var t = this.options.asNavFor; 13391 return t && null !== t && (t = u(t).not(this.$slider)), 13392 t 13393 } 13394 , 13395 r.prototype.asNavFor = function(e) { 13396 var t = this.getNavTarget(); 13397 null !== t && "object" == typeof t && t.each(function() { 13398 var t = u(this).slick("getSlick"); 13399 t.unslicked || t.slideHandler(e, !0) 13400 }) 13401 } 13402 , 13403 r.prototype.applyTransition = function(t) { 13404 var e = this 13405 , i = {}; 13406 !1 === e.options.fade ? i[e.transitionType] = e.transformType + " " + e.options.speed + "ms " + e.options.cssEase : i[e.transitionType] = "opacity " + e.options.speed + "ms " + e.options.cssEase, 13407 !1 === e.options.fade ? e.$slideTrack.css(i) : e.$slides.eq(t).css(i) 13408 } 13409 , 13410 r.prototype.autoPlay = function() { 13411 this.autoPlayClear(), 13412 this.slideCount > this.options.slidesToShow && (this.autoPlayTimer = setInterval(this.autoPlayIterator, this.options.autoplaySpeed)) 13413 } 13414 , 13415 r.prototype.autoPlayClear = function() { 13416 this.autoPlayTimer && clearInterval(this.autoPlayTimer) 13417 } 13418 , 13419 r.prototype.autoPlayIterator = function() { 13420 var t = this 13421 , e = t.currentSlide + t.options.slidesToScroll; 13422 t.paused || t.interrupted || t.focussed || (!1 === t.options.infinite && (1 === t.direction && t.currentSlide + 1 === t.slideCount - 1 ? t.direction = 0 : 0 === t.direction && (e = t.currentSlide - t.options.slidesToScroll, 13423 t.currentSlide - 1 == 0 && (t.direction = 1))), 13424 t.slideHandler(e)) 13425 } 13426 , 13427 r.prototype.buildArrows = function() { 13428 var t = this; 13429 !0 === t.options.arrows && (t.$prevArrow = u(t.options.prevArrow).addClass("slick-arrow"), 13430 t.$nextArrow = u(t.options.nextArrow).addClass("slick-arrow"), 13431 t.slideCount > t.options.slidesToShow ? (t.$prevArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"), 13432 t.$nextArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"), 13433 t.htmlExpr.test(t.options.prevArrow) && t.$prevArrow.prependTo(t.options.appendArrows), 13434 t.htmlExpr.test(t.options.nextArrow) && t.$nextArrow.appendTo(t.options.appendArrows), 13435 !0 !== t.options.infinite && t.$prevArrow.addClass("slick-disabled").attr("aria-disabled", "true")) : t.$prevArrow.add(t.$nextArrow).addClass("slick-hidden").attr({ 13436 "aria-disabled": "true", 13437 tabindex: "-1" 13438 })) 13439 } 13440 , 13441 r.prototype.buildDots = function() { 13442 var t, e, i = this; 13443 if (!0 === i.options.dots && i.slideCount > i.options.slidesToShow) { 13444 for (i.$slider.addClass("slick-dotted"), 13445 e = u("<ul />").addClass(i.options.dotsClass), 13446 t = 0; t <= i.getDotCount(); t += 1) 13447 e.append(u("<li />").append(i.options.customPaging.call(this, i, t))); 13448 i.$dots = e.appendTo(i.options.appendDots), 13449 i.$dots.find("li").first().addClass("slick-active") 13450 } 13451 } 13452 , 13453 r.prototype.buildOut = function() { 13454 var t = this; 13455 t.$slides = t.$slider.children(t.options.slide + ":not(.slick-cloned)").addClass("slick-slide"), 13456 t.slideCount = t.$slides.length, 13457 t.$slides.each(function(t, e) { 13458 u(e).attr("data-slick-index", t).data("originalStyling", u(e).attr("style") || "") 13459 }), 13460 t.$slider.addClass("slick-slider"), 13461 t.$slideTrack = 0 === t.slideCount ? u('<div class="slick-track"/>').appendTo(t.$slider) : t.$slides.wrapAll('<div class="slick-track"/>').parent(), 13462 t.$list = t.$slideTrack.wrap('<div class="slick-list"/>').parent(), 13463 t.$slideTrack.css("opacity", 0), 13464 !0 !== t.options.centerMode && !0 !== t.options.swipeToSlide || (t.options.slidesToScroll = 1), 13465 u("img[data-lazy]", t.$slider).not("[src]").addClass("slick-loading"), 13466 t.setupInfinite(), 13467 t.buildArrows(), 13468 t.buildDots(), 13469 t.updateDots(), 13470 t.setSlideClasses("number" == typeof t.currentSlide ? t.currentSlide : 0), 13471 !0 === t.options.draggable && t.$list.addClass("draggable") 13472 } 13473 , 13474 r.prototype.buildRows = function() { 13475 var t, e, i, n, s, o, r, a = this; 13476 if (n = document.createDocumentFragment(), 13477 o = a.$slider.children(), 13478 0 < a.options.rows) { 13479 for (r = a.options.slidesPerRow * a.options.rows, 13480 s = Math.ceil(o.length / r), 13481 t = 0; t < s; t++) { 13482 var l = document.createElement("div"); 13483 for (e = 0; e < a.options.rows; e++) { 13484 var c = document.createElement("div"); 13485 for (i = 0; i < a.options.slidesPerRow; i++) { 13486 var u = t * r + (e * a.options.slidesPerRow + i); 13487 o.get(u) && c.appendChild(o.get(u)) 13488 } 13489 l.appendChild(c) 13490 } 13491 n.appendChild(l) 13492 } 13493 a.$slider.empty().append(n), 13494 a.$slider.children().children().children().css({ 13495 width: 100 / a.options.slidesPerRow + "%", 13496 display: "inline-block" 13497 }) 13498 } 13499 } 13500 , 13501 r.prototype.checkResponsive = function(t, e) { 13502 var i, n, s, o = this, r = !1, a = o.$slider.width(), l = window.innerWidth || u(window).width(); 13503 if ("window" === o.respondTo ? s = l : "slider" === o.respondTo ? s = a : "min" === o.respondTo && (s = Math.min(l, a)), 13504 o.options.responsive && o.options.responsive.length && null !== o.options.responsive) { 13505 for (i in n = null, 13506 o.breakpoints) 13507 o.breakpoints.hasOwnProperty(i) && (!1 === o.originalSettings.mobileFirst ? s < o.breakpoints[i] && (n = o.breakpoints[i]) : s > o.breakpoints[i] && (n = o.breakpoints[i])); 13508 null !== n ? null !== o.activeBreakpoint ? (n !== o.activeBreakpoint || e) && (o.activeBreakpoint = n, 13509 "unslick" === o.breakpointSettings[n] ? o.unslick(n) : (o.options = u.extend({}, o.originalSettings, o.breakpointSettings[n]), 13510 !0 === t && (o.currentSlide = o.options.initialSlide), 13511 o.refresh(t)), 13512 r = n) : (o.activeBreakpoint = n, 13513 "unslick" === o.breakpointSettings[n] ? o.unslick(n) : (o.options = u.extend({}, o.originalSettings, o.breakpointSettings[n]), 13514 !0 === t && (o.currentSlide = o.options.initialSlide), 13515 o.refresh(t)), 13516 r = n) : null !== o.activeBreakpoint && (o.activeBreakpoint = null, 13517 o.options = o.originalSettings, 13518 !0 === t && (o.currentSlide = o.options.initialSlide), 13519 o.refresh(t), 13520 r = n), 13521 t || !1 === r || o.$slider.trigger("breakpoint", [o, r]) 13522 } 13523 } 13524 , 13525 r.prototype.changeSlide = function(t, e) { 13526 var i, n, s = this, o = u(t.currentTarget); 13527 switch (o.is("a") && t.preventDefault(), 13528 o.is("li") || (o = o.closest("li")), 13529 i = s.slideCount % s.options.slidesToScroll != 0 ? 0 : (s.slideCount - s.currentSlide) % s.options.slidesToScroll, 13530 t.data.message) { 13531 case "previous": 13532 n = 0 === i ? s.options.slidesToScroll : s.options.slidesToShow - i, 13533 s.slideCount > s.options.slidesToShow && s.slideHandler(s.currentSlide - n, !1, e); 13534 break; 13535 case "next": 13536 n = 0 === i ? s.options.slidesToScroll : i, 13537 s.slideCount > s.options.slidesToShow && s.slideHandler(s.currentSlide + n, !1, e); 13538 break; 13539 case "index": 13540 var r = 0 === t.data.index ? 0 : t.data.index || o.index() * s.options.slidesToScroll; 13541 s.slideHandler(s.checkNavigable(r), !1, e), 13542 o.children().trigger("focus"); 13543 break; 13544 default: 13545 return 13546 } 13547 } 13548 , 13549 r.prototype.checkNavigable = function(t) { 13550 var e, i; 13551 if (i = 0, 13552 t > (e = this.getNavigableIndexes())[e.length - 1]) 13553 t = e[e.length - 1]; 13554 else 13555 for (var n in e) { 13556 if (t < e[n]) { 13557 t = i; 13558 break 13559 } 13560 i = e[n] 13561 } 13562 return t 13563 } 13564 , 13565 r.prototype.cleanUpEvents = function() { 13566 var t = this; 13567 t.options.dots && null !== t.$dots && (u("li", t.$dots).off("click.slick", t.changeSlide).off("mouseenter.slick", u.proxy(t.interrupt, t, !0)).off("mouseleave.slick", u.proxy(t.interrupt, t, !1)), 13568 !0 === t.options.accessibility && t.$dots.off("keydown.slick", t.keyHandler)), 13569 t.$slider.off("focus.slick blur.slick"), 13570 !0 === t.options.arrows && t.slideCount > t.options.slidesToShow && (t.$prevArrow && t.$prevArrow.off("click.slick", t.changeSlide), 13571 t.$nextArrow && t.$nextArrow.off("click.slick", t.changeSlide), 13572 !0 === t.options.accessibility && (t.$prevArrow && t.$prevArrow.off("keydown.slick", t.keyHandler), 13573 t.$nextArrow && t.$nextArrow.off("keydown.slick", t.keyHandler))), 13574 t.$list.off("touchstart.slick mousedown.slick", t.swipeHandler), 13575 t.$list.off("touchmove.slick mousemove.slick", t.swipeHandler), 13576 t.$list.off("touchend.slick mouseup.slick", t.swipeHandler), 13577 t.$list.off("touchcancel.slick mouseleave.slick", t.swipeHandler), 13578 t.$list.off("click.slick", t.clickHandler), 13579 u(document).off(t.visibilityChange, t.visibility), 13580 t.cleanUpSlideEvents(), 13581 !0 === t.options.accessibility && t.$list.off("keydown.slick", t.keyHandler), 13582 !0 === t.options.focusOnSelect && u(t.$slideTrack).children().off("click.slick", t.selectHandler), 13583 u(window).off("orientationchange.slick.slick-" + t.instanceUid, t.orientationChange), 13584 u(window).off("resize.slick.slick-" + t.instanceUid, t.resize), 13585 u("[draggable!=true]", t.$slideTrack).off("dragstart", t.preventDefault), 13586 u(window).off("load.slick.slick-" + t.instanceUid, t.setPosition) 13587 } 13588 , 13589 r.prototype.cleanUpSlideEvents = function() { 13590 this.$list.off("mouseenter.slick", u.proxy(this.interrupt, this, !0)), 13591 this.$list.off("mouseleave.slick", u.proxy(this.interrupt, this, !1)) 13592 } 13593 , 13594 r.prototype.cleanUpRows = function() { 13595 var t; 13596 0 < this.options.rows && ((t = this.$slides.children().children()).removeAttr("style"), 13597 this.$slider.empty().append(t)) 13598 } 13599 , 13600 r.prototype.clickHandler = function(t) { 13601 !1 === this.shouldClick && (t.stopImmediatePropagation(), 13602 t.stopPropagation(), 13603 t.preventDefault()) 13604 } 13605 , 13606 r.prototype.destroy = function(t) { 13607 var e = this; 13608 e.autoPlayClear(), 13609 e.touchObject = {}, 13610 e.cleanUpEvents(), 13611 u(".slick-cloned", e.$slider).detach(), 13612 e.$dots && e.$dots.remove(), 13613 e.$prevArrow && e.$prevArrow.length && (e.$prevArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display", ""), 13614 e.htmlExpr.test(e.options.prevArrow) && e.$prevArrow.remove()), 13615 e.$nextArrow && e.$nextArrow.length && (e.$nextArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display", ""), 13616 e.htmlExpr.test(e.options.nextArrow) && e.$nextArrow.remove()), 13617 e.$slides && (e.$slides.removeClass("slick-slide slick-active slick-center slick-visible slick-current").removeAttr("aria-hidden").removeAttr("data-slick-index").each(function() { 13618 u(this).attr("style", u(this).data("originalStyling")) 13619 }), 13620 e.$slideTrack.children(this.options.slide).detach(), 13621 e.$slideTrack.detach(), 13622 e.$list.detach(), 13623 e.$slider.append(e.$slides)), 13624 e.cleanUpRows(), 13625 e.$slider.removeClass("slick-slider"), 13626 e.$slider.removeClass("slick-initialized"), 13627 e.$slider.removeClass("slick-dotted"), 13628 e.unslicked = !0, 13629 t || e.$slider.trigger("destroy", [e]) 13630 } 13631 , 13632 r.prototype.disableTransition = function(t) { 13633 var e = {}; 13634 e[this.transitionType] = "", 13635 !1 === this.options.fade ? this.$slideTrack.css(e) : this.$slides.eq(t).css(e) 13636 } 13637 , 13638 r.prototype.fadeSlide = function(t, e) { 13639 var i = this; 13640 !1 === i.cssTransitions ? (i.$slides.eq(t).css({ 13641 zIndex: i.options.zIndex 13642 }), 13643 i.$slides.eq(t).animate({ 13644 opacity: 1 13645 }, i.options.speed, i.options.easing, e)) : (i.applyTransition(t), 13646 i.$slides.eq(t).css({ 13647 opacity: 1, 13648 zIndex: i.options.zIndex 13649 }), 13650 e && setTimeout(function() { 13651 i.disableTransition(t), 13652 e.call() 13653 }, i.options.speed)) 13654 } 13655 , 13656 r.prototype.fadeSlideOut = function(t) { 13657 !1 === this.cssTransitions ? this.$slides.eq(t).animate({ 13658 opacity: 0, 13659 zIndex: this.options.zIndex - 2 13660 }, this.options.speed, this.options.easing) : (this.applyTransition(t), 13661 this.$slides.eq(t).css({ 13662 opacity: 0, 13663 zIndex: this.options.zIndex - 2 13664 })) 13665 } 13666 , 13667 r.prototype.filterSlides = r.prototype.slickFilter = function(t) { 13668 null !== t && (this.$slidesCache = this.$slides, 13669 this.unload(), 13670 this.$slideTrack.children(this.options.slide).detach(), 13671 this.$slidesCache.filter(t).appendTo(this.$slideTrack), 13672 this.reinit()) 13673 } 13674 , 13675 r.prototype.focusHandler = function() { 13676 var e = this; 13677 e.$slider.off("focus.slick blur.slick").on("focus.slick", "*", function() { 13678 var t = u(this); 13679 setTimeout(function() { 13680 e.options.pauseOnFocus && t.is(":focus") && (e.focussed = !0, 13681 e.autoPlay()) 13682 }, 0) 13683 }).on("blur.slick", "*", function() { 13684 u(this); 13685 e.options.pauseOnFocus && (e.focussed = !1, 13686 e.autoPlay()) 13687 }) 13688 } 13689 , 13690 r.prototype.getCurrent = r.prototype.slickCurrentSlide = function() { 13691 return this.currentSlide 13692 } 13693 , 13694 r.prototype.getDotCount = function() { 13695 var t = this 13696 , e = 0 13697 , i = 0 13698 , n = 0; 13699 if (!0 === t.options.infinite) 13700 if (t.slideCount <= t.options.slidesToShow) 13701 ++n; 13702 else 13703 for (; e < t.slideCount; ) 13704 ++n, 13705 e = i + t.options.slidesToScroll, 13706 i += t.options.slidesToScroll <= t.options.slidesToShow ? t.options.slidesToScroll : t.options.slidesToShow; 13707 else if (!0 === t.options.centerMode) 13708 n = t.slideCount; 13709 else if (t.options.asNavFor) 13710 for (; e < t.slideCount; ) 13711 ++n, 13712 e = i + t.options.slidesToScroll, 13713 i += t.options.slidesToScroll <= t.options.slidesToShow ? t.options.slidesToScroll : t.options.slidesToShow; 13714 else 13715 n = 1 + Math.ceil((t.slideCount - t.options.slidesToShow) / t.options.slidesToScroll); 13716 return n - 1 13717 } 13718 , 13719 r.prototype.getLeft = function(t) { 13720 var e, i, n, s, o = this, r = 0; 13721 return o.slideOffset = 0, 13722 i = o.$slides.first().outerHeight(!0), 13723 !0 === o.options.infinite ? (o.slideCount > o.options.slidesToShow && (o.slideOffset = o.slideWidth * o.options.slidesToShow * -1, 13724 s = -1, 13725 !0 === o.options.vertical && !0 === o.options.centerMode && (2 === o.options.slidesToShow ? s = -1.5 : 1 === o.options.slidesToShow && (s = -2)), 13726 r = i * o.options.slidesToShow * s), 13727 o.slideCount % o.options.slidesToScroll != 0 && t + o.options.slidesToScroll > o.slideCount && o.slideCount > o.options.slidesToShow && (t > o.slideCount ? (o.slideOffset = (o.options.slidesToShow - (t - o.slideCount)) * o.slideWidth * -1, 13728 r = (o.options.slidesToShow - (t - o.slideCount)) * i * -1) : (o.slideOffset = o.slideCount % o.options.slidesToScroll * o.slideWidth * -1, 13729 r = o.slideCount % o.options.slidesToScroll * i * -1))) : t + o.options.slidesToShow > o.slideCount && (o.slideOffset = (t + o.options.slidesToShow - o.slideCount) * o.slideWidth, 13730 r = (t + o.options.slidesToShow - o.slideCount) * i), 13731 o.slideCount <= o.options.slidesToShow && (r = o.slideOffset = 0), 13732 !0 === o.options.centerMode && o.slideCount <= o.options.slidesToShow ? o.slideOffset = o.slideWidth * Math.floor(o.options.slidesToShow) / 2 - o.slideWidth * o.slideCount / 2 : !0 === o.options.centerMode && !0 === o.options.infinite ? o.slideOffset += o.slideWidth * Math.floor(o.options.slidesToShow / 2) - o.slideWidth : !0 === o.options.centerMode && (o.slideOffset = 0, 13733 o.slideOffset += o.slideWidth * Math.floor(o.options.slidesToShow / 2)), 13734 e = !1 === o.options.vertical ? t * o.slideWidth * -1 + o.slideOffset : t * i * -1 + r, 13735 !0 === o.options.variableWidth && (n = o.slideCount <= o.options.slidesToShow || !1 === o.options.infinite ? o.$slideTrack.children(".slick-slide").eq(t) : o.$slideTrack.children(".slick-slide").eq(t + o.options.slidesToShow), 13736 e = !0 === o.options.rtl ? n[0] ? -1 * (o.$slideTrack.width() - n[0].offsetLeft - n.width()) : 0 : n[0] ? -1 * n[0].offsetLeft : 0, 13737 !0 === o.options.centerMode && (n = o.slideCount <= o.options.slidesToShow || !1 === o.options.infinite ? o.$slideTrack.children(".slick-slide").eq(t) : o.$slideTrack.children(".slick-slide").eq(t + o.options.slidesToShow + 1), 13738 e = !0 === o.options.rtl ? n[0] ? -1 * (o.$slideTrack.width() - n[0].offsetLeft - n.width()) : 0 : n[0] ? -1 * n[0].offsetLeft : 0, 13739 e += (o.$list.width() - n.outerWidth()) / 2)), 13740 e 13741 } 13742 , 13743 r.prototype.getOption = r.prototype.slickGetOption = function(t) { 13744 return this.options[t] 13745 } 13746 , 13747 r.prototype.getNavigableIndexes = function() { 13748 var t, e = this, i = 0, n = 0, s = []; 13749 for (!1 === e.options.infinite ? t = e.slideCount : (i = -1 * e.options.slidesToScroll,
13750 n = -1 * e.options.slidesToScroll, 13751 t = 2 * e.slideCount); i < t; ) 13752 s.push(i), 13753 i = n + e.options.slidesToScroll, 13754 n += e.options.slidesToScroll <= e.options.slidesToShow ? e.options.slidesToScroll : e.options.slidesToShow; 13755 return s 13756 } 13757 , 13758 r.prototype.getSlick = function() { 13759 return this 13760 } 13761 , 13762 r.prototype.getSlideCount = function() { 13763 var i, n, s = this; 13764 return n = !0 === s.options.centerMode ? s.slideWidth * Math.floor(s.options.slidesToShow / 2) : 0, 13765 !0 === s.options.swipeToSlide ? (s.$slideTrack.find(".slick-slide").each(function(t, e) { 13766 if (e.offsetLeft - n + u(e).outerWidth() / 2 > -1 * s.swipeLeft) 13767 return i = e, 13768 !1 13769 }), 13770 Math.abs(u(i).attr("data-slick-index") - s.currentSlide) || 1) : s.options.slidesToScroll 13771 } 13772 , 13773 r.prototype.goTo = r.prototype.slickGoTo = function(t, e) { 13774 this.changeSlide({ 13775 data: { 13776 message: "index", 13777 index: parseInt(t) 13778 } 13779 }, e) 13780 } 13781 , 13782 r.prototype.init = function(t) { 13783 var e = this; 13784 u(e.$slider).hasClass("slick-initialized") || (u(e.$slider).addClass("slick-initialized"), 13785 e.buildRows(), 13786 e.buildOut(), 13787 e.setProps(), 13788 e.startLoad(), 13789 e.loadSlider(), 13790 e.initializeEvents(), 13791 e.updateArrows(), 13792 e.updateDots(), 13793 e.checkResponsive(!0), 13794 e.focusHandler()), 13795 t && e.$slider.trigger("init", [e]), 13796 !0 === e.options.accessibility && e.initADA(), 13797 e.options.autoplay && (e.paused = !1, 13798 e.autoPlay()) 13799 } 13800 , 13801 r.prototype.initADA = function() { 13802 var n = this 13803 , i = Math.ceil(n.slideCount / n.options.slidesToShow) 13804 , s = n.getNavigableIndexes().filter(function(t) { 13805 return 0 <= t && t < n.slideCount 13806 }); 13807 n.$slides.add(n.$slideTrack.find(".slick-cloned")).attr({ 13808 "aria-hidden": "true", 13809 tabindex: "-1" 13810 }).find("a, input, button, select").attr({ 13811 tabindex: "-1" 13812 }), 13813 null !== n.$dots && (n.$slides.not(n.$slideTrack.find(".slick-cloned")).each(function(t) { 13814 var e = s.indexOf(t); 13815 if (u(this).attr({ 13816 role: "tabpanel", 13817 id: "slick-slide" + n.instanceUid + t, 13818 tabindex: -1 13819 }), 13820 -1 !== e) { 13821 var i = "slick-slide-control" + n.instanceUid + e; 13822 u("#" + i).length && u(this).attr({ 13823 "aria-describedby": i 13824 }) 13825 } 13826 }), 13827 n.$dots.attr("role", "tablist").find("li").each(function(t) { 13828 var e = s[t]; 13829 u(this).attr({ 13830 role: "presentation" 13831 }), 13832 u(this).find("button").first().attr({ 13833 role: "tab", 13834 id: "slick-slide-control" + n.instanceUid + t, 13835 "aria-controls": "slick-slide" + n.instanceUid + e, 13836 "aria-label": t + 1 + " of " + i, 13837 "aria-selected": null, 13838 tabindex: "-1" 13839 }) 13840 }).eq(n.currentSlide).find("button").attr({ 13841 "aria-selected": "true", 13842 tabindex: "0" 13843 }).end()); 13844 for (var t = n.currentSlide, e = t + n.options.slidesToShow; t < e; t++) 13845 n.options.focusOnChange ? n.$slides.eq(t).attr({ 13846 tabindex: "0" 13847 }) : n.$slides.eq(t).removeAttr("tabindex"); 13848 n.activateADA() 13849 } 13850 , 13851 r.prototype.initArrowEvents = function() { 13852 var t = this; 13853 !0 === t.options.arrows && t.slideCount > t.options.slidesToShow && (t.$prevArrow.off("click.slick").on("click.slick", { 13854 message: "previous" 13855 }, t.changeSlide), 13856 t.$nextArrow.off("click.slick").on("click.slick", { 13857 message: "next" 13858 }, t.changeSlide), 13859 !0 === t.options.accessibility && (t.$prevArrow.on("keydown.slick", t.keyHandler), 13860 t.$nextArrow.on("keydown.slick", t.keyHandler))) 13861 } 13862 , 13863 r.prototype.initDotEvents = function() { 13864 var t = this; 13865 !0 === t.options.dots && t.slideCount > t.options.slidesToShow && (u("li", t.$dots).on("click.slick", { 13866 message: "index" 13867 }, t.changeSlide), 13868 !0 === t.options.accessibility && t.$dots.on("keydown.slick", t.keyHandler)), 13869 !0 === t.options.dots && !0 === t.options.pauseOnDotsHover && t.slideCount > t.options.slidesToShow && u("li", t.$dots).on("mouseenter.slick", u.proxy(t.
vendor: 11,318 bytes, lines 13869-14168
13869interrupt, t, !0)).on("mouseleave.slick", u.proxy(t.interrupt, t, !1)) 13870 } 13871 , 13872 r.prototype.initSlideEvents = function() { 13873 this.options.pauseOnHover && (this.$list.on("mouseenter.slick", u.proxy(this.interrupt, this, !0)), 13874 this.$list.on("mouseleave.slick", u.proxy(this.interrupt, this, !1))) 13875 } 13876 , 13877 r.prototype.initializeEvents = function() { 13878 var t = this; 13879 t.initArrowEvents(), 13880 t.initDotEvents(), 13881 t.initSlideEvents(), 13882 t.$list.on("touchstart.slick mousedown.slick", { 13883 action: "start" 13884 }, t.swipeHandler), 13885 t.$list.on("touchmove.slick mousemove.slick", { 13886 action: "move" 13887 }, t.swipeHandler), 13888 t.$list.on("touchend.slick mouseup.slick", { 13889 action: "end" 13890 }, t.swipeHandler), 13891 t.$list.on("touchcancel.slick mouseleave.slick", { 13892 action: "end" 13893 }, t.swipeHandler), 13894 t.$list.on("click.slick", t.clickHandler), 13895 u(document).on(t.visibilityChange, u.proxy(t.visibility, t)), 13896 !0 === t.options.accessibility && t.$list.on("keydown.slick", t.keyHandler), 13897 !0 === t.options.focusOnSelect && u(t.$slideTrack).children().on("click.slick", t.selectHandler), 13898 u(window).on("orientationchange.slick.slick-" + t.instanceUid, u.proxy(t.orientationChange, t)), 13899 u(window).on("resize.slick.slick-" + t.instanceUid, u.proxy(t.resize, t)), 13900 u("[draggable!=true]", t.$slideTrack).on("dragstart", t.preventDefault), 13901 u(window).on("load.slick.slick-" + t.instanceUid, t.setPosition), 13902 u(t.setPosition) 13903 } 13904 , 13905 r.prototype.initUI = function() { 13906 !0 === this.options.arrows && this.slideCount > this.options.slidesToShow && (this.$prevArrow.show(), 13907 this.$nextArrow.show()), 13908 !0 === this.options.dots && this.slideCount > this.options.slidesToShow && this.$dots.show() 13909 } 13910 , 13911 r.prototype.keyHandler = function(t) { 13912 t.target.tagName.match("TEXTAREA|INPUT|SELECT") || (37 === t.keyCode && !0 === this.options.accessibility ? this.changeSlide({ 13913 data: { 13914 message: !0 === this.options.rtl ? "next" : "previous" 13915 } 13916 }) : 39 === t.keyCode && !0 === this.options.accessibility && this.changeSlide({ 13917 data: { 13918 message: !0 === this.options.rtl ? "previous" : "next" 13919 } 13920 })) 13921 } 13922 , 13923 r.prototype.lazyLoad = function() { 13924 function t(t) { 13925 u("img[data-lazy]", t).each(function() { 13926 var t = u(this) 13927 , e = u(this).attr("data-lazy") 13928 , i = u(this).attr("data-srcset") 13929 , n = u(this).attr("data-sizes") || o.$slider.attr("data-sizes") 13930 , s = document.createElement("img"); 13931 s.onload = function() { 13932 t.animate({ 13933 opacity: 0 13934 }, 100, function() { 13935 i && (t.attr("srcset", i), 13936 n && t.attr("sizes", n)), 13937 t.attr("src", e).animate({ 13938 opacity: 1 13939 }, 200, function() { 13940 t.removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading") 13941 }), 13942 o.$slider.trigger("lazyLoaded", [o, t, e]) 13943 }) 13944 } 13945 , 13946 s.onerror = function() { 13947 t.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"), 13948 o.$slider.trigger("lazyLoadError", [o, t, e]) 13949 } 13950 , 13951 s.src = e 13952 }) 13953 } 13954 var e, i, n, o = this; 13955 if (!0 === o.options.centerMode ? !0 === o.options.infinite ? n = (i = o.currentSlide + (o.options.slidesToShow / 2 + 1)) + o.options.slidesToShow + 2 : (i = Math.max(0, o.currentSlide - (o.options.slidesToShow / 2 + 1)), 13956 n = o.options.slidesToShow / 2 + 1 + 2 + o.currentSlide) : (i = o.options.infinite ? o.options.slidesToShow + o.currentSlide : o.currentSlide, 13957 n = Math.ceil(i + o.options.slidesToShow), 13958 !0 === o.options.fade && (0 < i && i--, 13959 n <= o.slideCount && n++)), 13960 e = o.$slider.find(".slick-slide").slice(i, n), 13961 "anticipated" === o.options.lazyLoad) 13962 for (var s = i - 1, r = n, a = o.$slider.find(".slick-slide"), l = 0; l < o.options.slidesToScroll; l++) 13963 s < 0 && (s = o.slideCount - 1), 13964 e = (e = e.add(a.eq(s))).add(a.eq(r)), 13965 s--, 13966 r++; 13967 t(e), 13968 o.slideCount <= o.options.slidesToShow ? t(o.$slider.find(".slick-slide")) : o.currentSlide >= o.slideCount - o.options.slidesToShow ? t(o.$slider.find(".slick-cloned").slice(0, o.options.slidesToShow)) : 0 === o.currentSlide && t(o.$slider.find(".slick-cloned").slice(-1 * o.options.slidesToShow)) 13969 } 13970 , 13971 r.prototype.loadSlider = function() { 13972 this.setPosition(), 13973 this.$slideTrack.css({ 13974 opacity: 1 13975 }), 13976 this.$slider.removeClass("slick-loading"), 13977 this.initUI(), 13978 "progressive" === this.options.lazyLoad && this.progressiveLazyLoad() 13979 } 13980 , 13981 r.prototype.next = r.prototype.slickNext = function() { 13982 this.changeSlide({ 13983 data: { 13984 message: "next" 13985 } 13986 }) 13987 } 13988 , 13989 r.prototype.orientationChange = function() { 13990 this.checkResponsive(), 13991 this.setPosition() 13992 } 13993 , 13994 r.prototype.pause = r.prototype.slickPause = function() { 13995 this.autoPlayClear(), 13996 this.paused = !0 13997 } 13998 , 13999 r.prototype.play = r.prototype.slickPlay = function() { 14000 this.autoPlay(), 14001 this.options.autoplay = !0, 14002 this.paused = !1, 14003 this.focussed = !1, 14004 this.interrupted = !1 14005 } 14006 , 14007 r.prototype.postSlide = function(t) { 14008 var e = this; 14009 e.unslicked || (e.$slider.trigger("afterChange", [e, t]), 14010 e.animating = !1, 14011 e.slideCount > e.options.slidesToShow && e.setPosition(), 14012 e.swipeLeft = null, 14013 e.options.autoplay && e.autoPlay(), 14014 !0 === e.options.accessibility && (e.initADA(), 14015 e.options.focusOnChange && u(e.$slides.get(e.currentSlide)).attr("tabindex", 0).focus())) 14016 } 14017 , 14018 r.prototype.prev = r.prototype.slickPrev = function() { 14019 this.changeSlide({ 14020 data: { 14021 message: "previous" 14022 } 14023 }) 14024 } 14025 , 14026 r.prototype.preventDefault = function(t) { 14027 t.preventDefault() 14028 } 14029 , 14030 r.prototype.progressiveLazyLoad = function(t) { 14031 t = t || 1; 14032 var e, i, n, s, o, r = this, a = u("img[data-lazy]", r.$slider); 14033 a.length ? (e = a.first(), 14034 i = e.attr("data-lazy"), 14035 n = e.attr("data-srcset"), 14036 s = e.attr("data-sizes") || r.$slider.attr("data-sizes"), 14037 (o = document.createElement("img")).onload = function() { 14038 n && (e.attr("srcset", n), 14039 s && e.attr("sizes", s)), 14040 e.attr("src", i).removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading"), 14041 !0 === r.options.adaptiveHeight && r.setPosition(), 14042 r.$slider.trigger("lazyLoaded", [r, e, i]), 14043 r.progressiveLazyLoad() 14044 } 14045 , 14046 o.onerror = function() { 14047 t < 3 ? setTimeout(function() { 14048 r.progressiveLazyLoad(t + 1) 14049 }, 500) : (e.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"), 14050 r.$slider.trigger("lazyLoadError", [r, e, i]), 14051 r.progressiveLazyLoad()) 14052 } 14053 , 14054 o.src = i) : r.$slider.trigger("allImagesLoaded", [r]) 14055 } 14056 , 14057 r.prototype.refresh = function(t) { 14058 var e, i, n = this; 14059 i = n.slideCount - n.options.slidesToShow, 14060 !n.options.infinite && n.currentSlide > i && (n.currentSlide = i), 14061 n.slideCount <= n.options.slidesToShow && (n.currentSlide = 0), 14062 e = n.currentSlide, 14063 n.destroy(!0), 14064 u.extend(n, n.initials, { 14065 currentSlide: e 14066 }), 14067 n.init(), 14068 t || n.changeSlide({ 14069 data: { 14070 message: "index", 14071 index: e 14072 } 14073 }, !1) 14074 } 14075 , 14076 r.prototype.registerBreakpoints = function() { 14077 var t, e, i, n = this, s = n.options.responsive || null; 14078 if ("array" === u.type(s) && s.length) { 14079 for (t in n.respondTo = n.options.respondTo || "window", 14080 s) 14081 if (i = n.breakpoints.length - 1, 14082 s.hasOwnProperty(t)) { 14083 for (e = s[t].breakpoint; 0 <= i; ) 14084 n.breakpoints[i] && n.breakpoints[i] === e && n.breakpoints.splice(i, 1), 14085 i--; 14086 n.breakpoints.push(e), 14087 n.breakpointSettings[e] = s[t].settings 14088 } 14089 n.breakpoints.sort(function(t, e) { 14090 return n.options.mobileFirst ? t - e : e - t 14091 }) 14092 } 14093 } 14094 , 14095 r.prototype.reinit = function() { 14096 var t = this; 14097 t.$slides = t.$slideTrack.children(t.options.slide).addClass("slick-slide"), 14098 t.slideCount = t.$slides.length, 14099 t.currentSlide >= t.slideCount && 0 !== t.currentSlide && (t.currentSlide = t.currentSlide - t.options.slidesToScroll), 14100 t.slideCount <= t.options.slidesToShow && (t.currentSlide = 0), 14101 t.registerBreakpoints(), 14102 t.setProps(), 14103 t.setupInfinite(), 14104 t.buildArrows(), 14105 t.updateArrows(), 14106 t.initArrowEvents(), 14107 t.buildDots(), 14108 t.updateDots(), 14109 t.initDotEvents(), 14110 t.cleanUpSlideEvents(), 14111 t.initSlideEvents(), 14112 t.checkResponsive(!1, !0), 14113 !0 === t.options.focusOnSelect && u(t.$slideTrack).children().on("click.slick", t.selectHandler), 14114 t.setSlideClasses("number" == typeof t.currentSlide ? t.currentSlide : 0), 14115 t.setPosition(), 14116 t.focusHandler(), 14117 t.paused = !t.options.autoplay, 14118 t.autoPlay(), 14119 t.$slider.trigger("reInit", [t]) 14120 } 14121 , 14122 r.prototype.resize = function() { 14123 var t = this; 14124 u(window).width() !== t.windowWidth && (clearTimeout(t.windowDelay), 14125 t.windowDelay = window.setTimeout(function() { 14126 t.windowWidth = u(window).width(), 14127 t.checkResponsive(), 14128 t.unslicked || t.setPosition() 14129 }, 50)) 14130 } 14131 , 14132 r.prototype.removeSlide = r.prototype.slickRemove = function(t, e, i) { 14133 var n = this; 14134 if (t = "boolean" == typeof t ? !0 === (e = t) ? 0 : n.slideCount - 1 : !0 === e ? --t : t, 14135 n.slideCount < 1 || t < 0 || t > n.slideCount - 1) 14136 return !1; 14137 n.unload(), 14138 !0 === i ? n.$slideTrack.children().remove() : n.$slideTrack.children(this.options.slide).eq(t).remove(), 14139 n.$slides = n.$slideTrack.children(this.options.slide), 14140 n.$slideTrack.children(this.options.slide).detach(), 14141 n.$slideTrack.append(n.$slides), 14142 n.$slidesCache = n.$slides, 14143 n.reinit() 14144 } 14145 , 14146 r.prototype.setCSS = function(t) { 14147 var e, i, n = this, s = {}; 14148 !0 === n.options.rtl && (t = -t), 14149 e = "left" == n.positionProp ? Math.ceil(t) + "px" : "0px", 14150 i = "top" == n.positionProp ? Math.ceil(t) + "px" : "0px", 14151 s[n.positionProp] = t, 14152 !1 === n.transformsEnabled || (!(s = {}) === n.cssTransitions ? s[n.animType] = "translate(" + e + ", " + i + ")" : s[n.animType] = "translate3d(" + e + ", " + i + ", 0px)"), 14153 n.$slideTrack.css(s) 14154 } 14155 , 14156 r.prototype.setDimensions = function() { 14157 var t = this; 14158 !1 === t.options.vertical ? !0 === t.options.centerMode && t.$list.css({ 14159 padding: "0px " + t.options.centerPadding 14160 }) : (t.$list.height(t.$slides.first().outerHeight(!0) * t.options.slidesToShow), 14161 !0 === t.options.centerMode && t.$list.css({ 14162 padding: t.options.centerPadding + " 0px" 14163 })), 14164 t.listWidth = t.$list.width(), 14165 t.listHeight = t.$list.height(), 14166 !1 === t.options.vertical && !1 === t.options.variableWidth ? (t.slideWidth = Math.ceil(t.listWidth / t.options.slidesToShow), 14167 t.$slideTrack.width(Math.ceil(t.slideWidth * t.$slideTrack.children(".slick-slide").length))) : !0 === t.options.variableWidth ? t.$slideTrack.width(5e3 * t.slideCount) : (t.slideWidth = Math.ceil(t.listWidth), 14168 t.$slideTrack.height(Math.ceil(t.$slides.first().outerHeight(!0) * t.$slideTrack.children(".slick-slide").length)));
14169 var e = t.$slides.first().outerWidth(!0) - t.$slides.first().width(); 14170 !1 === t.options.variableWidth && t.$slideTrack.children(".slick-slide").width(t.slideWidth - e) 14171 } 14172 , 14173 r.prototype.setFade = function() { 14174 var i, n = this; 14175 n.$slides.each(function(t, e) { 14176 i = n.slideWidth * t * -1, 14177 !0 === n.options.rtl ? u(e).css({ 14178 position: "relative", 14179 right: i, 14180 top: 0, 14181 zIndex: n.options.zIndex - 2, 14182 opacity: 0 14183 }) : u(e).css({ 14184 position: "relative", 14185 left: i, 14186 top: 0, 14187 zIndex: n.options.zIndex - 2, 14188 opacity: 0 14189 }) 14190 }), 14191 n.$slides.eq(n.currentSlide).css({ 14192 zIndex: n.options.zIndex - 1, 14193 opacity: 1 14194 }) 14195 } 14196 , 14197 r.prototype.setHeight = function() { 14198 if (1 === this.options.slidesToShow && !0 === this.options.adaptiveHeight && !1 === this.options.vertical) { 14199 var t = this.$slides.eq(this.currentSlide).outerHeight(!0); 14200 this.$list.css("height", t) 14201 } 14202 } 14203 , 14204 r.prototype.setOption = r.prototype.slickSetOption = function(t, e, i) { 14205 var n, s, o, r, a, l = this, c = !1; 14206 if ("object" === u.type(t) ? (o = t, 14207 c = e, 14208 a = "multiple") : "string" === u.type(t) && (r = e, 14209 c = i, 14210 "responsive" === (o = t) && "array" === u.type(e) ? a = "responsive" : void 0 !== e && (a = "single")), 14211 "single" === a) 14212 l.options[o] = r; 14213 else if ("multiple" === a) 14214 u.each(o, function(t, e) { 14215 l.options[t] = e 14216 }); 14217 else if ("responsive" === a) 14218 for (s in r) 14219 if ("array" !== u.type(l.options.responsive)) 14220 l.options.responsive = [r[s]]; 14221 else { 14222 for (n = l.options.responsive.length - 1; 0 <= n; ) 14223 l.options.responsive[n].breakpoint === r[s].breakpoint && l.options.responsive.splice(n, 1), 14224 n--; 14225 l.options.responsive.push(r[s]) 14226 } 14227 c && (l.unload(), 14228 l.reinit()) 14229 } 14230 , 14231 r.prototype.setPosition = function() { 14232 this.setDimensions(), 14233 this.setHeight(), 14234 !1 === this.options.fade ? this.setCSS(this.getLeft(this.currentSlide)) : this.setFade(), 14235 this.$slider.trigger("setPosition", [this]) 14236 } 14237 , 14238 r.prototype.setProps = function() { 14239 var t = this 14240 , e = document.body.style; 14241 t.positionProp = !0 === t.options.vertical ? "top" : "left", 14242 "top" === t.positionProp ? t.$slider.addClass("slick-vertical") : t.$slider.removeClass("slick-vertical"), 14243 void 0 === e.WebkitTransition && void 0 === e.MozTransition && void 0 === e.msTransition || !0 === t.options.useCSS && (t.cssTransitions = !0), 14244 t.options.fade && ("number" == typeof t.options.zIndex ? t.options.zIndex < 3 && (t.options.zIndex = 3) : t.options.zIndex = t.defaults.zIndex), 14245 void 0 !== e.OTransform && (t.animType = "OTransform", 14246 t.transformType = "-o-transform", 14247 t.transitionType = "OTransition", 14248 void 0 === e.perspectiveProperty && void 0 === e.webkitPerspective && (t.animType = !1)), 14249 void 0 !== e.MozTransform && (t.animType = "MozTransform", 14250 t.transformType = "-moz-transform", 14251 t.transitionType = "MozTransition", 14252 void 0 === e.perspectiveProperty && void 0 === e.MozPerspective && (t.animType = !1)), 14253 void 0 !== e.webkitTransform && (t.animType = "webkitTransform", 14254 t.transformType = "-webkit-transform", 14255 t.transitionType = "webkitTransition", 14256 void 0 === e.perspectiveProperty && void 0 === e.webkitPerspective && (t.animType = !1)), 14257 void 0 !== e.msTransform && (t.animType = "msTransform", 14258 t.transformType = "-ms-transform", 14259 t.transitionType = "msTransition", 14260 void 0 === e.msTransform && (t.animType = !1)), 14261 void 0 !== e.transform && !1 !== t.animType && (t.animType = "transform", 14262 t.transformType = "transform", 14263 t.transitionType = "transition"), 14264 t.transformsEnabled = t.options.useTransform && null !== t.animType && !1 !== t.animType 14265 } 14266 , 14267 r.prototype.setSlideClasses = function(t) { 14268 var e, i, n, s, o = this; 14269 if (i = o.$slider.find(".slick-slide").removeClass("slick-active slick-center slick-current").attr("aria-hidden", "true"), 14270 o.$slides.eq(t).addClass("slick-current"), 14271 !0 === o.options.centerMode) { 14272 var r = o.options.slidesToShow % 2 == 0 ? 1 : 0; 14273 e = Math.floor(o.options.slidesToShow / 2), 14274 !0 === o.options.infinite && (e <= t && t <= o.slideCount - 1 - e ? o.$slides.slice(t - e + r, t + e + 1).addClass("slick-active").attr("aria-hidden", "false") : (n = o.options.slidesToShow + t, 14275 i.slice(n - e + 1 + r, n + e + 2).addClass("slick-active").attr("aria-hidden", "false")), 14276 0 === t ? i.eq(i.length - 1 - o.options.slidesToShow).addClass("slick-center") : t === o.slideCount - 1 && i.eq(o.options.slidesToShow).addClass("slick-center")), 14277 o.$slides.eq(t).addClass("slick-center") 14278 } else 14279 0 <= t && t <= o.slideCount - o.options.slidesToShow ? o.$slides.slice(t, t + o.options.slidesToShow).addClass("slick-active").attr("aria-hidden", "false") : i.length <= o.options.slidesToShow ? i.addClass("slick-active").attr("aria-hidden", "false") : (s = o.slideCount % o.options.slidesToShow, 14280 n = !0 === o.options.infinite ? o.options.slidesToShow + t : t, 14281 o.options.slidesToShow == o.options.slidesToScroll && o.slideCount - t < o.options.slidesToShow ? i.slice(n - (o.options.slidesToShow - s), n + s).addClass("slick-active").attr("aria-hidden", "false") : i.slice(n, n + o.options.slidesToShow).addClass("slick-active").attr("aria-hidden", "false")); 14282 "ondemand" !== o.options.lazyLoad && "anticipated" !== o.options.lazyLoad || o.lazyLoad() 14283 } 14284 , 14285 r.prototype.setupInfinite = function() { 14286 var t, e, i, n = this; 14287 if (!0 === n.options.fade && (n.options.centerMode = !1), 14288 !0 === n.options.infinite && !1 === n.options.fade && (e = null, 14289 n.slideCount > n.options.slidesToShow)) { 14290 for (i = !0 === n.options.centerMode ? n.options.slidesToShow + 1 : n.options.slidesToShow, 14291 t = n.slideCount; t > n.slideCount - i; t -= 1) 14292 e = t - 1, 14293 u(n.$slides[e]).clone(!0).attr("id", "").attr("data-slick-index", e - n.slideCount).prependTo(n.$slideTrack).addClass("slick-cloned"); 14294 for (t = 0; t < i + n.slideCount; t += 1) 14295 e = t, 14296 u(n.$slides[e]).clone(!0).attr("id", "").attr("data-slick-index", e + n.slideCount).appendTo(n.$slideTrack).addClass("slick-cloned"); 14297 n.$slideTrack.find(".slick-cloned").find("[id]").each(function() { 14298 u(this).attr("id", "") 14299 }) 14300 } 14301 } 14302 , 14303 r.prototype.interrupt = function(t) { 14304 t || this.autoPlay(), 14305 this.interrupted = t 14306 } 14307 , 14308 r.prototype.selectHandler = function(t) { 14309 var e = u(t.target).is(".slick-slide") ? u(t.target) : u(t.target).parents(".slick-slide") 14310 , i = parseInt(e.attr("data-slick-index")); 14311 i || (i = 0), 14312 this.slideCount <= this.options.slidesToShow ? this.slideHandler(i, !1, !0) : this.slideHandler(i) 14313 } 14314 , 14315 r.prototype.slideHandler = function(t, e, i) { 14316 var n, s, o, r, a, l, c = this; 14317 if (e = e || !1, 14318 !(!0 === c.animating && !0 === c.options.waitForAnimate || !0 === c.options.fade && c.currentSlide === t)) 14319 if (!1 === e && c.asNavFor(t), 14320 n = t, 14321 a = c.getLeft(n),
vendor: 7,457 bytes, lines 14322-14472
14322 r = c.getLeft(c.currentSlide), 14323 c.currentLeft = null === c.swipeLeft ? r : c.swipeLeft, 14324 !1 === c.options.infinite && !1 === c.options.centerMode && (t < 0 || t > c.getDotCount() * c.options.slidesToScroll)) 14325 !1 === c.options.fade && (n = c.currentSlide, 14326 !0 !== i && c.slideCount > c.options.slidesToShow ? c.animateSlide(r, function() { 14327 c.postSlide(n) 14328 }) : c.postSlide(n)); 14329 else if (!1 === c.options.infinite && !0 === c.options.centerMode && (t < 0 || t > c.slideCount - c.options.slidesToScroll)) 14330 !1 === c.options.fade && (n = c.currentSlide, 14331 !0 !== i && c.slideCount > c.options.slidesToShow ? c.animateSlide(r, function() { 14332 c.postSlide(n) 14333 }) : c.postSlide(n)); 14334 else { 14335 if (c.options.autoplay && clearInterval(c.autoPlayTimer), 14336 s = n < 0 ? c.slideCount % c.options.slidesToScroll != 0 ? c.slideCount - c.slideCount % c.options.slidesToScroll : c.slideCount + n : n >= c.slideCount ? c.slideCount % c.options.slidesToScroll != 0 ? 0 : n - c.slideCount : n, 14337 c.animating = !0, 14338 c.$slider.trigger("beforeChange", [c, c.currentSlide, s]), 14339 o = c.currentSlide, 14340 c.currentSlide = s, 14341 c.setSlideClasses(c.currentSlide), 14342 c.options.asNavFor && (l = (l = c.getNavTarget()).slick("getSlick")).slideCount <= l.options.slidesToShow && l.setSlideClasses(c.currentSlide), 14343 c.updateDots(), 14344 c.updateArrows(), 14345 !0 === c.options.fade) 14346 return !0 !== i ? (c.fadeSlideOut(o), 14347 c.fadeSlide(s, function() { 14348 c.postSlide(s) 14349 })) : c.postSlide(s), 14350 void c.animateHeight(); 14351 !0 !== i && c.slideCount > c.options.slidesToShow ? c.animateSlide(a, function() { 14352 c.postSlide(s) 14353 }) : c.postSlide(s) 14354 } 14355 } 14356 , 14357 r.prototype.startLoad = function() { 14358 var t = this; 14359 !0 === t.options.arrows && t.slideCount > t.options.slidesToShow && (t.$prevArrow.hide(), 14360 t.$nextArrow.hide()), 14361 !0 === t.options.dots && t.slideCount > t.options.slidesToShow && t.$dots.hide(), 14362 t.$slider.addClass("slick-loading") 14363 } 14364 , 14365 r.prototype.swipeDirection = function() { 14366 var t, e, i, n; 14367 return t = this.touchObject.startX - this.touchObject.curX, 14368 e = this.touchObject.startY - this.touchObject.curY, 14369 i = Math.atan2(e, t), 14370 (n = Math.round(180 * i / Math.PI)) < 0 && (n = 360 - Math.abs(n)), 14371 n <= 45 && 0 <= n ? !1 === this.options.rtl ? "left" : "right" : n <= 360 && 315 <= n ? !1 === this.options.rtl ? "left" : "right" : 135 <= n && n <= 225 ? !1 === this.options.rtl ? "right" : "left" : !0 === this.options.verticalSwiping ? 35 <= n && n <= 135 ? "down" : "up" : "vertical" 14372 } 14373 , 14374 r.prototype.swipeEnd = function() { 14375 var t, e, i = this; 14376 if (i.dragging = !1, 14377 i.swiping = !1, 14378 i.scrolling) 14379 return i.scrolling = !1; 14380 if (i.interrupted = !1, 14381 i.shouldClick = !(10 < i.touchObject.swipeLength), 14382 void 0 === i.touchObject.curX) 14383 return !1; 14384 if (!0 === i.touchObject.edgeHit && i.$slider.trigger("edge", [i, i.swipeDirection()]), 14385 i.touchObject.swipeLength >= i.touchObject.minSwipe) { 14386 switch (e = i.swipeDirection()) { 14387 case "left": 14388 case "down": 14389 t = i.options.swipeToSlide ? i.checkNavigable(i.currentSlide + i.getSlideCount()) : i.currentSlide + i.getSlideCount(), 14390 i.currentDirection = 0; 14391 break; 14392 case "right": 14393 case "up": 14394 t = i.options.swipeToSlide ? i.checkNavigable(i.currentSlide - i.getSlideCount()) : i.currentSlide - i.getSlideCount(), 14395 i.currentDirection = 1 14396 } 14397 "vertical" != e && (i.slideHandler(t), 14398 i.touchObject = {}, 14399 i.$slider.trigger("swipe", [i, e])) 14400 } else 14401 i.touchObject.startX !== i.touchObject.curX && (i.slideHandler(i.currentSlide), 14402 i.touchObject = {}) 14403 } 14404 , 14405 r.prototype.swipeHandler = function(t) { 14406 var e = this; 14407 if (!(!1 === e.options.swipe || "ontouchend"in document && !1 === e.options.swipe || !1 === e.options.draggable && -1 !== t.type.indexOf("mouse"))) 14408 switch (e.touchObject.fingerCount = t.originalEvent && void 0 !== t.originalEvent.touches ? t.originalEvent.touches.length : 1, 14409 e.touchObject.minSwipe = e.listWidth / e.options.touchThreshold, 14410 !0 === e.options.verticalSwiping && (e.touchObject.minSwipe = e.listHeight / e.options.touchThreshold), 14411 t.data.action) { 14412 case "start": 14413 e.swipeStart(t); 14414 break; 14415 case "move": 14416 e.swipeMove(t); 14417 break; 14418 case "end": 14419 e.swipeEnd(t) 14420 } 14421 } 14422 , 14423 r.prototype.swipeMove = function(t) { 14424 var e, i, n, s, o, r, a = this; 14425 return o = void 0 !== t.originalEvent ? t.originalEvent.touches : null, 14426 !(!a.dragging || a.scrolling || o && 1 !== o.length) && (e = a.getLeft(a.currentSlide), 14427 a.touchObject.curX = void 0 !== o ? o[0].pageX : t.clientX, 14428 a.touchObject.curY = void 0 !== o ? o[0].pageY : t.clientY, 14429 a.touchObject.swipeLength = Math.round(Math.sqrt(Math.pow(a.touchObject.curX - a.touchObject.startX, 2))), 14430 r = Math.round(Math.sqrt(Math.pow(a.touchObject.curY - a.touchObject.startY, 2))), 14431 !a.options.verticalSwiping && !a.swiping && 4 < r ? !(a.scrolling = !0) : (!0 === a.options.verticalSwiping && (a.touchObject.swipeLength = r), 14432 i = a.swipeDirection(), 14433 void 0 !== t.originalEvent && 4 < a.touchObject.swipeLength && (a.swiping = !0, 14434 t.preventDefault()), 14435 s = (!1 === a.options.rtl ? 1 : -1) * (a.touchObject.curX > a.touchObject.startX ? 1 : -1), 14436 !0 === a.options.verticalSwiping && (s = a.touchObject.curY > a.touchObject.startY ? 1 : -1), 14437 n = a.touchObject.swipeLength, 14438 (a.touchObject.edgeHit = !1) === a.options.infinite && (0 === a.currentSlide && "right" === i || a.currentSlide >= a.getDotCount() && "left" === i) && (n = a.touchObject.swipeLength * a.options.edgeFriction, 14439 a.touchObject.edgeHit = !0), 14440 !1 === a.options.vertical ? a.swipeLeft = e + n * s : a.swipeLeft = e + n * (a.$list.height() / a.listWidth) * s, 14441 !0 === a.options.verticalSwiping && (a.swipeLeft = e + n * s), 14442 !0 !== a.options.fade && !1 !== a.options.touchMove && (!0 === a.animating ? (a.swipeLeft = null, 14443 !1) : void a.setCSS(a.swipeLeft)))) 14444 } 14445 , 14446 r.prototype.swipeStart = function(t) { 14447 var e, i = this; 14448 if (i.interrupted = !0, 14449 1 !== i.touchObject.fingerCount || i.slideCount <= i.options.slidesToShow) 14450 return !(i.touchObject = {}); 14451 void 0 !== t.originalEvent && void 0 !== t.originalEvent.touches && (e = t.originalEvent.touches[0]), 14452 i.touchObject.startX = i.touchObject.curX = void 0 !== e ? e.pageX : t.clientX, 14453 i.touchObject.startY = i.touchObject.curY = void 0 !== e ? e.pageY : t.clientY, 14454 i.dragging = !0 14455 } 14456 , 14457 r.prototype.unfilterSlides = r.prototype.slickUnfilter = function() { 14458 null !== this.$slidesCache && (this.unload(), 14459 this.$slideTrack.children(this.options.slide).detach(), 14460 this.$slidesCache.appendTo(this.$slideTrack), 14461 this.reinit()) 14462 } 14463 , 14464 r.prototype.unload = function() { 14465 var t = this; 14466 u(".slick-cloned", t.$slider).remove(), 14467 t.$dots && t.$dots.remove(), 14468 t.$prevArrow && t.htmlExpr.test(t.options.prevArrow) && t.$prevArrow.remove(), 14469 t.$nextArrow && t.htmlExpr.test(t.options.nextArrow) && t.$nextArrow.remove(), 14470 t.$slides.removeClass("slick-slide slick-active slick-visible slick-current").attr("aria-hidden", "true").css("width", "") 14471 } 14472 ,
14473 r.prototype.unslick = function(t) { 14474 this.$slider.trigger("unslick", [this, t]), 14475 this.destroy() 14476 } 14477 , 14478 r.prototype.updateArrows = function() { 14479 var t = this; 14480 Math.floor(t.options.slidesToShow / 2), 14481 !0 === t.options.arrows && t.slideCount > t.options.slidesToShow && !t.options.infinite && (t.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false"), 14482 t.$nextArrow.removeClass("slick-disabled").attr("aria-disabled", "false"), 14483 0 === t.currentSlide ? (t.$prevArrow.addClass("slick-disabled").attr("aria-disabled", "true"), 14484 t.$nextArrow.removeClass("slick-disabled").attr("aria-disabled", "false")) : t.currentSlide >= t.slideCount - t.options.slidesToShow && !1 === t.options.centerMode ? (t.$nextArrow.addClass("slick-disabled").attr("aria-disabled", "true"), 14485 t.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false")) : t.currentSlide >= t.slideCount - 1 && !0 === t.options.centerMode && (t.$nextArrow.addClass("slick-disabled").attr("aria-disabled", "true"), 14486 t.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false"))) 14487 } 14488 , 14489 r.prototype.updateDots = function() { 14490 null !== this.$dots && (this.$dots.find("li").removeClass("slick-active").end(), 14491 this.$dots.find("li").eq(Math.floor(this.currentSlide / this.options.slidesToScroll)).addClass("slick-active")) 14492 } 14493 , 14494 r.prototype.visibility = function() { 14495 this.options.autoplay && (document[this.hidden] ? this.interrupted = !0 : this.interrupted = !1) 14496 } 14497 , 14498 u.fn.slick = function(t) { 14499 var e, i, n = t, s = Array.prototype.slice.call(arguments, 1), o = this.length; 14500 for (e = 0; e < o; e++) 14501 if ("object" == typeof n || void 0 === n ? this[e].slick = new r(this[e],n) : i = this[e].slick[n].apply(this[e].slick, s), 14502 void 0 !== i) 14503 return i; 14504 return this 14505 } 14506}), 14507function(T, t, I) { 14508 "use strict"; 14509 function P(i, n) { 14510 var s = null; 14511 return function() { 14512 var t = this 14513 , e = arguments; 14514 null === s && (s = setTimeout(function() { 14515 i.apply(t, e), 14516 s = null 14517 }, n)) 14518 } 14519 } 14520 var e, o, i = (o = {}, 14521 function(t) { 14522 if (o[t] !== I) 14523 return o[t]; 14524 var e = document.createElement("div").style 14525 , i = t.charAt(0).toUpperCase() + t.slice(1) 14526 , n = (t + " " + ["webkit", "moz", "ms", "o"].join(i + " ") + i).split(" "); 14527 for (var s in n) 14528 if (n[s]in e) 14529 return o[t] = n[s]; 14530 return o[t] = !1 14531 } 14532 ), s = "http://www.w3.org/2000/svg", E = function() { 14533 if (e !== I) 14534 return e; 14535 var t = document.createElement("div"); 14536 return t.innerHTML = "<svg/>", 14537 e = t.firstChild && t.firstChild.namespaceURI === s 14538 }, M = T(t), D = i("transform"), n = { 14539 itemContainer: "ul", 14540 itemSelector: "li", 14541 start: "center", 14542 fadeIn: 400, 14543 loop: !1, 14544 autoplay: !1, 14545 pauseOnHover: !0, 14546 style: "coverflow", 14547 spacing: -.6, 14548 click: !0, 14549 keyboard: !0, 14550 scrollwheel: !0, 14551 touch: !0, 14552 nav: !1, 14553 buttons: !1, 14554 buttonPrev: "Previous", 14555 buttonNext: "Next", 14556 onItemSwitch: !1 14557 }, A = { 14558 main: "flipster", 14559 active: "flipster--active", 14560 container: "flipster__container", 14561 nav: "flipster__nav", 14562 navChild: "flipster__nav__child", 14563 navItem: "flipster__nav__item", 14564 navLink: "flipster__nav__link", 14565 navCurrent: "flipster__nav__item--current", 14566 navCategory: "flipster__nav__item--category", 14567 navCategoryLink: "flipster__nav__link--category", 14568 button: "flipster__button", 14569 buttonPrev: "flipster__button--prev", 14570 buttonNext: "flipster__button--next", 14571 item: "flipster__item", 14572 itemCurrent: "flipster__item--current", 14573 itemPast: "flipster__item--past", 14574 itemFuture: "flipster__item--future", 14575 itemContent: "flipster__item__content" 14576 }, j = new RegExp("\\b(" + A.itemCurrent + "|" + A.itemPast + "|" + A.itemFuture + ")(.*?)(\\s|$)","g"), O = new RegExp("\\s\\s+","g"); 14577 T.fn.flipster = function(e) { 14578 if ("string" == typeof e) { 14579 var i = Array.prototype.slice.call(arguments, 1); 14580 return this.each(function() { 14581 var t = T(this).data("methods"); 14582 return t[e] ? t[e].apply(this, i) : this 14583 }) 14584 } 14585 var S = T.extend({}, n, e); 14586 return this.each(function() { 14587 function t(e) { 14588 return e = e || "next", 14589 T('<button class="' + A.button + " " + ("next" === e ? A.buttonNext : A.buttonPrev) + '" role="button" />').html((t = e,
14590 i = "next" === t ? S.buttonNext : S.buttonPrev, 14591 "custom" !== S.buttons && E ? '<svg viewBox="0 0 13 20" xmlns="' + s + '" aria-labelledby="title"><title>' + i + '</title><polyline points="10,3 3,10 10,17"' + ("next" === t ? ' transform="rotate(180 6.5,10)"' : "") + "/></svg>" : i)).on("click", function(t) { 14592 d(e), 14593 t.preventDefault() 14594 }); 14595 var t, i 14596 } 14597 function o() { 14598 x.css("transition", ""), 14599 y.css("transition", ""), 14600 b.css("transition", "") 14601 } 14602 function h(s) { 14603 var t, e; 14604 (s && (x.css("transition", "none"), 14605 y.css("transition", "none"), 14606 b.css("transition", "none")), 14607 a = y.width(), 14608 y.height((e = 0, 14609 b.each(function() { 14610 (t = T(this).height()) > e && (e = t) 14611 }), 14612 e)), 14613 a) ? (i && (clearInterval(i), 14614 i = !1), 14615 b.each(function(t) { 14616 var e, i, n = T(this); 14617 n.attr("class", function(t, e) { 14618 return e && e.replace(j, "").replace(O, " ") 14619 }), 14620 e = n.outerWidth(), 14621 0 !== S.spacing && n.css("margin-right", e * S.spacing + "px"), 14622 i = n.position().left, 14623 _[t] = -1 * (i + e / 2 - a / 2), 14624 t === b.length - 1 && (r(), 14625 s && setTimeout(o, 1)) 14626 })) : i = i || setInterval(function() { 14627 h(s) 14628 }, 500) 14629 } 14630 function r() { 14631 var e, i, n, s = b.length; 14632 b.each(function(t) { 14633 e = T(this), 14634 i = " ", 14635 t === k ? (i += A.itemCurrent, 14636 n = s + 1) : t < k ? (i += A.itemPast + " " + A.itemPast + "-" + (k - t), 14637 n = s - (k - t)) : (i += A.itemFuture + " " + A.itemFuture + "-" + (t - k), 14638 n = s - (t - k)), 14639 e.css("z-index", n).attr("class", function(t, e) { 14640 return e && e.replace(j, "").replace(O, " ") + i 14641 }) 14642 }), 14643 0 <= k && (a && _[k] !== I || h(!0), 14644 D ? y.css("transform", "translateX(" + _[k] + "px)") : y.css({ 14645 left: _[k] + "px" 14646 })), 14647 function() { 14648 if (S.nav) { 14649 var t = l.data("flip-category"); 14650 u.removeClass(A.navCurrent), 14651 w.filter(function() { 14652 return T(this).data("index") === k || t && T(this).data("category") === t 14653 }).parent().addClass(A.navCurrent) 14654 } 14655 }() 14656 } 14657 function d(t) { 14658 var e = k; 14659 if (!(b.length <= 1)) 14660 return "prev" === t ? 0 < k ? k-- : S.loop && (k = b.length - 1) : "next" === t ? k < b.length - 1 ? k++ : S.loop && (k = 0) : "number" == typeof t ? k = t : t !== I && (k = b.index(t), 14661 S.loop && e != k && (e == b.length - 1 && k != b.length - 2 && (k = 0), 14662 0 == e && 1 != k && (k = b.length - 1))), 14663 l = b.eq(k), 14664 k !== e && S.onItemSwitch && S.onItemSwitch.call(x, b[k], b[e]), 14665 r(), 14666 x 14667 } 14668 function p(t) { 14669 return S.autoplay = t || S.autoplay, 14670 clearInterval(C), 14671 C = setInterval(function() { 14672 var t = k; 14673 d("next"), 14674 t !== k || S.loop || clearInterval(C) 14675 }, S.autoplay), 14676 x 14677 } 14678 function f() { 14679 return clearInterval(C), 14680 C = 0, 14681 x 14682 } 14683 function g(t) { 14684 return f(), 14685 S.autoplay && t && (C = -1), 14686 x 14687 } 14688 function m() { 14689 h(!0), 14690 x.hide().css("visibility", "").addClass(A.active).fadeIn(S.fadeIn) 14691 } 14692 function v() { 14693 if (y = x.find(S.itemContainer).addClass(A.container), 14694 !((b = y.find(S.itemSelector)).length <= 1)) 14695 return b.addClass(A.item).each(function() { 14696 var t = T(this); 14697 t.children("." + A.itemContent).length || t.wrapInner('<div class="' + A.itemContent + '" />') 14698 }), 14699 S.click && b.on("click.flipster touchend.flipster", function(t) { 14700 n || (T(this).hasClass(A.itemCurrent) || t.preventDefault(), 14701 d(this)) 14702 }), 14703 S.buttons && 1 < b.length && (x.find("." + A.button).remove(), 14704 x.append(t("prev"), t("next"))), 14705 a = {}, 14706 !S.nav || b.length <= 1 || (c && c.remove(), 14707 c = T('<ul class="' + A.nav + '" role="navigation" />'), 14708 w = T(""), 14709 b.each(function(t) { 14710 var e = T(this) 14711 , i = e.data("flip-category") 14712 , n = e.data("flip-title") || e.attr("title") || t 14713 , s = T('<a href="#" class="' + A.navLink + '">' + n + "</a>").data("index", t); 14714 if (w = w.add(s), 14715 i) { 14716 if (!a[i]) { 14717 var o = T('<li class="' + A.navItem + " " + A.navCategory + '">') 14718 , r = T('<a href="#" class="' + A.navLink + " " + A.navCategoryLink + '" data-flip-category="' + i + '">' + i + "</a>").data("category", i).data("index", t); 14719 a[i] = T('<ul class="' + A.navChild + '" />'), 14720 w = w.add(r), 14721 o.append(r, a[i]).appendTo(c) 14722 } 14723 a[i].append(s) 14724 } else 14725 c.append(s); 14726 s.wrap('<li class="' + A.navItem + '">') 14727 }), 14728 c.on("click", "a", function(t) { 14729 var e = T(this).data("index"); 14730 0 <= e && (d(e), 14731 t.preventDefault()) 14732 }), 14733 "after" === S.nav ? x.append(c) : x.prepend(c), 14734 u = c.find("." + A.navItem)), 14735 0 <= k && d(k), 14736 x; 14737 var a 14738 } 14739 var e, y, a, i, b, l, c, u, w, x = T(this), _ = [], k = 0, C = !1, n = !1; 14740 e = { 14741 jump: d, 14742 next: function() { 14743 return d("next") 14744 }, 14745 prev: function() { 14746 return d("prev") 14747 }, 14748 play: p, 14749 stop: f, 14750 pause: g, 14751 index: v 14752 }, 14753 x.data("methods", e), 14754 x.hasClass(A.active) || function() { 14755 var t; 14756 if (x.css("visibility", "hidden"), 14757 v(), 14758 b.length <= 1) 14759 x.css("visibility", ""); 14760 else { 14761 t = !!S.style && "flipster--" + S.style.split(" ").join(" flipster--"), 14762 x.addClass([A.main, D ? "flipster--transform" : " flipster--no-transform", t, S.click ? "flipster--click" : ""].join(" ")), 14763 S.start && (k = "center" === S.start ? Math.floor(b.length / 2) : S.start), 14764 d(k); 14765 var e, i, n, s, o, r, a, l, c = x.find("img"); 14766 if (c.length) { 14767 var u = 0; 14768 c.on("load", function() { 14769 ++u >= c.length && m() 14770 }), 14771 setTimeout(m, 750) 14772 } else 14773 m(); 14774 M.on("resize.flipster", P(h, 400)), 14775 S.autoplay && p(), 14776 S.pauseOnHover && y.on("mouseenter.flipster", function() { 14777 C ? g(!0) : f() 14778 }).on("mouseleave.flipster", function() { 14779 -1 === C && p() 14780 }), 14781 l = x, 14782 S.keyboard && (l[0].tabIndex = 0,
14783 l.on("keydown.flipster", P(function(t) { 14784 var e = t.which; 14785 37 !== e && 39 !== e || (d(37 === e ? "prev" : "next"), 14786 t.preventDefault()) 14787 }, 250))), 14788 function(t) { 14789 if (S.scrollwheel) { 14790 var e, i, n = !1, s = 0, o = 0, r = 0, a = /mozilla/.test(navigator.userAgent.toLowerCase()) && !/webkit/.test(navigator.userAgent.toLowerCase()); 14791 t.on("mousewheel.flipster wheel.flipster", function() { 14792 n = !0 14793 }).on("mousewheel.flipster wheel.flipster", P(function(t) { 14794 clearTimeout(o), 14795 o = setTimeout(function() { 14796 r = s = 0 14797 }, 300), 14798 t = t.originalEvent, 14799 r += t.wheelDelta || -1 * (t.deltaY + t.deltaX), 14800 Math.abs(r) < 25 && !a || (s++, 14801 i !== (e = 0 < r ? "prev" : "next") && (s = 0), 14802 i = e, 14803 (s < 6 || s % 3 == 0) && d(e), 14804 r = 0) 14805 }, 50)), 14806 M.on("mousewheel.flipster wheel.flipster", function(t) { 14807 n && (t.preventDefault(), 14808 n = !1) 14809 }) 14810 } 14811 }(y), 14812 e = y, 14813 S.touch && e.on({ 14814 "touchstart.flipster": function(t) { 14815 t = t.originalEvent, 14816 i = t.touches ? t.touches[0].clientX : t.clientX, 14817 n = t.touches ? t.touches[0].clientY : t.clientY 14818 }, 14819 "touchmove.flipster": function(t) { 14820 t = t.originalEvent, 14821 s = t.touches ? t.touches[0].clientX : t.clientX, 14822 o = t.touches ? t.touches[0].clientY : t.clientY, 14823 a = s - i, 14824 r = o - n, 14825 30 < Math.abs(a) && Math.abs(r) < 100 && t.preventDefault() 14826 }, 14827 "touchend.flipster touchcancel.flipster ": function() { 14828 a = s - i, 14829 r = o - n, 14830 30 < Math.abs(a) && Math.abs(r) < 100 && d(0 < a ? "prev" : "next") 14831 } 14832 }) 14833 } 14834 }() 14835 }) 14836 } 14837}(jQuery, window), 14838function(O, p) { 14839 "use strict"; 14840 function r(b, w, x, t, e) { 14841 function i() { 14842 var s, o, r, a; 14843 y = 1 < O.devicePixelRatio, 14844 x = n(x), 14845 0 <= w.delay && setTimeout(function() { 14846 l(!0) 14847 }, w.delay), 14848 (w.delay < 0 || w.combined) && (t.e = (s = w.throttle, 14849 o = function(t) { 14850 "resize" === t.type && (C = S = -1), 14851 l(t.all) 14852 } 14853 , 14854 a = 0, 14855 function(t, e) { 14856 function i() { 14857 a = +new Date, 14858 o.call(b, t) 14859 } 14860 var n = +new Date - a; 14861 r && clearTimeout(r), 14862 s < n || !w.enableThrottle || e ? i() : r = setTimeout(i, s - n) 14863 } 14864 ), 14865 t.a = function(t) { 14866 t = n(t), 14867 x.push.apply(x, t) 14868 } 14869 , 14870 t.g = function() { 14871 return x = z(x).filter(function() { 14872 return !z(this).data(w.loadedName) 14873 }) 14874 } 14875 , 14876 t.f = function(t) { 14877 for (var e = 0; e < t.length; e++) { 14878 var i = x.filter(function() { 14879 return this === t[e] 14880 }); 14881 i.length && l(!1, i) 14882 } 14883 } 14884 , 14885 l(), 14886 z(w.appendScroll).on("scroll." + e + " resize." + e, t.e)) 14887 } 14888 function n(t) { 14889 for (var e = w.defaultImage, i = w.placeholder, n = w.imageBase, s = w.srcsetAttribute, o = w.loaderAttribute, r = w._f || {}, a = 0, l = (t = z(t).filter(function() { 14890 var t = z(this) 14891 , e = k(this); 14892 return !t.data(w.handledName) && (t.attr(w.attribute) || t.attr(s) || t.attr(o) || r[e] !== p) 14893 }).data("plugin_" + w.name, b)).length; a < l; a++) { 14894 var c = z(t[a]) 14895 , u = k(t[a]) 14896 , h = c.attr(w.imageBaseAttribute) || n; 14897 u === E && h && c.attr(s) && c.attr(s, d(c.attr(s), h)), 14898 r[u] === p || c.attr(o) || c.attr(o, r[u]), 14899 u === E && e && !c.attr(M) ? c.attr(M, e) : u === E || !i || c.css(j) && "none" !== c.css(j) || c.css(j, "url('" + i + "')") 14900 } 14901 return t 14902 } 14903 function l(t, e) { 14904 if (x.length) { 14905 for (var i = e || x, n = !1, s = w.imageBase || "", o = w.srcsetAttribute, r = w.handledName, a = 0; a < i.length; a++) 14906 if (t || e || (p = i[a], 14907 void 0, 14908 f = p.getBoundingClientRect(), 14909 g = w.scrollDirection, 14910 m = w.threshold, 14911 v = (0 <= S ? S : S = z(O).height()) + m > f.top && -m < f.bottom, 14912 y = (0 <= C ? C : C = z(O).width()) + m > f.left && -m < f.right, 14913 "vertical" === g ? v : "horizontal" === g ? y : v && y)) { 14914 var l = z(i[a]) 14915 , c = k(i[a]) 14916 , u = l.attr(w.attribute) 14917 , h = l.attr(w.imageBaseAttribute) || s 14918 , d = l.attr(w.loaderAttribute); 14919 l.data(r) || w.visibleOnly && !l.is(":visible") || !((u || l.attr(o)) && (c === E && (h + u !== l.attr(M) || l.attr(o) !== l.attr(D)) || c !== E && h + u !== l.css(j)) || d) || (n = !0, 14920 l.data(r, !0), 14921 _(l, c, h, d)) 14922 } 14923 var p, f, g, m, v, y; 14924 n && (x = z(x).filter(function() { 14925 return !z(this).data(r) 14926 })) 14927 } else 14928 w.autoDestroy && b.destroy() 14929 } 14930 function _(e, t, i, n) { 14931 ++v; 14932 var s = function() { 14933 m("onError", e), 14934 g(), 14935 s = z.noop 14936 }; 14937 m("beforeLoad", e); 14938 var o = w.attribute 14939 , r = w.srcsetAttribute 14940 , a = w.sizesAttribute 14941 , l = w.retinaAttribute 14942 , c = w.removeAttribute 14943 , u = w.loadedName
14944 , h = e.attr(l); 14945 if (n) { 14946 var d = function() { 14947 c && e.removeAttr(w.loaderAttribute), 14948 e.data(u, !0), 14949 m(T, e), 14950 setTimeout(g, 1), 14951 d = z.noop 14952 }; 14953 e.off(P).one(P, s).one(I, d), 14954 m(n, e, function(t) { 14955 t ? (e.off(I), 14956 d()) : (e.off(P), 14957 s()) 14958 }) || e.trigger(P) 14959 } else { 14960 var p = z(new Image); 14961 p.one(P, s).one(I, function() { 14962 e.hide(), 14963 t === E ? e.attr(A, p.attr(A)).attr(D, p.attr(D)).attr(M, p.attr(M)) : e.css(j, "url('" + p.attr(M) + "')"), 14964 e[w.effect](w.effectTime), 14965 c && (e.removeAttr(o + " " + r + " " + l + " " + w.imageBaseAttribute), 14966 a !== A && e.removeAttr(a)), 14967 e.data(u, !0), 14968 m(T, e), 14969 p.remove(), 14970 g() 14971 }); 14972 var f = (y && h ? h : e.attr(o)) || ""; 14973 p.attr(A, e.attr(a)).attr(D, e.attr(r)).attr(M, f ? i + f : null), 14974 p.complete && p.trigger(I) 14975 } 14976 } 14977 function k(t) { 14978 return t.tagName.toLowerCase() 14979 } 14980 function d(t, e) { 14981 if (e) { 14982 var i = t.split(","); 14983 t = ""; 14984 for (var n = 0, s = i.length; n < s; n++) 14985 t += e + i[n].trim() + (n !== s - 1 ? "," : "") 14986 } 14987 return t 14988 } 14989 function g() { 14990 --v, 14991 x.length || v || m("onFinishedAll") 14992 } 14993 function m(t) { 14994 return !!(t = w[t]) && (t.apply(b, [].slice.call(arguments, 1)), 14995 !0) 14996 } 14997 var v = 0 14998 , C = -1 14999 , S = -1 15000 , y = !1 15001 , T = "afterLoad" 15002 , I = "load" 15003 , P = "error" 15004 , E = "img" 15005 , M = "src" 15006 , D = "srcset" 15007 , A = "sizes" 15008 , j = "background-image"; 15009 "event" === w.bind || s ? i() : z(O).on(I + "." + e, i) 15010 } 15011 function c(t, e) { 15012 var i = this 15013 , n = z.extend({}, i.config, e) 15014 , s = {} 15015 , o = n.name + "-" + ++a; 15016 return i.config = function(t, e) { 15017 return e === p ? n[t] : (n[t] = e, 15018 i) 15019 } 15020 , 15021 i.addItems = function(t) { 15022 return s.a && s.a("string" === z.type(t) ? z(t) : t), 15023 i 15024 } 15025 , 15026 i.getItems = function() { 15027 return s.g ? s.g() : {} 15028 } 15029 , 15030 i.update = function(t) { 15031 return s.e && s.e({}, !t), 15032 i 15033 } 15034 , 15035 i.force = function(t) { 15036 return s.f && s.f("string" === z.type(t) ? z(t) : t), 15037 i 15038 } 15039 , 15040 i.loadAll = function() { 15041 return s.e && s.e({ 15042 all: !0 15043 }, !0), 15044 i 15045 } 15046 , 15047 i.destroy = function() { 15048 return z(n.appendScroll).off("." + o, s.e), 15049 z(O).off("." + o), 15050 s = {}, 15051 p 15052 } 15053 , 15054 r(i, n, t, s, o), 15055 n.chainable ? t : i 15056 } 15057 var z = O.jQuery || O.Zepto 15058 , a = 0 15059 , s = !1; 15060 z.fn.Lazy = z.fn.lazy = function(t) { 15061 return new c(this,t) 15062 } 15063 , 15064 z.Lazy = z.lazy = function(t, e, i) { 15065 if (z.isFunction(e) && (i = e, 15066 e = []), 15067 z.isFunction(i)) { 15068 t = z.isArray(t) ? t : [t], 15069 e = z.isArray(e) ? e : [e]; 15070 for (var n = c.prototype.config, s = n._f || (n._f = {}), o = 0, r = t.length; o < r; o++) 15071 (n[t[o]] === p || z.isFunction(n[t[o]])) && (n[t[o]] = i); 15072 for (var a = 0, l = e.length; a < l; a++) 15073 s[e[a]] = t[0] 15074 } 15075 } 15076 , 15077 c.prototype.config = { 15078 name: "lazy", 15079 chainable: !0, 15080 autoDestroy: !0, 15081 bind: "load", 15082 threshold: 500, 15083 visibleOnly: !1, 15084 appendScroll: O, 15085 scrollDirection: "both", 15086 imageBase: null, 15087 defaultImage: "data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==", 15088 placeholder: null, 15089 delay: -1, 15090 combined: !1, 15091 attribute: "data-src", 15092 srcsetAttribute: "data-srcset", 15093 sizesAttribute: "data-sizes", 15094 retinaAttribute: "data-retina", 15095 loaderAttribute: "data-loader", 15096 imageBaseAttribute: "data-imagebase", 15097 removeAttribute: !0, 15098 handledName: "handled", 15099 loadedName: "loaded", 15100 effect: "show", 15101 effectTime: 0, 15102 enableThrottle: !0, 15103 throttle: 250, 15104 beforeLoad: p, 15105 afterLoad: p, 15106 onError: p, 15107 onFinishedAll: p 15108 }, 15109 z(O).on("load", function() { 15110 s = !0 15111 }) 15112}(window), 15113function(a) { 15114 function n(t, e) { 15115 var i, n, s, o = t.nodeName.toLowerCase(); 15116 return "area" === o ? (n = (i = t.parentNode).name, 15117 !(!t.href || !n || "map" !== i.nodeName.toLowerCase()) && (!!(s = a("img[usemap=#" + n + "]")[0]) && r(s))) : (/input|select|textarea|button|object/.test(o) ? !t.disabled : "a" === o && t.href || e) && r(t) 15118 } 15119 function r(t) { 15120 return !a(t).parents().andSelf().filter(function() { 15121 return "hidden" === a.css(this, "visibility") || a.expr.filters.hidden(this) 15122 }).length 15123 } 15124 var t = 0 15125 , e = /^ui-id-\d+$/; 15126 a.ui = a.ui || {}, 15127 a.ui.version || (a.extend(a.ui, { 15128 version: "1.9.0", 15129 keyCode: { 15130 BACKSPACE: 8, 15131 COMMA: 188, 15132 DELETE: 46, 15133 DOWN: 40, 15134 END: 35, 15135 ENTER: 13, 15136 ESCAPE: 27, 15137 HOME: 36, 15138 LEFT: 37, 15139 NUMPAD_ADD: 107, 15140 NUMPAD_DECIMAL: 110, 15141 NUMPAD_DIVIDE: 111, 15142 NUMPAD_ENTER: 108, 15143 NUMPAD_MULTIPLY: 106, 15144 NUMPAD_SUBTRACT: 109, 15145 PAGE_DOWN: 34, 15146 PAGE_UP: 33, 15147 PERIOD: 190, 15148 RIGHT: 39, 15149 SPACE: 32, 15150 TAB: 9, 15151 UP: 38 15152 } 15153 }), 15154 a.fn.extend({ 15155 _focus: a.fn.focus, 15156 focus: function(e, i) { 15157 return "number" == typeof e ? this.each(function() { 15158 var t = this; 15159 setTimeout(function() { 15160 a(t).focus(), 15161 i && i.call(t) 15162 }, e) 15163 }) : this._focus.apply(this, arguments) 15164 }, 15165 scrollParent: function() { 15166 var t; 15167 return t = a.browser.msie && /(static|relative)/.test(this.css("position")) || /absolute/.test(this.css("position")) ? this.parents().filter(function() { 15168 return /(relative|absolute|fixed)/.test(a.css(this, "position")) && /(auto|scroll)/.test(a.css(this, "overflow") + a.css(this, "overflow-y") + a.css(this, "overflow-x")) 15169 }).eq(0) : this.parents().filter(function() { 15170 return /(auto|scroll)/.test(a.css(this, "overflow") + a.css(this, "overflow-y") + a.css(this, "overflow-x")) 15171 }).eq(0), 15172 /fixed/.test(this.css("position")) || !t.length ? a(document) : t 15173 }, 15174 zIndex: function(t) { 15175 if (void 0 !== t) 15176 return this.css("zIndex", t); 15177 if (this.length) 15178 for (var e, i, n = a(this[0]); n.length && n[0] !== document; ) { 15179 if (("absolute" === (e = n.css("position")) || "relative" === e || "fixed" === e) && (i = parseInt(n.css("zIndex"), 10), 15180 !isNaN(i) && 0 !== i)) 15181 return i; 15182 n = n.parent() 15183 } 15184 return 0 15185 }, 15186 uniqueId: function() { 15187 return this.each(function() { 15188 this.id || (this.id = "ui-id-" + ++t) 15189 }) 15190 }, 15191 removeUniqueId: function() { 15192 return this.each(function() {
15193 e.test(this.id) && a(this).removeAttr("id") 15194 }) 15195 } 15196 }), 15197 a("<a>").outerWidth(1).jquery || a.each(["Width", "Height"], function(t, i) { 15198 function n(t, e, i, n) { 15199 return a.each(s, function() { 15200 e -= parseFloat(a.css(t, "padding" + this)) || 0, 15201 i && (e -= parseFloat(a.css(t, "border" + this + "Width")) || 0), 15202 n && (e -= parseFloat(a.css(t, "margin" + this)) || 0) 15203 }), 15204 e 15205 } 15206 var s = "Width" === i ? ["Left", "Right"] : ["Top", "Bottom"] 15207 , o = i.toLowerCase() 15208 , r = { 15209 innerWidth: a.fn.innerWidth, 15210 innerHeight: a.fn.innerHeight, 15211 outerWidth: a.fn.outerWidth, 15212 outerHeight: a.fn.outerHeight 15213 }; 15214 a.fn["inner" + i] = function(t) { 15215 return void 0 === t ? r["inner" + i].call(this) : this.each(function() { 15216 a(this).css(o, n(this, t) + "px") 15217 }) 15218 } 15219 , 15220 a.fn["outer" + i] = function(t, e) { 15221 return "number" != typeof t ? r["outer" + i].call(this, t) : this.each(function() { 15222 a(this).css(o, n(this, t, !0, e) + "px") 15223 }) 15224 } 15225 }), 15226 a.extend(a.expr[":"], { 15227 data: a.expr.createPseudo ? a.expr.createPseudo(function(e) { 15228 return function(t) { 15229 return !!a.data(t, e) 15230 } 15231 }) : function(t, e, i) { 15232 return !!a.data(t, i[3]) 15233 } 15234 , 15235 focusable: function(t) { 15236 return n(t, !isNaN(a.attr(t, "tabindex"))) 15237 }, 15238 tabbable: function(t) { 15239 var e = a.attr(t, "tabindex") 15240 , i = isNaN(e); 15241 return (i || 0 <= e) && n(t, !i) 15242 } 15243 }), 15244 a(function() { 15245 var t = document.body 15246 , e = t.appendChild(e = document.createElement("div")); 15247 e.offsetHeight, 15248 a.extend(e.style, { 15249 minHeight: "100px", 15250 height: "auto", 15251 padding: 0, 15252 borderWidth: 0 15253 }), 15254 a.support.minHeight = 100 === e.offsetHeight, 15255 a.support.selectstart = "onselectstart"in e, 15256 t.removeChild(e).style.display = "none" 15257 }), 15258 a.fn.extend({ 15259 disableSelection: function() { 15260 return this.bind((a.support.selectstart ? "selectstart" : "mousedown") + ".ui-disableSelection", function(t) { 15261 t.preventDefault() 15262 }) 15263 }, 15264 enableSelection: function() { 15265 return this.unbind(".ui-disableSelection") 15266 } 15267 }), 15268 a.extend(a.ui, { 15269 plugin: { 15270 add: function(t, e, i) { 15271 var n, s = a.ui[t].prototype; 15272 for (n in i) 15273 s.plugins[n] = s.plugins[n] || [], 15274 s.plugins[n].push([e, i[n]]) 15275 }, 15276 call: function(t, e, i) { 15277 var n, s = t.plugins[e]; 15278 if (s && t.element[0].parentNode && 11 !== t.element[0].parentNode.nodeType) 15279 for (n = 0; n < s.length; n++) 15280 t.options[s[n][0]] && s[n][1].apply(t.element, i) 15281 } 15282 }, 15283 contains: a.contains, 15284 hasScroll: function(t, e) { 15285 if ("hidden" === a(t).css("overflow")) 15286 return !1; 15287 var i, n = e && "left" === e ? "scrollLeft" : "scrollTop"; 15288 return 0 < t[n] || (t[n] = 1, 15289 i = 0 < t[n], 15290 t[n] = 0, 15291 i) 15292 }, 15293 isOverAxis: function(t, e, i) { 15294 return e < t && t < e + i 15295 }, 15296 isOver: function(t, e, i, n, s, o) { 15297 return a.ui.isOverAxis(t, i, s) && a.ui.isOverAxis(e, n, o) 15298 } 15299 })) 15300}(jQuery), 15301function(l, a) { 15302 var i = 0 15303 , c = Array.prototype.slice 15304 , n = l.cleanData; 15305 l.cleanData = function(t) { 15306 for (var e, i = 0; null != (e = t[i]); i++) 15307 try { 15308 l(e).triggerHandler("remove") 15309 } catch (t) {} 15310 n(t) 15311 } 15312 , 15313 l.widget = function(t, i, r) { 15314 var e, n, s, o, a = t.split(".")[0]; 15315 t = t.split(".")[1], 15316 e = a + "-" + t, 15317 r || (r = i, 15318 i = l.Widget), 15319 l.expr[":"][e.toLowerCase()] = function(t) { 15320 return !!l.data(t, e) 15321 } 15322 , 15323 l[a] = l[a] || {}, 15324 n = l[a][t], 15325 s = l[a][t] = function(t, e) { 15326 if (!this._createWidget) 15327 return new s(t,e); 15328 arguments.length && this._createWidget(t, e) 15329 } 15330 , 15331 l.extend(s, n, { 15332 version: r.version, 15333 _proto: l.extend({}, r), 15334 _childConstructors: [] 15335 }), 15336 (o = new i).options = l.widget.extend({}, o.options), 15337 l.each(r, function(e, n) { 15338 var s, o; 15339 l.isFunction(n) && (r[e] = (s = function() { 15340 return i.prototype[e].apply(this, arguments) 15341 } 15342 , 15343 o = function(t) { 15344 return i.prototype[e].apply(this, t) 15345 } 15346 , 15347 function() { 15348 var t, e = this._super, i = this._superApply; 15349 return this._super = s, 15350 this._superApply = o, 15351 t = n.apply(this, arguments), 15352 this._super = e, 15353 this._superApply = i, 15354 t 15355 } 15356 )) 15357 }), 15358 s.prototype = l.widget.extend(o, { 15359 widgetEventPrefix: t 15360 }, r, { 15361 constructor: s, 15362 namespace: a, 15363 widgetName: t, 15364 widgetBaseClass: e, 15365 widgetFullName: e 15366 }), 15367 n ? (l.each(n._childConstructors, function(t, e) { 15368 var i = e.prototype; 15369 l.widget(i.namespace + "." + i.widgetName, s, e._proto) 15370 }), 15371 delete n._childConstructors) : i._childConstructors.push(s), 15372 l.widget.bridge(t, s) 15373 } 15374 , 15375 l.widget.extend = function(t) { 15376 for (var e, i, n = c.call(arguments, 1), s = 0, o = n.length; s < o; s++) 15377 for (e in n[s]) 15378 i = n[s][e], 15379 n[s].hasOwnProperty(e) && i !== a && (t[e] = l.isPlainObject(i) ? l.widget.extend({}, t[e], i) : i); 15380 return t 15381 } 15382 , 15383 l.widget.bridge = function(o, e) { 15384 var r = e.prototype.widgetFullName; 15385 l.fn[o] = function(i) { 15386 var t = "string" == typeof i 15387 , n = c.call(arguments, 1) 15388 , s = this; 15389 return i = !t && n.length ? l.widget.extend.apply(null, [i].concat(n)) : i, 15390 t ? this.each(function() { 15391 var t, e = l.data(this, r); 15392 return e ? l.isFunction(e[i]) && "_" !== i.charAt(0) ? (t = e[i].apply(e, n)) !== e && t !== a ? (s = t && t.jquery ? s.pushStack(t.get()) : t, 15393 !1) : void 0 : l.error("no such method '" + i + "' for " + o + " widget instance") : l.error("cannot call methods on " + o + " prior to initialization; attempted to call method '" + i + "'") 15394 }) : this.each(function() { 15395 var t = l.data(this, r); 15396 t ? t.option(i || {})._init() : new e(i,this) 15397 }), 15398 s 15399 } 15400 } 15401 , 15402 l.Widget = function() {} 15403 , 15404 l.Widget._childConstructors = [], 15405 l.Widget.prototype = { 15406 widgetName: "widget", 15407 widgetEventPrefix: "", 15408 defaultElement: "<div>", 15409 options: { 15410 disabled: !1, 15411 create: null 15412 }, 15413 _createWidget: function(t, e) { 15414 e = l(e || this.defaultElement || this)[0], 15415 this.element = l(e), 15416 this.uuid = i++, 15417 this.eventNamespace = "." + this.widgetName + this.uuid, 15418 this.options = l.widget.extend({}, this.options, this._getCreateOptions(), t), 15419 this.bindings = l(), 15420 this.hoverable = l(), 15421 this.focusable = l(), 15422 e !== this && (l.data(e, this.widgetName, this), 15423 l.data(e, this.widgetFullName, this), 15424 this._on({ 15425 remove: "destroy" 15426 }), 15427 this.document = l(e.style ? e.ownerDocument : e.document || e), 15428 this.window = l(this.document[0].defaultView || this.document[0].parentWindow)), 15429 this._create(), 15430 this._trigger("create", null, this._getCreateEventData()), 15431 this._init() 15432 }, 15433 _getCreateOptions: l.noop, 15434 _getCreateEventData: l.noop, 15435 _create: l.noop, 15436 _init: l.noop, 15437 destroy: function() { 15438 this._destroy(), 15439 this.element.unbind(this.eventNamespace).removeData(this.widgetName).removeData(this.widgetFullName).removeData(l.camelCase(this.widgetFullName)), 15440 this.widget().unbind(this.eventNamespace).removeAttr("aria-disabled").removeClass(this.widgetFullName + "-disabled ui-state-disabled"), 15441 this.bindings.unbind(this.eventNamespace), 15442 this.hoverable.removeClass("ui-state-hover"), 15443 this.focusable.removeClass("ui-state-focus") 15444 }, 15445 _destroy: l.noop, 15446 widget: function() { 15447 return this.element 15448 }, 15449 option: function(t, e) { 15450 var i, n, s, o = t; 15451 if (0 === arguments.length) 15452 return l.widget.extend({}, this.options); 15453 if ("string" == typeof t) 15454 if (o = {}, 15455 t = (i = t.split(".")).shift(), 15456 i.length) { 15457 for (n = o[t] = l.widget.extend({}, this.options[t]), 15458 s = 0; s < i.length - 1; s++) 15459 n[i[s]] = n[i[s]] || {}, 15460 n = n[i[s]]; 15461 if (t = i.pop(), 15462 e === a) 15463 return n[t] === a ? null : n[t]; 15464 n[t] = e 15465 } else { 15466 if (e === a) 15467 return this.options[t] === a ? null : this.options[t]; 15468 o[t] = e 15469 } 15470 return this._setOptions(o), 15471 this 15472 }, 15473 _setOptions: function(t) { 15474 var e; 15475 for (e in t) 15476 this._setOption(e, t[e]); 15477 return this 15478 }, 15479 _setOption: function(t, e) { 15480 return this.options[t] = e, 15481 "disabled" === t && (this.widget().toggleClass(this.widgetFullName + "-disabled ui-state-disabled", !!e).attr("aria-disabled", e), 15482 this.hoverable.removeClass("ui-state-hover"), 15483 this.focusable.removeClass("ui-state-focus")), 15484 this 15485 }, 15486 enable: function() { 15487 return this._setOption("disabled", !1) 15488 }, 15489 disable: function() { 15490 return this._setOption("disabled", !0) 15491 }, 15492 _on: function(r, t) { 15493 t ? (r = l(r), 15494 this.bindings = this.bindings.add(r)) : (t = r, 15495 r = this.element); 15496 var a = this; 15497 l.each(t, function(t, e) { 15498 function i() { 15499 if (!0 !== a.options.disabled && !l(this).hasClass("ui-state-disabled"))
15500 return ("string" == typeof e ? a[e] : e).apply(a, arguments) 15501 } 15502 "string" != typeof e && (i.guid = e.guid = e.guid || i.guid || l.guid++); 15503 var n = t.match(/^(\w+)\s*(.*)$/) 15504 , s = n[1] + a.eventNamespace 15505 , o = n[2]; 15506 o ? a.widget().delegate(o, s, i) : r.bind(s, i) 15507 }) 15508 }, 15509 _off: function(t, e) { 15510 e = (e || "").split(" ").join(this.eventNamespace + " ") + this.eventNamespace, 15511 t.unbind(e).undelegate(e) 15512 }, 15513 _delay: function(t, e) { 15514 var i = this; 15515 return setTimeout(function() { 15516 return ("string" == typeof t ? i[t] : t).apply(i, arguments) 15517 }, e || 0) 15518 }, 15519 _hoverable: function(t) { 15520 this.hoverable = this.hoverable.add(t), 15521 this._on(t, { 15522 mouseenter: function(t) { 15523 l(t.currentTarget).addClass("ui-state-hover") 15524 }, 15525 mouseleave: function(t) { 15526 l(t.currentTarget).removeClass("ui-state-hover") 15527 } 15528 }) 15529 }, 15530 _focusable: function(t) { 15531 this.focusable = this.focusable.add(t), 15532 this._on(t, { 15533 focusin: function(t) { 15534 l(t.currentTarget).addClass("ui-state-focus") 15535 }, 15536 focusout: function(t) { 15537 l(t.currentTarget).removeClass("ui-state-focus") 15538 } 15539 }) 15540 }, 15541 _trigger: function(t, e, i) { 15542 var n, s, o = this.options[t]; 15543 if (i = i || {}, 15544 (e = l.Event(e)).type = (t === this.widgetEventPrefix ? t : this.widgetEventPrefix + t).toLowerCase(), 15545 e.target = this.element[0], 15546 s = e.originalEvent) 15547 for (n in s) 15548 n in e || (e[n] = s[n]); 15549 return this.element.trigger(e, i), 15550 !(l.isFunction(o) && !1 === o.apply(this.element[0], [e].concat(i)) || e.isDefaultPrevented()) 15551 } 15552 }, 15553 l.each({ 15554 show: "fadeIn", 15555 hide: "fadeOut" 15556 }, function(o, r) { 15557 l.Widget.prototype["_" + o] = function(e, t, i) { 15558 "string" == typeof t && (t = { 15559 effect: t 15560 }); 15561 var n, s = t ? !0 === t || "number" == typeof t ? r : t.effect || r : o; 15562 "number" == typeof (t = t || {}) && (t = { 15563 duration: t 15564 }), 15565 n = !l.isEmptyObject(t), 15566 t.complete = i, 15567 t.delay && e.delay(t.delay), 15568 n && l.effects && (l.effects.effect[s] || !1 !== l.uiBackCompat && l.effects[s]) ? e[o](t) : s !== o && e[s] ? e[s](t.duration, t.easing, i) : e.queue(function(t) { 15569 l(this)[o](), 15570 i && i.call(e[0]), 15571 t() 15572 }) 15573 } 15574 }), 15575 !1 !== l.uiBackCompat && (l.Widget.prototype._getCreateOptions = function() { 15576 return l.metadata && l.metadata.get(this.element[0])[this.widgetName] 15577 } 15578 ) 15579}(jQuery), 15580function(s) { 15581 var o = !1; 15582 s(document).mouseup(function() { 15583 o = !1 15584 }), 15585 s.widget("ui.mouse", { 15586 version: "1.9.0", 15587 options: { 15588 cancel: "input,textarea,button,select,option", 15589 distance: 1, 15590 delay: 0 15591 }, 15592 _mouseInit: function() { 15593 var e = this; 15594 this.element.bind("mousedown." + this.widgetName, function(t) { 15595 return e._mouseDown(t) 15596 }).bind("click." + this.widgetName, function(t) { 15597 if (!0 === s.data(t.target, e.widgetName + ".preventClickEvent")) 15598 return s.removeData(t.target, e.widgetName + ".preventClickEvent"), 15599 t.stopImmediatePropagation(), 15600 !1 15601 }), 15602 this.started = !1 15603 }, 15604 _mouseDestroy: function() { 15605 this.element.unbind("." + this.widgetName), 15606 this._mouseMoveDelegate && s(document).unbind("mousemove." + this.widgetName, this._mouseMoveDelegate).unbind("mouseup." + this.widgetName, this._mouseUpDelegate) 15607 }, 15608 _mouseDown: function(t) { 15609 if (!o) { 15610 this._mouseStarted && this._mouseUp(t), 15611 this._mouseDownEvent = t; 15612 var e = this 15613 , i = 1 === t.which 15614 , n = !("string" != typeof this.options.cancel || !t.target.nodeName) && s(t.target).closest(this.options.cancel).length; 15615 return !(i && !n && this._mouseCapture(t)) || (this.mouseDelayMet = !this.options.delay, 15616 this.mouseDelayMet || (this._mouseDelayTimer = setTimeout(function() { 15617 e.mouseDelayMet = !0 15618 }, this.options.delay)), 15619 this._mouseDistanceMet(t) && this._mouseDelayMet(t) && (this._mouseStarted = !1 !== this._mouseStart(t), 15620 !this._mouseStarted) ? (t.preventDefault(), 15621 !0) : (!0 === s.data(t.target, this.widgetName + ".preventClickEvent") && s.removeData(t.target, this.widgetName + ".preventClickEvent"), 15622 this._mouseMoveDelegate = function(t) { 15623 return e._mouseMove(t) 15624 } 15625 , 15626 this._mouseUpDelegate = function(t) { 15627 return e._mouseUp(t) 15628 } 15629 , 15630 s(document).bind("mousemove." + this.widgetName, this._mouseMoveDelegate).bind("mouseup." + this.widgetName, this._mouseUpDelegate), 15631 t.preventDefault(), 15632 o = !0)) 15633 } 15634 }, 15635 _mouseMove: function(t) { 15636 return !s.browser.msie || 9 <= document.documentMode || t.button ? this._mouseStarted ? (this._mouseDrag(t), 15637 t.preventDefault()) : (this._mouseDistanceMet(t) && this._mouseDelayMet(t) && (this._mouseStarted = !1 !== this._mouseStart(this._mouseDownEvent, t), 15638 this._mouseStarted ? this._mouseDrag(t) : this._mouseUp(t)), 15639 !this._mouseStarted) : this._mouseUp(t) 15640 }, 15641 _mouseUp: function(t) { 15642 return s(document).unbind("mousemove." + this.widgetName, this._mouseMoveDelegate).unbind("mouseup." + this.widgetName, this._mouseUpDelegate), 15643 this._mouseStarted && (this._mouseStarted = !1, 15644 t.target === this._mouseDownEvent.target && s.data(t.target, this.widgetName + ".preventClickEvent", !0), 15645 this._mouseStop(t)), 15646 !1 15647 }, 15648 _mouseDistanceMet: function(t) { 15649 return Math.max(Math.abs(this._mouseDownEvent.pageX - t.pageX), Math.abs(this._mouseDownEvent.pageY - t.pageY)) >= this.options.distance 15650 }, 15651 _mouseDelayMet: function() { 15652 return this.mouseDelayMet 15653 }, 15654 _mouseStart: function() {}, 15655 _mouseDrag: function() {}, 15656 _mouseStop: function() {}, 15657 _mouseCapture: function() { 15658 return !0 15659 } 15660 }) 15661}(jQuery), 15662function(b) { 15663 b.widget("ui.draggable", b.ui.mouse, { 15664 version: "1.9.0", 15665 widgetEventPrefix: "drag", 15666 options: { 15667 addClasses: !0, 15668 appendTo: "parent", 15669 axis: !1, 15670 connectToSortable: !1, 15671 containment: !1, 15672 cursor: "auto", 15673 cursorAt: !1, 15674 grid: !1, 15675 handle: !1, 15676 helper: "original", 15677 iframeFix: !1, 15678 opacity: !1, 15679 refreshPositions: !1, 15680 revert: !1, 15681 revertDuration: 500, 15682 scope: "default", 15683 scroll: !0, 15684 scrollSensitivity: 20, 15685 scrollSpeed: 20, 15686 snap: !1, 15687 snapMode: "both", 15688 snapTolerance: 20, 15689 stack: !1, 15690 zIndex: !1 15691 }, 15692 _create: function() { 15693 "original" != this.options.helper || /^(?:r|a|f)/.test(this.element.css("position")) || (this.element[0].style.position = "relative"), 15694 this.options.addClasses && this.element.addClass("ui-draggable"), 15695 this.options.disabled && this.element.addClass("ui-draggable-disabled"), 15696 this._mouseInit() 15697 }, 15698 _destroy: function() { 15699 this.element.removeClass("ui-draggable ui-draggable-dragging ui-draggable-disabled"), 15700 this._mouseDestroy() 15701 }, 15702 _mouseCapture: function(t) { 15703 var e = this.options; 15704 return !(this.helper || e.disabled || b(t.target).is(".ui-resizable-handle")) && (this.handle = this._getHandle(t), 15705 !!this.handle && (b(!0 === e.iframeFix ? "iframe" : e.iframeFix).each(function() { 15706 b('<div class="ui-draggable-iframeFix" style="background: #fff;"></div>').css({ 15707 width: this.offsetWidth + "px", 15708 height: this.offsetHeight + "px", 15709 position: "absolute", 15710 opacity: "0.001", 15711 zIndex: 1e3 15712 }).css(b(this).offset()).appendTo("body") 15713 }), 15714 !0)) 15715 }, 15716 _mouseStart: function(t) { 15717 var e = this.options; 15718 return this.helper = this._createHelper(t), 15719 this.helper.addClass("ui-draggable-dragging"), 15720 this._cacheHelperProportions(), 15721 b.ui.ddmanager && (b.ui.ddmanager.current = this), 15722 this._cacheMargins(), 15723 this.cssPosition = this.helper.css("position"), 15724 this.scrollParent = this.helper.scrollParent(), 15725 this.offset = this.positionAbs = this.element.offset(), 15726 this.offset = { 15727 top: this.offset.top - this.margins.top, 15728 left: this.offset.left - this.margins.left 15729 }, 15730 b.extend(this.offset, { 15731 click: { 15732 left: t.pageX - this.offset.left, 15733 top: t.pageY - this.offset.top 15734 }, 15735 parent: this._getParentOffset(), 15736 relative: this._getRelativeOffset() 15737 }), 15738 this.originalPosition = this.position = this._generatePosition(t), 15739 this.originalPageX = t.pageX, 15740 this.originalPageY = t.pageY, 15741 e.cursorAt && this._adjustOffsetFromHelper(e.cursorAt), 15742 e.containment && this._setContainment(), 15743 !1 === this._trigger("start", t) ? (this._clear(), 15744 !1) : (this._cacheHelperProportions(), 15745 b.ui.ddmanager && !e.dropBehaviour && b.ui.ddmanager.prepareOffsets(this, t), 15746 this._mouseDrag(t, !0), 15747 b.ui.ddmanager && b.ui.ddmanager.dragStart(this, t), 15748 !0) 15749 }, 15750 _mouseDrag: function(t, e) { 15751 if (this.position = this._generatePosition(t), 15752 this.positionAbs = this._convertPositionTo("absolute"), 15753 !e) { 15754 var i = this._uiHash(); 15755 if (!1 === this._trigger("drag", t, i)) 15756 return this._mouseUp({}), 15757 !1; 15758 this.position = i.position 15759 } 15760 return this.options.axis && "y" == this.options.axis || (this.helper[0].style.left = this.position.left + "px"), 15761 this.options.axis && "x" == this.options.axis || (this.helper[0].style.top = this.position.top + "px"), 15762 b.ui.ddmanager && b.ui.ddmanager.drag(this, t), 15763 !1 15764 }, 15765 _mouseStop: function(t) { 15766 var e = !1; 15767 b.ui.ddmanager && !this.options.dropBehaviour && (e = b.ui.ddmanager.drop(this, t)), 15768 this.dropped && (e = this.dropped, 15769 this.dropped = !1); 15770 for (var i = this.element[0], n = !1; i && (i = i.parentNode); ) 15771 i == document && (n = !0); 15772 if (!n && "original" === this.options.helper) 15773 return !1; 15774 if ("invalid" == this.options.revert && !e || "valid" == this.options.revert && e || !0 === this.options.revert || b.isFunction(this.options.revert) && this.options.revert.call(this.element, e)) { 15775 var s = this; 15776 b(this.helper).animate(this.originalPosition, parseInt(this.options.revertDuration, 10), function() { 15777 !1 !== s._trigger("stop", t) && s._clear() 15778 }) 15779 } else 15780 !1 !== this._trigger("stop", t) && this._clear(); 15781 return !1 15782 }, 15783 _mouseUp: function(t) { 15784 return b("div.ui-draggable-iframeFix").each(function() { 15785 this.parentNode.removeChild(this) 15786 }), 15787 b.ui.ddmanager && b.ui.ddmanager.dragStop(this, t), 15788 b.ui.mouse.prototype._mouseUp.call(this, t) 15789 }, 15790 cancel: function() { 15791 return this.helper.is(".ui-draggable-dragging") ? this._mouseUp({}) : this._clear(), 15792 this 15793 }, 15794 _getHandle: function(t) { 15795 var e = !this.options.handle || !b(this.options.handle, this.element).length; 15796 return b(this.options.handle, this.element).find("*").andSelf().each(function() { 15797 this == t.target && (e = !0) 15798 }), 15799 e 15800 }, 15801 _createHelper: function(t) { 15802 var e = this.options 15803 , i = b.isFunction(e.helper) ? b(e.helper.apply(this.element[0], [t])) : "clone" == e.helper ? this.element.clone().removeAttr("id") : this.element; 15804 return i.parents("body").length || i.appendTo("parent" == e.appendTo ? this.element[0].parentNode : e.appendTo), 15805 i[0] == this.element[0] || /(fixed|absolute)/.test(i.css("position")) || i.css("position", "absolute"), 15806 i 15807 }, 15808 _adjustOffsetFromHelper: function(t) { 15809 "string" == typeof t && (t = t.split(" ")), 15810 b.isArray(t) && (t = { 15811 left: +t[0], 15812 top: +t[1] || 0 15813 }), 15814 "left"in t && (this.offset.click.left = t.left + this.margins.left), 15815 "right"in t && (this.offset.click.left = this.helperProportions.width - t.right + this.margins.left), 15816 "top"in t && (this.offset.click.top = t.top + this.margins.top), 15817 "bottom"in t && (this.offset.click.top = this.helperProportions.height - t.bottom + this.margins.top) 15818 }, 15819 _getParentOffset: function() { 15820 this.offsetParent = this.helper.offsetParent(); 15821 var t = this.offsetParent.offset(); 15822 return "absolute" == this.cssPosition && this.scrollParent[0] != document && b.contains(this.scrollParent[0], this.offsetParent[0]) && (t.left += this.scrollParent.scrollLeft(), 15823 t.top += this.scrollParent.scrollTop()), 15824 (this.offsetParent[0] == document.body || this.offsetParent[0].tagName && "html" == this.offsetParent[0].tagName.toLowerCase() && b.browser.msie) && (t = { 15825 top: 0, 15826 left: 0 15827 }), 15828 { 15829 top: t.top + (parseInt(this.offsetParent.css("borderTopWidth"), 10) || 0), 15830 left: t.left + (parseInt(this.offsetParent.css("borderLeftWidth"), 10) || 0) 15831 } 15832 }, 15833 _getRelativeOffset: function() { 15834 if ("relative" == this.cssPosition) { 15835 var t = this.element.position(); 15836 return { 15837 top: t.top - (parseInt(this.helper.css("top"), 10) || 0) + this.scrollParent.scrollTop(), 15838 left: t.left - (parseInt(this.helper.css("left"), 10) || 0) + this.scrollParent.scrollLeft() 15839 } 15840 } 15841 return { 15842 top: 0, 15843 left: 0 15844 } 15845 }, 15846 _cacheMargins: function() { 15847 this.margins = { 15848 left: parseInt(this.element.css("marginLeft"), 10) || 0, 15849 top: parseInt(this.element.css("marginTop"), 10) || 0, 15850 right: parseInt(this.element.css("marginRight"), 10) || 0, 15851 bottom: parseInt(this.element.css("marginBottom"), 10) || 0 15852 } 15853 }, 15854 _cacheHelperProportions: function() { 15855 this.helperProportions = { 15856 width: this.helper.outerWidth(), 15857 height: this.helper.outerHeight() 15858 } 15859 }, 15860 _setContainment: function() { 15861 var t = this.options; 15862 if ("parent" == t.containment && (t.containment = this.helper[0].parentNode), 15863 "document" != t.containment && "window" != t.containment || (this.containment = ["document" == t.containment ? 0 : b(window).scrollLeft() - this.offset.relative.left - this.offset.parent.left, "document" == t.containment ? 0 : b(window).scrollTop() - this.offset.relative.top - this.offset.parent.top, ("document" == t.containment ? 0 : b(window).scrollLeft()) + b("document" == t.containment ? document : window).width() - this.helperProportions.width - this.margins.left, ("document" == t.containment ? 0 : b(window).scrollTop()) + (b("document" == t.containment ? document : window).height() || document.body.parentNode.scrollHeight) - this.helperProportions.height - this.margins.top]), 15864 /^(document|window|parent)$/.test(t.containment) || t.containment.constructor == Array) 15865 t.containment.constructor == Array && (this.containment = t.containment); 15866 else { 15867 var e = b(t.containment) 15868 , i = e[0]; 15869 if (!i) 15870 return; 15871 e.offset(); 15872 var n = "hidden" != b(i).css("overflow"); 15873 this.containment = [(parseInt(b(i).css("borderLeftWidth"), 10) || 0) + (parseInt(b(i).css("paddingLeft"), 10) || 0), (parseInt(b(i).css("borderTopWidth"), 10) || 0) + (parseInt(b(i).css("paddingTop"), 10) || 0), (n ? Math.max(i.scrollWidth, i.offsetWidth) : i.offsetWidth) - (parseInt(b(i).css("borderLeftWidth"), 10) || 0) - (parseInt(b(i).css("paddingRight"), 10) || 0) - this.helperProportions.width - this.margins.left - this.margins.right, (n ? Math.max(i.scrollHeight, i.offsetHeight) : i.offsetHeight) - (parseInt(b(i).css("borderTopWidth"), 10) || 0) - (parseInt(b(i).css("paddingBottom"), 10) || 0) - this.helperProportions.height - this.margins.top - this.margins.bottom], 15874 this.relative_container = e 15875 } 15876 }, 15877 _convertPositionTo: function(t, e) { 15878 e || (e = this.position); 15879 var i = "absolute" == t ? 1 : -1 15880 , n = (this.options, 15881 "absolute" != this.cssPosition || this.scrollParent[0] != document && b.contains(this.scrollParent[0], this.offsetParent[0]) ? this.scrollParent : this.offsetParent) 15882 , s = /(html|body)/i.test(n[0].tagName); 15883 return { 15884 top:
15884 e.top + this.offset.relative.top * i + this.offset.parent.top * i - ("fixed" == this.cssPosition ? -this.scrollParent.scrollTop() : s ? 0 : n.scrollTop()) * i, 15885 left: e.left + this.offset.relative.left * i + this.offset.parent.left * i - ("fixed" == this.cssPosition ? -this.scrollParent.scrollLeft() : s ? 0 : n.scrollLeft()) * i 15886 } 15887 }, 15888 _generatePosition: function(t) { 15889 var e = this.options 15890 , i = "absolute" != this.cssPosition || this.scrollParent[0] != document && b.contains(this.scrollParent[0], this.offsetParent[0]) ? this.scrollParent : this.offsetParent 15891 , n = /(html|body)/i.test(i[0].tagName) 15892 , s = t.pageX 15893 , o = t.pageY; 15894 if (this.originalPosition) { 15895 var r; 15896 if (this.containment) { 15897 if (this.relative_container) { 15898 var a = this.relative_container.offset(); 15899 r = [this.containment[0] + a.left, this.containment[1] + a.top, this.containment[2] + a.left, this.containment[3] + a.top] 15900 } else 15901 r = this.containment; 15902 t.pageX - this.offset.click.left < r[0] && (s = r[0] + this.offset.click.left), 15903 t.pageY - this.offset.click.top < r[1] && (o = r[1] + this.offset.click.top), 15904 t.pageX - this.offset.click.left > r[2] && (s = r[2] + this.offset.click.left), 15905 t.pageY - this.offset.click.top > r[3] && (o = r[3] + this.offset.click.top) 15906 } 15907 if (e.grid) { 15908 var l = e.grid[1] ? this.originalPageY + Math.round((o - this.originalPageY) / e.grid[1]) * e.grid[1] : this.originalPageY; 15909 o = r && (l - this.offset.click.top < r[1] || l - this.offset.click.top > r[3]) ? l - this.offset.click.top < r[1] ? l + e.grid[1] : l - e.grid[1] : l; 15910 var c = e.grid[0] ? this.originalPageX + Math.round((s - this.originalPageX) / e.grid[0]) * e.grid[0] : this.originalPageX; 15911 s = r && (c - this.offset.click.left < r[0] || c - this.offset.click.left > r[2]) ? c - this.offset.click.left < r[0] ? c + e.grid[0] : c - e.grid[0] : c 15912 } 15913 } 15914 return { 15915 top: o - this.offset.click.top - this.offset.relative.top - this.offset.parent.top + ("fixed" == this.cssPosition ? -this.scrollParent.scrollTop() : n ? 0 : i.scrollTop()), 15916 left: s - this.offset.click.left - this.offset.relative.left - this.offset.parent.left + ("fixed" == this.cssPosition ? -this.scrollParent.scrollLeft() : n ? 0 : i.scrollLeft()) 15917 } 15918 }, 15919 _clear: function() { 15920 this.helper.removeClass("ui-draggable-dragging"), 15921 this.helper[0] == this.element[0] || this.cancelHelperRemoval || this.helper.remove(), 15922 this.helper = null, 15923 this.cancelHelperRemoval = !1 15924 }, 15925 _trigger: function(t, e, i) { 15926 return i = i || this._uiHash(), 15927 b.ui.plugin.call(this, t, [e, i]), 15928 "drag" == t && (this.positionAbs = this._convertPositionTo("absolute")), 15929 b.Widget.prototype._trigger.call(this, t, e, i) 15930 }, 15931 plugins: {}, 15932 _uiHash: function() { 15933 return { 15934 helper: this.helper, 15935 position: this.position, 15936 originalPosition: this.originalPosition, 15937 offset: this.positionAbs 15938 } 15939 } 15940 }), 15941 b.ui.plugin.add("draggable", "connectToSortable", { 15942 start: function(e, t) { 15943 var i = b(this).data("draggable") 15944 , n = i.options 15945 , s = b.extend({}, t, { 15946 item: i.element 15947 }); 15948 i.sortables = [], 15949 b(n.connectToSortable).each(function() { 15950 var t = b.data(this, "sortable"); 15951 t && !t.options.disabled && (i.sortables.push({ 15952 instance: t, 15953 shouldRevert: t.options.revert 15954 }), 15955 t.refreshPositions(), 15956 t._trigger("activate", e, s)) 15957 }) 15958 }, 15959 stop: function(t, e) { 15960 var i = b(this).data("draggable") 15961 , n = b.extend({}, e, { 15962 item: i.element 15963 }); 15964 b.each(i.sortables, function() { 15965 this.instance.isOver ? (this.instance.isOver = 0, 15966 i.cancelHelperRemoval = !0, 15967 this.instance.cancelHelperRemoval = !1, 15968 this.shouldRevert && (this.instance.options.revert = !0), 15969 this.instance._mouseStop(t), 15970 this.instance.options.helper = this.instance.options._helper, 15971 "original" == i.options.helper && this.instance.currentItem.css({ 15972 top: "auto", 15973 left: "auto" 15974 })) : (this.instance.cancelHelperRemoval = !1, 15975 this.instance._trigger("deactivate", t, n)) 15976 }) 15977 }, 15978 drag: function(t, e) { 15979 var i = b(this).data("draggable") 15980 , n = this; 15981 b.each(i.sortables, function() { 15982 this.instance.positionAbs = i.positionAbs, 15983 this.instance.helperProportions = i.helperProportions, 15984 this.instance.offset.click = i.offset.click, 15985 this.instance._intersectsWith(this.instance.containerCache) ? (this.instance.isOver || (this.instance.isOver = 1, 15986 this.instance.currentItem = b(n).clone().removeAttr("id").appendTo(this.instance.element).data("sortable-item", !0), 15987 this.instance.options._helper = this.instance.options.helper, 15988 this.instance.options.helper = function() { 15989 return e.helper[0] 15990 } 15991 , 15992 t.target = this.instance.currentItem[0], 15993 this.instance._mouseCapture(t, !0), 15994 this.instance._mouseStart(t, !0, !0), 15995 this.instance.offset.click.top = i.offset.click.top, 15996 this.instance.offset.click.left = i.offset.click.left, 15997 this.instance.offset.parent.left -= i.offset.parent.left - this.instance.offset.parent.left, 15998 this.instance.offset.parent.top -= i.offset.parent.top - this.instance.offset.parent.top, 15999 i._trigger("toSortable", t), 16000 i.dropped = this.instance.element, 16001 i.currentItem = i.element, 16002 this.instance.fromOutside = i), 16003 this.instance.currentItem && this.instance._mouseDrag(t)) : this.instance.isOver && (this.instance.isOver = 0, 16004 this.instance.cancelHelperRemoval = !0, 16005 this.instance.options.revert = !1, 16006 this.instance._trigger("out", t, this.instance._uiHash(this.instance)), 16007 this.instance._mouseStop(t, !0), 16008 this.instance.options.helper = this.instance.options._helper, 16009 this.instance.currentItem.remove(), 16010 this.instance.placeholder && this.instance.placeholder.remove(), 16011 i._trigger("fromSortable", t), 16012 i.dropped = !1) 16013 }) 16014 } 16015 }), 16016 b.ui.plugin.add("draggable", "cursor", { 16017 start: function() { 16018 var t = b("body") 16019 , e = b(this).data("draggable").options; 16020 t.css("cursor") && (e._cursor = t.css("cursor")), 16021 t.css("cursor", e.cursor) 16022 }, 16023 stop: function() { 16024 var t = b(this).data("draggable").options; 16025 t._cursor && b("body").css("cursor", t._cursor) 16026 } 16027 }), 16028 b.ui.plugin.add("draggable", "opacity", { 16029 start: function(t, e) { 16030 var i = b(e.helper) 16031 , n = b(this).data("draggable").options; 16032 i.css("opacity") && (n._opacity = i.css("opacity")), 16033 i.css("opacity", n.opacity) 16034 }, 16035 stop: function(t, e) { 16036 var i = b(this).data("draggable").options; 16037 i._opacity && b(e.helper).css("opacity", i._opacity) 16038 } 16039 }), 16040 b.ui.plugin.add("draggable", "scroll", { 16041 start: function() { 16042 var t = b(this).data("draggable"); 16043 t.scrollParent[0] != document && "HTML" != t.scrollParent[0].tagName && (t.overflowOffset = t.scrollParent.offset()) 16044 }, 16045 drag: function(t) { 16046 var e = b(this).data("draggable") 16047 , i = e.options 16048 , n = !1; 16049 e.scrollParent[0] != document && "HTML" != e.scrollParent[0].tagName ? (i.axis && "x" == i.axis || (e.overflowOffset.top + e.scrollParent[0].offsetHeight - t.pageY < i.scrollSensitivity ? e.scrollParent[0].scrollTop = n = e.scrollParent[0].scrollTop + i.scrollSpeed : t.pageY - e.overflowOffset.top < i.scrollSensitivity && (e.scrollParent[0].scrollTop = n = e.scrollParent[0].scrollTop - i.scrollSpeed)), 16050 i.axis && "y" == i.axis || (e.overflowOffset.left + e.scrollParent[0].offsetWidth - t.pageX < i.scrollSensitivity ? e.scrollParent[0].scrollLeft = n = e.scrollParent[0].scrollLeft + i.scrollSpeed : t.pageX - e.overflowOffset.left < i.scrollSensitivity && (e.scrollParent[0].scrollLeft = n = e.scrollParent[0].scrollLeft - i.scrollSpeed))) : (i.axis && "x" == i.axis || (t.pageY - b(d
16050ocument).scrollTop() < i.scrollSensitivity ? n = b(document).scrollTop(b(document).scrollTop() - i.scrollSpeed) : b(window).height() - (t.pageY - b(document).scrollTop()) < i.scrollSensitivity && (n = b(document).scrollTop(b(document).scrollTop() + i.scrollSpeed))), 16051 i.axis && "y" == i.axis || (t.pageX - b(document).scrollLeft() < i.scrollSensitivity ? n = b(document).scrollLeft(b(document).scrollLeft() - i.scrollSpeed) : b(window).width() - (t.pageX - b(document).scrollLeft()) < i.scrollSensitivity && (n = b(document).scrollLeft(b(document).scrollLeft() + i.scrollSpeed)))), 16052 !1 !== n && b.ui.ddmanager && !i.dropBehaviour && b.ui.ddmanager.prepareOffsets(e, t) 16053 } 16054 }), 16055 b.ui.plugin.add("draggable", "snap", { 16056 start: function() { 16057 var i = b(this).data("draggable") 16058 , t = i.options; 16059 i.snapElements = [], 16060 b(t.snap.constructor != String ? t.snap.items || ":data(draggable)" : t.snap).each(function() { 16061 var t = b(this) 16062 , e = t.offset(); 16063 this != i.element[0] && i.snapElements.push({ 16064 item: this, 16065 width: t.outerWidth(), 16066 height: t.outerHeight(), 16067 top: e.top, 16068 left: e.left 16069 }) 16070 }) 16071 }, 16072 drag: function(t, e) { 16073 for (var i = b(this).data("draggable"), n = i.options, s = n.snapTolerance, o = e.offset.left, r = o + i.helperProportions.width, a = e.offset.top, l = a + i.helperProportions.height, c = i.snapElements.length - 1; 0 <= c; c--) { 16074 var u = i.snapElements[c].left 16075 , h = u + i.snapElements[c].width 16076 , d = i.snapElements[c].top 16077 , p = d + i.snapElements[c].height; 16078 if (u - s < o && o < h + s && d - s < a && a < p + s || u - s < o && o < h + s && d - s < l && l < p + s || u - s < r && r < h + s && d - s < a && a < p + s || u - s < r && r < h + s && d - s < l && l < p + s) { 16079 if ("inner" != n.snapMode) { 16080 var f = Math.abs(d - l) <= s 16081 , g = Math.abs(p - a) <= s 16082 , m = Math.abs(u - r) <= s 16083 , v = Math.abs(h - o) <= s; 16084 f && (e.position.top = i._convertPositionTo("relative", { 16085 top: d - i.helperProportions.height, 16086 left: 0 16087 }).top - i.margins.top), 16088 g && (e.position.top = i._convertPositionTo("relative", { 16089 top: p, 16090 left: 0 16091 }).top - i.margins.top), 16092 m && (e.position.left = i._convertPositionTo("relative", { 16093 top: 0, 16094 left: u - i.helperProportions.width 16095 }).left - i.margins.left), 16096 v && (e.position.left = i._convertPositionTo("relative", { 16097 top: 0, 16098 left: h 16099 }).left - i.margins.left) 16100 } 16101 var y = f || g || m || v; 16102 if ("outer" != n.snapMode) { 16103 f = Math.abs(d - a) <= s, 16104 g = Math.abs(p - l) <= s, 16105 m = Math.abs(u - o) <= s, 16106 v = Math.abs(h - r) <= s; 16107 f && (e.position.top = i._convertPositionTo("relative", { 16108 top: d, 16109 left: 0 16110 }).top - i.margins.top), 16111 g && (e.position.top = i._convertPositionTo("relative", { 16112 top: p - i.helperProportions.height, 16113 left: 0 16114 }).top - i.margins.top), 16115 m && (e.position.left = i._convertPositionTo("relative", { 16116 top: 0, 16117 left: u 16118 }).left - i.margins.left), 16119 v && (e.position.left = i._convertPositionTo("relative", { 16120 top: 0, 16121 left: h - i.helperProportions.width 16122 }).left - i.margins.left) 16123 } 16124 !i.snapElements[c].snapping && (f || g || m || v || y) && i.options.snap.snap && i.options.snap.snap.call(i.element, t, b.extend(i._uiHash(), { 16125 snapItem: i.snapElements[c].item 16126 })), 16127 i.snapElements[c].snapping = f || g || m || v || y 16128 } else 16129 i.snapElements[c].snapping && i.options.snap.release && i.options.snap.release.call(i.element, t, b.extend(i._uiHash(), { 16130 snapItem: i.snapElements[c].item 16131 })), 16132 i.snapElements[c].snapping = !1 16133 } 16134 } 16135 }), 16136 b.ui.plugin.add("draggable", "stack", { 16137 start: function() { 16138 var t = b(this).data("draggable").options 16139 , e = b.makeArray(b(t.stack)).sort(function(t, e) { 16140 return (parseInt(b(t).css("zIndex"), 10) || 0) - (parseInt(b(e).css("zIndex"), 10) || 0) 16141 }); 16142 if (e.length) { 16143 var i = parseInt(e[0].style.zIndex) || 0; 16144 b(e).each(function(t) { 16145 this.style.zIndex = i + t 16146 }), 16147 this[0].style.zIndex = i + e.length 16148 } 16149 } 16150 }), 16151 b.ui.plugin.add("draggable", "zIndex", { 16152 start: function(t, e) { 16153 var i = b(e.helper) 16154 , n = b(this).data("draggable").options; 16155 i.css("zIndex") && (n._zIndex = i.css("zIndex")), 16156 i.css("zIndex", n.zIndex) 16157 }, 16158 stop: function(t, e) { 16159 var i = b(this).data("draggable").options; 16160 i._zIndex && b(e.helper).css("zIndex", i._zIndex) 16161 } 16162 }) 16163}(jQuery), 16164function(p) { 16165 p.widget("ui.droppable", { 16166 version: "1.9.0", 16167 widgetEventPrefix: "drop", 16168 options: { 16169 accept: "*", 16170 activeClass: !1, 16171 addClasses: !0, 16172 greedy: !1, 16173 hoverClass: !1, 16174 scope: "default", 16175 tolerance: "intersect" 16176 }, 16177 _create: function() { 16178 var t = this.options 16179 , e = t.accept; 16180 this.isover = 0, 16181 this.isout = 1, 16182 this.accept = p.isFunction(e) ? e : function(t) { 16183 return t.is(e) 16184 } 16185 , 16186 this.proportions = { 16187 width: this.element[0].offsetWidth, 16188 height: this.element[0].offsetHeight 16189 }, 16190 p.ui.ddmanager.droppables[t.scope] = p.ui.ddmanager.droppables[t.scope] || [], 16191 p.ui.ddmanager.droppables[t.scope].push(this), 16192 t.addClasses && this.element.addClass("ui-droppable") 16193 }, 16194 _destroy: function() { 16195 for (var t = p.ui.ddmanager.droppables[this.options.scope], e = 0; e < t.length; e++) 16196 t[e] == this && t.splice(e, 1); 16197 this.element.removeClass("ui-droppable ui-droppable-disabled") 16198 }, 16199 _setOption: function(t, e) { 16200 "accept" == t && (this.accept = p.isFunction(e) ? e : function(t) { 16201 return t.is(e) 16202 } 16203 ), 16204 p.Widget.prototype._setOption.apply(this, arguments) 16205 }, 16206 _activate: function(t) { 16207 var e = p.ui.ddmanager.current; 16208 this.options.activeClass && this.element.addClass(this.options.activeClass), 16209 e && this._trigger("activate", t, this.ui(e)) 16210 }, 16211 _deactivate: function(t) { 16212 var e = p.ui.ddmanager.current; 16213 this.options.activeClass && this.element.removeClass(this.options.activeClass), 16214 e && this._trigger("deactivate", t, this.ui(e)) 16215 }, 16216 _over: function(t) { 16217 var e = p.ui.ddmanager.current; 16218 e && (e.currentItem || e.element)[0] != this.element[0] && this.accept.call(this.element[0], e.currentItem || e.element) && (this.options.hoverClass && this.element.addClass(this.options.hoverClass), 16219 this._trigger("over", t, this.ui(e))) 16220 }, 16221 _out: function(t) { 16222 var e = p.ui.ddmanager.current; 16223 e && (e.currentItem || e.element)[0] != this.element[0] && this.accept.call(this.element[0], e.currentItem || e.element) && (this.options.hoverClass && this.element.removeClass(this.options.hoverClass), 16224 this._trigger("out", t, this.ui(e))) 16225 }, 16226 _drop: function(t, e) { 16227 var i = e || p.ui.ddmanager.current; 16228 if (!i || (i.currentItem || i.element)[0] == this.element[0]) 16229 return !1; 16230 var n = !1; 16231 return this.element.find(":data(droppable)").not(".ui-draggable-dragging").each(function() { 16232 var t = p.data(this, "droppable"); 16233 if (t.options.greedy && !t.options.disabled && t.options.scope == i.options.scope && t.accept.call(t.element[0], i.currentItem || i.element) && p.ui.intersect(i, p.extend(t, { 16234 offset: t.element.offset() 16235 }), t.options.tolerance)) 16236 return !(n = !0) 16237 }), 16238 !n && (!!this.accept.call(this.element[0], i.currentItem || i.element) && (this.options.activeClass && this.element.removeClass(this.options.activeClass), 16239 this.options.hoverClass && this.element.removeClass(this.options.hoverClass), 16240 this._trigger("drop", t, this.ui(i)), 16241 this.element)) 16242 }, 16243 ui: function(t) { 16244 return { 16245 draggable: t.currentItem || t.element, 16246 helper: t.helper, 16247 position: t.position, 16248 offset: t.positionAbs 16249 } 16250 } 16251 }), 16252 p.ui.intersect = function(t, e, i) { 16253 if (!e.offset) 16254 return !1; 16255 var n = (t.positionAbs || t.position.absolute).left 16256 , s = n + t.helperProportions.width 16257 , o = (t.positionAbs || t.position.absolute).top 16258 , r = o + t.helperProportions.height 16259 , a = e.offset.left 16260 , l = a + e.proportions.width 16261 , c = e.offset.top 16262 , u = c + e.proportions.height; 16263 switch (i) { 16264 case "fit": 16265 return a <= n && s <= l && c <= o && r <= u; 16266 case "intersect": 16267 return a < n + t.helperProportions.width / 2 && s - t.helperProportions.width / 2 < l && c < o + t.helperProportions.height / 2 && r - t.helperProportions.height / 2 < u; 16268 case "pointer": 16269 var h = (t.positionAbs || t.position.absolute).left + (t.clickOffset || t.offset.click).left 16270 , d = (t.positionAbs || t.position.absolute).top + (t.clickOffset || t.offset.click).top; 16271 return p.ui.isOver(d, h, c, a, e.proportions.height, e.proportions.width); 16272 case "touch": 16273 return (c <= o && o <= u || c <= r && r <= u || o < c && u < r) && (a <= n && n <= l || a <= s && s <= l || n < a && l < s); 16274 default: 16275 return !1 16276 } 16277 } 16278 , 16279 p.ui.ddmanager = { 16280 current: null, 16281 droppables: { 16282 default: [] 16283 }, 16284 prepareOffsets: function(t, e) { 16285 var i = p.ui.ddmanager.droppables[t.options.scope] || [] 16286 , n = e ? e.type : null 16287 , s = (t.currentItem || t.element).find(":data(droppable)").andSelf(); 16288 t: for (var o = 0; o < i.length; o++) 16289 if (!(i[o].options.disabled || t && !i[o].accept.call(i[o].element[0], t.currentItem || t.element))) { 16290 for (var r = 0; r < s.length; r++) 16291 if (s[r] == i[o].element[0]) { 16292 i[o].proportions.height = 0; 16293 continue t 16294 } 16295 i[o].visible = "none" != i[o].element.css("display"), 16296 i[o].visible && ("mousedown" == n && i[o]._activate.call(i[o], e), 16297 i[o].offset = i[o].element.offset(), 16298 i[o].proportions = { 16299 width: i[o].element[0].offsetWidth, 16300 height: i[o].element[0].offsetHeight 16301 }) 16302 } 16303 }, 16304 drop: function(t, e) { 16305 var i = !1; 16306 return p.each(p.ui.ddmanager.droppables[t.options.scope] || [], function() { 16307 this.options && (!this.options.disabled && this.visible && p.ui.intersect(t, this, this.options.tolerance) && (i = this._drop.call(this, e) || i), 16308 !this.options.disabled && this.visible && this.accept.call(this.element[0], t.currentItem || t.element) && (this.isout = 1, 16309 this.isover = 0, 16310 this._deactivate.call(this, e))) 16311 }), 16312 i 16313 }, 16314 dragStart: function(t, e) { 16315 t.element.parentsUntil("body").bind("scroll.droppable", function() { 16316 t.options.refreshPositions || p.ui.ddmanager.prepareOffsets(t, e) 16317 }) 16318 }, 16319 drag: function(o, r) { 16320 o.options.refreshPositions && p.ui.ddmanager.prepareOffsets(o, r), 16321 p.each(p.ui.ddmanager.droppables[o.options.scope] || [], function() { 16322 if (!this.options.disabled && !this.greedyChild && this.visible) { 16323 var t = p.ui.intersect(o, this, this.options.tolerance) 16324 , e = t || 1 != this.isover ? t && 0 == this.isover ? "isover" : null : "
16324isout"; 16325 if (e) { 16326 var i; 16327 if (this.options.greedy) { 16328 var n = this.options.scope 16329 , s = this.element.parents(":data(droppable)").filter(function() { 16330 return p.data(this, "droppable").options.scope === n 16331 }); 16332 s.length && ((i = p.data(s[0], "droppable")).greedyChild = "isover" == e ? 1 : 0) 16333 } 16334 i && "isover" == e && (i.isover = 0, 16335 i.isout = 1, 16336 i._out.call(i, r)), 16337 this[e] = 1, 16338 this["isout" == e ? "isover" : "isout"] = 0, 16339 this["isover" == e ? "_over" : "_out"].call(this, r), 16340 i && "isout" == e && (i.isout = 0, 16341 i.isover = 1, 16342 i._over.call(i, r)) 16343 } 16344 } 16345 }) 16346 }, 16347 dragStop: function(t, e) { 16348 t.element.parentsUntil("body").unbind("scroll.droppable"), 16349 t.options.refreshPositions || p.ui.ddmanager.prepareOffsets(t, e) 16350 } 16351 } 16352}(jQuery), 16353function(d) { 16354 d.widget("ui.resizable", d.ui.mouse, { 16355 version: "1.9.0", 16356 widgetEventPrefix: "resize", 16357 options: { 16358 alsoResize: !1, 16359 animate: !1, 16360 animateDuration: "slow", 16361 animateEasing: "swing", 16362 aspectRatio: !1, 16363 autoHide: !1, 16364 containment: !1, 16365 ghost: !1, 16366 grid: !1, 16367 handles: "e,s,se", 16368 helper: !1, 16369 maxHeight: null, 16370 maxWidth: null, 16371 minHeight: 10, 16372 minWidth: 10, 16373 zIndex: 1e3 16374 }, 16375 _create: function() { 16376 var e = this 16377 , t = this.options; 16378 if (this.element.addClass("ui-resizable"), 16379 d.extend(this, { 16380 _aspectRatio: !!t.aspectRatio, 16381 aspectRatio: t.aspectRatio, 16382 originalElement: this.element, 16383 _proportionallyResizeElements: [], 16384 _helper: t.helper || t.ghost || t.animate ? t.helper || "ui-resizable-helper" : null 16385 }), 16386 this.element[0].nodeName.match(/canvas|textarea|input|select|button|img/i) && (this.element.wrap(d('<div class="ui-wrapper" style="overflow: hidden;"></div>').css({ 16387 position: this.element.css("position"), 16388 width: this.element.outerWidth(), 16389 height: this.element.outerHeight(), 16390 top: this.element.css("top"), 16391 left: this.element.css("left") 16392 })), 16393 this.element = this.element.parent().data("resizable", this.element.data("resizable")), 16394 this.elementIsWrapper = !0, 16395 this.element.css({ 16396 marginLeft: this.originalElement.css("marginLeft"), 16397 marginTop: this.originalElement.css("marginTop"), 16398 marginRight: this.originalElement.css("marginRight"), 16399 marginBottom: this.originalElement.css("marginBottom") 16400 }), 16401 this.originalElement.css({ 16402 marginLeft: 0, 16403 marginTop: 0, 16404 marginRight: 0, 16405 marginBottom: 0 16406 }), 16407 this.originalResizeStyle = this.originalElement.css("resize"), 16408 this.originalElement.css("resize", "none"), 16409 this._proportionallyResizeElements.push(this.originalElement.css({ 16410 position: "static", 16411 zoom: 1, 16412 display: "block" 16413 })), 16414 this.originalElement.css({ 16415 margin: this.originalElement.css("margin") 16416 }), 16417 this._proportionallyResize()), 16418 this.handles = t.handles || (d(".ui-resizable-handle", this.element).length ? { 16419 n: ".ui-resizable-n", 16420 e: ".ui-resizable-e", 16421 s: ".ui-resizable-s", 16422 w: ".ui-resizable-w", 16423 se: ".ui-resizable-se", 16424 sw: ".ui-resizable-sw", 16425 ne: ".ui-resizable-ne", 16426 nw: ".ui-resizable-nw" 16427 } : "e,s,se"), 16428 this.handles.constructor == String) { 16429 "all" == this.handles && (this.handles = "n,e,s,w,se,sw,ne,nw"); 16430 var i = this.handles.split(","); 16431 this.handles = {}; 16432 for (var n = 0; n < i.length; n++) { 16433 var s = d.trim(i[n]) 16434 , o = d('<div class="ui-resizable-handle ' + ("ui-resizable-" + s) + '"></div>'); 16435 o.css({ 16436 zIndex: t.zIndex 16437 }), 16438 "se" == s && o.addClass("ui-icon ui-icon-gripsmall-diagonal-se"), 16439 this.handles[s] = ".ui-resizable-" + s, 16440 this.element.append(o) 16441 } 16442 } 16443 this._renderAxis = function(t) { 16444 for (var e in t = t || this.element, 16445 this.handles) { 16446 if (this.handles[e].constructor == String && (this.handles[e] = d(this.handles[e], this.element).show()), 16447 this.elementIsWrapper && this.originalElement[0].nodeName.match(/textarea|input|select|button/i)) { 16448 var i, n = d(this.handles[e], this.element); 16449 i = /sw|ne|nw|se|n|s/.test(e) ? n.outerHeight() : n.outerWidth();
16450 var s = ["padding", /ne|nw|n/.test(e) ? "Top" : /se|sw|s/.test(e) ? "Bottom" : /^e$/.test(e) ? "Right" : "Left"].join(""); 16451 t.css(s, i), 16452 this._proportionallyResize() 16453 } 16454 d(this.handles[e]).length 16455 } 16456 } 16457 , 16458 this._renderAxis(this.element), 16459 this._handles = d(".ui-resizable-handle", this.element).disableSelection(), 16460 this._handles.mouseover(function() { 16461 if (!e.resizing) { 16462 if (this.className) 16463 var t = this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i); 16464 e.axis = t && t[1] ? t[1] : "se" 16465 } 16466 }), 16467 t.autoHide && (this._handles.hide(), 16468 d(this.element).addClass("ui-resizable-autohide").mouseenter(function() { 16469 t.disabled || (d(this).removeClass("ui-resizable-autohide"), 16470 e._handles.show()) 16471 }).mouseleave(function() { 16472 t.disabled || e.resizing || (d(this).addClass("ui-resizable-autohide"), 16473 e._handles.hide()) 16474 })), 16475 this._mouseInit() 16476 }, 16477 _destroy: function() { 16478 this._mouseDestroy(); 16479 var t = function(t) { 16480 d(t).removeClass("ui-resizable ui-resizable-disabled ui-resizable-resizing").removeData("resizable").removeData("ui-resizable").unbind(".resizable").find(".ui-resizable-handle").remove() 16481 }; 16482 if (this.elementIsWrapper) { 16483 t(this.element); 16484 var e = this.element; 16485 e.after(this.originalElement.css({ 16486 position: e.css("position"), 16487 width: e.outerWidth(), 16488 height: e.outerHeight(), 16489 top: e.css("top"), 16490 left: e.css("left") 16491 })).remove() 16492 } 16493 return this.originalElement.css("resize", this.originalResizeStyle), 16494 t(this.originalElement), 16495 this 16496 }, 16497 _mouseCapture: function(t) { 16498 var e = !1; 16499 for (var i in this.handles) 16500 d(this.handles[i])[0] == t.target && (e = !0); 16501 return !this.options.disabled && e 16502 }, 16503 _mouseStart: function(t) { 16504 var e = this.options 16505 , i = this.element.position() 16506 , n = this.element; 16507 this.resizing = !0, 16508 this.documentScroll = { 16509 top: d(document).scrollTop(), 16510 left: d(document).scrollLeft() 16511 }, 16512 (n.is(".ui-draggable") || /absolute/.test(n.css("position"))) && n.css({ 16513 position: "absolute", 16514 top: i.top, 16515 left: i.left 16516 }), 16517 this._renderProxy(); 16518 var s = p(this.helper.css("left")) 16519 , o = p(this.helper.css("top")); 16520 e.containment && (s += d(e.containment).scrollLeft() || 0, 16521 o += d(e.containment).scrollTop() || 0), 16522 this.offset = this.helper.offset(), 16523 this.position = { 16524 left: s, 16525 top: o 16526 }, 16527 this.size = this._helper ? { 16528 width: n.outerWidth(), 16529 height: n.outerHeight() 16530 } : { 16531 width: n.width(), 16532 height: n.height() 16533 }, 16534 this.originalSize = this._helper ? { 16535 width: n.outerWidth(), 16536 height: n.outerHeight() 16537 } : { 16538 width: n.width(), 16539 height: n.height() 16540 }, 16541 this.originalPosition = { 16542 left: s, 16543 top: o 16544 }, 16545 this.sizeDiff = { 16546 width: n.outerWidth() - n.width(), 16547 height: n.outerHeight() - n.height() 16548 }, 16549 this.originalMousePosition = { 16550 left: t.pageX, 16551 top: t.pageY 16552 }, 16553 this.aspectRatio = "number" == typeof e.aspectRatio ? e.aspectRatio : this.originalSize.width / this.originalSize.height || 1; 16554 var r = d(".ui-resizable-" + this.axis).css("cursor"); 16555 return d("body").css("cursor", "auto" == r ? this.axis + "-resize" : r), 16556 n.addClass("ui-resizable-resizing"), 16557 this._propagate("start", t), 16558 !0 16559 }, 16560 _mouseDrag: function(t) { 16561 var e = this.helper 16562 , i = (this.options, 16563 this.originalMousePosition) 16564 , n = this.axis 16565 , s = t.pageX - i.left || 0 16566 , o = t.pageY - i.top || 0 16567 , r = this._change[n]; 16568 if (!r) 16569 return !1; 16570 var a = r.apply(this, [t, s, o]); 16571 return this._updateVirtualBoundaries(t.shiftKey), 16572 (this._aspectRatio || t.shiftKey) && (a = this._updateRatio(a, t)), 16573 a = this._respectSize(a, t), 16574 this._propagate("resize", t), 16575 e.css({ 16576 top: this.position.top + "px", 16577 left: this.position.left + "px", 16578 width: this.size.width + "px", 16579 height: this.size.height + "px" 16580 }), 16581 !this._helper && this._proportionallyResizeElements.length && this._proportionallyResize(), 16582 this._updateCache(a), 16583 this._trigger("resize", t, this.ui()), 16584 !1 16585 }, 16586 _mouseStop: function(t) { 16587 this.resizing = !1; 16588 var e = this.options 16589 , i = this; 16590 if (this._helper) { 16591 var n = this._proportionallyResizeElements 16592 , s = n.length && /textarea/i.test(n[0].nodeName) 16593 , o = s && d.ui.hasScroll(n[0], "left") ? 0 : i.sizeDiff.height 16594 , r = s ? 0 : i.sizeDiff.width 16595 , a = { 16596 width: i.helper.width() - r, 16597 height: i.helper.height() - o 16598 } 16599 , l = parseInt(i.element.css("left"), 10) + (i.position.left - i.originalPosition.left) || null 16600 , c = parseInt(i.element.css("top"), 10) + (i.position.top - i.originalPosition.top) || null; 16601 e.animate || this.element.css(d.extend(a, { 16602 top: c, 16603 left: l 16604 })), 16605 i.helper.height(i.size.height), 16606 i.helper.width(i.size.width), 16607 this._helper && !e.animate && this._proportionallyResize() 16608 } 16609 return d("body").css("cursor", "auto"), 16610 this.element.removeClass("ui-resizable-resizing"), 16611 this._propagate("stop", t), 16612 this._helper && this.helper.remove(), 16613 !1 16614 }, 16615 _updateVirtualBoundaries: function(t) { 16616 var e, i, n, s, o, r = this.options; 16617 o = { 16618 minWidth: f(r.minWidth) ? r.minWidth : 0, 16619 maxWidth: f(r.maxWidth) ? r.maxWidth : 1 / 0, 16620 minHeight: f(r.minHeight) ? r.minHeight : 0, 16621 maxHeight: f(r.maxHeight) ? r.maxHeight : 1 / 0 16622 }, 16623 (this._aspectRatio || t) && (e = o.minHeight * this.aspectRatio, 16624 n = o.minWidth / this.aspectRatio, 16625 i = o.maxHeight * this.aspectRatio, 16626 s = o.maxWidth / this.aspectRatio, 16627 e > o.minWidth && (o.minWidth = e), 16628 n > o.minHeight && (o.minHeight = n), 16629 i < o.maxWidth && (o.maxWidth = i), 16630 s < o.maxHeight && (o.maxHeight = s)), 16631 this._vBoundaries = o 16632 }, 16633 _updateCache: function(t) { 16634 this.options; 16635 this.offset = this.helper.offset(), 16636 f(t.left) && (this.position.left = t.left), 16637 f(t.top) && (this.position.top = t.top), 16638 f(t.height) && (this.size.height = t.height), 16639 f(t.width) && (this.size.width = t.width) 16640 }, 16641 _updateRatio: function(t) { 16642 this.options; 16643 var e = this.position 16644 , i = this.size 16645 , n = this.axis; 16646 return f(t.height) ? t.width = t.height * this.aspectRatio : f(t.width) && (t.height = t.width / this.aspectRatio), 16647 "sw" == n && (t.left = e.left + (i.width - t.width), 16648 t.top = null),
16649 "nw" == n && (t.top = e.top + (i.height - t.height), 16650 t.left = e.left + (i.width - t.width)), 16651 t 16652 }, 16653 _respectSize: function(t, e) { 16654 this.helper; 16655 var i = this._vBoundaries 16656 , n = (this._aspectRatio || e.shiftKey, 16657 this.axis) 16658 , s = f(t.width) && i.maxWidth && i.maxWidth < t.width 16659 , o = f(t.height) && i.maxHeight && i.maxHeight < t.height 16660 , r = f(t.width) && i.minWidth && i.minWidth > t.width 16661 , a = f(t.height) && i.minHeight && i.minHeight > t.height; 16662 r && (t.width = i.minWidth), 16663 a && (t.height = i.minHeight), 16664 s && (t.width = i.maxWidth), 16665 o && (t.height = i.maxHeight); 16666 var l = this.originalPosition.left + this.originalSize.width 16667 , c = this.position.top + this.size.height 16668 , u = /sw|nw|w/.test(n) 16669 , h = /nw|ne|n/.test(n); 16670 r && u && (t.left = l - i.minWidth), 16671 s && u && (t.left = l - i.maxWidth), 16672 a && h && (t.top = c - i.minHeight), 16673 o && h && (t.top = c - i.maxHeight); 16674 var d = !t.width && !t.height; 16675 return d && !t.left && t.top ? t.top = null : d && !t.top && t.left && (t.left = null), 16676 t 16677 }, 16678 _proportionallyResize: function() { 16679 this.options; 16680 if (this._proportionallyResizeElements.length) 16681 for (var t = this.helper || this.element, e = 0; e < this._proportionallyResizeElements.length; e++) { 16682 var i = this._proportionallyResizeElements[e]; 16683 if (!this.borderDif) { 16684 var n = [i.css("borderTopWidth"), i.css("borderRightWidth"), i.css("borderBottomWidth"), i.css("borderLeftWidth")] 16685 , s = [i.css("paddingTop"), i.css("paddingRight"), i.css("paddingBottom"), i.css("paddingLeft")]; 16686 this.borderDif = d.map(n, function(t, e) { 16687 return (parseInt(t, 10) || 0) + (parseInt(s[e], 10) || 0) 16688 }) 16689 } 16690 i.css({ 16691 height: t.height() - this.borderDif[0] - this.borderDif[2] || 0, 16692 width: t.width() - this.borderDif[1] - this.borderDif[3] || 0 16693 }) 16694 } 16695 }, 16696 _renderProxy: function() { 16697 var t = this.element 16698 , e = this.options; 16699 if (this.elementOffset = t.offset(), 16700 this._helper) { 16701 this.helper = this.helper || d('<div style="overflow:hidden;"></div>'); 16702 var i = d.browser.msie && d.browser.version < 7 16703 , n = i ? 1 : 0 16704 , s = i ? 2 : -1; 16705 this.helper.addClass(this._helper).css({ 16706 width: this.element.outerWidth() + s, 16707 height: this.element.outerHeight() + s, 16708 position: "absolute", 16709 left: this.elementOffset.left - n + "px", 16710 top: this.elementOffset.top - n + "px", 16711 zIndex: ++e.zIndex 16712 }), 16713 this.helper.appendTo("body").disableSelection() 16714 } else 16715 this.helper = this.element 16716 }, 16717 _change: { 16718 e: function(t, e) { 16719 return { 16720 width: this.originalSize.width + e 16721 } 16722 }, 16723 w: function(t, e) { 16724 this.options; 16725 var i = this.originalSize; 16726 return { 16727 left: this.originalPosition.left + e, 16728 width: i.width - e 16729 } 16730 }, 16731 n: function(t, e, i) { 16732 this.options; 16733 var n = this.originalSize; 16734 return { 16735 top: this.originalPosition.top + i, 16736 height: n.height - i 16737 } 16738 }, 16739 s: function(t, e, i) { 16740 return { 16741 height: this.originalSize.height + i 16742 } 16743 }, 16744 se: function(t, e, i) { 16745 return d.extend(this._change.s.apply(this, arguments), this._change.e.apply(this, [t, e, i])) 16746 }, 16747 sw: function(t, e, i) { 16748 return d.extend(this._change.s.apply(this, arguments), this._change.w.apply(this, [t, e, i])) 16749 }, 16750 ne: function(t, e, i) { 16751 return d.extend(this._change.n.apply(this, arguments), this._change.e.apply(this, [t, e, i])) 16752 }, 16753 nw: function(t, e, i) { 16754 return d.extend(this._change.n.apply(this, arguments), this._change.w.apply(this, [t, e, i])) 16755 } 16756 }, 16757 _propagate: function(t, e) { 16758 d.ui.plugin.call(this, t, [e, this.ui()]), 16759 "resize" != t && this._trigger(t, e, this.ui()) 16760 }, 16761 plugins: {}, 16762 ui: function() { 16763 return { 16764 originalElement: this.originalElement, 16765 element: this.element, 16766 helper: this.helper, 16767 position: this.position, 16768 size: this.size, 16769 originalSize: this.originalSize, 16770 originalPosition: this.originalPosition 16771 } 16772 } 16773 }), 16774 d.ui.plugin.add("resizable", "alsoResize", { 16775 start: function() { 16776 var t = d(this).data("resizable").options 16777 , e = function(t) { 16778 d(t).each(function() { 16779 var t = d(this); 16780 t.data("resizable-alsoresize", { 16781 width: parseInt(t.width(), 10), 16782 height: parseInt(t.height(), 10), 16783 left: parseInt(t.css("left"), 10), 16784 top: parseInt(t.css("top"), 10) 16785 }) 16786 }) 16787 }; 16788 "object" != typeof t.alsoResize || t.alsoResize.parentNode ? e(t.alsoResize) : t.alsoResize.length ? (t.alsoResize = t.alsoResize[0], 16789 e(t.alsoResize)) : d.each(t.alsoResize, function(t) { 16790 e(t) 16791 }) 16792 }, 16793 resize: function(t, o) { 16794 var e = d(this).data("resizable") 16795 , i = e.options 16796 , n = e.originalSize 16797 , s = e.originalPosition 16798 , r = { 16799 height: e.size.height - n.height || 0, 16800 width: e.size.width - n.width || 0, 16801 top: e.position.top - s.top || 0, 16802 left: e.position.left - s.left || 0 16803 } 16804 , a = function(t, i) { 16805 d(t).each(function() { 16806 var t = d(this) 16807 , n = d(this).data("resizable-alsoresize") 16808 , s = {} 16809 , e = i && i.length ? i : t.parents(o.originalElement[0]).length ? ["width", "height"] : ["width", "height", "top", "left"]; 16810 d.each(e, function(t, e) { 16811 var i = (n[e] || 0) + (r[e] || 0); 16812 i && 0 <= i && (s[e] = i || null) 16813 }), 16814 t.css(s) 16815 }) 16816 }; 16817 "object" != typeof i.alsoResize || i.alsoResize.nodeType ? a(i.alsoResize) : d.each(i.alsoResize, function(t, e) { 16818 a(t, e) 16819 }) 16820 }, 16821 stop: function() { 16822 d(this).removeData("resizable-alsoresize") 16823 } 16824 }), 16825 d.ui.plugin.add("resizable", "animate", { 16826 stop: function(e) { 16827 var i = d(this).data("resizable") 16828 , t = i.options 16829 , n = i._proportionallyResizeElements 16830 , s = n.length && /textarea/i.test(n[0].nodeName) 16831 , o = s && d.ui.hasScroll(n[0], "left") ? 0 : i.sizeDiff.height 16832 , r = s ? 0 : i.sizeDiff.width 16833 , a = { 16834 width: i.size.width - r, 16835 height: i.size.height - o 16836 } 16837 , l = parseInt(i.element.css("left"), 10) + (i.position.left - i.originalPosition.left) || null 16838 , c = parseInt(i.element.css("top"), 10) + (i.position.top - i.originalPosition.top) || null; 16839 i.element.animate(d.extend(a, c && l ? { 16840 top: c, 16841 left: l 16842 } : {}), { 16843 duration: t.animateDuration, 16844 easing: t.animateEasing, 16845 step: function() { 16846 var t = { 16847 width: parseInt(i.element.css("width"), 10), 16848 height: parseInt(i.element.css("height"), 10), 16849 top: parseInt(i.element.css("top"), 10), 16850 left: parseInt(i.element.css("left"), 10) 16851 }; 16852 n && n.length && d(n[0]).css({ 16853 width: t.width, 16854 height: t.height 16855 }), 16856 i._updateCache(t), 16857 i._propagate("resize", e) 16858 } 16859 }) 16860 } 16861 }), 16862 d.ui.plugin.add("resizable", "containment", { 16863 start: function() { 16864 var t = d(this).data("resizable") 16865 , e = t.options 16866 , i = t.element 16867 , n = e.containment 16868 , s = n instanceof d ? n.get(0) : /parent/.test(n) ? i.parent().get(0) : n; 16869 if (s) 16870 if (t.containerElement = d(s), 16871 /document/.test(n) || n == document) 16872 t.containerOffset = { 16873 left: 0, 16874 top: 0 16875 }, 16876 t.containerPosition = { 16877 left: 0, 16878 top: 0 16879 }, 16880 t.parentData = { 16881 element: d(document), 16882 left: 0, 16883 top: 0, 16884 width: d(document).width(), 16885 height: d(document).height() || document.body.parentNode.scrollHeight 16886 }; 16887 else { 16888 var o = d(s) 16889 , r = []; 16890 d(["Top", "Right", "Left", "Bottom"]).each(function(t, e) { 16891 r[t] = p(o.css("padding" + e)) 16892 }), 16893 t.containerOffset = o.offset(), 16894 t.containerPosition = o.position(), 16895 t.containerSize = { 16896 height: o.innerHeight() - r[3], 16897 width: o.innerWidth() - r[1] 16898 }; 16899 var a = t.containerOffset 16900 , l = t.containerSize.height 16901 , c = t.containerSize.width 16902 , u = d.ui.hasScroll(s, "left") ? s.scrollWidth : c 16903 , h = d.ui.hasScroll(s) ? s.scrollHeight : l; 16904 t.parentData = { 16905 element: s, 16906 left: a.left, 16907 top: a.top, 16908 width: u, 16909 height: h 16910 } 16911 } 16912 }, 16913 resize: function(t) { 16914 var e = d(this).data("resizable") 16915 , i = e.options 16916 , n = (e.containerSize, 16917 e.containerOffset) 16918 , s = (e.size, 16919 e.position) 16920 , o = e._aspectRatio || t.shiftKey 16921 , r = { 16922 top: 0, 16923 left: 0 16924 } 16925 , a = e.containerElement; 16926 a[0] != document && /static/.test(a.css("position")) && (r = n), 16927 s.left < (e._helper ? n.left : 0) && (e.size.width = e.size.width + (e._helper ? e.position.left - n.left : e.position.left - r.left), 16928 o && (e.size.height = e.size.width / e.aspectRatio), 16929 e.position.left = i.helper ? n.left : 0), 16930 s.top < (e._helper ? n.top : 0) && (e.size.height = e.size.height + (e._helper ? e.position.top - n.top : e.position.top), 16931 o && (e.size.width = e.size.height * e.aspectRatio), 16932 e.position.top = e._helper ? n.top : 0), 16933 e.offset.left = e.parentData.left + e.position.left, 16934 e.offset.top = e.parentData.top + e.position.top; 16935 var l = Math.abs((e._helper, 16936 e.offset.left - r.left + e.sizeDiff.width)) 16937 , c = Math.abs((e._helper ? e.offset.top - r.top : e.offset.top - n.top) + e.sizeDiff.height) 16938 , u = e.containerElement.get(0) == e.element.parent().get(0) 16939 , h = /relative|absolute/.test(e.containerElement.css("position")); 16940 u && h && (l -= e.parentData.left), 16941 l + e.size.width >= e.parentData.width && (e.size.width = e.parentData.width - l, 16942 o && (e.size.height = e.size.width / e.aspectRatio)), 16943 c + e.size.height >= e.parentData.height && (e.size.height = e.parentData.height - c, 16944 o && (e.size.width = e.size.height * e.aspectRatio)) 16945 }, 16946 stop: function() { 16947 var t = d(this).data("resizable") 16948 , e = t.options 16949 , i = (t.position, 16950 t.containerOffset) 16951 , n = t.containerPosition 16952 , s = t.containerElement 16953 , o = d(t.helper) 16954 , r = o.offset() 16955 , a = o.outerWidth() - t.sizeDiff.width 16956 , l = o.outerHeight() - t.sizeDiff.height; 16957 t._helper && !e.animate && /relative/.test(s.css("position")) && d(this).css({ 16958 left: r.left - n.left - i.left, 16959 width: a, 16960 height: l 16961 }), 16962 t._helper && !e.animate && /static/.test(s.css("position")) && d(this).css({ 16963 left: r.left - n.left - i.left, 16964 width: a, 16965 height: l 16966 }) 16967 } 16968 }), 16969 d.ui.plugin.add("resizable", "ghost", { 16970 start: function() { 16971 var t = d(this).data("resizable") 16972 , e = t.options 16973 , i = t.size; 16974 t.ghost = t.originalElement.clone(), 16975 t.ghost.css({ 16976 opacity: .25, 16977 display: "block", 16978 position: "relative", 16979 height: i.height, 16980 width: i.width, 16981 margin: 0, 16982 left: 0, 16983 top: 0 16984 }).addClass("ui-resizable-ghost").addClass("string" == typeof e.ghost ? e.ghost : ""), 16985 t.ghost.appendTo(t.helper) 16986 }, 16987 resize: function() { 16988 var t = d(this).data("resizable"); 16989 t.options; 16990 t.ghost && t.ghost.css({ 16991 position: "relative", 16992 height: t.size.height, 16993 width: t.size.width 16994 }) 16995 }, 16996 stop: function() { 16997 var t = d(this).data("resizable"); 16998 t.options; 16999 t.ghost && t.helper && t.helper.get(0).removeChild(t.ghost.get(0)) 17000 } 17001 }), 17002 d.ui.plugin.add("resizable", "grid", { 17003 resize: function(t) { 17004 var e = d(this).data("resizable") 17005 , i = e.options 17006 , n = e.size 17007 , s = e.originalSize 17008 , o = e.originalPosition 17009 , r = e.axis; 17010 i._aspectRatio || t.shiftKey; 17011 i.grid = "number" == typeof i.grid ? [i.grid, i.grid] : i.grid; 17012 var a = Math.round((n.width - s.width) / (i.grid[0] || 1)) * (i.grid[0] || 1) 17013 , l = Math.round((n.height - s.height) / (i.grid[1] || 1)) * (i.grid[1] || 1); 17014 /^(se|s|e)$/.test(r) ? (e.size.width = s.width + a, 17015 e.size.height = s.height + l) : /^(ne)$/.test(r) ? (e.size.width = s.width + a, 17016 e.size.height = s.height + l, 17017 e.position.top = o.top - l) : (/^(sw)$/.test(r) ? (e.size.width = s.width + a, 17018 e.size.height = s.height + l) : (e.size.width = s.width + a, 17019 e.size.height = s.height + l, 17020 e.position.top = o.top - l), 17021 e.position.left = o.left - a) 17022 } 17023 }); 17024 var p = function(t) { 17025 return parseInt(t, 10) || 0 17026 } 17027 , f = function(t) { 17028 return !isNaN(parseInt(t, 10)) 17029 } 17030}(jQuery), 17031function(c) { 17032 c.widget("ui.selectable", c.ui.mouse, { 17033 version: "1.9.0", 17034 options: { 17035 appendTo: "body", 17036 autoRefresh: !0, 17037 distance: 0, 17038 filter: "*", 17039 tolerance: "touch" 17040 }, 17041 _create: function() { 17042 var t, e = this; 17043 this.element.addClass("ui-selectable"), 17044 this.dragged = !1, 17045 this.refresh = function() { 17046 (t = c(e.options.filter, e.element[0])).addClass("ui-selectee"), 17047 t.each(function() { 17048 var t = c(this) 17049 , e = t.offset(); 17050 c.data(this, "selectable-item", { 17051 element: this, 17052 $element: t, 17053 left: e.left, 17054 top: e.top, 17055 right: e.left + t.outerWidth(), 17056 bottom: e.top + t.outerHeight(), 17057 startselected: !1, 17058 selected: t.hasClass("ui-selected"), 17059 selecting: t.hasClass("ui-selecting"), 17060 unselecting: t.hasClass("ui-unselecting") 17061 }) 17062 }) 17063 } 17064 , 17065 this.refresh(), 17066 this.selectees = t.addClass("ui-selectee"), 17067 this._mouseInit(), 17068 this.helper = c("<div class='ui-selectable-helper'></div>") 17069 }, 17070 _destroy: function() { 17071 this.selectees.removeClass("ui-selectee").removeData("selectable-item"), 17072 this.element.removeClass("ui-selectable ui-selectable-disabled"), 17073 this._mouseDestroy() 17074 }, 17075 _mouseStart: function(i) { 17076 var n = this; 17077 if (this.opos = [i.pageX, i.pageY], 17078 !this.options.disabled) { 17079 var t = this.options; 17080 this.selectees = c(t.filter, this.element[0]), 17081 this._trigger("start", i), 17082 c(t.appendTo).append(this.helper), 17083 this.helper.css({ 17084 left: i.clientX, 17085 top: i.clientY, 17086 width: 0, 17087 height: 0 17088 }), 17089 t.autoRefresh && this.refresh(), 17090 this.selectees.filter(".ui-selected").each(function() { 17091 var t = c.data(this, "selectable-item"); 17092 t.startselected = !0, 17093 i.metaKey || i.ctrlKey || (t.$element.removeClass("ui-selected"), 17094 t.selected = !1, 17095 t.$element.addClass("ui-unselecting"), 17096 t.unselecting = !0, 17097 n._trigger("unselecting", i, { 17098 unselecting: t.element 17099 })) 17100 }), 17101 c(i.target).parents().andSelf().each(function() { 17102 var t = c.data(this, "selectable-item"); 17103 if (t) { 17104 var e = !i.metaKey && !i.ctrlKey || !t.$element.hasClass("ui-selected"); 17105 return t.$element.removeClass(e ? "ui-unselecting" : "ui-selected").addClass(e ? "ui-selecting" : "ui-unselecting"), 17106 t.unselecting = !e, 17107 t.selecting = e, 17108 (t.selected = e) ? n._trigger("selecting", i, { 17109 selecting: t.element 17110 }) : n._trigger("unselecting", i, { 17111
vendor: 13,657 bytes, lines 17111-17441
17111 unselecting: t.element 17112 }), 17113 !1 17114 } 17115 }) 17116 } 17117 }, 17118 _mouseDrag: function(i) { 17119 var n = this; 17120 if (this.dragged = !0, 17121 !this.options.disabled) { 17122 var s = this.options 17123 , o = this.opos[0] 17124 , r = this.opos[1] 17125 , a = i.pageX 17126 , l = i.pageY; 17127 if (a < o) { 17128 var t = a; 17129 a = o, 17130 o = t 17131 } 17132 if (l < r) { 17133 t = l; 17134 l = r, 17135 r = t 17136 } 17137 return this.helper.css({ 17138 left: o, 17139 top: r, 17140 width: a - o, 17141 height: l - r 17142 }), 17143 this.selectees.each(function() { 17144 var t = c.data(this, "selectable-item"); 17145 if (t && t.element != n.element[0]) { 17146 var e = !1; 17147 "touch" == s.tolerance ? e = !(t.left > a || t.right < o || t.top > l || t.bottom < r) : "fit" == s.tolerance && (e = t.left > o && t.right < a && t.top > r && t.bottom < l), 17148 e ? (t.selected && (t.$element.removeClass("ui-selected"), 17149 t.selected = !1), 17150 t.unselecting && (t.$element.removeClass("ui-unselecting"), 17151 t.unselecting = !1), 17152 t.selecting || (t.$element.addClass("ui-selecting"), 17153 t.selecting = !0, 17154 n._trigger("selecting", i, { 17155 selecting: t.element 17156 }))) : (t.selecting && ((i.metaKey || i.ctrlKey) && t.startselected ? (t.$element.removeClass("ui-selecting"), 17157 t.selecting = !1, 17158 t.$element.addClass("ui-selected"), 17159 t.selected = !0) : (t.$element.removeClass("ui-selecting"), 17160 t.selecting = !1, 17161 t.startselected && (t.$element.addClass("ui-unselecting"), 17162 t.unselecting = !0), 17163 n._trigger("unselecting", i, { 17164 unselecting: t.element 17165 }))), 17166 t.selected && (i.metaKey || i.ctrlKey || t.startselected || (t.$element.removeClass("ui-selected"), 17167 t.selected = !1, 17168 t.$element.addClass("ui-unselecting"), 17169 t.unselecting = !0, 17170 n._trigger("unselecting", i, { 17171 unselecting: t.element 17172 })))) 17173 } 17174 }), 17175 !1 17176 } 17177 }, 17178 _mouseStop: function(e) { 17179 var i = this; 17180 this.dragged = !1; 17181 this.options; 17182 return c(".ui-unselecting", this.element[0]).each(function() { 17183 var t = c.data(this, "selectable-item"); 17184 t.$element.removeClass("ui-unselecting"), 17185 t.unselecting = !1, 17186 t.startselected = !1, 17187 i._trigger("unselected", e, { 17188 unselected: t.element 17189 }) 17190 }), 17191 c(".ui-selecting", this.element[0]).each(function() { 17192 var t = c.data(this, "selectable-item"); 17193 t.$element.removeClass("ui-selecting").addClass("ui-selected"), 17194 t.selecting = !1, 17195 t.selected = !0, 17196 t.startselected = !0, 17197 i._trigger("selected", e, { 17198 selected: t.element 17199 }) 17200 }), 17201 this._trigger("stop", e), 17202 this.helper.remove(), 17203 !1 17204 } 17205 }) 17206}(jQuery), 17207function(d) { 17208 d.widget("ui.sortable", d.ui.mouse, { 17209 version: "1.9.0", 17210 widgetEventPrefix: "sort", 17211 ready: !1, 17212 options: { 17213 appendTo: "parent", 17214 axis: !1, 17215 connectWith: !1, 17216 containment: !1, 17217 cursor: "auto", 17218 cursorAt: !1, 17219 dropOnEmpty: !0, 17220 forcePlaceholderSize: !1, 17221 forceHelperSize: !1, 17222 grid: !1, 17223 handle: !1, 17224 helper: "original", 17225 items: "> *", 17226 opacity: !1, 17227 placeholder: !1, 17228 revert: !1, 17229 scroll: !0, 17230 scrollSensitivity: 20, 17231 scrollSpeed: 20, 17232 scope: "default", 17233 tolerance: "intersect", 17234 zIndex: 1e3 17235 }, 17236 _create: function() { 17237 var t = this.options; 17238 this.containerCache = {}, 17239 this.element.addClass("ui-sortable"), 17240 this.refresh(), 17241 this.floating = !!this.items.length && ("x" === t.axis || /left|right/.test(this.items[0].item.css("float")) || /inline|table-cell/.test(this.items[0].item.css("display"))), 17242 this.offset = this.element.offset(), 17243 this._mouseInit(), 17244 this.ready = !0 17245 }, 17246 _destroy: function() { 17247 this.element.removeClass("ui-sortable ui-sortable-disabled"), 17248 this._mouseDestroy(); 17249 for (var t = this.items.length - 1; 0 <= t; t--) 17250 this.items[t].item.removeData(this.widgetName + "-item"); 17251 return this 17252 }, 17253 _setOption: function(t, e) { 17254 "disabled" === t ? (this.options[t] = e, 17255 this.widget().toggleClass("ui-sortable-disabled", !!e)) : d.Widget.prototype._setOption.apply(this, arguments) 17256 }, 17257 _mouseCapture: function(t, e) { 17258 var i = this; 17259 if (this.reverting) 17260 return !1; 17261 if (this.options.disabled || "static" == this.options.type) 17262 return !1; 17263 this._refreshItems(t); 17264 var n = null; 17265 d(t.target).parents().each(function() { 17266 if (d.data(this, i.widgetName + "-item") == i) 17267 return n = d(this), 17268 !1 17269 }); 17270 if (d.data(t.target, i.widgetName + "-item") == i && (n = d(t.target)), 17271 !n) 17272 return !1; 17273 if (this.options.handle && !e) { 17274 var s = !1; 17275 if (d(this.options.handle, n).find("*").andSelf().each(function() { 17276 this == t.target && (s = !0) 17277 }), 17278 !s) 17279 return !1 17280 } 17281 return this.currentItem = n, 17282 this._removeCurrentsFromItems(), 17283 !0 17284 }, 17285 _mouseStart: function(t, e, i) { 17286 var n = this.options; 17287 if ((this.currentContainer = this).refreshPositions(), 17288 this.helper = this._createHelper(t), 17289 this._cacheHelperProportions(), 17290 this._cacheMargins(), 17291 this.scrollParent = this.helper.scrollParent(), 17292 this.offset = this.currentItem.offset(), 17293 this.offset = { 17294 top: this.offset.top - this.margins.top, 17295 left: this.offset.left - this.margins.left 17296 }, 17297 d.extend(this.offset, { 17298 click: { 17299 left: t.pageX - this.offset.left, 17300 top: t.pageY - this.offset.top 17301 }, 17302 parent: this._getParentOffset(), 17303 relative: this._getRelativeOffset() 17304 }), 17305 this.helper.css("position", "absolute"), 17306 this.cssPosition = this.helper.css("position"), 17307 this.originalPosition = this._generatePosition(t), 17308 this.originalPageX = t.pageX, 17309 this.originalPageY = t.pageY, 17310 n.cursorAt && this._adjustOffsetFromHelper(n.cursorAt), 17311 this.domPosition = { 17312 prev: this.currentItem.prev()[0], 17313 parent: this.currentItem.parent()[0] 17314 }, 17315 this.helper[0] != this.currentItem[0] && this.currentItem.hide(), 17316 this._createPlaceholder(), 17317 n.containment && this._setContainment(), 17318 n.cursor && (d("body").css("cursor") && (this._storedCursor = d("body").css("cursor")), 17319 d("body").css("cursor", n.cursor)), 17320 n.opacity && (this.helper.css("opacity") && (this._storedOpacity = this.helper.css("opacity")), 17321 this.helper.css("opacity", n.opacity)), 17322 n.zIndex && (this.helper.css("zIndex") && (this._storedZIndex = this.helper.css("zIndex")), 17323 this.helper.css("zIndex", n.zIndex)), 17324 this.scrollParent[0] != document && "HTML" != this.scrollParent[0].tagName && (this.overflowOffset = this.scrollParent.offset()), 17325 this._trigger("start", t, this._uiHash()), 17326 this._preserveHelperProportions || this._cacheHelperProportions(), 17327 !i) 17328 for (var s = this.containers.length - 1; 0 <= s; s--) 17329 this.containers[s]._trigger("activate", t, this._uiHash(this)); 17330 return d.ui.ddmanager && (d.ui.ddmanager.current = this), 17331 d.ui.ddmanager && !n.dropBehaviour && d.ui.ddmanager.prepareOffsets(this, t), 17332 this.dragging = !0, 17333 this.helper.addClass("ui-sortable-helper"), 17334 this._mouseDrag(t), 17335 !0 17336 }, 17337 _mouseDrag: function(t) { 17338 if (this.position = this._generatePosition(t), 17339 this.positionAbs = this._convertPositionTo("absolute"), 17340 this.lastPositionAbs || (this.lastPositionAbs = this.positionAbs), 17341 this.options.scroll) { 17342 var e = this.options 17343 , i = !1; 17344 this.scrollParent[0] != document && "HTML" != this.scrollParent[0].tagName ? (this.overflowOffset.top + this.scrollParent[0].offsetHeight - t.pageY < e.scrollSensitivity ? this.scrollParent[0].scrollTop = i = this.scrollParent[0].scrollTop + e.scrollSpeed : t.pageY - this.overflowOffset.top < e.scrollSensitivity && (this.scrollParent[0].scrollTop = i = this.scrollParent[0].scrollTop - e.scrollSpeed), 17345 this.overflowOffset.left + this.scrollParent[0].offsetWidth - t.pageX < e.scrollSensitivity ? this.scrollParent[0].scrollLeft = i = this.scrollParent[0].scrollLeft + e.scrollSpeed : t.pageX - this.overflowOffset.left < e.scrollSensitivity && (this.scrollParent[0].scrollLeft = i = this.scrollParent[0].scrollLeft - e.scrollSpeed)) : (t.pageY - d(document).scrollTop() < e.scrollSensitivity ? i = d(document).scrollTop(d(document).scrollTop() - e.scrollSpeed) : d(window).height() - (t.pageY - d(document).scrollTop()) < e.scrollSensitivity && (i = d(document).scrollTop(d(document).scrollTop() + e.scrollSpeed)), 17346 t.pageX - d(document).scrollLeft() < e.scrollSensitivity ? i = d(document).scrollLeft(d(document).scrollLeft() - e.scrollSpeed) : d(window).width() - (t.pageX - d(document).scrollLeft()) < e.scrollSensitivity && (i = d(document).scrollLeft(d(document).scrollLeft() + e.scrollSpeed))), 17347 !1 !== i && d.ui.ddmanager && !e.dropBehaviour && d.ui.ddmanager.prepareOffsets(this, t) 17348 } 17349 this.positionAbs = this._convertPositionTo("absolute"), 17350 this.options.axis && "y" == this.options.axis || (this.helper[0].style.left = this.position.left + "px"), 17351 this.options.axis && "x" == this.options.axis || (this.helper[0].style.top = this.position.top + "px"); 17352 for (var n = this.items.length - 1; 0 <= n; n--) { 17353 var s = this.items[n] 17354 , o = s.item[0] 17355 , r = this._intersectsWithPointer(s); 17356 if (r && (s.instance === this.currentContainer && !(o == this.currentItem[0] || this.placeholder[1 == r ? "next" : "prev"]()[0] == o || d.contains(this.placeholder[0], o) || "semi-dynamic" == this.options.type && d.contains(this.element[0], o)))) { 17357 if (this.direction = 1 == r ? "down" : "up", 17358 "pointer" != this.options.tolerance && !this._intersectsWithSides(s)) 17359 break; 17360 this._rearrange(t, s), 17361 this._trigger("change", t, this._uiHash()); 17362 break 17363 } 17364 } 17365 return this._contactContainers(t), 17366 d.ui.ddmanager && d.ui.ddmanager.drag(this, t), 17367 this._trigger("sort", t, this._uiHash()), 17368 this.lastPositionAbs = this.positionAbs, 17369 !1 17370 }, 17371 _mouseStop: function(t, e) { 17372 if (t) { 17373 if (d.ui.ddmanager && !this.options.dropBehaviour && d.ui.ddmanager.drop(this, t), 17374 this.options.revert) { 17375 var i = this 17376 , n = this.placeholder.offset(); 17377 this.reverting = !0, 17378 d(this.helper).animate({ 17379 left: n.left - this.offset.parent.left - this.margins.left + (this.offsetParent[0] == document.body ? 0 : this.offsetParent[0].scrollLeft), 17380 top: n.top - this.offset.parent.top - this.margins.top + (this.offsetParent[0] == document.body ? 0 : this.offsetParent[0].scrollTop) 17381 }, parseInt(this.options.revert, 10) || 500, function() { 17382 i._clear(t) 17383 }) 17384 } else 17385 this._clear(t, e); 17386 return !1 17387 } 17388 }, 17389 cancel: function() { 17390 if (this.dragging) { 17391 this._mouseUp({ 17392 target: null 17393 }), 17394 "original" == this.options.helper ? this.currentItem.css(this._storedCSS).removeClass("ui-sortable-helper") : this.currentItem.show(); 17395 for (var t = this.containers.length - 1; 0 <= t; t--) 17396 this.containers[t]._trigger("deactivate", null, this._uiHash(this)), 17397 this.containers[t].containerCache.over && (this.containers[t]._trigger("out", null, this._uiHash(this)), 17398 this.containers[t].containerCache.over = 0) 17399 } 17400 return this.placeholder && (this.placeholder[0].parentNode && this.placeholder[0].parentNode.removeChild(this.placeholder[0]), 17401 "original" != this.options.helper && this.helper && this.helper[0].parentNode && this.helper.remove(), 17402 d.extend(this, { 17403 helper: null, 17404 dragging: !1, 17405 reverting: !1, 17406 _noFinalSort: null 17407 }), 17408 this.domPosition.prev ? d(this.domPosition.prev).after(this.currentItem) : d(this.domPosition.parent).prepend(this.currentItem)), 17409 this 17410 }, 17411 serialize: function(e) { 17412 var t = this._getItemsAsjQuery(e && e.connected) 17413 , i = []; 17414 return e = e || {}, 17415 d(t).each(function() { 17416 var t = (d(e.item || this).attr(e.attribute || "id") || "").match(e.expression || /(.+)[-=_](.+)/); 17417 t && i.push((e.key || t[1] + "[]") + "=" + (e.key && e.expression ? t[1] : t[2])) 17418 }), 17419 !i.length && e.key && i.push(e.key + "="), 17420 i.join("&") 17421 }, 17422 toArray: function(t) { 17423 var e = this._getItemsAsjQuery(t && t.connected) 17424 , i = []; 17425 return t = t || {}, 17426 e.each(function() { 17427 i.push(d(t.item || this).attr(t.attribute || "id") || "") 17428 }), 17429 i 17430 }, 17431 _intersectsWith: function(t) { 17432 var e = this.positionAbs.left 17433 , i = e + this.helperProportions.width 17434 , n = this.positionAbs.top 17435 , s = n + this.helperProportions.height 17436 , o = t.left 17437 , r = o + t.width 17438 , a = t.top 17439 , l = a + t.height 17440 , c = this.offset.click.top 17441 , u = this.offset.click.left
17442 , h = a < n + c && n + c < l && o < e + u && e + u < r; 17443 return "pointer" == this.options.tolerance || this.options.forcePointerForContainers || "pointer" != this.options.tolerance && this.helperProportions[this.floating ? "width" : "height"] > t[this.floating ? "width" : "height"] ? h : o < e + this.helperProportions.width / 2 && i - this.helperProportions.width / 2 < r && a < n + this.helperProportions.height / 2 && s - this.helperProportions.height / 2 < l 17444 }, 17445 _intersectsWithPointer: function(t) { 17446 var e = "x" === this.options.axis || d.ui.isOverAxis(this.positionAbs.top + this.offset.click.top, t.top, t.height) 17447 , i = "y" === this.options.axis || d.ui.isOverAxis(this.positionAbs.left + this.offset.click.left, t.left, t.width) 17448 , n = e && i 17449 , s = this._getDragVerticalDirection() 17450 , o = this._getDragHorizontalDirection(); 17451 return !!n && (this.floating ? o && "right" == o || "down" == s ? 2 : 1 : s && ("down" == s ? 2 : 1)) 17452 }, 17453 _intersectsWithSides: function(t) { 17454 var e = d.ui.isOverAxis(this.positionAbs.top + this.offset.click.top, t.top + t.height / 2, t.height) 17455 , i = d.ui.isOverAxis(this.positionAbs.left + this.offset.click.left, t.left + t.width / 2, t.width) 17456 , n = this._getDragVerticalDirection() 17457 , s = this._getDragHorizontalDirection(); 17458 return this.floating && s ? "right" == s && i || "left" == s && !i : n && ("down" == n && e || "up" == n && !e) 17459 }, 17460 _getDragVerticalDirection: function() { 17461 var t = this.positionAbs.top - this.lastPositionAbs.top; 17462 return 0 != t && (0 < t ? "down" : "up") 17463 }, 17464 _getDragHorizontalDirection: function() { 17465 var t = this.positionAbs.left - this.lastPositionAbs.left; 17466 return 0 != t && (0 < t ? "right" : "left") 17467 }, 17468 refresh: function(t) { 17469 return this._refreshItems(t), 17470 this.refreshPositions(), 17471 this 17472 }, 17473 _connectWith: function() { 17474 var t = this.options; 17475 return t.connectWith.constructor == String ? [t.connectWith] : t.connectWith 17476 }, 17477 _getItemsAsjQuery: function(t) { 17478 var e = [] 17479 , i = [] 17480 , n = this._connectWith(); 17481 if (n && t) 17482 for (var s = n.length - 1; 0 <= s; s--) 17483 for (var o = d(n[s]), r = o.length - 1; 0 <= r; r--) { 17484 var a = d.data(o[r], this.widgetName); 17485 a && a != this && !a.options.disabled && i.push([d.isFunction(a.options.items) ? a.options.items.call(a.element) : d(a.options.items, a.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"), a]) 17486 } 17487 i.push([d.isFunction(this.options.items) ? this.options.items.call(this.element, null, { 17488 options: this.options, 17489 item: this.currentItem 17490 }) : d(this.options.items, this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"), this]); 17491 for (s = i.length - 1; 0 <= s; s--) 17492 i[s][0].each(function() { 17493 e.push(this) 17494 }); 17495 return d(e) 17496 }, 17497 _removeCurrentsFromItems: function() { 17498 for (var t = this.currentItem.find(":data(" + this.widgetName + "-item)"), e = 0; e < this.items.length; e++) 17499 for (var i = 0; i < t.length; i++) 17500 t[i] == this.items[e].item[0] && this.items.splice(e, 1) 17501 }, 17502 _refreshItems: function(t) { 17503 this.items = [], 17504 this.containers = [this]; 17505 var e = this.items 17506 , i = [[d.isFunction(this.options.items) ? this.options.items.call(this.element[0], t, { 17507 item: this.currentItem 17508 }) : d(this.options.items, this.element), this]] 17509 , n = this._connectWith(); 17510 if (n && this.ready) 17511 for (var s = n.length - 1; 0 <= s; s--) 17512 for (var o = d(n[s]), r = o.length - 1; 0 <= r; r--) { 17513 var a = d.data(o[r], this.widgetName); 17514 a && a != this && !a.options.disabled && (i.push([d.isFunction(a.options.items) ? a.options.items.call(a.element[0], t, { 17515 item: this.currentItem 17516 }) : d(a.options.items, a.element), a]), 17517 this.containers.push(a)) 17518 } 17519 for (s = i.length - 1; 0 <= s; s--) 17520 for (var l = i[s][1], c = i[s][0], u = (r = 0, 17521 c.length); r < u; r++) { 17522 var h = d(c[r]); 17523 h.data(this.widgetName + "-item", l), 17524 e.push({ 17525 item: h, 17526 instance: l, 17527 width: 0, 17528 height: 0, 17529 left: 0, 17530 top: 0 17531 }) 17532 } 17533 }, 17534 refreshPositions: function(t) { 17535 this.offsetParent && this.helper && (this.offset.parent = this._getParentOffset()); 17536 for (var e = this.items.length - 1; 0 <= e; e--) { 17537 var i = this.items[e]; 17538 if (i.instance == this.currentContainer || !this.currentContainer || i.item[0] == this.currentItem[0]) { 17539 var n = this.options.toleranceElement ? d(this.options.toleranceElement, i.item) : i.item; 17540 t || (i.width = n.outerWidth(), 17541 i.height = n.outerHeight()); 17542 var s = n.offset(); 17543 i.left = s.left, 17544 i.top = s.top 17545 } 17546 } 17547 if (this.options.custom && this.options.custom.refreshContainers
17547) 17548 this.options.custom.refreshContainers.call(this); 17549 else 17550 for (e = this.containers.length - 1; 0 <= e; e--) { 17551 s = this.containers[e].element.offset(); 17552 this.containers[e].containerCache.left = s.left, 17553 this.containers[e].containerCache.top = s.top, 17554 this.containers[e].containerCache.width = this.containers[e].element.outerWidth(), 17555 this.containers[e].containerCache.height = this.containers[e].element.outerHeight() 17556 } 17557 return this 17558 }, 17559 _createPlaceholder: function(i) { 17560 var n = (i = i || this).options; 17561 if (!n.placeholder || n.placeholder.constructor == String) { 17562 var s = n.placeholder; 17563 n.placeholder = { 17564 element: function() { 17565 var t = d(document.createElement(i.currentItem[0].nodeName)).addClass(s || i.currentItem[0].className + " ui-sortable-placeholder").removeClass("ui-sortable-helper")[0]; 17566 return s || (t.style.visibility = "hidden"), 17567 t 17568 }, 17569 update: function(t, e) { 17570 s && !n.forcePlaceholderSize || (e.height() || e.height(i.currentItem.innerHe
17570ight() - parseInt(i.currentItem.css("paddingTop") || 0, 10) - parseInt(i.currentItem.css("paddingBottom") || 0, 10)), 17571 e.width() || e.width(i.currentItem.innerWidth() - parseInt(i.currentItem.css("paddingLeft") || 0, 10) - parseInt(i.currentItem.css("paddingRight") || 0, 10))) 17572 } 17573 } 17574 } 17575 i.placeholder = d(n.placeholder.element.call(i.element, i.currentItem)), 17576 i.currentItem.after(i.placeholder), 17577 n.placeholder.update(i, i.placeholder) 17578 }, 17579 _contactContainers: function(t) { 17580 for (var e = null, i = null, n = this.containers.length - 1; 0 <= n; n--) 17581 if (!d.contains(this.currentItem[0], this.containers[n].element[0])) 17582 if (this._intersectsWith(this.containers[n].containerCache)) { 17583 if (e && d.contains(this.containers[n].element[0], e.element[0])) 17584 continue; 17585 e = this.containers[n], 17586 i = n 17587 } else 17588 this.containers[n].containerCache.over && (this.containers[n]._trigger("out", t, this._uiHash(this)), 17589 this.containers[n].containerCache.over = 0); 17590 if (e) 17591 if (1 === this.containers.length) 17592 this.containers[i]._trigger("over", t, this._uiHash(this)), 17593 this.containers[i].containerCache.over = 1; 17594 else if (this.currentContainer != this.containers[i]) { 17595 for (var s = 1e4, o = null, r = this.positionAbs[this.containers[i].floating ? "left" : "top"], a = this.items.length - 1; 0 <= a; a--) 17596 if (d.contains(this.containers[i].element[0], this.items[a].item[0])) { 17597 var l = this.containers[i].floating ? this.items[a].item.offset().left : this.items[a].item.offset().top; 17598 Math.abs(l - r) < s && (s = Math.abs(l - r), 17599 o = this.items[a], 17600 this.direction = 0 < l - r ? "down" : "up") 17601 } 17602 if (!o && !this.options.dropOnEmpty) 17603 return; 17604 this.currentContainer = this.containers[i], 17605 o ? this._rearrange(t, o, null, !0) : this._rearrange(t, null, this.containers[i].element, !0), 17606 this._trigger("change", t, this._uiHash()), 17607 this.containers[i]._trigger("change", t, this._uiHash(this)), 17608 this.options.placeholder.update(this.currentContainer, this.placeholder), 17609 this.containers[i]._trigger("over", t, this._uiHash(this)), 17610 this.containers[i].containerCache.over = 1 17611 } 17612 }, 17613 _createHelper: function(t) { 17614 var e = this.options 17615 , i = d.isFunction(e.helper) ? d(e.helper.apply(this.element[0], [t, this.currentItem])) : "clone" == e.helper ? this.currentItem.clone() : this.currentItem; 17616 return i.parents("body").length || d("parent" != e.appendTo ? e.appendTo : this.currentItem[0].parentNode)[0].appendChild(i[0]), 17617 i[0] == this.currentItem[0] && (this._storedCSS = { 17618 width: this.currentItem[0].style.width, 17619 height: this.currentItem[0].style.height, 17620 position: this.currentItem.css("position"), 17621 top: this.currentItem.css("top"), 17622 left: this.currentItem.css("left") 17623 }), 17624 ("" == i[0].style.width || e.forceHelperSize) && i.width(this.currentItem.width()), 17625 ("" == i[0].style.height || e.forceHelperSize) && i.height(this.currentItem.height()), 17626 i 17627 }, 17628 _adjustOffsetFromHelper: function(t) { 17629 "string" == typeof t && (t = t.split(" ")), 17630 d.isArray(t) && (t = { 17631 left: +t[0], 17632 top: +t[1] || 0 17633 }), 17634 "left"in t && (this.offset.click.left = t.left + this.margins.left), 17635 "right"in t && (this.offset.click.left = this.helperProportions.width - t.right + this.margins.left), 17636 "top"in t && (this.offset.click.top = t.top + this.margins.top), 17637 "bottom"in t && (this.offset.click.top = this.helperProportions.height - t.bottom + this.margins.top) 17638 }, 17639 _getParentOffset: function() { 17640 this.offsetParent = this.helper.offsetParent(); 17641 var t = this.offsetParent.offset(); 17642 return "absolute" == this.cssPosition && this.scrollParent[0] != document && d.contains(this.scrollParent[0], this.offsetParent[0]) && (t.left += this.scrollParent.scrollLeft(), 17643 t.top += this.scrollParent.scrollTop()), 17644 (this.offsetParent[0] == document.body || this.offsetParent[0].tagName && "html" == this.offsetParent[0].tagName.toLowerCase() && d.browser.msie) && (t = { 17645 top: 0, 17646 left: 0 17647 }), 17648 { 17649 top: t.top + (parseInt(this.offsetParent.css("borderTopWidth"), 10) || 0), 17650 left: t.left + (parseInt(this.offsetParent.css("borderLeftWidth"), 10) || 0) 17651 } 17652 }, 17653 _getRelativeOffset: function() { 17654 if ("relative" == this.cssPosition) { 17655 var t = this.currentItem.position(); 17656 return { 17657 top: t.top - (parseInt(this.helper.css("top"), 10) || 0) + this.scrollParent.scrollTop(), 17658 left: t.left - (parseInt(this.helper.css("left"), 10) || 0) + this.scrollParent.scrollLeft() 17659 } 17660 } 17661 return { 17662 top: 0, 17663 left: 0 17664 } 17665 }, 17666 _cacheMargins: function() { 17667 this.margins = { 17668 left: parseInt(this.currentItem.css("marginLeft"), 10) || 0, 17669 top: parseInt(this.currentItem.css("marginTop"), 10) || 0 17670 } 17671 }, 17672 _cacheHelperProportions: function() { 17673 this.helperProportions = { 17674 width: this.helper.outerWidth(), 17675 height: this.helper.outerHeight() 17676 } 17677 }, 17678 _setContainment: function() { 17679 var t = this.options; 17680 if ("parent" == t.containment && (t.containment = this.helper[0].parentNode), 17681 "document" != t.containment && "window" != t.containment || (this.containment = [0 - this.offset.relative.left - this.offset.parent.left, 0 - this.offset.relative.top - this.offset.parent.top, d("document" == t.containment ? document : window).width() - this.helperProportions.width - this.margins.left, (d("document" == t.containment ? document : window).height() || document.body.parentNode.scrollHeight) - this.helperProportions.height - this.margins.top]), 17682 !/^(document|window|parent)$/.test(t.containment)) { 17683 var e = d(t.containment)[0] 17684 , i = d(t.containment).offset() 17685 , n = "hidden" != d(e).css("overflow"); 17686 this.containment = [i.left + (parseInt(d(e).css("borderLeftWidth"), 10) || 0) + (parseInt(d(e).css("paddingLeft"), 10) || 0) - this.margins.left, i.top + (parseInt(d(e).css("borderTopWidth"), 10) || 0) + (parseInt(d(e).css("paddingTop"), 10) || 0) - this.margins.top, i.left + (n ? Math.max(e.scrollWidth, e.offsetWidth) : e.offsetWidth) - (parseInt(d(e).css("borderLeftWidth"), 10) || 0) - (parseInt(d(e).css("paddingRight"), 10) || 0) - this.helperProportions.width - this.margins.left, i.top + (n ? Math.max(e.scrollHeight, e.offsetHeight) : e.offsetHeight) - (parseInt(d(e).css("borderTopWidth"), 10) || 0) - (parseInt(d(e).css("paddingBottom"), 10) || 0) - this.helperProportions.height - this.margins.top] 17687 } 17688 }, 17689 _convertPositionTo: function(t, e) { 17690 e || (e = this.position); 17691 var i = "absolute" == t ? 1 : -1 17692 , n = (this.options, 17693 "absolute" != this.cssPosition || this.scrollParent[0] != document && d.contains(this.scrollParent[0], this.offsetParent[0]) ? this.scrollParent : this.offsetParent) 17694 , s = /(html|body)/i.test(n[0].tagName); 17695 return { 17696 top: e.top + this.offset.relative.top * i + this.offset.parent.top * i - ("fixed" == this.cssPosition ? -this.scrollParent.scrollTop() : s ? 0 : n.scrollTop()) * i, 17697 left: e.left + this.offset.relative.left * i + this.offset.parent.left * i - ("fixed" == this.cssPosition ? -this.scrollParent.scrollLeft() : s ? 0 : n.scrollLeft()) * i 17698 } 17699 }, 17700 _generatePosition: function(t) { 17701 var e = this.options 17702 , i = "absolute" != this.cssPosition || this.scrollParent[0] != document && d.contains(this.scrollParent[0], this.offsetParent[0]) ? this.scrollParent : this.offsetParent 17703 , n = /(html|body)/i.test(i[0].tagName); 17704 "relative" != this.cssPosition || this.scrollParent[0] != document && this.scrollParent[0] != this.offsetParent[0] || (this.offset.relative = this._getRelativeOffset()); 17705 var s = t.pageX 17706 , o = t.pageY; 17707 if (this.originalPosition && (this.containment && (t.pageX - this.offset.click.left < this.containment[0] && (s = this.containment[0] + this.offset.click.left), 17708 t.pageY - this.offset.click.top < this.containment[1] && (o = this.containment[1] + this.offset.click.top), 17709 t.pageX - this.offset.click.left > this.containment[2] && (s = this.containment[2] + this.offset.click.left), 17710 t.pageY - this.offset.click.top > this.containment[3] && (o = this.containment[3] + this.offset.click.top)), 17711 e.grid)) { 17712 var r = this.originalPageY + Math.round((o - this.originalPageY) / e.grid[1]) * e.grid[1]; 17713 o = this.containment && (r - this.offset.click.top < this.containment[1] || r - this.offset.click.top > this.containment[3]) ? r - this.offset.click.top < this.containment[1] ? r + e.grid[1] : r - e.grid[1] : r; 17714 var a = this.originalPageX + Math.round((s - this.originalPageX) / e.grid[0]) * e.grid[0]; 17715 s = this.containment && (a - this.offset.click.left < this.containment[0] || a - this.offset.click.left > this.containment[2]) ? a - this.offset.click.left < this.containment[0] ? a + e.grid[0] : a - e.grid[0] : a 17716 } 17717 return { 17718 top: o - this.offset.click.top - this.offset.relative.top - this.offset.parent.top + ("fixed" == this.cssPosition ? -this.scrollParent.scrollTop() : n ? 0 : i.scrollTop()), 17719 left: s - this.offset.click.left - this.offset.relative.left - this.offset.parent.left + ("fixed" == this.cssPosition ? -this.scrollParent.scrollLeft() : n ? 0 : i.scrollLeft()) 17720 } 17721 }, 17722 _rearrange: function(t, e, i, n) { 17723 i ? i[0].appendChild(this.placeholder[0]) : e.item[0].parentNode.insertBefore(this.placeholder[0], "down" == this.direction ? e.
17723item[0] : e.item[0].nextSibling), 17724 this.counter = this.counter ? ++this.counter : 1; 17725 var s = this.counter; 17726 this._delay(function() { 17727 s == this.counter && this.refreshPositions(!n) 17728 }) 17729 }, 17730 _clear: function(t, e) { 17731 this.reverting = !1; 17732 var i = []; 17733 if (!this._noFinalSort && this.currentItem.parent().length && this.placeholder.before(this.currentItem), 17734 this._noFinalSort = null, 17735 this.helper[0] == this.currentItem[0]) { 17736 for (var n in this._storedCSS) 17737 "auto" != this._storedCSS[n] && "static" != this._storedCSS[n] || (this._storedCSS[n] = ""); 17738 this.currentItem.css(this._storedCSS).removeClass("ui-sortable-helper") 17739 } else 17740 this.currentItem.show(); 17741 this.fromOutside && !e && i.push(function(t) { 17742 this._trigger("receive", t, this._uiHash(this.fromOutside)) 17743 }), 17744 !this.fromOutside && this.domPosition.prev == this.currentItem.prev().not(".ui-sortable-helper")[0] && this.domPosition.parent == this.currentItem.parent()[0] || e || i.push(function(t) { 17745 this._trigger("update", t, this._uiHash()) 17746 }), 17747 this !== this.currentContainer && (e || (i.push(function(t) { 17748 this._trigger("remove", t, this._uiHash()) 17749 }), 17750 i.push(function(e) { 17751 return function(t) { 17752 e._trigger("receive", t, this._uiHash(this)) 17753 } 17754 } 17755 .call(this, this.currentContainer)), 17756 i.push(function(e) { 17757 return function(t) { 17758 e._trigger("update", t, this._uiHash(this)) 17759 } 17760 } 17761 .call(this, this.currentContainer)))); 17762 for (n = this.containers.length - 1; 0 <= n; n--) 17763 e || i.push(function(e) { 17764 return function(t) { 17765 e._trigger("deactivate", t, this._uiHash(this)) 17766 } 17767 } 17768 .call(this, this.containers[n])), 17769 this.containers[n].containerCache.over && (i.push(function(e) { 17770 return function(t) { 17771 e._trigger("out", t, this._uiHash(this)) 17772 } 17773 } 17774 .call(this, this.containers[n])), 17775 this.containers[n].containerCache.over = 0); 17776 if (this._storedCursor && d("body").css("cursor", this._storedCursor), 17777 this._storedOpacity && this.helper.css("opacity", this._storedOpacity), 17778 this._storedZIndex && this.helper.css("zIndex", "auto" == this._storedZIndex ? "" : this._storedZIndex), 17779 this.dragging = !1, 17780 this.cancelHelperRemoval) { 17781 if (!e) { 17782 this._trigger("beforeStop", t, this._uiHash()); 17783 for (n = 0; n < i.length; n++) 17784 i[n].call(this, t); 17785 this._trigger("stop", t, this._uiHash()) 17786 } 17787 return this.fromOutside = !1 17788 } 17789 if (e || this._trigger("beforeStop", t, this._uiHash()), 17790 this.placeholder[0].parentNode.removeChild(this.placeholder[0]), 17791 this.helper[0] != this.currentItem[0] && this.helper.remove(), 17792 this.helper = null, 17793 !e) { 17794 for (n = 0; n < i.length; n++) 17795 i[n].call(this, t); 17796 this._trigger("stop", t, this._uiHash()) 17797 } 17798 return !(this.fromOutside = !1) 17799 }, 17800 _trigger: function() { 17801 !1 === d.Widget.prototype._trigger.apply(this, arguments) && this.cancel() 17802 }, 17803 _uiHash: function(t) { 17804 var e = t || this; 17805 return { 17806 helper: e.helper, 17807 placeholder: e.placeholder || d([]), 17808 position: e.position, 17809 originalPosition: e.originalPosition, 17810 offset: e.positionAbs, 17811 item: e.currentItem, 17812 sender: t ? t.element : null 17813 } 17814 } 17815 }) 17816}(jQuery), 17817jQuery.effects || function(y, o) { 17818 var i, a = !1 !== y.uiBackCompat, r = "ui-effects-"; 17819 y.effects = { 17820 effect: {} 17821 }, 17822 function(u, h) { 17823 function d(t, e, i) { 17824 var n = m[e.type] || {}; 17825 return null == t ? i || !e.def ? null : e.def : (t = n.floor ? ~~t : parseFloat(t), 17826 isNaN(t) ? e.def : n.mod ? (t + n.mod) % n.mod : t < 0 ? 0 : n.max < t ? n.max : t) 17827 } 17828 function a(r) { 17829 var a = f() 17830 , l = a._rgba = []; 17831 return r = r.toLowerCase(), 17832 v(e, function(t, e) { 17833 var i, n = e.re.exec(r), s = n && e.parse(n), o = e.space || "rgba"; 17834 if (s) 17835 return i = a[o](s), 17836 a[g[o].cache] = i[g[o].cache], 17837 l = a._rgba = i._rgba, 17838 !1 17839 }), 17840 l.length ? ("0,0,0,0" === l.join() && u.extend(l, c.transparent), 17841 a) : c[r] 17842 } 17843 function l(t, e, i) { 17844 return 6 * (i = (i + 1) % 1) < 1 ? t + (e - t) * i * 6 : 2 * i < 1 ? e : 3 * i < 2 ? t + (e - t) * (2 / 3 - i) * 6 : t 17845 } 17846 var c, t = "backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor".split(" "), p = /^([\-+])=\s*(\d+\.?\d*)/, e = [{ 17847 re: /rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d+(?:\.\d+)?)\s*)?\)/, 17848 parse: function(t) { 17849 return [t[1], t[2], t[3], t[4]] 17850 } 17851 }, {
vendor: 8,483 bytes, lines 17852-18123
17852 re: /rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d+(?:\.\d+)?)\s*)?\)/, 17853 parse: function(t) { 17854 return [2.55 * t[1], 2.55 * t[2], 2.55 * t[3], t[4]] 17855 } 17856 }, { 17857 re: /#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/, 17858 parse: function(t) { 17859 return [parseInt(t[1], 16), parseInt(t[2], 16), parseInt(t[3], 16)] 17860 } 17861 }, { 17862 re: /#([a-f0-9])([a-f0-9])([a-f0-9])/, 17863 parse: function(t) { 17864 return [parseInt(t[1] + t[1], 16), parseInt(t[2] + t[2], 16), parseInt(t[3] + t[3], 16)] 17865 } 17866 }, { 17867 re: /hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d+(?:\.\d+)?)\s*)?\)/, 17868 space: "hsla", 17869 parse: function(t) { 17870 return [t[1], t[2] / 100, t[3] / 100, t[4]] 17871 } 17872 }], f = u.Color = function(t, e, i, n) { 17873 return new u.Color.fn.parse(t,e,i,n) 17874 } 17875 , g = { 17876 rgba: { 17877 props: { 17878 red: { 17879 idx: 0, 17880 type: "byte" 17881 }, 17882 green: { 17883 idx: 1, 17884 type: "byte" 17885 }, 17886 blue: { 17887 idx: 2, 17888 type: "byte" 17889 } 17890 } 17891 }, 17892 hsla: { 17893 props: { 17894 hue: { 17895 idx: 0, 17896 type: "degrees" 17897 }, 17898 saturation: { 17899 idx: 1, 17900 type: "percent" 17901 }, 17902 lightness: { 17903 idx: 2, 17904 type: "percent" 17905 } 17906 } 17907 } 17908 }, m = { 17909 byte: { 17910 floor: !0, 17911 max: 255 17912 }, 17913 percent: { 17914 max: 1 17915 }, 17916 degrees: { 17917 mod: 360, 17918 floor: !0 17919 } 17920 }, r = f.support = {}, i = u("<p>")[0], v = u.each; 17921 i.style.cssText = "background-color:rgba(1,1,1,.5)", 17922 r.rgba = -1 < i.style.backgroundColor.indexOf("rgba"), 17923 v(g, function(t, e) { 17924 e.cache = "_" + t, 17925 e.props.alpha = { 17926 idx: 3, 17927 type: "percent", 17928 def: 1 17929 } 17930 }), 17931 f.fn = u.extend(f.prototype, { 17932 parse: function(s, t, e, i) { 17933 if (s === h) 17934 return this._rgba = [null, null, null, null], 17935 this; 17936 (s.jquery || s.nodeType) && (s = u(s).css(t), 17937 t = h); 17938 var o = this 17939 , n = u.type(s) 17940 , r = this._rgba = []; 17941 return t !== h && (s = [s, t, e, i], 17942 n = "array"), 17943 "string" === n ? this.parse(a(s) || c._default) : "array" === n ? (v(g.rgba.props, function(t, e) { 17944 r[e.idx] = d(s[e.idx], e) 17945 }), 17946 this) : "object" === n ? (v(g, s instanceof f ? function(t, e) { 17947 s[e.cache] && (o[e.cache] = s[e.cache].slice()) 17948 } 17949 : function(t, i) { 17950 var n = i.cache; 17951 v(i.props, function(t, e) { 17952 if (!o[n] && i.to) { 17953 if ("alpha" === t || null == s[t]) 17954 return; 17955 o[n] = i.to(o._rgba) 17956 } 17957 o[n][e.idx] = d(s[t], e, !0) 17958 }), 17959 o[n] && y.inArray(null, o[n].slice(0, 3)) < 0 && (o[n][3] = 1, 17960 i.from && (o._rgba = i.from(o[n]))) 17961 } 17962 ), 17963 this) : void 0 17964 }, 17965 is: function(t) { 17966 var s = f(t) 17967 , o = !0 17968 , r = this; 17969 return v(g, function(t, e) { 17970 var i, n = s[e.cache]; 17971 return n && (i = r[e.cache] || e.to && e.to(r._rgba) || [], 17972 v(e.props, function(t, e) { 17973 if (null != n[e.idx]) 17974 return o = n[e.idx] === i[e.idx] 17975 })), 17976 o 17977 }), 17978 o 17979 }, 17980 _space: function() { 17981 var i = [] 17982 , n = this; 17983 return v(g, function(t, e) { 17984 n[e.cache] && i.push(t) 17985 }), 17986 i.pop() 17987 }, 17988 transition: function(t, r) { 17989 var a = f(t) 17990 , e = a._space() 17991 , i = g[e] 17992 , n = 0 === this.alpha() ? f("transparent") : this 17993 , l = n[i.cache] || i.to(n._rgba) 17994 , c = l.slice(); 17995 return a = a[i.cache], 17996 v(i.props, function(t, e) { 17997 var i = e.idx 17998 , n = l[i] 17999 , s = a[i] 18000 , o = m[e.type] || {}; 18001 null !== s && (null === n ? c[i] = s : (o.mod && (s - n > o.mod / 2 ? n += o.mod : n - s > o.mod / 2 && (n -= o.mod)), 18002 c[i] = d((s - n) * r + n, e))) 18003 }), 18004 this[e](c) 18005 }, 18006 blend: function(t) { 18007 if (1 === this._rgba[3]) 18008 return this; 18009 var e = this._rgba.slice() 18010 , i = e.pop() 18011 , n = f(t)._rgba; 18012 return f(u.map(e, function(t, e) { 18013 return (1 - i) * n[e] + i * t 18014 })) 18015 }, 18016 toRgbaString: function() { 18017 var t = "rgba(" 18018 , e = u.map(this._rgba, function(t, e) { 18019 return null == t ? 2 < e ? 1 : 0 : t 18020 }); 18021 return 1 === e[3] && (e.pop(), 18022 t = "rgb("), 18023 t + e.join() + ")" 18024 }, 18025 toHslaString: function() { 18026 var t = "hsla(" 18027 , e = u.map(this.hsla(), function(t, e) { 18028 return null == t && (t = 2 < e ? 1 : 0), 18029 e && e < 3 && (t = Math.round(100 * t) + "%"), 18030 t 18031 }); 18032 return 1 === e[3] && (e.pop(), 18033 t = "hsl("), 18034 t + e.join() + ")" 18035 }, 18036 toHexString: function(t) { 18037 var e = this._rgba.slice() 18038 , i = e.pop(); 18039 return t && e.push(~~(255 * i)), 18040 "#" + u.map(e, function(t) { 18041 return 1 === (t = (t || 0).toString(16)).length ? "0" + t : t 18042 }).join("") 18043 }, 18044 toString: function() { 18045 return 0 === this._rgba[3] ? "transparent" : this.toRgbaString() 18046 } 18047 }), 18048 f.fn.parse.prototype = f.fn, 18049 g.hsla.to = function(t) { 18050 if (null == t[0] || null == t[1] || null == t[2]) 18051 return [null, null, null, t[3]]; 18052 var e, i, n = t[0] / 255, s = t[1] / 255, o = t[2] / 255, r = t[3], a = Math.max(n, s, o), l = Math.min(n, s, o), c = a - l, u = a + l, h = .5 * u; 18053 return e = l === a ? 0 : n === a ? 60 * (s - o) / c + 360 : s === a ? 60 * (o - n) / c + 120 : 60 * (n - s) / c + 240, 18054 i = 0 === h || 1 === h ? h : h <= .5 ? c / u : c / (2 - u), 18055 [Math.round(e) % 360, i, h, null == r ? 1 : r] 18056 } 18057 , 18058 g.hsla.from = function(t) { 18059 if (null == t[0] || null == t[1] || null == t[2]) 18060 return [null, null, null, t[3]]; 18061 var e = t[0] / 360 18062 , i = t[1] 18063 , n = t[2] 18064 , s = t[3] 18065 , o = n <= .5 ? n * (1 + i) : n + i - n * i 18066 , r = 2 * n - o; 18067 return [Math.round(255 * l(r, o, e + 1 / 3)), Math.round(255 * l(r, o, e)), Math.round(255 * l(r, o, e - 1 / 3)), s] 18068 } 18069 , 18070 v(g, function(l, t) { 18071 var i = t.props 18072 , r = t.cache 18073 , a = t.to 18074 , c = t.from; 18075 f.fn[l] = function(t) { 18076 if (a && !this[r] && (this[r] = a(this._rgba)), 18077 t === h) 18078 return this[r].slice(); 18079 var e, n = u.type(t), s = "array" === n || "object" === n ? t : arguments, o = this[r].slice(); 18080 return v(i, function(t, e) { 18081 var i = s["object" === n ? t : e.idx]; 18082 null == i && (i = o[e.idx]), 18083 o[e.idx] = d(i, e) 18084 }), 18085 c ? ((e = f(c(o)))[r] = o, 18086 e) : f(o) 18087 } 18088 , 18089 v(i, function(r, a) { 18090 f.fn[r] || (f.fn[r] = function(t) { 18091 var e, i = u.type(t), n = "alpha" === r ? this._hsla ? "hsla" : "rgba" : l, s = this[n](), o = s[a.idx]; 18092 return "undefined" === i ? o : ("function" === i && (t = t.call(this, o), 18093 i = u.type(t)), 18094 null == t && a.empty ? this : ("string" === i && (e = p.exec(t)) && (t = o + parseFloat(e[2]) * ("+" === e[1] ? 1 : -1)), 18095 s[a.idx] = t, 18096 this[n](s))) 18097 } 18098 ) 18099 }) 18100 }), 18101 v(t, function(t, o) { 18102 u.cssHooks[o] = { 18103 set: function(t, e) { 18104 var i, n, s = ""; 18105 if ("string" !== u.type(e) || (i = a(e))) { 18106 if (e = f(i || e), 18107 !r.rgba && 1 !== e._rgba[3]) { 18108 for (n = "backgroundColor" === o ? t.parentNode : t; ("" === s || "transparent" === s) && n && n.style; ) 18109 try { 18110 s = u.css(n, "backgroundColor"), 18111 n = n.parentNode 18112 } catch (t) {} 18113 e = e.blend(s && "transparent" !== s ? s : "_default") 18114 } 18115 e = e.toRgbaString() 18116 } 18117 try { 18118 t.style[o] = e 18119 } catch (e) {} 18120 } 18121 }, 18122 u.fx.step[o] = function(t) { 18123 t.colorInit || (t.start = f(t.elem, o),
18124 t.end = f(t.end), 18125 t.colorInit = !0), 18126 u.cssHooks[o].set(t.elem, t.start.transition(t.end, t.pos)) 18127 } 18128 }), 18129 u.cssHooks.borderColor = { 18130 expand: function(i) { 18131 var n = {}; 18132 return v(["Top", "Right", "Bottom", "Left"], function(t, e) { 18133 n["border" + e + "Color"] = i 18134 }), 18135 n 18136 } 18137 }, 18138 c = u.Color.names = { 18139 aqua: "#00ffff", 18140 black: "#000000", 18141 blue: "#0000ff", 18142 fuchsia: "#ff00ff", 18143 gray: "#808080", 18144 green: "#008000", 18145 lime: "#00ff00", 18146 maroon: "#800000", 18147 navy: "#000080", 18148 olive: "#808000", 18149 purple: "#800080", 18150 red: "#ff0000", 18151 silver: "#c0c0c0", 18152 teal: "#008080", 18153 white: "#ffffff", 18154 yellow: "#ffff00", 18155 transparent: [null, null, null, 0], 18156 _default: "#ffffff" 18157 } 18158 }(jQuery), 18159 function() { 18160 function r() { 18161 var t, e, i = this.ownerDocument.defaultView ? this.ownerDocument.defaultView.getComputedStyle(this, null) : this.currentStyle, n = {}; 18162 if (i && i.length && i[0] && i[i[0]]) 18163 for (e = i.length; e--; ) 18164 "string" == typeof i[t = i[e]] && (n[y.camelCase(t)] = i[t]); 18165 else 18166 for (t in i) 18167 "string" == typeof i[t] && (n[t] = i[t]); 18168 return n 18169 } 18170 var a = ["add", "remove", "toggle"] 18171 , l = { 18172 border: 1, 18173 borderBottom: 1, 18174 borderColor: 1, 18175 borderLeft: 1, 18176 borderRight: 1, 18177 borderTop: 1, 18178 borderWidth: 1, 18179 margin: 1, 18180 padding: 1 18181 }; 18182 y.each(["borderLeftStyle", "borderRightStyle", "borderBottomStyle", "borderTopStyle"], function(t, e) { 18183 y.fx.step[e] = function(t) { 18184 ("none" !== t.end && !t.setAttr || 1 === t.pos && !t.setAttr) && (jQuery.style(t.elem, e, t.end), 18185 t.setAttr = !0) 18186 } 18187 }), 18188 y.effects.animateClass = function(s, t, e, i) { 18189 var o = y.speed(t, e, i); 18190 return this.queue(function() { 18191 var t, i = y(this), e = i.attr("class") || "", n = o.children ? i.find("*").andSelf() : i; 18192 n = n.map(function() { 18193 return { 18194 el: y(this), 18195 start: r.call(this) 18196 } 18197 }), 18198 (t = function() { 18199 y.each(a, function(t, e) { 18200 s[e] && i[e + "Class"](s[e]) 18201 }) 18202 } 18203 )(), 18204 n = n.map(function() { 18205 return this.end = r.call(this.el[0]), 18206 this.diff = function(t, e) { 18207 var i, n, s = {}; 18208 for (i in e) 18209 n = e[i], 18210 t[i] !== n && (l[i] || !y.fx.step[i] && isNaN(parseFloat(n)) || (s[i] = n)); 18211 return s 18212 }(this.start, this.end), 18213 this 18214 }), 18215 i.attr("class", e), 18216 n = n.map(function() { 18217 var t = this 18218 , e = y.Deferred() 18219 , i = jQuery.extend({}, o, { 18220 queue: !1, 18221 complete: function() { 18222 e.resolve(t) 18223 } 18224 }); 18225 return this.el.animate(this.diff, i), 18226 e.promise() 18227 }), 18228 y.when.apply(y, n.get()).done(function() { 18229 t(), 18230 y.each(arguments, function() { 18231 var e = this.el; 18232 y.each(this.diff, function(t) { 18233 e.css(t, "") 18234 }) 18235 }), 18236 o.complete.call(i[0]) 18237 }) 18238 }) 18239 } 18240 , 18241 y.fn.extend({ 18242 _addClass: y.fn.addClass, 18243 addClass: function(t, e, i, n) { 18244 return e ? y.effects.animateClass.call(this, { 18245 add: t 18246 }, e, i, n) : this._addClass(t) 18247 }, 18248 _removeClass: y.fn.removeClass, 18249 removeClass: function(t, e, i, n) { 18250 return e ? y.effects.animateClass.call(this, { 18251 remove: t 18252 }, e, i, n) : this._removeClass(t) 18253 }, 18254 _toggleClass: y.fn.toggleClass, 18255 toggleClass: function(t, e, i, n, s) { 18256 return "boolean" == typeof e || e === o ? i ? y.effects.animateClass.call(this, e ? { 18257 add: t 18258 } : { 18259 remove: t 18260 }, i, n, s) : this._toggleClass(t, e) : y.effects.animateClass.call(this, { 18261 toggle: t 18262 }, e, i, n) 18263 }, 18264 switchClass: function(t, e, i, n, s) { 18265 return y.effects.animateClass.call(this, { 18266 add: e, 18267 remove: t 18268 }, i, n, s) 18269 } 18270 }) 18271 }(), 18272 function() { 18273 function s(t, e, i, n) { 18274 return y.isPlainObject(t) && (t = (e = t).effect), 18275 t = { 18276 effect: t 18277 }, 18278 e === o && (e = {}), 18279 y.isFunction(e) && (n = e, 18280 i = null, 18281 e = {}), 18282 ("number" == typeof e || y.fx.speeds[e]) && (n = i, 18283 i = e, 18284 e = {}), 18285 y.isFunction(i) && (n = i, 18286 i = null),
18287 e && y.extend(t, e), 18288 i = i || e.duration, 18289 t.duration = y.fx.off ? 0 : "number" == typeof i ? i : i in y.fx.speeds ? y.fx.speeds[i] : y.fx.speeds._default, 18290 t.complete = n || e.complete, 18291 t 18292 } 18293 function i(t) { 18294 return !(t && "number" != typeof t && !y.fx.speeds[t]) || "string" == typeof t && !y.effects.effect[t] && (!a || !y.effects[t]) 18295 } 18296 y.extend(y.effects, { 18297 version: "1.9.0", 18298 save: function(t, e) { 18299 for (var i = 0; i < e.length; i++) 18300 null !== e[i] && t.data(r + e[i], t[0].style[e[i]]) 18301 }, 18302 restore: function(t, e) { 18303 var i, n; 18304 for (n = 0; n < e.length; n++) 18305 null !== e[n] && ((i = t.data(r + e[n])) === o && (i = ""), 18306 t.css(e[n], i)) 18307 }, 18308 setMode: function(t, e) { 18309 return "toggle" === e && (e = t.is(":hidden") ? "show" : "hide"), 18310 e 18311 }, 18312 getBaseline: function(t, e) { 18313 var i, n; 18314 switch (t[0]) { 18315 case "top": 18316 i = 0; 18317 break; 18318 case "middle": 18319 i = .5; 18320 break; 18321 case "bottom": 18322 i = 1; 18323 break; 18324 default: 18325 i = t[0] / e.height 18326 } 18327 switch (t[1]) { 18328 case "left": 18329 n = 0; 18330 break; 18331 case "center": 18332 n = .5; 18333 break; 18334 case "right": 18335 n = 1; 18336 break; 18337 default: 18338 n = t[1] / e.width 18339 } 18340 return { 18341 x: n, 18342 y: i 18343 } 18344 }, 18345 createWrapper: function(i) { 18346 if (i.parent().is(".ui-effects-wrapper")) 18347 return i.parent(); 18348 var n = { 18349 width: i.outerWidth(!0), 18350 height: i.outerHeight(!0), 18351 float: i.css("float") 18352 } 18353 , t = y("<div></div>").addClass("ui-effects-wrapper").css({ 18354 fontSize: "100%", 18355 background: "transparent", 18356 border: "none", 18357 margin: 0, 18358 padding: 0 18359 }) 18360 , e = { 18361 width: i.width(), 18362 height: i.height() 18363 } 18364 , s = document.activeElement; 18365 try { 18366 s.id 18367 } catch (t) { 18368 s = document.body 18369 } 18370 return i.wrap(t), 18371 (i[0] === s || y.contains(i[0], s)) && y(s).focus(), 18372 t = i.parent(), 18373 "static" === i.css("position") ? (t.css({ 18374 position: "relative" 18375 }), 18376 i.css({ 18377 position: "relative" 18378 })) : (y.extend(n, { 18379 position: i.css("position"), 18380 zIndex: i.css("z-index") 18381 }), 18382 y.each(["top", "left", "bottom", "right"], function(t, e) { 18383 n[e] = i.css(e), 18384 isNaN(parseInt(n[e], 10)) && (n[e] = "auto") 18385 }), 18386 i.css({ 18387 position: "relative", 18388 top: 0, 18389 left: 0, 18390 right: "auto", 18391 bottom: "auto" 18392 })), 18393 i.css(e), 18394 t.css(n).show() 18395 }, 18396 removeWrapper: function(t) { 18397 var e = document.activeElement; 18398 return t.parent().is(".ui-effects-wrapper") && (t.parent().replaceWith(t), 18399 (t[0] === e || y.contains(t[0], e)) && y(e).focus()), 18400 t 18401 }, 18402 setTransition: function(n, t, s, o) { 18403 return o = o || {}, 18404 y.each(t, function(t, e) { 18405 var i = n.cssUnit(e); 18406 0 < i[0] && (o[e] = i[0] * s + i[1]) 18407 }), 18408 o 18409 } 18410 }), 18411 y.fn.extend({ 18412 effect: function() { 18413 function t(t) { 18414 function e() { 18415 y.isFunction(n) && n.call(i[0]), 18416 y.isFunction(t) && t() 18417 } 18418 var i = y(this) 18419 , n = o.complete 18420 , s = o.mode; 18421 (i.is(":hidden") ? "hide" === s : "show" === s) ? e() : r.call(i[0], o, e) 18422 } 18423 var o = s.apply(this, arguments) 18424 , e = o.mode 18425 , i = o.queue 18426 , r = y.effects.effect[o.effect] 18427 , n = !r && a && y.effects[o.effect]; 18428 return y.fx.off || !r && !n ? e ? this[e](o.duration, o.complete) : this.each(function() { 18429 o.complete && o.complete.call(this) 18430 }) : r ? !1 === i ? this.each(t) : this.queue(i || "fx", t) : n.call(this, { 18431 options: o, 18432 duration: o.duration, 18433 callback: o.complete, 18434 mode: o.mode 18435 }) 18436 }, 18437 _show: y.fn.show, 18438 show: function(t) { 18439 if (i(t)) 18440 return this._show.apply(this, arguments); 18441 var e = s.apply(this, arguments); 18442 return e.mode = "show", 18443 this.effect.call(this, e) 18444 }, 18445 _hide: y.fn.hide, 18446 hide: function(t) { 18447 if (i(t)) 18448 return this._hide.apply(this, arguments); 18449 var e = s.apply(this, arguments); 18450 return e.mode = "hide", 18451 this.effect.call(this, e) 18452 }, 18453 __toggle: y.fn.toggle, 18454 toggle: function(t) { 18455 if (i(t) || "boolean" == typeof t || y.isFunction(t)) 18456 return this.__toggle.apply(this, arguments); 18457 var e = s.apply(this, arguments); 18458 return e.mode = "toggle", 18459 this.effect.call(this, e) 18460 }, 18461 cssUnit: function(t) { 18462 var i = this.css(t) 18463 , n = []; 18464 return y.each(["em", "px", "%", "pt"], function(t, e) { 18465 0 < i.indexOf(e) && (n = [parseFloat(i), e]) 18466 }), 18467 n 18468 } 18469 }) 18470 }(), 18471 i = {}, 18472 y.each(["Quad", "Cubic", "Quart", "Quint", "Expo"], function(e, t) { 18473 i[t] = function(t) { 18474 return Math.pow(t, e + 2) 18475 } 18476 }), 18477 y.extend(i, { 18478 Sine: function(t) { 18479 return 1 - Math.cos(t * Math.PI / 2) 18480 }, 18481 Circ: function(t) { 18482 return 1 - Math.sqrt(1 - t * t) 18483 }, 18484 Elastic: function(t) { 18485 return 0 === t || 1 === t ? t : -Math.pow(2, 8 * (t - 1)) * Math.sin((80 * (t - 1)
18485- 7.5) * Math.PI / 15) 18486 }, 18487 Back: function(t) { 18488 return t * t * (3 * t - 2) 18489 }, 18490 Bounce: function(t) { 18491 for (var e, i = 4; t < ((e = Math.pow(2, --i)) - 1) / 11; ) 18492 ; 18493 return 1 / Math.pow(4, 3 - i) - 7.5625 * Math.pow((3 * e - 2) / 22 - t, 2) 18494 } 18495 }), 18496 y.each(i, function(t, e) { 18497 y.easing["easeIn" + t] = e, 18498 y.easing["easeOut" + t] = function(t) { 18499 return 1 - e(1 - t) 18500 } 18501 , 18502 y.easing["easeInOut" + t] = function(t) { 18503 return t < .5 ? e(2 * t) / 2 : 1 - e(-2 * t + 2) / 2 18504 } 18505 }) 18506}(jQuery), 18507function(l) { 18508 var e = 0 18509 , d = {} 18510 , p = {}; 18511 d.height = d.paddingTop = d.paddingBottom = d.borderTopWidth = d.borderBottomWidth = "hide", 18512 p.height = p.paddingTop = p.paddingBottom = p.borderTopWidth = p.borderBottomWidth = "show", 18513 l.widget("ui.accordion", { 18514 version: "1.9.0", 18515 options: { 18516 active: 0, 18517 animate: {}, 18518 collapsible: !1, 18519 event: "click", 18520 header: "> li > :first-child,> :not(li):even", 18521 heightStyle: "auto", 18522 icons: { 18523 activeHeader: "ui-icon-triangle-1-s", 18524 header: "ui-icon-triangle-1-e" 18525 }, 18526 activate: null, 18527 beforeActivate: null 18528 }, 18529 _create: function() { 18530 var o = this.accordionId = "ui-accordion-" + (this.element.attr("id") || ++e) 18531 , t = this.options; 18532 this.prevShow = this.prevHide = l(), 18533 this.element.addClass("ui-accordion ui-widget ui-helper-reset"), 18534 this.headers = this.element.find(t.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all"), 18535 this._hoverable(this.headers), 18536 this._focusable(this.headers), 18537 this.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom").hide(), 18538 t.collapsible || !1 !== t.active || (t.active = 0), 18539 t.active < 0 && (t.active += this.headers.length), 18540 this.active = this._findActive(t.active).addClass("ui-accordion-header-active ui-state-active").toggleClass("ui-corner-all ui-corner-top"), 18541 this.active.next().addClass("ui-accordion-content-active").show(), 18542 this._createIcons(), 18543 this.originalHeight = this.element[0].style.height, 18544 this.refresh(), 18545 this.element.attr("role", "tablist"), 18546 this.headers.attr("role", "tab").each(function(t) { 18547 var e = l(this) 18548 , i = e.attr("id") 18549 , n = e.next() 18550 , s = n.attr("id"); 18551 i || (i = o + "-header-" + t, 18552 e.attr("id", i)), 18553 s || (s = o + "-panel-" + t, 18554 n.attr("id", s)), 18555 e.attr("aria-controls", s), 18556 n.attr("aria-labelledby", i) 18557 }).next().attr("role", "tabpanel"), 18558 this.headers.not(this.active).attr({ 18559 "aria-selected": "false", 18560 tabIndex: -1 18561 }).next().attr({ 18562 "aria-expanded": "false", 18563 "aria-hidden": "true" 18564 }).hide(), 18565 this.active.length ? this.active.attr({ 18566 "aria-selected": "true", 18567 tabIndex: 0 18568 }).next().attr({ 18569 "aria-expanded": "true", 18570 "aria-hidden": "false" 18571 }) : this.headers.eq(0).attr("tabIndex", 0), 18572 this._on(this.headers, { 18573 keydown: "_keydown" 18574 }), 18575 this._on(this.headers.next(), { 18576 keydown: "_panelKeyDown" 18577 }), 18578 this._setupEvents(t.event) 18579 }, 18580 _getCreateEventData: function() { 18581 return { 18582 header: this.active, 18583 content: this.active.length ? this.active.next() : l() 18584 } 18585 }, 18586 _createIcons: function() { 18587 var t = this.options.icons; 18588 t && (l("<span>").addClass("ui-accordion-header-icon ui-icon " + t.header).prependTo(this.headers), 18589 this.active.children(".ui-accordion-header-icon").removeClass(t.header).addClass(t.activeHeader), 18590 this.headers.addClass("ui-accordion-icons")) 18591 }, 18592 _destroyIcons: function() { 18593 this.headers.removeClass("ui-accordion-icons").children(".ui-accordion-header-icon").remove() 18594 }, 18595 _destroy: function() { 18596 var t; 18597 this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role"), 18598 this.headers.removeClass("ui-accordion-header ui-accordion-header-active ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-state-disabled ui-corner-top").removeAttr("role").removeAttr("aria-selected").removeAttr("aria-controls").removeAttr("tabIndex").each(function() {
18599 /^ui-accordion/.test(this.id) && this.removeAttribute("id") 18600 }), 18601 this._destroyIcons(), 18602 t = this.headers.next().css("display", "").removeAttr("role").removeAttr("aria-expanded").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeClass("ui-helper-reset ui-widget-content ui-corner-bottom ui-accordion-content ui-accordion-content-active ui-state-disabled").each(function() { 18603 /^ui-accordion/.test(this.id) && this.removeAttribute("id") 18604 }), 18605 "content" !== this.options.heightStyle && (this.element.css("height", this.originalHeight), 18606 t.css("height", "")) 18607 }, 18608 _setOption: function(t, e) { 18609 "active" !== t ? ("event" === t && (this.options.event && this._off(this.headers, this.options.event), 18610 this._setupEvents(e)), 18611 this._super(t, e), 18612 "collapsible" !== t || e || !1 !== this.options.active || this._activate(0), 18613 "icons" === t && (this._destroyIcons(), 18614 e && this._createIcons()), 18615 "disabled" === t && this.headers.add(this.headers.next()).toggleClass("ui-state-disabled", !!e)) : this._activate(e) 18616 }, 18617 _keydown: function(t) { 18618 if (!t.altKey && !t.ctrlKey) { 18619 var e = l.ui.keyCode 18620 , i = this.headers.length 18621 , n = this.headers.index(t.target) 18622 , s = !1; 18623 switch (t.keyCode) { 18624 case e.RIGHT: 18625 case e.DOWN: 18626 s = this.headers[(n + 1) % i]; 18627 break; 18628 case e.LEFT: 18629 case e.UP: 18630 s = this.headers[(n - 1 + i) % i]; 18631 break; 18632 case e.SPACE: 18633 case e.ENTER: 18634 this._eventHandler(t); 18635 break; 18636 case e.HOME: 18637 s = this.headers[0]; 18638 break; 18639 case e.END: 18640 s = this.headers[i - 1] 18641 } 18642 s && (l(t.target).attr("tabIndex", -1), 18643 l(s).attr("tabIndex", 0), 18644 s.focus(), 18645 t.preventDefault()) 18646 } 18647 }, 18648 _panelKeyDown: function(t) { 18649 t.keyCode === l.ui.keyCode.UP && t.ctrlKey && l(t.currentTarget).prev().focus() 18650 }, 18651 refresh: function() { 18652 var i, t, e = this.options.heightStyle, n = this.element.parent(); 18653 this.element.css("height", this.originalHeight), 18654 "fill" === e ? (l.support.minHeight || (t = n.css("overflow"), 18655 n.css("overflow", "hidden")), 18656 i = n.height(), 18657 this.element.siblings(":visible").each(function() { 18658 var t = l(this) 18659 , e = t.css("position"); 18660 "absolute" !== e && "fixed" !== e && (i -= t.outerHeight(!0)) 18661 }), 18662 t && n.css("overflow", t), 18663 this.headers.each(function() { 18664 i -= l(this).outerHeight(!0) 18665 }), 18666 this.headers.next().each(function() { 18667 l(this).height(Math.max(0, i - l(this).innerHeight() + l(this).height())) 18668 }).css("overflow", "auto")) : "auto" === e && (i = 0, 18669 this.headers.next().each(function() { 18670 i = Math.max(i, l(this).height("").height()) 18671 }).height(i)), 18672 "content" !== e && this.element.height(this.element.height()) 18673 }, 18674 _activate: function(t) { 18675 var e = this._findActive(t)[0]; 18676 e !== this.active[0] && (e = e || this.active[0], 18677 this._eventHandler({ 18678 target: e, 18679 currentTarget: e, 18680 preventDefault: l.noop 18681 })) 18682 }, 18683 _findActive: function(t) { 18684 return "number" == typeof t ? this.headers.eq(t) : l() 18685 }, 18686 _setupEvents: function(t) { 18687 var i = {}; 18688 t && (l.each(t.split(" "), function(t, e) { 18689 i[e] = "_eventHandler" 18690 }), 18691 this._on(this.headers, i)) 18692 }, 18693 _eventHandler: function(t) { 18694 var e = this.options 18695 , i = this.active 18696 , n = l(t.currentTarget) 18697 , s = n[0] === i[0] 18698 , o = s && e.collapsible 18699 , r = o ? l() : n.next() 18700 , a = { 18701 oldHeader: i, 18702 oldPanel: i.next(), 18703 newHeader: o ? l() : n, 18704 newPanel: r 18705 }; 18706 t.preventDefault(), 18707 s && !e.collapsible || !1 === this._trigger("beforeActivate", t, a) || (e.active = !o && this.headers.index(n), 18708 this.active = s ? l() : n, 18709 this._toggle(a), 18710 i.removeClass("ui-accordion-header-active ui-state-active"), 18711 e.icons && i.children(".ui-accordion-header-icon").removeClass(e.icons.activeHeader).addClass(e.icons.header), 18712 s || (n.removeClass("ui-corner-all").addClass("ui-accordion-header-active ui-state-active ui-corner-top"), 18713 e.icons && n.children(".ui-accordion-header-icon").removeClass(e.icons.header).addClass(e.icons.activeHeader), 18714 n.next().addClass("ui-accordion-content-active"))) 18715 }, 18716 _toggle: function(t) { 18717 var e = t.newPanel 18718 , i = this.prevShow.length ? this.prevShow : t.oldPanel; 18719 this.prevShow.add(this.prevHide).stop(!0, !0), 18720 this.prevShow = e, 18721 this.prevHide = i, 18722 this.options.animate ? this._animate(e, i, t) : (i.hide(), 18723 e.show(), 18724 this._toggleComplete(t)), 18725 i.attr({ 18726 "aria-expanded": "false", 18727 "aria-hidden": "true" 18728 }), 18729 i.prev().attr("aria-selected", "false"), 18730 e.length && i.length ? i.prev().attr("tabIndex", -1) : e.length && this.headers.filter(function() { 18731 return 0 === l(this).attr("tabIndex") 18732 }).attr("tabIndex", -1), 18733 e.attr({ 18734 "aria-expanded": "true", 18735 "aria-hidden": "false" 18736 }).prev().attr({ 18737 "aria-selected": "true", 18738 tabIndex: 0 18739 }) 18740 }, 18741 _animate: function(t, i, e) { 18742 var n, s, o, r = this, a = 0, l = t.length && (!i.length || t.index() < i.index()), c = this.options.animate || {}, u = l && c.down || c, h = function() { 18743 r._toggleComplete(e) 18744 }; 18745 return "number" == typeof u && (o = u), 18746 "string" == typeof u && (s = u), 18747 s = s || u.easing || c.easing, 18748 o = o || u.duration || c.duration, 18749 i.length ? t.length ? (n = t.show().outerHeight(), 18750 i.animate(d, { 18751 duration: o, 18752 easing: s, 18753 step: function(t, e) { 18754 e.now = Math.round(t) 18755 } 18756 }), 18757 void t.hide().animate(p, { 18758 duration: o, 18759 easing: s, 18760 complete: h, 18761 step: function(t, e) { 18762 e.now = Math.round(t), 18763 "height" !== e.prop ? a += e.now : "content" !== r.options.heightStyle && (e.now = Math.round(n - i.outerHeight() - a), 18764 a = 0) 18765 } 18766 })) : i.animate(d, o, s, h) : t.animate(p, o, s, h) 18767 }, 18768 _toggleComplete: function(t) { 18769 var e = t.oldPanel; 18770 e.removeClass("ui-accordion-content-active").prev().removeClass("ui-corner-top").addClass("ui-corner-all"), 18771 e.length && (e.parent()[0].className = e.parent()[0].className), 18772 this._trigger("activate", null, t) 18773 } 18774 }), 18775 !1 !== l.uiBackCompat && (function(s, t) { 18776 s.extend(t.options, { 18777 navigation: !1, 18778 navigationFilter: function() { 18779 return this.href.toLowerCase() === location.href.toLowerCase() 18780 } 18781 }); 18782 var o = t._create; 18783 t._create = function() { 18784 if (this.options.navigation) { 18785 var e = this 18786 , t = this.element.find(this.options.header) 18787 , i = t.next() 18788 , n = t.add(i).find("a").filter(this.options.navigationFilter)[0]; 18789 n && t.add(i).each(function(t) { 18790 if (s.contains(this, n)) 18791 return e.options.active = Math.floor(t / 2), 18792 !1 18793 }) 18794 } 18795 o.call(this) 18796 } 18797 }(jQuery, jQuery.ui.accordion.prototype), 18798 function(t, e) { 18799 t.extend(e.options, { 18800 heightStyle: null, 18801 autoHeight: !0, 18802 clearStyle: !1, 18803 fillSpace: !1 18804 }); 18805 var i = e._create 18806 , n = e._setOption; 18807 t.extend(e, { 18808 _create: function() { 18809 this.options.heightStyle = this.options.heightStyle || this._mergeHeightStyle(), 18810 i.call(this) 18811 }, 18812 _setOption: function(t) { 18813 "autoHeight" !== t && "clearStyle" !== t && "fillSpace" !== t || (this.options.heightStyle = this._mergeHeightStyle()), 18814 n.apply(this, arguments) 18815 }, 18816 _mergeHeightStyle: function() { 18817 var t = this.options; 18818 return t.fillSpace ? "fill" : t.clearStyle ? "content" : t.autoHeight ? "auto" : void 0 18819 } 18820 }) 18821 }(jQuery, jQuery.ui.accordion.prototype), 18822 function(t, e) { 18823 t.extend(e.options.icons, { 18824 activeHeader: null, 18825 headerSelected: "ui-icon-triangle-1-s" 18826 }); 18827 var i = e._createIcons; 18828 e._createIcons = function() { 18829 this.options.icons && (this.options.icons.activeHeader = this.options.icons.activeHeader || this.options.icons.headerSelected), 18830 i.call(this) 18831 } 18832 }(jQuery, jQuery.ui.accordion.prototype), 18833 function(t, e) { 18834 e.activate = e._activate; 18835 var i = e._findActive; 18836 e._findActive = function(t) { 18837 return -1 === t && (t = !1), 18838 t && "number" != typeof t && -1 === (t = this.headers.index(this.headers.filter(t))) && (t = !1), 18839 i.call(this, t) 18840 } 18841 }(jQuery, jQuery.ui.accordion.prototype), 18842 jQuery.ui.accordion.prototype.resize = jQuery.ui.accordion.prototype.refresh, 18843 function(t, e) { 18844 t.extend(e.options, { 18845 change: null, 18846 changestart: null 18847 }); 18848 var s = e._trigger; 18849 e._trigger = function(t, e, i) { 18850 var n = s.apply(this, arguments); 18851 return !!n && ("beforeActivate" === t ? n = s.call(this, "changestart", e, { 18852 oldHeader: i.oldHeader, 18853 oldContent: i.oldPanel, 18854 newHeader: i.newHeader, 18855 newContent: i.newPanel 18856 }) : "activate" === t && (n = s.call(this, "change", e, { 18857 oldHeader: i.oldHeader, 18858 oldContent: i.oldPanel, 18859 newHeader: i.newHeader, 18860 newContent: i.newPanel 18861 })), 18862 n) 18863 } 18864 }(jQuery, jQuery.ui.accordion.prototype), 18865 function(t, e) { 18866 t.extend(e.options, { 18867 animate: null, 18868 animated: "slide" 18869 }); 18870 var i = e._create; 18871 e._create = function() { 18872 var t = this.options; 18873 null === t.animate && (t.animated ? "slide" === t.animated ? t.animate = 300
18873: "bounceslide" === t.animated ? t.animate = { 18874 duration: 200, 18875 down: { 18876 easing: "easeOutBounce", 18877 duration: 1e3 18878 } 18879 } : t.animate = t.animated : t.animate = !1), 18880 i.call(this) 18881 } 18882 }(jQuery, jQuery.ui.accordion.prototype)) 18883}(jQuery), 18884function(o) { 18885 var n = 0; 18886 o.widget("ui.autocomplete", { 18887 version: "1.9.0", 18888 defaultElement: "<input>", 18889 options: { 18890 appendTo: "body", 18891 autoFocus: !1, 18892 delay: 300, 18893 minLength: 1, 18894 position: { 18895 my: "left top", 18896 at: "left bottom", 18897 collision: "none" 18898 }, 18899 source: null, 18900 change: null, 18901 close: null, 18902 focus: null, 18903 open: null, 18904 response: null, 18905 search: null, 18906 select: null 18907 }, 18908 pending: 0, 18909 _create: function() { 18910 var i, n, s; 18911 this.isMultiLine = this._isMultiLine(), 18912 this.valueMethod = this.element[this.element.is("input,textarea") ? "val" : "text"], 18913 this.isNewMenu = !0, 18914 this.element.addClass("ui-autocomplete-input").attr("autocomplete", "off"), 18915 this._on({ 18916 keydown: function(t) { 18917 if (this.element.prop("readOnly")) 18918 n = s = i = !0; 18919 else { 18920 n = s = i = !1; 18921 var e = o.ui.keyCode; 18922 switch (t.keyCode) { 18923 case e.PAGE_UP: 18924 i = !0, 18925 this._move("previousPage", t); 18926 break; 18927 case e.PAGE_DOWN: 18928 i = !0, 18929 this._move("nextPage", t); 18930 break; 18931 case e.UP: 18932 i = !0, 18933 this._keyEvent("previous", t); 18934 break; 18935 case e.DOWN: 18936 i = !0, 18937 this._keyEvent("next", t); 18938 break; 18939 case e.ENTER: 18940 case e.NUMPAD_ENTER: 18941 this.menu.active && (i = !0, 18942 t.preventDefault(), 18943 this.menu.select(t)); 18944 break; 18945 case e.TAB: 18946 this.menu.active && this.menu.select(t); 18947 break; 18948 case e.ESCAPE: 18949 this.menu.element.is(":visible") && (this._value(this.term), 18950 this.close(t), 18951 t.preventDefault()); 18952 break; 18953 default: 18954 n = !0, 18955 this._searchTimeout(t) 18956 } 18957 } 18958 }, 18959 keypress: function(t) { 18960 if (i) 18961 return i = !1, 18962 void t.preventDefault(); 18963 if (!n) { 18964 var e = o.ui.keyCode; 18965 switch (t.keyCode) { 18966 case e.PAGE_UP: 18967 this._move("previousPage", t); 18968 break; 18969 case e.PAGE_DOWN: 18970 this._move("nextPage", t); 18971 break; 18972 case e.UP: 18973 this._keyEvent("previous", t); 18974 break; 18975 case e.DOWN: 18976 this._keyEvent("next", t) 18977 } 18978 } 18979 }, 18980 input: function(t) { 18981 if (s) 18982 return s = !1, 18983 void t.preventDefault(); 18984 this._searchTimeout(t) 18985 }, 18986 focus: function() { 18987 this.selectedItem = null, 18988 this.previous = this._value() 18989 }, 18990 blur: function(t) { 18991 this.cancelBlur ? delete this.cancelBlur : (clearTimeout(this.searching), 18992 this.close(t), 18993 this._change(t)) 18994 } 18995 }), 18996 this._initSource(), 18997 this.menu = o("<ul>").addClass("ui-autocomplete").appendTo(this.document.find(this.options.appendTo || "body")[0]).menu({ 18998 input: o(), 18999 role: null 19000 }).zIndex(this.element.zIndex() + 1).hide().data("menu"), 19001 this._on(this.menu.element, { 19002 mousedown: function(t) { 19003 t.preventDefault(), 19004 this.cancelBlur = !0, 19005 this._delay(function() { 19006 delete this.cancelBlur 19007 }); 19008 var i = this.menu.element[0]; 19009 o(t.target).closest(".ui-menu-item").length || this._delay(function() { 19010 var e = this; 19011 this.document.one("mousedown", function(t) { 19012 t.target === e.element[0] || t.target === i || o.contains(i, t.target) || e.close() 19013 }) 19014 }) 19015 }, 19016 menufocus: function(t, e) { 19017 if (this.isNewMenu && (this.isNewMenu = !1, 19018 t.originalEvent && /^mouse/.test(t.originalEvent.type))) 19019 return this.menu.blur(), 19020 void this.document.one("mousemove", function() { 19021 o(t.target).trigger(t.originalEvent) 19022 }); 19023 var i = e.item.data("ui-autocomplete-item") || e.item.data("item.autocomplete"); 19024 !1 !== this._trigger("focus", t, { 19025 item: i 19026 }) ? t.originalEvent && /^key/.test(t.originalEvent.type) && this._value(i.value) : this.liveRegion.text(i.value) 19027 }, 19028 menuselect: function(t, e) { 19029 var i = e.item.data("ui-autocomplete-item") || e.item.data("item.autocomplete") 19030 , n = this.previous; 19031 this.element[0] !== this.document[0].activeElement && (this.element.focus(), 19032 this.previous = n, 19033 this._delay(function() { 19034 this.previous = n, 19035 this.selectedItem = i 19036 })), 19037 !1 !== this._trigger("select", t, { 19038 item: i 19039 }) && this._value(i.value),
19040 this.term = this._value(), 19041 this.close(t), 19042 this.selectedItem = i 19043 } 19044 }), 19045 this.liveRegion = o("<span>", { 19046 role: "status", 19047 "aria-live": "polite" 19048 }).addClass("ui-helper-hidden-accessible").insertAfter(this.element), 19049 o.fn.bgiframe && this.menu.element.bgiframe(), 19050 this._on(this.window, { 19051 beforeunload: function() { 19052 this.element.removeAttr("autocomplete") 19053 } 19054 }) 19055 }, 19056 _destroy: function() { 19057 clearTimeout(this.searching), 19058 this.element.removeClass("ui-autocomplete-input").removeAttr("autocomplete"), 19059 this.menu.element.remove(), 19060 this.liveRegion.remove() 19061 }, 19062 _setOption: function(t, e) { 19063 this._super(t, e), 19064 "source" === t && this._initSource(), 19065 "appendTo" === t && this.menu.element.appendTo(this.document.find(e || "body")[0]), 19066 "disabled" === t && e && this.xhr && this.xhr.abort() 19067 }, 19068 _isMultiLine: function() { 19069 return !!this.element.is("textarea") || !this.element.is("input") && this.element.prop("isContentEditable") 19070 }, 19071 _initSource: function() { 19072 var i, n, s = this; 19073 o.isArray(this.options.source) ? (i = this.options.source, 19074 this.source = function(t, e) { 19075 e(o.ui.autocomplete.filter(i, t.term)) 19076 } 19077 ) : "string" == typeof this.options.source ? (n = this.options.source, 19078 this.source = function(t, e) { 19079 s.xhr && s.xhr.abort(), 19080 s.xhr = o.ajax({ 19081 url: n, 19082 data: t, 19083 dataType: "json", 19084 success: function(t) { 19085 e(t) 19086 }, 19087 error: function() { 19088 e([]) 19089 } 19090 }) 19091 } 19092 ) : this.source = this.options.source 19093 }, 19094 _searchTimeout: function(t) { 19095 clearTimeout(this.searching), 19096 this.searching = this._delay(function() { 19097 this.term !== this._value() && (this.selectedItem = null, 19098 this.search(null, t)) 19099 }, this.options.delay) 19100 }, 19101 search: function(t, e) { 19102 return t = null != t ? t : this._value(), 19103 this.term = this._value(), 19104 t.length < this.options.minLength ? this.close(e) : !1 !== this._trigger("search", e) ? this._search(t) : void 0 19105 }, 19106 _search: function(t) { 19107 this.pending++, 19108 this.element.addClass("ui-autocomplete-loading"), 19109 this.cancelSearch = !1, 19110 this.source({ 19111 term: t 19112 }, this._response()) 19113 }, 19114 _response: function() { 19115 var e = this 19116 , i = ++n; 19117 return function(t) { 19118 i === n && e.__response(t), 19119 e.pending--, 19120 e.pending || e.element.removeClass("ui-autocomplete-loading") 19121 } 19122 }, 19123 __response: function(t) { 19124 t && (t = this._normalize(t)), 19125 this._trigger("response", null, { 19126 content: t 19127 }), 19128 !this.options.disabled && t && t.length && !this.cancelSearch ? (this._suggest(t), 19129 this._trigger("open")) : this._close() 19130 }, 19131 close: function(t) { 19132 this.cancelSearch = !0, 19133 this._close(t) 19134 }, 19135 _close: function(t) { 19136 this.menu.element.is(":visible") && (this.menu.element.hide(), 19137 this.menu.blur(), 19138 this.isNewMenu = !0, 19139 this._trigger("close", t)) 19140 }, 19141 _change: function(t) { 19142 this.previous !== this._value() && this._trigger("change", t, { 19143 item: this.selectedItem 19144 }) 19145 }, 19146 _normalize: function(t) { 19147 return t.length && t[0].label && t[0].value ? t : o.map(t, function(t) { 19148 return "string" == typeof t ? { 19149 label: t, 19150 value: t 19151 } : o.extend({ 19152 label: t.label || t.value, 19153 value: t.value || t.label 19154 }, t) 19155 }) 19156 }, 19157 _suggest: function(t) { 19158 var e = this.menu.element.empty().zIndex(this.element.zIndex() + 1); 19159 this._renderMenu(e, t), 19160 this.menu.refresh(), 19161 e.show(), 19162 this._resizeMenu(), 19163 e.position(o.extend({ 19164 of: this.element 19165 }, this.options.position)), 19166 this.options.autoFocus && this.menu.next() 19167 }, 19168 _resizeMenu: function() { 19169 var t = this.menu.element; 19170 t.outerWidth(Math.max(t.width("").outerWidth() + 1, this.element.outerWidth())) 19171 }, 19172 _renderMenu: function(i, t) { 19173 var n = this; 19174 o.each(t, function(t, e) { 19175 n._renderItemData(i, e) 19176 }) 19177 }, 19178 _renderItemData: function(t, e) { 19179 return this._renderItem(t, e).data("ui-autocomplete-item", e) 19180 }, 19181 _renderItem: function(t, e) { 19182 return o("<li>").append(o("<a>").text(e.label)).appendTo(t) 19183 }, 19184 _move: function(t, e) { 19185 if (this.menu.element.is(":visible")) 19186 return this.menu.isFirstItem() && /^previous/.test(t) || this.menu.isLastItem() && /^next/.test(t) ? (this._value(this.term), 19187 void this.menu.blur()) : void this.menu[t](e); 19188 this.search(null, e) 19189 }, 19190 widget: function() { 19191 return this.menu.element 19192 }, 19193 _value: function() { 19194 return this.valueMethod.apply(this.element, arguments) 19195 }, 19196 _keyEvent: function(t, e) { 19197 this.isMultiLine && !this.menu.element.is(":visible") || (this._move(t, e), 19198 e.preventDefault()) 19199 } 19200 }), 19201 o.extend(o.ui.autocomplete, { 19202 escapeRegex: function(t) { 19203 return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&") 19204 }, 19205 filter: function(t, e) { 19206 var i = new RegExp(o.ui.autocomplete.escapeRegex(e),"i"); 19207 return o.grep(t, function(t) { 19208 return i.test(t.label || t.value || t) 19209 }) 19210 } 19211 }), 19212 o.widget("ui.autocomplete", o.ui.autocomplete, { 19213 options: { 19214 messages: { 19215 noResults: "No search results.", 19216 results: function(t) { 19217 return t + (1 < t ? " results are" : " result is") + " available, use up and down arrow keys to navigate." 19218 } 19219 } 19220 }, 19221 __response: function(t) { 19222 var e; 19223 this._superApply(arguments), 19224 this.options.disabled || this.cancelSearch || (e = t && t.length ? this.options.messages.results(t.length) : this.options.messages.noResults, 19225 this.liveRegion.text(e)) 19226 } 19227 }) 19228}(jQuery), 19229function(o) { 19230 var r, a, l, c, u = "ui-button ui-widget ui-state-default ui-corner-all", h = "ui-button-icons-only ui-button-icon-only ui-button-text-icons ui-button-text-icon-primary ui-button-text-icon-secondary ui-button-text-only", d = function() { 19231 var t = o(this).find(":ui-button"); 19232 setTimeout(function() { 19233 t.button("refresh") 19234 }, 1) 19235 }, p = function(t) { 19236 var e = t.name 19237 , i = t.form 19238 , n = o([]); 19239 return e && (n = i ? o(i).find("[name='" + e + "']") : o("[name='" + e + "']", t.ownerDocument).filter(function() { 19240 return !this.form 19241 })), 19242 n 19243 }; 19244 o.widget("ui.button", { 19245 version: "1.9.0", 19246 defaultElement: "<button>", 19247 options: { 19248 disabled: null, 19249 text: !0, 19250 label: null, 19251 icons: { 19252 primary: null, 19253 secondary: null 19254 } 19255 }, 19256 _create: function() { 19257 this.element.closest("form").unbind("reset" + this.eventNamespace).bind("reset" + this.eventNamespace, d), 19258 "boolean" != typeof this.options.disabled ? this.options.disabled = !!this.element.prop("disabled") : this.element.prop("disabled", this.options.disabled), 19259 this._determineButtonType(), 19260 this.hasTitle = !!this.buttonElement.attr("title"); 19261 var e = this 19262 , i = this.options 19263 , t = "checkbox" === this.type || "radio" === this.type 19264 , n = "ui-state-hover" + (t ? "" : " ui-state-active") 19265 , s = "ui-state-focus"; 19266 null === i.label && (i.label = "input" === this.type ? this.buttonElement.val() : this.buttonElement.html()), 19267 this.buttonElement.addClass(u).attr("role", "button").bind("mouseenter" + this.eventNamespace, function() { 19268 i.disabled || (o(this).addClass("ui-state-hover"), 19269 this === r && o(this).addClass("ui-state-active")) 19270 }).bind("mouseleave" + this.eventNamespace, function() { 19271 i.disabled || o(this).removeClass(n) 19272 }).bind("click" + this.eventNamespace, function(t) { 19273 i.disabled && (t.preventDefault(), 19274 t.stopImmediatePropagation()) 19275 }), 19276 this.element.bind("focus" + this.eventNamespace, function() { 19277 e.buttonElement.addClass(s) 19278 }).bind("blur" + this.eventNamespace, function() { 19279 e.buttonElement.removeClass(s) 19280 }), 19281 t && (this.element.bind("change" + this.eventNamespace, function() { 19282 c || e.refresh() 19283 }), 19284 this.buttonElement.bind("mousedown" + this.eventNamespace, function(t) { 19285 i.disabled || (c = !1, 19286 a = t.pageX, 19287 l = t.pageY) 19288 }).bind("mouseup" + this.eventNamespace, function(t) { 19289 i.disabled || a === t.pageX && l === t.pageY || (c = !0) 19290 })), 19291 "checkbox" === this.type ? this.buttonElement.bind("click" + this.eventNamespace, function() { 19292 if (i.disabled || c) 19293 return !1; 19294 o(this).toggleClass("ui-state-active"), 19295 e.buttonElement.attr("aria-pressed", e.element[0].checked) 19296 }) : "radio" === this.type ? this.buttonElement.bind("click" + this.eventNamespace, function() { 19297 if (i.disabled || c) 19298 return !1; 19299 o(this).addClass("ui-state-active"), 19300 e.buttonElement.attr("aria-pressed", "true"); 19301 var t = e.element[0]; 19302 p(t).not(t).map(function() { 19303 return o(this).button("widget")[0] 19304 }).removeClass("ui-state-active").attr("aria-pressed", "false") 19305 }) : (this.buttonElement.bind("mousedown" + this.eventNamespace, function() { 19306 if (i.disabled) 19307 return !1; 19308 o(this).addClass("ui-state-active"), 19309 r = this, 19310 e.document.one("mouseup", function() { 19311 r = null 19312 }) 19313 }).bind("mouseup" + this.eventNamespace, function() { 19314 if (i.disabled) 19315 return !1; 19316 o(this).removeClass("ui-state-active") 19317 }).bind("keydown" + this.eventNamespace, function(t) { 19318 if (i.disabled) 19319 return !1; 19320 t.keyCode !== o.ui.keyCode.SPACE && t.keyCode !== o.ui.keyCode.ENTER || o(this).addClass("ui-state-active") 19321 }).bind("keyup" + this.eventNamespace, function() { 19322 o(this).removeClass("ui-state-active") 19323 }), 19324 this.buttonElement.is("a") && this.buttonElement.keyup(function(t) { 19325 t.keyCode === o.ui.keyCode.SPACE && o(this).click() 19326 })), 19327 this._setOption("disabled", i.disabled), 19328 this._resetButton() 19329 }, 19330 _determineButtonType: function() { 19331 var t, e, i; 19332 this.element.is("[type=checkbox]") ? this.type = "checkbox" : this.element.is("[type=radio]") ? this.type = "radio" : this.element.is("input") ? this.type = "input" : this.type = "button", 19333 "checkbox" === this.type || "radio" === this.type ? (t = this.element.parents().last(
vendor: 4,957 bytes, lines 19333-19431
19333), 19334 e = "label[for='" + this.element.attr("id") + "']", 19335 this.buttonElement = t.find(e), 19336 this.buttonElement.length || (t = t.length ? t.siblings() : this.element.siblings(), 19337 this.buttonElement = t.filter(e), 19338 this.buttonElement.length || (this.buttonElement = t.find(e))), 19339 this.element.addClass("ui-helper-hidden-accessible"), 19340 (i = this.element.is(":checked")) && this.buttonElement.addClass("ui-state-active"), 19341 this.buttonElement.prop("aria-pressed", i)) : this.buttonElement = this.element 19342 }, 19343 widget: function() { 19344 return this.buttonElement 19345 }, 19346 _destroy: function() { 19347 this.element.removeClass("ui-helper-hidden-accessible"), 19348 this.buttonElement.removeClass(u + " ui-state-hover ui-state-active " + h).removeAttr("role").removeAttr("aria-pressed").html(this.buttonElement.find(".ui-button-text").html()), 19349 this.hasTitle || this.buttonElement.removeAttr("title") 19350 }, 19351 _setOption: function(t, e) { 19352 this._super(t, e), 19353 "disabled" !== t ? this._resetButton() : e ? this.element.prop("disabled", !0) : this.element.prop("disabled", !1) 19354 }, 19355 refresh: function() { 19356 var t = this.element.is(":disabled"); 19357 t !== this.options.disabled && this._setOption("disabled", t), 19358 "radio" === this.type ? p(this.element[0]).each(function() { 19359 o(this).is(":checked") ? o(this).button("widget").addClass("ui-state-active").attr("aria-pressed", "true") : o(this).button("widget").removeClass("ui-state-active").attr("aria-pressed", "false") 19360 }) : "checkbox" === this.type && (this.element.is(":checked") ? this.buttonElement.addClass("ui-state-active").attr("aria-pressed", "true") : this.buttonElement.removeClass("ui-state-active").attr("aria-pressed", "false")) 19361 }, 19362 _resetButton: function() { 19363 if ("input" !== this.type) { 19364 var t = this.buttonElement.removeClass(h) 19365 , e = o("<span></span>", this.document[0]).addClass("ui-button-text").html(this.options.label).appendTo(t.empty()).text() 19366 , i = this.options.icons 19367 , n = i.primary && i.secondary 19368 , s = []; 19369 i.primary || i.secondary ? (this.options.text && s.push("ui-button-text-icon" + (n ? "s" : i.primary ? "-primary" : "-secondary")), 19370 i.primary && t.prepend("<span class='ui-button-icon-primary ui-icon " + i.primary + "'></span>"), 19371 i.secondary && t.append("<span class='ui-button-icon-secondary ui-icon " + i.secondary + "'></span>"), 19372 this.options.text || (s.push(n ? "ui-button-icons-only" : "ui-button-icon-only"), 19373 this.hasTitle || t.attr("title", o.trim(e)))) : s.push("ui-button-text-only"), 19374 t.addClass(s.join(" ")) 19375 } else 19376 this.options.label && this.element.val(this.options.label) 19377 } 19378 }), 19379 o.widget("ui.buttonset", { 19380 version: "1.9.0", 19381 options: { 19382 items: "button, input[type=button], input[type=submit], input[type=reset], input[type=checkbox], input[type=radio], a, :data(button)" 19383 }, 19384 _create: function() { 19385 this.element.addClass("ui-buttonset") 19386 }, 19387 _init: function() { 19388 this.refresh() 19389 }, 19390 _setOption: function(t, e) { 19391 "disabled" === t && this.buttons.button("option", t, e), 19392 this._super(t, e) 19393 }, 19394 refresh: function() { 19395 var t = "rtl" === this.element.css("direction"); 19396 this.buttons = this.element.find(this.options.items).filter(":ui-button").button("refresh").end().not(":ui-button").button().end().map(function() { 19397 return o(this).button("widget")[0] 19398 }).removeClass("ui-corner-all ui-corner-left ui-corner-right").filter(":first").addClass(t ? "ui-corner-right" : "ui-corner-left").end().filter(":last").addClass(t ? "ui-corner-left" : "ui-corner-right").end().end() 19399 }, 19400 _destroy: function() { 19401 this.element.removeClass("ui-buttonset"), 19402 this.buttons.map(function() { 19403 return o(this).button("widget")[0] 19404 }).removeClass("ui-corner-left ui-corner-right").end().button("destroy") 19405 } 19406 }) 19407}(jQuery), 19408function($, undefined) { 19409 function Datepicker() { 19410 this.debug = !1, 19411 this._curInst = null, 19412 this._keyEvent = !1, 19413 this._disabledInputs = [], 19414 this._datepickerShowing = !1, 19415 this._inDialog = !1, 19416 this._mainDivId = "ui-datepicker-div", 19417 this._inlineClass = "ui-datepicker-inline", 19418 this._appendClass = "ui-datepicker-append", 19419 this._triggerClass = "ui-datepicker-trigger", 19420 this._dialogClass = "ui-datepicker-dialog", 19421 this._disableClass = "ui-datepicker-disabled", 19422 this._unselectableClass = "ui-datepicker-unselectable", 19423 this._currentClass = "ui-datepicker-current-day", 19424 this._dayOverClass = "ui-datepicker-days-cell-over", 19425 this.regional = [], 19426 this.regional[""] = { 19427 closeText: "Done", 19428 prevText: "Prev", 19429 nextText: "Next", 19430 currentText: "Today", 19431 monthNames: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "
19431November", "December"], 19432 monthNamesShort: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], 19433 dayNames: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"], 19434 dayNamesShort: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], 19435 dayNamesMin: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], 19436 weekHeader: "Wk", 19437 dateFormat: "mm/dd/yy", 19438 firstDay: 0, 19439 isRTL: !1, 19440 showMonthAfterYear: !1, 19441 yearSuffix: "" 19442 }, 19443 this._defaults = { 19444 showOn: "focus", 19445 showAnim: "fadeIn", 19446 showOptions: {}, 19447 defaultDate: null, 19448 appendText: "", 19449 buttonText: "...", 19450 buttonImage: "", 19451 buttonImageOnly: !1, 19452 hideIfNoPrevNext: !1, 19453 navigationAsDateFormat: !1, 19454 gotoCurrent: !1, 19455 changeMonth: !1, 19456 changeYear: !1, 19457 yearRange: "c-10:c+10", 19458 showOtherMonths: !1, 19459 selectOtherMonths: !1, 19460 showWeek: !1, 19461 calculateWeek: this.iso8601Week, 19462 shortYearCutoff: "+10", 19463 minDate: null, 19464 maxDate: null, 19465 duration: "fast", 19466 beforeShowDay: null, 19467 beforeShow: null, 19468 onSelect: null, 19469 onChangeMonthYear: null, 19470 onClose: null, 19471 numberOfMonths: 1, 19472 showCurrentAtPos: 0, 19473 stepMonths: 1, 19474 stepBigMonths: 12, 19475 altField: "", 19476 altFormat: "", 19477 constrainInput: !0, 19478 showButtonPanel: !1, 19479 autoSize: !1, 19480 disabled: !1 19481 }, 19482 $.extend(this._defaults, this.regional[""]), 19483 this.dpDiv = bindHover($('<div id="' + this._mainDivId + '" class="ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>')) 19484 } 19485 function bindHover(t) { 19486 var e = "button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a"; 19487 return t.delegate(e, "mouseout", function() { 19488 $(this).removeClass("ui-state-hover"), 19489 -1 != this.className.indexOf("ui-datepicker-prev") && $(this).removeClass("ui-datepicker-prev-hover"), 19490 -1 != this.className.indexOf("ui-datepicker-next") && $(this).removeClass("ui-datepicker-next-hover") 19491 }).delegate(e, "mouseover", function() { 19492 $.datepicker._isDisabledDatepicker(instActive.inline ? t.parent()[0] : instActive.input[0]) || ($(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"), 19493 $(this).addClass("ui-state-hover"), 19494 -1 != this.className.indexOf("ui-datepicker-prev") && $(this).addClass("ui-datepicker-prev-hover"), 19495 -1 != this.className.indexOf("ui-datepicker-next") && $(this).addClass("ui-datepicker-next-hover")) 19496 }) 19497 } 19498 function extendRemove(t, e) { 19499 for (var i in $.extend(t, e), 19500 e) 19501 null != e[i] && e[i] != undefined || (t[i] = e[i]); 19502 return t 19503 } 19504 $.extend($.ui, { 19505 datepicker: { 19506 version: "1.9.0" 19507 } 19508 }); 19509 var PROP_NAME = "datepicker", dpuuid = (new Date).getTime(), instActive; 19510 $.extend(Datepicker.prototype, { 19511 markerClassName: "hasDatepicker", 19512 maxRows: 4, 19513 log: function() { 19514 this.debug && console.log.apply("", arguments) 19515 }, 19516 _widgetDatepicker: function() { 19517 return this.dpDiv 19518 }, 19519 setDefaults: function(t) { 19520 return extendRemove(this._defaults, t || {}), 19521 this 19522 }, 19523 _attachDatepicker: function(target, settings) { 19524 var inlineSettings = null; 19525 for (var attrName in this._defaults) { 19526 var attrValue = target.getAttribute("date:" + attrName); 19527 if (attrValue) { 19528 inlineSettings = inlineSettings || {}; 19529 try { 19530 inlineSettings[attrName] = eval(attrValue) 19531 } catch (t) { 19532 inlineSettings[attrName] = attrValue 19533 } 19534 } 19535 } 19536 var nodeName = target.nodeName.toLowerCase() 19537 , inline = "div" == nodeName || "span" == nodeName; 19538 target.id || (this.uuid += 1, 19539 target.id = "dp" + this.uuid); 19540 var inst = this._newInst($(target), inline); 19541 inst.settings = $.extend({}, settings || {}, inlineSettings || {}), 19542 "input" == nodeName ? this._connectDatepicker(target, inst) : inline && this._inlineDatepicker(target, inst) 19543 }, 19544 _newInst: function(t, e) { 19545 return { 19546 id: t[0].id.replace(/([^A-Za-z0-9_-])/g, "\\\\$1"), 19547 input: t, 19548 selectedDay: 0, 19549 selectedMonth: 0, 19550 selectedYear: 0, 19551 drawMonth: 0, 19552 drawYear: 0, 19553 inline: e, 19554 dpDiv: e ? bindHover($('<div class="' + this._inlineClass + ' ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>')) : this.dpDiv 19555 } 19556 }, 19557 _connectDatepicker: function(t, n) { 19558 var e = $(t); 19559 n.append = $([]), 19560 n.trigger = $([]), 19561 e.hasClass(this.markerClassName) || (this._attachments(e, n), 19562 e.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress).keyup(this._doKeyUp).bind("setData.datepicker", function(t, e, i) { 19563 n.settings[e] = i 19564 }).bind("getData.datepicker", function(t, e) { 19565 return this._get(n, e) 19566 }), 19567 this._autoSize(n), 19568 $.data(t, PROP_NAME, n), 19569 n.settings.disabled && this._disableDatepicker(t)) 19570 }, 19571 _attachments: function(t, e) { 19572 var i = this._get(e, "appendText") 19573 , n = this._get(e, "isRTL"); 19574 e.append && e.append.remove(), 19575 i && (e.append = $('<span class="' + this._appendClass + '">' + i + "</span>"), 19576 t[n ? "before" : "after"](e.append)), 19577 t.unbind("focus", this._showDatepicker), 19578 e.trigger && e.trigger.remove(); 19579 var s = this._get(e, "showOn"); 19580 if ("focus" != s && "both" != s || t.focus(this._showDatepicker), 19581 "button" == s || "both" == s) { 19582 var o = this._get(e, "buttonText") 19583 , r = this._get(e, "buttonImage"); 19584 e.trigger = $(this._get(e, "buttonImageOnly") ? $("<img/>").addClass(this._triggerClass).attr({ 19585 src: r, 19586 alt: o, 19587 title: o 19588 }) : $('<button type="button"></button>').addClass(this._triggerClass).html("" == r ? o : $("<img/>").attr({ 19589 src: r, 19590 alt: o, 19591 title: o 19592 }))), 19593 t[n ? "before" : "after"](e.trigger), 19594 e.trigger.click(function() { 19595 return $.datepicker._datepickerShowing && $.datepicker._lastInput == t[0] ? $.datepicker._hideDatepicker() : ($.datepicker._datepickerShowing && $.datepicker._lastInput != t[0] && $.datepicker._hideDatepicker(), 19596 $.datepicker._showDatepicker(t[0])), 19597 !1 19598 }) 19599 } 19600 }, 19601 _autoSize: function(t) { 19602 if (this._get(t, "autoSize") && !t.inline) { 19603 var e = new Date(2009,11,20) 19604 , i = this._get(t, "dateFormat"); 19605 if (i.match(/[DM]/)) { 19606 var n = function(t) { 19607 for (var e = 0, i = 0, n = 0; n < t.length; n++) 19608 t[n].length > e && (e = t[n].length, 19609 i = n); 19610 return i 19611 }; 19612 e.setMonth(n(this._get(t, i.match(/MM/) ? "monthNames" : "monthNamesShort"))), 19613 e.setDate(n(this._get(t, i.match(/DD/) ? "dayNames" : "dayNamesShort")) + 20 - e.getDay()) 19614 } 19615 t.input.attr("size", this._formatDate(t, e).length) 19616 } 19617 }, 19618 _inlineDatepicker: function(t, n) { 19619 var e = $(t); 19620 e.hasClass(this.markerClassName) || (e.addClass(this.markerClassName).append(n.dpDiv).bind("setData.datepicker", function(t, e, i) { 19621 n.settings[e] = i 19622 }).bind("getData.datepicker", function(t, e) { 19623 return this._get(n, e) 19624 }), 19625 $.data(t, PROP_NAME, n), 19626 this._setDate(n, this._getDefaultDate(n), !0), 19627 this._updateDatepicker(n), 19628 this._updateAlternate(n), 19629 n.settings.disabled && this._disableDatepicker(t), 19630 n.dpDiv.css("display", "block")) 19631 }, 19632 _dialogDatepicker: function(t, e, i, n, s) { 19633 var o = this._dialogInst; 19634 if (!o) { 19635 this.uuid += 1; 19636 var r = "dp" + this.uuid; 19637 this._dialogInput = $('<input type="text" id="' + r + '" style="position: absolute; top: -100px; width: 0px;"/>'), 19638 this._dialogInput.keydown(this._doKeyDown), 19639 $("body").append(this._dialogInput), 19640 (o = this._dialogInst = this._newInst(this._dialogInput, !1)).settings = {}, 19641 $.data(this._dialogInput[0], PROP_NAME, o) 19642 } 19643 if (extendRemove(o.settings, n || {}), 19644 e = e && e.constructor == Date ? this._formatDate(o, e) : e, 19645 this._dialogInput.val(e), 19646 this._pos = s ? s.length ? s : [s.pageX, s.pageY] : null, 19647 !this._pos) { 19648 var a = document.documentElement.clientWidth 19649 , l = document.documentElement.clientHeight 19650 , c = document.documentElement.scrollLeft || document.body.scrollLeft 19651 , u = document.documentElement.scrollTop || document.body.scrollTop; 19652 this._pos = [a / 2 - 100 + c, l / 2 - 150 + u] 19653 } 19654 return this._dialogInput.css("left", this._pos[0] + 20 + "px").css("top", this._pos[1] + "px"), 19655 o.settings.onSelect = i, 19656 this._inDialog = !0, 19657 this.dpDiv.addClass(this._dialogClass), 19658 this._showDatepicker(this._dialogInput[0]), 19659 $.blockUI && $.blockUI(this.dpDiv), 19660 $.data(this._dialogInput[0], PROP_NAME, o), 19661 this 19662 }, 19663 _destroyDatepicker: function(t) { 19664 var e = $(t) 19665 , i = $.data(t, PROP_NAME); 19666 if (e.hasClass(this.markerClassName)) { 19667 var n = t.nodeName.toLowerCase(); 19668 $.removeData(t, PROP_NAME), 19669 "input" == n ? (i.append.remove(), 19670 i.trigger.remove(), 19671 e.removeClass(this.markerClassName).unbind("focus", this._showDatepicker).unbind("
19671keydown", this._doKeyDown).unbind("keypress", this._doKeyPress).unbind("keyup", this._doKeyUp)) : "div" != n && "span" != n || e.removeClass(this.markerClassName).empty() 19672 } 19673 }, 19674 _enableDatepicker: function(e) { 19675 var t = $(e) 19676 , i = $.data(e, PROP_NAME); 19677 if (t.hasClass(this.markerClassName)) { 19678 var n = e.nodeName.toLowerCase(); 19679 if ("input" == n) 19680 e.disabled = !1, 19681 i.trigger.filter("button").each(function() { 19682 this.disabled = !1 19683 }).end().filter("img").css({ 19684 opacity: "1.0", 19685 cursor: "" 19686 }); 19687 else if ("div" == n || "span" == n) { 19688 var s = t.children("." + this._inlineClass); 19689 s.children().removeClass("ui-state-disabled"), 19690 s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled", !1) 19691 } 19692 this._disabledInputs = $.map(this._disabledInputs, function(t) { 19693 return t == e ? null : t 19694 }) 19695 } 19696 }, 19697 _disableDatepicker: function(e) { 19698 var t = $(e) 19699 , i = $.data(e, PROP_NAME); 19700 if (t.hasClass(this.markerClassName)) { 19701 var n = e.nodeName.toLowerCase(); 19702 if ("input" == n) 19703 e.disabled = !0, 19704 i.trigger.filter("button").each(function() { 19705 this.disabled = !0 19706 }).end().filter("img").css({ 19707 opacity: "0.5", 19708 cursor: "default" 19709 }); 19710 else if ("div" == n || "span" == n) { 19711 var s = t.children("." + this._inlineClass); 19712 s.children().addClass("ui-state-disabled"), 19713 s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled", !0) 19714 } 19715 this._disabledInputs = $.map(this._disabledInputs, function(t) { 19716 return t == e ? null : t 19717 }), 19718 this._disabledInputs[this._disabledInputs.length] = e 19719 } 19720 }, 19721 _isDisabledDatepicker: function(t) { 19722 if (!t) 19723 return !1; 19724 for (var e = 0; e < this._disabledInputs.length; e++) 19725 if (this._disabledInputs[e] == t) 19726 return !0; 19727 return !1 19728 }, 19729 _getInst: function(t) { 19730 try { 19731 return $.data(t, PROP_NAME) 19732 } catch (t) { 19733 throw "Missing instance data for this datepicker" 19734 } 19735 }, 19736 _optionDatepicker: function(t, e, i) { 19737 var n = this._getInst(t); 19738 if (2 == arguments.length && "string" == typeof e) 19739 return "defaults" == e ? $.extend({}, $.datepicker._defaults) : n ? "all" == e ? $.extend({}, n.settings) : this._get(n, e) : null; 19740 var s = e || {}; 19741 if ("string" == typeof e && ((s = {})[e] = i), 19742 n) { 19743 this._curInst == n && this._hideDatepicker(); 19744 var o = this._getDateDatepicker(t, !0) 19745 , r = this._getMinMaxDate(n, "min") 19746 , a = this._getMinMaxDate(n, "max"); 19747 extendRemove(n.settings, s), 19748 null !== r && s.dateFormat !== undefined && s.minDate === undefined && (n.settings.minDate = this._formatDate(n, r)), 19749 null !== a && s.dateFormat !== undefined && s.maxDate === undefined && (n.settings.maxDate = this._formatDate(n, a)), 19750 this._attachments($(t), n), 19751 this._autoSize(n), 19752 this._setDate(n, o), 19753 this._updateAlternate(n), 19754 this._updateDatepicker(n) 19755 } 19756 }, 19757 _changeDatepicker: function(t, e, i) { 19758 this._optionDatepicker(t, e, i) 19759 }, 19760 _refreshDatepicker: function(t) { 19761 var e = this._getInst(t); 19762 e && this._updateDatepicker(e) 19763 }, 19764 _setDateDatepicker: function(t, e) { 19765 var i = this._getInst(t); 19766 i && (this._setDate(i, e), 19767 this._updateDatepicker(i), 19768 this._updateAlternate(i)) 19769 }, 19770 _getDateDatepicker: function(t, e) { 19771 var i = this._getInst(t); 19772 return i && !i.inline && this._setDateFromField(i, e), 19773 i ? this._getDate(i) : null 19774 }, 19775 _doKeyDown: function(t) { 19776 var e = $.datepicker._getInst(t.target) 19777 , i = !0 19778 , n = e.dpDiv.is(".ui-datepicker-rtl"); 19779 if (e._keyEvent = !0, 19780 $.datepicker._datepickerShowing) 19781 switch (t.keyCode) { 19782 case 9: 19783 $.datepicker._hideDatepicker(), 19784 i = !1; 19785 break; 19786 case 13: 19787 var s = $("td." + $.datepicker._dayOverClass + ":not(." + $.datepicker._currentClass + ")", e.dpDiv); 19788 s[0] && $.datepicker._selectDay(t.target, e.selectedMonth, e.selectedYear, s[0]); 19789 var o = $.datepicker._get(e, "onSelect"); 19790 if (o) { 19791 var r = $.datepicker._formatDate(e); 19792 o.apply(e.input ? e.input[0] : null, [r, e]) 19793 } else 19794 $.datepicker._hideDatepicker(); 19795 return !1; 19796 case 27: 19797 $.datepicker._hideDatepicker(); 19798 break; 19799 case 33: 19800 $.datepicker._adjustDate(t.target, t.ctrlKey ? -$.datepicker._get(e, "stepBigMonths") : -$.datepicker._get(e, "stepMonths"), "M"); 19801 break; 19802 case 34: 19803 $.datepicker._adjustDate(t.target, t.ctrlKey ? +$.datepicker._get(e, "stepBigMonths") : +$.datepicker._get(e, "stepMonths"), "M"); 19804 break; 19805 case 35: 19806 (t.ctrlKey || t.metaKey) && $.datepicker._clearDate(t.target), 19807 i = t.ctrlKey || t.metaKey; 19808 break; 19809 case 36: 19810 (t.ctrlKey || t.metaKey) && $.datepicker._gotoToday(t.target), 19811 i = t.ctrlKey || t.metaKey; 19812 break; 19813 case 37: 19814 (t.ctrlKey || t.metaKey) && $.datepicker._adjustDate(t.target, n ? 1 : -1, "D"), 19815 i = t.ctrlKey || t.metaKey, 19816 t.originalEvent.altKey && $.datepicker._adjustDate(t.target, t.ctrlKey ? -$.datepicker._get(e, "stepBigMonths") : -$.datepicker._get(e, "stepMonths"), "M"); 19817 break; 19818 case 38: 19819 (t.ctrlKey || t.metaKey) && $.datepicker._adjustDate(t.target, -7, "D"), 19820 i = t.ctrlKey || t.metaKey; 19821 break; 19822 case 39: 19823 (t.ctrlKey || t.metaKey) && $.datepicker._adjustDate(t.target, n ? -1 : 1, "D"), 19824 i = t.ctrlKey || t.metaKey, 19825 t.originalEvent.altKey && $.datepicker._adjustDate(t.target, t.ctrlKey ? +$.datepicker._get(e, "stepBigMonths") : +$.datepicker._get(e, "stepMonths"), "M"); 19826 break; 19827 case 40: 19828 (t.ctrlKey || t.metaKey) && $.datepicker._adjustDate(t.target, 7, "D"), 19829 i = t.ctrlKey || t.metaKey; 19830 break; 19831 default: 19832 i = !1 19833 } 19834 else 19835 36 == t.keyCode && t.ctrlKey ? $.datepicker._showDatepicker(this) : i = !1; 19836 i && (t.preventDefault(), 19837 t.stopPropagation()) 19838 }, 19839 _doKeyPress: function(t) { 19840 var e = $.datepicker._getInst(t.target); 19841 if ($.datepicker._get(e, "constrainInput")) { 19842 var i = $.datepicker._possibleChars($.datepicker._get(e, "dateFormat")) 19843 , n = String.fromCharCode(t.charCode == undefined ? t.keyCode : t.charCode); 19844 return t.ctrlKey || t.metaKey || n < " " || !i || -1 < i.indexOf(n) 19845 } 19846 }, 19847 _doKeyUp: function(t) { 19848 var e = $.datepicker._getInst(t.target); 19849 if (e.input.val() != e.lastVal) 19850 try { 19851 $.datepicker.parseDate($.datepicker._get(e, "dateFormat"), e.input ? e.input.val() : null, $.datepicker._getFormatConfig(e)) && ($.datepicker._setDateFromField(e), 19852 $.datepicker._updateAlternate(e), 19853 $.datepicker._updateDatepicker(e)) 19854 } catch (t) { 19855 $.datepicker.log(t) 19856 } 19857 return !0 19858 }, 19859 _showDatepicker: function(t) { 19860 if ("input" != (t = t.target || t).nodeName.toLowerCase() && (t = $("input", t.parentNode)[0]), 19861 !$.datepicker._isDisabledDatepicker(t) && $.datepicker._lastInput != t) { 19862 var i = $.datepicker._getInst(t); 19863 $.datepicker._curInst && $.datepicker._curInst != i && ($.datepicker._curInst.dpDiv.stop(!0, !0), 19864 i && $.datepicker._datepickerShowing && $.datepicker._hideDatepicker($.datepicker._curInst.input[0])); 19865 var e = $.datepicker._get(i, "beforeShow") 19866 , n = e ? e.apply(t, [t, i]) : {}; 19867 if (!1 !== n) { 19868 extendRemove(i.settings, n), 19869 i.lastVal = null, 19870 $.datepicker._lastInput = t, 19871 $.datepicker._setDateFromField(i), 19872 $.datepicker._inDialog && (t.value = ""), 19873 $.datepicker._pos || ($.datepicker._pos = $.datepicker._findPos(t), 19874 $.datepicker._pos[1] += t.offsetHeight); 19875 var s = !1; 19876 $(t).parents().each(function() { 19877 return !(s |= "fixed" == $(this).css("position")) 19878 }); 19879 var o = { 19880 left: $.datepicker._pos[0], 19881 top: $.datepicker._pos[1] 19882 }; 19883 if ($.datepicker._pos = null, 19884 i.dpDiv.empty(), 19885 i.dpDiv.css({ 19886 position: "absolute", 19887 display: "block", 19888 top: "-1000px" 19889 }), 19890 $.datepicker._updateDatepicker(i), 19891 o = $.datepicker._checkOffset(i, o, s), 19892 i.dpDiv.css({ 19893 position: $.datepicker._inDialog && $.blockUI ? "static" : s ? "f
19893ixed" : "absolute", 19894 display: "none", 19895 left: o.left + "px", 19896 top: o.top + "px" 19897 }), 19898 !i.inline) { 19899 var r = $.datepicker._get(i, "showAnim") 19900 , a = $.datepicker._get(i, "duration") 19901 , l = function() { 19902 var t = i.dpDiv.find("iframe.ui-datepicker-cover"); 19903 if (t.length) { 19904 var e = $.datepicker._getBorders(i.dpDiv); 19905 t.css({ 19906 left: -e[0], 19907 top: -e[1], 19908 width: i.dpDiv.outerWidth(), 19909 height: i.dpDiv.outerHeight() 19910 }) 19911 } 19912 }; 19913 i.dpDiv.zIndex($(t).zIndex() + 1), 19914 $.datepicker._datepickerShowing = !0, 19915 $.effects && ($.effects.effect[r] || $.effects[r]) ? i.dpDiv.show(r, $.datepicker._get(i, "showOptions"), a, l) : i.dpDiv[r || "show"](r ? a : null, l), 19916 r && a || l(), 19917 i.input.is(":visible") && !i.input.is(":disabled") && i.input.focus(), 19918 $.datepicker._curInst = i 19919 } 19920 } 19921 } 19922 }, 19923 _updateDatepicker: function(t) { 19924 this.maxRows = 4; 19925 var e = $.datepicker._getBorders(t.dpDiv); 19926 (instActive = t).dpDiv.empty().append(this._generateHTML(t)), 19927 this._attachHandlers(t); 19928 var i = t.dpDiv.find("iframe.ui-datepicker-cover"); 19929 i.length && i.css({ 19930 left: -e[0], 19931 top: -e[1], 19932 width: t.dpDiv.outerWidth(), 19933 height: t.dpDiv.outerHeight() 19934 }), 19935 t.dpDiv.find("." + this._dayOverClass + " a").mouseover(); 19936 var n = this._getNumberOfMonths(t) 19937 , s = n[1]; 19938 if (t.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""), 19939 1 < s && t.dpDiv.addClass("ui-datepicker-multi-" + s).css("width", 17 * s + "em"), 19940 t.dpDiv[(1 != n[0] || 1 != n[1] ? "add" : "remove") + "Class"]("ui-datepicker-multi"), 19941 t.dpDiv[(this._get(t, "isRTL") ? "add" : "remove") + "Class"]("ui-datepicker-rtl"), 19942 t == $.datepicker._curInst && $.datepicker._datepickerShowing && t.input && t.input.is(":visible") && !t.input.is(":disabled") && t.input[0] != document.activeElement && t.input.focus(), 19943 t.yearshtml) { 19944 var o = t.yearshtml; 19945 setTimeout(function() { 19946 o === t.yearshtml && t.yearshtml && t.dpDiv.find("select.ui-datepicker-year:first").replaceWith(t.yearshtml), 19947 o = t.yearshtml = null 19948 }, 0) 19949 } 19950 }, 19951 _getBorders: function(t) { 19952 var e = function(t) { 19953 return { 19954 thin: 1, 19955 medium: 2, 19956 thick: 3 19957 }[t] || t 19958 }; 19959 return [parseFloat(e(t.css("border-left-width"))), parseFloat(e(t.css("border-top-width")))] 19960 }, 19961 _checkOffset: function(t, e, i) { 19962 var n = t.dpDiv.outerWidth() 19963 , s = t.dpDiv.outerHeight() 19964 , o = t.input ? t.input.outerWidth() : 0 19965 , r = t.input ? t.input.outerHeight() : 0 19966 , a = document.documentElement.clientWidth + (i ? 0 : $(document).scrollLeft()) 19967 , l = document.documentElement.clientHeight + (i ? 0 : $(document).scrollTop()); 19968 return e.left -= this._get(t, "isRTL") ? n - o : 0, 19969 e.left -= i && e.left == t.input.offset().left ? $(document).scrollLeft() : 0, 19970 e.top -= i && e.top == t.input.offset().top + r ? $(document).scrollTop() : 0, 19971 e.left -= Math.min(e.left, e.left + n > a && n < a ? Math.abs(e.left + n - a) : 0), 19972 e.top -= Math.min(e.top, e.top + s > l && s < l ? Math.abs(s + r) : 0), 19973 e 19974 }, 19975 _findPos: function(t) { 19976 for (var e = this._getInst(t), i = this._get(e, "isRTL"); t && ("hidden" == t.type || 1 != t.nodeType || $.expr.filters.hidden(t)); ) 19977 t = t[i ? "previousSibling" : "nextSibling"]; 19978 var n = $(t).offset(); 19979 return [n.left, n.top] 19980 }, 19981 _hideDatepicker: function(t) { 19982 var e = this._curInst; 19983 if (e && (!t || e == $.data(t, PROP_NAME)) && this._datepickerShowing) { 19984 var i = this._get(e, "showAnim") 19985 , n = this._get(e, "duration") 19986 , s = function() { 19987 $.datepicker._tidyDialog(e) 19988 }; 19989 $.effects && ($.effects.effect[i] || $.effects[i]) ? e.dpDiv.hide(i, $.datepicker._get(e, "showOptions"), n, s) : e.dpDiv["slideDown" == i ? "slideUp" : "fadeIn" == i ? "fadeOut" : "hide"](i ? n : null, s), 19990 i || s(), 19991 this._datepickerShowing = !1; 19992 var o = this._get(e, "onClose"); 19993 o && o.apply(e.input ? e.input[0] : null, [e.input ? e.input.val() : "", e]), 19994 this._lastInput = null, 19995 this._inDialog && (this._dialogInput.css({ 19996 position: "absolute", 19997 left: "0", 19998 top: "-100px" 19999 }), 20000 $.blockUI && ($.unblockUI(), 20001 $("body").append(this.dpDiv))), 20002 this._inDialog = !1 20003 } 20004 }, 20005 _tidyDialog: function(t) { 20006 t.dpDiv.removeClass(this._dialogClass).unbind(".ui-datepicker-calendar") 20007 }, 20008 _checkExternalClick: function(t) { 20009 if ($.datepicker._curInst) { 20010 var e = $(t.target) 20011 , i = $.datepicker._getInst(e[0]); 20012 (e[0].id == $.datepicker._mainDivId || 0 != e.parents("#" + $.datepicker._mainDivId).length || e.hasClass($.datepicker.markerClassName) || e.closest("." + $.datepicker._triggerClass).length || !$.datepicker._datepickerShowing || $.datepicker._inDialog && $.blockUI) && (!e.hasClass($.datepicker.markerClassName) || $.datepicker._curInst == i) || $.datepicker._hideDatepicker() 20013 } 20014 }, 20015 _adjustDate: function(t, e, i) { 20016 var n = $(t) 20017 , s = this._getInst(n[0]); 20018 this._isDisabledDatepicker(n[0]) || (this._adjustInstDate(s, e + ("M" == i ? this._get(s, "showCurrentAtPos") : 0), i), 20019 this._updateDatepicker(s)) 20020 }, 20021 _gotoToday: function(t) { 20022 var e = $(t) 20023 , i = this._getInst(e[0]); 20024 if (this._get(i, "gotoCurrent") && i.currentDay) 20025 i.selectedDay = i.currentDay, 20026 i.drawMonth = i.selectedMonth = i.currentMonth, 20027 i.drawYear = i.selectedYear = i.currentYear; 20028 else { 20029 var n = new Date; 20030 i.selectedDay = n.getDate(), 20031 i.drawMonth = i.selectedMonth = n.getMonth(), 20032 i.drawYear = i.selectedYear = n.getFullYear() 20033 } 20034 this._notifyChange(i), 20035 this._adjustDate(e) 20036 }, 20037 _selectMonthYear: function(t, e, i) { 20038 var n = $(t) 20039 , s = this._getInst(n[0]); 20040 s["selected" + ("M" == i ? "Month" : "Year")] = s["draw" + ("M" == i ? "Month" : "Year")] = parseInt(e.options[e.selectedIndex].value, 10), 20041 this._notifyChange(s), 20042 this._adjustDate(n) 20043 }, 20044 _selectDay: function(t, e, i, n) { 20045 var s = $(t); 20046 if (!$(n).hasClass(this._unselectableClass) && !this._isDisabledDatepicker(s[0])) { 20047 var o = this._getInst(s[0]); 20048 o.selectedDay = o.currentDay = $("a", n).html(), 20049 o.selectedMonth = o.currentMonth = e, 20050 o.selectedYear = o.currentYear = i, 20051 this._selectDate(t, this._formatDate(o, o.currentDay, o.currentMonth, o.currentYear)) 20052 } 20053 }, 20054 _clearDate: function(t) { 20055 var e = $(t); 20056 this._getInst(e[0]); 20057 this._selectDate(e, "") 20058 }, 20059 _selectDate: function(t, e) { 20060 var i = $(t) 20061 , n = this._getInst(i[0]); 20062 e = null != e ? e : this._formatDate(n), 20063 n.input && n.input.val(e), 20064 this._updateAlternate(n); 20065 var s = this._get(n, "onSelect"); 20066 s ? s.apply(n.input ? n.input[0] : null, [e, n]) : n.input && n.input.trigger("change"), 20067 n.inline ? this._updateDatepicker(n) : (this._hideDatepicker(), 20068 this._lastInput = n.input[0], 20069 "object" != typeof n.input[0] && n.input.focus(), 20070 this._lastInput = null) 20071 }, 20072 _updateAlternate: function(t) { 20073 var e = this._get(t, "altField"); 20074 if (e) { 20075 var i = this._get(t, "altFormat") || this._get(t, "dateFormat") 20076 , n = this._getDate(t) 20077 , s = this.formatDate(i, n, this._getFormatConfig(t)); 20078 $(e).each(function() { 20079 $(this).val(s) 20080 }) 20081 } 20082 },
20083 noWeekends: function(t) { 20084 var e = t.getDay(); 20085 return [0 < e && e < 6, ""] 20086 }, 20087 iso8601Week: function(t) { 20088 var e = new Date(t.getTime()); 20089 e.setDate(e.getDate() + 4 - (e.getDay() || 7)); 20090 var i = e.getTime(); 20091 return e.setMonth(0), 20092 e.setDate(1), 20093 Math.floor(Math.round((i - e) / 864e5) / 7) + 1 20094 }, 20095 parseDate: function(i, o, t) { 20096 if (null == i || null == o) 20097 throw "Invalid arguments"; 20098 if ("" == (o = "object" == typeof o ? o.toString() : o + "")) 20099 return null; 20100 var e = (t ? t.shortYearCutoff : null) || this._defaults.shortYearCutoff; 20101 e = "string" != typeof e ? e : (new Date).getFullYear() % 100 + parseInt(e, 10); 20102 for (var n = (t ? t.dayNamesShort : null) || this._defaults.dayNamesShort, s = (t ? t.dayNames : null) || this._defaults.dayNames, r = (t ? t.monthNamesShort : null) || this._defaults.monthNamesShort, a = (t ? t.monthNames : null) || this._defaults.monthNames, l = -1, c = -1, u = -1, h = -1, d = !1, p = function(t) { 20103 var e = y + 1 < i.length && i.charAt(y + 1) == t; 20104 return e && y++, 20105 e 20106 }, f = function(t) { 20107 var e = p(t) 20108 , i = new RegExp("^\\d{1," + ("@" == t ? 14 : "!" == t ? 20 : "y" == t && e ? 4 : "o" == t ? 3 : 2) + "}") 20109 , n = o.substring(v).match(i); 20110 if (!n) 20111 throw "Missing number at position " + v; 20112 return v += n[0].length, 20113 parseInt(n[0], 10) 20114 }, g = function(t, e, i) { 20115 var n = $.map(p(t) ? i : e, function(t, e) { 20116 return [[e, t]] 20117 }).sort(function(t, e) { 20118 return -(t[1].length - e[1].length) 20119 }) 20120 , s = -1; 20121 if ($.each(n, function(t, e) { 20122 var i = e[1]; 20123 if (o.substr(v, i.length).toLowerCase() == i.toLowerCase()) 20124 return s = e[0], 20125 v += i.length, 20126 !1 20127 }), 20128 -1 != s) 20129 return s + 1; 20130 throw "Unknown name at position " + v 20131 }, m = function() { 20132 if (o.charAt(v) != i.charAt(y)) 20133 throw "Unexpected literal at position " + v; 20134 v++ 20135 }, v = 0, y = 0; y < i.length; y++) 20136 if (d) 20137 "'" != i.charAt(y) || p("'") ? m() : d = !1; 20138 else 20139 switch (i.charAt(y)) { 20140 case "d": 20141 u = f("d"); 20142 break; 20143 case "D": 20144 g("D", n, s); 20145 break; 20146 case "o": 20147 h = f("o"); 20148 break; 20149 case "m": 20150 c = f("m"); 20151 break; 20152 case "M": 20153 c = g("M", r, a); 20154 break; 20155 case "y": 20156 l = f("y"); 20157 break; 20158 case "@": 20159 l = (b = new Date(f("@"))).getFullYear(), 20160 c = b.getMonth() + 1, 20161 u = b.getDate(); 20162 break; 20163 case "!": 20164 var b; 20165 l = (b = new Date((f("!") - this._ticksTo1970) / 1e4)).getFullYear(), 20166 c = b.getMonth() + 1, 20167 u = b.getDate(); 20168 break; 20169 case "'": 20170 p("'") ? m() : d = !0; 20171 break; 20172 default: 20173 m() 20174 } 20175 if (v < o.length) { 20176 var w = o.substr(v); 20177 if (!/^\s+/.test(w)) 20178 throw "Extra/unparsed characters found in date: " + w 20179 } 20180 if (-1 == l ? l = (new Date).getFullYear() : l < 100 && (l += (new Date).getFullYear() - (new Date).getFullYear() % 100 + (l <= e ? 0 : -100)), 20181 -1 < h) 20182 for (c = 1, 20183 u = h; ; ) { 20184 var x = this._getDaysInMonth(l, c - 1); 20185 if (u <= x) 20186 break; 20187 c++, 20188 u -= x 20189 } 20190 if ((b = this._daylightSavingAdjust(new Date(l,c - 1,u))).getFullYear() != l || b.getMonth() + 1 != c || b.getDate() != u) 20191 throw "Invalid date"; 20192 return b 20193 }, 20194 ATOM: "yy-mm-dd", 20195 COOKIE: "D, dd M yy", 20196 ISO_8601: "yy-mm-dd", 20197 RFC_822: "D, d M y", 20198 RFC_850: "DD, dd-M-y", 20199 RFC_1036: "D, d M y", 20200 RFC_1123: "D, d M yy", 20201 RFC_2822: "D, d M yy", 20202 RSS: "D, d M y", 20203 TICKS: "!", 20204 TIMESTAMP: "@", 20205 W3C: "yy-mm-dd", 20206 _ticksTo1970: 24 * (718685 + Math.floor(492.5) - Math.floor(19.7) + Math.floor(4.925)) * 60 * 60 * 1e7, 20207 formatDate: function(i, t, e) { 20208 if (!t) 20209 return ""; 20210 var n = (e ? e.dayNamesShort : null) || this._defaults.dayNamesShort 20211 , s = (e ? e.dayNames : null) || this._defaults.dayNames 20212 , o = (e ? e.monthNamesShort : null) || this._defaults.monthNamesShort 20213 , r = (e ? e.monthNames : null) || this._defaults.monthNames 20214 , a = function(t) { 20215 var e = d + 1 < i.length && i.charAt(d + 1) == t; 20216 return e && d++, 20217 e 20218 } 20219 , l = function(t, e, i) { 20220 var n = "" + e; 20221 if (a(t)) 20222 for (; n.length < i; ) 20223 n = "0" + n; 20224 return n 20225 } 20226 , c = function(t, e, i, n) { 20227 return a(t) ? n[e] : i[e] 20228 } 20229 , u = "" 20230 , h = !1; 20231 if (t) 20232 for (var d = 0; d < i.length; d++) 20233 if (h) 20234 "'" != i.charAt(d) || a("'") ? u += i.charAt(d) : h = !1; 20235 else 20236 switch (i.charAt(d)) { 20237 case "d": 20238 u += l("d", t.getDate(), 2); 20239 break; 20240 case "D": 20241 u += c("D", t.getDay(), n, s); 20242 break; 20243 case "o": 20244 u += l("o", Math.round((new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime() - new Date(t.getFullYear(),0,0).getTime()) / 864e5), 3); 20245 break; 20246 case "m": 20247 u += l("m", t.getMonth() + 1, 2); 20248 break; 20249 case "M": 20250 u += c("M", t.getMonth(), o, r); 20251 break; 20252 case "y": 20253 u += a("y") ? t.getFullYear() : (t.getYear() % 100 < 10 ? "0" : "") + t.getYear() % 100; 20254 break; 20255 case "@": 20256 u += t.getTime(); 20257 break; 20258 case "!": 20259 u += 1e4 * t.getTime() + this._ticksTo1970; 20260 break;
20261 case "'": 20262 a("'") ? u += "'" : h = !0; 20263 break; 20264 default: 20265 u += i.charAt(d) 20266 } 20267 return u 20268 }, 20269 _possibleChars: function(i) { 20270 for (var t = "", e = !1, n = function(t) { 20271 var e = s + 1 < i.length && i.charAt(s + 1) == t; 20272 return e && s++, 20273 e 20274 }, s = 0; s < i.length; s++) 20275 if (e) 20276 "'" != i.charAt(s) || n("'") ? t += i.charAt(s) : e = !1; 20277 else 20278 switch (i.charAt(s)) { 20279 case "d": 20280 case "m": 20281 case "y": 20282 case "@": 20283 t += "0123456789"; 20284 break; 20285 case "D": 20286 case "M": 20287 return null; 20288 case "'": 20289 n("'") ? t += "'" : e = !0; 20290 break; 20291 default: 20292 t += i.charAt(s) 20293 } 20294 return t 20295 }, 20296 _get: function(t, e) { 20297 return t.settings[e] !== undefined ? t.settings[e] : this._defaults[e] 20298 }, 20299 _setDateFromField: function(t, e) { 20300 if (t.input.val() != t.lastVal) { 20301 var i, n, s = this._get(t, "dateFormat"), o = t.lastVal = t.input ? t.input.val() : null; 20302 i = n = this._getDefaultDate(t); 20303 var r = this._getFormatConfig(t); 20304 try { 20305 i = this.parseDate(s, o, r) || n 20306 } catch (t) { 20307 this.log(t), 20308 o = e ? "" : o 20309 } 20310 t.selectedDay = i.getDate(), 20311 t.drawMonth = t.selectedMonth = i.getMonth(), 20312 t.drawYear = t.selectedYear = i.getFullYear(), 20313 t.currentDay = o ? i.getDate() : 0, 20314 t.currentMonth = o ? i.getMonth() : 0, 20315 t.currentYear = o ? i.getFullYear() : 0, 20316 this._adjustInstDate(t) 20317 } 20318 }, 20319 _getDefaultDate: function(t) { 20320 return this._restrictMinMax(t, this._determineDate(t, this._get(t, "defaultDate"), new Date)) 20321 }, 20322 _determineDate: function(a, t, e) { 20323 var i, n, s = null == t || "" === t ? e : "string" == typeof t ? function(t) { 20324 try { 20325 return $.datepicker.parseDate($.datepicker._get(a, "dateFormat"), t, $.datepicker._getFormatConfig(a)) 20326 } catch (t) {} 20327 for (var e = (t.toLowerCase().match(/^c/) ? $.datepicker._getDate(a) : null) || new Date, i = e.getFullYear(), n = e.getMonth(), s = e.getDate(), o = /([+-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g, r = o.exec(t); r; ) { 20328 switch (r[2] || "d") { 20329 case "d": 20330 case "D": 20331 s += parseInt(r[1], 10); 20332 break; 20333 case "w": 20334 case "W": 20335 s += 7 * parseInt(r[1], 10); 20336 break; 20337 case "m": 20338 case "M": 20339 n += parseInt(r[1], 10), 20340 s = Math.min(s, $.datepicker._getDaysInMonth(i, n)); 20341 break; 20342 case "y": 20343 case "Y": 20344 i += parseInt(r[1], 10), 20345 s = Math.min(s, $.datepicker._getDaysInMonth(i, n)) 20346 } 20347 r = o.exec(t) 20348 } 20349 return new Date(i,n,s) 20350 }(t) : "number" == typeof t ? isNaN(t) ? e : (i = t, 20351 (n = new Date).setDate(n.getDate() + i), 20352 n) : new Date(t.getTime()); 20353 return (s = s && "Invalid Date" == s.toString() ? e : s) && (s.setHours(0), 20354 s.setMinutes(0), 20355 s.setSeconds(0), 20356 s.setMilliseconds(0)), 20357 this._daylightSavingAdjust(s) 20358 }, 20359 _daylightSavingAdjust: function(t) { 20360 return t ? (t.setHours(12 < t.getHours() ? t.getHours() + 2 : 0), 20361 t) : null 20362 }, 20363 _setDate: function(t, e, i) { 20364 var n = !e 20365 , s = t.selectedMonth 20366 , o = t.selectedYear 20367 , r = this._restrictMinMax(t, this._determineDate(t, e, new Date)); 20368 t.selectedDay = t.currentDay = r.getDate(), 20369 t.drawMonth = t.selectedMonth = t.currentMonth = r.getMonth(), 20370 t.drawYear = t.selectedYear = t.currentYear = r.getFullYear(), 20371 s == t.selectedMonth && o == t.selectedYear || i || this._notifyChange(t), 20372 this._adjustInstDate(t), 20373 t.input && t.input.val(n ? "" : this._formatDate(t)) 20374 }, 20375 _getDate: function(t) { 20376 return !t.currentYear || t.input && "" == t.input.val() ? null : this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay)) 20377 }, 20378 _attachHandlers: function(t) { 20379 var e = this._get(t, "stepMonths") 20380 , i = "#" + t.id.replace(/\\\\/g, "\\");
20381 t.dpDiv.find("[data-handler]").map(function() { 20382 var t = { 20383 prev: function() { 20384 window["DP_jQuery_" + dpuuid].datepicker._adjustDate(i, -e, "M") 20385 }, 20386 next: function() { 20387 window["DP_jQuery_" + dpuuid].datepicker._adjustDate(i, +e, "M") 20388 }, 20389 hide: function() { 20390 window["DP_jQuery_" + dpuuid].datepicker._hideDatepicker() 20391 }, 20392 today: function() { 20393 window["DP_jQuery_" + dpuuid].datepicker._gotoToday(i) 20394 }, 20395 selectDay: function() { 20396 return window["DP_jQuery_" + dpuuid].datepicker._selectDay(i, +this.getAttribute("data-month"), +this.getAttribute("data-year"), this), 20397 !1 20398 }, 20399 selectMonth: function() { 20400 return window["DP_jQuery_" + dpuuid].datepicker._selectMonthYear(i, this, "M"), 20401 !1 20402 }, 20403 selectYear: function() { 20404 return window["DP_jQuery_" + dpuuid].datepicker._selectMonthYear(i, this, "Y"), 20405 !1 20406 } 20407 }; 20408 $(this).bind(this.getAttribute("data-event"), t[this.getAttribute("data-handler")]) 20409 }) 20410 }, 20411 _generateHTML: function(t) { 20412 var e = new Date; 20413 e = this._daylightSavingAdjust(new Date(e.getFullYear(),e.getMonth(),e.getDate())); 20414 var i = this._get(t, "isRTL") 20415 , n = this._get(t, "showButtonPanel") 20416 , s = this._get(t, "hideIfNoPrevNext") 20417 , o = this._get(t, "navigationAsDateFormat") 20418 , r = this._getNumberOfMonths(t) 20419 , a = this._get(t, "showCurrentAtPos") 20420 , l = this._get(t, "stepMonths") 20421 , c = 1 != r[0] || 1 != r[1] 20422 , u = this._daylightSavingAdjust(t.currentDay ? new Date(t.currentYear,t.currentMonth,t.currentDay) : new Date(9999,9,9)) 20423 , h = this._getMinMaxDate(t, "min") 20424 , d = this._getMinMaxDate(t, "max") 20425 , p = t.drawMonth - a 20426 , f = t.drawYear; 20427 if (p < 0 && (p += 12, 20428 f--), 20429 d) { 20430 var g = this._daylightSavingAdjust(new Date(d.getFullYear(),d.getMonth() - r[0] * r[1] + 1,d.getDate())); 20431 for (g = h && g < h ? h : g; this._daylightSavingAdjust(new Date(f,p,1)) > g; ) 20432 --p < 0 && (p = 11, 20433 f--) 20434 } 20435 t.drawMonth = p, 20436 t.drawYear = f; 20437 var m = this._get(t, "prevText"); 20438 m = o ? this.formatDate(m, this._daylightSavingAdjust(new Date(f,p - l,1)), this._getFormatConfig(t)) : m; 20439 var v = this._canAdjustMonth(t, -1, f, p) ? '<a class="ui-datepicker-prev ui-corner-all" data-handler="prev" data-event="click" title="' + m + '"><span class="ui-icon ui-icon-circle-triangle-' + (i ? "e" : "w") + '">' + m + "</span></a>" : s ? "" : '<a class="ui-datepicker-prev ui-corner-all ui-state-disabled" title="' + m + '"><span class="ui-icon ui-icon-circle-triangle-' + (i ? "e" : "w") + '">' + m + "</span></a>" 20440 , y = this._get(t, "nextText"); 20441 y = o ? this.formatDate(y, this._daylightSavingAdjust(new Date(f,p + l,1)), this._getFormatConfig(t)) : y; 20442 var b = this._canAdjustMonth(t, 1, f, p) ? '<a class="ui-datepicker-next ui-corner-all" data-handler="next" data-event="click" title="' + y + '"><span class="ui-icon ui-icon-circle-triangle-' + (i ? "w" : "e") + '">' + y + "</span></a>" : s ? "" : '<a class="ui-datepicker-next ui-corner-all ui-state-disabled" title="' + y + '"><span class="ui-icon ui-icon-circle-triangle-' + (i ? "w" : "e") + '">' + y + "</span></a>" 20443 , w = this._get(t, "currentText") 20444 , x = this._get(t, "gotoCurrent") && t.currentDay ? u : e; 20445 w = o ? this.formatDate(w, x, this._getFormatConfig(t)) : w; 20446 var _ = t.inline ? "" : '<button type="button" class="ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all" data-handler="hide" data-event="click">' + this._get(t, "closeText") + "</button>" 20447 , k = n ? '<div class="ui-datepicker-buttonpane ui-widget-content">' + (i ? _ : "") + (this._isInRange(t, x) ? '<button type="button" class="ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all" data-handler="today" data-event="click">' + w + "</button>" : "") + (i ? "" : _) + "</div>" : "" 20448 , C = parseInt(this._get(t, "firstDay"), 10); 20449 C = isNaN(C) ? 0 : C; 20450 for (var S = this._get(t, "showWeek"), T = this._get(t, "dayNames"), I = (this._get(t, "dayNamesShort"), 20451 this._get(t, "dayNamesMin")), P = this._get(t, "monthNames"), E = this._get(t, "monthNamesShort"), M = this._get(t, "beforeShowDay"), D = this._get(t, "showOtherMonths"), A = this._get(t, "selectOtherMonths"), j = (this._get(t, "calculateWeek") || this.iso8601Week, 20452 this._getDefaultDate(t)), O = "", z = 0; z < r[0]; z++) { 20453 var L = ""; 20454 this.maxRows = 4; 20455 for (var N = 0; N < r[1]; N++) { 20456 var H = this._daylightSavingAdjust(new Date(f,p,t.selectedDay)) 20457 , W = " ui-corner-all" 20458 , R = ""; 20459 if (c) { 20460 if (R += '<div class="ui-datepicker-group', 20461 1 < r[1]) 20462 switch (N) { 20463 case 0: 20464 R += " ui-datepicker-group-first", 20465 W = " ui-corner-" + (i ? "right" : "left"); 20466 break; 20467 case r[1] - 1: 20468 R += " ui-datepicker-group-last", 20469 W = " ui-corner-" + (i ? "left" : "right"); 20470 break; 20471 default: 20472 R += " ui-datepicker-group-middle", 20473 W = "" 20474 } 20475 R += '">' 20476 } 20477 R += '<div class="ui-datepicker-header ui-widget-header ui-helper-clearfix' + W + '">
20477' + (/all|left/.test(W) && 0 == z ? i ? b : v : "") + (/all|right/.test(W) && 0 == z ? i ? v : b : "") + this._generateMonthYearHeader(t, p, f, h, d, 0 < z || 0 < N, P, E) + '</div><table class="ui-datepicker-calendar"><thead><tr>'; 20478 for (var F = S ? '<th class="ui-datepicker-week-col">' + this._get(t, "weekHeader") + "</th>" : "", Q = 0; Q < 7; Q++) { 20479 var B = (Q + C) % 7; 20480 F += "<th" + (5 <= (Q + C + 6) % 7 ? ' class="ui-datepicker-week-end"' : "") + '><span title="' + T[B] + '">' + I[B] + "</span></th>" 20481 } 20482 R += F + "</tr></thead><tbody>"; 20483 var q = this._getDaysInMonth(f, p); 20484 f == t.selectedYear && p == t.selectedMonth && (t.selectedDay = Math.min(t.selectedDay, q)); 20485 var Y = (this._getFirstDayOfMonth(f, p) - C + 7) % 7 20486 , X = Math.ceil((Y + q) / 7) 20487 , V = c && this.maxRows > X ? this.maxRows : X; 20488 this.maxRows = V; 20489 for (var U = this._daylightSavingAdjust(new Date(f,p,1 - Y)), K = 0; K < V; K++) { 20490 R += "<tr>"; 20491 var G = S ? '<td class="ui-datepicker-week-col">' + this._get(t, "calculateWeek")(U) + "</td>" : ""; 20492 for (Q = 0; Q < 7; Q++) { 20493 var Z = M ? M.apply(t.input ? t.input[0] : null, [U]) : [!0, ""] 20494 , J = U.getMonth() != p 20495 , tt = J && !A || !Z[0] || h && U < h || d && d < U; 20496 G += '<td class="' + (5 <= (Q + C + 6) % 7 ? " ui-datepicker-week-end" : "") + (J ? " ui-datepicker-other-month" : "") + (U.getTime() == H.getTime() && p == t.selectedMonth && t._keyEvent || j.getTime() == U.getTime() && j.getTime() == H.getTime() ? " " + this._dayOverClass : "") + (tt ? " " + this._unselectableClass + " ui-state-disabled" : "") + (J && !D ? "" : " " + Z[1] + (U.getTime() == u.getTime() ? " " + this._currentClass : "") + (U.getTime() == e.getTime() ? " ui-datepicker-today" : "")) + '"' + (J && !D || !Z[2] ? "" : ' title="' + Z[2] + '"') + (tt ? "" : ' data-handler="selectDay" data-event="click" data-month="' + U.getMonth() + '" data-year="' + U.getFullYear() + '"') + ">" + (J && !D ? " " : tt ? '<span class="ui-state-default">' + U.getDate() + "</span>" : '<a class="ui-state-default' + (U.getTime() == e.getTime() ? " ui-state-highlight" : "") + (U.getTime() == u.getTime() ? " ui-state-active" : "") + (J ? " ui-priority-secondary" : "") + '" href="#">' + U.getDate() + "</a>") + "</td>", 20497 U.setDate(U.getDate() + 1), 20498 U = this._daylightSavingAdjust(U) 20499 } 20500 R += G + "</tr>" 20501 } 20502 11 < ++p && (p = 0, 20503 f++), 20504 L += R += "</tbody></table>" + (c ? "</div>" + (0 < r[0] && N == r[1] - 1 ? '<div class="ui-datepicker-row-break"></div>' : "") : "") 20505 } 20506 O += L 20507 } 20508 return O += k + ($.browser.msie && parseInt($.browser.version, 10) < 7 && !t.inline ? '<iframe src="javascript:false;" class="ui-datepicker-cover" frameborder="0"></iframe>' : ""), 20509 t._keyEvent = !1, 20510 O 20511 }, 20512 _generateMonthYearHeader: function(t, e, i, n, s, o, r, a) { 20513 var l = this._get(t, "changeMonth") 20514 , c = this._get(t, "changeYear") 20515 , u = this._get(t, "showMonthAfterYear") 20516 , h = '<div class="ui-datepicker-title">' 20517 , d = ""; 20518 if (o || !l) 20519 d += '<span class="ui-datepicker-month">' + r[e] + "</span>"; 20520 else { 20521 var p = n && n.getFullYear() == i 20522 , f = s && s.getFullYear() == i; 20523 d += '<select class="ui-datepicker-month" data-handler="selectMonth" data-event="change">'; 20524 for (var g = 0; g < 12; g++) 20525 (!p || g >= n.getMonth()) && (!f || g <= s.getMonth()) && (d += '<option value="' + g + '"' + (g == e ? ' selected="selected"' : "") + ">" + a[g] + "</option>"); 20526 d += "</select>" 20527 } 20528 if (u || (h += d + (!o && l && c ? "" : " ")), 20529 !t.yearshtml) 20530 if (t.yearshtml = "", 20531 o || !c) 20532 h += '<span class="ui-datepicker-year">' + i + "</span>"; 20533 else { 20534 var m = this._get(t, "yearRange").split(":") 20535 , v = (new Date).getFullYear() 20536 , y = function(t) { 20537 var e = t.match(/c[+-].*/) ? i + parseInt(t.substring(1), 10) : t.match(/[+-].*/) ? v + parseInt(t, 10) : parseInt(t, 10); 20538 return isNaN(e) ? v : e 20539 } 20540 , b = y(m[0]) 20541 , w = Math.max(b, y(m[1] || "")); 20542 for (b = n ? Math.max(b, n.getFullYear()) : b, 20543 w = s ? Math.min(w, s.getFullYear()) : w, 20544 t.yearshtml += '<select class="ui-datepicker-year" data-handler="selectYear" data-event="change">'; b <= w; b++) 20545 t.yearshtml += '<option value="' + b + '"' + (b == i ? ' selected="selected"' : "") + ">" + b + "</option>"; 20546 t.yearshtml += "</select>", 20547 h += t.yearshtml, 20548 t.yearshtml = null 20549 } 20550 return h += this._get(t, "yearSuffix"), 20551 u && (h += (!o && l && c ? "" : " ") + d), 20552 h += "</div>" 20553 }, 20554 _adjustInstDate: function(t, e, i) { 20555 var n = t.drawYear + ("Y" == i ? e : 0) 20556 , s = t.drawMonth + ("M" == i ? e : 0) 20557 , o = Math.min(t.selectedDay, this._getDaysInMonth(n, s)) + ("D" == i ? e : 0) 20558 , r = this._restrictMinMax(t, this._daylightSavingAdjust(new Date(n,s,o))); 20559 t.selectedDay = r.getDate(), 20560 t.drawMonth = t.selectedMonth = r.getMonth(), 20561 t.drawYear = t.selectedYear = r.getFullYear(), 20562 "M" != i && "Y" != i || this._notifyChange(t) 20563 }, 20564 _restrictMinMax: function(t, e) { 20565 var i = this._getMinMaxDate(t, "min") 20566 , n = this._getMinMaxDate(t, "max") 20567 , s = i && e < i ? i : e; 20568 return s = n && n < s ? n : s 20569 }, 20570 _notifyChange: function(t) { 20571 var e = this._get(t, "onChangeMonthYear"); 20572 e && e.apply(t.input ? t.input[0] : null, [t.selectedYear, t.selectedMonth + 1, t]) 20573 }, 20574 _getNumberOfMonths: function(t) { 20575 var e = this._get(t, "numberOfMonths"); 20576 return null == e ? [1, 1] : "number" == typeof e ? [1, e] : e 20577 }, 20578 _getMinMaxDate: function(t, e) { 20579 return this._determineDate(t, this._get(t, e + "Date"), null) 20580 }, 20581 _getDaysInMonth: function(t, e) { 20582 return 32 - this._daylightSavingAdjust(new Date(t,e,32)).getDate() 20583 }, 20584 _getFirstDayOfMonth: function(t, e) { 20585 return new Date(t,e,1).getDay() 20586 }, 20587 _canAdjustMonth: function(t, e, i, n) { 20588 var s = this._getNumberOfMonths(t) 20589 , o = this._daylightSavingAdjust(new Date(i,n + (e < 0 ? e : s[0] *
20589s[1]),1)); 20590 return e < 0 && o.setDate(this._getDaysInMonth(o.getFullYear(), o.getMonth())), 20591 this._isInRange(t, o) 20592 }, 20593 _isInRange: function(t, e) { 20594 var i = this._getMinMaxDate(t, "min") 20595 , n = this._getMinMaxDate(t, "max"); 20596 return (!i || e.getTime() >= i.getTime()) && (!n || e.getTime() <= n.getTime()) 20597 }, 20598 _getFormatConfig: function(t) { 20599 var e = this._get(t, "shortYearCutoff"); 20600 return { 20601 shortYearCutoff: e = "string" != typeof e ? e : (new Date).getFullYear() % 100 + parseInt(e, 10), 20602 dayNamesShort: this._get(t, "dayNamesShort"), 20603 dayNames: this._get(t, "dayNames"), 20604 monthNamesShort: this._get(t, "monthNamesShort"), 20605 monthNames: this._get(t, "monthNames") 20606 } 20607 }, 20608 _formatDate: function(t, e, i, n) { 20609 e || (t.currentDay = t.selectedDay, 20610 t.currentMonth = t.selectedMonth, 20611 t.currentYear = t.selectedYear); 20612 var s = e ? "object" == typeof e ? e : this._daylightSavingAdjust(new Date(n,i,e)) : this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay)); 20613 return this.formatDate(this._get(t, "dateFormat"), s, this._getFormatConfig(t)) 20614 } 20615 }), 20616 $.fn.datepicker = function(t, e) { 20617 if (!this.length) 20618 return this; 20619 $.datepicker.initialized || ($(document).mousedown($.datepicker._checkExternalClick).find(document.body).append($.datepicker.dpDiv), 20620 $.datepicker.initialized = !0); 20621 var i = Array.prototype.slice.call(arguments, 1); 20622 return "string" != typeof t || "isDisabled" != t && "getDate" != t && "widget" != t ? "option" == t && 2 == arguments.length && "string" == typeof e ? $.datepicker["_" + t + "Datepicker"].apply($.datepicker, [this[0]].concat(i)) : this.each(function() { 20623 "string" == typeof t ? $.datepicker["_" + t + "Datepicker"].apply($.datepicker, [this].concat(i)) : $.datepicker._attachDatepicker(this, t) 20624 }) : $.datepicker["_" + t + "Datepicker"].apply($.datepicker, [this[0]].concat(i)) 20625 } 20626 , 20627 $.datepicker = new Datepicker, 20628 $.datepicker.initialized = !1, 20629 $.datepicker.uuid = (new Date).getTime(), 20630 $.datepicker.version = "1.9.0", 20631 window["DP_jQuery_" + dpuuid] = $ 20632}(jQuery), 20633function(l) { 20634 var c = "ui-dialog ui-widget ui-widget-content ui-corner-all " 20635 , o = { 20636 buttons: !0, 20637 height: !0, 20638 maxHeight: !0, 20639 maxWidth: !0, 20640 minHeight: !0, 20641 minWidth: !0, 20642 width: !0 20643 } 20644 , r = { 20645 maxHeight: !0, 20646 maxWidth: !0, 20647 minHeight: !0, 20648 minWidth: !0 20649 }; 20650 l.widget("ui.dialog", { 20651 version: "1.9.0", 20652 options: { 20653 autoOpen: !0, 20654 buttons: {}, 20655 closeOnEscape: !0, 20656 closeText: "close", 20657 dialogClass: "", 20658 draggable: !0, 20659 hide: null, 20660 height: "auto", 20661 maxHeight: !1, 20662 maxWidth: !1, 20663 minHeight: 150, 20664 minWidth: 150, 20665 modal: !1, 20666 position: { 20667 my: "center", 20668 at: "center", 20669 of: window, 20670 collision: "fit", 20671 using: function(t) { 20672 var e = l(this).css(t).offset().top; 20673 e < 0 && l(this).css("top", t.top - e) 20674 } 20675 }, 20676 resizable: !0, 20677 show: null, 20678 stack: !0, 20679 title: "", 20680 width: 300, 20681 zIndex: 1e3 20682 }, 20683 _create: function() { 20684 this.originalTitle = this.element.attr("title"), 20685 "string" != typeof this.originalTitle && (this.originalTitle = ""), 20686 this.oldPosition = { 20687 parent: this.element.parent(), 20688 index: this.element.parent().children().index(this.element) 20689 }, 20690 this.options.title = this.options.title || this.originalTitle; 20691 var e = this 20692 , s = this.options 20693 , t = s.title || " " 20694 , o = (this.uiDialog = l("<div>")).addClass(c + s.dialogClass).css({ 20695 display: "none", 20696 outline: 0, 20697 zIndex: s.zIndex 20698 }).attr("tabIndex", -1).keydown(function(t) { 20699 s.closeOnEscape && !t.isDefaultPrevented() && t.keyCode && t.keyCode === l.ui.keyCode.ESCAPE && (e.close(t), 20700 t.preventDefault()) 20701 }).mousedown(function(t) { 20702 e.moveToTop(!1, t) 20703 }).appendTo("body") 20704 , i = (this.element.show().removeAttr("title").addClass("ui-dialog-content ui-widget-content").appendTo(o), 20705 (this.uiDialogTitlebar = l("<div>")).addClass("ui-dialog-titlebar ui-widget-header ui-corner-all ui-helper-clearfix").prependTo(o)) 20706 , n = l("<a href='#'></a>").addClass("ui-dialog-titlebar-close ui-corner-all").attr("role", "button").click(function(t) { 20707 t.preventDefault(), 20708 e.close(t) 20709 }).appendTo(i) 20710 , r = ((this.uiDialogTitlebarCloseText = l("<span>")).addClass("ui-icon ui-icon-closethick").text(s.closeText).appendTo(n), 20711 l("<span>").uniqueId().addClass("ui-dialog-title").html(t).prependTo(i)) 20712 , a = (this.uiDialogButtonPane = l("<div>")).addClass("ui-dialog-buttonpane ui-widget-content ui-helper-clearfix"); 20713 (this.uiButtonSet = l("<div>")).addClass("ui-dialog-buttonset").appendTo(a); 20714 o.attr({ 20715 role: "dialog", 20716 "aria-labelledby": r.attr("id") 20717 }), 20718 i.find("*").add(i).disableSelection(), 20719 this._hoverable(n), 20720 this._focusable(n), 20721 s.draggable && l.fn.draggable && this._makeDraggable(), 20722 s.resizable && l.fn.resizable && this._makeResizable(), 20723 this._createButtons(s.buttons), 20724 this._isOpen = !1, 20725 l.fn.bgiframe && o.bgiframe(), 20726 this._on(o, { 20727 keydown: function(t) { 20728 if (s.modal && t.keyCode === l.ui.keyCode.TAB) { 20729 var e = l(":tabbable", o) 20730 , i = e.filter(":first") 20731 , n = e.filter(":last"); 20732 return t.target !== n[0] || t.shiftKey ? t.target === i[0] && t.shiftKey ? (n.focus(1), 20733 !1) : void 0 : (i.focus(1), 20734 !1) 20735 } 20736 } 20737 }) 20738 }, 20739 _init: function() { 20740 this.options.autoOpen && this.open() 20741 }, 20742 _destroy: function() { 20743 var t, e = this.oldPosition; 20744 this.overlay && this.overlay.destroy(), 20745 this.uiDialog.hide(), 20746 this.element.removeClass("ui-dialog-content ui-widget-content").hide().appendTo("body"), 20747 this.uiDialog.remove(), 20748 this.originalTitle && this.element.attr("title", this.originalTitle), 20749 (t = e.parent.children().eq(e.index)).length && t[0] !== this.element[0] ? t.before(this.element) : e.parent.append(this.element) 20750 }, 20751 widget: function() { 20752 return this.uiDialog 20753 }, 20754 close: function(t) { 20755 var e, i, n = this; 20756 if (this._isOpen && !1 !== this._trigger("beforeClose", t)) 20757 return this._isOpen = !1, 20758 this.overlay && this.overlay.destroy(), 20759 this.options.hide ? this.uiDialog.hide(this.options.hide, function() { 20760 n._trigger("close", t) 20761 }) : (this.uiDialog.hide(), 20762 this._trigger("close", t)), 20763 l.ui.dialog.overlay.resize(), 20764 this.options.modal && (e = 0, 20765 l(".ui-dialog").each(function() { 20766 this !== n.uiDialog[0] && (i = l(this).css("z-index"), 20767 isNaN(i) || (e = Math.max(e, i))) 20768 }), 20769 l.ui.dialog.maxZ = e), 20770 this 20771 }, 20772 isOpen: function() { 20773 return this._isOpen 20774 }, 20775 moveToTop: function(t, e) { 20776 var i, n = this.options; 20777 return n.modal && !t || !n.stack && !n.modal ? this._trigger("focus", e) : (n.zIndex > l.ui.dialog.maxZ && (l.ui.dialog.maxZ = n.zIndex), 20778 this.overlay && (l.ui.dialog.maxZ += 1, 20779 l.ui.dialog.overlay.maxZ = l.ui.dialog.maxZ, 20780 this.overlay.$el.css("z-index", l.ui.dialog.overlay.maxZ)), 20781 i = { 20782 scrollTop: this.element.scrollTop(), 20783 scrollLeft: this.element.scrollLeft() 20784 }, 20785 l.ui.dialog.maxZ += 1, 20786 this.uiDialog.css("z-index", l.ui.dialog.maxZ), 20787 this.element.attr(i), 20788 this._trigger("focus", e), 20789 this) 20790 }, 20791 open: function() { 20792 if (!this._isOpen) { 20793 var t, e = this.options, i = this.uiDialog; 20794 return this._size(), 20795 this._position(e.position), 20796 i.show(e.show),
20797 this.overlay = e.modal ? new l.ui.dialog.overlay(this) : null, 20798 this.moveToTop(!0), 20799 (t = this.element.find(":tabbable")).length || (t = this.uiDialogButtonPane.find(":tabbable")).length || (t = i), 20800 t.eq(0).focus(), 20801 this._isOpen = !0, 20802 this._trigger("open"), 20803 this 20804 } 20805 }, 20806 _createButtons: function(t) { 20807 var n = this 20808 , e = !1; 20809 this.uiDialogButtonPane.remove(), 20810 this.uiButtonSet.empty(), 20811 "object" == typeof t && null !== t && l.each(t, function() { 20812 return !(e = !0) 20813 }), 20814 e ? (l.each(t, function(t, e) { 20815 e = l.isFunction(e) ? { 20816 click: e, 20817 text: t 20818 } : e; 20819 var i = l("<button type='button'>").attr(e, !0).unbind("click").click(function() { 20820 e.click.apply(n.element[0], arguments) 20821 }).appendTo(n.uiButtonSet); 20822 l.fn.button && i.button() 20823 }), 20824 this.uiDialog.addClass("ui-dialog-buttons"), 20825 this.uiDialogButtonPane.appendTo(this.uiDialog)) : this.uiDialog.removeClass("ui-dialog-buttons") 20826 }, 20827 _makeDraggable: function() { 20828 function i(t) { 20829 return { 20830 position: t.position, 20831 offset: t.offset 20832 } 20833 } 20834 var n = this 20835 , s = this.options; 20836 this.uiDialog.draggable({ 20837 cancel: ".ui-dialog-content, .ui-dialog-titlebar-close", 20838 handle: ".ui-dialog-titlebar", 20839 containment: "document", 20840 start: function(t, e) { 20841 l(this).addClass("ui-dialog-dragging"), 20842 n._trigger("dragStart", t, i(e)) 20843 }, 20844 drag: function(t, e) { 20845 n._trigger("drag", t, i(e)) 20846 }, 20847 stop: function(t, e) { 20848 s.position = [e.position.left - n.document.scrollLeft(), e.position.top - n.document.scrollTop()], 20849 l(this).removeClass("ui-dialog-dragging"), 20850 n._trigger("dragStop", t, i(e)), 20851 l.ui.dialog.overlay.resize() 20852 } 20853 }) 20854 }, 20855 _makeResizable: function(t) { 20856 function i(t) { 20857 return { 20858 originalPosition: t.originalPosition, 20859 originalSize: t.originalSize, 20860 position: t.position, 20861 size: t.size 20862 } 20863 } 20864 t = void 0 === t ? this.options.resizable : t; 20865 var n = this 20866 , s = this.options 20867 , e = this.uiDialog.css("position") 20868 , o = "string" == typeof t ? t : "n,e,s,w,se,sw,ne,nw"; 20869 this.uiDialog.resizable({ 20870 cancel: ".ui-dialog-content", 20871 containment: "document", 20872 alsoResize: this.element, 20873 maxWidth: s.maxWidth, 20874 maxHeight: s.maxHeight, 20875 minWidth: s.minWidth, 20876 minHeight: this._minHeight(), 20877 handles: o, 20878 start: function(t, e) { 20879 l(this).addClass("ui-dialog-resizing"), 20880 n._trigger("resizeStart", t, i(e)) 20881 }, 20882 resize: function(t, e) { 20883 n._trigger("resize", t, i(e)) 20884 }, 20885 stop: function(t, e) { 20886 l(this).removeClass("ui-dialog-resizing"), 20887 s.height = l(this).height(), 20888 s.width = l(this).width(), 20889 n._trigger("resizeStop", t, i(e)), 20890 l.ui.dialog.overlay.resize() 20891 } 20892 }).css("position", e).find(".ui-resizable-se").addClass("ui-icon ui-icon-grip-diagonal-se") 20893 }, 20894 _minHeight: function() { 20895 var t = this.options; 20896 return "auto" === t.height ? t.minHeight : Math.min(t.minHeight, t.height) 20897 }, 20898 _position: function(t) { 20899 var e, i = [], n = [0, 0]; 20900 t ? (("string" == typeof t || "object" == typeof t && "0"in t) && (1 === (i = t.split ? t.split(" ") : [t[0], t[1]]).length && (i[1] = i[0]), 20901 l.each(["left", "top"], function(t, e) { 20902 +i[t] === i[t] && (n[t] = i[t], 20903 i[t] = e) 20904 }), 20905 t = { 20906 my: i.join(" "), 20907 at: i.join(" "), 20908 offset: n.join(" ") 20909 }), 20910 t = l.extend({}, l.ui.dialog.prototype.options.position, t)) : t = l.ui.dialog.prototype.options.position, 20911 (e = this.uiDialog.is(":visible")) || this.uiDialog.show(), 20912 this.uiDialog.position(t), 20913 e || this.uiDialog.hide() 20914 }, 20915 _setOptions: function(t) { 20916 var i = this 20917 , n = {} 20918 , s = !1; 20919 l.each(t, function(t, e) { 20920 i._setOption(t, e), 20921 t in o && (s = !0), 20922 t in r && (n[t] = e) 20923 }), 20924 s && this._size(), 20925 this.uiDialog.is(":data(resizable)") && this.uiDialog.resizable("option", n) 20926 }, 20927 _setOption: function(t, e) { 20928 var i, n, s = this.uiDialog; 20929 switch (t) { 20930 case "buttons": 20931 this._createButtons(e); 20932 break; 20933 case "closeText": 20934 this.uiDialogTitlebarCloseText.text("" + e); 20935 break; 20936 case "dialogClass": 20937 s.removeClass(this.options.dialogClass).addClass(c + e); 20938 break; 20939 case "disabled": 20940 e ? s.addClass("ui-dialog-disabled") : s.removeClass("ui-dialog-disabled"); 20941 break; 20942 case "draggable": 20943 (i = s.is(":data(draggable)")) && !e && s.draggable("destroy"), 20944 !i && e && this._makeDraggable(); 20945 break; 20946 case "position": 20947 this._position(e); 20948 break; 20949 case "resizable": 20950 (n = s.is(":data(resizable)")) && !e && s.resizable("destroy"), 20951 n && "string" == typeof e && s.resizable("option", "handles", e), 20952 n || !1 === e || this._makeResizable(e); 20953 break; 20954 case "title": 20955 l(".ui-dialog-title", this.uiDialogTitlebar).html("" + (e || " ")) 20956 } 20957 this._super(t, e) 20958 }, 20959 _size: function() { 20960 var t, e, i, n = this.options, s = this.uiDialog.is(":visible"); 20961 this.element.show().css({ 20962 width: "auto", 20963 minHeight: 0, 20964 height: 0 20965 }), 20966 n.minWidth > n.width && (n.width = n.minWidth), 20967 t = this.uiDialog.css({ 20968 height: "auto", 20969 width: n.width 20970 }).outerHeight(), 20971 e = Math.max(0, n.minHeight - t), 20972 "auto" === n.height ? l.support.minHeight ? this.element.css({ 20973 minHeight: e, 20974 height: "auto" 20975 }) : (this.uiDialog.show(), 20976 i = this.element.css("height", "auto").height(), 20977 s || this.uiDialog.hide(), 20978 this.element.height(Math.max(i, e))) : this.element.height(Math.max(n.height - t, 0)), 20979 this.uiDialog.is(":data(resizable)") && this.uiDialog.resizable("option", "minHeight", this._minHeight()) 20980 } 20981 }), 20982 l.extend(l.ui.dialog, { 20983 uuid: 0, 20984 maxZ: 0, 20985 getTitleId: function(t) { 20986 var e = t.attr("id"); 20987 return e || (this.uuid += 1, 20988 e = this.uuid), 20989 "ui-dialog-title-" + e 20990 }, 20991 overlay: function(t) { 20992 this.$el = l.ui.dialog.overlay.create(t) 20993 } 20994 }), 20995 l.extend(l.ui.dialog.overlay, { 20996 instances: [], 20997 oldInstances: [], 20998 maxZ: 0, 20999 events: l.map("focus,mousedown,mouseup,keydown,keypress,click".split(","), function(t) { 21000 return t + ".dialog-overlay" 21001 }).join(" "), 21002 create: function(i) { 21003 0 === this.instances.length && (setTimeout(function() { 21004 l.ui.dialog.overlay.instances.length && l(document).bind(l.ui.dialog.overlay.events, function(t) { 21005 if (l(t.target).zIndex() < l.ui.dialog.overlay.maxZ) 21006 return !1 21007 }) 21008 }, 1), 21009 l(window).bind("resize.dialog-overlay", l.ui.dialog.overlay.resize)); 21010 var n = this.oldInstances.pop() || l("<div>").addClass("ui-widget-overlay"); 21011 return l(document).bind("keydown.dialog-overlay", function(t) { 21012 var e = l.ui.dialog.overlay.instances; 21013 0 !== e.length && e[e.length - 1] === n && i.options.closeOnEscape && !t.isDefaultPrevented() && t.keyCode && t.keyCode === l.ui.keyCode.ESCAPE && (i.close(t), 21014 t.preventDefault()) 21015 }), 21016 n.appendTo(document.body).css({ 21017 width: this.width(), 21018 height: this.height() 21019 }), 21020 l.fn.bgiframe && n.bgiframe(), 21021 this.instances.push(n), 21022 n 21023 }, 21024 destroy: function(t) { 21025 var e = l.inArray(t, this.instances) 21026 , i = 0; 21027 -1 !== e && this.oldInstances.push(this.instances.splice(e, 1)[0]), 21028 0 === this.instances.length && l([document, window]).unbind(".dialog-overlay"), 21029 t.height(0).width(0).remove(), 21030 l.each(this.instances, function() { 21031 i = Math.max(i, this.css("z-index")) 21032 }), 21033 this.maxZ = i 21034 }, 21035 height: function() { 21036 var t; 21037 return l.browser.msie ? (t = Math.max(document.documentElement.scrollHeight, document.body.scrollHeight)) < Math.max(document.documentElement.offsetHeight, document.body.offsetHeight) ? l(window).height() + "px" : t + "px" : l(document).height() + "px" 21038 }, 21039 width: function() { 21040 var t; 21041 return l.browser.msie ? (t = Math.max(document.documentElement.scrollWidth, document.body.scrollWidth)) < Math.max(document.documentElement.offsetWidth, document.body.offsetWidth) ? l(window).width() + "px" : t + "px" : l(document).width() + "px" 21042 }, 21043 resize: function() { 21044 var t = l([]); 21045 l.each(l.ui.dialog.overlay.instances, function() { 21046 t = t.add(this) 21047 }), 21048 t.css({ 21049 width: 0, 21050 height: 0 21051 }).css({ 21052 width: l.ui.dialog.overlay.width(), 21053 height: l.ui.dialog.overlay.height() 21054 }) 21055 } 21056 }), 21057 l.extend(l.ui.dialog.overlay.prototype, { 21058 destroy: function() { 21059 l.ui.dialog.overlay.destroy(this.$el) 21060 } 21061 }) 21062}(jQuery), 21063function(g) { 21064 var m = /up|down|vertical/ 21065 , v = /up|left|vertical|horizontal/; 21066 g.effects.effect.blind = function(t, e) { 21067 var i, n, s, o = g(this), r = ["position", "top", "bottom", "left", "right", "height", "width"], a = g.effects.setMode(o, t.mode || "hide"), l = t.direction || "up", c = m.test(l), u = c ? "height" : "width", h = c ? "top" : "left", d = v.test(l), p = {}, f = "show" === a; 21068 o.parent().is(".ui-effects-wrapper") ? g.effects.save(o.parent(), r)
21068: g.effects.save(o, r), 21069 o.show(), 21070 n = (i = g.effects.createWrapper(o).css({ 21071 overflow: "hidden" 21072 }))[u](), 21073 s = parseFloat(i.css(h)) || 0, 21074 p[u] = f ? n : 0, 21075 d || (o.css(c ? "bottom" : "right", 0).css(c ? "top" : "left", "auto").css({ 21076 position: "absolute" 21077 }), 21078 p[h] = f ? s : n + s), 21079 f && (i.css(u, 0), 21080 d || i.css(h, s + n)), 21081 i.animate(p, { 21082 duration: t.duration, 21083 easing: t.easing, 21084 queue: !1, 21085 complete: function() { 21086 "hide" === a && o.hide(), 21087 g.effects.restore(o, r), 21088 g.effects.removeWrapper(o), 21089 e() 21090 } 21091 }) 21092 } 21093}(jQuery), 21094function(w) { 21095 w.effects.effect.bounce = function(t, e) { 21096 var i, n, s, o = w(this), r = ["position", "top", "bottom", "left", "right", "height", "width"], a = w.effects.setMode(o, t.mode || "effect"), l = "hide" === a, c = "show" === a, u = t.direction || "up", h = t.distance, d = t.times || 5, p = 2 * d + (c || l ? 1 : 0), f = t.duration / p, g = t.easing, m = "up" === u || "down" === u ? "top" : "left", v = "up" === u || "left" === u, y = o.queue(), b = y.length; 21097 for ((c || l) && r.push("opacity"), 21098 w.effects.save(o, r), 21099 o.show(), 21100 w.effects.createWrapper(o), 21101 h || (h = o["top" === m ? "outerHeight" : "outerWidth"]() / 3), 21102 c && ((s = { 21103 opacity: 1 21104 })[m] = 0, 21105 o.css("opacity", 0).css(m, v ? 2 * -h : 2 * h).animate(s, f, g)), 21106 l && (h /= Math.pow(2, d - 1)), 21107 i = (s = {})[m] = 0; i < d; i++) 21108 (n = {})[m] = (v ? "-=" : "+=") + h, 21109 o.animate(n, f, g).animate(s, f, g), 21110 h = l ? 2 * h : h / 2; 21111 l && ((n = { 21112 opacity: 0 21113 })[m] = (v ? "-=" : "+=") + h, 21114 o.animate(n, f, g)), 21115 o.queue(function() { 21116 l && o.hide(), 21117 w.effects.restore(o, r), 21118 w.effects.removeWrapper(o), 21119 e() 21120 }), 21121 1 < b && y.splice.apply(y, [1, 0].concat(y.splice(b, p + 1))), 21122 o.dequeue() 21123 } 21124}(jQuery), 21125function(d) { 21126 d.effects.effect.clip = function(t, e) { 21127 var i, n, s, o = d(this), r = ["position", "top", "bottom", "left", "right", "height", "width"], a = "show" === d.effects.setMode(o, t.mode || "hide"), l = "vertical" === (t.direction || "vertical"), c = l ? "height" : "width", u = l ? "top" : "left", h = {}; 21128 d.effects.save(o, r), 21129 o.show(), 21130 i = d.effects.createWrapper(o).css({ 21131 overflow: "hidden" 21132 }), 21133 s = (n = "IMG" === o[0].tagName ? i : o)[c](), 21134 a && (n.css(c, 0), 21135 n.css(u, s / 2)), 21136 h[c] = a ? s : 0, 21137 h[u] = a ? 0 : s / 2, 21138 n.animate(h, { 21139 queue: !1, 21140 duration: t.duration, 21141 easing: t.easing, 21142 complete: function() { 21143 a || o.hide(), 21144 d.effects.restore(o, r), 21145 d.effects.removeWrapper(o), 21146 e() 21147 } 21148 }) 21149 } 21150}(jQuery), 21151function(h) { 21152 h.effects.effect.drop = function(t, e) { 21153 var i, n = h(this), s = ["position", "top", "bottom", "left", "right", "opacity", "height", "width"], o = h.effects.setMode(n, t.mode || "hide"), r = "show" === o, a = t.direction || "left", l = "up" === a || "down" === a ? "top" : "left", c = "up" === a || "left" === a ? "pos" : "neg", u = { 21154 opacity: r ? 1 : 0 21155 }; 21156 h.effects.save(n, s), 21157 n.show(), 21158 h.effects.createWrapper(n), 21159 i = t.distance || n["top" === l ? "outerHeight" : "outerWidth"](!0) / 2, 21160 r && n.css("opacity", 0).css(l, "pos" === c ? -i : i), 21161 u[l] = (r ? "pos" === c ? "+=" : "-=" : "pos" === c ? "-=" : "+=") + i, 21162 n.animate(u, { 21163 queue: !1, 21164 duration: t.duration, 21165 easing: t.easing, 21166 complete: function() { 21167 "hide" === o && n.hide(), 21168 h.effects.restore(n, s), 21169 h.effects.removeWrapper(n), 21170 e() 21171 } 21172 }) 21173 } 21174}(jQuery), 21175function(v) { 21176 v.effects.effect.explode = function(t, e) { 21177 function i() { 21178 m.push(this), 21179 m.length === c * u && function() { 21180 h.css({ 21181 visibility: "visible" 21182 }), 21183 v(m).remove(), 21184 d || h.hide(); 21185 e() 21186 }() 21187 } 21188 var n, s, o, r, a, l, c = t.pieces ? Math.round(Math.sqrt(t.pieces)) : 3, u = c, h = v(this), d = "show" === v.effects.setMode(h, t.mode || "hide"), p = h.show().css("visibility", "hidden").offset(), f = Math.
vendor: 23,570 bytes, lines 21188-21835
21188ceil(h.outerWidth() / u), g = Math.ceil(h.outerHeight() / c), m = []; 21189 for (n = 0; n < c; n++) 21190 for (r = p.top + n * g, 21191 l = n - (c - 1) / 2, 21192 s = 0; s < u; s++) 21193 o = p.left + s * f, 21194 a = s - (u - 1) / 2, 21195 h.clone().appendTo("body").wrap("<div></div>").css({ 21196 position: "absolute", 21197 visibility: "visible", 21198 left: -s * f, 21199 top: -n * g 21200 }).parent().addClass("ui-effects-explode").css({ 21201 position: "absolute", 21202 overflow: "hidden", 21203 width: f, 21204 height: g, 21205 left: o + (d ? a * f : 0), 21206 top: r + (d ? l * g : 0), 21207 opacity: d ? 0 : 1 21208 }).animate({ 21209 left: o + (d ? 0 : a * f), 21210 top: r + (d ? 0 : l * g), 21211 opacity: d ? 1 : 0 21212 }, t.duration || 500, t.easing, i) 21213 } 21214}(jQuery), 21215function(s) { 21216 s.effects.effect.fade = function(t, e) { 21217 var i = s(this) 21218 , n = s.effects.setMode(i, t.mode || "toggle"); 21219 i.animate({ 21220 opacity: n 21221 }, { 21222 queue: !1, 21223 duration: t.duration, 21224 easing: t.easing, 21225 complete: e 21226 }) 21227 } 21228}(jQuery), 21229function(v) { 21230 v.effects.effect.fold = function(t, e) { 21231 var i, n, s = v(this), o = ["position", "top", "bottom", "left", "right", "height", "width"], r = v.effects.setMode(s, t.mode || "hide"), a = "show" === r, l = "hide" === r, c = t.size || 15, u = /([0-9]+)%/.exec(c), h = !!t.horizFirst, d = a !== h, p = d ? ["width", "height"] : ["height", "width"], f = t.duration / 2, g = {}, m = {}; 21232 v.effects.save(s, o), 21233 s.show(), 21234 i = v.effects.createWrapper(s).css({ 21235 overflow: "hidden" 21236 }), 21237 n = d ? [i.width(), i.height()] : [i.height(), i.width()], 21238 u && (c = parseInt(u[1], 10) / 100 * n[l ? 0 : 1]), 21239 a && i.css(h ? { 21240 height: 0, 21241 width: c 21242 } : { 21243 height: c, 21244 width: 0 21245 }), 21246 g[p[0]] = a ? n[0] : c, 21247 m[p[1]] = a ? n[1] : 0, 21248 i.animate(g, f, t.easing).animate(m, f, t.easing, function() { 21249 l && s.hide(), 21250 v.effects.restore(s, o), 21251 v.effects.removeWrapper(s), 21252 e() 21253 }) 21254 } 21255}(jQuery), 21256function(r) { 21257 r.effects.effect.highlight = function(t, e) { 21258 var i = r(this) 21259 , n = ["backgroundImage", "backgroundColor", "opacity"] 21260 , s = r.effects.setMode(i, t.mode || "show") 21261 , o = { 21262 backgroundColor: i.css("backgroundColor") 21263 }; 21264 "hide" === s && (o.opacity = 0), 21265 r.effects.save(i, n), 21266 i.show().css({ 21267 backgroundImage: "none", 21268 backgroundColor: t.color || "#ffff99" 21269 }).animate(o, { 21270 queue: !1, 21271 duration: t.duration, 21272 easing: t.easing, 21273 complete: function() { 21274 "hide" === s && i.hide(), 21275 r.effects.restore(i, n), 21276 e() 21277 } 21278 }) 21279 } 21280}(jQuery), 21281function(p) { 21282 p.effects.effect.pulsate = function(t, e) { 21283 var i, n = p(this), s = p.effects.setMode(n, t.mode || "show"), o = "show" === s, r = "hide" === s, a = o || "hide" === s, l = 2 * (t.times || 5) + (a ? 1 : 0), c = t.duration / l, u = 0, h = n.queue(), d = h.length; 21284 for (!o && n.is(":visible") || (n.css("opacity", 0).show(), 21285 u = 1), 21286 i = 1; i < l; i++) 21287 n.animate({ 21288 opacity: u 21289 }, c, t.easing), 21290 u = 1 - u; 21291 n.animate({ 21292 opacity: u 21293 }, c, t.easing), 21294 n.queue(function() { 21295 r && n.hide(), 21296 e() 21297 }), 21298 1 < d && h.splice.apply(h, [1, 0].concat(h.splice(d, l + 1))), 21299 n.dequeue() 21300 } 21301}(jQuery), 21302function(v) { 21303 v.effects.effect.puff = function(t, e) { 21304 var i = v(this) 21305 , n = v.effects.setMode(i, t.mode || "hide") 21306 , s = "hide" === n 21307 , o = parseInt(t.percent, 10) || 150 21308 , r = o / 100 21309 , a = { 21310 height: i.height(), 21311 width: i.width() 21312 }; 21313 v.extend(t, { 21314 effect: "scale", 21315 queue: !1, 21316 fade: !0, 21317 mode: n, 21318 complete: e, 21319 percent: s ? o : 100, 21320 from: s ? a : { 21321 height: a.height * r, 21322 width: a.width * r 21323 } 21324 }), 21325 i.effect(t) 21326 } 21327 , 21328 v.effects.effect.scale = function(t, e) { 21329 var i = v(this) 21330 , n = v.extend(!0, {}, t) 21331 , s = v.effects.setMode(i, t.mode || "effect") 21332 , o = parseInt(t.percent, 10) || (0 === parseInt(t.percent, 10) ? 0 : "hide" === s ? 0 : 100) 21333 , r = t.direction || "both" 21334 , a = t.origin 21335 , l = { 21336 height: i.height(), 21337 width: i.width(), 21338 outerHeight: i.outerHeight(), 21339 outerWidth: i.outerWidth() 21340 } 21341 , c = "horizontal" !== r ? o / 100 : 1 21342 , u = "vertical" !== r ? o / 100 : 1; 21343 n.effect = "size", 21344 n.queue = !1, 21345 n.complete = e, 21346 "effect" !== s && (n.origin = a || ["middle", "center"], 21347 n.restore = !0), 21348 n.from = t.from || ("show" === s ? { 21349 height: 0, 21350 width: 0 21351 } : l), 21352 n.to = { 21353 height: l.height * c, 21354 width: l.width * u, 21355 outerHeight: l.outerHeight * c, 21356 outerWidth: l.outerWidth * u 21357 }, 21358 n.fade && ("show" === s && (n.from.opacity = 0, 21359 n.to.opacity = 1), 21360 "hide" === s && (n.from.opacity = 1, 21361 n.to.opacity = 0)), 21362 i.effect(n) 21363 } 21364 , 21365 v.effects.effect.size = function(n, t) { 21366 var e, i, s, o = v(this), r = ["position", "top", "bottom", "left", "right", "width", "height", "overflow", "opacity"], a = ["position", "top", "bottom", "left", "right", "overflow", "opacity"], l = ["width", "height", "overflow"], c = ["fontSize"], u = ["borderTopWidth", "borderBottomWidth", "paddingTop", "paddingBottom"], h = ["borderLeftWidth", "borderRightWidth", "paddingLeft", "paddingRight"], d = v.effects.setMode(o, n.mode || "effect"), p = n.restore || "effect" !== d, f = n.scale || "both", g = n.origin || ["middle", "center"], m = o.css("position"); 21367 "show" === d && o.show(), 21368 e = { 21369 height: o.height(), 21370 width: o.width(), 21371 outerHeight: o.outerHeight(), 21372 outerWidth: o.outerWidth() 21373 }, 21374 o.from = n.from || e, 21375 o.to = n.to || e, 21376 s = { 21377 from: { 21378 y: o.from.height / e.height, 21379 x: o.from.width / e.width 21380 }, 21381 to: { 21382 y: o.to.height / e.height, 21383 x: o.to.width / e.width 21384 } 21385 }, 21386 "box" !== f && "both" !== f || (s.from.y !== s.to.y && (r = r.concat(u), 21387 o.from = v.effects.setTransition(o, u, s.from.y, o.from), 21388 o.to = v.effects.setTransition(o, u, s.to.y, o.to)), 21389 s.from.x !== s.to.x && (r = r.concat(h), 21390 o.from = v.effects.setTransition(o, h, s.from.x, o.from), 21391 o.to = v.effects.setTransition(o, h, s.to.x, o.to))), 21392 "content" !== f && "both" !== f || s.from.y !== s.to.y && (r = r.concat(c), 21393 o.from = v.effects.setTransition(o, c, s.from.y, o.from), 21394 o.to = v.effects.setTransition(o, c, s.to.y, o.to)), 21395 v.effects.save(o, p ? r : a), 21396 o.show(), 21397 v.effects.createWrapper(o), 21398 o.css("overflow", "hidden").css(o.from), 21399 g && (i = v.effects.getBaseline(g, e), 21400 o.from.top = (e.outerHeight - o.outerHeight()) * i.y, 21401 o.from.left = (e.outerWidth - o.outerWidth()) * i.x, 21402 o.to.top = (e.outerHeight - o.to.outerHeight) * i.y, 21403 o.to.left = (e.outerWidth - o.to.outerWidth) * i.x), 21404 o.css(o.from), 21405 "content" !== f && "both" !== f || (u = u.concat(["marginTop", "marginBottom"]).concat(c), 21406 h = h.concat(["marginLeft", "marginRight"]), 21407 l = r.concat(u).concat(h), 21408 o.find("*[width]").each(function() { 21409 var t = v(this) 21410 , e = t.height() 21411 , i = t.width(); 21412 p && v.effects.save(t, l), 21413 t.from = { 21414 height: e * s.from.y, 21415 width: i * s.from.x 21416 }, 21417 t.to = { 21418 height: e * s.to.y, 21419 width: i * s.to.x 21420 }, 21421 s.from.y !== s.to.y && (t.from = v.effects.setTransition(t, u, s.from.y, t.from), 21422 t.to = v.effects.setTransition(t, u, s.to.y, t.to)), 21423 s.from.x !== s.to.x && (t.from = v.effects.setTransition(t, h, s.from.x, t.from), 21424 t.to = v.effects.setTransition(t, h, s.to.x, t.to)), 21425 t.css(t.from), 21426 t.animate(t.to, n.duration, n.easing, function() { 21427 p && v.effects.restore(t, l) 21428 }) 21429 })), 21430 o.animate(o.to, { 21431 queue: !1, 21432 duration: n.duration, 21433 easing: n.easing, 21434 complete: function() { 21435 0 === o.to.opacity && o.css("opacity", o.from.opacity), 21436 "hide" === d && o.hide(), 21437 v.effects.restore(o, p ? r : a), 21438 p || ("static" === m ? o.css({ 21439 position: "relative", 21440 top: o.to.top, 21441 left: o.to.left 21442 }) : v.each(["top", "left"], function(s, t) { 21443 o.css(t, function(t, e) { 21444 var i = parseInt(e, 10) 21445 , n = s ? o.to.left : o.to.top; 21446 return "auto" === e ? n + "px" : i + n + "px" 21447 }) 21448 })), 21449 v.effects.removeWrapper(o), 21450 t() 21451 } 21452 }) 21453 } 21454}(jQuery), 21455function(y) { 21456 y.effects.effect.shake = function(t, e) { 21457 var i, n = y(this), s = ["position", "top", "bottom", "left", "right", "height", "width"], o = y.effects.setMode(n, t.mode || "effect"), r = t.direction || "left", a = t.distance || 20, l = t.times || 3, c = 2 * l + 1, u = Math.round(t.duration / c), h = "up" === r || "down" === r ? "top" : "left", d = "up" === r || "left" === r, p = {}, f = {}, g = {}, m = n.queue(), v = m.length; 21458 for (y.effects.save(n, s), 21459 n.show(), 21460 y.effects.createWrapper(n), 21461 p[h] = (d ? "-=" : "+=") + a, 21462 f[h] = (d ? "+=" : "-=") + 2 * a, 21463 g[h] = (d ? "-=" : "+=") + 2 * a, 21464 n.animate(p, u, t.easing), 21465 i = 1; i < l; i++) 21466 n.animate(f, u, t.easing).animate(g, u, t.easing); 21467 n.animate(f, u, t.easing).animate(p, u / 2, t.easing).queue(function() { 21468 "hide" === o && n.hide(), 21469 y.effects.restore(n, s), 21470 y.effects.removeWrapper(n), 21471 e() 21472 }), 21473 1 < v && m.splice.apply(m, [1, 0].concat(m.splice(v, c + 1))), 21474 n.dequeue() 21475 } 21476}(jQuery), 21477function(h) { 21478 h.effects.effect.slide = function(t, e) { 21479 var i, n = h(this), s = ["position", "top", "bottom", "left", "right", "width", "height"], o = h.effects.setMode(n, t.mode || "show"), r = "show" === o, a = t.direction || "left", l = "up" === a || "down" === a ? "top" : "left", c = "up" === a || "left" === a, u = {}; 21480 h.effects.save(n, s), 21481 n.show(), 21482 i = t.distance || n["top" === l ? "outerHeight" : "outerWidth"](!0), 21483 h.effects.createWrapper(n).css({ 21484 overflow: "hidden" 21485 }), 21486 r && n.css(l, c ? isNaN(i) ? "-" + i : -i : i), 21487 u[l] = (r ? c ? "+=" : "-=" : c ? "-=" : "+=") + i, 21488 n.animate(u, { 21489 queue: !1, 21490 duration: t.duration, 21491 easing: t.easing, 21492 complete: function() { 21493 "hide" === o && n.hide(), 21494 h.effects.restore(n, s), 21495 h.effects.removeWrapper(n), 21496 e() 21497 } 21498 }) 21499 } 21500}(jQuery), 21501function(d) { 21502 d.effects.effect.transfer = function(t, e) { 21503 var i = d(this) 21504 , n = d(t.to) 21505 , s = "fixed" === n.css("position") 21506 , o = d("body") 21507 , r = s ? o.scrollTop() : 0 21508 , a = s ? o.scrollLeft() : 0 21509 , l = n.offset() 21510 , c = { 21511 top: l.top - r, 21512 left: l.left - a, 21513 height: n.innerHeight(), 21514 width: n.innerWidth() 21515 } 21516 , u = i.offset() 21517 , h = d('<div class="ui-effects-transfer"></div>').appendTo(document.body).addClass(t.className).css({ 21518 top: u.top - r, 21519 left: u.left - a, 21520 height: i.innerHeight(), 21521 width: i.innerWidth(), 21522 position: s ? "fixed" : "absolute" 21523 }).animate(c, t.duration, t.easing, function() { 21524 h.remove(), 21525 e() 21526 }) 21527 } 21528}(jQuery), 21529function(l) { 21530 var i = !1; 21531 l.widget("ui.menu", { 21532 version: "1.9.0", 21533 defaultElement: "<ul>", 21534 delay: 300, 21535 options: { 21536 icons: { 21537 submenu: "ui-icon-carat-1-e" 21538 }, 21539 menus: "ul", 21540 position: { 21541 my: "left top", 21542 at: "right top" 21543 }, 21544 role: "menu", 21545 blur: null, 21546 focus: null, 21547 select: null 21548 }, 21549 _create: function() { 21550 this.activeMenu = this.element, 21551 this.element.uniqueId().addClass("ui-menu ui-widget ui-widget-content ui-corner-all").toggleClass("ui-menu-icons", !!this.element.find(".ui-icon").length).attr({ 21552 role: this.options.role, 21553 tabIndex: 0 21554 }).bind("click" + this.eventNamespace, l.proxy(function(t) { 21555 this.options.disabled && t.preventDefault() 21556 }, this)), 21557 this.options.disabled && this.element.addClass("ui-state-disabled").attr("aria-disabled", "true"), 21558 this._on({ 21559 "mousedown .ui-menu-item > a": function(t) { 21560 t.preventDefault() 21561 }, 21562 "click .ui-state-disabled > a": function(t) { 21563 t.preventDefault() 21564 }, 21565 "click .ui-menu-item:has(a)": function(t) { 21566 var e = l(t.target).closest(".ui-menu-item"); 21567 !i && e.not(".ui-state-disabled").length && (i = !0, 21568 this.select(t), 21569 e.has(".ui-menu").length ? this.expand(t) : this.element.is(":focus") || (this.element.trigger("focus", [!0]), 21570 this.active && 1 === this.active.parents(".ui-menu").length && clearTimeout(this.timer))) 21571 }, 21572 "mouseenter .ui-menu-item": function(t) { 21573 var e = l(t.currentTarget); 21574 e.siblings().children(".ui-state-active").removeClass("ui-state-active"), 21575 this.focus(t, e) 21576 }, 21577 mouseleave: "collapseAll", 21578 "mouseleave .ui-menu": "collapseAll", 21579 focus: function(t, e) { 21580 var i = this.active || this.element.children(".ui-menu-item").eq(0); 21581 e || this.focus(t, i) 21582 }, 21583 blur: function(t) { 21584 this._delay(function() { 21585 l.contains(this.element[0], this.document[0].activeElement) || this.collapseAll(t) 21586 }) 21587 }, 21588 keydown: "_keydown" 21589 }), 21590 this.refresh(), 21591 this._on(this.document, { 21592 click: function(t) { 21593 l(t.target).closest(".ui-menu").length || this.collapseAll(t), 21594 i = !1 21595 } 21596 }) 21597 }, 21598 _destroy: function() { 21599 this.element.removeAttr("aria-activedescendant").find(".ui-menu").andSelf().removeClass("ui-menu ui-widget ui-widget-content ui-corner-all ui-menu-icons").removeAttr("role").removeAttr("tabIndex").removeAttr("aria-labelledby").removeAttr("aria-expanded").removeAttr("aria-hidden").removeAttr("aria-disabled").removeUniqueId().show(), 21600 this.element.find(".ui-menu-item").removeClass("ui-menu-item").removeAttr("role").removeAttr("aria-disabled").children("a").removeUniqueId().removeClass("ui-corner-all ui-state-hover").removeAttr("tabIndex").removeAttr("role").removeAttr("aria-haspopup").children().each(function() { 21601 var t = l(this); 21602 t.data("ui-menu-submenu-carat") && t.remove() 21603 }), 21604 this.element.find(".ui-menu-divider").removeClass("ui-menu-divider ui-widget-content") 21605 }, 21606 _keydown: function(t) { 21607 function e(t) { 21608 return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&") 21609 } 21610 var i, n, s, o, r, a = !0; 21611 switch (t.keyCode) { 21612 case l.ui.keyCode.PAGE_UP: 21613 this.previousPage(t); 21614 break; 21615 case l.ui.keyCode.PAGE_DOWN: 21616 this.nextPage(t); 21617 break; 21618 case l.ui.keyCode.HOME: 21619 this._move("first", "first", t); 21620 break; 21621 case l.ui.keyCode.END: 21622 this._move("last", "last", t); 21623 break; 21624 case l.ui.keyCode.UP: 21625 this.previous(t); 21626 break; 21627 case l.ui.keyCode.DOWN: 21628 this.next(t); 21629 break; 21630 case l.ui.keyCode.LEFT: 21631 this.collapse(t); 21632 break; 21633 case l.ui.keyCode.RIGHT: 21634 this.active && !this.active.is(".ui-state-disabled") && this.expand(t); 21635 break; 21636 case l.ui.keyCode.ENTER: 21637 case l.ui.keyCode.SPACE: 21638 this._activate(t); 21639 break; 21640 case l.ui.keyCode.ESCAPE: 21641 this.collapse(t); 21642 break; 21643 default: 21644 a = !1, 21645 n = this.previousFilter || "", 21646 s = String.fromCharCode(t.keyCode), 21647 o = !1, 21648 clearTimeout(this.filterTimer), 21649 s === n ? o = !0 : s = n + s, 21650 r = new RegExp("^" + e(s),"i"), 21651 i = this.activeMenu.children(".ui-menu-item").filter(function() { 21652 return r.test(l(this).children("a").text()) 21653 }), 21654 (i = o && -1 !== i.index(this.active.next()) ? this.active.nextAll(".ui-menu-item") : i).length || (s = String.fromCharCode(t.keyCode), 21655 r = new RegExp("^" + e(s),"i"), 21656 i = this.activeMenu.children(".ui-menu-item").filter(function() { 21657 return r.test(l(this).children("a").text()) 21658 })), 21659 i.length ? (this.focus(t, i), 21660 1 < i.length ? (this.previousFilter = s, 21661 this.filterTimer = this._delay(function() { 21662 delete this.previousFilter 21663 }, 1e3)) : delete this.previousFilter) : delete this.previousFilter 21664 } 21665 a && t.preventDefault() 21666 }, 21667 _activate: function(t) { 21668 this.active.is(".ui-state-disabled") || (this.active.children("a[aria-haspopup='true']").length ? this.expand(t) : this.select(t)) 21669 }, 21670 refresh: function() { 21671 var t, n = this.options.icons.submenu, e = this.element.find(this.options.menus + ":not(.ui-menu)").addClass("ui-menu ui-widget ui-widget-content ui-corner-all").hide().attr({ 21672 role: this.options.role, 21673 "aria-hidden": "true", 21674 "aria-expanded": "false" 21675 }); 21676 (t = e.add(this.element)).children(":not(.ui-menu-item):has(a)").addClass("ui-menu-item").attr("role", "presentation").children("a").uniqueId().addClass("ui-corner-all").attr({ 21677 tabIndex: -1, 21678 role: this._itemRole() 21679 }), 21680 t.children(":not(.ui-menu-item)").each(function() { 21681 var t = l(this); 21682 /[^\-ââ\s]/.test(t.text()) || t.addClass("ui-widget-content ui-menu-divider") 21683 }), 21684 t.children(".ui-state-disabled").attr("aria-disabled", "true"), 21685 e.each(function() { 21686 var t = l(this) 21687 , e = t.prev("a") 21688 , i = l("<span>").addClass("ui-menu-icon ui-icon " + n).data("ui-menu-submenu-carat", !0); 21689 e.attr("aria-haspopup", "true").prepend(i), 21690 t.attr("aria-labelledby", e.attr("id")) 21691 }), 21692 this.active && !l.contains(this.element[0], this.active[0]) && this.blur() 21693 }, 21694 _itemRole: function() { 21695 return { 21696 menu: "menuitem", 21697 listbox: "option" 21698 }[this.options.role] 21699 }, 21700 focus: function(t, e) { 21701 var i, n; 21702 this.blur(t, t && "focus" === t.type), 21703 this._scrollIntoView(e), 21704 this.active = e.first(), 21705 n = this.active.children("a").addClass("ui-state-focus"), 21706 this.options.role && this.element.attr("aria-activedescendant", n.attr("id")), 21707 this.active.parent().closest(".ui-menu-item").children("a:first").addClass("ui-state-active"), 21708 t && "keydown" === t.type ? this._close() : this.timer = this._delay(function() { 21709 this._close() 21710 }, this.delay), 21711 (i = e.children(".ui-menu")).length && /^mouse/.test(t.type) && this._startOpening(i), 21712 this.activeMenu = e.parent(), 21713 this._trigger("focus", t, { 21714 item: e 21715 }) 21716 }, 21717 _scrollIntoView: function(t) { 21718 var e, i, n, s, o, r; 21719 this._hasScroll() && (e = parseFloat(l.css(this.activeMenu[0], "borderTopWidth")) || 0, 21720 i = parseFloat(l.css(this.activeMenu[0], "paddingTop")) || 0, 21721 n = t.offset().top - this.activeMenu.offset().top - e - i, 21722 s = this.activeMenu.scrollTop(), 21723 o = this.activeMenu.height(), 21724 r = t.height(), 21725 n < 0 ? this.activeMenu.scrollTop(s + n) : o < n + r && this.activeMenu.scrollTop(s + n - o + r)) 21726 }, 21727 blur: function(t, e) { 21728 e || clearTimeout(this.timer), 21729 this.active && (this.active.children("a").removeClass("ui-state-focus"), 21730 this.active = null, 21731 this._trigger("blur", t, { 21732 item: this.active 21733 })) 21734 }, 21735 _startOpening: function(t) { 21736 clearTimeout(this.timer), 21737 "true" === t.attr("aria-hidden") && (this.timer = this._delay(function() { 21738 this._close(), 21739 this._open(t) 21740 }, this.delay)) 21741 }, 21742 _open: function(t) { 21743 var e = l.extend({ 21744 of: this.active 21745 }, this.options.position); 21746 clearTimeout(this.timer), 21747 this.element.find(".ui-menu").not(t.parents(".ui-menu")).hide().attr("aria-hidden", "true"), 21748 t.show().removeAttr("aria-hidden").attr("aria-expanded", "true").position(e) 21749 }, 21750 collapseAll: function(e, i) { 21751 clearTimeout(this.timer), 21752 this.timer = this._delay(function() { 21753 var t = i ? this.element : l(e && e.target).closest(this.element.find(".ui-menu")); 21754 t.length || (t = this.element), 21755 this._close(t), 21756 this.blur(e), 21757 this.activeMenu = t 21758 }, this.delay) 21759 }, 21760 _close: function(t) { 21761 t || (t = this.active ? this.active.parent() : this.element), 21762 t.find(".ui-menu").hide().attr("aria-hidden", "true").attr("aria-expanded", "false").end().find("a.ui-state-active").removeClass("ui-state-active") 21763 }, 21764 collapse: function(t) { 21765 var e = this.active && this.active.parent().closest(".ui-menu-item", this.element); 21766 e && e.length && (this._close(), 21767 this.focus(t, e)) 21768 }, 21769 expand: function(t) { 21770 var e = this.active && this.active.children(".ui-menu ").children(".ui-menu-item").first(); 21771 e && e.length && (this._open(e.parent()), 21772 this._delay(function() { 21773 this.focus(t, e) 21774 })) 21775 }, 21776 next: function(t) { 21777 this._move("next", "first", t) 21778 }, 21779 previous: function(t) { 21780 this._move("prev", "last", t) 21781 }, 21782 isFirstItem: function() { 21783 return this.active && !this.active.prevAll(".ui-menu-item").length 21784 }, 21785 isLastItem: function() { 21786 return this.active && !this.active.nextAll(".ui-menu-item").length 21787 }, 21788 _move: function(t, e, i) { 21789 var n; 21790 this.active && (n = "first" === t || "last" === t ? this.active["first" === t ? "prevAll" : "nextAll"](".ui-menu-item").eq(-1) : this.active[t + "All"](".ui-menu-item").eq(0)), 21791 n && n.length && this.active || (n = this.activeMenu.children(".ui-menu-item")[e]()), 21792 this.focus(i, n) 21793 }, 21794 nextPage: function(t) { 21795 var e, i, n; 21796 this.active ? this.isLastItem() || (this._hasScroll() ? (i = this.active.offset().top, 21797 n = this.element.height(), 21798 this.active.nextAll(".ui-menu-item").each(function() { 21799 return (e = l(this)).offset().top - i - n < 0 21800 }), 21801 this.focus(t, e)) : this.focus(t, this.activeMenu.children(".ui-menu-item")[this.active ? "last" : "first"]())) : this.next(t) 21802 }, 21803 previousPage: function(t) { 21804 var e, i, n; 21805 this.active ? this.isFirstItem() || (this._hasScroll() ? (i = this.active.offset().top, 21806 n = this.element.height(), 21807 this.active.prevAll(".ui-menu-item").each(function() { 21808 return 0 < (e = l(this)).offset().top - i + n 21809 }), 21810 this.focus(t, e)) : this.focus(t, this.activeMenu.children(".ui-menu-item").first())) : this.next(t) 21811 }, 21812 _hasScroll: function() { 21813 return this.element.outerHeight() < this.element.prop("scrollHeight") 21814 }, 21815 select: function(t) { 21816 this.active = this.active || l(t.target).closest(".ui-menu-item"); 21817 var e = { 21818 item: this.active 21819 }; 21820 this.active.has(".ui-menu").length || this.collapseAll(t, !0), 21821 this._trigger("select", t, e) 21822 } 21823 }) 21824}(jQuery), 21825function(_) { 21826 function k(t, e, i) { 21827 return [parseInt(t[0], 10) * (u.test(t[0]) ? e / 100 : 1), parseInt(t[1], 10) * (u.test(t[1]) ? i / 100 : 1)] 21828 } 21829 function C(t, e) { 21830 return parseInt(_.css(t, e), 10) || 0 21831 } 21832 _.ui = _.ui || {}; 21833 var s, n, o, S = Math.max, T = Math.abs, I = Math.round, r = /left|center|right/, a = /top|center|bottom/, l = /[\+\-]\d+%?/, c = /^\w+/, u = /%$/, e = _.fn.position; 21834 _.position = { 21835 scrollbarWidth: function()
vendor: 6,260 bytes, lines 21835-21992
21835 { 21836 if (void 0 !== s) 21837 return s; 21838 var t, e, i = _("<div style='display:block;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>"), n = i.children()[0]; 21839 return _("body").append(i), 21840 t = n.offsetWidth, 21841 i.css("overflow", "scroll"), 21842 t === (e = n.offsetWidth) && (e = i[0].clientWidth), 21843 i.remove(), 21844 s = t - e 21845 }, 21846 getScrollInfo: function(t) { 21847 var e = t.isWindow ? "" : t.element.css("overflow-x") 21848 , i = t.isWindow ? "" : t.element.css("overflow-y") 21849 , n = "scroll" === e || "auto" === e && t.width < t.element[0].scrollWidth 21850 , s = "scroll" === i || "auto" === i && t.height < t.element[0].scrollHeight; 21851 return { 21852 width: n ? _.position.scrollbarWidth() : 0, 21853 height: s ? _.position.scrollbarWidth() : 0 21854 } 21855 }, 21856 getWithinInfo: function(t) { 21857 var e = _(t || window) 21858 , i = _.isWindow(e[0]); 21859 return { 21860 element: e, 21861 isWindow: i, 21862 offset: e.offset() || { 21863 left: 0, 21864 top: 0 21865 }, 21866 scrollLeft: e.scrollLeft(), 21867 scrollTop: e.scrollTop(), 21868 width: i ? e.width() : e.outerWidth(), 21869 height: i ? e.height() : e.outerHeight() 21870 } 21871 } 21872 }, 21873 _.fn.position = function(h) { 21874 if (!h || !h.of) 21875 return e.apply(this, arguments); 21876 h = _.extend({}, h); 21877 var d, p, f, g, m, v = _(h.of), y = _.position.getWithinInfo(h.within), b = _.position.getScrollInfo(y), t = v[0], w = (h.collision || "flip").split(" "), x = {}; 21878 return 9 === t.nodeType ? (p = v.width(), 21879 f = v.height(), 21880 g = { 21881 top: 0, 21882 left: 0 21883 }) : _.isWindow(t) ? (p = v.width(), 21884 f = v.height(), 21885 g = { 21886 top: v.scrollTop(), 21887 left: v.scrollLeft() 21888 }) : t.preventDefault ? (h.at = "left top", 21889 p = f = 0, 21890 g = { 21891 top: t.pageY, 21892 left: t.pageX 21893 }) : (p = v.outerWidth(), 21894 f = v.outerHeight(), 21895 g = v.offset()), 21896 m = _.extend({}, g), 21897 _.each(["my", "at"], function() { 21898 var t, e, i = (h[this] || "").split(" "); 21899 1 === i.length && (i = r.test(i[0]) ? i.concat(["center"]) : a.test(i[0]) ? ["center"].concat(i) : ["center", "center"]), 21900 i[0] = r.test(i[0]) ? i[0] : "center", 21901 i[1] = a.test(i[1]) ? i[1] : "center", 21902 t = l.exec(i[0]), 21903 e = l.exec(i[1]), 21904 x[this] = [t ? t[0] : 0, e ? e[0] : 0], 21905 h[this] = [c.exec(i[0])[0], c.exec(i[1])[0]] 21906 }), 21907 1 === w.length && (w[1] = w[0]), 21908 "right" === h.at[0] ? m.left += p : "center" === h.at[0] && (m.left += p / 2), 21909 "bottom" === h.at[1] ? m.top += f : "center" === h.at[1] && (m.top += f / 2), 21910 d = k(x.at, p, f), 21911 m.left += d[0], 21912 m.top += d[1], 21913 this.each(function() { 21914 var i, t, r = _(this), a = r.outerWidth(), l = r.outerHeight(), e = C(this, "marginLeft"), n = C(this, "marginTop"), s = a + e + C(this, "marginRight") + b.width, o = l + n + C(this, "marginBottom") + b.height, c = _.extend({}, m), u = k(x.my, r.outerWidth(), r.outerHeight()); 21915 "right" === h.my[0] ? c.left -= a : "center" === h.my[0] && (c.left -= a / 2), 21916 "bottom" === h.my[1] ? c.top -= l : "center" === h.my[1] && (c.top -= l / 2), 21917 c.left += u[0], 21918 c.top += u[1], 21919 _.support.offsetFractions || (c.left = I(c.left), 21920 c.top = I(c.top)), 21921 i = { 21922 marginLeft: e, 21923 marginTop: n 21924 }, 21925 _.each(["left", "top"], function(t, e) { 21926 _.ui.position[w[t]] && _.ui.position[w[t]][e](c, { 21927 targetWidth: p, 21928 targetHeight: f, 21929 elemWidth: a, 21930 elemHeight: l, 21931 collisionPosition: i, 21932 collisionWidth: s, 21933 collisionHeight: o, 21934 offset: [d[0] + u[0], d[1] + u[1]], 21935 my: h.my, 21936 at: h.at, 21937 within: y, 21938 elem: r 21939 }) 21940 }), 21941 _.fn.bgiframe && r.bgiframe(), 21942 h.using && (t = function(t) { 21943 var e = g.left - c.left 21944 , i = e + p - a 21945 , n = g.top - c.top 21946 , s = n + f - l 21947 , o = { 21948 target: { 21949 element: v, 21950 left: g.left, 21951 top: g.top, 21952 width: p, 21953 height: f 21954 }, 21955 element: { 21956 element: r, 21957 left: c.left, 21958 top: c.top, 21959 width: a, 21960 height: l 21961 }, 21962 horizontal: i < 0 ? "left" : 0 < e ? "right" : "center", 21963 vertical: s < 0 ? "top" : 0 < n ? "bottom" : "middle" 21964 }; 21965 p < a && T(e + i) < p && (o.horizontal = "center"), 21966 f < l && T(n + s) < f && (o.vertical = "middle"), 21967 S(T(e), T(i)) > S(T(n), T(s)) ? o.important = "horizontal" : o.important = "vertical", 21968 h.using.call(this, t, o) 21969 } 21970 ), 21971 r.offset(_.extend(c, { 21972 using: t 21973 })) 21974 }) 21975 } 21976 , 21977 _.ui.position = { 21978 fit: { 21979 left: function(t, e) { 21980 var i, n = e.within, s = n.isWindow ? n.scrollLeft : n.offset.left, o = n.width, r = t.left - e.collisionPosition.marginLeft, a = s - r, l = r + e.collisionWidth - o - s; 21981 e.collisionWidth > o ? 0 < a && l <= 0 ? (i = t.left + a + e.collisionWidth - o - s, 21982 t.left += a - i) : t.left = 0 < l && a <= 0 ? s : l < a ? s + o - e.collisionWidth : s : 0 < a ? t.left += a : 0 < l ? t.left -= l : t.left = S(t.left - r, t.left) 21983 }, 21984 top: function(t, e) { 21985 var i, n = e.within, s = n.isWindow ? n.scrollTop : n.offset.top, o = e.within.height, r = t.top - e.collisionPosition.marginTop, a = s - r, l = r + e.collisionHeight - o - s; 21986 e.collisionHeight > o ? 0 < a && l <= 0 ? (i = t.top + a + e.collisionHeight - o - s, 21987 t.top += a - i) : t.top = 0 < l && a <= 0 ? s : l < a ? s + o - e.collisionHeight : s : 0 < a ? t.top += a : 0 < l ? t.top -= l : t.top = S(t.top - r, t.top) 21988 } 21989 }, 21990 flip: { 21991 left: function(t, e) { 21992 var i, n, s = e.within, o = s.offset.left + s.scrollLeft, r = s.width, a = s.isWindow ? s.scrollLeft : s.offset.left, l = t.left - e.collisionPosition.marginLeft, c = l - a, u = l + e.collisionWidth - r - a, h = "left" === e.my[0] ? -e.elemWidth : "right" === e.my[0] ? e.elemWidth : 0, d = "left" === e.at[0] ? e.targetWidth : "right" === e.at[0] ? -e.targetWidth : 0, p = -2 * e.offset[0];
21993 c < 0 ? ((i = t.left + h + d + p + e.collisionWidth - r - o) < 0 || i < T(c)) && (t.left += h + d + p) : 0 < u && (0 < (n = t.left - e.collisionPosition.marginLeft + h + d + p - a) || T(n) < u) && (t.left += h + d + p) 21994 }, 21995 top: function(t, e) { 21996 var i, n, s = e.within, o = s.offset.top + s.scrollTop, r = s.height, a = s.isWindow ? s.scrollTop : s.offset.top, l = t.top - e.collisionPosition.marginTop, c = l - a, u = l + e.collisionHeight - r - a, h = "top" === e.my[1] ? -e.elemHeight : "bottom" === e.my[1] ? e.elemHeight : 0, d = "top" === e.at[1] ? e.targetHeight : "bottom" === e.at[1] ? -e.targetHeight : 0, p = -2 * e.offset[1]; 21997 c < 0 ? (n = t.top + h + d + p + e.collisionHeight - r - o, 21998 t.top + h + d + p > c && (n < 0 || n < T(c)) && (t.top += h + d + p)) : 0 < u && (i = t.top - e.collisionPosition.marginTop + h + d + p - a, 21999 t.top + h + d + p > u && (0 < i || T(i) < u) && (t.top += h + d + p)) 22000 } 22001 }, 22002 flipfit: { 22003 left: function() { 22004 _.ui.position.flip.left.apply(this, arguments), 22005 _.ui.position.fit.left.apply(this, arguments) 22006 }, 22007 top: function() { 22008 _.ui.position.flip.top.apply(this, arguments), 22009 _.ui.position.fit.top.apply(this, arguments) 22010 } 22011 } 22012 }, 22013 function() { 22014 var t, e, i, n, s, o = document.getElementsByTagName("body")[0], r = document.createElement("div"); 22015 for (s in t = document.createElement(o ? "div" : "body"), 22016 i = { 22017 visibility: "hidden", 22018 width: 0, 22019 height: 0, 22020 border: 0, 22021 margin: 0, 22022 background: "none" 22023 }, 22024 o && _.extend(i, { 22025 position: "absolute", 22026 left: "-1000px", 22027 top: "-1000px" 22028 }), 22029 i) 22030 t.style[s] = i[s]; 22031 t.appendChild(r), 22032 (e = o || document.documentElement).insertBefore(t, e.firstChild), 22033 r.style.cssText = "position: absolute; left: 10.7432222px;", 22034 n = _(r).offset().left, 22035 _.support.offsetFractions = 10 < n && n < 11, 22036 t.innerHTML = "", 22037 e.removeChild(t) 22038 }(), 22039 !1 !== _.uiBackCompat && (n = jQuery, 22040 o = n.fn.position, 22041 n.fn.position = function(t) { 22042 if (!t || !t.offset) 22043 return o.call(this, t); 22044 var e = t.offset.split(" ") 22045 , i = t.at.split(" "); 22046 return 1 === e.length && (e[1] = e[0]), 22047 /^\d/.test(e[0]) && (e[0] = "+" + e[0]), 22048 /^\d/.test(e[1]) && (e[1] = "+" + e[1]), 22049 1 === i.length && (/left|center|right/.test(i[0]) ? i[1] = "center" : (i[1] = i[0], 22050 i[0] = "center")), 22051 o.call(this, n.extend(t, { 22052 at: i[0] + e[0] + " " + i[1] + e[1], 22053 offset: void 0 22054 })) 22055 } 22056 ) 22057}(jQuery), 22058function(t) { 22059 t.widget("ui.progressbar", { 22060 version: "1.9.0", 22061 options: { 22062 value: 0, 22063 max: 100 22064 }, 22065 min: 0, 22066 _create: function() { 22067 this.element.addClass("ui-progressbar ui-widget ui-widget-content ui-corner-all").attr({ 22068 role: "progressbar", 22069 "aria-valuemin": this.min, 22070 "aria-valuemax": this.options.max, 22071 "aria-valuenow": this._value() 22072 }), 22073 this.valueDiv = t("<div class='ui-progressbar-value ui-widget-header ui-corner-left'></div>").appendTo(this.element), 22074 this.oldValue = this._value(), 22075 this._refreshValue() 22076 }, 22077 _destroy: function() { 22078 this.element.removeClass("ui-progressbar ui-widget ui-widget-content ui-corner-all").removeAttr("role").removeAttr("aria-valuemin").removeAttr("aria-valuemax").removeAttr("aria-valuenow"), 22079 this.valueDiv.remove() 22080 }, 22081 value: function(t) { 22082 return void 0 === t ? this._value() : (this._setOption("value", t), 22083 this) 22084 }, 22085 _setOption: function(t, e) { 22086 "value" === t && (this.options.value = e, 22087 this._refreshValue(), 22088 this._value() === this.options.max && this._trigger("complete")), 22089 this._super(t, e) 22090 }, 22091 _value: function() { 22092 var t = this.options.value; 22093 return "number" != typeof t && (t = 0), 22094 Math.min(this.options.max, Math.max(this.min, t)) 22095 }, 22096 _percentage: function() { 22097 return 100 * this._value() / this.options.max 22098 }, 22099 _refreshValue: function() { 22100 var t = this.value() 22101 , e = this._percentage(); 22102 this.oldValue !== t && (this.oldValue = t, 22103 this._trigger("change")), 22104 this.valueDiv.toggle(t > this.min).toggleClass("ui-corner-right", t === this.options.max).width(e.toFixed(0) + "%"), 22105 this.element.attr("aria-valuenow", t) 22106 } 22107 }) 22108}(jQuery), 22109function(u) { 22110 u.widget("ui.slider", u.ui.mouse, { 22111 version: "1.9.0", 22112 widgetEventPrefix: "slide", 22113 options: { 22114 animate: !1, 22115 distance: 0, 22116 max: 100, 22117 min: 0, 22118 orientation: "horizontal", 22119 range: !1, 22120 step: 1, 22121 value: 0, 22122 values: null 22123 }, 22124 _create: function() { 22125 var t, e = this.options, i = this.element.find(".ui-slider-handle").addClass("ui-state-default ui-corner-all"), n = e.values && e.values.length || 1, s = []; 22126 for (this._keySliding = !1, 22127 this._mouseSliding = !1, 22128 this._animateOff = !0, 22129 this._handleIndex = null, 22130 this._detectOrientation(), 22131 this._mouseInit(), 22132 this.element.addClass("ui-slider ui-slider-" + this.orientation + " ui-widget ui-widget-content ui-corner-all" + (e.disabled ? " ui-slider-disabled ui-disabled" : "")), 22133 this.range = u([]), 22134 e.range && (!0 === e.range && (e.values || (e.values = [this._valueMin(), this._valueMin()]), 22135 e.values.length && 2 !== e.values.length && (e.values = [e.values[0], e.values[0]])), 22136 this.range = u("<div></div>").appendTo(this.element).addClass("ui-slider-range ui-widget-header" + ("min" === e.range || "max" === e.range ? " ui-slider-range-" + e.range : ""))), 22137 t = i.length; t < n; t++) 22138 s.push("<a class='ui-slider-handle ui-state-default ui-corner-all' href='#'></a>"); 22139 this.handles = i.add(u(s.join("")).appendTo(this.element)), 22140 this.handle = this.handles.eq(0), 22141 this.handles.add(this.range).filter("a").click(function(t) { 22142 t.preventDefault() 22143 }).mouseenter(function() { 22144 e.disabled || u(this).addClass("ui-state-hover") 22145 }).mouseleave(function() { 22146 u(this).removeClass("ui-state-hover") 22147 }).focus(function() { 22148 e.disabled ? u(this).blur() : (u(".ui-slider .ui-state-focus").removeClass("ui-state-focus"), 22149 u(this).addClass("ui-state-focus")) 22150 }).blur(function() { 22151 u(this).removeClass("ui-state-focus") 22152 }), 22153 this.handles.each(function(t) { 22154 u(this).data("ui-slider-handle-index", t) 22155 }), 22156 this._on(this.handles, { 22157 keydown: function(t) { 22158 var e, i, n, s = u(t.target).data("ui-slider-handle-index"); 22159 switch (t.keyCode) { 22160 case u.ui.keyCode.HOME: 22161 case u.ui.keyCode.END: 22162 case u.ui.keyCode.PAGE_UP: 22163 case u.ui.keyCode.PAGE_DOWN: 22164 case u.ui.keyCode.UP: 22165 case u.ui.keyCode.RIGHT: 22166 case u.ui.keyCode.DOWN: 22167 case u.ui.keyCode.LEFT: 22168 if (t.preventDefault(), 22169 !this._keySliding && (this._keySliding = !0, 22170 u(t.target).addClass("ui-state-active"), 22171 !1 === this._start(t, s))) 22172 return 22173 } 22174 switch (n = this.options.step, 22175 e = i = this.options.values && this.options.values.length ? this.values(s) : this.value(), 22176 t.keyCode) { 22177 case u.ui.keyCode.HOME: 22178 i = this._valueMin(); 22179 break; 22180 case u.ui.keyCode.END: 22181 i = this._valueMax(); 22182 break; 22183 case u.ui.keyCode.PAGE_UP: 22184 i = this._trimAlignValue(e + (this._valueMax() - this._valueMin()) / 5); 22185 break; 22186 case u.ui.keyCode.PAGE_DOWN: 22187 i = this._trimAlignValue(e - (this._valueMax() - this._valueMin()) / 5); 22188 break; 22189 case u.ui.keyCode.UP: 22190 case u.ui.keyCode.RIGHT: 22191 if (e === this._valueMax()) 22192 return; 22193 i = this._trimAlignValue(e + n); 22194 break; 22195 case u.ui.keyCode.DOWN: 22196 case u.ui.keyCode.LEFT: 22197 if (e === this._valueMin()) 22198 return; 22199 i = this._trimAlignValue(e - n) 22200 } 22201 this._slide(t, s, i) 22202 }, 22203 keyup: function(t) { 22204 var e = u(t.target).data("ui-slider-handle-index"); 22205 this._keySliding && (this._keySliding = !1, 22206 this._stop(t, e), 22207 this._change(t, e), 22208 u(t.target).removeClass("ui-state-active")) 22209 } 22210 }), 22211 this._refreshValue(), 22212 this._animateOff = !1 22213 }, 22214 _destroy: function() { 22215 this.handles.remove(), 22216 this.range.remove(), 22217 this.element.removeClass("ui-slider ui-slider-horizontal ui-slider-vertical ui-slider-disabled ui-widget ui-widget-content ui-corner-all"), 22218 this._mouseDestroy() 22219 }, 22220 _mouseCapture: function(t) { 22221 var e, i, n, s, o, r, a, l = this, c = this.options; 22222 return !c.disabled && (this.elementSize = { 22223 width: this.element.outerWidth(), 22224 height: this.element.outerHeight() 22225 }, 22226 this.elementOffset = this.element.offset(), 22227 e = { 22228 x: t.pageX, 22229 y: t.pageY 22230 }, 22231 i = this._normValueFromMouse(e), 22232 n = this._valueMax() - this._valueMin() + 1, 22233 this.handles.each(function(t) { 22234 var e = Math.abs(i - l.values(t)); 22235 e < n && (n = e, 22236 s = u(this), 22237 o = t) 22238 }), 22239 !0 === c.range && this.values(1) === c.min && (o += 1, 22240 s = u(this.handles[o])), 22241 !1 !== this._start(t, o) && (this._mouseSliding = !0, 22242 this._handleIndex = o, 22243 s.addClass("ui-state-active").focus(), 22244 r = s.offset(), 22245 a = !u(t.target).parents().andSelf().is(".ui-slider-handle"), 22246 this._clickOffset = a ? {
22247 left: 0, 22248 top: 0 22249 } : { 22250 left: t.pageX - r.left - s.width() / 2, 22251 top: t.pageY - r.top - s.height() / 2 - (parseInt(s.css("borderTopWidth"), 10) || 0) - (parseInt(s.css("borderBottomWidth"), 10) || 0) + (parseInt(s.css("marginTop"), 10) || 0) 22252 }, 22253 this.handles.hasClass("ui-state-hover") || this._slide(t, o, i), 22254 this._animateOff = !0)) 22255 }, 22256 _mouseStart: function() { 22257 return !0 22258 }, 22259 _mouseDrag: function(t) { 22260 var e = { 22261 x: t.pageX, 22262 y: t.pageY 22263 } 22264 , i = this._normValueFromMouse(e); 22265 return this._slide(t, this._handleIndex, i), 22266 !1 22267 }, 22268 _mouseStop: function(t) { 22269 return this.handles.removeClass("ui-state-active"), 22270 this._mouseSliding = !1, 22271 this._stop(t, this._handleIndex), 22272 this._change(t, this._handleIndex), 22273 this._handleIndex = null, 22274 this._clickOffset = null, 22275 this._animateOff = !1 22276 }, 22277 _detectOrientation: function() { 22278 this.orientation = "vertical" === this.options.orientation ? "vertical" : "horizontal" 22279 }, 22280 _normValueFromMouse: function(t) { 22281 var e, i, n, s, o; 22282 return "horizontal" === this.orientation ? (e = this.elementSize.width, 22283 i = t.x - this.elementOffset.left - (this._clickOffset ? this._clickOffset.left : 0)) : (e = this.elementSize.height, 22284 i = t.y - this.elementOffset.top - (this._clickOffset ? this._clickOffset.top : 0)), 22285 1 < (n = i / e) && (n = 1), 22286 n < 0 && (n = 0), 22287 "vertical" === this.orientation && (n = 1 - n), 22288 s = this._valueMax() - this._valueMin(), 22289 o = this._valueMin() + n * s, 22290 this._trimAlignValue(o) 22291 }, 22292 _start: function(t, e) { 22293 var i = { 22294 handle: this.handles[e], 22295 value: this.value() 22296 }; 22297 return this.options.values && this.options.values.length && (i.value = this.values(e), 22298 i.values = this.values()), 22299 this._trigger("start", t, i) 22300 }, 22301 _slide: function(t, e, i) { 22302 var n, s, o; 22303 this.options.values && this.options.values.length ? (n = this.values(e ? 0 : 1), 22304 2 === this.options.values.length && !0 === this.options.range && (0 === e && n < i || 1 === e && i < n) && (i = n), 22305 i !== this.values(e) && ((s = this.values())[e] = i, 22306 o = this._trigger("slide", t, { 22307 handle: this.handles[e], 22308 value: i, 22309 values: s 22310 }), 22311 n = this.values(e ? 0 : 1), 22312 !1 !== o && this.values(e, i, !0))) : i !== this.value() && !1 !== (o = this._trigger("slide", t, { 22313 handle: this.handles[e], 22314 value: i 22315 })) && this.value(i) 22316 }, 22317 _stop: function(t, e) { 22318 var i = { 22319 handle: this.handles[e], 22320 value: this.value() 22321 }; 22322 this.options.values && this.options.values.length && (i.value = this.values(e), 22323 i.values = this.values()), 22324 this._trigger("stop", t, i) 22325 }, 22326 _change: function(t, e) { 22327 if (!this._keySliding && !this._mouseSliding) { 22328 var i = { 22329 handle: this.handles[e], 22330 value: this.value() 22331 }; 22332 this.options.values && this.options.values.length && (i.value = this.values(e), 22333 i.values = this.values()), 22334 this._trigger("change", t, i) 22335 } 22336 }, 22337 value: function(t) { 22338 return arguments.length ? (this.options.value = this._trimAlignValue(t), 22339 this._refreshValue(), 22340 void this._change(null, 0)) : this._value() 22341 }, 22342 values: function(t, e) { 22343 var i, n, s; 22344 if (1 < arguments.length) 22345 return this.options.values[t] = this._trimAlignValue(e), 22346 this._refreshValue(), 22347 void this._change(null, t); 22348 if (!arguments.length) 22349 return this._values(); 22350 if (!u.isArray(t)) 22351 return this.options.values && this.options.values.length ? this._values(t) : this.value(); 22352 for (i = this.options.values, 22353 n = t, 22354 s = 0; s < i.length; s += 1) 22355 i[s] = this._trimAlignValue(n[s]), 22356 this._change(null, s); 22357 this._refreshValue() 22358 }, 22359 _setOption: function(t, e) { 22360 var i, n = 0; 22361 switch (u.isArray(this.options.values) && (n = this.options.values.length), 22362 u.Widget.prototype._setOption.apply(this, arguments), 22363 t) { 22364 case "disabled": 22365 e ? (this.handles.filter(".ui-state-focus").blur(), 22366 this.handles.removeClass("ui-state-hover"), 22367 this.handles.prop("disabled", !0), 22368 this.element.addClass("ui-disabled")) : (this.handles.prop("disabled", !1), 22369 this.element.removeClass("ui-disabled")); 22370 break; 22371 case "orientation": 22372 this._detectOrientation(), 22373 this.element.removeClass("ui-slider-horizontal ui-slider-vertical").addClass("ui-slider-" + this.orientation), 22374 this._refreshValue(); 22375 break; 22376 case "value": 22377 this._animateOff = !0, 22378 this._refreshValue(), 22379 this._change(null, 0), 22380 this._animateOff = !1; 22381 break; 22382 case "values": 22383 for (this._animateOff = !0, 22384 this._refreshValue(), 22385 i = 0; i < n; i += 1) 22386 this._change(null, i); 22387 this._animateOff = !1 22388 } 22389 }, 22390 _value: function() { 22391 var t = this.options.value; 22392 return t = this._trimAlignValue(t) 22393 }, 22394 _values: function(t) { 22395 var e, i, n; 22396 if (arguments.length) 22397 return e = this.options.values[t], 22398 e = this._trimAlignValue(e); 22399 for (i = this.options.values.slice(), 22400 n = 0; n < i.length; n += 1) 22401 i[n] = this._trimAlignValue(i[n]); 22402 return i 22403 }, 22404 _trimAlignValue: function(t) { 22405 if (t <= this._valueMin()) 22406 return this._valueMin(); 22407 if (t >= this._valueMax()) 22408 return this._valueMax(); 22409 var e = 0 < this.options.step ? this.options.step : 1 22410 , i = (t - this._valueMin()) % e 22411 , n = t - i; 22412 return 2 * Math.abs(i) >= e && (n += 0 < i ? e : -e), 22413 parseFloat(n.toFixed(5)) 22414 }, 22415 _valueMin: function() { 22416 return this.options.min 22417 }, 22418 _valueMax: function() { 22419 return this.options.max 22420 }, 22421 _refreshValue: function() { 22422 var e, i, t, n, s, o = this.options.range, r = this.options, a = this, l = !this._animateOff && r.animate, c = {}; 22423 this.options.values && this.options.values.length ? this.handles.each(function(t) { 22424 i = (a.values(t) - a._valueMin()) / (a._valueMax() - a._valueMin()) * 100, 22425 c["horizontal" === a.orientation ? "left" : "bottom"] = i + "%", 22426 u(this).stop(1, 1)[l ? "animate" : "css"](c, r.animate), 22427 !0 === a.options.range && ("horizontal" === a.orientation ? (0 === t && a.range.stop(1, 1)[l ? "animate" : "css"]({ 22428 left: i + "%" 22429 }, r.animate), 22430 1 === t && a.range[l ? "animate" : "css"]({ 22431 width: i - e + "%"
vendor: 27,503 bytes, lines 22432-23210
22432 }, { 22433 queue: !1, 22434 duration: r.animate 22435 })) : (0 === t && a.range.stop(1, 1)[l ? "animate" : "css"]({ 22436 bottom: i + "%" 22437 }, r.animate), 22438 1 === t && a.range[l ? "animate" : "css"]({ 22439 height: i - e + "%" 22440 }, { 22441 queue: !1, 22442 duration: r.animate 22443 }))), 22444 e = i 22445 }) : (t = this.value(), 22446 n = this._valueMin(), 22447 s = this._valueMax(), 22448 i = s !== n ? (t - n) / (s - n) * 100 : 0, 22449 c["horizontal" === this.orientation ? "left" : "bottom"] = i + "%", 22450 this.handle.stop(1, 1)[l ? "animate" : "css"](c, r.animate), 22451 "min" === o && "horizontal" === this.orientation && this.range.stop(1, 1)[l ? "animate" : "css"]({ 22452 width: i + "%" 22453 }, r.animate), 22454 "max" === o && "horizontal" === this.orientation && this.range[l ? "animate" : "css"]({ 22455 width: 100 - i + "%" 22456 }, { 22457 queue: !1, 22458 duration: r.animate 22459 }), 22460 "min" === o && "vertical" === this.orientation && this.range.stop(1, 1)[l ? "animate" : "css"]({ 22461 height: i + "%" 22462 }, r.animate), 22463 "max" === o && "vertical" === this.orientation && this.range[l ? "animate" : "css"]({ 22464 height: 100 - i + "%" 22465 }, { 22466 queue: !1, 22467 duration: r.animate 22468 })) 22469 } 22470 }) 22471}(jQuery), 22472function(o) { 22473 function e(e) { 22474 return function() { 22475 var t = this.element.val(); 22476 e.apply(this, arguments), 22477 this._refresh(), 22478 t !== this.element.val() && this._trigger("change") 22479 } 22480 } 22481 o.widget("ui.spinner", { 22482 version: "1.9.0", 22483 defaultElement: "<input>", 22484 widgetEventPrefix: "spin", 22485 options: { 22486 culture: null, 22487 icons: { 22488 down: "ui-icon-triangle-1-s", 22489 up: "ui-icon-triangle-1-n" 22490 }, 22491 incremental: !0, 22492 max: null, 22493 min: null, 22494 numberFormat: null, 22495 page: 10, 22496 step: 1, 22497 change: null, 22498 spin: null, 22499 start: null, 22500 stop: null 22501 }, 22502 _create: function() { 22503 this._setOption("max", this.options.max), 22504 this._setOption("min", this.options.min), 22505 this._setOption("step", this.options.step), 22506 this._value(this.element.val(), !0), 22507 this._draw(), 22508 this._on(this._events), 22509 this._refresh(), 22510 this._on(this.window, { 22511 beforeunload: function() { 22512 this.element.removeAttr("autocomplete") 22513 } 22514 }) 22515 }, 22516 _getCreateOptions: function() { 22517 var n = {} 22518 , s = this.element; 22519 return o.each(["min", "max", "step"], function(t, e) { 22520 var i = s.attr(e); 22521 void 0 !== i && i.length && (n[e] = i) 22522 }), 22523 n 22524 }, 22525 _events: { 22526 keydown: function(t) { 22527 this._start(t) && this._keydown(t) && t.preventDefault() 22528 }, 22529 keyup: "_stop", 22530 focus: function() { 22531 this.uiSpinner.addClass("ui-state-active"), 22532 this.previous = this.element.val() 22533 }, 22534 blur: function(t) { 22535 this.cancelBlur ? delete this.cancelBlur : (this._refresh(), 22536 this.uiSpinner.removeClass("ui-state-active"), 22537 this.previous !== this.element.val() && this._trigger("change", t)) 22538 }, 22539 mousewheel: function(t, e) { 22540 if (e) { 22541 if (!this.spinning && !this._start(t)) 22542 return !1; 22543 this._spin((0 < e ? 1 : -1) * this.options.step, t), 22544 clearTimeout(this.mousewheelTimer), 22545 this.mousewheelTimer = this._delay(function() { 22546 this.spinning && this._stop(t) 22547 }, 100), 22548 t.preventDefault() 22549 } 22550 }, 22551 "mousedown .ui-spinner-button": function(t) { 22552 function e() { 22553 this.element[0] === this.document[0].activeElement || (this.element.focus(), 22554 this.previous = i, 22555 this._delay(function() { 22556 this.previous = i 22557 })) 22558 } 22559 var i; 22560 i = this.element[0] === this.document[0].activeElement ? this.previous : this.element.val(), 22561 t.preventDefault(), 22562 e.call(this), 22563 this.cancelBlur = !0, 22564 this._delay(function() { 22565 delete this.cancelBlur, 22566 e.call(this) 22567 }), 22568 !1 !== this._start(t) && this._repeat(null, o(t.currentTarget).hasClass("ui-spinner-up") ? 1 : -1, t) 22569 }, 22570 "mouseup .ui-spinner-button": "_stop", 22571 "mouseenter .ui-spinner-button": function(t) { 22572 if (o(t.currentTarget).hasClass("ui-state-active")) 22573 return !1 !== this._start(t) && void this._repeat(null, o(t.currentTarget).hasClass("ui-spinner-up") ? 1 : -1, t) 22574 }, 22575 "mouseleave .ui-spinner-button": "_stop" 22576 }, 22577 _draw: function() { 22578 var t = this.uiSpinner = this.element.addClass("ui-spinner-input").attr("autocomplete", "off").wrap(this._uiSpinnerHtml()).parent().append(this._buttonHtml()); 22579 this._hoverable(t), 22580 this.element.attr("role", "spinbutton"), 22581 this.buttons = t.find(".ui-spinner-button").attr("tabIndex", -1).button().removeClass("ui-corner-all"), 22582 this.buttons.height() > Math.ceil(.5 * t.height()) && 0 < t.height() && t.height(t.height()), 22583 this.options.disabled && this.disable() 22584 }, 22585 _keydown: function(t) { 22586 var e = this.options 22587 , i = o.ui.keyCode; 22588 switch (t.keyCode) { 22589 case i.UP: 22590 return this._repeat(null, 1, t), 22591 !0; 22592 case i.DOWN: 22593 return this._repeat(null, -1, t), 22594 !0; 22595 case i.PAGE_UP: 22596 return this._repeat(null, e.page, t), 22597 !0; 22598 case i.PAGE_DOWN: 22599 return this._repeat(null, -e.page, t), 22600 !0 22601 } 22602 return !1 22603 }, 22604 _uiSpinnerHtml: function() { 22605 return "<span class='ui-spinner ui-state-default ui-widget ui-widget-content ui-corner-all'></span>" 22606 }, 22607 _buttonHtml: function() { 22608 return "<a class='ui-spinner-button ui-spinner-up ui-corner-tr'><span class='ui-icon " + this.options.icons.up + "'>▲</span></a><a class='ui-spinner-button ui-spinner-down ui-corner-br'><span class='ui-icon " + this.options.icons.down + "'>▼</span></a>" 22609 }, 22610 _start: function(t) { 22611 return !(!this.spinning && !1 === this._trigger("start", t)) && (this.counter || (this.counter = 1), 22612 this.spinning = !0) 22613 }, 22614 _repeat: function(t, e, i) { 22615 t = t || 500, 22616 clearTimeout(this.timer), 22617 this.timer = this._delay(function() { 22618 this._repeat(40, e, i) 22619 }, t), 22620 this._spin(e * this.options.step, i) 22621 }, 22622 _spin: function(t, e) { 22623 var i = this.value() || 0; 22624 this.counter || (this.counter = 1), 22625 i = this._adjustValue(i + t * this._increment(this.counter)), 22626 this.spinning && !1 === this._trigger("spin", e, { 22627 value: i 22628 }) || (this._value(i), 22629 this.counter++) 22630 }, 22631 _increment: function(t) { 22632 var e = this.options.incremental; 22633 return e ? o.isFunction(e) ? e(t) : Math.floor(t * t * t / 5e4 - t * t / 500 + 17 * t / 200 + 1) : 1 22634 }, 22635 _precision: function() { 22636 var t = this._precisionOf(this.options.step); 22637 return null !== this.options.min && (t = Math.max(t, this._precisionOf(this.options.min))), 22638 t 22639 }, 22640 _precisionOf: function(t) { 22641 var e = t.toString() 22642 , i = e.indexOf("."); 22643 return -1 === i ? 0 : e.length - i - 1 22644 }, 22645 _adjustValue: function(t) { 22646 var e, i, n = this.options; 22647 return i = t - (e = null !== n.min ? n.min : 0), 22648 t = e + (i = Math.round(i / n.step) * n.step), 22649 t = parseFloat(t.toFixed(this._precision())), 22650 null !== n.max && t > n.max ? n.max : null !== n.min && t < n.min ? n.min : t 22651 }, 22652 _stop: function(t) { 22653 this.spinning && (clearTimeout(this.timer), 22654 clearTimeout(this.mousewheelTimer), 22655 this.counter = 0, 22656 this.spinning = !1, 22657 this._trigger("stop", t)) 22658 }, 22659 _setOption: function(t, e) { 22660 if ("culture" === t || "numberFormat" === t) { 22661 var i = this._parse(this.element.val()); 22662 return this.options[t] = e, 22663 void this.element.val(this._format(i)) 22664 } 22665 "max" !== t && "min" !== t && "step" !== t || "string" == typeof e && (e = this._parse(e)), 22666 this._super(t, e), 22667 "disabled" === t && (e ? (this.element.prop("disabled", !0), 22668 this.buttons.button("disable")) : (this.element.prop("disabled", !1), 22669 this.buttons.button("enable"))) 22670 }, 22671 _setOptions: e(function(t) { 22672 this._super(t), 22673 this._value(this.element.val()) 22674 }), 22675 _parse: function(t) { 22676 return "string" == typeof t && "" !== t && (t = window.Globalize && this.options.numberFormat ? Globalize.parseFloat(t, 10, this.options.culture) : +t), 22677 "" === t || isNaN(t) ? null : t 22678 }, 22679 _format: function(t) { 22680 return "" === t ? "" : window.Globalize && this.options.numberFormat ? Globalize.format(t, this.options.numberFormat, this.options.culture) : t 22681 }, 22682 _refresh: function() { 22683 this.element.attr({ 22684 "aria-valuemin": this.options.min, 22685 "aria-valuemax": this.options.max, 22686 "aria-valuenow": this._parse(this.element.val()) 22687 }) 22688 }, 22689 _value: function(t, e) { 22690 var i; 22691 "" !== t && null !== (i = this._parse(t)) && (e || (i = this._adjustValue(i)), 22692 t = this._format(i)), 22693 this.element.val(t), 22694 this._refresh() 22695 }, 22696 _destroy: function() { 22697 this.element.removeClass("ui-spinner-input").prop("disabled", !1).removeAttr("autocomplete").removeAttr("role").removeAttr("aria-valuemin").removeAttr("aria-valuemax").removeAttr("aria-valuenow"), 22698 this.uiSpinner.replaceWith(this.element) 22699 }, 22700 stepUp: e(function(t) { 22701 this._stepUp(t) 22702 }), 22703 _stepUp: function(t) { 22704 this._spin((t || 1) * this.options.step) 22705 }, 22706 stepDown: e(function(t) { 22707 this._stepDown(t) 22708 }), 22709 _stepDown: function(t) { 22710 this._spin((t || 1) * -this.options.step) 22711 }, 22712 pageUp: e(function(t) { 22713 this._stepUp((t || 1) * this.options.page) 22714 }), 22715 pageDown: e(function(t) { 22716 this._stepDown((t || 1) * this.options.page) 22717 }), 22718 value: function(t) { 22719 if (!arguments.length) 22720 return this._parse(this.element.val()); 22721 e(this._value).call(this, t) 22722 }, 22723 widget: function() { 22724 return this.uiSpinner 22725 } 22726 }) 22727}(jQuery), 22728function(c, l) { 22729 function i() { 22730 return ++t 22731 } 22732 function u(t) { 22733 return 1 < (t = t.cloneNode(!1)).hash.length && t.href.replace(e, "") === location.href.replace(e, "") 22734 } 22735 var n, t = 0, e = /#.*$/; 22736 c.widget("ui.tabs", { 22737 version: "1.9.0", 22738 delay: 300, 22739 options: { 22740 active: null, 22741 collapsible: !1, 22742 event: "click", 22743 heightStyle: "content", 22744 hide: null, 22745 show: null, 22746 activate: null, 22747 beforeActivate: null, 22748 beforeLoad: null, 22749 load: null 22750 }, 22751 _create: function() { 22752 var e = this 22753 , t = this.options 22754 , i = t.active; 22755 this.running = !1, 22756 this.element.addClass("ui-tabs ui-widget ui-widget-content ui-corner-all").toggleClass("ui-tabs-collapsible", t.collapsible).delegate(".ui-tabs-nav > li", "mousedown" + this.eventNamespace, function(t) { 22757 c(this).is(".ui-state-disabled") && t.preventDefault() 22758 }).delegate(".ui-tabs-anchor", "focus" + this.eventNamespace, function() { 22759 c(this).closest("li").is(".ui-state-disabled") && this.blur() 22760 }), 22761 this._processTabs(), 22762 null === i && (location.hash && this.anchors.each(function(t, e) { 22763 if (e.hash === location.hash) 22764 return i = t, 22765 !1 22766 }), 22767 null === i && (i = this.tabs.filter(".ui-tabs-active").index()), 22768 null !== i && -1 !== i || (i = !!this.tabs.length && 0)), 22769 !1 !== i && -1 === (i = this.tabs.index(this.tabs.eq(i))) && (i = !t.collapsible && 0), 22770 t.active = i, 22771 !t.collapsible && !1 === t.active && this.anchors.length && (t.active = 0), 22772 c.isArray(t.disabled) && (t.disabled = c.unique(t.disabled.concat(c.map(this.tabs.filter(".ui-state-disabled"), function(t) { 22773 return e.tabs.index(t) 22774 }))).sort()), 22775 !1 !== this.options.active && this.anchors.length ? this.active = this._findActive(this.options.active) : this.active = c(), 22776 this._refresh(), 22777 this.active.length && this.load(t.active) 22778 }, 22779 _getCreateEventData: function() { 22780 return { 22781 tab: this.active, 22782 panel: this.active.length ? this._getPanelForTab(this.active) : c() 22783 } 22784 }, 22785 _tabKeydown: function(t) { 22786 var e = c(this.document[0].activeElement).closest("li") 22787 , i = this.tabs.index(e) 22788 , n = !0; 22789 if (!this._handlePageNav(t)) { 22790 switch (t.keyCode) { 22791 case c.ui.keyCode.RIGHT: 22792 case c.ui.keyCode.DOWN: 22793 i++; 22794 break; 22795 case c.ui.keyCode.UP: 22796 case c.ui.keyCode.LEFT: 22797 n = !1, 22798 i--; 22799 break; 22800 case c.ui.keyCode.END: 22801 i = this.anchors.length - 1; 22802 break; 22803 case c.ui.keyCode.HOME: 22804 i = 0; 22805 break; 22806 case c.ui.keyCode.SPACE: 22807 return t.preventDefault(), 22808 clearTimeout(this.activating), 22809 void this._activate(i); 22810 case c.ui.keyCode.ENTER: 22811 return t.preventDefault(), 22812 clearTimeout(this.activating), 22813 void this._activate(i !== this.options.active && i); 22814 default: 22815 return 22816 } 22817 t.preventDefault(), 22818 clearTimeout(this.activating), 22819 i = this._focusNextTab(i, n), 22820 t.ctrlKey || (e.attr("aria-selected", "false"), 22821 this.tabs.eq(i).attr("aria-selected", "true"), 22822 this.activating = this._delay(function() { 22823 this.option("active", i) 22824 }, this.delay)) 22825 } 22826 }, 22827 _panelKeydown: function(t) { 22828 this._handlePageNav(t) || t.ctrlKey && t.keyCode === c.ui.keyCode.UP && (t.preventDefault(), 22829 this.active.focus()) 22830 }, 22831 _handlePageNav: function(t) { 22832 return t.altKey && t.keyCode === c.ui.keyCode.PAGE_UP ? (this._activate(this._focusNextTab(this.options.active - 1, !1)), 22833 !0) : t.altKey && t.keyCode === c.ui.keyCode.PAGE_DOWN ? (this._activate(this._focusNextTab(this.options.active + 1, !0)), 22834 !0) : void 0 22835 }, 22836 _findNextTab: function(t, e) { 22837 for (var i = this.tabs.length - 1; -1 !== c.inArray((i < t && (t = 0), 22838 t < 0 && (t = i), 22839 t), this.options.disabled); ) 22840 t = e ? t + 1 : t - 1; 22841 return t 22842 }, 22843 _focusNextTab: function(t, e) { 22844 return t = this._findNextTab(t, e), 22845 this.tabs.eq(t).focus(), 22846 t 22847 }, 22848 _setOption: function(t, e) { 22849 "active" !== t ? "disabled" !== t ? (this._super(t, e), 22850 "collapsible" === t && (this.element.toggleClass("ui-tabs-collapsible", e), 22851 e || !1 !== this.options.active || this._activate(0)), 22852 "event" === t && this._setupEvents(e), 22853 "heightStyle" === t && this._setupHeightStyle(e)) : this._setupDisabled(e) : this._activate(e) 22854 }, 22855 _tabId: function(t) { 22856 return t.attr("aria-controls") || "ui-tabs-" + i() 22857 }, 22858 _sanitizeSelector: function(t) { 22859 return t ? t.replace(/[!"$%&'()*+,.\/:;<=>?@\[\]\^`{|}~]/g, "\\$&") : "" 22860 }, 22861 refresh: function() { 22862 var t = this.options 22863 , e = this.tablist.children(":has(a[href])"); 22864 t.disabled = c.map(e.filter(".ui-state-disabled"), function(t) { 22865 return e.index(t) 22866 }), 22867 this._processTabs(), 22868 !1 !== t.active && this.anchors.length ? this.active.length && !c.contains(this.tablist[0], this.active[0]) ? this.tabs.length === t.disabled.length ? (t.active = !1, 22869 this.active = c()) : this._activate(this._findNextTab(Math.max(0, t.active - 1), !1)) : t.active = this.tabs.index(this.active) : (t.active = !1, 22870 this.active = c()), 22871 this._refresh() 22872 }, 22873 _refresh: function() { 22874 this._setupDisabled(this.options.disabled), 22875 this._setupEvents(this.options.event), 22876 this._setupHeightStyle(this.options.heightStyle), 22877 this.tabs.not(this.active).attr({ 22878 "aria-selected": "false", 22879 tabIndex: -1 22880 }), 22881 this.panels.not(this._getPanelForTab(this.active)).hide().attr({ 22882 "aria-expanded": "false", 22883 "aria-hidden": "true" 22884 }), 22885 this.active.length ? (this.active.addClass("ui-tabs-active ui-state-active").attr({ 22886 "aria-selected": "true", 22887 tabIndex: 0 22888 }), 22889 this._getPanelForTab(this.active).show().attr({ 22890 "aria-expanded": "true", 22891 "aria-hidden": "false" 22892 })) : this.tabs.eq(0).attr("tabIndex", 0) 22893 }, 22894 _processTabs: function() { 22895 var l = this; 22896 this.tablist = this._getList().addClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all").attr("role", "tablist"), 22897 this.tabs = this.tablist.find("> li:has(a[href])").addClass("ui-state-default ui-corner-top").attr({ 22898 role: "tab", 22899 tabIndex: -1 22900 }), 22901 this.anchors = this.tabs.map(function() { 22902 return c("a", this)[0] 22903 }).addClass("ui-tabs-anchor").attr({ 22904 role: "presentation", 22905 tabIndex: -1 22906 }), 22907 this.panels = c(), 22908 this.anchors.each(function(t, e) { 22909 var i, n, s, o = c(e).uniqueId().attr("id"), r = c(e).closest("li"), a = r.attr("aria-controls"); 22910 u(e) ? (i = e.hash, 22911 n = l.element.find(l._sanitizeSelector(i))) : (i = "#" + (s = l._tabId(r)), 22912 (n = l.element.find(i)).length || (n = l._createPanel(s)).insertAfter(l.panels[t - 1] || l.tablist), 22913 n.attr("aria-live", "polite")), 22914 n.length && (l.panels = l.panels.add(n)), 22915 a && r.data("ui-tabs-aria-controls", a), 22916 r.attr({ 22917 "aria-controls": i.substring(1), 22918 "aria-labelledby": o 22919 }), 22920 n.attr("aria-labelledby", o) 22921 }), 22922 this.panels.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom").attr("role", "tabpanel") 22923 }, 22924 _getList: function() { 22925 return this.element.find("ol,ul").eq(0) 22926 }, 22927 _createPanel: function(t) { 22928 return c("<div>").attr("id", t).addClass("ui-tabs-panel ui-widget-content ui-corner-bottom").data("ui-tabs-destroy", !0) 22929 }, 22930 _setupDisabled: function(t) { 22931 c.isArray(t) && (t.length ? t.length === this.anchors.length && (t = !0) : t = !1); 22932 for (var e, i = 0; e = this.tabs[i]; i++) 22933 !0 === t || -1 !== c.inArray(i, t) ? c(e).addClass("ui-state-disabled").attr("aria-disabled", "true") : c(e).removeClass("ui-state-disabled").removeAttr("aria-disabled"); 22934 this.options.disabled = t 22935 }, 22936 _setupEvents: function(t) { 22937 var i = { 22938 click: function(t) { 22939 t.preventDefault() 22940 } 22941 }; 22942 t && c.each(t.split(" "), function(t, e) { 22943 i[e] = "_eventHandler" 22944 }), 22945 this._off(this.anchors.add(this.tabs).add(this.panels)), 22946 this._on(this.anchors, i), 22947 this._on(this.tabs, { 22948 keydown: "_tabKeydown" 22949 }), 22950 this._on(this.panels, { 22951 keydown: "_panelKeydown" 22952 }), 22953 this._focusable(this.tabs), 22954 this._hoverable(this.tabs) 22955 }, 22956 _setupHeightStyle: function(t) { 22957 var i, e, n = this.element.parent(); 22958 "fill" === t ? (c.support.minHeight || (e = n.css("overflow"), 22959 n.css("overflow", "hidden")), 22960 i = n.height(), 22961 this.element.siblings(":visible").each(function() { 22962 var t = c(this) 22963 , e = t.css("position"); 22964 "absolute" !== e && "fixed" !== e && (i -= t.outerHeight(!0)) 22965 }), 22966 e && n.css("overflow", e), 22967 this.element.children().not(this.panels).each(function() { 22968 i -= c(this).outerHeight(!0) 22969 }), 22970 this.panels.each(function() { 22971 c(this).height(Math.max(0, i - c(this).innerHeight() + c(this).height())) 22972 }).css("overflow", "auto")) : "auto" === t && (i = 0, 22973 this.panels.each(function() { 22974 i = Math.max(i, c(this).height("").height()) 22975 }).height(i)) 22976 }, 22977 _eventHandler: function(t) { 22978 var e = this.options 22979 , i = this.active 22980 , n = c(t.currentTarget).closest("li") 22981 , s = n[0] === i[0] 22982 , o = s && e.collapsible 22983 , r = o ? c() : this._getPanelForTab(n) 22984 , a = i.length ? this._getPanelForTab(i) : c() 22985 , l = { 22986 oldTab: i, 22987 oldPanel: a, 22988 newTab: o ? c() : n, 22989 newPanel: r 22990 }; 22991 t.preventDefault(), 22992 n.hasClass("ui-state-disabled") || n.hasClass("ui-tabs-loading") || this.running || s && !e.collapsible || !1 === this._trigger("beforeActivate", t, l) || (e.active = !o && this.tabs.index(n), 22993 this.active = s ? c() : n, 22994 this.xhr && this.xhr.abort(), 22995 a.length || r.length || c.error("jQuery UI Tabs: Mismatching fragment identifier."), 22996 r.length && this.load(this.tabs.index(n), t), 22997 this._toggle(t, l)) 22998 }, 22999 _toggle: function(t, e) { 23000 function i() { 23001 s.running = !1, 23002 s._trigger("activate", t, e) 23003 } 23004 function n() { 23005 e.newTab.closest("li").addClass("ui-tabs-active ui-state-active"), 23006 o.length && s.options.show ? s._show(o, s.options.show, i) : (o.show(), 23007 i()) 23008 } 23009 var s = this 23010 , o = e.newPanel 23011 , r = e.oldPanel; 23012 this.running = !0, 23013 r.length && this.options.hide ? this._hide(r, this.options.hide, function() { 23014 e.oldTab.closest("li").removeClass("ui-tabs-active ui-state-active"), 23015 n() 23016 }) : (e.oldTab.closest("li").removeClass("ui-tabs-active ui-state-active"), 23017 r.hide(), 23018 n()), 23019 r.attr({ 23020 "aria-expanded": "false", 23021 "aria-hidden": "true" 23022 }), 23023 e.oldTab.attr("aria-selected", "false"), 23024 o.length && r.length ? e.oldTab.attr("tabIndex", -1) : o.length && this.tabs.filter(function() { 23025 return 0 === c(this).attr("tabIndex") 23026 }).attr("tabIndex", -1), 23027 o.attr({ 23028 "aria-expanded": "true", 23029 "aria-hidden": "false" 23030 }), 23031 e.newTab.attr({ 23032 "aria-selected": "true", 23033 tabIndex: 0 23034 }) 23035 }, 23036 _activate: function(t) { 23037 var e, i = this._findActive(t); 23038 i[0] !== this.active[0] && (i.length || (i = this.active), 23039 e = i.find(".ui-tabs-anchor")[0], 23040 this._eventHandler({ 23041 target: e, 23042 currentTarget: e, 23043 preventDefault: c.noop 23044 })) 23045 }, 23046 _findActive: function(t) { 23047 return !1 === t ? c() : this.tabs.eq(t) 23048 }, 23049 _getIndex: function(t) { 23050 return "string" == typeof t && (t = this.anchors.index(this.anchors.filter("[href$='" + t + "']"))), 23051 t 23052 }, 23053 _destroy: function() { 23054 this.xhr && this.xhr.abort(), 23055 this.element.removeClass("ui-tabs ui-widget ui-widget-content ui-corner-all ui-tabs-collapsible"), 23056 this.tablist.removeClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all").removeAttr("role"), 23057 this.anchors.removeClass("ui-tabs-anchor").removeAttr("role").removeAttr("tabIndex").removeData("href.tabs").removeData("load.tabs").removeUniqueId(), 23058 this.tabs.add(this.panels).each(function() { 23059 c.data(this, "ui-tabs-destroy") ? c(this).remove() : c(this).removeClass("ui-state-default ui-state-active ui-state-disabled ui-corner-top ui-corner-bottom ui-widget-content ui-tabs-active ui-tabs-panel").removeAttr("tabIndex").removeAttr("aria-live").removeAttr("aria-busy").removeAttr("aria-selected").removeAttr("aria-labelledby").removeAttr("aria-hidden").removeAttr("aria-expanded").removeAttr("role") 23060 }), 23061 this.tabs.each(function() { 23062 var t = c(this) 23063 , e = t.data("ui-tabs-aria-controls"); 23064 e ? t.attr("aria-controls", e) : t.removeAttr("aria-controls") 23065 }), 23066 "content" !== this.options.heightStyle && this.panels.css("height", "") 23067 }, 23068 enable: function(i) { 23069 var t = this.options.disabled; 23070 !1 !== t && (i === l ? t = !1 : (i = this._getIndex(i), 23071 t = c.isArray(t) ? c.map(t, function(t) { 23072 return t !== i ? t : null 23073 }) : c.map(this.tabs, function(t, e) { 23074 return e !== i ? e : null 23075 })), 23076 this._setupDisabled(t)) 23077 }, 23078 disable: function(t) { 23079 var e = this.options.disabled; 23080 if (!0 !== e) { 23081 if (t === l) 23082 e = !0; 23083 else { 23084 if (t = this._getIndex(t), 23085 -1 !== c.inArray(t, e)) 23086 return; 23087 e = c.isArray(e) ? c.merge([t], e).sort() : [t] 23088 } 23089 this._setupDisabled(e) 23090 } 23091 }, 23092 load: function(t, e) { 23093 t = this._getIndex(t); 23094 var i = this 23095 , n = this.tabs.eq(t) 23096 , s = n.find(".ui-tabs-anchor") 23097 , o = this._getPanelForTab(n) 23098 , r = { 23099 tab: n, 23100 panel: o 23101 }; 23102 u(s[0]) || (this.xhr = c.ajax(this._ajaxSettings(s, e, r)), 23103 this.xhr && "canceled" !== this.xhr.statusText && (n.addClass("ui-tabs-loading"), 23104 o.attr("aria-busy", "true"), 23105 this.xhr.success(function(t) { 23106 setTimeout(function() { 23107 o.html(t), 23108 i._trigger("load", e, r) 23109 }, 1) 23110 }).complete(function(t, e) { 23111 setTimeout(function() { 23112 "abort" === e && i.panels.stop(!1, !0), 23113 n.removeClass("ui-tabs-loading"), 23114 o.removeAttr("aria-busy"), 23115 t === i.xhr && delete i.xhr 23116 }, 1) 23117 }))) 23118 }, 23119 _ajaxSettings: function(t, i, n) { 23120 var s = this; 23121 return { 23122 url: t.attr("href"), 23123 beforeSend: function(t, e) { 23124 return s._trigger("beforeLoad", i, c.extend({ 23125 jqXHR: t, 23126 ajaxSettings: e 23127 }, n)) 23128 } 23129 } 23130 }, 23131 _getPanelForTab: function(t) { 23132 var e = c(t).attr("aria-controls"); 23133 return this.element.find(this._sanitizeSelector("#" + e)) 23134 } 23135 }), 23136 !1 !== c.uiBackCompat && (c.ui.tabs.prototype._ui = function(t, e) { 23137 return { 23138 tab: t, 23139 panel: e, 23140 index: this.anchors.index(t) 23141 } 23142 } 23143 , 23144 c.widget("ui.tabs", c.ui.tabs, { 23145 url: function(t, e) { 23146 this.anchors.eq(t).attr("href", e) 23147 } 23148 }), 23149 c.widget("ui.tabs", c.ui.tabs, { 23150 options: { 23151 ajaxOptions: null, 23152 cache: !1 23153 }, 23154 _create: function() { 23155 this._super(); 23156 var i = this; 23157 this._on({ 23158 tabsbeforeload: function(t, e) { 23159 c.data(e.tab[0], "cache.tabs") ? t.preventDefault() : e.jqXHR.success(function() { 23160 i.options.cache && c.data(e.tab[0], "cache.tabs", !0) 23161 }) 23162 } 23163 }) 23164 }, 23165 _ajaxSettings: function(t, e, i) { 23166 var n = this.options.ajaxOptions; 23167 return c.extend({}, n, { 23168 error: function(t, e) { 23169 try { 23170 n.error(t, e, i.tab.closest("li").index(), i.tab[0]) 23171 } catch (t) {} 23172 } 23173 }, this._superApply(arguments)) 23174 }, 23175 _setOption: function(t, e) { 23176 "cache" === t && !1 === e && this.anchors.removeData("cache.tabs"), 23177 this._super(t, e) 23178 }, 23179 _destroy: function() { 23180 this.anchors.removeData("cache.tabs"), 23181 this._super() 23182 }, 23183 url: function(t) { 23184 this.anchors.eq(t).removeData("cache.tabs"), 23185 this._superApply(arguments) 23186 } 23187 }), 23188 c.widget("ui.tabs", c.ui.tabs, { 23189 abort: function() { 23190 this.xhr && this.xhr.abort() 23191 } 23192 }), 23193 c.widget("ui.tabs", c.ui.tabs, { 23194 options: { 23195 spinner: "<em>Loading…</em>" 23196 }, 23197 _create: function() { 23198 this._super(), 23199 this._on({ 23200 tabsbeforeload: function(t, e) { 23201 if (t.target === this.element[0] && this.options.spinner) { 23202 var i = e.tab.find("span") 23203 , n = i.html(); 23204 i.html(this.options.spinner), 23205 e.jqXHR.complete(function() { 23206 i.html(n) 23207 }) 23208 } 23209 } 23210 }
23210) 23211 } 23212 }), 23213 c.widget("ui.tabs", c.ui.tabs, { 23214 options: { 23215 enable: null, 23216 disable: null 23217 }, 23218 enable: function(t) { 23219 var e, i = this.options; 23220 (t && !0 === i.disabled || c.isArray(i.disabled) && -1 !== c.inArray(t, i.disabled)) && (e = !0), 23221 this._superApply(arguments), 23222 e && this._trigger("enable", null, this._ui(this.anchors[t], this.panels[t])) 23223 }, 23224 disable: function(t) { 23225 var e, i = this.options; 23226 (t && !1 === i.disabled || c.isArray(i.disabled) && -1 === c.inArray(t, i.disabled)) && (e = !0), 23227 this._superApply(arguments), 23228 e && this._trigger("disable", null, this._ui(this.anchors[t], this.panels[t])) 23229 } 23230 }), 23231 c.widget("ui.tabs", c.ui.tabs, { 23232 options: { 23233 add: null, 23234 remove: null, 23235 tabTemplate: "<li><a href='#{href}'><span>#{label}</span></a></li>" 23236 }, 23237 add: function(t, e, i) { 23238 i === l && (i = this.anchors.length); 23239 var n, s, o = this.options, r = c(o.tabTemplate.replace(/#\{href\}/g, t).replace(/#\{label\}/g, e)), a = t.indexOf("#") ? this._tabId(r) : t.replace("#", ""); 23240 return r.addClass("ui-state-default ui-corner-top").data("ui-tabs-destroy", !0), 23241 r.attr("aria-controls", a), 23242 n = i >= this.tabs.length, 23243 (s = this.element.find("#" + a)).length || (s = this._createPanel(a), 23244 n ? 0 < i ? s.insertAfter(this.panels.eq(-1)) : s.appendTo(this.element) : s.insertBefore(this.panels[i])), 23245 s.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom").hide(), 23246 n ? r.appendTo(this.tablist) : r.insertBefore(this.tabs[i]), 23247 o.disabled = c.map(o.disabled, function(t) { 23248 return i <= t ? ++t : t 23249 }), 23250 this.refresh(), 23251 1 === this.tabs.length && !1 === o.active && this.option("active", 0), 23252 this._trigger("add", null, this._ui(this.anchors[i], this.panels[i])), 23253 this 23254 }, 23255 remove: function(e) { 23256 e = this._getIndex(e); 23257 var t = this.options 23258 , i = this.tabs.eq(e).remove() 23259 , n = this._getPanelForTab(i).remove(); 23260 return i.hasClass("ui-tabs-active") && 2 < this.anchors.length && this._activate(e + (e + 1 < this.anchors.length ? 1 : -1)), 23261 t.disabled = c.map(c.grep(t.disabled, function(t) { 23262 return t !== e 23263 }), function(t) { 23264 return e <= t ? --t : t 23265 }), 23266 this.refresh(), 23267 this._trigger("remove", null, this._ui(i.find("a")[0], n[0])), 23268 this 23269 } 23270 }), 23271 c.widget("ui.tabs", c.ui.tabs, { 23272 length: function() { 23273 return this.anchors.length 23274 } 23275 }), 23276 c.widget("ui.tabs", c.ui.tabs, { 23277 options: { 23278 idPrefix: "ui-tabs-" 23279 }, 23280 _tabId: function(t) { 23281 var e = t.is("li") ? t.find("a[href]") : t; 23282 return e = e[0], 23283 c(e).closest("li").attr("aria-controls") || e.title && e.title.replace(/\s/g, "_").replace(/[^\w\u00c0-\uFFFF\-]/g, "") || this.options.idPrefix + i() 23284 } 23285 }), 23286 c.widget("ui.tabs", c.ui.tabs, { 23287 options: { 23288 panelTemplate: "<div></div>" 23289 }, 23290 _createPanel: function(t) { 23291 return c(this.options.panelTemplate).attr("id", t).addClass("ui-tabs-panel ui-widget-content ui-corner-bottom").data("ui-tabs-destroy", !0) 23292 } 23293 }), 23294 c.widget("ui.tabs", c.ui.tabs, { 23295 _create: function() { 23296 var t = this.options; 23297 null === t.active && t.selected !== l && (t.active = -1 !== t.selected && t.selected), 23298 this._super(), 23299 t.selected = t.active, 23300 !1 === t.selected && (t.selected = -1) 23301 }, 23302 _setOption: function(t, e) { 23303 if ("selected" !== t) 23304 return this._super(t, e); 23305 var i = this.options; 23306 this._super("active", -1 !== e && e), 23307 i.selected = i.active, 23308 !1 === i.selected && (i.selected = -1) 23309 }, 23310 _eventHandler: function() { 23311 this._superApply(arguments), 23312 this.options.selected = this.options.active, 23313 !1 === this.options.selected && (this.options.selected = -1) 23314 } 23315 }), 23316 c.widget("ui.tabs", c.ui.tabs, { 23317 options: { 23318 show: null, 23319 select: null 23320 }, 23321 _create: function() { 23322 this._super(), 23323 !1 !== this.options.active && this._trigger("show", null, this._ui(this.active.find(".ui-tabs-anchor")[0], this._getPanelForTab(this.active)[0])) 23324 }, 23325 _trigger: function(t, e, i) { 23326 var n = this._superApply(arguments); 23327 return !!n && ("beforeActivate" === t && i.newTab.length ? n = this._super("select", e, { 23328 tab: i.newTab.find(".ui-tabs-anchor")[0], 23329 panel: i.newPanel[0], 23330 index: i.newTab.closest("li").index() 23331 }) : "activate" === t && i.newTab.length && (n = this._super("show", e, { 23332 tab: i.newTab.find(".ui-tabs-anchor")[0], 23333 panel: i.newPanel[0], 23334 index: i.newTab.closest("li").index() 23335 })), 23336 n) 23337 } 23338 }), 23339 c.widget("ui.tabs", c.ui.tabs, { 23340 select: function(t) { 23341 if (-1 === (t = this._getIndex(t))) { 23342 if (!this.options.collapsible || -1 === this.options.selected) 23343 return; 23344 t = this.options.selected 23345 } 23346 this.anchors.eq(t).trigger(this.options.event + this.eventNamespace) 23347 } 23348 }), 23349 n = 0, 23350 c.widget("ui.tabs", c.ui.tabs, { 23351 options: { 23352 cookie: null 23353 }, 23354 _create: function() { 23355 var t, e = this.options; 23356 null == e.active && e.cookie && (-1 === (t = parseInt(this._cookie(), 10)) && (t = !1), 23357 e.active = t), 23358 this._super() 23359 }, 23360 _cookie: function(t) { 23361 var e = [this.cookie || (this.cookie = this.options.cookie.name || "ui-tabs-" + ++n)]; 23362 return arguments.length && (e.push(!1 === t ? -1 : t), 23363 e.push(this.options.cookie)), 23364 c.cookie.apply(null, e) 23365 }, 23366 _refresh: function() { 23367 this._super(), 23368 this.options.cookie && this._cookie(this.options.active, this.options.cookie) 23369 }, 23370 _eventHandler: function() { 23371 this._superApply(arguments), 23372 this.options.cookie && this._cookie(this.options.active, this.options.cookie) 23373 }, 23374 _destroy: function() { 23375 this._super(), 23376 this.options.cookie && this._cookie(null, this.options.cookie) 23377 } 23378 }), 23379 c.widget("ui.tabs", c.ui.tabs, { 23380 _trigger: function(t, e, i) { 23381 var n = c.extend({}, i); 23382 return "load" === t && (n.panel = n.panel[0], 23383 n.tab = n.tab.find(".ui-tabs-anchor")[0]), 23384 this._super(t, e, n) 23385 } 23386 }), 23387 c.widget("ui.tabs", c.ui.tabs, { 23388 options: { 23389 fx: null 23390 }, 23391 _getFx: function() { 23392 var t, e, i = this.options.fx; 23393 return i && (c.isArray(i) ? (t = i[0], 23394 e = i[1]) : t = e = i), 23395 i ? { 23396 show: e, 23397 hide: t 23398 } : null 23399 }, 23400 _toggle: function(t, e) { 23401 function i() { 23402 s.running = !1, 23403 s._trigger("activate", t, e) 23404 } 23405 function n() { 23406 e.newTab.closest("li").addClass("ui-tabs-active ui-state-active"), 23407 o.length && a.show ? o.animate(a.show, a.show.duration, function() { 23408 i() 23409 }) : (o.show(), 23410 i()) 23411 } 23412 var s = this 23413 , o = e.newPanel 23414 , r = e.oldPanel 23415 , a = this._getFx(); 23416 if (!a) 23417 return this._super(t, e); 23418 s.running = !0, 23419 r.length && a.hide ? r.animate(a.hide, a.hide.duration, function() { 23420 e.oldTab.closest("li").removeClass("ui-tabs-active ui-state-active"), 23421 n() 23422 }) : (e.oldTab.closest("li").removeClass("ui-tabs-active ui-state-active"), 23423 r.hide(), 23424 n()) 23425 } 23426 })) 23427}(jQuery), 23428function(c) { 23429 var n = 0; 23430 c.widget("ui.tooltip", { 23431 version: "1.9.0", 23432 options: { 23433 content: function() { 23434 return c(this).attr("title") 23435 }, 23436 hide: !0, 23437 items: "[title]", 23438 position: { 23439 my: "left+15 center", 23440 at: "right center", 23441 collision: "flipfit flipfit" 23442 }, 23443 show: !0, 23444 tooltipClass: null, 23445 track: !1, 23446 close: null, 23447 open: null 23448 }, 23449 _create: function() { 23450 this._on({ 23451 mouseover: "open", 23452 focusin: "open" 23453 }), 23454 this.tooltips = {} 23455 }, 23456 _setOption: function(t, e) { 23457 var i = this; 23458 if ("disabled" === t) 23459 return this[e ? "_disable" : "_enable"](), 23460 void (this.options[t] = e); 23461 this._super(t, e), 23462 "content" === t && c.each(this.tooltips, function(t, e) { 23463 i._updateContent(e) 23464 }) 23465 }, 23466 _disable: function() { 23467 var n = this; 23468 c.each(this.tooltips, function(t, e) { 23469 var i = c.Event("blur"); 23470 i.target = i.currentTarget = e[0], 23471 n.close(i, !0) 23472 }), 23473 this.element.find(this.options.items).andSelf().each(function() { 23474 var t = c(this); 23475 t.is("[title]") && t.data("ui-tooltip-title", t.attr("title")).attr("title", "") 23476 }) 23477 }, 23478 _enable: function() { 23479 this.element.find(this.options.items).andSelf().each(function() { 23480 var t = c(this); 23481 t.data("ui-tooltip-title") && t.attr("title", t.data("ui-tooltip-title")) 23482 }) 23483 }, 23484 open: function(t) { 23485 var e = c(t ? t.target : this.element).closest(this.options.items); 23486 if (e.length) { 23487 if (this.options.track && e.data("ui-tooltip-id")) 23488 return this._find(e).position(c.extend({ 23489 of: e 23490 }, this.options.position)), 23491 void this._off(this.document, "mousemove"); 23492 e.attr("title") && e.data("ui-tooltip-title", e.attr("title")), 23493 e.data("tooltip-open", !0), 23494 this._updateContent(e, t) 23495 } 23496 }, 23497 _updateContent: function(e, i) { 23498 var t, n = this.options.content, s = this; 23499 if ("string" == typeof n) 23500 return this._open(i, e, n); 23501 (t = n.call(e[0], function(t) { 23502 e.data("tooltip-open") && s._delay(function() { 23503 this._open(i, e, t) 23504 }) 23505 })) && this._open(i, e, t) 23506 }, 23507 _open: function(t, i, e) { 23508 function n(t) { 23509 o.of = t, 23510 s.position(o) 23511 } 23512 var s, o, r, a, l; 23513 e && ((s = this._find(i)).length ? s.find(".ui-tooltip-content").html(e) : (i.is("[title]") && (t && "mouseover" === t.type ? i.attr("title", "") : i.removeAttr("title")), 23514 s = this._tooltip(i), 23515 r = i, 23516 a = s.attr("id"), 23517 (l = (r.attr("aria-describedby") || "").split(/\s+/)).push(a), 23518 r.data("ui-tooltip-id", a).attr("aria-describedby", c.trim(l.join(" "))), 23519 s.find(".ui-tooltip-content").html(e), 23520 this.options.track && t && /^mouse/.test(t.originalEvent.type) ? (o = c.extend({}, this.options.position), 23521 this._on(this.document, { 23522 mousemove: n 23523 }), 23524 n(t)) : s.position(c.extend({ 23525 of: i 23526 }, this.options.position)), 23527 s.hide(), 23528 this._show(s, this.options.show), 23529 this._trigger("open", t, { 23530 tooltip: s 23531 }), 23532 this._on(i, { 23533 mouseleave: "close", 23534 focusout: "close", 23535 keyup: function(t) { 23536 if (t.keyCode === c.ui.keyCode.ESCAPE) { 23537 var e = c.Event(t); 23538 e.currentTarget = i[0], 23539 this.close(e, !0) 23540 } 23541 } 23542 }))) 23543 }, 23544 close: function(t, e) { 23545 var i, n, s, o, r = this, a = c(t ? t.currentTarget : this.element), l = this._find(a); 23546 this.closing || (!e && t && "focusout" !== t.type && this.document[0].activeElement === a[0] || (a.data("ui-tooltip-title") && a.attr("title", a.data("ui-tooltip-title")), 23547 n = (i = a).data("ui-tooltip-id"), 23548 s = (i.attr("aria-describedby") || "").split(/\s+/), 23549 -1 !== (o = c.inArray(n, s)) && s.splice(o, 1), 23550 i.removeData("ui-tooltip-id"), 23551 (s = c.trim(s.join(" "))) ? i.attr("aria-describedby", s) : i.removeAttr("aria-describedby"), 23552 l.stop(!0), 23553 this._hide(l, this.options.hide, function() { 23554 c(this).remove(), 23555 delete r.tooltips[this.id] 23556 }), 23557 a.removeData("tooltip-open"), 23558 this._off(a, "mouseleave focusout keyup"), 23559 this._off(this.document, "mousemove"), 23560 this.closing = !0, 23561 this._trigger("close", t, { 23562 tooltip: l 23563 }), 23564 this.closing = !1)) 23565 }, 23566 _tooltip: function(t) { 23567 var e = "ui-tooltip-" + n++ 23568 , i = c("<div>").attr({ 23569 id: e, 23570 role: "tooltip" 23571 }).addClass("ui-tooltip ui-widget ui-corner-all ui-widget-content " + (this.options.tooltipClass || "")); 23572 return c("<div>").addClass("ui-tooltip-content").appendTo(i), 23573 i.appendTo(this.document[0].body), 23574 c.fn.bgiframe && i.bgiframe(), 23575 this.tooltips[e] = t, 23576 i 23577 }, 23578 _find: function(t) { 23579 var e = t.data("ui-tooltip-id"); 23580 return e ? c("#" + e) : c() 23581 }, 23582 _destroy: function() { 23583 var n = this; 23584 c.each(this.tooltips, function(t, e) { 23585 var i = c.Event("blur"); 23586 i.target = i.currentTarget = e[0], 23587 n.close(i, !0), 23588 c("#" + t).remove(), 23589 e.data("ui-tooltip-title") && (e.attr("title", e.data("ui-tooltip-title")), 23590 e.removeData("ui-tooltip-title")) 23591 }) 23592 } 23593 }) 23594}(jQuery), 23595function(_, e) { 23596 "use strict"; 23597 var k = function(t) { 23598 return t < 0 ? -1 : 1 23599 } 23600 , C = function(t, e, i, n, s) { 23601 return (t - e) * (s - n) / (i - e) + n 23602 } 23603 , o = "onwheel"in document ? "wheel" : "mousewheel"; 23604 _.widget("vanderlee.coverflow", { 23605 options: { 23606 animateComplete: e, 23607 animateStart: e, 23608 animateStep: e, 23609 density: 1, 23610 duration: "normal", 23611 easing: e, 23612 enableKeyboard: "both", 23613 enableClick: !0, 23614 enableWheel: !0, 23615 index: 0, 23616 innerAngle: -75, 23617 innerCss: e, 23618 innerOffset: 100 / 3, 23619 innerScale: .75, 23620 outerAngle: -30, 23621 outerCss: e, 23622 outerScale: .25, 23623 selectedCss: e, 23624 visible: "density", 23625 width: e, 23626 change: e, 23627 confirm: e, 23628 select: e 23629 }, 23630 _window_handler_resize: null, 23631 _window_handler_keydown: null, 23632 _create: function() { 23633 var t, s = this, e = s._getCovers(), i = e.filter("img").add("img", e).filter(function() { 23634 return !(this.complete || 0 < this.height) 23635 }), n = Math.max.apply(null, e.map(function() { 23636 return _(this).height() 23637 }).get()); 23638 return s.widgetEventPrefix = "vanderlee-coverflow", 23639 s.hovering = !1, 23640 s.pagesize = 1, 23641 s.currentIndex = s.options.index, 23642 s.element.height(n), 23643 i.on(function() { 23644 t = s._getCovers().height(), 23645 n < t && (n = t, 23646 s.element.height(n)) 23647 }), 23648 e.hide(), 23649 this.element.not(":tabbable") && (this.element.attr("tabIndex", -1), 23650 this.element.attr("autofocus") && this.element.focus()), 23651 s.element.on("mousedown tap click", "> *", function(t) { 23652 if (s.options.enableClick) { 23653 var e = s._getCovers().index(this); 23654 e === s.currentIndex ? s._callback("confirm", t) : s._setIndex(e, !0) 23655 } 23656 }), 23657 s.element.on(o, function(t) { 23658 if (s.options.enableWheel) { 23659 var e = 0 < ("deltaY"in (i = t).originalEvent ? 0 - i.originalEvent.deltaY : "wheelDelta"in i.originalEvent ? i.originalEvent.wheelDelta : void 0) ? 1 : -1; 23660 t.preventDefault(), 23661 s._setIndex(s.options.index - e, !0) 23662 } 23663 var i 23664 }), 23665 _.isFunction(s.element.swipe) && s.element.swipe({ 23666 allowPageScroll: "vertical", 23667 swipe: function(t, e, i) { 23668 var n = Math.round(1.25 * ("left" === e ? 1 : "right" === e ? -1 : 0) * s.pagesize * i / s.element.width()); 23669 s._setIndex(s.options.index + n, !0) 23670 } 23671 }), 23672 s._window_handler_resize = function() { 23673 s.refresh() 23674 } 23675 , 23676 _(window).on("resize", s._window_handler_resize), 23677 s._window_handler_keydown = function(t) { 23678 if (0 <= _.inArray(s.options.enableKeyboard, [!0, "both", "focus"]) && s.element.is(":focus") || 0 <= (0 <= _.inArray(s.options.enableKeyboard, [!0, "both", "hover"])) && s.element.is(":hover")) 23679 switch (t.which) { 23680 case 36: 23681 t.preventDefault(), 23682 s._setIndex(0, !0); 23683 break; 23684 case 35: 23685 t.preventDefault(), 23686 s._setIndex(s._getCovers().length - 1, !0); 23687 break; 23688 case 38: 23689 case 37: 23690 t.preventDefault(), 23691 s._setIndex(s.options.index - 1, !0); 23692 break; 23693 case 40: 23694 case 39: 23695 t.preventDefault(), 23696 s._setIndex(s.options.index + 1, !0); 23697 break; 23698 case 33: 23699 t.preventDefault(), 23700 s._setIndex(s.options.index - s.pagesize, !0); 23701 break; 23702 case 34: 23703
23703t.preventDefault(), 23704 s._setIndex(s.options.index + s.pagesize, !0) 23705 } 23706 } 23707 , 23708 _(window).on("keydown", s._window_handler_keydown), 23709 s._setIndex(s.options.index, !1, !0), 23710 s 23711 }, 23712 _destroy: function() { 23713 _(window).off("resize", this._window_handler_resize), 23714 _(window).off("keydown", this._window_handler_keydown), 23715 this.element.height("") 23716 }, 23717 cover: function() { 23718 return _(this._getCovers()[this.options.index]) 23719 }, 23720 _getCovers: function() { 23721 return _("> *", this.element) 23722 }, 23723 _setIndex: function(t, e, i) { 23724 var n = this 23725 , s = n._getCovers(); 23726 if ((t = Math.max(0, Math.min(t, s.length - 1))) !== n.options.index) 23727 if (s.css("position", "absolute"), 23728 this._frame(n.options.index), 23729 !0 === e || 0 === n.options.duration) { 23730 n.options.index = Math.round(t); 23731 var o = "number" == typeof n.options.duration ? n.options.duration : jQuery.fx.speeds[n.options.duration] || jQuery.fx.speeds._default; 23732 this.refresh(o, n.options.index) 23733 } else 23734 n.options.index = Math.round(t), 23735 n.refresh(0); 23736 else 23737 !0 === i && (n.refresh(), 23738 n._callback("select")) 23739 }, 23740 _callback: function(t, e) { 23741 this._trigger(t, e, [this._getCovers().get(this.currentIndex), this.currentIndex]) 23742 }, 23743 index: function(t) { 23744 if (t === e) 23745 return this.options.index; 23746 for (; t < 0; ) 23747 t += this._getCovers().length; 23748 this._setIndex(t, !0) 23749 }, 23750 _frame: function(g) { 23751 g = g.toFixed(6); 23752 var m = this 23753 , t = m._getCovers() 23754 , v = t.length 23755 , y = m.element.innerWidth() 23756 , e = m.options.width || t.eq(this.options.index).show().get(0).offsetWidth 23757 , b = "density" === m.options.visible ? Math.round(y * m.options.density / e) : _.isNumeric(m.options.visible) ? m.options.visible : v 23758 , w = m.element.position().left - (1 - m.options.outerScale) * e * .5 23759 , x = .5 * (y - m.options.outerScale * e); 23760 m.pagesize = b, 23761 t.removeClass("current").each(function(t, e) { 23762 var i, n = _(e), s = t - g, o = Math.min(Math.max(-1, s / b), 1), r = 0 == s, a = v - Math.abs(Math.round(s)), l = Math.abs(s) <= b, c = Math.sin(o * Math.PI * .5), u = Math.cos(o * Math.PI * .5), h = k(c) * C(Math.abs(c), 0, 1, m.options.innerOffset * m.options.density, x), d = l ? C(Math.abs(u), 1, 0, m.options.innerScale, m.options.outerScale) : 0, p = k(c) * C(Math.abs(c), 0, 1, m.options.innerAngle, m.options.outerAngle), f = r ? m.options.selectedCss || {} : _.interpolate && m.options.outerCss && !_.isEmptyObject(m.options.outerCss) ? l ? _.interpolate(m.options.innerCss || {}, m.options.outerCss, Math.abs(c)) : m.options.outerCss : {}; 23763 Math.abs(s) < 1 && (p = 0 - (0 - p) * Math.abs(s), 23764 d = 1 - (1 - d) * Math.abs(s), 23765 h = 0 - (0 - h) * Math.abs(s)), 23766 i = "scale(" + d + "," + d + ") perspective(" + .5 * y + "px) rotateY(" + p + "deg)", 23767 n[r ? "addClass" : "removeClass"]("current"), 23768 n[l ? "show" : "hide"](), 23769 n.css(_.extend(f, { 23770 left: w + x + h, 23771 "z-index": a, 23772 "-webkit-transform": i, 23773 "-ms-transform": i, 23774 transform: i 23775 })), 23776 m._trigger("animateStep", null, [e, o, l, r, c, u]), 23777 g == m.options.index && m._trigger("animateComplete", null, [e, o, l, r, c, u]) 23778 }) 23779 }, 23780 refresh: function(t, e) { 23781 var i = this 23782 , n = i.currentIndex 23783 , s = i._getCovers() 23784 , o = s.length 23785 , r = !1; 23786 i._callback("before"), 23787 s.css("position", "absolute"), 23788 i.element.stop().animate({ 23789 __coverflow_frame: e || i.options.index 23790 }, { 23791 easing: i.options.easing, 23792 duration: t || 0, 23793 step: function(t) { 23794 i._frame(t), 23795 i.currentIndex = Math.max(0, Math.min(Math.round(t), o - 1)), 23796 n !== i.currentIndex && (n = i.currentIndex, 23797 i._callback("change"), 23798 i.currentIndex === i.options.index && (r = !0)) 23799 }, 23800 complete: function() { 23801 i.currentIndex = i.options.index, 23802 i._callback("after"), 23803 r || i._callback("change"), 23804 i._callback("select") 23805 } 23806 }) 23807 } 23808 }) 23809}(jQuery), 23810function(r) { 23811 r.fn.interpolate = function(t, e, i, n) { 23812 var s = this; 23813 return r.isPlainObject(t) ? (n = i || "linear", 23814 i = r.isNumeric(e) ? e : .5, 23815 r.each(t, function(t, e) { 23816 r.each(s, function() { 23817 r.Tween(this, { 23818 duration: 1 23819 }, t, e, n).run(i) 23820 }) 23821 })) : (i = r.isNumeric(i) ? i : .5, 23822 r.each(s, function() { 23823 r.Tween(this[0], { 23824 duration: 1 23825 }, t, e, n || "linear").run(i) 23826 })), 23827 this 23828 } 23829 , 23830 r.interpolate = function(t, e, i, n) {
23831 var s = r("<span/>") 23832 , o = r.extend({}, t); 23833 return s.css(o).interpolate(e, i, n), 23834 r.each(e, function(t) { 23835 o[t] = s.css(t) 23836 }), 23837 o 23838 } 23839}(jQuery), 23840function(t) { 23841 "function" == typeof define && define.amd && define.amd.jQuery ? define(["jquery"], t) : "undefined" != typeof module && module.exports ? t(require("jquery")) : t(jQuery) 23842}(function(at) { 23843 function n(i) { 23844 return !i || void 0 !== i.allowPageScroll || void 0 === i.swipe && void 0 === i.swipeStatus || (i.allowPageScroll = ft), 23845 void 0 !== i.click && void 0 === i.tap && (i.tap = i.click), 23846 i || (i = {}), 23847 i = at.extend({}, at.fn.swipe.defaults, i), 23848 this.each(function() { 23849 var t = at(this) 23850 , e = t.data(At); 23851 e || (e = new function(t, m) { 23852 function e(t) { 23853 if (!0 !== K.data(At + "_intouch") && !(0 < at(t.target).closest(m.excludedElements, K).length)) { 23854 var e, i, n = t.originalEvent ? t.originalEvent : t, s = n.touches, o = s ? s[0] : n; 23855 return G = St, 23856 s ? Z = s.length : !1 !== m.preventDefaultEvents && t.preventDefault(), 23857 V = F = R = null, 23858 Y = 1, 23859 X = q = B = Q = W = 0, 23860 (i = {})[lt] = E(lt), 23861 i[ct] = E(ct), 23862 i[ut] = E(ut), 23863 i[ht] = E(ht), 23864 U = i, 23865 k(), 23866 T(0, o), 23867 !s || Z === m.fingers || m.fingers === kt || b() ? (tt = j(), 23868 2 == Z && (T(1, s[1]), 23869 B = q = D(J[0].start, J[1].start)), 23870 (m.swipeStatus || m.pinchStatus) && (e = y(n, G))) : e = !1, 23871 !1 === e ? (y(n, G = Pt), 23872 e) : (m.hold && (rt = setTimeout(at.proxy(function() { 23873 K.trigger("hold", [n.target]), 23874 m.hold && (e = m.hold.call(K, n, n.target)) 23875 }, this), m.longTapThreshold)), 23876 S(!0), 23877 null) 23878 } 23879 } 23880 function i(t) { 23881 var e = t.originalEvent ? t.originalEvent : t; 23882 if (G !== It && G !== Pt && !C()) { 23883 var i, n, s, o, r, a, l, c, u, h = e.touches, d = h ? h[0] : e, p = I(d); 23884 if (et = j(), 23885 h && (Z = h.length), 23886 m.hold && clearTimeout(rt), 23887 G = Tt, 23888 2 == Z && (0 == B ? (T(1, h[1]), 23889 B = q = D(J[0].start, J[1].start)) : (I(h[1]), 23890 q = D(J[0].end, J[1].end), 23891 J[0].end, 23892 J[1].end, 23893 V = Y < 1 ? pt : dt), 23894 Y = (q / B * 1).toFixed(2), 23895 X = Math.abs(B - q)), 23896 Z === m.fingers || m.fingers === kt || !h || b()) { 23897 if (R = A(p.start, p.end), 23898 F = A(p.last, p.end), 23899 function(t, e) { 23900 if (!1 === m.preventDefaultEvents) 23901 return; 23902 if (m.allowPageScroll === ft) 23903 t.preventDefault(); 23904 else { 23905 var i = m.allowPageScroll === gt; 23906 switch (e) { 23907 case lt: 23908 (m.swipeLeft && i || !i && m.allowPageScroll != xt) && t.preventDefault(); 23909 break; 23910 case ct: 23911 (m.swipeRight && i || !i && m.allowPageScroll != xt) && t.preventDefault(); 23912 break; 23913 case ut: 23914 (m.swipeUp && i || !i && m.allowPageScroll != _t) && t.preventDefault(); 23915 break; 23916 case ht: 23917 (m.swipeDown && i || !i && m.allowPageScroll != _t) && t.preventDefault() 23918 } 23919 } 23920 }(t, F), 23921 c = p.start, 23922 u = p.end, 23923 W = Math.round(Math.sqrt(Math.pow(u.x - c.x, 2) + Math.pow(u.y - c.y, 2))), 23924 Q = M(), 23925 a = R, 23926 l = W, 23927 l = Math.max(l, P(a)), 23928 U[a].distance = l, 23929 i = y(e, G), 23930 !m.triggerOnTouchEnd || m.triggerOnTouchLeave) { 23931 var f = !0; 23932 if (m.triggerOnTouchLeave) { 23933 var g = { 23934 left: (r = (o = at(o = this)).offset()).left, 23935 right: r.left + o.outerWidth(), 23936 top: r.top, 23937 bottom: r.top + o.outerHeight() 23938 }; 23939 n = p.end, 23940 s = g, 23941 f = n.x > s.left && n.x < s.right && n.y > s.top && n.y < s.bottom 23942 } 23943 !m.triggerOnTouchEnd && f ? G = v(Tt) : m.triggerOnTouchLeave && !f && (G = v(It)), 23944 G != Pt && G != It || y(e, G) 23945 } 23946 } else 23947 y(e, G = Pt); 23948 !1 === i && y(e, G = Pt) 23949 } 23950 } 23951 function n(t) { 23952 var e, i = t.originalEvent ? t.originalEvent : t, n = i.touches; 23953 if (n) { 23954 if (n.length && !C()) 23955 return e = i, 23956 it = j(), 23957 nt = e.touches.length + 1, 23958 !0; 23959 if (n.length && C()) 23960 return !0 23961 } 23962 return C() && (Z = nt), 23963 et = j(), 23964 Q = M(), 23965 c() || !l() ? y(i, G = Pt) : m.triggerOnTouchEnd || 0 == m.triggerOnTouchEnd && G === Tt ? (!1 !== m.preventDefaultEvents && t.preventDefault(), 23966 y(i, G = It)) : !m.triggerOnTouchEnd && w() ? a(i, G = It, yt) : G === Tt && y(i, G = Pt), 23967 S(!1), 23968 null 23969 } 23970 function s() { 23971 q = B = tt = et = Z = 0, 23972 Y = 1, 23973 k(), 23974 S(!1) 23975 } 23976 function o(t) { 23977 var e = t.originalEvent ? t.originalEvent : t; 23978 m.triggerOnTouchLeave && (G = v(It), 23979 y(e, G)) 23980 } 23981 function r() { 23982 K.unbind(z, e),
23983 K.unbind(H, s), 23984 K.unbind($, i), 23985 K.unbind(L, n), 23986 N && K.unbind(N, o), 23987 S(!1) 23988 } 23989 function v(t) { 23990 var e = t 23991 , i = u() 23992 , n = l() 23993 , s = c(); 23994 return !i || s ? e = Pt : !n || t != Tt || m.triggerOnTouchEnd && !m.triggerOnTouchLeave ? !n && t == It && m.triggerOnTouchLeave && (e = Pt) : e = It, 23995 e 23996 } 23997 function y(t, e) { 23998 var i, n = t.touches; 23999 return (d() && p() || p()) && (i = a(t, e, mt)), 24000 (h() && b() || b()) && !1 !== i && (i = a(t, e, vt)), 24001 _() && x() && !1 !== i ? i = a(t, e, bt) : Q > m.longTapThreshold && W < Ct && m.longTap && !1 !== i ? i = a(t, e, wt) : 1 !== Z && Et || !(isNaN(W) || W < m.threshold) || !w() || !1 === i || (i = a(t, e, yt)), 24002 e === Pt && (p() && (i = a(t, e, mt)), 24003 b() && (i = a(t, e, vt)), 24004 s()), 24005 e === It && (n && n.length || s()), 24006 i 24007 } 24008 function a(t, e, i) { 24009 var n; 24010 if (i == mt) { 24011 if (K.trigger("swipeStatus", [e, R || null, W || 0, Q || 0, Z, J, F]), 24012 m.swipeStatus && !1 === (n = m.swipeStatus.call(K, t, e, R || null, W || 0, Q || 0, Z, J, F))) 24013 return !1; 24014 if (e == It && d()) { 24015 if (clearTimeout(ot), 24016 clearTimeout(rt), 24017 K.trigger("swipe", [R, W, Q, Z, J, F]), 24018 m.swipe && !1 === (n = m.swipe.call(K, t, R, W, Q, Z, J, F))) 24019 return !1; 24020 switch (R) { 24021 case lt: 24022 K.trigger("swipeLeft", [R, W, Q, Z, J, F]), 24023 m.swipeLeft && (n = m.swipeLeft.call(K, t, R, W, Q, Z, J, F)); 24024 break; 24025 case ct: 24026 K.trigger("swipeRight", [R, W, Q, Z, J, F]), 24027 m.swipeRight && (n = m.swipeRight.call(K, t, R, W, Q, Z, J, F)); 24028 break; 24029 case ut: 24030 K.trigger("swipeUp", [R, W, Q, Z, J, F]), 24031 m.swipeUp && (n = m.swipeUp.call(K, t, R, W, Q, Z, J, F)); 24032 break; 24033 case ht: 24034 K.trigger("swipeDown", [R, W, Q, Z, J, F]), 24035 m.swipeDown && (n = m.swipeDown.call(K, t, R, W, Q, Z, J, F)) 24036 } 24037 } 24038 } 24039 if (i == vt) { 24040 if (K.trigger("pinchStatus", [e, V || null, X || 0, Q || 0, Z, Y, J]), 24041 m.pinchStatus && !1 === (n = m.pinchStatus.call(K, t, e, V || null, X || 0, Q || 0, Z, Y, J))) 24042 return !1; 24043 if (e == It && h()) 24044 switch (V) { 24045 case dt: 24046 K.trigger("pinchIn", [V || null, X || 0, Q || 0, Z, Y, J]), 24047 m.pinchIn && (n = m.pinchIn.call(K, t, V || null, X || 0, Q || 0, Z, Y, J)); 24048 break; 24049 case pt: 24050 K.trigger("pinchOut", [V || null, X || 0, Q || 0, Z, Y, J]), 24051 m.pinchOut && (n = m.pinchOut.call(K, t, V || null, X || 0, Q || 0, Z, Y, J)) 24052 } 24053 } 24054 return i == yt ? e !== Pt && e !== It || (clearTimeout(ot), 24055 clearTimeout(rt), 24056 x() && !_() ? (st = j(), 24057 ot = setTimeout(at.proxy(function() { 24058 st = null, 24059 K.trigger("tap", [t.target]), 24060 m.tap && (n = m.tap.call(K, t, t.target)) 24061 }, this), m.doubleTapThreshold)) : (st = null, 24062 K.trigger("tap", [t.target]), 24063 m.tap && (n = m.tap.call(K, t, t.target)))) : i == bt ? e !== Pt && e !== It || (clearTimeout(ot), 24064 clearTimeout(rt), 24065 st = null, 24066 K.trigger("doubletap", [t.target]), 24067 m.doubleTap && (n = m.doubleTap.call(K, t, t.target))) : i == wt && (e !== Pt && e !== It || (clearTimeout(ot), 24068 st = null, 24069 K.trigger("longtap", [t.target]), 24070 m.longTap && (n = m.longTap.call(K, t, t.target)))), 24071 n 24072 } 24073 function l() { 24074 var t = !0; 24075 return null !== m.threshold && (t = W >= m.threshold), 24076 t 24077 } 24078 function c() { 24079 var t = !1; 24080 return null !== m.cancelThreshold && null !== R && (t = P(R) - W >= m.cancelThreshold), 24081 t 24082 } 24083 function u() { 24084 return !m.maxTimeThreshold || !(Q >= m.maxTimeThreshold) 24085 } 24086 function h() { 24087 var t = f() 24088 , e = g() 24089 , i = function() { 24090 if (null !== m.pinchThreshold) 24091 return X >= m.pinchThreshold; 24092 return !0 24093 }(); 24094 return t && e && i 24095 } 24096 function b() { 24097 return !!(m.pinchStatus || m.pinchIn || m.pinchOut) 24098 } 24099 function d() { 24100 var t = u() 24101 , e = l() 24102 , i = f() 24103 , n = g() 24104 , s = c() 24105 , o = !s && n && i && e && t; 24106 return o 24107 } 24108 function p() { 24109 return !!(m.swipe || m.swipeStatus || m.swipeLeft || m.swipeRight || m.swipeUp || m.swipeDown) 24110 } 24111 function f() { 24112 return Z === m.fingers || m.fingers === kt || !Et 24113 } 24114 function g() { 24115 return 0 !== J[0].end.x 24116 } 24117 function w() { 24118 return !!m.tap 24119 } 24120 function x() { 24121 return !!m.doubleTap 24122 } 24123 function _() { 24124 if (null == st) 24125 return !1; 24126 var t = j(); 24127 return x() && t - st <= m.doubleTapThreshold 24128 } 24129 function k() { 24130 nt = it = 0 24131 } 24132 function C() { 24133 var t = !1; 24134 if (it) { 24135 var e = j() - it; 24136 e <= m.fingerReleaseThreshold && (t = !0) 24137 } 24138 return t 24139 } 24140 function S(t) { 24141 K && (!0 === t ? (K.bind($, i), 24142 K.bind(L, n), 24143 N && K.bind(N, o)) : (K.unbind($, i, !1), 24144 K.unbind(L, n, !1), 24145 N && K.unbind(N, o, !1)), 24146 K.data(At + "_intouch", !0 === t)) 24147 } 24148 function T(t, e) { 24149 var i = { 24150 start: { 24151 x: 0, 24152 y: 0 24153 }, 24154 last: { 24155 x: 0, 24156 y: 0 24157 }, 24158 end: { 24159 x: 0, 24160 y: 0 24161 } 24162 };
24163 return i.start.x = i.last.x = i.end.x = e.pageX || e.clientX, 24164 i.start.y = i.last.y = i.end.y = e.pageY || e.clientY, 24165 J[t] = i 24166 } 24167 function I(t) { 24168 var e = void 0 !== t.identifier ? t.identifier : 0 24169 , i = J[e] || null; 24170 return null === i && (i = T(e, t)), 24171 i.last.x = i.end.x, 24172 i.last.y = i.end.y, 24173 i.end.x = t.pageX || t.clientX, 24174 i.end.y = t.pageY || t.clientY, 24175 i 24176 } 24177 function P(t) { 24178 if (U[t]) 24179 return U[t].distance 24180 } 24181 function E(t) { 24182 return { 24183 direction: t, 24184 distance: 0 24185 } 24186 } 24187 function M() { 24188 return et - tt 24189 } 24190 function D(t, e) { 24191 var i = Math.abs(t.x - e.x) 24192 , n = Math.abs(t.y - e.y); 24193 return Math.round(Math.sqrt(i * i + n * n)) 24194 } 24195 function A(t, e) { 24196 var i = function(t, e) { 24197 var i = t.x - e.x 24198 , n = e.y - t.y 24199 , s = Math.atan2(n, i) 24200 , o = Math.round(180 * s / Math.PI); 24201 o < 0 && (o = 360 - Math.abs(o)); 24202 return o 24203 }(t, e); 24204 return i <= 45 && 0 <= i ? lt : i <= 360 && 315 <= i ? lt : 135 <= i && i <= 225 ? ct : 45 < i && i < 135 ? ht : ut 24205 } 24206 function j() { 24207 var t = new Date; 24208 return t.getTime() 24209 } 24210 var m = at.extend({}, m) 24211 , O = Et || Dt || !m.fallbackToMouseEvents 24212 , z = O ? Dt ? Mt ? "MSPointerDown" : "pointerdown" : "touchstart" : "mousedown" 24213 , $ = O ? Dt ? Mt ? "MSPointerMove" : "pointermove" : "touchmove" : "mousemove" 24214 , L = O ? Dt ? Mt ? "MSPointerUp" : "pointerup" : "touchend" : "mouseup" 24215 , N = O ? Dt ? "mouseleave" : null : "mouseleave" 24216 , H = Dt ? Mt ? "MSPointerCancel" : "pointercancel" : "touchcancel" 24217 , W = 0 24218 , R = null 24219 , F = null 24220 , Q = 0 24221 , B = 0 24222 , q = 0 24223 , Y = 1 24224 , X = 0 24225 , V = 0 24226 , U = null 24227 , K = at(t) 24228 , G = "start" 24229 , Z = 0 24230 , J = {} 24231 , tt = 0 24232 , et = 0 24233 , it = 0 24234 , nt = 0 24235 , st = 0 24236 , ot = null 24237 , rt = null; 24238 try { 24239 K.bind(z, e), 24240 K.bind(H, s) 24241 } catch (t) { 24242 at.error("events not supported " + z + "," + H + " on jQuery.swipe") 24243 } 24244 this.enable = function() { 24245 return K.bind(z, e), 24246 K.bind(H, s), 24247 K 24248 } 24249 , 24250 this.disable = function() { 24251 return r(), 24252 K 24253 } 24254 , 24255 this.destroy = function() { 24256 r(), 24257 K.data(At, null), 24258 K = null 24259 } 24260 , 24261 this.option = function(t, e) { 24262 if ("object" == typeof t) 24263 m = at.extend(m, t); 24264 else if (void 0 !== m[t]) { 24265 if (void 0 === e) 24266 return m[t]; 24267 m[t] = e 24268 } else { 24269 if (!t) 24270 return m; 24271 at.error("Option " + t + " does not exist on jQuery.swipe.options") 24272 } 24273 return null 24274 } 24275 } 24276 (this,i), 24277 t.data(At, e)) 24278 }) 24279 } 24280 var lt = "left" 24281 , ct = "right" 24282 , ut = "up" 24283 , ht = "down" 24284 , dt = "in" 24285 , pt = "out" 24286 , ft = "none" 24287 , gt = "auto" 24288 , mt = "swipe" 24289 , vt = "pinch" 24290 , yt = "tap" 24291 , bt = "doubletap" 24292 , wt = "longtap" 24293 , xt = "horizontal" 24294 , _t = "vertical" 24295 , kt = "all" 24296 , Ct = 10 24297 , St = "start" 24298 , Tt = "move" 24299 , It = "end" 24300 , Pt = "cancel" 24301 , Et = "ontouchstart"in window 24302 , Mt = window.navigator.msPointerEnabled && !window.navigator.pointerEnabled && !Et 24303 , Dt = (window.navigator.pointerEnabled || window.navigator.msPointerEnabled) && !Et 24304 , At = "TouchSwipe"; 24305 at.fn.swipe = function(t) { 24306 var e = at(this) 24307 , i = e.data(At); 24308 if (i && "string" == typeof t) { 24309 if (i[t]) 24310 return i[t].apply(this, Array.prototype.slice.call(arguments, 1)); 24311 at.error("Method " + t + " does not exist on jQuery.swipe") 24312 } else if (i && "object" == typeof t) 24313 i.option.apply(this, arguments); 24314 else if (!(i || "object" != typeof t && t)) 24315 return n.apply(this, arguments); 24316 return e 24317 } 24318 , 24319 at.fn.swipe.version = "1.6.15", 24320 at.fn.swipe.defaults = { 24321 fingers: 1, 24322 threshold: 75, 24323 cancelThreshold: null, 24324 pinchThreshold: 20, 24325 maxTimeThreshold: null, 24326 fingerReleaseThreshold: 250, 24327 longTapThreshold: 500, 24328 doubleTapThreshold: 200, 24329 swipe: null, 24330 swipeLeft: null, 24331 swipeRight: null, 24332 swipeUp: null, 24333 swipeDown: null, 24334 swipeStatus: null, 24335 pinchIn: null, 24336 pinchOut: null, 24337 pinchStatus: null, 24338 click: null, 24339 tap: null, 24340 doubleTap: null, 24341 longTap: null, 24342 hold: null, 24343 triggerOnTouchEnd: !0, 24344 triggerOnTouchLeave: !1, 24345 allowPageScroll: "auto", 24346 fallbackToMouseEvents: !0, 24347 excludedElements: "label, button, input, select, textarea, a, .noSwipe", 24348 preventDefaultEvents: !0 24349 }, 24350 at.fn.swipe.phases = { 24351 PHASE_START: St, 24352 PHASE_MOVE: Tt, 24353 PHASE_END: It, 24354 PHASE_CANCEL: Pt 24355 }, 24356 at.fn.swipe.directions = { 24357 LEFT: lt, 24358 RIGHT: ct, 24359 UP: ut, 24360 DOWN: ht, 24361 IN: dt, 24362 OUT: pt 24363 }, 24364 at.fn.swipe.pageScroll = { 24365 NONE: ft, 24366 HORIZONTAL: xt, 24367 VERTICAL: _t, 24368 AUTO: gt 24369 }, 24370 at.fn.swipe.fingers = { 24371 ONE: 1, 24372 TWO: 2, 24373 THREE: 3, 24374 FOUR: 4, 24375 FIVE: 5, 24376 ALL: kt 24377 } 24378}), 24379function(c) { 24380 c.fn.extend({ 24381 reflect: function(l) { 24382 return l = c.extend({ 24383 height: 1 / 3, 24384 opacity: .5 24385 }, l), 24386 this.unreflect().each(function() { 24387 function t() { 24388 var t, e, i, n, s, o = a.width, r = a.height; 24389 if (e = Math.floor(1 < l.height ? Math.min(r, l.height) : r * l.height), 24390 (t = c("<canvas />")[0]).getContext) { 24391 n = t.getContext("2d"); 24392 try { 24393 c(t).attr({ 24394 width: o, 24395 height: e 24396 }), 24397 n.save(), 24398 n.translate(0, r - 1), 24399 n.scale(1, -1), 24400 n.drawImage(a, 0, 0, o, r),
24401 n.restore(), 24402 n.globalCompositeOperation = "destination-out", 24403 (s = n.createLinearGradient(0, 0, 0, e)).addColorStop(0, "rgba(255, 255, 255, " + (1 - l.opacity) + ")"), 24404 s.addColorStop(1, "rgba(255, 255, 255, 1.0)"), 24405 n.fillStyle = s, 24406 n.rect(0, 0, o, e), 24407 n.fill() 24408 } catch (t) { 24409 return 24410 } 24411 } else { 24412 if (!window.ActiveXObject) 24413 return; 24414 t = c("<img />").attr("src", a.src).css({ 24415 width: o, 24416 height: r, 24417 marginBottom: e - r, 24418 filter: "FlipV progid:DXImageTransform.Microsoft.Alpha(Opacity=" + 100 * l.opacity + ", FinishOpacity=0, Style=1, StartX=0, StartY=0, FinishX=0, FinishY=" + e / r * 100 + ")" 24419 })[0] 24420 } 24421 c(t).css({ 24422 display: "block", 24423 border: 0 24424 }), 24425 (i = c(/^a$/i.test(a.parentNode.tagName) ? "<span />" : "<div />").insertAfter(a).append([a, t])[0]).className = a.className, 24426 c.data(a, "reflected", i.style.cssText = a.style.cssText), 24427 c(i).css({ 24428 width: o, 24429 height: r + e, 24430 overflow: "hidden" 24431 }), 24432 a.style.cssText = "display: block; border: 0px", 24433 a.className = "reflected" 24434 } 24435 var a = this; 24436 /^img$/i.test(a.tagName) && (a.complete ? t() : c(a).load(t)) 24437 }) 24438 }, 24439 unreflect: function() { 24440 return this.unbind("load").each(function() { 24441 var t, e = c.data(this, "reflected"); 24442 void 0 !== e && (t = this.parentNode, 24443 this.className = t.className, 24444 this.style.cssText = e, 24445 c.removeData(this, "reflected"), 24446 t.parentNode.replaceChild(this, t)) 24447 }) 24448 } 24449 }) 24450}(jQuery), 24451jQuery(function(t) { 24452 t("img.reflect").reflect({}) 24453}); 24454var debugOn = !1, app = app || {}, loading = !1, wheight = jQuery(window).height(), wwidth = jQuery(window).width(), dheight = jQuery(document).height(), dwidth = jQuery(document).width(), s, themeurl = "//" + window.location.host + "/wp-content/themes/bluenote_bluenote/"; 24455app.events = {}, 24456_.extend(app.events, Backbone.Events); 24457var styles = ["background: #000", "border: 2px solid #000", "color: white", "display: block", "text-align: center", "font-weight: bold", "font-size: 14px"].join(";"); 24458console.log("%cð¤ BLUE NOTE - BY THE CREATIVE CORPORATION ð¤", styles), 24459debug("DEBUG MODE IS ON! This will be off when live.", "red"), 24460function(l, r, a) { 24461 function c() { 24462 l(".typed").each(function() { 24463 l(this).typed({ 24464 strings: [l(this).html()], 24465 loop: !1, 24466 typeSpeed: 25, 24467 startDelay: 200 24468 }) 24469 }), 24470 l(".section-title h2").each(function() { 24471 var t = l(this).visible(!1); 24472 l(this).hasClass("anim") ? t || l(this).removeClass("anim") : t && (l(this).addClass("anim"), 24473 l(this).textillate("start")) 24474 }), 24475 l(".counter-value").each(function() { 24476 if (700 < l(r).width()) { 24477 var t = l(this).visible(!1); 24478 if (l(this).hasClass("anim")) 24479 ; 24480 else if (t) { 24481 l(this).addClass("anim"); 24482 var e = parseInt(l(this).attr("data-from")) 24483 , i = parseInt(l(this).attr("data-to")) 24484 , n = parseInt(l(this).attr("data-speed")); 24485 l(this).count(e, i, n) 24486 } 24487 } else { 24488 i = parseInt(l(this).attr("data-to")); 24489 l(this).html(i) 24490 } 24491 }), 24492 l(".sr-animation").each(function() { 24493 if (700 < l(r).width()) { 24494 var t = l(this).visible(!0) 24495 , e = l(this).attr("data-delay"); 24496 e || (e = 0), 24497 l(this).hasClass("animated") || t && l(this).delay(e).queue(function() { 24498 l(this).addClass("animated") 24499 }) 24500 } else 24501 l(this).addClass("animated") 24502 }), 24503 l(".skill").each(function() { 24504 var t = l(this).visible(!0) 24505 , e = l(this).find(".skill-bar .skill-active ").attr("data-perc"); 24506 if (l(this).hasClass("anim")) 24507 ; 24508 else if (t) { 24509 var i = Math.floor(251 * Math.random()) + 50; 24510 l(this).addClass("anim"), 24511 l(this).find(".skill-bar .skill-active ").animate({ 24512 width: e + "%"
24513 }, 2e3, "easeInOutQuart", function() { 24514 l(this).find(".tooltip").delay(i).animate({ 24515 top: "-28px", 24516 opacity: 1 24517 }, 500) 24518 }).css("overflow", "visible") 24519 } 24520 }) 24521 } 24522 function u() { 24523 debug("SLICK: Fix Height", "orange"), 24524 l("#spotlight-slider, #news-slider, #video-slider, #playlist-slider, #product-slider, #release-slider, #artist-slider, #blog-grid").each(function() { 24525 var t = 0 24526 , e = 0; 24527 l(".equal-title", this).each(function() { 24528 l(this).height() > t && (t = l(this).height()) 24529 }), 24530 l(".equal-title", this).height(t), 24531 l(".equal-text", this).each(function() { 24532 l(this).height() > e && (e = l(this).height()) 24533 }), 24534 l(".equal-text", this).height(e) 24535 }) 24536 } 24537 function h() { 24538 debug("MAGNIFIC: Init", "blue"), 24539 l("#page-content").magnificPopup({ 24540 delegate: ".js-photo", 24541 type: "image", 24542 tLoading: "Loading image #%curr%...", 24543 removalDelay: 300, 24544 midClick: !0, 24545 mainClass: "mfp-slide-in", 24546 fixedContentPos: !0, 24547 gallery: { 24548 enabled: !0, 24549 navigateByImgClick: !1, 24550 preload: [0, 1], 24551 arrowMarkup: '<button title="%title%" type="button" class="mfp-nav mfp-nav-%dir%"><i class="mfp-prevent-close fa fa-angle-double-%dir%"></span></button>' 24552 }, 24553 image: { 24554 markup: '<div class="mfp-figure animated fadeInRightQuick"><div class="mfp-img"></div><div class="mfp-bottom-bar"><div class="mfp-title"></div><div class="mfp-counter"></div></div></div>', 24555 tError: '<a href="%url%">The image #%curr%</a> could not be loaded.', 24556 titleSrc: function(t) { 24557 return t.el.attr("title") 24558 } 24559 }, 24560 closeBtnInside: !1, 24561 closeMarkup: '<button title="%title%" class="mfp-close"><i class="fa fa-times"></i></button>' 24562 }); 24563 var t = { 24564 el: null, 24565 onPlayerReady: function(t) { 24566 Modernizr.touch || t.target.playVideo() 24567 }, 24568 onPlayerStateChange: function(t) { 24569 switch (t.data) { 24570 case YT.PlayerState.ENDED: 24571 var i = l.magnificPopup.instance 24572 , e = i.items[(n = i.currItem.index + 1, 24573 s = i.items.length, 24574 s - 1 < n ? n - s : n < 0 ? s + n : n)]; 24575 i.content.find("#mfplayer,h1").removeClass("animated fadeInRight").addClass("animated fadeOutLeft"), 24576 l.ajax({ 24577 url: "https://www.googleapis.com/youtube/v3/videos?id=" + e.el.data("youtube") + "&key=AIzaSyAge_dhlmNzd_sApyywWlcnipExcSZu73Y&part=snippet", 24578 dataType: "jsonp", 24579 success: function(t) { 24580 if (1 === t.items.length) { 24581 var e = ich.video_tpl({ 24582 video: t.items[0].snippet 24583 }); 24584 i.content.prepend(e), 24585 i.content.find(".countdown").countdown(function() { 24586 l.magnificPopup.instance.isOpen && (this.closest(".video-player").remove(), 24587 i.next()) 24588 }, 10, "Next video playing in <span>%duration%</span>") 24589 } 24590 }, 24591 error: function(t, e, i) { 24592 console.log(e, NaN + i) 24593 } 24594 }) 24595 } 24596 var n, s 24597 }, 24598 onPlayerError: function(t) { 24599 console.log(t) 24600 } 24601 }; 24602 l(".js-video").magnificPopup({ 24603 type: "iframe", 24604 iframe: { 24605 markup: '<div class="mfp-iframe-scaler"><div id="mfplayer"></div><h1 class="mfp-title video-title"></h1></div>', 24606 patterns: { 24607 youtube: { 24608 src: "//www.youtube.com/embed/%id%?version=3&rel=0&showinfo=0&enablejsapi=1" 24609 } 24610 } 24611 }, 24612 gallery: { 24613 enabled: !0, 24614 navigateByImgClick: !1, 24615 arrowMarkup: '<button title="%title%" type="button" class="mfp-nav mfp-nav-%dir%"><i class="mfp-prevent-close fa fa-angle-double-%dir%"></span></button>' 24616 }, 24617 mainClass: "fadeIn animated", 24618 removalDelay: 200, 24619 fixedContentPos: !0, 24620 tLoading: "Loading video...", 24621 closeBtnInside: !1, 24622 closeMarkup: '<button title="%title%" class="mfp-close"><i class="fa fa-times"></i></button>', 24623 callbacks: { 24624 open: function() { 24625 t.el = new YT.Player("mfplayer",{ 24626 videoId: this.currItem.el.data("youtube"), 24627 events: { 24628 onReady: t.onPlayerReady, 24629 onStateChange: t.onPlayerStateChange, 24630 onError: t.onPlayerError 24631 } 24632 }) 24633 }, 24634 change: function() { 24635 t.el && t.el.destroy() 24636 }, 24637 afterChange: function() { 24638 this.content.find("#mfplayer,h1").removeClass("fadeOutLeft").addClass("animated fadeInRight"), 24639 t.el = new YT.Player("mfplayer",{ 24640 videoId: this.currItem.el.data("youtube"), 24641 events: { 24642 onReady: t.onPlayerReady, 24643 onStateChange: t.onPlayerStateChange, 24644 onError: t.onPlayerError 24645 } 24646 }) 24647 }, 24648 markupParse: function(t, e, i) { 24649 e.title = i.el.attr("title") 24650 } 24651 } 24652 }) 24653 } 24654 l("#main-nav").fadeOut(0); 24655 setTimeout(function() { 24656 l(".loader-logo").css("opacity", "1") 24657 }, 2e3); 24658 l.fn.countdown = function(t, e, i) { 24659 i = i || "%duration%"; 24660 var n = l(this[0]).html(i.replace("%duration%", e)) 24661 , s = setInterval(function() { 24662 --e ? n.html(i.replace("%duration%", e)) : (clearInterval(s), 24663 t && t.call(n)) 24664 }, 1e3) 24665 } 24666 ; 24667 var t, s = l("#audioPlayer"); 24668 l(function() { 24669 new App.Views.HeaderView, 24670 new App.Views.BodyView, 24671 h() 24672 }), 24673 l(r).load(function() { 24674 function t() { 24675 if (l(".horizontalsection").length) { 24676 var t = l(".horizontalsection").position().left + 1 24677 , e = l(r).width() + 2; 24678 l(".horizontalsection").find(".horizontalinner").css({ 24679 left: "-" + t + "px", 24680 width: e + "px" 24681 }) 24682 } 24683 } 24684 function e() { 24685 var t = l("#menu-responsive").height() + 10; 24686 l("#menu-responsive").animate({ 24687 top: "-" + t + "px" 24688 }, 800, "easeInOutQuart"), 24689 l(".open-responsive-nav span").css({ 24690 "background-position": "-380px 0px" 24691 }) 24692 } 24693 var i; 24694 resetSkrollr(), 24695 l("#main-nav").fadeIn(600), 24696 l(".home a.sr-button.sr-button4.medium-button.sr-buttonicon.scroll-to").click(function() { 24697 return l("html, body").animate({ 24698 scrollTop: wheight - 100 24699 }, 1e3, "easeInOutQuart"), 24700 !1 24701 }), 24702 l(".social a").wrapInner("<span></span>"), 24703 l("#main-nav li.newsletter a").addClass("scroll-to"), 24704 l(".section-title h2").textillate({ 24705 loop: !1, 24706 autoStart: !1, 24707 in: { 24708 effect: "flipInY", 24709 delayScale: .6, 24710 delay: 100, 24711 sync: !1, 24712 shuffle: !1, 24713 reverse: !1, 24714 callback: function() {} 24715 }, 24716 type: "char" 24717 }), 24718 l(".slide-title h1").textillate({ 24719 loop: !1, 24720 autoStart: !1, 24721 in: { 24722 effect: "flipInY", 24723 delayScale: .4, 24724 delay: 100, 24725 sync: !1, 24726 shuffle: !1, 24727 reverse: !1, 24728 callback: function() {} 24729 }, 24730 type: "char" 24731 }), 24732 l(".tracklisting a, .night-to-night").on("click", function() { 24733 l("#page-content").fadeOut(300), 24734 l(".parallax-mirror").fadeOut(300), 24735 l("body").addClass("night") 24736 }), 24737 l("#logo a, .night-to-day").on("click", function() { 24738 l("#page-content").fadeOut(300), 24739 l(".parallax-mirror").fadeOut(300), 24740 l("body").hasClass("night") && (l("body").addClass("day"), 24741 l("body").removeClass("night")) 24742 }), 24743 s.on("click", "#toggle", function() { 24744 return s.toggleClass("closed"), 24745 !1 24746 }), 24747 l(".stream-this").click(function() { 24748 var t = decodeURIComponent(l(this).data("embed")); 24749 return s.find(".inner").html(t).text(), 24750 s.removeClass("closed"), 24751 !1 24752 }), 24753 l(".stream-this-new").click(function() { 24754 var t = decodeURIComponent(l(this).data("embed")) 24755 , e = l(this).data("id"); 24756 l("#stream-player-" + e).find(".inner").html(t).text(), 24757 l("#stream-player-" + e).addClass("active"); 24758 var i = l("#stream-player-" + e + " iframe").attr("src"); 24759 return l("#stream-player-" + e + " iframe").attr("src", i + "&theme=white"), 24760 !1 24761 }), 24762 l(".close-overlay").click(function() { 24763 return l(this).parent().removeClass("active"), 24764 !1 24765 }), 24766 l("#page-loader #loader-blocks").addClass("active"), 24767 l(".slide-title h1").textillate("start"), 24768 l("#page-loader .page-loader-inner").delay(1e3).fadeOut(500, function() { 24769 l("#page-loader").fadeOut(500), 24770 l(".section-title h2").textillate("start") 24771 }), 24772 t(), 24773 l(r).resize(function() { 24774 t(), 24775 u() 24776 }), 24777 i = "body", 24778 l().flexslider && l(i + " .flexslider").flexslider({ 24779 animation: "slide", 24780 slideshowSpeed: 7e3, 24781 animationDuration: 1e3, 24782 slideshow: !0, 24783 directionNav: !1, 24784 controlNav: !0, 24785 smoothHeight: !0, 24786 touch: !0, 24787 video: !0, 24788 randomize: !1 24789 }), 24790 l().isotope && (hookUpLazyLoading(), 24791 l(".masonry").each(function() { 24792 var t = l(this); 24793 t.imagesLoaded(function() { 24794 t.isotope({ 24795 itemSelector: ".masonry-item", 24796 transformsEnabled: !0 24797 }), 24798 l(r).scroll(), 24799 c() 24800 }) 24801 }), 24802 l(".filter li a").click(function() { 24803 l(r).scroll(), 24804 debug("FILTER: Clicked", "lime"); 24805 var t = l(this).parents("ul.filter").data("related-grid"); 24806 l(this).parents("ul.filter").find("li a").removeClass("active"), 24807 l(this).addClass("active"); 24808 var e = l(this).attr("data-option-value"); 24809 return l("#" + t).isotope({ 24810 filter: e 24811 }, function() {}), 24812 setTimeout(function() { 24813 l(r).scroll(), 24814 debug("FILTER: Done", "lime"), 24815 c() 24816 }, 600), 24817 !1 24818 })); 24819 var n = []; 24820 l("nav#main-nav li").each(function(t) { 24821 if (0 < l(this).find("ul").length) { 24822 var e = l(this); 24823 l(this).mouseenter(function() { 24824 n[t] && (clearTimeout(n[t]), 24825 n[t] = null),
24826 n[t] = setTimeout(function() { 24827 l(e).children("ul").fadeIn(200) 24828 }, 150) 24829 }), 24830 l(this).mouseleave(function() { 24831 n[t] && (clearTimeout(n[t]), 24832 n[t] = null), 24833 n[t] = setTimeout(function() { 24834 l(e).children("ul").fadeOut(200) 24835 }, 150) 24836 }) 24837 } 24838 }), 24839 l("nav#main-nav").on("click", "li", function() { 24840 if (l(r).width() < 1025 && 0 < l(this).find("ul").length && "block" !== l(this).find("ul").css("display")) 24841 return l(this).children("ul").fadeIn(200), 24842 !1 24843 }), 24844 l('<a class="open-responsive-nav" href=""><div id="nav-icon3"><span></span><span></span><span></span><span></span></div></a>').appendTo(".header-inner .menu"), 24845 l("#page-content").prepend('<div id="menu-responsive" class=""><div id="menu-responsive-inner"><a href="" class="close-responsive-nav"><span></span></a><nav id="responsive-nav"><ul></ul></nav></div></div>'), 24846 l("nav#responsive-nav > ul").html(l("nav#main-nav > ul > li:not(.social)").clone()), 24847 l("nav#responsive-nav").append(l('<ul class="social-menu"></ul>').append(l("nav#main-nav li.social").clone())), 24848 l("#nav-icon1,#nav-icon2,#nav-icon3,#nav-icon4").click(function() { 24849 l(this).toggleClass("open"), 24850 l("body").toggleClass("menu-open"), 24851 l("html").toggleClass("html-menu-open") 24852 }), 24853 l("header").on("click", ".open-responsive-nav", function() { 24854 var t = l(r).height(); 24855 return l("#menu-responsive").css({ 24856 height: t + "px" 24857 }), 24858 0 == l("#menu-responsive").css("top") || "0px" == l("#menu-responsive").css("top") ? e() : (l("#menu-responsive").animate({ 24859 top: "0" 24860 }, 800, "easeInOutQuart"), 24861 l(".open-responsive-nav span").css({ 24862 "background-position": "-305px 5px" 24863 })), 24864 !1 24865 }), 24866 l("#page-content").on("click", "#menu-responsive", function() { 24867 e() 24868 }), 24869 l("#menu-responsive").on("click", "a", function() { 24870 l("#nav-icon1,#nav-icon2,#nav-icon3,#nav-icon4").click() 24871 }), 24872 l(".toggle-item").each(function() { 24873 l(this).find(".toggle-active").siblings(".toggle-inner").slideDown(300) 24874 }), 24875 l("body").on("click", ".toggle-title", function() { 24876 var t = l(this).parent("div").parent("div") 24877 , e = l(this).parent("div").find(".toggle-inner").css("display"); 24878 return "accordion" == l(t).attr("class") ? "none" !== e ? (l(t).find(".toggle-item .toggle-inner").slideUp(300), 24879 l(this).toggleClass("toggle-active")) : (l(t).find(".toggle-item .toggle-inner").slideUp(300), 24880 l(t).find(".toggle-item .toggle-title").removeClass("toggle-active"), 24881 l(this).toggleClass("toggle-active"), 24882 l(this).siblings(".toggle-inner").slideDown(300)) : (l(this).toggleClass("toggle-active"), 24883 l(this).siblings(".toggle-inner").slideToggle(300)), 24884 !1 24885 }), 24886 l("#backtotop").click(function() { 24887 return l("html, body").animate({ 24888 scrollTop: 0 24889 }, 1e3, "easeInOutQuart"), 24890 !1 24891 }), 24892 l("body").on("mouseenter", ".imgoverlay", function() { 24893 var t = parseInt(l(this).find(".overlayinfo").height() / 2); 24894 l(this).find(".overlayinfo").css({ 24895 marginTop: "-" + t + "px" 24896 }) 24897 }), 24898 l().fitVids && l("body").fitVids({ 24899 ignore: ".slide-video iframe" 24900 }), 24901 l().srParallax && l(".parallax-section").srParallax(), 24902 l().jPlayer && l(".jp-interface").length && l(".jp-interface").each(function() { 24903 var t = l(this).width() - 175; 24904 l(this).find(".jp-progress-container").css({ 24905 width: t + "px" 24906 }) 24907 }), 24908 l().bgVideo && setTimeout(function() { 24909 l(".videobg-section").bgVideo() 24910 }, 1e3), 24911 l().owlCarousel && (l(".portfolio-carousel").owlCarousel({ 24912 navigation: !1, 24913 items: 4, 24914 itemsCustom: !1, 24915 itemsDesktop: [1199, 4], 24916 itemsDesktopSmall: [980, 3], 24917 itemsTablet: [768, 2], 24918 itemsTabletSmall: !1, 24919 itemsMobile: [479, 1] 24920 }), 24921 l("#blog-carousel").owlCarousel({ 24922 navigation: !1, 24923 items: 3, 24924 itemsCustom: !1, 24925 itemsDesktop: [1199, 3], 24926 itemsDesktopSmall: [980, 2], 24927 itemsTablet: [768, 2], 24928 itemsTabletSmall: !1, 24929 itemsMobile: [479, 1] 24930 })), 24931 l().fancybox && l(".openfancybox").fancybox({ 24932 openEffect: "fade", 24933 closeEffect: "fade" 24934 }), 24935 l().perfectScrollbar && l(".scrollbar").perfectScrollbar({ 24936 suppressScrollX: !0 24937 }), 24938 c(), 24939 l(".flip").flip({ 24940 axis: "y", 24941 trigger: "click", 24942 autoSize: !0 24943 }), 24944 l(".flipit").on("click", function(t) { 24945 t.preventDefault(); 24946 var e = l(this).attr("data-album"); 24947 l("#flip-" + e).flip(!0), 24948 console.log(e) 24949 }) 24950 }), 24951 l("a#load-more").on("click", function(t) { 24952 t.preventDefault(), 24953 l(r).scroll() 24954 }), 24955 l(r).scroll(function() { 24956 var i = l("a#load-more") 24957 , t = l(r).scrollTop() 24958 , e = l(a).height() 24959 , n = l(r).height(); 24960 if (!loading && i && .5 < t / (e - n)) { 24961 var s = i.data("query")
24962 , o = l(i.data("container")); 24963 s && (debug("AJAX: Loading more", "purple"), 24964 loading = !0, 24965 s.paged++, 24966 l.post(srvars.ajaxurl, { 24967 action: "load_more", 24968 query: JSON.stringify(s) 24969 }).done(function(t) { 24970 if (t) { 24971 var e = l(t); 24972 o.append(e), 24973 o.hasClass("masonry") && o.isotope("appended", e).imagesLoaded(function() { 24974 o.isotope("layout"), 24975 setTimeout(function() { 24976 e.removeClass("loading"), 24977 app.events.trigger("Skrollr", "reset") 24978 }, 50) 24979 }), 24980 i.data("query", s) 24981 } else 24982 l("a#load-more").remove(); 24983 loading = !1, 24984 debug("AJAX: Loading done", "purple"), 24985 u(), 24986 h() 24987 }).error(function() { 24988 loading = !1 24989 })) 24990 } 24991 c() 24992 }), 24993 l("#intro-slider").slick({ 24994 autoplay: !0, 24995 autoplaySpeed: 7e3, 24996 arrows: !1, 24997 dots: !0, 24998 infinite: !1, 24999 speed: 600, 25000 slidesToShow: 1, 25001 slidesToScroll: 1, 25002 fade: !0 25003 }), 25004 l("#intro-slider").on("beforeChange", function() { 25005 l(".slide-title h1").textillate("start"), 25006 l("#slider-blocks").removeClass("active"), 25007 l("#intro-slider").addClass("active") 25008 }), 25009 l("#intro-slider").on("afterChange", function() { 25010 l("#slider-blocks").addClass("active"), 25011 l("#intro-slider").removeClass("active") 25012 }), 25013 l(".slick").on("init", function() { 25014 debug("SLICK: INIT", "orange"), 25015 l(this).find(".slick-arrow").length ? l(this).removeClass("slick-no-nav") : l(this).addClass("slick-no-nav") 25016 }), 25017 l(".slick").on("breakpoint", function() { 25018 debug("SLICK: Breakpoint", "orange"), 25019 l(this).find(".slick-arrow").length ? l(this).removeClass("slick-no-nav") : l(this).addClass("slick-no-nav") 25020 }), 25021 l("#album-slider").slick({ 25022 dots: !1, 25023 arrows: !1, 25024 infinite: !1, 25025 speed: 300, 25026 slidesToShow: 1, 25027 slidesToScroll: 1, 25028 responsive: [{ 25029 breakpoint: 1024, 25030 settings: { 25031 slidesToShow: 1, 25032 slidesToScroll: 1 25033 } 25034 }, { 25035 breakpoint: 768, 25036 settings: { 25037 slidesToShow: 1, 25038 slidesToScroll: 1 25039 } 25040 }, { 25041 breakpoint: 420, 25042 settings: { 25043 slidesToShow: 1, 25044 slidesToScroll: 1 25045 } 25046 }] 25047 }), 25048 l("#release-titles a").on("click", function(t) { 25049 t.preventDefault(); 25050 var e = l(this).attr("data-id"); 25051 l("#album-slider").slick("slickGoTo", parseInt(e), !1), 25052 l("#release-titles a").removeClass("active"), 25053 l(this).addClass("active") 25054 }), 25055 l("#video-slider").slick({ 25056 dots: !1, 25057 infinite: !1, 25058 speed: 300, 25059 slidesToShow: 1, 25060 slidesToScroll: 1, 25061 responsive: [{ 25062 breakpoint: 1024, 25063 settings: { 25064 slidesToShow: 1, 25065 slidesToScroll: 1 25066 } 25067 }, { 25068 breakpoint: 768, 25069 settings: { 25070 slidesToShow: 1, 25071 slidesToScroll: 1 25072 } 25073 }, { 25074 breakpoint: 420, 25075 settings: { 25076 slidesToShow: 1, 25077 slidesToScroll: 1, 25078 arrows: !1, 25079 dots: !0 25080 } 25081 }] 25082 }), 25083 l("#spotlight-slider").slick({ 25084 dots: !1, 25085 infinite: !1, 25086 speed: 300, 25087 slidesToShow: 1, 25088 slidesToScroll: 1, 25089 responsive: [{ 25090 breakpoint: 1024, 25091 settings: { 25092 slidesToShow: 1, 25093 slidesToScroll: 1 25094 } 25095 }, { 25096 breakpoint: 768, 25097 settings: { 25098 slidesToShow: 1, 25099 slidesToScroll: 1 25100 } 25101 }, { 25102 breakpoint: 420, 25103 settings: { 25104 slidesToShow: 1, 25105 slidesToScroll: 1, 25106 arrows: !1, 25107 dots: !0 25108 } 25109 }] 25110 }), 25111 l("#news-slider").slick({ 25112 arrows: !1, 25113 dots: !1, 25114 infinite: !1, 25115 speed: 300, 25116 slidesToShow: 2, 25117 slidesToScroll: 1, 25118 responsive: [{ 25119 breakpoint: 1024, 25120 settings: { 25121 slidesToShow: 2, 25122 slidesToScroll: 1 25123 } 25124 }, { 25125 breakpoint: 768, 25126 settings: { 25127 slidesToShow: 2, 25128 slidesToScroll: 1 25129 } 25130 }, { 25131 breakpoint: 420, 25132 settings: { 25133 slidesToShow: 1, 25134 slidesToScroll: 1, 25135 arrows: !1, 25136 dots: !0 25137 } 25138 }] 25139 }), 25140 l("#playlist-slider").slick({ 25141 dots: !1, 25142 infinite: !1, 25143 speed: 300, 25144 slidesToShow: 4, 25145 slidesToScroll: 1, 25146 responsive: [{ 25147 breakpoint: 1024, 25148 settings: { 25149 slidesToShow: 4, 25150 slidesToScroll: 1 25151 } 25152 }, {
25153 breakpoint: 769, 25154 settings: { 25155 slidesToShow: 3, 25156 slidesToScroll: 1 25157 } 25158 }, { 25159 breakpoint: 420, 25160 settings: { 25161 slidesToShow: 1, 25162 slidesToScroll: 1, 25163 arrows: !1, 25164 dots: !0 25165 } 25166 }] 25167 }), 25168 l("#photo-slider, #product-slider, #artist-slider, #release-slider").slick({ 25169 dots: !1, 25170 infinite: !1, 25171 speed: 300, 25172 slidesToShow: 3, 25173 slidesToScroll: 3, 25174 responsive: [{ 25175 breakpoint: 1024, 25176 settings: { 25177 slidesToShow: 3, 25178 slidesToScroll: 3 25179 } 25180 }, { 25181 breakpoint: 768, 25182 settings: { 25183 slidesToShow: 3, 25184 slidesToScroll: 1 25185 } 25186 }, { 25187 breakpoint: 420, 25188 settings: { 25189 slidesToShow: 1, 25190 slidesToScroll: 1, 25191 arrows: !1, 25192 dots: !0 25193 } 25194 }] 25195 }); 25196 var e = 0 25197 , i = 5 25198 , n = l("header").outerHeight(); 25199 l(r).scroll(function() { 25200 t = !0 25201 }), 25202 setInterval(function() { 25203 t && (!function() { 25204 var t = l(this).scrollTop(); 25205 Math.abs(e - t) <= i || (e < t && n < t ? l("header").removeClass("nav-down").addClass("nav-up") : t + l(r).height() < l(a).height() && l("header").removeClass("nav-up").addClass("nav-down"), 25206 e = t) 25207 }(), 25208 t = !1) 25209 }, 250), 25210 fireSkrollr(), 25211 u(), 25212 initTimeline = function() { 25213 function s(i) { 25214 var n = l("a#load-more-timeline"); 25215 if (!r && n) { 25216 var s = n.data("query") 25217 , o = l(n.data("container")); 25218 s && (debug("TIMELINE: Loading more", "silver"), 25219 r = !0, 25220 s.paged++, 25221 l.post(srvars.ajaxurl, { 25222 action: "load_more", 25223 query: JSON.stringify(s) 25224 }).done(function(t) { 25225 if (t) { 25226 var e = l(t); 25227 o.append(e), 25228 n.data("query", s) 25229 } else 25230 l("a#load-more").remove(); 25231 debug("TIMELINE: Loading done", "silver"), 25232 l("#timeline").coverflow("refresh"), 25233 debug("re-index"), 25234 debug(r), 25235 a[i] = "loaded", 25236 l.fn.reflect && l("#timeline .cover img").reflect(), 25237 c() 25238 }).error(function() { 25239 r = !1 25240 })) 25241 } 25242 } 25243 debug("TIMELINE: init", "silver"), 25244 l.fn.reflect && l("#timeline .cover img").reflect(); 25245 var r = !1 25246 , a = {} 25247 , t = l("#timeline").attr("data-index"); 25248 t || (t = 20), 25249 l("#timeline").coverflow({ 25250 index: parseInt(t - 1), 25251 density: 2, 25252 innerOffset: 50, 25253 innerScale: .7, 25254 enableWheel: !1, 25255 innerAngle: -20, 25256 outerAngle: -30, 25257 select: function(t, e, i) { 25258 if (debug("TIMELINE: Switch " + i, "silver"), 25259 i % 20 <= 0 && "loaded" != a[i]) 25260 debug("TIMELINE: mod check " + i, "silver"), 25261 s(i); 25262 else { 25263 r = !1; 25264 var n = 20 * Math.floor(i / 20); 25265 1 <= n && "loaded" != a[n] ? (debug("TIMELINE: skip check " + n + "@" + i, "silver"), 25266 s(n)) : setTimeout(function() {}, 300) 25267 } 25268 loadTimelineTitle() 25269 }, 25270 change: function() {} 25271 }), 25272 l("#timeline-prev").on("click", function(t) { 25273 t.preventDefault(); 25274 var e = l("#timeline").coverflow("index"); 25275 l("#timeline").coverflow("index", e - 1) 25276 }), 25277 l("#timeline-next").on("click", function(t) { 25278 t.preventDefault(); 25279 var e = l("#timeline").coverflow("index"); 25280 l("#timeline").coverflow("index", e + 1) 25281 }) 25282 } 25283 , 25284 loadTimelineTitle = function() { 25285 l("#timeline-title .inner").fadeOut(300, function() { 25286 var t = l("#timeline .current .blog-headline").html() 25287 , e = l("#timeline .current").data("released-year") 25288 , i = l("#timeline .current").data("recorded-year") 25289 , n = l("#timeline .current .overlayinfo").html() 25290 , s = ""; 25291 i ? s = " (" + i + ")" : e && (s = " (" + e + ")"), 25292 t && "" != t && "undefined" != t && (l(this).html(t + s), 25293 l("#timeline-title .info").html(decodeURIComponent(l("#timeline .current").data("release-info"))), 25294 l("#timeline-title .buttons").html(n)), 25295 l(this).fadeIn(300) 25296 }) 25297 } 25298 , 25299 initTimeline(), 25300 hookUpLazyLoading = function() { 25301 debug("LAZY: Init", "brown"), 25302 l(".lazy").Lazy({ 25303 threshold: 0, 25304 effect: "fadeIn", 25305 effectTime: 300, 25306 afterLoad: function() { 25307 l("#blog-grid").data("isotope") && l("#blog-grid").isotope("layout"), 25308 debug("LAZY: Rejig", "brown") 25309 }, 25310 onError: function(t) { 25311 console.log("error loading " + t.data("src")) 25312 } 25313 }) 25314 } 25315}(jQuery, window, document);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.