1/* 2@Author: ThemeMascot 3@URL: http://ThemeMascot.com 4 5Necessary jQuery Collection 6*/ 7 8/** 9 * Table of Contents: 10 * 11 * jQuery Cookie Plugin v1.4.1 12 * jquery.easing.1.3.js for piechart smoothness and other 13 * jquery.scrollTo 14 * jquery.localScroll 15 * SmoothScroll for websites 16 * jQuery appear plugin 17 * modernizr 18 * scrollToFixed 19 * Menuzord - Responsive Megamenu 20 * jQuery Isotope 21 * jquery parallax 22 * animateNumbers 23 * jflickrfeed 24 * fitvids 25 * Retina.js 26 * ajaxchimp 27 * tweetie 28 * menufullpage 29 * WOW animation 30 * Typed Animation 31 * Owl carousel 32 * FlexSlider 33 * Magnific Popup 34 * Nivo Lightbox 35 * PrettyPhoto Lightbox 36 * equalHeights 37 * Maximage Slider 38 * BxSlider 39 * moment.js 40 * Clock1 - The Final Countdown 41 * Clock2 - flipclock 42 * instafeed.js 43 * jQuery Validation 44 * jQuery Form 45 * code highlight 46 * YTPlayer 47 * Infinite Scroll 48 * jQuery Pagination Plugin 49 * Vide jQuery plugin for video backgrounds 50 * Datepicker for Bootstrap 51 * jquery-timepicker 52 * bootstrap-datetimejs 53 * datepair.js 54 * easy-pie-chart 55 * jquery.ddslick.min.js 56 * FullCalendar 57 * 58 * 59 * 60 * 61 * 62 * =============================================== 63 */ 64 65 66/*! 67 * jQuery Cookie Plugin v1.4.1 68 * https://github.com/carhartl/jquery-cookie 69 * 70 * Copyright 2006, 2014 Klaus Hartl 71 * Released under the MIT license 72 */ 73! function (e) { 74 "function" == typeof define && define.amd ? define(["jquery"], e) : "object" == typeof exports ? module.exports = e(require("jquery")) : e(jQuery) 75}(function (e) { 76 function n(e) { 77 return u.raw ? e : encodeURIComponent(e) 78 } 79 80 function o(e) { 81 return u.raw ? e : decodeURIComponent(e) 82 } 83 84 function i(e) { 85 return n(u.json ? JSON.stringify(e) : String(e)) 86 } 87 88 function t(e) { 89 0 === e.indexOf('"') && (e = e.slice(1, -1).replace(/\\"/g, '"').replace(/\\\\/g, "\\")); 90 try { 91 return e = decodeURIComponent(e.replace(c, " ")), u.json ? JSON.parse(e) : e 92 } catch (n) { } 93 } 94 95 function r(n, o) { 96 var i = u.raw ? n : t(n); 97 return e.isFunction(o) ? o(i) : i 98 } 99 var c = /\+/g, 100 u = e.cookie = function (t, c, s) { 101 if (arguments.length > 1 && !e.isFunction(c)) { 102 if (s = e.extend({}, u.defaults, s), "number" == typeof s.expires) { 103 var a = s.expires, 104 d = s.expires = new Date; 105 d.setMilliseconds(d.getMilliseconds() + 864e5 * a) 106 } 107 return document.cookie = [n(t), "=", i(c), s.expires ? "; expires=" + s.expires.toUTCString() : "", s.path ? "; path=" + s.path : "", s.domain ? "; domain=" + s.domain : "", s.secure ? "; secure" : ""].join("") 108 } 109 for (var f = t ? void 0 : {}, p = document.cookie ? document.cookie.split("; ") : [], l = 0, m = p.length; m > l; l++) { 110 var x = p[l].split("="), 111 g = o(x.shift()), 112 j = x.join("="); 113 if (t === g) { 114 f = r(j, c); 115 break 116 } 117 t || void 0 === (j = r(j)) || (f[g] = j) 118 } 119 return f 120 }; 121 u.defaults = {}, e.removeCookie = function (n, o) { 122 return e.cookie(n, "", e.extend({}, o, { 123 expires: -1 124 })), !e.cookie(n) 125 } 126}); 127 128 129 130 131/* 132 * jquery.easing.1.3.js for piechart smoothness and other 133 * ----------------------------------------------- 134 */ 135/* 136 * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ 137 * 138 * Uses the built in easing capabilities added In jQuery 1.1 139 * to offer multiple easing options 140 * 141 */ 142jQuery.easing.jswing = jQuery.easing.swing, jQuery.extend(jQuery.easing, { 143 def: "easeOutQuad", 144 swing: function (n, e, t, u, a) { 145 return jQuery.easing[jQuery.easing.def](n, e, t, u, a) 146 }, 147 easeInQuad: function (n, e, t, u, a) { 148 return u * (e /= a) * e + t 149 }, 150 easeOutQuad: function (n, e, t, u, a) { 151 return -u * (e /= a) * (e - 2) + t 152 }, 153 easeInOutQuad: function (n, e, t, u, a) { 154 return (e /= a / 2) < 1 ? u / 2 * e * e + t : -u / 2 * (--e * (e - 2) - 1) + t 155 }, 156 easeInCubic: function (n, e, t, u, a) { 157 return u * (e /= a) * e * e + t 158 }, 159 easeOutCubic: function (n, e, t, u, a) { 160 return u * ((e = e / a - 1) * e * e + 1) + t 161 }, 162 easeInOutCubic: function (n, e, t, u, a) { 163 return (e /= a / 2) < 1 ? u / 2 * e * e * e + t : u / 2 * ((e -= 2) * e * e + 2) + t 164 }, 165 easeInQuart: function (n, e, t, u, a) { 166 return u * (e /= a) * e * e * e + t 167 }, 168 easeOutQuart: function (n, e, t, u, a) { 169 return -u * ((e = e / a - 1) * e * e * e - 1) + t 170 }, 171 easeInOutQuart: function (n, e, t, u, a) { 172 return (e /= a / 2) < 1 ? u / 2 * e * e * e * e + t : -u / 2 * ((e -= 2) * e * e * e - 2) + t 173 }, 174 easeInQuint: function (n, e, t, u, a) { 175 return u * (e /= a) * e * e * e * e + t 176 }, 177 easeOutQuint: function (n, e, t, u, a) { 178 return u * ((e = e / a - 1) * e * e * e * e + 1) + t 179 }, 180 easeInOutQuint: function (n, e, t, u, a) { 181 return (e /= a / 2) < 1 ? u / 2 * e * e * e * e * e + t : u / 2 * ((e -= 2) * e * e * e * e + 2) + t 182 }, 183 easeInSine: function (n, e, t, u, a) { 184 return -u * Math.cos(e / a * (Math.PI / 2)) + u + t 185 }, 186 easeOutSine: function (n, e, t, u, a) { 187 return u * Math.sin(e / a * (Math.PI / 2)) + t 188 }, 189 easeInOutSine: function (n, e, t, u, a) { 190 return -u / 2 * (Math.cos(Math.PI * e / a) - 1) + t 191 }, 192 easeInExpo: function (n, e, t, u, a) { 193 return 0 == e ? t : u * Math.pow(2, 10 * (e / a - 1)) + t 194 }, 195 easeOutExpo: function (n, e, t, u, a) { 196 return e == a ? t + u : u * (-Math.pow(2, -10 * e / a) + 1) + t 197 }, 198 easeInOutExpo: function (n, e, t, u, a) { 199 return 0 == e ? t : e == a ? t + u : (e /= a / 2) < 1 ? u / 2 * Math.pow(2, 10 * (e - 1)) + t : u / 2 * (-Math.pow(2, -10 * --e) + 2) + t 200 }, 201 easeInCirc: function (n, e, t, u, a) { 202 return -u * (Math.sqrt(1 - (e /= a) * e) - 1) + t 203 }, 204 easeOutCirc: function (n, e, t, u, a) { 205 return u * Math.sqrt(1 - (e = e / a - 1) * e) + t 206 }, 207 easeInOutCirc: function (n, e, t, u, a) { 208 return (e /= a / 2) < 1 ? -u / 2 * (Math.sqrt(1 - e * e) - 1) + t : u / 2 * (Math.sqrt(1 - (e -= 2) * e) + 1) + t 209 }, 210 easeInElastic: function (n, e, t, u, a) { 211 var r = 1.70158, 212 i = 0, 213 s = u; 214 if (0 == e) return t; 215 if (1 == (e /= a)) return t + u; 216 if (i || (i = .3 * a), s < Math.abs(u)) { 217 s = u; 218 var r = i / 4 219 } else var r = i / (2 * Math.PI) * Math.asin(u / s); 220 return -(s * Math.pow(2, 10 * (e -= 1)) * Math.sin(2 * (e * a - r) * Math.PI / i)) + t 221 }, 222 easeOutElastic: function (n, e, t, u, a) { 223 var r = 1.70158, 224 i = 0, 225 s = u; 226 if (0 == e) return t; 227 if (1 == (e /= a)) return t + u; 228 if (i || (i = .3 * a), s < Math.abs(u)) { 229 s = u; 230 var r = i / 4 231 } else var r = i / (2 * Math.PI) * Math.asin(u / s); 232 return s * Math.pow(2, -10 * e) * Math.sin(2 * (e * a - r) * Math.PI / i) + u + t 233 }, 234 easeInOutElastic: function (n, e, t, u, a) { 235 var r = 1.70158, 236 i = 0, 237 s = u; 238 if (0 == e) return t; 239 if (2 == (e /= a / 2)) return t + u; 240 if (i || (i = .3 * a * 1.5), s < Math.abs(u)) { 241 s = u; 242 var r = i / 4 243 } else var r = i / (2 * Math.PI) * Math.asin(u / s); 244 return 1 > e ? -.5 * s * Math.pow(2, 10 * (e -= 1)) * Math.sin(2 * (e * a - r) * Math.PI / i) + t : s * Math.pow(2, -10 * (e -= 1)) * Math.sin(2 * (e * a - r) * Math.PI / i) * .5 + u + t 245 }, 246 easeInBack: function (n, e, t, u, a, r) { 247 return void 0 == r && (r = 1.70158), u * (e /= a) * e * ((r + 1) * e - r) + t 248 }, 249 easeOutBack: function (n, e, t, u, a, r) { 250 return void 0 == r && (r = 1.70158), u * ((e = e / a - 1) * e * ((r + 1) * e + r) + 1) + t 251 }, 252 easeInOutBack: function (n, e, t, u, a, r) { 253 return void 0 == r && (r = 1.70158), (e /= a / 2) < 1 ? u / 2 * e * e * (((r *= 1.525) + 1) * e - r) + t : u / 2 * ((e -= 2) * e * (((r *= 1.525) + 1) * e + r) + 2) + t 254 }, 255 easeInBounce: function (n, e, t, u, a) { 256 return u - jQuery.easing.easeOutBounce(n, a - e, 0, u, a) + t 257 }, 258 easeOutBounce: function (n, e, t, u, a) { 259 return (e /= a) < 1 / 2.75 ? 7.5625 * u * e * e + t : 2 / 2.75 > e ? u * (7.5625 * (e -= 1.5 / 2.75) * e + .75) + t : 2.5 / 2.75 > e ? u * (7.5625 * (e -= 2.25 / 2.75) * e + .9375) + t : u * (7.5625 * (e -= 2.625 / 2.75) * e + .984375) + t 260 }, 261 easeInOutBounce: function (n, e, t, u, a) { 262 return a / 2 > e ? .5 * jQuery.easing.easeInBounce(n, 2 * e, 0, u, a) + t : .5 * jQuery.easing.easeOutBounce(n, 2 * e - a, 0, u, a) + .5 * u + t 263 } 264}); 265 266/* 267 * jquery.scrollTo 268 * ----------------------------------------------- 269 */ 270/** 271 * Copyright (c) 2007-2015 Ariel Flesler - aflesler<a>gmail<d>com | http://flesler.blogspot.com 272 * Licensed under MIT 273 * @author Ariel Flesler 274 * @version 2.1.2 275 */ 276; 277(function (f) { 278 "use strict"; 279 "function" === typeof define && define.amd ? define(["jquery"], f) : "undefined" !== typeof module && module.exports ? module.exports = f(require("jquery")) : f(jQuery) 280})(function ($) { 281 "use strict"; 282 283 function n(a) { 284 return !a.nodeName || -1 !== $.inArray(a.nodeName.toLowerCase(), ["iframe", "#document", "html", "body"]) 285 } 286 287 function h(a) { 288 return $.isFunction(a) || $.isPlainObject(a) ? a : { 289 top: a, 290 left: a 291 } 292 } 293 var p = $.scrollTo = function (a, d, b) { 294 return $(window).scrollTo(a, d, b) 295 }; 296 p.defaults = { 297 axis: "xy", 298 duration: 0, 299 limit: !0 300 }; 301 $.fn.scrollTo = function (a, d, b) { 302 "object" === typeof d && (b = d, d = 0); 303 "function" === typeof b && (b = { 304 onAfter: b 305 }); 306 "max" === a && (a = 9E9); 307 b = $.extend({}, p.defaults, b); 308 d = d || b.duration; 309 var u = b.queue && 1 < b.axis.length; 310 u && (d /= 2); 311 b.offset = h(b.offset); 312 b.over = h(b.over); 313 return this.each(function () { 314 function k(a) { 315 var k = $.extend({}, b, { 316 queue: !0, 317 duration: d, 318 complete: a && function () { 319 a.call(q, e, b) 320 } 321 }); 322 r.animate(f, k) 323 } 324 if (null !== a) { 325 var l = n(this), 326 q = l ? this.contentWindow || window : this, 327 r = $(q), 328 e = a, 329 f = {}, 330 t; 331 switch (typeof e) { 332 case "number": 333 case "string": 334 if (/^([+-]=?)?\d+(\.\d+)?(px|%)?$/.test(e)) { 335 e = h(e); 336 break 337 } 338 e = l ? $(e) : $(e, q); 339 case "object": 340 if (e.length === 0) return; 341 if (e.is || e.style) t = (e = $(e)).offset() 342 } 343 var v = $.isFunction(b.offset) && b.offset(q, e) || b.offset; 344 $.each(b.axis.split(""), function (a, c) { 345 var d = "x" === c ? "Left" : "Top", 346 m = d.toLowerCase(), 347 g = "scroll" + d, 348 h = r[g](), 349 n = p.max(q, c); 350 t ? (f[g] = t[m] + (l ? 0 : h - r.offset()[m]), b.margin && (f[g] -= parseInt(e.css("margin" + d), 10) || 0, f[g] -= parseInt(e.css("border" + d + "Width"), 10) || 0), f[g] += v[m] || 0, b.over[m] && (f[g] += e["x" === c ? "width" : "height"]() * b.over[m])) : (d = e[m], f[g] = d.slice && "%" === d.slice(-1) ? parseFloat(d) / 100 * n : d); 351 b.limit && /^\d+$/.test(f[g]) && (f[g] = 0 >= f[g] ? 0 : Math.min(f[g], n)); 352 !a && 1 < b.axis.length && (h === f[g] ? f = {} : u && (k(b.onAfterFirst), f = {})) 353 }); 354 k(b.onAfter) 355 } 356 }) 357 }; 358 p.max = function (a, d) { 359 var b = "x" === d ? "Width" : "Height", 360 h = "scroll" + b;
361 if (!n(a)) return a[h] - $(a)[b.toLowerCase()](); 362 var b = "client" + b, 363 k = a.ownerDocument || a.document, 364 l = k.documentElement, 365 k = k.body; 366 return Math.max(l[h], k[h]) - Math.min(l[b], k[b]) 367 }; 368 $.Tween.propHooks.scrollLeft = $.Tween.propHooks.scrollTop = { 369 get: function (a) { 370 return $(a.elem)[a.prop]() 371 }, 372 set: function (a) { 373 var d = this.get(a); 374 if (a.options.interrupt && a._last && a._last !== d) return $(a.elem).stop(); 375 var b = Math.round(a.now); 376 d !== b && ($(a.elem)[a.prop](b), a._last = this.get(a)) 377 } 378 }; 379 return p 380}); 381 382/* 383 * jquery.localScroll 384 * ----------------------------------------------- 385 */ 386/** 387 * Copyright (c) 2007-2015 Ariel Flesler - aflesler<a>gmail<d>com | http://flesler.blogspot.com 388 * Licensed under MIT 389 * @author Ariel Flesler 390 * @version 1.4.0 391 */ 392; 393(function (a) { 394 if (typeof define === 'function' && define.amd) { 395 define(['jquery'], a) 396 } else { 397 a(jQuery) 398 } 399}(function ($) { 400 var g = location.href.replace(/#.*/, ''); 401 var h = $.localScroll = function (a) { 402 $('body').localScroll(a) 403 }; 404 h.defaults = { 405 duration: 1000, 406 axis: 'y', 407 event: 'click', 408 stop: true, 409 target: window 410 }; 411 $.fn.localScroll = function (a) { 412 a = $.extend({}, h.defaults, a); 413 if (a.hash && location.hash) { 414 if (a.target) window.scrollTo(0, 0); 415 scroll(0, location, a) 416 } 417 return a.lazy ? this.on(a.event, 'a,area', function (e) { 418 if (filter.call(this)) { 419 scroll(e, this, a) 420 } 421 }) : this.find('a,area').filter(filter).bind(a.event, function (e) { 422 scroll(e, this, a) 423 }).end().end(); 424 425 function filter() { 426 return !!this.href && !!this.hash && this.href.replace(this.hash, '') === g && (!a.filter || $(this).is(a.filter)) 427 } 428 }; 429 h.hash = function () { }; 430 431 function scroll(e, a, b) { 432 var c = a.hash.slice(1), 433 elem = document.getElementById(c) || document.getElementsByName(c)[0]; 434 if (!elem) return; 435 if (e) e.preventDefault(); 436 var d = $(b.target); 437 if (b.lock && d.is(':animated') || b.onBefore && b.onBefore(e, elem, d) === false) return; 438 if (b.stop) { 439 d.stop(true) 440 } 441 if (b.hash) { 442 var f = elem.id === c ? 'id' : 'name', 443 $a = $('<a> </a>').attr(f, c).css({ 444 position: 'absolute', 445 top: $(window).scrollTop(), 446 left: $(window).scrollLeft() 447 }); 448 elem[f] = ''; 449 $('body').prepend($a); 450 location.hash = a.hash; 451 $a.remove(); 452 elem[f] = c 453 } 454 d.scrollTo(elem, b).trigger('notify.serialScroll', [elem]) 455 } 456 return h 457})); 458 459 460/* 461 * SmoothScroll for websites 462 * ----------------------------------------------- 463 */ 464// SmoothScroll for websites v1.4.0 (Balazs Galambosi) 465// http://www.smoothscroll.net/ 466! function () { 467 function e() { 468 469 z.keyboardSupport && m("keydown", a) 470 } 471 472 function t() { 473 if (!A && document.body) { 474 A = !0; 475 var t = document.body, 476 o = document.documentElement, 477 n = window.innerHeight, 478 r = t.scrollHeight; 479 if (B = document.compatMode.indexOf("CSS") >= 0 ? o : t, D = t, e(), top != self) X = !0; 480 else if (r >
480 n && (t.offsetHeight <= n || o.offsetHeight <= n)) { 481 var a = document.createElement("div"); 482 a.style.cssText = "position:absolute; z-index:-10000; top:0; left:0; right:0; height:" + B.scrollHeight + "px", document.body.appendChild(a); 483 var i; 484 T = function () { 485 i || (i = setTimeout(function () { 486 L || (a.style.height = "0", a.style.height = B.scrollHeight + "px", i = null) 487 }, 500)) 488 }, setTimeout(T, 10), m("resize", T); 489 var l = { 490 attributes: !0, 491 childList: !0, 492 characterData: !1 493 }; 494 if (M = new V(T), M.observe(t, l), B.offsetHeight <= n) { 495 var c = document.createElement("div"); 496 c.style.clear = "both", t.appendChild(c) 497 } 498 } 499 z.fixedBackground || L || (t.style.backgroundAttachment = "scroll", o.style.backgroundAttachment = "scroll") 500 } 501 } 502 503 function o() { 504 505 M && M.disconnect(), h(I, r), h("mousedown", i), h("keydown", a), h("resize", T), h("load", t) 506 } 507 508 function n(e, t, o) { 509 if (p(t, o), 1 != z.accelerationMax) { 510 var n = Date.now(), 511 r = n - R; 512 if (r < z.accelerationDelta) { 513 var a = (1 + 50 / r) / 2; 514 a > 1 && (a = Math.min(a, z.accelerationMax), t *= a, o *= a) 515 } 516 R = Date.now() 517 } 518 if (q.push({ 519 x: t, 520 y: o, 521 lastX: 0 > t ? .99 : -.99, 522 lastY: 0 > o ? .99 : -.99, 523 start: Date.now() 524 }), !P) { 525 var i = e === document.body, 526 l = function (n) { 527 for (var r = Date.now(), a = 0, c = 0, u = 0; u < q.length; u++) { 528 var d = q[u], 529 s = r - d.start, 530 f = s >= z.animationTime, 531 m = f ? 1 : s / z.animationTime; 532 z.pulseAlgorithm && (m = x(m)); 533 var h = d.x * m - d.lastX >> 0, 534 w = d.y * m - d.lastY >> 0; 535 a += h, c += w, d.lastX += h, d.lastY += w, f && (q.splice(u, 1), u--) 536 } 537 i ? window.scrollBy(a, c) : 538 (a && (e.scrollLeft += a), c && (e.scrollTop += c)), t || o || (q = []), 539 q.length ? _(l, e, 1e3 / z.frameRate + 1) : P = !1 540 }; 541 _(l, e, 0), P = !0 542 } 543 } 544 545 function r(e) { 546 A || t(); 547 var o = e.target, 548 r = u(o); 549 if (!r || e.defaultPrevented || e.ctrlKey) return !0; 550 if (w(D, "embed") || w(o, "embed") && /\.pdf/i.test(o.src) || w(D, "object")) 551 return !0; 552 var a = -e.wheelDeltaX || e.deltaX || 0, 553 i = -e.wheelDeltaY || e.deltaY || 0; 554 return K && (e.wheelDeltaX && b(e.wheelDeltaX, 120) && 555 (a = -120 * (e.wheelDeltaX / Math.abs(e.wheelDeltaX))), e.wheelDeltaY && b(e.wheelDeltaY, 120) && 556 (i = -120 * (e.wheelDeltaY / Math.abs(e.wheelDeltaY)))), a || i || (i = -e.wheelDelta || 0), 1 === e.deltaMode && 557 (a *= 40, i *= 40), !z.touchpadSupport && v(i) ? !0 : (Math.abs(a) > 1.2 && (a *= z.stepSize / 120), Math.abs(i) > 1.2 && 558 (i *= z.stepSize / 120), n(r, a, i) 559 //, e.preventDefault() 560 , void l()) 561 } 562 563 function a(e) { 564 var t = e.target, 565 o = e.ctrlKey || e.altKey || e.metaKey || e.shiftKey && e.keyCode !== N.spacebar; 566 document.contains(D) || (D = document.activeElement); 567 var r = /^(textarea|select|embed|object)$/i, 568 a = /^(button|submit|radio|checkbox|file|color|image)$/i; 569 if (r.test(t.nodeName) || w(t, "input") && !a.test(t.type) || w(D, "video") || y(e) || t.isContentEditable || e.defaultPrevented || o) return !0; 570 if ((w(t, "button") || w(t, "input") && a.test(t.type)) && e.keyCode === N.spacebar) return !0; 571 var i, c = 0, 572 d = 0, 573 s = u(D), 574 f = s.clientHeight; 575 switch (s == document.body && (f = window.innerHeight), e.keyCode) { 576 case N.up: 577 d = -z.arrowScroll; 578 break; 579 case N.down: 580 d = z.arrowScroll; 581 break; 582 case N.spacebar: 583 i = e.shiftKey ? 1 : -1, d = -i * f * .9; 584 break; 585 case N.pageup: 586 d = .9 * -f; 587 break; 588 case N.pagedown: 589 d = .9 * f; 590 break; 591 case N.home: 592 d = -s.scrollTop; 593 break; 594 case N.end: 595 var m = s.scrollHeight - s.scrollTop - f; 596 d = m > 0 ? m + 10 : 0; 597 break;
598 case N.left: 599 c = -z.arrowScroll; 600 break; 601 case N.right: 602 c = z.arrowScroll; 603 break; 604 default: 605 return !0 606 } 607 n(s, c, d), e.preventDefault(), l() 608 } 609 610 function i(e) { 611 D = e.target 612 } 613 614 function l() { 615 clearTimeout(E), E = setInterval(function () { 616 F = {} 617 }, 1e3) 618 } 619 620 function c(e, t) { 621 for (var o = e.length; o--;) F[j(e[o])] = t; 622 return t 623 } 624 625 function u(e) { 626 var t = [], 627 o = document.body, 628 n = B.scrollHeight; 629 do { 630 var r = F[j(e)]; 631 if (r) return c(t, r); 632 if (t.push(e), n === e.scrollHeight) { 633 var a = s(B) && s(o), 634 i = a || f(B); 635 if (X && d(B) || !X && i) return c(t, $()) 636 } else if (d(e) && f(e)) return c(t, e) 637 } while (e = e.parentElement) 638 } 639 640 function d(e) { 641 return e.clientHeight + 10 < e.scrollHeight 642 } 643 644 function s(e) { 645 var t = getComputedStyle(e, "").getPropertyValue("overflow-y"); 646 return "hidden" !== t 647 } 648 649 function f(e) { 650 var t = getComputedStyle(e, "").getPropertyValue("overflow-y"); 651 return "scroll" === t || "auto" === t 652 } 653 654 function m(e, t) { 655 window.addEventListener(e, t, !1) 656 } 657 658 function h(e, t) { 659 window.removeEventListener(e, t, !1) 660 } 661 662 function w(e, t) { 663 return (e.nodeName || "").toLowerCase() === t.toLowerCase() 664 } 665 666 function p(e, t) { 667 e = e > 0 ? 1 : -1, t = t > 0 ? 1 : -1, (Y.x !== e || Y.y !== t) && (Y.x = e, Y.y = t, q = [], R = 0) 668 } 669 670 function v(e) { 671 return e ? (O.length || (O = [e, e, e]), e = Math.abs(e), O.push(e), O.shift(), clearTimeout(H), H = setTimeout(function () { 672 window.localStorage && (localStorage.SS_deltaBuffer = O.join(",")) 673 }, 1e3), !g(120) && !g(100)) : void 0 674 } 675 676 function b(e, t) { 677 return Math.floor(e / t) == e / t 678 } 679 680 function g(e) { 681 return b(O[0], e) && b(O[1], e) && b(O[2], e) 682 } 683 684 function y(e) { 685 var t = e.target, 686 o = !1; 687 if (-1 != document.URL.indexOf("www.youtube.com/watch")) 688 do 689 if (o = t.classList && t.classList.contains("html5-video-controls")) break; while (t = t.parentNode); 690 return o 691 } 692 693 function S(e) { 694 var t, o, n; 695 return e *= z.pulseScale, 1 > e ? t = e - (1 - Math.exp(-e)) : (o = Math.exp(-1), e -= 1, n = 1 - Math.exp(-e), t = o + n * (1 - o)), t * z.pulseNormalize 696 } 697 698 function x(e) { 699 return e >= 1 ? 1 : 0 >= e ? 0 : (1 == z.pulseNormalize && (z.pulseNormalize /= S(1)), S(e)) 700 } 701 702 function k(e) { 703 for (var t in e) C.hasOwnProperty(t) && (z[t] = e[t]) 704 } 705 var D, M, T, E, H, C = { 706 frameRate: 150, 707 animationTime: 400, 708 stepSize: 100, 709 pulseAlgorithm: !0, 710 pulseScale: 4, 711 pulseNormalize: 1, 712 accelerationDelta: 50, 713 accelerationMax: 3, 714 keyboardSupport: !0, 715 arrowScroll: 50, 716 touchpadSupport: !1, 717 fixedBackground: !0, 718 excluded: "" 719 }, 720 z = C, 721 L = !1, 722 X = !1, 723 Y = { 724 x: 0, 725 y: 0 726 }, 727 A = !1, 728 B = document.documentElement, 729 O = [], 730 K = /^Mac/.test(navigator.platform), 731 N = { 732 left: 37, 733 up: 38, 734 right: 39, 735 down: 40, 736 spacebar: 32, 737 pageup: 33, 738 pagedown: 34, 739 end: 35, 740 home: 36 741 }, 742 q = [], 743 P = !1, 744 R = Date.now(), 745 j = function () { 746 var e = 0; 747 return function (t) { 748 return t.uniqueID || (t.uniqueID = e++) 749 } 750 }(), 751 F = {}; 752 window.localStorage && localStorage.SS_deltaBuffer && (O = localStorage.SS_deltaBuffer.split(",")); 753 var I, _ = function () { 754 return window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || function (e, t, o) { 755 window.setTimeout(e, o || 1e3 / 60) 756 } 757 }(), 758 V = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver, 759 $ = function () { 760 var e; 761 return function () { 762 if (!e) { 763 var t = document.createElement("div"); 764 t.style.cssText = "height:10000px;width:1px;", document.body.appendChild(t); 765 var o = document.body.scrollTop; 766 document.documentElement.scrollTop; 767 window.scrollBy(0, 3), e = document.body.scrollTop != o ? document.body : document.documentElement, window.scrollBy(0, -3), document.body.removeChild(t) 768 } 769 return e 770 } 771 }(), 772 U = window.navigator.userAgent, 773 W = /Edge/.test(U), 774 G = /chrome/i.test(U) && !W, 775 J = /safari/i.test(U) && !W, 776 Q = /mobile/i.test(U), 777 Z = (G || J) && !Q; 778 "onwheel" in document.createElement("div") ? I = "wheel" : "onmousewheel" in document.createElement("div") && (I = "mousewheel"), I && Z && (m(I, r), m("mousedown", i), m("load", t)), k.destroy = o, window.SmoothScrollOptions && k(window.SmoothScrollOptions), "function" == typeof define && define.amd ? define(function () { 779 return k 780 }) : "object" == typeof exports ? module.exports = k : window.SmoothScroll = k 781}(); 782 783 784 785/* 786 * jQuery appear plugin 787 * 788 * Copyright (c) 2012 Andrey Sidorov 789 * licensed under MIT license. 790 * 791 * https://github.com/morr/jquery.appear/ 792 * 793 * Version: 0.3.6 794 */ 795! function (e) { 796 function r(r) { 797 return e(r).filter(function () { 798 return e(this).is(":appeared") 799 }) 800 } 801 802 function t() { 803 a = !1; 804 for (var e = 0, t = i.length; t > e; e++) { 805 var n = r(i[e]); 806 if (n.trigger("appear", [n]), p[e]) { 807 var o = p[e].not(n); 808 o.trigger("disappear", [o]) 809 } 810 p[e] = n 811 } 812 } 813 814 function n(e) { 815 i.push(e), p.push() 816 } 817 var i = [], 818 o = !1, 819 a = !1, 820 f = { 821 interval: 250, 822 force_process: !1 823 }, 824 u = e(window), 825 p = []; 826 e.expr[":"].appeared = function (r) { 827 var t = e(r); 828 if (!t.is(":visible")) return !1; 829 var n = u.scrollLeft(), 830 i = u.scrollTop(), 831 o = t.offset(), 832 a = o.left, 833 f = o.top; 834 return f + t.height() >= i && f - (t.data("appear-top-offset") || 0) <= i + u.height() && a + t.width() >
vendor: 17,102 bytes, lines 834-1197
834= n && a - (t.data("appear-left-offset") || 0) <= n + u.width() ? !0 : !1 835 }, e.fn.extend({ 836 appear: function (r) { 837 var i = e.extend({}, f, r || {}), 838 u = this.selector || this; 839 if (!o) { 840 var p = function () { 841 a || (a = !0, setTimeout(t, i.interval)) 842 }; 843 e(window).scroll(p).resize(p), o = !0 844 } 845 return i.force_process && setTimeout(t, i.interval), n(u), e(u) 846 } 847 }), e.extend({ 848 force_appear: function () { 849 return o ? (t(), !0) : !1 850 } 851 }) 852}(function () { 853 return "undefined" != typeof module ? require("jquery") : jQuery 854}()); 855 856 857/* 858 * modernizr 859 * ----------------------------------------------- 860 */ 861window.Modernizr = function (e, t, n) { 862 function r(e) { 863 b.cssText = e 864 } 865 866 function o(e, t) { 867 return r(S.join(e + ";") + (t || "")) 868 } 869 870 function a(e, t) { 871 return typeof e === t 872 } 873 874 function i(e, t) { 875 return !!~("" + e).indexOf(t) 876 } 877 878 function c(e, t) { 879 for (var r in e) { 880 var o = e[r]; 881 if (!i(o, "-") && b[o] !== n) return "pfx" == t ? o : !0 882 } 883 return !1 884 } 885 886 function s(e, t, r) { 887 for (var o in e) { 888 var i = t[e[o]]; 889 if (i !== n) return r === !1 ? e[o] : a(i, "function") ? i.bind(r || t) : i 890 } 891 return !1 892 } 893 894 function u(e, t, n) { 895 var r = e.charAt(0).toUpperCase() + e.slice(1), 896 o = (e + " " + k.join(r + " ") + r).split(" "); 897 return a(t, "string") || a(t, "undefined") ? c(o, t) : (o = (e + " " + T.join(r + " ") + r).split(" "), s(o, t, n)) 898 } 899 900 function l() { 901 p.input = function (n) { 902 for (var r = 0, o = n.length; o > r; r++) j[n[r]] = !!(n[r] in E); 903 return j.list && (j.list = !(!t.createElement("datalist") || !e.HTMLDataListElement)), j 904 }("autocomplete autofocus list placeholder max min multiple pattern required step".split(" ")), p.inputtypes = function (e) { 905 for (var r, o, a, i = 0, c = e.length; c > i; i++) E.setAttribute("type", o = e[i]), r = "text" !== E.type, r && (E.value = x, E.style.cssText = "position:absolute;visibility:hidden;", /^range$/.test(o) && E.style.WebkitAppearance !== n ? (g.appendChild(E), a = t.defaultView, r = a.getComputedStyle && "textfield" !== a.getComputedStyle(E, null).WebkitAppearance && 0 !== E.offsetHeight, g.removeChild(E)) : /^(search|tel)$/.test(o) || (r = /^(url|email)$/.test(o) ? E.checkValidity && E.checkValidity() === !1 : E.value != x)), P[e[i]] = !!r; 906 return P 907 }("search tel url email datetime date month week time datetime-local number range color".split(" ")) 908 } 909 var d, f, m = "2.7.1", 910 p = {}, 911 h = !0, 912 g = t.documentElement, 913 v = "modernizr", 914 y = t.createElement(v), 915 b = y.style, 916 E = t.createElement("input"), 917 x = ":)", 918 w = {}.toString, 919 S = " -webkit- -moz- -o- -ms- ".split(" "), 920 C = "Webkit Moz O ms", 921 k = C.split(" "), 922 T = C.toLowerCase().split(" "), 923 N = { 924 svg: "http://www.w3.org/2000/svg" 925 }, 926 M = {}, 927 P = {}, 928 j = {}, 929 $ = [], 930 D = $.slice, 931 F = function (e, n, r, o) { 932 var a, i, c, s, u = t.createElement("div"), 933 l = t.body, 934 d = l || t.createElement("body"); 935 if (parseInt(r, 10)) 936 for (; r--;) c = t.createElement("div"), c.id = o ? o[r] : v + (r + 1), u.appendChild(c); 937 return a = ["­", '<style id="s', v, '">', e, "</style>"].join(""), u.id = v, (l ? u : d).innerHTML += a, d.appendChild(u), l || (d.style.background = "", d.style.overflow = "hidden", s = g.style.overflow, g.style.overflow = "hidden", g.appendChild(d)), i = n(u, e), l ? u.parentNode.removeChild(u) : (d.parentNode.removeChild(d), g.style.overflow = s), !!i 938 }, 939 z = function (t) { 940 var n = e.matchMedia || e.msMatchMedia; 941 if (n) return n(t).matches; 942 var r; 943 return F("@media " + t + " { #" + v + " { position: absolute; } }", function (t) { 944 r = "absolute" == (e.getComputedStyle ? getComputedStyle(t, null) : t.currentStyle).position 945 }), r 946 }, 947 A = function () { 948 function e(e, o) { 949 o = o || t.createElement(r[e] || "div"), e = "on" + e; 950 var i = e in o; 951 return i || (o.setAttribute || (o = t.createElement("div")), o.setAttribute && o.removeAttribute && (o.setAttribute(e, ""), i = a(o[e], "function"), a(o[e], "undefined") || (o[e] = n), o.removeAttribute(e))), o = null, i 952 } 953 var r = { 954 select: "input", 955 change: "input", 956 submit: "form", 957 reset: "form", 958 error: "img", 959 load: "img", 960 abort: "img" 961 }; 962 return e 963 }(), 964 L = {}.hasOwnProperty; 965 f = a(L, "undefined") || a(L.call, "undefined") ? function (e, t) { 966 return t in e && a(e.constructor.prototype[t], "undefined") 967 } : function (e, t) { 968 return L.call(e, t) 969 }, Function.prototype.bind || (Function.prototype.bind = function (e) { 970 var t = this; 971 if ("function" != typeof t) throw new TypeError; 972 var n = D.call(arguments, 1), 973 r = function () { 974 if (this instanceof r) { 975 var o = function () { }; 976 o.prototype = t.prototype; 977 var a = new o, 978 i = t.apply(a, n.concat(D.call(arguments))); 979 return Object(i) === i ? i : a 980 } 981 return t.apply(e, n.concat(D.call(arguments))) 982 }; 983 return r 984 }), M.flexbox = function () { 985 return u("flexWrap") 986 }, M.flexboxlegacy = function () { 987 return u("boxDirection") 988 }, M.canvas = function () { 989 var e = t.createElement("canvas"); 990 return !(!e.getContext || !e.getContext("2d")) 991 }, M.canvastext = function () { 992 return !(!p.canvas || !a(t.createElement("canvas").getContext("2d").fillText, "function")) 993 }, M.webgl = function () { 994 return !!e.WebGLRenderingContext 995 }, M.touch = function () { 996 var n; 997 return "ontouchstart" in e || e.DocumentTouch && t instanceof DocumentTouch ? n = !0 : F(["@media (", S.join("touch-enabled),("), v, ")", "{#modernizr{top:9px;position:absolute}}"].join(""), function (e) { 998 n = 9 === e.offsetTop 999 }), n 1000 }, M.geolocation = function () { 1001 return "geolocation" in navigator 1002 }, M.postmessage = function () { 1003 return !!e.postMessage 1004 }, M.websqldatabase = function () { 1005 return !!e.openDatabase 1006 }, M.indexedDB = function () { 1007 return !!u("indexedDB", e) 1008 }, M.hashchange = function () { 1009 return A("hashchange", e) && (t.documentMode === n || t.documentMode > 7) 1010 }, M.history = function () { 1011 return !(!e.history || !history.pushState) 1012 }, M.draganddrop = function () { 1013 var e = t.createElement("div"); 1014 return "draggable" in e || "ondragstart" in e && "ondrop" in e 1015 }, M.websockets = function () { 1016 return "WebSocket" in e || "MozWebSocket" in e 1017 }, M.rgba = function () { 1018 return r("background-color:rgba(150,255,150,.5)"), i(b.backgroundColor, "rgba") 1019 }, M.hsla = function () { 1020 return r("background-color:hsla(120,40%,100%,.5)"), i(b.backgroundColor, "rgba") || i(b.backgroundColor, "hsla") 1021 }, M.multiplebgs = function () { 1022 return r("background:url(https://),url(https://),red url(https://)"), /(url\s*\(.*?){3}/.test(b.background) 1023 }, M.backgroundsize = function () { 1024 return u("backgroundSize") 1025 }, M.borderimage = function () { 1026 return u("borderImage") 1027 }, M.borderradius = function () { 1028 return u("borderRadius") 1029 }, M.boxshadow = function () { 1030 return u("boxShadow") 1031 }, M.textshadow = function () { 1032 return "" === t.createElement("div").style.textShadow 1033 }, M.opacity = function () { 1034 return o("opacity:.55"), /^0.55$/.test(b.opacity) 1035 }, M.cssanimations = function () { 1036 return u("animationName") 1037 }, M.csscolumns = function () { 1038 return u("columnCount") 1039 }, M.cssgradients = function () { 1040 var e = "background-image:", 1041 t = "gradient(linear,left top,right bottom,from(#9f9),to(white));", 1042 n = "linear-gradient(left top,#9f9, white);"; 1043 return r((e + "-webkit- ".split(" ").join(t + e) + S.join(n + e)).slice(0, -e.length)), i(b.backgroundImage, "gradient") 1044 }, M.cssreflections = function () { 1045 return u("boxReflect") 1046 }, M.csstransforms = function () { 1047 return !!u("transform") 1048 }, M.csstransforms3d = function () { 1049 var e = !!u("perspective"); 1050 return e && "webkitPerspective" in g.style && F("@media (transform-3d),(-webkit-transform-3d){#modernizr{left:9px;position:absolute;height:3px;}}", function (t, n) { 1051 e = 9 === t.offsetLeft && 3 === t.offsetHeight 1052 }), e 1053 }, M.csstransitions = function () { 1054 return u("transition") 1055 }, M.fontface = function () { 1056 var e; 1057 return F('@font-face {font-family:"font";src:url("https://")}', function (n, r) { 1058 var o = t.getElementById("smodernizr"), 1059 a = o.sheet || o.styleSheet, 1060 i = a ? a.cssRules && a.cssRules[0] ? a.cssRules[0].cssText : a.cssText || "" : ""; 1061 e = /src/i.test(i) && 0 === i.indexOf(r.split(" ")[0]) 1062 }), e 1063 }, M.generatedcontent = function () { 1064 var e; 1065 return F(["#", v, "{font:0/0 a}#", v, ':after{content:"', x, '";visibility:hidden;font:3px/1 a}'].join(""), function (t) { 1066 e = t.offsetHeight >= 3 1067 }), e 1068 }, M.video = function () { 1069 var e = t.createElement("video"), 1070 n = !1; 1071 try { 1072 (n = !!e.canPlayType) && (n = new Boolean(n), n.ogg = e.canPlayType('video/ogg; codecs="theora"').replace(/^no$/, ""), n.h264 = e.canPlayType('video/mp4; codecs="avc1.42E01E"').replace(/^no$/, ""), n.webm = e.canPlayType('video/webm; codecs="vp8, vorbis"').replace(/^no$/, "")) 1073 } catch (r) { } 1074 return n 1075 }, M.audio = function () { 1076 var e = t.createElement("audio"), 1077 n = !1; 1078 try { 1079 (n = !!e.canPlayType) && (n = new Boolean(n), n.ogg = e.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/, ""), n.mp3 = e.canPlayType("audio/mpeg;").replace(/^no$/, ""), n.wav = e.canPlayType('audio/wav; codecs="1"').replace(/^no$/, ""), n.m4a = (e.canPlayType("audio/x-m4a;") || e.canPlayType("audio/aac;")).replace(/^no$/, "")) 1080 } catch (r) { } 1081 return n 1082 }, M.localstorage = function () { 1083 try { 1084 return localStorage.setItem(v, v), localStorage.removeItem(v), !0 1085 } catch (e) { 1086 return !1 1087 } 1088 }, M.sessionstorage = function () { 1089 try { 1090 return sessionStorage.setItem(v, v), sessionStorage.removeItem(v), !0 1091 } catch (e) { 1092 return !1 1093 } 1094 }, M.webworkers = function () { 1095 return !!e.Worker 1096 }, M.applicationcache = function () { 1097 return !!e.applicationCache 1098 }, M.svg = function () { 1099 return !!t.createElementNS && !!t.createElementNS(N.svg, "svg").createSVGRect 1100 }, M.inlinesvg = function () { 1101 var e = t.createElement("div"); 1102 return e.innerHTML = "<svg/>", (e.firstChild && e.firstChild.namespaceURI) == N.svg 1103 }, M.smil = function () { 1104 return !!t.createElementNS && /SVGAnimate/.test(w.call(t.createElementNS(N.svg, "animate"))) 1105 }, M.svgclippaths = function () { 1106 return !!t.createElementNS && /SVGClipPath/.test(w.call(t.createElementNS(N.svg, "clipPath"))) 1107 }; 1108 for (var H in M) f(M, H) && (d = H.toLowerCase(), p[d] = M[H](), $.push((p[d] ? "" : "no-") + d)); 1109 return p.input || l(), p.addTest = function (e, t) { 1110 if ("object" == typeof e) 1111 for (var r in e) f(e, r) && p.addTest(r, e[r]); 1112 else { 1113 if (e = e.toLowerCase(), p[e] !== n) return p; 1114 t = "function" == typeof t ? t() : t, "undefined" != typeof h && h && (g.className += " " + (t ? "" : "no-") + e), p[e] = t 1115 } 1116 return p 1117 }, r(""), y = E = null, 1118 function (e, t) { 1119 function n(e, t) { 1120 var n = e.createElement("p"), 1121 r = e.getElementsByTagName("head")[0] || e.documentElement; 1122 return n.innerHTML = "x<style>" + t + "</style>", r.insertBefore(n.lastChild, r.firstChild) 1123 } 1124 1125 function r() { 1126 var e = y.elements; 1127 return "string" == typeof e ? e.split(" ") : e 1128 } 1129 1130 function o(e) { 1131 var t = v[e[h]]; 1132 return t || (t = {}, g++ , e[h] = g, v[g] = t), t 1133 } 1134 1135 function a(e, n, r) { 1136 if (n || (n = t), l) return n.createElement(e); 1137 r || (r = o(n)); 1138 var a; 1139 return a = r.cache[e] ? r.cache[e].cloneNode() : p.test(e) ? (r.cache[e] = r.createElem(e)).cloneNode() : r.createElem(e), !a.canHaveChildren || m.test(e) || a.tagUrn ? a : r.frag.appendChild(a) 1140 } 1141 1142 function i(e, n) { 1143 if (e || (e = t), l) return e.createDocumentFragment(); 1144 n = n || o(e); 1145 for (var a = n.frag.cloneNode(), i = 0, c = r(), s = c.length; s > i; i++) a.createElement(c[i]); 1146 return a 1147 } 1148 1149 function c(e, t) { 1150 t.cache || (t.cache = {}, t.createElem = e.createElement, t.createFrag = e.createDocumentFragment, t.frag = t.createFrag()), e.createElement = function (n) { 1151 return y.shivMethods ? a(n, e, t) : t.createElem(n) 1152 }, e.createDocumentFragment = Function("h,f", "return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&(" + r().join().replace(/[\w\-]+/g, function (e) { 1153 return t.createElem(e), t.frag.createElement(e), 'c("' + e + '")' 1154 }) + ");return n}")(y, t.frag) 1155 } 1156 1157 function s(e) { 1158 e || (e = t); 1159 var r = o(e); 1160 return !y.shivCSS || u || r.hasCSS || (r.hasCSS = !!n(e, "article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")), l || c(e, r), e 1161 } 1162 var u, l, d = "3.7.0", 1163 f = e.html5 || {}, 1164 m = /^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i, 1165 p = /^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i, 1166 h = "_html5shiv", 1167 g = 0, 1168 v = {}; 1169 ! function () { 1170 try { 1171 var e = t.createElement("a"); 1172 e.innerHTML = "<xyz></xyz>", u = "hidden" in e, l = 1 == e.childNodes.length || function () { 1173 t.createElement("a"); 1174 var e = t.createDocumentFragment(); 1175 return "undefined" == typeof e.cloneNode || "undefined" == typeof e.createDocumentFragment || "undefined" == typeof e.createElement 1176 }() 1177 } catch (n) { 1178 u = !0, l = !0 1179 } 1180 }(); 1181 var y = { 1182 elements: f.elements || "abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output progress section summary template time video", 1183 version: d, 1184 shivCSS: f.shivCSS !== !1, 1185 supportsUnknownElements: l, 1186 shivMethods: f.shivMethods !== !1, 1187 type: "default", 1188 shivDocument: s, 1189 createElement: a, 1190 createDocumentFragment: i 1191 }; 1192 e.html5 = y, s(t) 1193 }(this, t), p._version = m, p._prefixes = S, p._domPrefixes = T, p._cssomPrefixes = k, p.mq = z, p.hasEvent = A, p.testProp = function (e) { 1194 return c([e]) 1195 }, p.testAllProps = u, p.testStyles = F, p.prefixed = function (e, t, n) { 1196 return t ? u(e, t, n) : u(e, "pfx") 1197 }, g.className = g.className.replace(/(^|\s)no-js(\s|$)/, "$1$2") + (h ? " js " + $.j
vendor: 12,659 bytes, lines 1197-1572
1197oin(" ") : ""), p 1198}(this, this.document); 1199/* 1200 * scrollToFixed 1201 * ----------------------------------------------- 1202 */ 1203(function (a) { 1204 a.isScrollToFixed = function (b) { 1205 return !!a(b).data("ScrollToFixed") 1206 }; 1207 a.ScrollToFixed = function (d, i) { 1208 var m = this; 1209 m.$el = a(d); 1210 m.el = d; 1211 m.$el.data("ScrollToFixed", m); 1212 var c = false; 1213 var H = m.$el; 1214 var I; 1215 var F; 1216 var k; 1217 var e; 1218 var z; 1219 var E = 0; 1220 var r = 0; 1221 var j = -1; 1222 var f = -1; 1223 var u = null; 1224 var A; 1225 var g; 1226 1227 function v() { 1228 H.trigger("preUnfixed.ScrollToFixed"); 1229 l(); 1230 H.trigger("unfixed.ScrollToFixed"); 1231 f = -1; 1232 E = H.offset().top; 1233 r = H.offset().left; 1234 if (m.options.offsets) { 1235 r += (H.offset().left - H.position().left) 1236 } 1237 if (j == -1) { 1238 j = r 1239 } 1240 I = H.css("position"); 1241 c = true; 1242 if (m.options.bottom != -1) { 1243 H.trigger("preFixed.ScrollToFixed"); 1244 x(); 1245 H.trigger("fixed.ScrollToFixed") 1246 } 1247 } 1248 1249 function o() { 1250 var J = m.options.limit; 1251 if (!J) { 1252 return 0 1253 } 1254 if (typeof (J) === "function") { 1255 return J.apply(H) 1256 } 1257 return J 1258 } 1259 1260 function q() { 1261 return I === "fixed" 1262 } 1263 1264 function y() { 1265 return I === "absolute" 1266 } 1267 1268 function h() { 1269 return !(q() || y()) 1270 } 1271 1272 function x() { 1273 if (!q()) { 1274 var J = H[0].getBoundingClientRect(); 1275 u.css({ 1276 display: H.css("display"), 1277 width: J.width, 1278 height: J.height, 1279 "float": H.css("float") 1280 }); 1281 cssOptions = { 1282 "z-index": m.options.zIndex, 1283 position: "fixed", 1284 top: m.options.bottom == -1 ? t() : "", 1285 bottom: m.options.bottom == -1 ? "" : m.options.bottom, 1286 "margin-left": "0px" 1287 }; 1288 if (!m.options.dontSetWidth) { 1289 cssOptions.width = H.css("width") 1290 } 1291 H.css(cssOptions); 1292 H.addClass(m.options.baseClassName); 1293 if (m.options.className) { 1294 H.addClass(m.options.className) 1295 } 1296 I = "fixed" 1297 } 1298 } 1299 1300 function b() { 1301 var K = o(); 1302 var J = r; 1303 if (m.options.removeOffsets) { 1304 J = ""; 1305 K = K - E 1306 } 1307 cssOptions = { 1308 position: "absolute", 1309 top: K, 1310 left: J, 1311 "margin-left": "0px", 1312 bottom: "" 1313 }; 1314 if (!m.options.dontSetWidth) { 1315 cssOptions.width = H.css("width") 1316 } 1317 H.css(cssOptions); 1318 I = "absolute" 1319 } 1320 1321 function l() { 1322 if (!h()) { 1323 f = -1; 1324 u.css("display", "none"); 1325 H.css({ 1326 "z-index": z, 1327 width: "", 1328 position: F, 1329 left: "", 1330 top: e, 1331 "margin-left": "" 1332 }); 1333 H.removeClass("scroll-to-fixed-fixed"); 1334 if (m.options.className) { 1335 H.removeClass(m.options.className) 1336 } 1337 I = null 1338 } 1339 } 1340 1341 function w(J) { 1342 if (J != f) { 1343 H.css("left", r - J); 1344 f = J 1345 } 1346 } 1347 1348 function t() { 1349 var J = m.options.marginTop; 1350 if (!J) { 1351 return 0 1352 } 1353 if (typeof (J) === "function") { 1354 return J.apply(H) 1355 } 1356 return J 1357 } 1358 1359 function B() { 1360 if (!a.isScrollToFixed(H) || H.is(":hidden")) { 1361 return 1362 } 1363 var M = c; 1364 var L = h(); 1365 if (!c) { 1366 v() 1367 } else { 1368 if (h()) { 1369 E = H.offset().top; 1370 r = H.offset().left 1371 } 1372 } 1373 var J = a(window).scrollLeft(); 1374 var N = a(window).scrollTop(); 1375 var K = o(); 1376 if (m.options.minWidth && a(window).width() < m.options.minWidth) { 1377 if (!h() || !M) { 1378 p(); 1379 H.trigger("preUnfixed.ScrollToFixed"); 1380 l(); 1381 H.trigger("unfixed.ScrollToFixed") 1382 } 1383 } else { 1384 if (m.options.maxWidth && a(window).width() > m.options.maxWidth) { 1385 if (!h() || !M) { 1386 p(); 1387 H.trigger("preUnfixed.ScrollToFixed"); 1388 l(); 1389 H.trigger("unfixed.ScrollToFixed") 1390 } 1391 } else { 1392 if (m.options.bottom == -1) { 1393 if (K > 0 && N >= K - t()) { 1394 if (!L && (!y() || !M)) { 1395 p(); 1396 H.trigger("preAbsolute.ScrollToFixed"); 1397 b(); 1398 H.trigger("unfixed.ScrollToFixed") 1399 } 1400 } else { 1401 if (N >= E - t()) { 1402 if (!q() || !M) { 1403 p(); 1404 H.trigger("preFixed.ScrollToFixed"); 1405 x(); 1406 f = -1; 1407 H.trigger("fixed.ScrollToFixed") 1408 } 1409 w(J) 1410 } else { 1411 if (!h() || !M) { 1412 p(); 1413 H.trigger("preUnfixed.ScrollToFixed"); 1414 l(); 1415 H.trigger("unfixed.ScrollToFixed") 1416 } 1417 } 1418 } 1419 } else { 1420 if (K > 0) { 1421 if (N + a(window).height() - H.outerHeight(true) >= K - (t() || -n())) { 1422 if (q()) { 1423 p(); 1424 H.trigger("preUnfixed.ScrollToFixed"); 1425 if (F === "absolute") { 1426 b() 1427 } else { 1428 l() 1429 } 1430 H.trigger("unfixed.ScrollToFixed") 1431 } 1432 } else { 1433 if (!q()) { 1434 p(); 1435 H.trigger("preFixed.ScrollToFixed"); 1436 x() 1437 } 1438 w(J); 1439 H.trigger("fixed.ScrollToFixed") 1440 } 1441 } else { 1442 w(J) 1443 } 1444 } 1445 } 1446 } 1447 } 1448 1449 function n() { 1450 if (!m.options.bottom) { 1451 return 0 1452 } 1453 return m.options.bottom 1454 } 1455 1456 function p() { 1457 var J = H.css("position"); 1458 if (J == "absolute") { 1459 H.trigger("postAbsolute.ScrollToFixed") 1460 } else { 1461 if (J == "fixed") { 1462 H.trigger("postFixed.ScrollToFixed") 1463 } else { 1464 H.trigger("postUnfixed.ScrollToFixed") 1465 } 1466 } 1467 } 1468 var D = function (J) { 1469 if (H.is(":visible")) { 1470 c = false; 1471 B() 1472 } 1473 }; 1474 var G = function (J) { 1475 (!!window.requestAnimationFrame) ? requestAnimationFrame(B) : B() 1476 }; 1477 var C = function () { 1478 var K = document.body; 1479 if (document.createElement && K && K.appendChild && K.removeChild) { 1480 var M = document.createElement("div"); 1481 if (!M.getBoundingClientRect) { 1482 return null 1483 } 1484 M.innerHTML = "x"; 1485 M.style.cssText = "position:fixed;top:100px;"; 1486 K.appendChild(M); 1487 var N = K.style.height, 1488 O = K.scrollTop; 1489 K.style.height = "3000px"; 1490 K.scrollTop = 500; 1491 var J = M.getBoundingClientRect().top; 1492 K.style.height = N; 1493 var L = (J === 100); 1494 K.removeChild(M); 1495 K.scrollTop = O; 1496 return L 1497 } 1498 return null 1499 }; 1500 var s = function (J) { 1501 J = J || window.event; 1502 if (J.preventDefault) { 1503 J.preventDefault() 1504 } 1505 J.returnValue = false 1506 }; 1507 m.init = function () { 1508 m.options = a.extend({}, a.ScrollToFixed.defaultOptions, i); 1509 z = H.css("z-index"); 1510 m.$el.css("z-index", m.options.zIndex); 1511 u = a("<div />"); 1512 I = H.css("position"); 1513 F = H.css("position"); 1514 k = H.css("float"); 1515 e = H.css("top"); 1516 if (h()) { 1517 m.$el.after(u) 1518 } 1519 a(window).bind("resize.ScrollToFixed", D); 1520 a(window).bind("scroll.ScrollToFixed", G); 1521 if ("ontouchmove" in window) { 1522 a(window).bind("touchmove.ScrollToFixed", B) 1523 } 1524 if (m.options.preFixed) { 1525 H.bind("preFixed.ScrollToFixed", m.options.preFixed) 1526 } 1527 if (m.options.postFixed) { 1528 H.bind("postFixed.ScrollToFixed", m.options.postFixed) 1529 } 1530 if (m.options.preUnfixed) { 1531 H.bind("preUnfixed.ScrollToFixed", m.options.preUnfixed) 1532 } 1533 if (m.options.postUnfixed) { 1534 H.bind("postUnfixed.ScrollToFixed", m.options.postUnfixed) 1535 } 1536 if (m.options.preAbsolute) { 1537 H.bind("preAbsolute.ScrollToFixed", m.options.preAbsolute) 1538 } 1539 if (m.options.postAbsolute) { 1540 H.bind("postAbsolute.ScrollToFixed", m.options.postAbsolute) 1541 } 1542 if (m.options.fixed) { 1543 H.bind("fixed.ScrollToFixed", m.options.fixed) 1544 } 1545 if (m.options.unfixed) { 1546 H.bind("unfixed.ScrollToFixed", m.options.unfixed) 1547 } 1548 if (m.options.spacerClass) { 1549 u.addClass(m.options.spacerClass) 1550 } 1551 H.bind("resize.ScrollToFixed", function () { 1552 u.height(H.height()) 1553 }); 1554 H.bind("scroll.ScrollToFixed", function () { 1555 H.trigger("preUnfixed.ScrollToFixed"); 1556 l(); 1557 H.trigger("unfixed.ScrollToFixed"); 1558 B() 1559 }); 1560 H.bind("detach.ScrollToFixed", function (J) { 1561 s(J); 1562 H.trigger("preUnfixed.ScrollToFixed"); 1563 l(); 1564 H.trigger("unfixed.ScrollToFixed"); 1565 a(window).unbind("resize.ScrollToFixed", D); 1566 a(window).unbind("scroll.ScrollToFixed", G); 1567 H.unbind(".ScrollToFixed"); 1568 u.remove(); 1569 m.$el.removeData("ScrollToFixed") 1570 }); 1571 D() 1572 };
1573 m.init() 1574 }; 1575 a.ScrollToFixed.defaultOptions = { 1576 marginTop: 0, 1577 limit: 0, 1578 bottom: -1, 1579 zIndex: 1000, 1580 baseClassName: "scroll-to-fixed-fixed" 1581 }; 1582 a.fn.scrollToFixed = function (b) { 1583 return this.each(function () { 1584 (new a.ScrollToFixed(this, b)) 1585 }) 1586 } 1587})(jQuery); 1588 1589/* 1590 * Menuzord - Responsive Megamenu 1591 * ----------------------------------------------- 1592 */ 1593! function (e) { 1594 jQuery.fn.menuzord = function (n) { 1595 function i(n) { 1596 "fade" == p.effect ? e(n).children(".dropdown, .megamenu").stop(!0, !0).delay(p.showDelay).fadeIn(p.showSpeed).addClass(p.animation) : e(n).children(".dropdown, .megamenu").stop(!0, !0).delay(p.showDelay).slideDown(p.showSpeed).addClass(p.animation) 1597 } 1598 1599 function d(n) { 1600 "fade" == p.effect ? e(n).children(".dropdown, .megamenu").stop(!0, !0).delay(p.hideDelay).fadeOut(p.hideSpeed).removeClass(p.animation) : e(n).children(".dropdown, .megamenu").stop(!0, !0).delay(p.hideDelay).slideUp(p.hideSpeed).removeClass(p.animation), e(n).children(".dropdown, .megamenu").find(".dropdown, .megamenu").stop(!0, !0).delay(p.hideDelay).fadeOut(p.hideSpeed) 1601 } 1602 1603 function o() { 1604 e(g).find(".dropdown, .megamenu").hide(0), navigator.userAgent.match(/Mobi/i) || window.navigator.msMaxTouchPoints > 0 || "click" == p.trigger ? (e(".menuzord-menu > li > a, .menuzord-menu ul.dropdown li a").bind("click touchstart", function (n) { 1605 return n.stopPropagation(), n.preventDefault(), e(this).parent("li").siblings("li").find(".dropdown, .megamenu").stop(!0, !0).fadeOut(300), "none" == e(this).siblings(".dropdown, .megamenu").css("display") ? (i(e(this).parent("li")), !1) : (d(e(this).parent("li")), void (window.location.href = e(this).attr("href"))) 1606 }), e(document).bind("click.menu touchstart.menu", function (n) { 1607 0 == e(n.target).closest(".menuzord").length && e(".menuzord-menu").find(".dropdown, .megamenu").fadeOut(300) 1608 })) : e(w).bind("mouseenter", function () { 1609 i(this) 1610 }).bind("mouseleave", function () { 1611 d(this) 1612 }) 1613 } 1614 1615 function t() { 1616 e(g).find(".dropdown, .megamenu").hide(0), e(g).find(".indicator").each(function () { 1617 e(this).parent("a").siblings(".dropdown, .megamenu").length > 0 && e(this).bind("click", function (n) { 1618 e(g).scrollTo({ 1619 top: 45, 1620 left: 0 1621 }, 600), "A" == e(this).parent().prop("tagName") && n.preventDefault(), "none" == e(this).parent("a").siblings(".dropdown, .megamenu").css("display") ? (e(this).parent("a").siblings(".dropdown, .megamenu").delay(p.showDelay).slideDown(p.showSpeed), e(this).parent("a").parent("li").siblings("li").find(".dropdown, .megamenu").slideUp(p.hideSpeed)) : e(this).parent("a").siblings(".dropdown, .megamenu").slideUp(p.hideSpeed) 1622 }) 1623 }) 1624 } 1625 1626 function a() { 1627 var n = e(g).children("li").children(".dropdown, .megamenu"); 1628 if (e(window).innerWidth() > v) 1629 for (var i = e(f).outerWidth(!0), d = 0; d < n.length; d++) e(n[d]).parent("li").position().left + e(n[d]).outerWidth() > i ? e(n[d]).css("right", 0) : ((i == e(n[d]).outerWidth() || i - e(n[d]).outerWidth() < 20) && e(n[d]).css("left", 0), e(n[d]).parent("li").position().left + e(n[d]).outerWidth() < i && e(n[d]).css("right", "auto")) 1630 } 1631 1632 function s() { 1633 e(g).hide(0), e(m).show(0).click(function () { 1634 "none" == e(g).css("display") ? e(g).slideDown(p.showSpeed) : e(g).slideUp(p.hideSpeed).find(".dropdown, .megamenu").hide(p.hideSpeed) 1635 }) 1636 } 1637 1638 function r() { 1639 e(g).show(0), e(m).hide(0) 1640 } 1641 1642 function l() { 1643 e(f).find("li, a").unbind(), e(document).unbind("click.menu touchstart.menu") 1644 } 1645 1646 function h() { 1647 function n(n) { 1648 var i = e(n).find(".menuzord-tabs-nav > li"), 1649 d = e(n).find(".menuzord-tabs-content"); 1650 e(i).bind("click touchstart", function (n) { 1651 n.stopPropagation(), n.preventDefault(), e(i).removeClass("active"), e(this).addClass("active"), e(d).hide(0), e(d[e(this).index()]).show(0) 1652 }) 1653 } 1654 if (e(g).find(".menuzord-tabs").length > 0) 1655 for (var i = e(g).find(".menuzord-tabs"), d = 0; d < i.length; d++) n(i[d]) 1656 } 1657 1658 function c() { 1659 return window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth 1660 } 1661 1662 function u() { 1663 if (a(), c() <= v && b > v && (l(), p.responsive ? (s(), t()) : o()), c() > v && v >= y && (l(), r(), o()), b = c(), y = c(), h(), /MSIE (\d+\.\d+);/.test(navigator.userAgent) && c() < v) { 1664 var n = new Number(RegExp.$1); 1665 8 == n && (e(m).hide(0), e(g).show(0), l(), o()) 1666 } 1667 } 1668 var p; 1669 e.extend(p = { 1670 showSpeed: 300, 1671 hideSpeed: 300, 1672 trigger: "hover", 1673 showDelay: 0, 1674 hideDelay: 0, 1675 effect: "fade", 1676 align: "left", 1677 responsive: !0, 1678 animation: "none", 1679 indentChildren: !0, 1680 indicatorFirstLevel: "+", 1681 indicatorSecondLevel: "+", 1682 scrollable: !0, 1683 scrollableMaxHeight: 400 1684 }, n); 1685 var m, f = e(this), 1686 g = e(f).children(".menuzord-menu"), 1687 w = e(g).find("li"), 1688 v = 900, 1689 b = 2e3, 1690 y = 200; 1691 e(g).children("li").children("a").each(function () { 1692 e(this).siblings(".dropdown, .megamenu").length > 0 && e(this).append("<span class='indicator'>" + p.indicatorFirstLevel + "</span>") 1693 }), e(g).find(".dropdown").children("li").children("a").each(function () { 1694 e(this).siblings(".dropdown").length > 0 && e(this).append("<span class='indicator'>" + p.indicatorSecondLevel + "</span>") 1695 }), "right" == p.align && e(g).addClass("menuzord-right"), p.indentChildren && e(g).addClass("menuzord-indented"), p.responsive && (e(f).addClass("menuzord-responsive").prepend("<
1695a href='javascript:void(0)' class='showhide'><em></em><em></em><em></em></a>"), m = e(f).children(".showhide")), p.scrollable && p.responsive && e(g).css("max-height", p.scrollableMaxHeight).addClass("scrollable").append("<li class='scrollable-fix'></li>"), u(), e(window).resize(function () { 1696 u(), a() 1697 }) 1698 } 1699}(jQuery); 1700 1701/*! 1702 * imagesLoaded PACKAGED v4.1.0 1703 * JavaScript is all like "You images are done yet or what?" 1704 * MIT License 1705 */ 1706! function (t, e) { 1707 "function" == typeof define && define.amd ? define("ev-emitter/ev-emitter", e) : "object" == typeof module && module.exports ? module.exports = e() : t.EvEmitter = e() 1708}(this, function () { 1709 function t() { } 1710 var e = t.prototype; 1711 return e.on = function (t, e) { 1712 if (t && e) { 1713 var i = this._events = this._events || {}, 1714 n = i[t] = i[t] || []; 1715 return -1 == n.indexOf(e) && n.push(e), this 1716 } 1717 }, e.once = function (t, e) { 1718 if (t && e) { 1719 this.on(t, e); 1720 var i = this._onceEvents = this._onceEvents || {}, 1721 n = i[t] = i[t] || []; 1722 return n[e] = !0, this 1723 } 1724 }, e.off = function (t, e) { 1725 var i = this._events && this._events[t]; 1726 if (i && i.length) { 1727 var n = i.indexOf(e); 1728 return -1 != n && i.splice(n, 1), this 1729 } 1730 }, e.emitEvent = function (t, e) { 1731 var i = this._events && this._events[t]; 1732 if (i && i.length) { 1733 var n = 0, 1734 o = i[n]; 1735 e = e || []; 1736 for (var r = this._onceEvents && this._onceEvents[t]; o;) { 1737 var s = r && r[o]; 1738 s && (this.off(t, o), delete r[o]), o.apply(this, e), n += s ? 0 : 1, o = i[n] 1739 } 1740 return this 1741 } 1742 }, t 1743}), 1744 function (t, e) { 1745 "use strict"; 1746 "function" == typeof define && define.amd ? define(["ev-emitter/ev-emitter"], function (i) { 1747 return e(t, i) 1748 }) : "object" == typeof module && module.exports ? module.exports = e(t, require("ev-emitter")) : t.imagesLoaded = e(t, t.EvEmitter) 1749 }(window, function (t, e) { 1750 function i(t, e) { 1751 for (var i in e) t[i] = e[i]; 1752 return t 1753 } 1754 1755 function n(t) { 1756 var e = []; 1757 if (Array.isArray(t)) e = t; 1758 else if ("number" == typeof t.length) 1759 for (var i = 0; i < t.length; i++) e.push(t[i]); 1760 else e.push(t); 1761 return e 1762 } 1763 1764 function o(t, e, r) { 1765 return this instanceof o ? ("string" == typeof t && (t = document.querySelectorAll(t)), this.elements = n(t), this.options = i({}, this.options), "function" == typeof e ? r = e : i(this.options, e), r && this.on("always", r), this.getImages(), h && (this.jqDeferred = new h.Deferred), void setTimeout(function () { 1766 this.check() 1767 }.bind(this))) : new o(t, e, r) 1768 } 1769 1770 function r(t) { 1771 this.img = t 1772 } 1773 1774 function s(t, e) { 1775 this.url = t, this.element = e, this.img = new Image 1776 } 1777 var h = t.jQuery, 1778 a = t.console; 1779 o.prototype = Object.create(e.prototype), o.prototype.options = {}, o.prototype.getImages = function () { 1780 this.images = [], this.elements.forEach(this.addElementImages, this) 1781 }, o.prototype.addElementImages = function (t) { 1782 "IMG" == t.nodeName && this.addImage(t), this.options.background === !0 && this.addElementBackgroundImages(t); 1783 var e = t.nodeType; 1784 if (e && d[e]) { 1785 for (var i = t.querySelectorAll("img"), n = 0; n < i.length; n++) { 1786 var o = i[n]; 1787 this.addImage(o) 1788 } 1789 if ("string" == typeof this.options.background) { 1790 var r = t.querySelectorAll(this.options.background); 1791 for (n = 0; n < r.length; n++) { 1792 var s = r[n];
vendor: 4,299 bytes, lines 1793-1864
1793 this.addElementBackgroundImages(s) 1794 } 1795 } 1796 } 1797 }; 1798 var d = { 1799 1: !0, 1800 9: !0, 1801 11: !0 1802 }; 1803 return o.prototype.addElementBackgroundImages = function (t) { 1804 var e = getComputedStyle(t); 1805 if (e) 1806 for (var i = /url\((['"])?(.*?)\1\)/gi, n = i.exec(e.backgroundImage); null !== n;) { 1807 var o = n && n[2]; 1808 o && this.addBackground(o, t), n = i.exec(e.backgroundImage) 1809 } 1810 }, o.prototype.addImage = function (t) { 1811 var e = new r(t); 1812 this.images.push(e) 1813 }, o.prototype.addBackground = function (t, e) { 1814 var i = new s(t, e); 1815 this.images.push(i) 1816 }, o.prototype.check = function () { 1817 function t(t, i, n) { 1818 setTimeout(function () { 1819 e.progress(t, i, n) 1820 }) 1821 } 1822 var e = this; 1823 return this.progressedCount = 0, this.hasAnyBroken = !1, this.images.length ? void this.images.forEach(function (e) { 1824 e.once("progress", t), e.check() 1825 }) : void this.complete() 1826 }, o.prototype.progress = function (t, e, i) { 1827 this.progressedCount++ , this.hasAnyBroken = this.hasAnyBroken || !t.isLoaded, this.emitEvent("progress", [this, t, e]), this.jqDeferred && this.jqDeferred.notify && this.jqDeferred.notify(this, t), this.progressedCount == this.images.length && this.complete(), this.options.debug && a && a.log("progress: " + i, t, e) 1828 }, o.prototype.complete = function () { 1829 var t = this.hasAnyBroken ? "fail" : "done"; 1830 if (this.isComplete = !0, this.emitEvent(t, [this]), this.emitEvent("always", [this]), this.jqDeferred) { 1831 var e = this.hasAnyBroken ? "reject" : "resolve"; 1832 this.jqDeferred[e](this) 1833 } 1834 }, r.prototype = Object.create(e.prototype), r.prototype.check = function () { 1835 var t = this.getIsImageComplete(); 1836 return t ? void this.confirm(0 !== this.img.naturalWidth, "naturalWidth") : (this.proxyImage = new Image, this.proxyImage.addEventListener("load", this), this.proxyImage.addEventListener("error", this), this.img.addEventListener("load", this), this.img.addEventListener("error", this), void (this.proxyImage.src = this.img.src)) 1837 }, r.prototype.getIsImageComplete = function () { 1838 return this.img.complete && void 0 !== this.img.naturalWidth 1839 }, r.prototype.confirm = function (t, e) { 1840 this.isLoaded = t, this.emitEvent("progress", [this, this.img, e]) 1841 }, r.prototype.handleEvent = function (t) { 1842 var e = "on" + t.type; 1843 this[e] && this[e](t) 1844 }, r.prototype.onload = function () { 1845 this.confirm(!0, "onload"), this.unbindEvents() 1846 }, r.prototype.onerror = function () { 1847 this.confirm(!1, "onerror"), this.unbindEvents() 1848 }, r.prototype.unbindEvents = function () { 1849 this.proxyImage.removeEventListener("load", this), this.proxyImage.removeEventListener("error", this), this.img.removeEventListener("load", this), this.img.removeEventListener("error", this) 1850 }, s.prototype = Object.create(r.prototype), s.prototype.check = function () { 1851 this.img.addEventListener("load", this), this.img.addEventListener("error", this), this.img.src = this.url; 1852 var t = this.getIsImageComplete(); 1853 t && (this.confirm(0 !== this.img.naturalWidth, "naturalWidth"), this.unbindEvents()) 1854 }, s.prototype.unbindEvents = function () { 1855 this.img.removeEventListener("load", this), this.img.removeEventListener("error", this) 1856 }, s.prototype.confirm = function (t, e) { 1857 this.isLoaded = t, this.emitEvent("progress", [this, this.element, e]) 1858 }, o.makeJQueryPlugin = function (e) { 1859 e = e || t.jQuery, e && (h = e, h.fn.imagesLoaded = function (t, e) { 1860 var i = new o(this, t, e); 1861 return i.jqDeferred.promise(h(this)) 1862 }) 1863 }, o.makeJQueryPlugin(), o 1864 });
1865 1866/* 1867 * jQuery Isotope 1868 * ----------------------------------------------- 1869 */ 1870/*! 1871 * Isotope PACKAGED v2.2.2 1872 * 1873 * http://isotope.metafizzy.co 1874 * Copyright 2015 Metafizzy 1875 */ 1876 1877! function (a) { 1878 function b() { } 1879 1880 function c(a) { 1881 function c(b) { 1882 b.prototype.option || (b.prototype.option = function (b) { 1883 a.isPlainObject(b) && (this.options = a.extend(!0, this.options, b)) 1884 }) 1885 } 1886 1887 function e(b, c) { 1888 a.fn[b] = function (e) { 1889 if ("string" == typeof e) { 1890 for (var g = d.call(arguments, 1), h = 0, i = this.length; i > h; h++) { 1891 var j = this[h], 1892 k = a.data(j, b); 1893 if (k) 1894 if (a.isFunction(k[e]) && "_" !== e.charAt(0)) { 1895 var l = k[e].apply(k, g); 1896 if (void 0 !== l) return l 1897 } else f("no such method '" + e + "' for " + b + " instance"); 1898 else f("cannot call methods on " + b + " prior to initialization; attempted to call '" + e + "'") 1899 } 1900 return this 1901 } 1902 return this.each(function () { 1903 var d = a.data(this, b); 1904 d ? (d.option(e), d._init()) : (d = new c(this, e), a.data(this, b, d)) 1905 }) 1906 } 1907 } 1908 if (a) { 1909 var f = "undefined" == typeof console ? b : function (a) { 1910 console.error(a) 1911 }; 1912 return a.bridget = function (a, b) { 1913 c(b), e(a, b) 1914 }, a.bridget 1915 } 1916 } 1917 var d = Array.prototype.slice; 1918 "function" == typeof define && define.amd ? define("jquery-bridget/jquery.bridget", ["jquery"], c) : c("object" == typeof exports ? require("jquery") : a.jQuery) 1919}(window), 1920 function (a) { 1921 function b(b) { 1922 var c = a.event; 1923 return c.target = c.target || c.srcElement || b, c 1924 } 1925 var c = document.documentElement, 1926 d = function () { }; 1927 c.addEventListener ? d = function (a, b, c) { 1928 a.addEventListener(b, c, !1) 1929 } : c.attachEvent && (d = function (a, c, d) { 1930 a[c + d] = d.handleEvent ? function () { 1931 var c = b(a); 1932 d.handleEvent.call(d, c) 1933 } : function () { 1934 var c = b(a); 1935 d.call(a, c) 1936 }, a.attachEvent("on" + c, a[c + d]) 1937 }); 1938 var e = function () { }; 1939 c.removeEventListener ? e = function (a, b, c) { 1940 a.removeEventListener(b, c, !1) 1941 } : c.detachEvent && (e = function (a, b, c) { 1942 a.detachEvent("on" + b, a[b + c]); 1943 try { 1944 delete a[b + c] 1945 } catch (d) { 1946 a[b + c] = void 0 1947 } 1948 }); 1949 var f = { 1950 bind: d, 1951 unbind: e 1952 }; 1953 "function" == typeof define && define.amd ? define("eventie/eventie", f) : "object" == typeof exports ? module.exports = f : a.eventie = f 1954 }(window), 1955 function () { 1956 "use strict"; 1957 1958 function a() { } 1959 1960 function b(a, b) { 1961 for (var c = a.length; c--;) 1962 if (a[c].listener === b) return c; 1963 return -1 1964 } 1965 1966 function c(a) { 1967 return function () { 1968 return this[a].apply(this, arguments) 1969 } 1970 } 1971 var d = a.prototype, 1972 e = this, 1973 f = e.EventEmitter; 1974 d.getListeners = function (a) { 1975 var b, c, d = this._getEvents(); 1976 if (a instanceof RegExp) { 1977 b = {}; 1978 for (c in d) d.hasOwnProperty(c) && a.test(c) && (b[c] = d[c]) 1979 } else b = d[a] || (d[a] = []); 1980 return b 1981 }, d.flattenListeners = function (a) { 1982 var b, c = []; 1983 for (b = 0; b < a.length; b += 1) c.push(a[b].listener); 1984 return c 1985 }, d.getListenersAsObject = function (a) { 1986 var b, c = this.getListeners(a); 1987 return c instanceof Array && (b = {}, b[a] = c), b || c 1988 }, d.addListener = function (a, c) { 1989 var d, e = this.getListenersAsObject(a), 1990 f = "object" == typeof c; 1991 for (d in e) e.hasOwnProperty(d) && -1 === b(e[d], c) && e[d].push(f ? c : { 1992 listener: c, 1993 once: !1 1994 }); 1995 return this 1996 }, d.on = c("addListener"), d.addOnceListener = function (a, b) { 1997 return this.addListener(a, { 1998 listener: b, 1999 once: !0 2000 }) 2001 }, d.once = c("addOnceListener"), d.defineEvent = function (a) { 2002 return this.getListeners(a), this 2003 }, d.defineEvents = function (a) { 2004 for (var b = 0; b < a.length; b += 1) this.defineEvent(a[b]); 2005 return this 2006 }, d.removeListener = function (a, c) { 2007 var d, e, f = this.getListenersAsObject(a); 2008 for (e in f) f.hasOwnProperty(e) && (d = b(f[e], c), -1 !== d && f[e].splice(d, 1)); 2009 return this 2010 }, d.off = c("removeListener"), d.addListeners = function (a, b) { 2011 return this.manipulateListeners(!1, a, b) 2012 }, d.removeListeners = function (a, b) { 2013 return this.manipulateListeners(!0, a, b) 2014 }, d.manipulateListeners = function (a, b, c) { 2015 var d, e, f = a ? this.removeListener : this.addListener, 2016 g = a ? this.removeListeners : this.addListeners; 2017 if ("object" != typeof b || b instanceof RegExp) 2018 for (d = c.length; d--;) f.call(this, b, c[d]); 2019 else 2020 for (d in b) b.hasOwnProperty(d) && (e = b[d]) && ("function" == typeof e ? f.call(this, d, e) : g.call(this, d, e)); 2021 return this 2022 }, d.removeEvent = function (a) { 2023 var b, c = typeof a, 2024 d = this._getEvents(); 2025 if ("string" === c) delete d[a]; 2026 else if (a instanceof RegExp) 2027 for (b in d) d.hasOwnProperty(b) && a.test(b) && delete d[b]; 2028 else delete this._events; 2029 return this 2030 }, d.removeAllListeners = c("removeEvent"), d.emitEvent = function (a, b) { 2031 var c, d, e, f, g = this.getListenersAsObject(a); 2032 for (e in g) 2033 if (g.hasOwnProperty(e)) 2034 for (d = g[e].length; d--;) c = g[e][d], c.once === !0 && this.removeListener(a, c.listener), f = c.listener.apply(this, b || []), f === this._getOnceReturnValue() && this.removeListener(a, c.listener); 2035 return this 2036 }, d.trigger = c("emitEvent"), d.emit = function (a) { 2037 var b = Array.prototype.slice.call(arguments, 1); 2038 return this.emitEvent(a, b) 2039 }, d.setOnceReturnValue = function (a) { 2040 return this._onceReturnValue = a, this 2041 }, d._getOnceReturnValue = function () { 2042 return this.hasOwnProperty("_onceReturnValue") ? this._onceReturnValue : !0 2043 }, d._getEvents = function () { 2044 return this._events || (this._events = {}) 2045 }, a.noConflict = function () { 2046 return e.EventEmitter = f, a 2047 }, "function" == typeof define && define.amd ? define("eventEmitter/EventEmitter", [], function () { 2048 return a 2049 }) : "object" == typeof module && module.exports ? module.exports = a : e.EventEmitter = a 2050 }.call(this), 2051 function (a) { 2052 function b(a) { 2053 if (a) { 2054 if ("string" == typeof d[a]) return a; 2055 a = a.charAt(0).toUpperCase() + a.slice(1); 2056 for (var b, e = 0, f = c.length; f > e; e++) 2057 if (b = c[e] + a, "string" == typeof d[b]) return b 2058 } 2059 } 2060 var c = "Webkit Moz ms Ms O".split(" "), 2061 d = document.documentElement.style; 2062 "function" == typeof define && define.amd ? define("get-style-property/get-style-property", [], function () { 2063 return b 2064 }) : "object" == typeof exports ? module.exports = b : a.getStyleProperty = b 2065 }(window), 2066 function (a, b) { 2067 function c(a) { 2068 var b = parseFloat(a), 2069 c = -1 === a.indexOf("%") && !isNaN(b); 2070 return c && b 2071 } 2072 2073 function d() { } 2074 2075 function e() { 2076 for (var a = { 2077 width: 0, 2078 height: 0, 2079 innerWidth: 0, 2080 innerHeight: 0, 2081 outerWidth: 0, 2082 outerHeight: 0 2083 }, b = 0, c = h.length; c > b; b++) { 2084 var d = h[b]; 2085 a[d] = 0 2086 } 2087 return a 2088 } 2089 2090 function f(b) { 2091 function d() { 2092 if (!m) { 2093 m = !0; 2094 var d = a.getComputedStyle; 2095 if (j = function () { 2096 var a = d ? function (a) { 2097 return d(a, null) 2098 } : function (a) { 2099 return a.currentStyle 2100 }; 2101 return function (b) { 2102 var c = a(b); 2103 return c || g("Style returned " + c + ". Are you running this code in a hidden iframe on Firefox? See http://bit.ly/getsizebug1"), c 2104 } 2105 }(), k = b("boxSizing")) { 2106 var e = document.createElement("div"); 2107 e.style.width = "200px", e.style.padding = "1px 2px 3px 4px", e.style.borderStyle = "solid", e.style.borderWidth = "1px 2px 3px 4px", e.style[k] = "border-box"; 2108 var f = document.body || document.documentElement; 2109 f.appendChild(e); 2110 var h = j(e); 2111 l = 200 === c(h.width), f.removeChild(e) 2112 } 2113 } 2114 } 2115 2116 function f(a) { 2117 if (d(), "string" == typeof a && (a = document.querySelector(a)), a && "object" == typeof a && a.nodeType) { 2118 var b = j(a); 2119 if ("none" === b.display) return e(); 2120 var f = {}; 2121 f.width = a.offsetWidth, f.height = a.offsetHeight; 2122 for (var g = f.isBorderBox = !(!k || !b[k] || "border-box" !== b[k]), m = 0, n = h.length; n > m; m++) { 2123 var o = h[m], 2124 p = b[o]; 2125 p = i(a, p); 2126 var q = parseFloat(p); 2127 f[o] = isNaN(q) ? 0 : q 2128 } 2129 var r = f.paddingLeft + f.paddingRight, 2130 s = f.paddingTop + f.paddingBottom, 2131 t = f.marginLeft + f.marginRight, 2132 u = f.marginTop + f.marginBottom, 2133 v = f.borderLeftWidth + f.borderRightWidth, 2134 w = f.borderTopWidth + f.borderBottomWidth, 2135 x = g && l, 2136 y = c(b.width); 2137 y !== !1 && (f.width = y + (x ? 0 : r + v)); 2138 var z = c(b.height); 2139 return z !== !1 && (f.height = z + (x ? 0 : s + w)), f.innerWidth = f.width - (r + v), f.innerHe
2139ight = f.height - (s + w), f.outerWidth = f.width + t, f.outerHeight = f.height + u, f 2140 } 2141 } 2142 2143 function i(b, c) { 2144 if (a.getComputedStyle || -1 === c.indexOf("%")) return c; 2145 var d = b.style, 2146 e = d.left, 2147 f = b.runtimeStyle, 2148 g = f && f.left; 2149 return g && (f.left = b.currentStyle.left), d.left = c, c = d.pixelLeft, d.left = e, g && (f.left = g), c 2150 } 2151 var j, k, l, m = !1; 2152 return f 2153 } 2154 var g = "undefined" == typeof console ? d : function (a) { 2155 console.error(a) 2156 }, 2157 h = ["paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "marginLeft", "marginRight", "marginTop", "marginBottom", "borderLeftWidth", "borderRightWidth", "borderTopWidth", "borderBottomWidth"]; 2158 "function" == typeof define && define.amd ? define("get-size/get-size", ["get-style-property/get-style-property"], f) : "object" == typeof exports ? module.exports = f(require("desandro-get-style-property")) : a.getSize = f(a.getStyleProperty) 2159 }(window), 2160 function (a) { 2161 function b(a) { 2162 "function" == typeof a && (b.isReady ? a() : g.push(a)) 2163 } 2164 2165 function c(a) { 2166 var c = "readystatechange" === a.type && "complete" !== f.readyState; 2167 b.isReady || c || d() 2168 } 2169 2170 function d() { 2171 b.isReady = !0; 2172 for (var a = 0, c = g.length; c > a; a++) { 2173 var d = g[a]; 2174 d() 2175 } 2176 } 2177 2178 function e(e) { 2179 return "complete" === f.readyState ? d() : (e.bind(f, "DOMContentLoaded", c), e.bind(f, "readystatechange", c), e.bind(a, "load", c)), b 2180 } 2181 var f = a.document, 2182 g = []; 2183 b.isReady = !1, "function" == typeof define && define.amd ? define("doc-ready/doc-ready", ["eventie/eventie"], e) : "object" == typeof exports ? module.exports = e(require("eventie")) : a.docReady = e(a.eventie) 2184 }(window), 2185 function (a) { 2186 "use strict"; 2187 2188 function b(a, b) { 2189 return a[g](b) 2190 } 2191 2192 function c(a) { 2193 if (!a.parentNode) { 2194 var b = document.createDocumentFragment(); 2195 b.appendChild(a) 2196 } 2197 } 2198 2199 function d(a, b) { 2200 c(a); 2201 for (var d = a.parentNode.querySelectorAll(b), e = 0, f = d.length; f > e; e++) 2202 if (d[e] === a) return !0; 2203 return !1 2204 } 2205 2206 function e(a, d) { 2207 return c(a), b(a, d) 2208 } 2209 var f, g = function () { 2210 if (a.matches) return "matches"; 2211 if (a.matchesSelector) return "matchesSelector"; 2212 for (var b = ["webkit", "moz", "ms", "o"], c = 0, d = b.length; d > c; c++) { 2213 var e = b[c], 2214 f = e + "MatchesSelector"; 2215 if (a[f]) return f 2216 } 2217 }(); 2218 if (g) { 2219 var h = document.createElement("div"), 2220 i = b(h, "div"); 2221 f = i ? b : e 2222 } else f = d; 2223 "function" == typeof define && define.amd ? define("matches-selector/matches-selector", [], function () { 2224 return f 2225 }) : "object" == typeof exports ? module.exports = f : window.matchesSelector = f 2226 }(Element.prototype), 2227 function (a, b) { 2228 "use strict"; 2229 "function" == typeof define && define.amd ? define("fizzy-ui-utils/utils", ["doc-ready/doc-ready", "matches-selector/matches-selector"], function (c, d) { 2230 return b(a, c, d) 2231 }) : "object" == typeof exports ? module.exports = b(a, require("doc-ready"), require("desandro-matches-selector")) : a.fizzyUIUtils = b(a, a.docReady, a.matchesSelector) 2232 }(window, function (a, b, c) { 2233 var d = {}; 2234 d.extend = function (a, b) { 2235 for (var c in b) a[c] = b[c]; 2236 return a 2237 }, d.modulo = function (a, b) { 2238 return (a % b + b) % b 2239 }; 2240 var e = Object.prototype.toString; 2241 d.isArray = function (a) { 2242 return "[object Array]" == e.call(a) 2243 }, d.makeArray = function (a) { 2244 var b = []; 2245 if (d.isArray(a)) b = a; 2246 else if (a && "number" == typeof a.length) 2247 for (var c = 0, e = a.length; e > c; c++) b.push(a[c]); 2248 else b.push(a); 2249 return b 2250 }, d.indexOf = Array.prototype.indexOf ? function (a, b) { 2251 return a.indexOf(b) 2252 } : function (a, b) { 2253 for (var c = 0, d = a.length; d > c; c++) 2254 if (a[c] === b) return c; 2255 return -1 2256 }, d.removeFrom = function (a, b) { 2257 var c = d.indexOf(a, b); - 1 != c && a.splice(c, 1) 2258 }, d.isElement = "function" == typeof HTMLElement || "object" == typeof HTMLElement ? function (a) { 2259 return a instanceof HTMLElement 2260 } : function (a) { 2261 return a && "object" == typeof a && 1 == a.nodeType && "string" == typeof a.nodeName 2262 }, d.setText = function () { 2263 function a(a, c) { 2264 b = b || (void 0 !== document.documentElement.textContent ? "textContent" : "innerText"), a[b] = c 2265 } 2266 var b; 2267 return a 2268 }(), d.getParent = function (a, b) { 2269 for (; a != document.body;) 2270 if (a = a.parentNode, c(a, b)) return a 2271 }, d.getQueryElement = function (a) { 2272 return "string" == typeof a ? document.querySelector(a) : a 2273 }, d.handleEvent = function (a) { 2274 var b = "on" + a.type; 2275 this[b] && this[b](a) 2276 }, d.filterFindElements = function (a, b) { 2277 a = d.makeArray(a); 2278 for (var e = [], f = 0, g = a.length; g > f; f++) { 2279 var h = a[f]; 2280 if (d.isElement(h)) 2281 if (b) { 2282 c(h, b) && e.push(h); 2283 for (var i = h.querySelectorAll(b), j = 0, k = i.length; k > j; j++) e.push(i[j]) 2284 } else e.push(h) 2285 } 2286 return e 2287 }, d.debounceMethod = function (a, b, c) { 2288 var d = a.prototype[b], 2289 e = b + "Timeout"; 2290 a.prototype[b] = function () { 2291 var a = this[e]; 2292 a && clearTimeout(a); 2293 var b = arguments, 2294 f = this; 2295 this[e] = setTimeout(function () { 2296 d.apply(f, b), delete f[e] 2297 }, c || 100) 2298 } 2299 }, d.toDashed = function (a) { 2300 return a.replace(/(.)([A-Z])/g, function (a, b, c) { 2301 return b + "-" + c 2302 }).toLowerCase() 2303 }; 2304 var f = a.console; 2305 return d.htmlInit = function (c, e) { 2306 b(function () { 2307 for (var b = d.toDashed(e), g = document.querySelectorAll(".js-" + b), h = "data-" + b + "-options", i = 0, j = g.length; j > i; i++) { 2308 var k, l = g[i], 2309 m = l.getAttribute(h); 2310 try { 2311 k = m && JSON.parse(m) 2312 } catch (n) { 2313 f && f.error("Error parsing " + h + " on " + l.no
2313deName.toLowerCase() + (l.id ? "#" + l.id : "") + ": " + n); 2314 continue 2315 } 2316 var o = new c(l, k), 2317 p = a.jQuery; 2318 p && p.data(l, e, o) 2319 } 2320 }) 2321 }, d 2322 }), 2323 function (a, b) { 2324 "use strict"; 2325 "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 (c, d, e, f) { 2326 return b(a, c, d, e, f) 2327 }) : "object" == typeof exports ? module.exports = b(a, require("wolfy87-eventemitter"), require("get-size"), require("desandro-get-style-property"), require("fizzy-ui-utils")) : (a.Outlayer = {}, a.Outlayer.Item = b(a, a.EventEmitter, a.getSize, a.getStyleProperty, a.fizzyUIUtils)) 2328 }(window, function (a, b, c, d, e) { 2329 "use strict"; 2330 2331 function f(a) { 2332 for (var b in a) return !1; 2333 return b = null, !0 2334 } 2335 2336 function g(a, b) { 2337 a && (this.element = a, this.layout = b, this.position = { 2338 x: 0, 2339 y: 0 2340 }, this._create()) 2341 } 2342 2343 function h(a) { 2344 return a.replace(/([A-Z])/g, function (a) { 2345 return "-" + a.toLowerCase() 2346 }) 2347 } 2348 var i = a.getComputedStyle, 2349 j = i ? function (a) { 2350 return i(a, null) 2351 } : function (a) { 2352 return a.currentStyle 2353 }, 2354 k = d("transition"), 2355 l = d("transform"), 2356 m = k && l, 2357 n = !!d("perspective"), 2358 o = { 2359 WebkitTransition: "webkitTransitionEnd", 2360 MozTransition: "transitionend", 2361 OTransition: "otransitionend", 2362 transition: "transitionend" 2363 }[k], 2364 p = ["transform", "transition", "transitionDuration", "transitionProperty"], 2365 q = function () { 2366 for (var a = {}, b = 0, c = p.length; c > b; b++) { 2367 var e = p[b], 2368 f = d(e); 2369 f && f !== e && (a[e] = f) 2370 } 2371 return a 2372 }(); 2373 e.extend(g.prototype, b.prototype), g.prototype._create = function () { 2374 this._transn = { 2375 ingProperties: {}, 2376 clean: {}, 2377 onEnd: {} 2378 }, this.css({ 2379 position: "absolute" 2380 }) 2381 }, g.prototype.handleEvent = function (a) { 2382 var b = "on" + a.type; 2383 this[b] && this[b](a) 2384 }, g.prototype.getSize = function () { 2385 this.size = c(this.element) 2386 }, g.prototype.css = function (a) { 2387 var b = this.element.style; 2388 for (var c in a) { 2389 var d = q[c] || c; 2390 b[d] = a[c] 2391 } 2392 }, g.prototype.getPosition = function () { 2393 var a = j(this.element), 2394 b = this.layout.options, 2395 c = b.isOriginLeft, 2396 d = b.isOriginTop, 2397 e = a[c ? "left" : "right"], 2398 f = a[d ? "top" : "bottom"], 2399 g = this.layout.size, 2400 h = -1 != e.indexOf("%") ? parseFloat(e) / 100 * g.width : parseInt(e, 10), 2401 i = -1 != f.indexOf("%") ? parseFloat(f) / 100 * g.height : parseInt(f, 10); 2402 h = isNaN(h) ? 0 : h, i = isNaN(i) ? 0 : i, h -= c ? g.paddingLeft : g.paddingRight, i -= d ? g.paddingTop : g.paddingBottom, this.position.x = h, this.position.y = i 2403 }, g.prototype.layoutPosition = function () { 2404 var a = this.layout.size, 2405 b = this.layout.options, 2406 c = {}, 2407 d = b.isOriginLeft ? "paddingLeft" : "paddingRight", 2408 e = b.isOriginLeft ? "left" : "right", 2409 f = b.isOriginLeft ? "right" : "left", 2410 g = this.position.x + a[d]; 2411 c[e] = this.getXValue(g), c[f] = ""; 2412 var h = b.isOriginTop ? "paddingTop" : "paddingBottom", 2413 i = b.isOriginTop ? "top" : "bottom", 2414 j = b.isOriginTop ? "bottom" : "top", 2415 k = this.position.y + a[h]; 2416 c[i] = this.getYValue(k), c[j] = "", this.css(c), this.emitEvent("layout", [this]) 2417 }, g.prototype.getXValue = function (a) { 2418 var b = this.layout.options; 2419 return b.percentPosition && !b.isHorizontal ? a / this.layout.size.width * 100 + "%" : a + "px" 2420 }, g.prototype.getYValue = function (a) { 2421 var b = this.layout.options; 2422 return b.percentPosition && b.isHorizontal ? a / this.layout.size.height * 100 + "%" : a + "px" 2423 }
2423, g.prototype._transitionTo = function (a, b) { 2424 this.getPosition(); 2425 var c = this.position.x, 2426 d = this.position.y, 2427 e = parseInt(a, 10), 2428 f = parseInt(b, 10), 2429 g = e === this.position.x && f === this.position.y; 2430 if (this.setPosition(a, b), g && !this.isTransitioning) return void this.layoutPosition(); 2431 var h = a - c, 2432 i = b - d, 2433 j = {}; 2434 j.transform = this.getTranslate(h, i), this.transition({ 2435 to: j, 2436 onTransitionEnd: { 2437 transform: this.layoutPosition 2438 }, 2439 isCleaning: !0 2440 }) 2441 }, g.prototype.getTranslate = function (a, b) { 2442 var c = this.layout.options; 2443 return a = c.isOriginLeft ? a : -a, b = c.isOriginTop ? b : -b, n ? "translate3d(" + a + "px, " + b + "px, 0)" : "translate(" + a + "px, " + b + "px)" 2444 }, g.prototype.goTo = function (a, b) { 2445 this.setPosition(a, b), this.layoutPosition() 2446 }, g.prototype.moveTo = m ? g.prototype._transitionTo : g.prototype.goTo, g.prototype.setPosition = function (a, b) { 2447 this.position.x = parseInt(a, 10), this.position.y = parseInt(b, 10) 2448 }, g.prototype._nonTransition = function (a) { 2449 this.css(a.to), a.isCleaning && this._removeStyles(a.to); 2450 for (var b in a.onTransitionEnd) a.onTransitionEnd[b].call(this) 2451 }, g.prototype._transition = function (a) { 2452 if (!parseFloat(this.layout.options.transitionDuration)) return void this._nonTransition(a); 2453 var b = this._transn; 2454 for (var c in a.onTransitionEnd) b.onEnd[c] = a.onTransitionEnd[c]; 2455 for (c in a.to) b.ingProperties[c] = !0, a.isCleaning && (b.clean[c] = !0); 2456 if (a.from) { 2457 this.css(a.from); 2458 var d = this.element.offsetHeight; 2459 d = null 2460 } 2461 this.enableTransition(a.to), this.css(a.to), this.isTransitioning = !0 2462 }; 2463 var r = "opacity," + h(q.transform || "transform"); 2464 g.prototype.enableTransition = function () { 2465 this.isTransitioning || (this.css({ 2466 transitionProperty: r, 2467 transitionDuration: this.layout.options.transitionDuration 2468 }), this.element.addEventListener(o, this, !1)) 2469 }, g.prototype.transition = g.prototype[k ? "_transition" : "_nonTransition"], g.prototype.onwebkitTransitionEnd = function (a) { 2470 this.ontransitionend(a) 2471 }, g.prototype.onotransitionend = function (a) { 2472 this.ontransitionend(a) 2473 }; 2474 var s = { 2475 "-webkit-transform": "transform", 2476 "-moz-transform": "transform", 2477 "-o-transform": "transform" 2478 }; 2479 g.prototype.ontransitionend = function (a) { 2480 if (a.target === this.element) { 2481 var b = this._transn, 2482 c = s[a.propertyName] || a.propertyName; 2483 if (delete b.ingProperties[c], f(b.ingProperties) && this.disableTransition(), c in b.clean && (this.element.style[a.propertyName] = "", delete b.clean[c]), c in b.onEnd) { 2484 var d = b.onEnd[c]; 2485 d.call(this), delete b.onEnd[c] 2486 } 2487 this.emitEvent("transitionEnd", [this]) 2488 } 2489 }, g.prototype.disableTransition = function () { 2490 this.removeTransitionStyles(), this.element.removeEventListener(o, this, !1), this.isTransitioning = !1 2491 }, g.prototype._removeStyles = function (a) { 2492 var b = {}; 2493 for (var c in a) b[c] = ""; 2494 this.css(b) 2495 }; 2496 var t = { 2497 transitionProperty: "", 2498 transitionDuration: "" 2499 }; 2500 return g.prototype.removeTransitionStyles = function () { 2501 this.css(t) 2502 }, g.prototype.removeElem = function () { 2503 this.element.parentNode.removeChild(this.element), this.css({ 2504 display: "" 2505 }), this.emitEvent("remove", [this]) 2506 }, g.prototype.remove = function () { 2507 if (!k || !parseFloat(this.layout.options.transitionDuration)) return void this.removeElem(); 2508 var a = this; 2509 this.once("transitionEnd", function () { 2510 a.removeElem() 2511 }), this.hide() 2512 }, g.prototype.reveal = function () { 2513 delete this.isHidden, this.css({ 2514 display: "" 2515 }); 2516 var a = this.layout.options, 2517 b = {}, 2518 c = this.getHideRevealTransitionEndProperty("visibleStyle"); 2519 b[c] = this.onRevealTransitionEnd, this.transition({ 2520 from: a.hiddenStyle, 2521 to: a.visibleStyle, 2522 isCleaning: !0, 2523 onTransitionEnd: b 2524 }) 2525 }, g.prototype.onRevealTransitionEnd = function () { 2526 this.isHidden || this.emitEvent("reveal") 2527 }, g.prototype.getHideRevealTransitionEndProperty = function (a) { 2528 var b = this.layout.options[a]; 2529 if (b.opacity) return "opacity"; 2530 for (var c in b) return c 2531 }, g.prototype.hide = function () { 2532 this.isHidden = !0, this.css({ 2533 display: "" 2534 }); 2535 var a = this.layout.options, 2536 b = {}, 2537 c = this.getHideRevealTransitionEndProperty("hiddenStyle"); 2538 b[c] = this.onHideTransitionEnd, this.transition({ 2539 from: a.visibleStyle, 2540 to: a.hiddenStyle, 2541 isCleaning: !0, 2542 onTransitionEnd: b 2543 }) 2544 }, g.prototype.onHideTransitionEnd = function () { 2545 this.isHidden && (this.css({ 2546 display: "none" 2547 }), this.emitEvent("hide")) 2548 }, g.prototype.destroy = function () { 2549 this.css({ 2550 position: "", 2551 left: "", 2552 right: "", 2553 top: "", 2554 bottom: "", 2555 transition: "", 2556 transform: "" 2557 }) 2558 }, g 2559 }), 2560 function (a, b) { 2561 "use strict"; 2562 "function" == typeof define && define.amd ? define("outlayer/outlayer", ["eventie/eventie", "eventEmitter/EventEmitter", "get-size/get-size", "fizzy-ui-utils/utils", "./item"], function (c, d, e, f, g) { 2563 return b(a, c, d, e, f, g) 2564 }) : "object" == typeof exports ? module.exports = b(a, require("eventie"), require("wolfy87-eventemitter"), require("get-size"), require("fizzy-ui-utils"), require("./item")) : a.Outlayer = b(a, a.eventie, a.EventEmitter, a.getSize, a.fizzyUIUtils, a.Outlayer.Item) 2565 }(window, function (a, b, c, d, e, f) { 2566 "use strict"; 2567 2568 function g(a, b) { 2569 var c = e.getQueryElement(a); 2570 if (!c) return void (h && h.error("Bad element for " + this.constructor.namespace + ": " + (c || a))); 2571 this.element = c, i && (this.$element = i(this.element)), this.options = e.extend({}, this.constructor.defaults), this.option(b); 2572 var d = ++k; 2573 this.element.outlayerGUID = d, l[d] = this, this._create(), this.options.isInitLayout && this.layout() 2574 } 2575 var h = a.console, 2576 i = a.jQuery, 2577 j = function () { }, 2578 k = 0, 2579 l = {}; 2580 return g.namespace = "outlayer", g.Item = f, g.defaults = { 2581 containerStyle: { 2582 position: "relative" 2583 }, 2584 isInitLayout: !0, 2585 isOriginLeft: !0, 2586 isOriginTop: !0, 2587 isResizeBound: !0, 2588 isResizingContainer: !0, 2589 transitionDuration: "0.4s", 2590 hiddenStyle: { 2591 opacity: 0, 2592 transform: "scale(0.001)" 2593 }, 2594 visibleStyle: { 2595 opacity: 1, 2596 transform: "scale(1)" 2597 } 2598 }, e.extend(g.prototype, c.prototype), g.prototype.option = function (a) { 2599 e.extend(this.options, a) 2600 }, g.prototype._create = function () { 2601 this.reloadItems(), this.stamps = [], this.stamp(this.options.stamp), e.extend(this.element.style, this.options.containerStyle), this.options.isResizeBound && this.bindResize() 2602 }, g.prototype.reloadItems = function () { 2603 this.items = this._itemize(this.element.children) 2604 }, g.prototype._itemize = function (a) { 2605 for (var b = this._filterFindItemElements(a), c = this.constructor.Item, d = [], e = 0, f = b.length; f > e; e++) { 2606 var g = b[e], 2607 h = new c(g, this); 2608 d.push(h) 2609 } 2610 return d 2611 }, g.prototype._filterFindItemElements = function (a) { 2612 return e.filterFindElements(a, this.options.itemSelector) 2613 }, g.prototype.getItemElements = function () { 2614 for (var a = [], b = 0, c = this.items.length; c > b; b++) a.push(this.items[b].element); 2615 return a 2616 }, g.prototype.layout = function () { 2617 this._resetLayout(), this._manageStamps(); 2618 var a = void 0 !== this.options.isLayoutInstant ? this.options.isLayoutInstant : !this._isLayoutInited; 2619 this.layoutItems(this.items, a), this._isLayoutInited = !0 2620 }, g.prototype._init = g.prototype.layout, g.prototype._resetLayout = function () {
2621 this.getSize() 2622 }, g.prototype.getSize = function () { 2623 this.size = d(this.element) 2624 }, g.prototype._getMeasurement = function (a, b) { 2625 var c, f = this.options[a]; 2626 f ? ("string" == typeof f ? c = this.element.querySelector(f) : e.isElement(f) && (c = f), this[a] = c ? d(c)[b] : f) : this[a] = 0 2627 }, g.prototype.layoutItems = function (a, b) { 2628 a = this._getItemsForLayout(a), this._layoutItems(a, b), this._postLayout() 2629 }, g.prototype._getItemsForLayout = function (a) { 2630 for (var b = [], c = 0, d = a.length; d > c; c++) { 2631 var e = a[c]; 2632 e.isIgnored || b.push(e) 2633 } 2634 return b 2635 }, g.prototype._layoutItems = function (a, b) { 2636 if (this._emitCompleteOnItems("layout", a), a && a.length) { 2637 for (var c = [], d = 0, e = a.length; e > d; d++) { 2638 var f = a[d], 2639 g = this._getItemLayoutPosition(f); 2640 g.item = f, g.isInstant = b || f.isLayoutInstant, c.push(g) 2641 } 2642 this._processLayoutQueue(c) 2643 } 2644 }, g.prototype._getItemLayoutPosition = function () { 2645 return { 2646 x: 0, 2647 y: 0 2648 } 2649 }, g.prototype._processLayoutQueue = function (a) { 2650 for (var b = 0, c = a.length; c > b; b++) { 2651 var d = a[b]; 2652 this._positionItem(d.item, d.x, d.y, d.isInstant) 2653 } 2654 }, g.prototype._positionItem = function (a, b, c, d) { 2655 d ? a.goTo(b, c) : a.moveTo(b, c) 2656 }, g.prototype._postLayout = function () { 2657 this.resizeContainer() 2658 }, g.prototype.resizeContainer = function () { 2659 if (this.options.isResizingContainer) { 2660 var a = this._getContainerSize(); 2661 a && (this._setContainerMeasure(a.width, !0), this._setContainerMeasure(a.height, !1)) 2662 } 2663 }, g.prototype._getContainerSize = j, g.prototype._setContainerMeasure = function (a, b) { 2664 if (void 0 !== a) { 2665 var c = this.size; 2666 c.isBorderBox && (a += b ? c.paddingLeft + c.paddingRight + c.borderLeftWidth + c.borderRightWidth : c.paddingBottom + c.paddingTop + c.borderTopWidth + c.borderBottomWidth), a = Math.max(a, 0), this.element.style[b ? "width" : "height"] = a + "px" 2667 } 2668 }, g.prototype._emitCompleteOnItems = function (a, b) { 2669 function c() { 2670 e.dispatchEvent(a + "Complete", null, [b]) 2671 } 2672 2673 function d() { 2674 g++ , g === f && c() 2675 } 2676 var e = this, 2677 f = b.length; 2678 if (!b || !f) return void c(); 2679 for (var g = 0, h = 0, i = b.length; i > h; h++) { 2680 var j = b[h]; 2681 j.once(a, d) 2682 } 2683 }, g.prototype.dispatchEvent = function (a, b, c) { 2684 var d = b ? [b].concat(c) : c; 2685 if (this.emitEvent(a, d), i) 2686 if (this.$element = this.$element || i(this.element), b) { 2687 var e = i.Event(b); 2688 e.type = a, this.$element.trigger(e, c) 2689 } else this.$element.trigger(a, c) 2690 }, g.prototype.ignore = function (a) { 2691 var b = this.getItem(a); 2692 b && (b.isIgnored = !0) 2693 }, g.prototype.unignore = function (a) { 2694 var b = this.getItem(a); 2695 b && delete b.isIgnored 2696 }, g.prototype.stamp = function (a) { 2697 if (a = this._find(a)) { 2698 this.stamps = this.stamps.concat(a); 2699 for (var b = 0, c = a.length; c > b; b++) { 2700 var d = a[b]; 2701 this.ignore(d) 2702 } 2703 } 2704 }, g.prototype.unstamp = function (a) { 2705 if (a = this._find(a)) 2706 for (var b = 0, c = a.length; c > b; b++) { 2707 var d = a[b]; 2708 e.removeFrom(this.stamps, d), this.unignore(d) 2709 } 2710 }, g.prototype._find = function (a) { 2711 return a ? ("string" == typeof a && (a = this.element.querySelectorAll(a)), a = e.makeArray(a)) : void 0 2712 }, g.prototype._manageStamps = function () { 2713 if (this.stamps && this.stamps.length) {
2714 this._getBoundingRect(); 2715 for (var a = 0, b = this.stamps.length; b > a; a++) { 2716 var c = this.stamps[a]; 2717 this._manageStamp(c) 2718 } 2719 } 2720 }, g.prototype._getBoundingRect = function () { 2721 var a = this.element.getBoundingClientRect(), 2722 b = this.size; 2723 this._boundingRect = { 2724 left: a.left + b.paddingLeft + b.borderLeftWidth, 2725 top: a.top + b.paddingTop + b.borderTopWidth, 2726 right: a.right - (b.paddingRight + b.borderRightWidth), 2727 bottom: a.bottom - (b.paddingBottom + b.borderBottomWidth) 2728 } 2729 }, g.prototype._manageStamp = j, g.prototype._getElementOffset = function (a) { 2730 var b = a.getBoundingClientRect(), 2731 c = this._boundingRect, 2732 e = d(a), 2733 f = { 2734 left: b.left - c.left - e.marginLeft, 2735 top: b.top - c.top - e.marginTop, 2736 right: c.right - b.right - e.marginRight, 2737 bottom: c.bottom - b.bottom - e.marginBottom 2738 }; 2739 return f 2740 }, g.prototype.handleEvent = function (a) { 2741 var b = "on" + a.type; 2742 this[b] && this[b](a) 2743 }, g.prototype.bindResize = function () { 2744 this.isResizeBound || (b.bind(a, "resize", this), this.isResizeBound = !0) 2745 }, g.prototype.unbindResize = function () { 2746 this.isResizeBound && b.unbind(a, "resize", this), this.isResizeBound = !1 2747 }, g.prototype.onresize = function () { 2748 function a() { 2749 b.resize(), delete b.resizeTimeout 2750 } 2751 this.resizeTimeout && clearTimeout(this.resizeTimeout); 2752 var b = this; 2753 this.resizeTimeout = setTimeout(a, 100) 2754 }, g.prototype.resize = function () { 2755 this.isResizeBound && this.needsResizeLayout() && this.layout() 2756 }, g.prototype.needsResizeLayout = function () { 2757 var a = d(this.element), 2758 b = this.size && a; 2759 return b && a.innerWidth !== this.size.innerWidth 2760 }, g.prototype.addItems = function (a) { 2761 var b = this._itemize(a); 2762 return b.length && (this.items = this.items.concat(b)), b 2763 }, g.prototype.appended = function (a) { 2764 var b = this.addItems(a); 2765 b.length && (this.layoutItems(b, !0), this.reveal(b)) 2766 }, g.prototype.prepended = function (a) { 2767 var b = this._itemize(a); 2768 if (b.length) { 2769 var c = this.items.slice(0); 2770 this.items = b.concat(c), this._resetLayout(), this._manageStamps(), this.layoutItems(b, !0), this.reveal(b), this.layoutItems(c) 2771 } 2772 }, g.prototype.reveal = function (a) { 2773 this._emitCompleteOnItems("reveal", a); 2774 for (var b = a && a.length, c = 0; b && b > c; c++) { 2775 var d = a[c]; 2776 d.reveal() 2777 } 2778 }, g.prototype.hide = function (a) { 2779 this._emitCompleteOnItems("hide", a); 2780 for (var b = a && a.length, c = 0; b && b > c; c++) { 2781 var d = a[c]; 2782 d.hide() 2783 } 2784 }, g.prototype.revealItemElements = function (a) { 2785 var b = this.getItems(a); 2786 this.reveal(b) 2787 }, g.prototype.hideItemElements = function (a) { 2788 var b = this.getItems(a); 2789 this.hide(b) 2790 }, g.prototype.getItem = function (a) { 2791 for (var b = 0, c = this.items.length; c > b; b++) { 2792 var d = this.items[b]; 2793 if (d.element === a) return d 2794 } 2795 }, g.prototype.getItems = function (a) { 2796 a = e.makeArray(a); 2797 for (var b = [], c = 0, d = a.length; d > c; c++) { 2798 var f = a[c], 2799 g = this.getItem(f); 2800 g && b.push(g) 2801 } 2802 return b 2803 }, g.prototype.remove = function (a) { 2804 var b = this.getItems(a); 2805 if (this._emitCompleteOnItems("remove", b), b && b.length) 2806 for (var c = 0, d = b.length; d > c; c++) { 2807 var f = b[c]; 2808 f.remove(), e.removeFrom(this.items, f) 2809 } 2810 }, g.prototype.destroy = function () { 2811 var a = this.element.style; 2812 a.height = "", a.position = "", a.width = ""; 2813 for (var b = 0, c = this.items.length; c > b; b++) { 2814 var d = this.items[b]; 2815 d.destroy() 2816 } 2817 this.unbindResize(); 2818 var e = this.element.outlayerGUID; 2819 delete l[e], delete this.element.outlayerGUID, i && i.removeData(this.element, this.constructor.namespace) 2820 }, g.data = function (a) { 2821 a = e.getQueryElement(a); 2822 var b = a && a.outlayerGUID; 2823 return b && l[b] 2824 }, g.create = function (a, b) { 2825 function c() { 2826 g.apply(this, arguments) 2827 } 2828 return Object.create ? c.prototype = Object.create(g.prototype) : e.extend(c.prototype, g.prototype), c.prototype.constructor = c, c.defaults = e.extend({}, g.defaults), e.extend(c.defaults, b), c.prototype.settings = {}, c.namespace = a, c.data = g.data, c.Item = function () { 2829 f.apply(this, arguments) 2830 }, c.Item.prototype = new f, e.htmlInit(c, a), i && i.bridget && i.bridget(a, c), c 2831 }, g.Item = f, g 2832 }), 2833 function (a, b) { 2834 "use strict"; 2835 "function" == typeof define && define.amd ? define("isotope/js/item", ["outlayer/outlayer"], b) : "object" == typeof exports ? module.exports = b(require("outlayer")) : (a.Isotope = a.Isotope || {}, a.Isotope.Item = b(a.Outlayer)) 2836 }(window, function (a) { 2837 "use strict"; 2838 2839 function b() { 2840 a.Item.apply(this, arguments) 2841 } 2842 b.prototype = new a.Item, b.prototype._create = function () { 2843 this.id = this.layout.itemGUID++ , a.Item.prototype._create.call(this), this.sortData = {} 2844 }, b.prototype.updateSortData = function () { 2845 if (!this.isIgnored) { 2846 this.sortData.id = this.id, this.sortData["original-order"] = this.id, this.sortData.random = Math.random(); 2847 var a = this.layout.options.getSortData, 2848 b = this.layout._sorters; 2849 for (var c in a) { 2850 var d = b[c]; 2851 this.sortData[c] = d(this.element, this) 2852 } 2853 } 2854 }; 2855 var c = b.prototype.destroy; 2856 return b.prototype.destroy = function () { 2857 c.apply(this, arguments), this.css({ 2858 display: "" 2859 }) 2860 }, b 2861 }), 2862 function (a, b) { 2863 "use strict"; 2864 "function" == typeof define && define.amd ? define("isotope/js/layout-mode", ["get-size/get-size", "outlayer/outlayer"], b) : "object" == typeof exports ? module.exports = b(require("get-size"), require("outlayer")) : (a.Isotope = a.Isotope || {}, a.Isotope.LayoutMode = b(a.getSize, a.Outlayer)) 2865 }(window, function (a, b) { 2866 "use strict"; 2867 2868 function c(a) { 2869 this.isotope = a, a && (this.options = a.options[this.namespace], this.element = a.element, this.items = a.filteredItems, this.size = a.size) 2870 } 2871 return function () { 2872 function a(a) { 2873 return function () { 2874 return b.prototype[a].apply(this.isotope, arguments) 2875 } 2876 } 2877 for (var d = ["_resetLayout", "_getItemLayoutPosition", "_manageStamp", "_getContainerSize", "_getElementOffset", "needsResizeLayout"], e = 0, f = d.length; f > e; e++) { 2878 var g = d[e]; 2879 c.prototype[g] = a(g) 2880 } 2881 }(), c.prototype.needsVerticalResizeLayout = function () { 2882 var b = a(this.isotope.element), 2883 c = this.isotope.size && b;
vendor: 11,480 bytes, lines 2884-3103
2884 return c && b.innerHeight != this.isotope.size.innerHeight 2885 }, c.prototype._getMeasurement = function () { 2886 this.isotope._getMeasurement.apply(this, arguments) 2887 }, c.prototype.getColumnWidth = function () { 2888 this.getSegmentSize("column", "Width") 2889 }, c.prototype.getRowHeight = function () { 2890 this.getSegmentSize("row", "Height") 2891 }, c.prototype.getSegmentSize = function (a, b) { 2892 var c = a + b, 2893 d = "outer" + b; 2894 if (this._getMeasurement(c, d), !this[c]) { 2895 var e = this.getFirstItemSize(); 2896 this[c] = e && e[d] || this.isotope.size["inner" + b] 2897 } 2898 }, c.prototype.getFirstItemSize = function () { 2899 var b = this.isotope.filteredItems[0]; 2900 return b && b.element && a(b.element) 2901 }, c.prototype.layout = function () { 2902 this.isotope.layout.apply(this.isotope, arguments) 2903 }, c.prototype.getSize = function () { 2904 this.isotope.getSize(), this.size = this.isotope.size 2905 }, c.modes = {}, c.create = function (a, b) { 2906 function d() { 2907 c.apply(this, arguments) 2908 } 2909 return d.prototype = new c, b && (d.options = b), d.prototype.namespace = a, c.modes[a] = d, d 2910 }, c 2911 }), 2912 function (a, b) { 2913 "use strict"; 2914 "function" == typeof define && define.amd ? define("masonry/masonry", ["outlayer/outlayer", "get-size/get-size", "fizzy-ui-utils/utils"], b) : "object" == typeof exports ? module.exports = b(require("outlayer"), require("get-size"), require("fizzy-ui-utils")) : a.Masonry = b(a.Outlayer, a.getSize, a.fizzyUIUtils) 2915 }(window, function (a, b, c) { 2916 var d = a.create("masonry"); 2917 return d.prototype._resetLayout = function () { 2918 this.getSize(), this._getMeasurement("columnWidth", "outerWidth"), this._getMeasurement("gutter", "outerWidth"), this.measureColumns(); 2919 var a = this.cols; 2920 for (this.colYs = []; a--;) this.colYs.push(0); 2921 this.maxY = 0 2922 }, d.prototype.measureColumns = function () { 2923 if (this.getContainerWidth(), !this.columnWidth) { 2924 var a = this.items[0], 2925 c = a && a.element; 2926 this.columnWidth = c && b(c).outerWidth || this.containerWidth 2927 } 2928 var d = this.columnWidth += this.gutter, 2929 e = this.containerWidth + this.gutter, 2930 f = e / d, 2931 g = d - e % d, 2932 h = g && 1 > g ? "round" : "floor"; 2933 f = Math[h](f), this.cols = Math.max(f, 1) 2934 }, d.prototype.getContainerWidth = function () { 2935 var a = this.options.isFitWidth ? this.element.parentNode : this.element, 2936 c = b(a); 2937 this.containerWidth = c && c.innerWidth 2938 }, d.prototype._getItemLayoutPosition = function (a) { 2939 a.getSize(); 2940 var b = a.size.outerWidth % this.columnWidth, 2941 d = b && 1 > b ? "round" : "ceil", 2942 e = Math[d](a.size.outerWidth / this.columnWidth); 2943 e = Math.min(e, this.cols); 2944 for (var f = this._getColGroup(e), g = Math.min.apply(Math, f), h = c.indexOf(f, g), i = { 2945 x: this.columnWidth * h, 2946 y: g 2947 }, j = g + a.size.outerHeight, k = this.cols + 1 - f.length, l = 0; k > l; l++) this.colYs[h + l] = j; 2948 return i 2949 }, d.prototype._getColGroup = function (a) { 2950 if (2 > a) return this.colYs; 2951 for (var b = [], c = this.cols + 1 - a, d = 0; c > d; d++) { 2952 var e = this.colYs.slice(d, d + a); 2953 b[d] = Math.max.apply(Math, e) 2954 } 2955 return b 2956 }, d.prototype._manageStamp = function (a) { 2957 var c = b(a), 2958 d = this._getElementOffset(a), 2959 e = this.options.isOriginLeft ? d.left : d.right, 2960 f = e + c.outerWidth, 2961 g = Math.floor(e / this.columnWidth); 2962 g = Math.max(0, g); 2963 var h = Math.floor(f / this.columnWidth); 2964 h -= f % this.columnWidth ? 0 : 1, h = Math.min(this.cols - 1, h); 2965 for (var i = (this.options.isOriginTop ? d.top : d.bottom) + c.outerHeight, j = g; h >= j; j++) this.colYs[j] = Math.max(i, this.colYs[j]) 2966 }, d.prototype._getContainerSize = function () { 2967 this.maxY = Math.max.apply(Math, this.colYs); 2968 var a = { 2969 height: this.maxY 2970 }; 2971 return this.options.isFitWidth && (a.width = this._getContainerFitWidth()), a 2972 }, d.prototype._getContainerFitWidth = function () { 2973 for (var a = 0, b = this.cols; --b && 0 === this.colYs[b];) a++; 2974 return (this.cols - a) * this.columnWidth - this.gutter 2975 }, d.prototype.needsResizeLayout = function () { 2976 var a = this.containerWidth; 2977 return this.getContainerWidth(), a !== this.containerWidth 2978 }, d 2979 }), 2980 function (a, b) { 2981 "use strict"; 2982 "function" == typeof define && define.amd ? define("isotope/js/layout-modes/masonry", ["../layout-mode", "masonry/masonry"], b) : "object" == typeof exports ? module.exports = b(require("../layout-mode"), require("masonry-layout")) : b(a.Isotope.LayoutMode, a.Masonry) 2983 }(window, function (a, b) { 2984 "use strict"; 2985 2986 function c(a, b) { 2987 for (var c in b) a[c] = b[c]; 2988 return a 2989 } 2990 var d = a.create("masonry"), 2991 e = d.prototype._getElementOffset, 2992 f = d.prototype.layout, 2993 g = d.prototype._getMeasurement; 2994 c(d.prototype, b.prototype), d.prototype._getElementOffset = e, d.prototype.layout = f, d.prototype._getMeasurement = g; 2995 var h = d.prototype.measureColumns; 2996 d.prototype.measureColumns = function () { 2997 this.items = this.isotope.filteredItems, h.call(this) 2998 }; 2999 var i = d.prototype._manageStamp; 3000 return d.prototype._manageStamp = function () { 3001 this.options.isOriginLeft = this.isotope.options.isOriginLeft, this.options.isOriginTop = this.isotope.options.isOriginTop, i.apply(this, arguments) 3002 }, d 3003 }), 3004 function (a, b) { 3005 "use strict"; 3006 "function" == typeof define && define.amd ? define("isotope/js/layout-modes/fit-rows", ["../layout-mode"], b) : "object" == typeof exports ? module.exports = b(require("../layout-mode")) : b(a.Isotope.LayoutMode) 3007 }(window, function (a) { 3008 "use strict"; 3009 var b = a.create("fitRows"); 3010 return b.prototype._resetLayout = function () { 3011 this.x = 0, this.y = 0, this.maxY = 0, this._getMeasurement("gutter", "outerWidth") 3012 }, b.prototype._getItemLayoutPosition = function (a) { 3013 a.getSize(); 3014 var b = a.size.outerWidth + this.gutter, 3015 c = this.isotope.size.innerWidth + this.gutter; 3016 0 !== this.x && b + this.x > c && (this.x = 0, this.y = this.maxY); 3017 var d = { 3018 x: this.x, 3019 y: this.y 3020 }; 3021 return this.maxY = Math.max(this.maxY, this.y + a.size.outerHeight), this.x += b, d 3022 }, b.prototype._getContainerSize = function () { 3023 return { 3024 height: this.maxY 3025 } 3026 }, b 3027 }), 3028 function (a, b) { 3029 "use strict"; 3030 "function" == typeof define && define.amd ? define("isotope/js/layout-modes/vertical", ["../layout-mode"], b) : "object" == typeof exports ? module.exports = b(require("../layout-mode")) : b(a.Isotope.LayoutMode) 3031 }(window, function (a) { 3032 "use strict"; 3033 var b = a.create("vertical", { 3034 horizontalAlignment: 0 3035 }); 3036 return b.prototype._resetLayout = function () { 3037 this.y = 0 3038 }, b.prototype._getItemLayoutPosition = function (a) { 3039 a.getSize(); 3040 var b = (this.isotope.size.innerWidth - a.size.outerWidth) * this.options.horizontalAlignment, 3041 c = this.y; 3042 return this.y += a.size.outerHeight, { 3043 x: b, 3044 y: c 3045 } 3046 }, b.prototype._getContainerSize = function () { 3047 return { 3048 height: this.y 3049 } 3050 }, b 3051 }), 3052 function (a, b) { 3053 "use strict"; 3054 "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 (c, d, e, f, g, h) { 3055 return b(a, c, d, e, f, g, h) 3056 }) : "object" == typeof exports ? module.exports = b(a, 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")) : a.Isotope = b(a, a.Outlayer, a.getSize, a.matchesSelector, a.fizzyUIUtils, a.Isotope.Item, a.Isotope.LayoutMode) 3057 }(window, function (a, b, c, d, e, f, g) { 3058 function h(a, b) { 3059 return function (c, d) { 3060 for (var e = 0, f = a.length; f > e; e++) { 3061 var g = a[e], 3062 h = c.sortData[g], 3063 i = d.sortData[g]; 3064 if (h > i || i > h) { 3065 var j = void 0 !== b[g] ? b[g] : b, 3066 k = j ? 1 : -1; 3067 return (h > i ? 1 : -1) * k 3068 } 3069 } 3070 return 0 3071 } 3072 } 3073 var i = a.jQuery, 3074 j = String.prototype.trim ? function (a) { 3075 return a.trim() 3076 } : function (a) { 3077 return a.replace(/^\s+|\s+$/g, "") 3078 }, 3079 k = document.documentElement, 3080 l = k.textContent ? function (a) { 3081 return a.textContent 3082 } : function (a) { 3083 return a.innerText 3084 }, 3085 m = b.create("isotope", { 3086 layoutMode: "masonry", 3087 isJQueryFiltering: !0, 3088 sortAscending: !0 3089 }); 3090 m.Item = f, m.LayoutMode = g, m.prototype._create = function () { 3091 this.itemGUID = 0, this._sorters = {}, this._getSorters(), b.prototype._create.call(this), this.modes = {}, this.filteredItems = this.items, this.sortHistory = ["original-order"]; 3092 for (var a in g.modes) this._initLayoutMode(a) 3093 }, m.prototype.reloadItems = function () { 3094 this.itemGUID = 0, b.prototype.reloadItems.call(this) 3095 }, m.prototype._itemize = function () { 3096 for (var a = b.prototype._itemize.apply(this, arguments), c = 0, d = a.length; d > c; c++) { 3097 var e = a[c]; 3098 e.id = this.itemGUID++ 3099 } 3100 return this._updateItemsSortData(a), a 3101 }, m.prototype._initLayoutMode = function (a) { 3102 var b = g.modes[a], 3103 c = this.options[a] || {};
3104 this.options[a] = b.options ? e.extend(b.options, c) : c, this.modes[a] = new b(this) 3105 }, m.prototype.layout = function () { 3106 return !this._isLayoutInited && this.options.isInitLayout ? void this.arrange() : void this._layout() 3107 }, m.prototype._layout = function () { 3108 var a = this._getIsInstant(); 3109 this._resetLayout(), this._manageStamps(), this.layoutItems(this.filteredItems, a), this._isLayoutInited = !0 3110 }, m.prototype.arrange = function (a) { 3111 function b() { 3112 d.reveal(c.needReveal), d.hide(c.needHide) 3113 } 3114 this.option(a), this._getIsInstant(); 3115 var c = this._filter(this.items); 3116 this.filteredItems = c.matches; 3117 var d = this; 3118 this._bindArrangeComplete(), this._isInstant ? this._noTransition(b) : b(), this._sort(), this._layout() 3119 }, m.prototype._init = m.prototype.arrange, m.prototype._getIsInstant = function () { 3120 var a = void 0 !== this.options.isLayoutInstant ? this.options.isLayoutInstant : !this._isLayoutInited; 3121 return this._isInstant = a, a 3122 }, m.prototype._bindArrangeComplete = function () { 3123 function a() { 3124 b && c && d && e.dispatchEvent("arrangeComplete", null, [e.filteredItems]) 3125 } 3126 var b, c, d, e = this; 3127 this.once("layoutComplete", function () { 3128 b = !0, a() 3129 }), this.once("hideComplete", function () { 3130 c = !0, a() 3131 }), this.once("revealComplete", function () { 3132 d = !0, a() 3133 }) 3134 }, m.prototype._filter = function (a) { 3135 var b = this.options.filter; 3136 b = b || "*"; 3137 for (var c = [], d = [], e = [], f = this._getFilterTest(b), g = 0, h = a.length; h > g; g++) { 3138 var i = a[g]; 3139 if (!i.isIgnored) { 3140 var j = f(i); 3141 j && c.push(i), j && i.isHidden ? d.push(i) : j || i.isHidden || e.push(i) 3142 } 3143 } 3144 return { 3145 matches: c, 3146 needReveal: d, 3147 needHide: e 3148 } 3149 }, m.prototype._getFilterTest = function (a) { 3150 return i && this.options.isJQueryFiltering ? function (b) { 3151 return i(b.element).is(a) 3152 } : "function" == typeof a ? function (b) { 3153 return a(b.element) 3154 } : function (b) { 3155 return d(b.element, a) 3156 } 3157 }, m.prototype.updateSortData = function (a) { 3158 var b; 3159 a ? (a = e.makeArray(a), b = this.getItems(a)) : b = this.items, this._getSorters(), this._updateItemsSortData(b) 3160 }, m.prototype._getSorters = function () { 3161 var a = this.options.getSortData; 3162 for (var b in a) { 3163 var c = a[b]; 3164 this._sorters[b] = n(c) 3165 } 3166 }, m.prototype._updateItemsSortData = function (a) { 3167 for (var b = a && a.length, c = 0; b && b > c; c++) { 3168 var d = a[c]; 3169 d.updateSortData() 3170 } 3171 }; 3172 var n = function () { 3173 function a(a) { 3174 if ("string" != typeof a) return a; 3175 var c = j(a).split(" "), 3176 d = c[0], 3177 e = d.match(/^\[(.+)\]$/), 3178 f = e && e[1], 3179 g = b(f, d), 3180 h = m.sortDataParsers[c[1]]; 3181 return a = h ? function (a) { 3182 return a && h(g(a)) 3183 } : function (a) { 3184 return a && g(a) 3185 } 3186 } 3187 3188 function b(a, b) { 3189 var c; 3190 return c = a ? function (b) { 3191 return b.getAttribute(a) 3192 } : function (a) { 3193 var c = a.querySelector(b); 3194 return c && l(c) 3195 } 3196 } 3197 return a 3198 }(); 3199 m.sortDataParsers = { 3200 parseInt: function (a) { 3201 return parseInt(a, 10) 3202 }, 3203 parseFloat: function (a) { 3204 return parseFloat(a) 3205 } 3206 }, m.prototype._sort = function () { 3207 var a = this.options.sortBy; 3208 if (a) { 3209 var b = [].concat.apply(a, this.sortHistory), 3210 c = h(b, this.options.sortAscending); 3211 this.filteredItems.sort(c), a != this.sortHistory[0] && this.sortHistory.unshift(a) 3212 } 3213 }, m.prototype._mode = function () { 3214 var a = this.options.layoutMode,
3215 b = this.modes[a]; 3216 if (!b) throw new Error("No layout mode: " + a); 3217 return b.options = this.options[a], b 3218 }, m.prototype._resetLayout = function () { 3219 b.prototype._resetLayout.call(this), this._mode()._resetLayout() 3220 }, m.prototype._getItemLayoutPosition = function (a) { 3221 return this._mode()._getItemLayoutPosition(a) 3222 }, m.prototype._manageStamp = function (a) { 3223 this._mode()._manageStamp(a) 3224 }, m.prototype._getContainerSize = function () { 3225 return this._mode()._getContainerSize() 3226 }, m.prototype.needsResizeLayout = function () { 3227 return this._mode().needsResizeLayout() 3228 }, m.prototype.appended = function (a) { 3229 var b = this.addItems(a); 3230 if (b.length) { 3231 var c = this._filterRevealAdded(b); 3232 this.filteredItems = this.filteredItems.concat(c) 3233 } 3234 }, m.prototype.prepended = function (a) { 3235 var b = this._itemize(a); 3236 if (b.length) { 3237 this._resetLayout(), this._manageStamps(); 3238 var c = this._filterRevealAdded(b); 3239 this.layoutItems(this.filteredItems), this.filteredItems = c.concat(this.filteredItems), this.items = b.concat(this.items) 3240 } 3241 }, m.prototype._filterRevealAdded = function (a) { 3242 var b = this._filter(a); 3243 return this.hide(b.needHide), this.reveal(b.matches), this.layoutItems(b.matches, !0), b.matches 3244 }, m.prototype.insert = function (a) { 3245 var b = this.addItems(a); 3246 if (b.length) { 3247 var c, d, e = b.length; 3248 for (c = 0; e > c; c++) d = b[c], this.element.appendChild(d.element); 3249 var f = this._filter(b).matches; 3250 for (c = 0; e > c; c++) b[c].isLayoutInstant = !0; 3251 for (this.arrange(), c = 0; e > c; c++) delete b[c].isLayoutInstant; 3252 this.reveal(f) 3253 } 3254 }; 3255 var o = m.prototype.remove; 3256 return m.prototype.remove = function (a) { 3257 a = e.makeArray(a); 3258 var b = this.getItems(a); 3259 o.call(this, a); 3260 var c = b && b.length; 3261 if (c) 3262 for (var d = 0; c > d; d++) { 3263 var f = b[d]; 3264 e.removeFrom(this.filteredItems, f) 3265 } 3266 }, m.prototype.shuffle = function () { 3267 for (var a = 0, b = this.items.length; b > a; a++) { 3268 var c = this.items[a]; 3269 c.sortData.random = Math.random() 3270 } 3271 this.options.sortBy = "random", this._sort(), this._layout() 3272 }, m.prototype._noTransition = function (a) { 3273 var b = this.options.transitionDuration; 3274 this.options.transitionDuration = 0; 3275 var c = a.call(this); 3276 return this.options.transitionDuration = b, c 3277 }, m.prototype.getFilteredItemElements = function () { 3278 for (var a = [], b = 0, c = this.filteredItems.length; c > b; b++) a.push(this.filteredItems[b].element); 3279 return a 3280 }, m 3281 }); 3282 3283 3284/* 3285 * jquery parallax 3286 * ----------------------------------------------- 3287 */ 3288/* 3289Plugin: jQuery Parallax 3290Version 1.1.3 3291Author: Ian Lunn 3292Twitter: @IanLunn 3293Author URL: http://www.ianlunn.co.uk/ 3294Plugin URL: http://www.ianlunn.co.uk/plugins/jquery-parallax/ 3295Dual licensed under the MIT and GPL licenses: 3296http://www.opensource.org/licenses/mit-license.php 3297http://www.gnu.org/licenses/gpl.html 3298*/ 3299(function ($) { 3300 var $window = $(window); 3301 var windowHeight = $window.height(); 3302 $window.resize(function () { 3303 windowHeight = $window.height() 3304 }); 3305 $.fn.parallax = function (xpos, speedFactor, outerHeight) { 3306 var $this = $(this); 3307 var getHeight; 3308 var firstTop; 3309 var paddingTop = 0; 3310 $this.each(function () { 3311 firstTop = $this.offset().top 3312 }); 3313 if (outerHeight) { 3314 getHeight = function (jqo) { 3315 return jqo.outerHeight(true) 3316 } 3317 } else { 3318 getHeight = function (jqo) { 3319 return jqo.height() 3320 } 3321 } 3322 if (arguments.length < 1 || xpos === null) xpos = "50%"; 3323 if (arguments.length < 2 || speedFactor === null) speedFactor = 0.1; 3324 if (arguments.length < 3 || outerHeight === null) outerHeight = true; 3325
3326 function update() { 3327 var pos = $window.scrollTop(); 3328 $this.each(function () { 3329 var $element = $(this); 3330 var top = $element.offset().top; 3331 var height = getHeight($element); 3332 if (top + height < pos || top > pos + windowHeight) { 3333 return 3334 } 3335 $this.css('backgroundPosition', xpos + " " + Math.round((firstTop - pos) * speedFactor) + "px") 3336 }) 3337 } 3338 $window.bind('scroll', update).resize(update); 3339 update() 3340 } 3341})(jQuery); 3342 3343 3344 3345/* 3346 * animateNumbers 3347 * ----------------------------------------------- 3348 */ 3349/*********** 3350 Animates element's number to new number with commas 3351 Parameters: 3352 stop (number): number to stop on 3353 commas (boolean): turn commas on/off (default is true) 3354 duration (number): how long in ms (default is 1000) 3355 ease (string): type of easing (default is "swing", others are avaiable from jQuery's easing plugin 3356 Examples: 3357 $("#div").animateNumbers(1234, false, 500, "linear"); // half second linear without commas 3358 $("#div").animateNumbers(1234, true, 2000); // two second swing with commas 3359 $("#div").animateNumbers(4321); // one second swing with commas 3360 This fully expects an element containing an integer 3361 If the number is within copy then separate it with a span and target the span 3362 Inserts and accounts for commas during animation by default 3363***********/ 3364! function (t) { 3365 t.fn.animateNumbers = function (e, n, a, i) { 3366 return this.each(function () { 3367 var d = t(this), 3368 o = parseInt(d.text().replace(/,/g, "")); 3369 n = void 0 === n ? !0 : n, t({ 3370 value: o 3371 }).animate({ 3372 value: e 3373 }, { 3374 duration: void 0 == a ? 1e3 : a, 3375 easing: void 0 == i ? "swing" : i, 3376 step: function () { 3377 d.text(Math.floor(this.value)), n && d.text(d.text().replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1,")) 3378 }, 3379 complete: function () { 3380 parseInt(d.text()) !== e && (d.text(e), n && d.text(d.text().replace(/(\d)(?=(\d\d\d)+(?!\d))/g, "$1,"))) 3381 } 3382 }) 3383 }) 3384 } 3385}(jQuery); 3386 3387/* 3388 * jflickrfeed 3389 * ----------------------------------------------- 3390 */ 3391/* 3392 * Copyright (C) 2009 Joel Sutherland 3393 * Licenced under the MIT license 3394 * http://www.newmediacampaigns.com/page/jquery-flickr-plugin 3395 * 3396 * Available tags for templates: 3397 * title, link, date_taken, description, published, author, author_id, tags, image* 3398 */ 3399(function ($) { 3400 $.fn.jflickrfeed = function (settings, callback) { 3401 settings = $.extend(true, { 3402 flickrbase: 'http://api.flickr.com/services/feeds/', 3403 feedapi: 'photos_public.gne', 3404 limit: 20, 3405 qstrings: { 3406 lang: 'en-us', 3407 format: 'json', 3408 jsoncallback: '?' 3409 }, 3410 cleanDescription: true, 3411 useTemplate: true, 3412 itemTemplate: '', 3413 itemCallback: function () { } 3414 }, settings); 3415 var url = settings.flickrbase + settings.feedapi + '?'; 3416 var first = true; 3417 for (var key in settings.qstrings) { 3418 if (!first) 3419 url += '&'; 3420 url += key + '=' + settings.qstrings[key]; 3421 first = false; 3422 } 3423 return $(this).each(function () { 3424 var $container = $(this); 3425 var container = this; 3426 $.getJSON(url, function (data) { 3427 $.each(data.items, function (i, item) { 3428 if (i < settings.limit) { 3429 if (settings.cleanDescription) { 3430 var regex = /<p>(.*?)<\/p>/g; 3431 var input = item.description; 3432 if (regex.test(input)) { 3433 item.description = input.match(regex)[2] 3434 if (item.description != undefined) 3435 item.description = item.description.replace('<p>', '').replace('</p>', ''); 3436 } 3437 } 3438 item['image_s'] = item.media.m.replace('_m', '_s'); 3439 item['image_t'] = item.media.m.replace('_m', '_t'); 3440 item['image_m'] = item.media.m.replace('_m', '_m'); 3441 item['image'] = item.media.m.replace('_m', ''); 3442 item['image_b'] = item.media.m.replace('_m', '_b'); 3443 delete item.media; 3444 if (settings.useTemplate) { 3445 var template = settings.itemTemplate; 3446 for (var key in item) { 3447 var rgx = new RegExp('{{' + key + '}}', 'g'); 3448 template = template.replace(rgx, item[key]); 3449 } 3450 $container.append(template) 3451 } 3452 settings.itemCallback.call(container, item); 3453 } 3454 }); 3455 if ($.isFunction(callback)) { 3456 callback.call(container, data); 3457 } 3458 }); 3459 }); 3460 } 3461})(jQuery); 3462 3463/* 3464 * fitvids 3465 * ----------------------------------------------- 3466 */ 3467/*jshint browser:true */ 3468/*! 3469 * FitVids 1.1 3470 *
3471 * Copyright 2013, Chris Coyier - http://css-tricks.com + Dave Rupert - http://daverupert.com 3472 * Credit to Thierry Koblentz - http://www.alistapart.com/articles/creating-intrinsic-ratios-for-video/ 3473 * Released under the WTFPL license - http://sam.zoy.org/wtfpl/ 3474 * 3475 */ 3476! function (t) { 3477 "use strict"; 3478 t.fn.fitVids = function (e) { 3479 var i = { 3480 customSelector: null, 3481 ignore: null 3482 }; 3483 if (!document.getElementById("fit-vids-style")) { 3484 var r = document.head || document.getElementsByTagName("head")[0], 3485 a = ".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%;}", 3486 d = document.createElement("div"); 3487 d.innerHTML = '<p>x</p><style id="fit-vids-style">' + a + "</style>", r.appendChild(d.childNodes[1]) 3488 } 3489 return e && t.extend(i, e), this.each(function () { 3490 var e = ['iframe[src*="player.vimeo.com"]', 'iframe[src*="youtube.com"]', 'iframe[src*="youtube-nocookie.com"]', 'iframe[src*="kickstarter.com"][src*="video.html"]', "object", "embed"]; 3491 i.customSelector && e.push(i.customSelector); 3492 var r = ".fitvidsignore"; 3493 i.ignore && (r = r + ", " + i.ignore); 3494 var a = t(this).find(e.join(",")); 3495 a = a.not("object object"), a = a.not(r), a.each(function (e) { 3496 var i = t(this); 3497 if (!(i.parents(r).length > 0 || "embed" === this.tagName.toLowerCase() && i.parent("object").length || i.parent(".fluid-width-video-wrapper").length)) { 3498 i.css("height") || i.css("width") || !isNaN(i.attr("height")) && !isNaN(i.attr("width")) || (i.attr("height", 9), i.attr("width", 16)); 3499 var a = "object" === this.tagName.toLowerCase() || i.attr("height") && !isNaN(parseInt(i.attr("height"), 10)) ? parseInt(i.attr("height"), 10) : i.height(), 3500 d = isNaN(parseInt(i.attr("width"), 10)) ? i.width() : parseInt(i.attr("width"), 10), 3501 o = a / d; 3502 if (!i.attr("id")) { 3503 var h = "fitvid" + e; 3504 i.attr("id", h) 3505 } 3506 i.wrap('<div class="fluid-width-video-wrapper"></div>').parent(".fluid-width-video-wrapper").css("padding-top", 100 * o + "%"), i.removeAttr("height").removeAttr("width") 3507 } 3508 }) 3509 }) 3510 } 3511}(window.jQuery || window.Zepto); 3512 3513/* 3514 * Retina.js 3515 * ----------------------------------------------- 3516 */ 3517/*! 3518 * Retina.js v1.3.0 3519 * 3520 * Copyright 2014 Imulus, LLC 3521 * Released under the MIT license 3522 * 3523 * Retina.js is an open source script that makes it easy to serve 3524 * high-resolution images to devices with retina displays. 3525 */ 3526/*!function(){function a(){}function b(a){return f.retinaImageSuffix+a}function c(a,c){if(this.path=a||"","undefined"!=typeof c&&null!==c)this.at_2x_path=c,this.perform_check=!1;else{if(void 0!==document.createElement){var d=document.createElement("a");d.href=this.path,d.pathname=d.pathname.replace(g,b),this.at_2x_path=d.href}else{var e=this.path.split("?");e[0]=e[0].replace(g,b),this.at_2x_path=e.join("?")}this.perform_check=!0}}function d(a){this.el=a,this.path=new c(this.el.getAttribute("src"),this.el.getAttribute("data-at2x"));var b=this;this.path.check_2x_variant(function(a){a&&b.swap()})}var e="undefined"==typeof exports?window:exports,f={retinaImageSuffix:"@2x",check_mime_type:!0,force_original_dimensions:!0};e.Retina=a,a.configure=function(a){null===a&&(a={});for(var b in a)a.hasOwnProperty(b)&&(f[b]=a[b])},a.init=function(a){null===a&&(a=e);var b=a.onload||function(){};a.onload=function(){var a,c,e=document.getElementsByTagName("img"),f=[];for(a=0;a<e.length;a+=1)c=e[a],c.getAttributeNode("data-no-retina")||f.push(new d(c));b()}},a.isRetina=function(){var a="(-webkit-min-device-pixel-ratio: 1.5), (min--moz-device-pixel-ratio: 1.5), (-o-min-device-pixel-ratio: 3/2), (min-resolution: 1.5dppx)";return e.devicePixelRatio>1?!0:e.matchMedia&&e.matchMedia(a).matches?!0:!1};var g=/\.\w+$/;e.RetinaImagePath=c,c.confirmed_paths=[],c.prototype.is_external=function(){return!(!this.path.match(/^https?\:/i)||this.path.match("//"+document.domain))},c.prototype.check_2x_variant=function(a){var b,d=this;return this.is_external()?a(!1):this.perform_check||"undefined"==typeof this.at_2x_path||null===this.at_2x_path?this.at_2x_path in c.confirmed_paths?a(!0):(b=new XMLHttpRequest,b.open("HEAD",this.at_2x_path),b.onreadystatechange=function(){if(4!==b.readyState)return a(!1);if(b.status>=200&&b.status<=399){if(f.check_mime_type){var e=b.getResponseHeader("Content-Type");if(null===e||!e.match(/^image/i))return a(!1)}return c.confirmed_paths.push(d.at_2x_path),a(!0)}return a(!1)},b.send(),void 0):a(!0)},e.RetinaImage=d,d.prototype.swap=function(a){function b(){c.el.complete?(f.force_original_dimensions&&(c.el.setAttribute("width",c.el.offsetWidth),c.el.setAttribute("height",c.el.offsetHeight)),c.el.setAttribute("src",a)):setTimeout(b,5)}"undefined"==typeof a&&(a=this.path.at_2x_path);var c=this;b()},a.isRetina()&&a.init(e)}(); 3527 */ 3528 3529/* 3530 * ajaxchimp 3531 * ----------------------------------------------- 3532 */ 3533/*! 3534 * version 1.3.0 3535 */ 3536(function ($) { 3537 "use strict"; 3538 $.ajaxChimp = { 3539 responses: { 3540 "We have sent you a confirmation email": 0, 3541 "Please enter a value": 1, 3542 "An email address must contain a single @": 2,
3543 "The domain portion of the email address is invalid (the portion after the @: )": 3, 3544 "The username portion of the email address is invalid (the portion before the @: )": 4, 3545 "This email address looks fake or invalid. Please enter a real email address": 5 3546 }, 3547 translations: { 3548 en: null 3549 }, 3550 init: function (selector, options) { 3551 $(selector).ajaxChimp(options) 3552 } 3553 }; 3554 $.fn.ajaxChimp = function (options) { 3555 $(this).each(function (i, elem) { 3556 var form = $(elem); 3557 var email = form.find("input[type=email]"); 3558 var label = form.find("label[for=" + email.attr("id") + "]"); 3559 var settings = $.extend({ 3560 url: form.attr("action"), 3561 language: "en" 3562 }, options); 3563 var url = settings.url.replace("/post?", "/post-json?").concat("&c=?"); 3564 form.attr("novalidate", "true"); 3565 email.attr("name", "EMAIL"); 3566 form.submit(function () { 3567 var msg; 3568 3569 function successCallback(resp) { 3570 if (resp.result === "success") { 3571 msg = "We have sent you a confirmation email"; 3572 label.removeClass("error").addClass("valid"); 3573 email.removeClass("error").addClass("valid") 3574 } else { 3575 email.removeClass("valid").addClass("error"); 3576 label.removeClass("valid").addClass("error"); 3577 var index = -1; 3578 try { 3579 var parts = resp.msg.split(" - ", 2); 3580 if (parts[1] === undefined) { 3581 msg = resp.msg 3582 } else { 3583 var i = parseInt(parts[0], 10); 3584 if (i.toString() === parts[0]) { 3585 index = parts[0]; 3586 msg = parts[1] 3587 } else { 3588 index = -1; 3589 msg = resp.msg 3590 } 3591 } 3592 } catch (e) { 3593 index = -1; 3594 msg = resp.msg 3595 } 3596 } 3597 if (settings.language !== "en" && $.ajaxChimp.responses[msg] !== undefined && $.ajaxChimp.translations && $.ajaxChimp.translations[settings.language] && $.ajaxChimp.translations[settings.language][$.ajaxChimp.responses[msg]]) { 3598 msg = $.ajaxChimp.translations[settings.language][$.ajaxChimp.responses[msg]] 3599 } 3600 label.html(msg); 3601 label.show(2e3); 3602 if (settings.callback) { 3603 settings.callback(resp) 3604 } 3605 } 3606 var data = {}; 3607 var dataArray = form.serializeArray(); 3608 $.each(dataArray, function (index, item) { 3609 data[item.name] = item.value 3610 }); 3611 $.ajax({
3612 url: url, 3613 data: data, 3614 success: successCallback, 3615 dataType: "jsonp", 3616 error: function (resp, text) { 3617 console.log("mailchimp ajax submit error: " + text) 3618 } 3619 }); 3620 var submitMsg = "Submitting..."; 3621 if (settings.language !== "en" && $.ajaxChimp.translations && $.ajaxChimp.translations[settings.language] && $.ajaxChimp.translations[settings.language]["submit"]) { 3622 submitMsg = $.ajaxChimp.translations[settings.language]["submit"] 3623 } 3624 label.html(submitMsg).show(2e3); 3625 return false 3626 }) 3627 }); 3628 return this 3629 } 3630})(jQuery); 3631 3632 3633/* 3634 * tweetie 3635 * ----------------------------------------------- 3636 */ 3637(function (e) { 3638 "use strict"; 3639 e.fn.twittie = function () { 3640 var t = arguments[0] instanceof Object ? arguments[0] : {}, 3641 n = typeof arguments[0] === "function" ? arguments[0] : arguments[1]; 3642 var r = e.extend({ 3643 username: null, 3644 list: null, 3645 hashtag: null, 3646 count: 10, 3647 hideReplies: false, 3648 dateFormat: "%b/%d/%Y", 3649 template: "{{date}} - {{tweet}}", 3650 apiPath: "includes/twitter/tweet.php", 3651 loadingText: "Loading..." 3652 }, t); 3653 if (r.list && !r.username) { 3654 e.error("If you want to fetch tweets from a list, you must define the username of the list owner.") 3655 } 3656 var i = function (e) { 3657 var t = e.replace(/(https?:\/\/([-\w\.]+)+(:\d+)?(\/([\w\/_\.]*(\?\S+)?)?)?)/ig, '<a href="$1" target="_blank" title="Visit this link">$1</a>').replace(/#([a-zA-Z0-9_]+)/g, '<a href="https://twitter.com/search?q=%23$1&src=hash" target="_blank" title="Search for #$1">#$1</a>').replace(/@([a-zA-Z0-9_]+)/g, '<a href="https://twitter.com/$1" target="_blank" title="$1 on Twitter">@$1</a>'); 3658 return t 3659 }; 3660 var s = function (e) { 3661 var t = e.split(" "); 3662 e = new Date(Date.parse(t[1] + " " + t[2] + ", " + t[5] + " " + t[3] + " UTC")); 3663 var n = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "
3663November", "December"]; 3664 var i = { 3665 "%d": e.getDate(), 3666 "%m": e.getMonth() + 1, 3667 "%b": n[e.getMonth()].substr(0, 3), 3668 "%B": n[e.getMonth()], 3669 "%y": String(e.getFullYear()).slice(-2), 3670 "%Y": e.getFullYear() 3671 }; 3672 var s = r.dateFormat; 3673 var o = r.dateFormat.match(/%[dmbByY]/g); 3674 for (var u = 0, a = o.length; u < a; u++) { 3675 s = s.replace(o[u], i[o[u]]) 3676 } 3677 return s 3678 }; 3679 var o = function (e) { 3680 var t = r.template; 3681 var n = ["date", "tweet", "avatar", "url", "retweeted", "screen_name", "user_name"]; 3682 for (var i = 0, s = n.length; i < s; i++) { 3683 t = t.replace(new RegExp("{{" + n[i] + "}}", "gi"), e[n[i]]) 3684 } 3685 return t 3686 }; 3687 this.html("<span>" + r.loadingText + "</span>"); 3688 var u = this; 3689 e.getJSON(r.apiPath, { 3690 username: r.username, 3691 list: r.list, 3692 hashtag: r.hashtag, 3693 count: r.count, 3694 exclude_replies: r.hideReplies 3695 }, function (e) { 3696 u.find("span").fadeOut("fast", function () { 3697 u.html("<ul></ul>"); 3698 for (var t = 0; t < r.count; t++) { 3699 var a = false; 3700 if (e[t]) { 3701 a = e[t] 3702 } else if (e.statuses !== undefined && e.statuses[t]) { 3703 a = e.statuses[t] 3704 } else { 3705 break 3706 } 3707 var f = { 3708 user_name: a.user.name, 3709 date: s(a.created_at), 3710 tweet: a.retweeted ? i("RT @" + a.user.screen_name + ": " + a.retweeted_status.text) : i(a.text), 3711 avatar: '<img src="' + a.user.profile_image_url + '" />', 3712 url: "https://twitter.com/" + a.user.screen_name + "/status/" + a.id_str, 3713 retweeted: a.retweeted, 3714 screen_name: i("@" + a.user.screen_name) 3715 }; 3716 u.find("ul").append("<li class='item'>" + o(f) + "</li>") 3717 } 3718 if (typeof n === "function") { 3719 n() 3720 } 3721 }) 3722 }) 3723 } 3724})(jQuery) 3725 3726/* 3727 * menufullpage 3728 * ----------------------------------------------- 3729 */ 3730/*! menufullpage - v1.0.0 - 2015-03-26 3731 * https://github.com/rottenstudios/menufullpage 3732 * Copyright (c) 2015 Carmelo Catalfamo - rottenStudios.it */ 3733! function (a) { 3734 "use strict"; 3735 a.fn.menufullpage = function (b) { 3736 var c = a.extend({ 3737 menu: "#fullpage-nav", 3738 push: ".push", 3739 side: "left", 3740 menuWidth: "100%", 3741 speed: "400", 3742 activeBtn: "menu-open" 3743 }, b), 3744 d = this, 3745 e = a(c.menu), 3746 f = a(c.push), 3747 g = c.menuWidth, 3748 h = { 3749 position: "fixed", 3750 top: "0", 3751 bottom: "0", 3752 "settings.side": "-" + c.menuWidth, 3753 width: c.menuWidth, 3754 height: "100%" 3755 }, 3756 i = { 3757 "-webkit-transition": c.side + " " + c.speed + "ms ease", 3758 "-moz-transition": c.side + " " + c.speed + "ms ease", 3759 "-ms-transition": c.side + " " + c.speed + "ms ease", 3760 "-o-transition": c.side + " " + c.speed + "ms ease", 3761 transition: c.side + " " + c.speed + "ms ease" 3762 }; 3763 return e.css(h), f.css(c.side, "0"), e.css(i), f.css(i), e._state = "closed", e.open = function () { 3764 e._state = "open", e.css(c.side, "0"), f.css(c.side, g), d.addClass(c.activeBtn) 3765 }, e.close = function () { 3766 e._state = "closed", e.css(c.side, "-" + g), f.css(c.side, "0"), d.removeClass(c.activeBtn) 3767 }, a(document).on("click.menufullpage", function (b) { 3768 a(b.target).parents().andSelf().is(d) || "open" !== e._state || (e.close(), d.removeClass(c.activeBtn)) 3769 }), d.on("click.menufullpage", function (a) { 3770 a.preventDefault(), "closed" === e._state ? e.open() : e.close() 3771 }), d.on("touchend", function (a) { 3772 d.trigger("click.menufullpage"), a.preventDefault() 3773 }), e 3774 } 3775}(jQuery); 3776! function (e, t) { 3777 "function" == typeof define && define.amd ? define("smoothScroll", t(e)) : "object" == typeof exports ? module.exports = t(e) : e.smoothScroll = t(e) 3778}(window || this, function (e) { 3779 "use strict"; 3780 var t, n, o, r = {}, 3781 a = !!document.querySelector && !!e.addEventListener, 3782 c = { 3783 speed: 500, 3784 easing: "easeInOutCubic", 3785 offset: 0, 3786 updateURL: !0, 3787 callbackBefore: function () { }, 3788 callbackAfter: function () { } 3789 }, 3790 u = function (e, t, n) { 3791 if ("[object Object]" === Object.prototype.toString.call(e)) 3792 for (var o in e) Object.prototype.hasOwnProperty.call(e, o) && t.call(n, e[o
3792], o, e); 3793 else 3794 for (var r = 0, a = e.length; a > r; r++) t.call(n, e[r], r, e) 3795 }, 3796 i = function (e, t) { 3797 var n = {}; 3798 return u(e, function (t, o) { 3799 n[o] = e[o] 3800 }), u(t, function (e, o) { 3801 n[o] = t[o] 3802 }), n 3803 }, 3804 l = function (e, t) { 3805 for (var n = t.charAt(0); e && e !== document; e = e.parentNode) 3806 if ("." === n) { 3807 if (e.classList.contains(t.substr(1))) return e 3808 } else if ("#" === n) { 3809 if (e.id === t.substr(1)) return e 3810 } else if ("[" === n && e.hasAttribute(t.substr(1, t.length - 2))) return e; 3811 return !1 3812 }, 3813 s = function (e) { 3814 return Math.max(e.scrollHeight, e.offsetHeight, e.clientHeight) 3815 }, 3816 f = function (e) { 3817 for (var t, n = String(e), o = n.length, r = -1, a = "", c = n.charCodeAt(0); ++r < o;) { 3818 if (t = n.charCodeAt(r), 0 === t) throw new InvalidCharacterError("Invalid character: the input contains U+0000."); 3819 a += t >= 1 && 31 >= t || 127 == t || 0 === r && t >= 48 && 57 >= t || 1 === r && t >= 48 && 57 >= t && 45 === c ? "\\" + t.toString(16) + " " : t >= 128 || 45 === t || 95 === t || t >= 48 && 57 >= t || t >= 65 && 90 >= t || t >= 97 && 122 >= t ? n.charAt(r) : "\\" + n.charAt(r) 3820 } 3821 return a 3822 }, 3823 d = function (e, t) { 3824 var n; 3825 return "easeInQuad" === e && (n = t * t), "easeOutQuad" === e && (n = t * (2 - t)), "easeInOutQuad" === e && (n = .5 > t ? 2 * t * t : -1 + (4 - 2 * t) * t), "easeInCubic" === e && (n = t * t * t), "easeOutCubic" === e && (n = --t * t * t + 1), "easeInOutCubic" === e && (n = .5 > t ? 4 * t * t * t : (t - 1) * (2 * t - 2) * (2 * t - 2) + 1), "easeInQuart" === e && (n = t * t * t * t), "easeOutQuart" === e && (n = 1 - --t * t * t * t), "easeInOutQuart" === e && (n = .5 > t ? 8 * t * t * t * t : 1 - 8 * --t * t * t * t), "easeInQuint" === e && (n = t * t * t * t * t), "easeOutQuint" === e && (n = 1 + --t * t * t * t * t), "easeInOutQuint" === e && (n = .5 > t ? 16 * t * t * t * t * t : 1 + 16 * --t * t * t * t * t), n || t 3826 }, 3827 h = function (e, t, n) { 3828 var o = 0; 3829 if (e.offsetParent) 3830 do o += e.offsetTop, e = e.offsetParent; while (e); 3831 return o = o - t - n, o >= 0 ? o : 0 3832 }, 3833 m = function () { 3834 return Math.max(document.body.scrollHeight, document.documentElement.scrollHeight, document.body.offsetHeight, document.documentElement.offsetHeight, document.body.clientHeight, document.documentElement.clientHeight) 3835 }, 3836 p = function (e) { 3837 return e && "object" == typeof JSON && "function" == typeof JSON.parse ? JSON.parse(e) : {} 3838 }, 3839 v = function (t, n) { 3840 history.pushState && (n || "true" === n) && history.pushState(null, null, [e.location.protocol, "//", e.location.host, e.location.pathname, e.location.search, t].join("")) 3841 }; 3842 r.animateScroll = function (t, n, r) { 3843 var a = i(a || c, r || {}), 3844 u = p(t ? t.getAttribute("data-options") : null); 3845 a = i(a, u), n = "#" + f(n.substr(1)); 3846 var l = "#" === n ? document.documentElement : document.querySelector(n), 3847 g = e.pageYOffset; 3848 o || (o = document.querySelector("[data-scroll-header]")); 3849 var b, O, y, S = null === o ? 0 : s(o) + o.offsetTop, 3850 I = h(l, S, parseInt(a.offset, 10)), 3851 H = I - g, 3852 E = m(), 3853 A = 0; 3854 v(n, a.updateURL); 3855 var L = function (o, r, c) { 3856 var u = e.pageYOffset; 3857 (o == r || u == r || e.innerHeight + u >= E) && (clearInterval(c), l.focus(), a.callbackAfter(t, n)) 3858 }, 3859 Q = function () { 3860 A += 16, O = A / parseInt(a.speed, 10), O = O > 1 ? 1 : O, y = g + H * d(a.easing, O), e.scrollTo(0, Math.floor(y)), L(y, I, b) 3861 }, 3862 C = function () { 3863 a.callbackBefore(t, n), b = setInterval(Q, 16) 3864 }; 3865 0 === e.pageYOffset && e.scrollTo(0, 0), C() 3866 }; 3867 var g = function (e) { 3868 var n = l(e.target, "[data-scroll]"); 3869 n && "a" === n.tagName.toLowerCase() && (e.preventDefault(), r.animateScroll(n, n.hash, t)) 3870 }, 3871 b = function () { 3872 n || (n = setTimeout(function () { 3873 n = null, headerHeight = null === o ? 0 : s(o) + o.offsetTop 3874 }, 66)) 3875 }; 3876 return r.destroy = function () { 3877 t && (document.removeEventListener("click", g, !1), e.removeEventListener("resize", b, !1), t = null, n = null, o = null) 3878 }, r.init = function (n) { 3879 a && (r.destroy(), t = i(c, n || {}), o = document.querySelector("[data-scroll-header]"), document.addEventListener("click", g, !1), o && e.addEventListener("resize", b, !1)) 3880 }, r 3881}); 3882 3883/* 3884 * WOW animation 3885 * ----------------------------------------------- 3886 */ 3887/*! WOW - v1.1.2 - 2015-08-19 3888 * Copyright (c) 2015 Matthieu Aussaguel; Licensed MIT */ 3889(function () { 3890 var a, b, c, d, e, f = function (a, b) { 3891 return function () { 3892 return a.apply(b, arguments) 3893 } 3894 }, 3895 g = [].indexOf || function (a) { 3896 for (var b = 0, c = this.length; c > b; b++) 3897 if (b in this && this[b] === a) return b; 3898 return -1 3899 }; 3900 b = function () { 3901 function a() { } 3902 return a.prototype.extend = function (a, b) { 3903 var c, d; 3904 for (c in b) d = b[c], null == a[c] && (a[c] = d); 3905 return a 3906 }, a.prototype.isMobile = function (a) { 3907 return /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(a) 3908 }, a.prototype.createEvent = function (a, b, c, d) { 3909 var e; 3910 return null == b && (b = !1), null == c && (c = !1), null == d && (d = null), null != document.createEvent ? (e = document.createEvent("CustomEvent"), e.initCustomEvent(a, b, c, d)) : null != document.createEventObject ? (e = document.createEventObject(), e.eventType = a) : e.eventName = a, e 3911 }, a.prototype.emitEvent = function (a, b) { 3912 return null != a.dispatchEvent ? a.dispatchEvent(b) : b in (null != a) ? a[b]() : "on" + b in (null != a) ? a["on"
vendor: 8,555 bytes, lines 3912-4040
3912+ b]() : void 0 3913 }, a.prototype.addEvent = function (a, b, c) { 3914 return null != a.addEventListener ? a.addEventListener(b, c, !1) : null != a.attachEvent ? a.attachEvent("on" + b, c) : a[b] = c 3915 }, a.prototype.removeEvent = function (a, b, c) { 3916 return null != a.removeEventListener ? a.removeEventListener(b, c, !1) : null != a.detachEvent ? a.detachEvent("on" + b, c) : delete a[b] 3917 }, a.prototype.innerHeight = function () { 3918 return "innerHeight" in window ? window.innerHeight : document.documentElement.clientHeight 3919 }, a 3920 }(), c = this.WeakMap || this.MozWeakMap || (c = function () { 3921 function a() { 3922 this.keys = [], this.values = [] 3923 } 3924 return a.prototype.get = function (a) { 3925 var b, c, d, e, f; 3926 for (f = this.keys, b = d = 0, e = f.length; e > d; b = ++d) 3927 if (c = f[b], c === a) return this.values[b] 3928 }, a.prototype.set = function (a, b) { 3929 var c, d, e, f, g; 3930 for (g = this.keys, c = e = 0, f = g.length; f > e; c = ++e) 3931 if (d = g[c], d === a) return void (this.values[c] = b); 3932 return this.keys.push(a), this.values.push(b) 3933 }, a 3934 }()), a = this.MutationObserver || this.WebkitMutationObserver || this.MozMutationObserver || (a = function () { 3935 function a() { 3936 "undefined" != typeof console && null !== console && console.warn("MutationObserver is not supported by your browser."), "undefined" != typeof console && null !== console && console.warn("WOW.js cannot detect dom mutations, please call .sync() after loading new content.") 3937 } 3938 return a.notSupported = !0, a.prototype.observe = function () { }, a 3939 }()), d = this.getComputedStyle || function (a) { 3940 return this.getPropertyValue = function (b) { 3941 var c; 3942 return "float" === b && (b = "styleFloat"), e.test(b) && b.replace(e, function (a, b) { 3943 return b.toUpperCase() 3944 }), (null != (c = a.currentStyle) ? c[b] : void 0) || null 3945 }, this 3946 }, e = /(\-([a-z]){1})/g, this.WOW = function () { 3947 function e(a) { 3948 null == a && (a = {}), this.scrollCallback = f(this.scrollCallback, this), this.scrollHandler = f(this.scrollHandler, this), this.resetAnimation = f(this.resetAnimation, this), this.start = f(this.start, this), this.scrolled = !0, this.config = this.util().extend(a, this.defaults), null != a.scrollContainer && (this.config.scrollContainer = document.querySelector(a.scrollContainer)), this.animationNameCache = new c, this.wowEvent = this.util().createEvent(this.config.boxClass) 3949 } 3950 return e.prototype.defaults = { 3951 boxClass: "wow", 3952 animateClass: "animated", 3953 offset: 0, 3954 mobile: !0, 3955 live: !0, 3956 callback: null, 3957 scrollContainer: null 3958 }, e.prototype.init = function () { 3959 var a; 3960 return this.element = window.document.documentElement, "interactive" === (a = document.readyState) || "complete" === a ? this.start() : this.util().addEvent(document, "DOMContentLoaded", this.start), this.finished = [] 3961 }, e.prototype.start = function () { 3962 var b, c, d, e; 3963 if (this.stopped = !1, this.boxes = function () { 3964 var a, c, d, e; 3965 for (d = this.element.querySelectorAll("." + this.config.boxClass), e = [], a = 0, c = d.length; c > a; a++) b = d[a], e.push(b); 3966 return e 3967 }.call(this), this.all = function () { 3968 var a, c, d, e; 3969 for (d = this.boxes, e = [], a = 0, c = d.length; c > a; a++) b = d[a], e.push(b); 3970 return e 3971 }.call(this), this.boxes.length) 3972 if (this.disabled()) this.resetStyle(); 3973 else 3974 for (e = this.boxes, c = 0, d = e.length; d > c; c++) b = e[c], this.applyStyle(b, !0); 3975 return this.disabled() || (this.util().addEvent(this.config.scrollContainer || window, "scroll", this.scrollHandler), this.util().addEvent(window, "resize", this.scrollHandler), this.interval = setInterval(this.scrollCallback, 50)), this.config.live ? new a(function (a) { 3976 return function (b) { 3977 var c, d, e, f, g; 3978 for (g = [], c = 0, d = b.length; d > c; c++) f = b[c], g.push(function () { 3979 var a, b, c, d; 3980 for (c = f.addedNodes || [], d = [], a = 0, b = c.length; b > a; a++) e = c[a], d.push(this.doSync(e)); 3981 return d 3982 }.call(a)); 3983 return g 3984 } 3985 }(this)).observe(document.body, { 3986 childList: !0, 3987 subtree: !0 3988 }) : void 0 3989 }, e.prototype.stop = function () { 3990 return this.stopped = !0, this.util().removeEvent(this.config.scrollContainer || window, "scroll", this.scrollHandler), this.util().removeEvent(window, "resize", this.scrollHandler), null != this.interval ? clearInterval(this.interval) : void 0 3991 }, e.prototype.sync = function () { 3992 return a.notSupported ? this.doSync(this.element) : void 0 3993 }, e.prototype.doSync = function (a) { 3994 var b, c, d, e, f; 3995 if (null == a && (a = this.element), 1 === a.nodeType) { 3996 for (a = a.parentNode || a, e = a.querySelectorAll("." + this.config.boxClass), f = [], c = 0, d = e.length; d > c; c++) b = e[c], g.call(this.all, b) < 0 ? (this.boxes.push(b), this.all.push(b), this.stopped || this.disabled() ? this.resetStyle() : this.applyStyle(b, !0), f.push(this.scrolled = !0)) : f.push(void 0); 3997 return f 3998 } 3999 }, e.prototype.show = function (a) { 4000 return this.applyStyle(a), a.className = a.className + " " + this.config.animateClass, null != this.config.callback && this.config.callback(a), this.util().emitEvent(a, this.wowEvent), this.util().addEvent(a, "animationend", this.resetAnimation), this.util().addEvent(a, "oanimationend", this.resetAnimation), this.util().addEvent(a, "webkitAnimationEnd", this.resetAnimation), this.util().addEvent(a, "MSAnimationEnd", this.resetAnimation), a 4001 }, e.prototype.applyStyle = function (a, b) { 4002 var c, d, e; 4003 return d = a.getAttribute("data-wow-duration"), c = a.getAttribute("data-wow-delay"), e = a.getAttribute("data-wow-iteration"), this.animate(function (f) { 4004 return function () { 4005 return f.customStyle(a, b, d, c, e) 4006 } 4007 }(this)) 4008 }, e.prototype.animate = function () { 4009 return "requestAnimationFrame" in window ? function (a) { 4010 return window.requestAnimationFrame(a) 4011 } : function (a) { 4012 return a() 4013 } 4014 }(), e.prototype.resetStyle = function () { 4015 var a, b, c, d, e; 4016 for (d = this.boxes, e = [], b = 0, c = d.length; c > b; b++) a = d[b], e.push(a.style.visibility = "visible"); 4017 return e 4018 }, e.prototype.resetAnimation = function (a) { 4019 var b; 4020 return a.type.toLowerCase().indexOf("animationend") >= 0 ? (b = a.target || a.srcElement, b.className = b.className.replace(this.config.animateClass, "").trim()) : void 0 4021 }, e.prototype.customStyle = function (a, b, c, d, e) { 4022 return b && this.cacheAnimationName(a), a.style.visibility = b ? "hidden" : "visible", c && this.vendorSet(a.style, { 4023 animationDuration: c 4024 }), d && this.vendorSet(a.style, { 4025 animationDelay: d 4026 }), e && this.vendorSet(a.style, { 4027 animationIterationCount: e 4028 }), this.vendorSet(a.style, { 4029 animationName: b ? "none" : this.cachedAnimationName(a) 4030 }), a 4031 }, e.prototype.vendors = ["moz", "webkit"], e.prototype.vendorSet = function (a, b) { 4032 var c, d, e, f; 4033 d = []; 4034 for (c in b) e = b[c], a["" + c] = e, d.push(function () { 4035 var b, d, g, h; 4036 for (g = this.vendors, h = [], b = 0, d = g.length; d > b; b++) f = g[b], h.push(a["" + f + c.charAt(0).toUpperCase() + c.substr(1)] = e); 4037 return h 4038 }.call(this)); 4039 return d 4040 }
4040, e.prototype.vendorCSS = function (a, b) { 4041 var c, e, f, g, h, i; 4042 for (h = d(a), g = h.getPropertyCSSValue(b), f = this.vendors, c = 0, e = f.length; e > c; c++) i = f[c], g = g || h.getPropertyCSSValue("-" + i + "-" + b); 4043 return g 4044 }, e.prototype.animationName = function (a) { 4045 var b; 4046 try { 4047 b = this.vendorCSS(a, "animation-name").cssText 4048 } catch (c) { 4049 b = d(a).getPropertyValue("animation-name") 4050 } 4051 return "none" === b ? "" : b 4052 }, e.prototype.cacheAnimationName = function (a) { 4053 return this.animationNameCache.set(a, this.animationName(a)) 4054 }, e.prototype.cachedAnimationName = function (a) { 4055 return this.animationNameCache.get(a) 4056 }, e.prototype.scrollHandler = function () { 4057 return this.scrolled = !0 4058 }, e.prototype.scrollCallback = function () { 4059 var a; 4060 return !this.scrolled || (this.scrolled = !1, this.boxes = function () { 4061 var b, c, d, e; 4062 for (d = this.boxes, e = [], b = 0, c = d.length; c > b; b++) a = d[b], a && (this.isVisible(a) ? this.show(a) : e.push(a)); 4063 return e 4064 }.call(this), this.boxes.length || this.config.live) ? void 0 : this.stop() 4065 }, e.prototype.offsetTop = function (a) { 4066 for (var b; void 0 === a.offsetTop;) a = a.parentNode; 4067 for (b = a.offsetTop; a = a.offsetParent;) b += a.offsetTop; 4068 return b 4069 }, e.prototype.isVisible = function (a) { 4070 var b, c, d, e, f; 4071 return c = a.getAttribute("data-wow-offset") || this.config.offset, f = this.config.scrollContainer && this.config.scrollContainer.scrollTop || window.pageYOffset, e = f + Math.min(this.element.clientHeight, this.util().innerHeight()) - c, d = this.offsetTop(a), b = d + a.clientHeight, e >= d && b >= f 4072 }, e.prototype.util = function () { 4073 return null != this._util ? this._util : this._util = new b 4074 }, e.prototype.disabled = function () { 4075 return !this.config.mobile && this.util().isMobile(navigator.userAgent) 4076 }, e 4077 }() 4078}).call(this); 4079 4080 4081/* 4082 * Typed Animation 4083 * ----------------------------------------------- 4084 */ 4085! function (t) { 4086 "use strict"; 4087 var s = function (s, e) { 4088 this.el = t(s), this.options = t.extend({}, t.fn.typed.defaults, e), this.isInput = this.el.is("input"), this.attr = this.options.attr, this.showCursor = this.isInput ? !1 : this.options.showCursor, this.elContent = this.attr ? this.el.attr(this.attr) : this.el.text(), this.contentType = this.options.contentType, this.typeSpeed = this.options.typeSpeed, this.startDelay = this.options.startDelay, this.backSpeed = this.options.backSpeed, this.backDelay = this.options.backDelay, this.stringsElement = this.options.stringsElement, this.strings = this.options.strings, this.strPos = 0, this.arrayPos = 0, this.stopNum = 0, this.loop = this.options.loop, this.loopCount = this.options.loopCount, this.curLoop = 0, this.stop = !1, this.cursorChar = this.options.cursorChar, this.shuffle = this.options.shuffle, this.sequence = [], this.build() 4089 }; 4090 s.prototype = { 4091 constructor: s, 4092 init: function () { 4093 var t = this; 4094 t.timeout = setTimeout(function () { 4095 for (var s = 0; s < t.strings.length; ++s) t.sequence[s] = s; 4096 t.shuffle && (t.sequence = t.shuffleArray(t.sequence)), t.typewrite(t.strings[t.sequence[t.arrayPos]], t.strPos) 4097 }, t.startDelay) 4098 }, 4099 build: function () { 4100 var s = this; 4101 if (this.showCursor === !0 && (this.cursor = t('<span class="typed-cursor">' + this.cursorChar + "</span>"), this.el.after(this.cursor)), this.stringsElement) { 4102 s.strings = [], this.stringsElement.hide(); 4103 var e = this.stringsElement.find("p"); 4104 t.each(e, function (e, i) { 4105 s.strings.push(t(i).html()) 4106 }) 4107 } 4108 this.init() 4109 }, 4110 typewrite: function (t, s) { 4111 if (this.stop !== !0) { 4112 var e = Math.round(70 * Math.random()) + this.typeSpeed, 4113 i = this; 4114 i.timeout = setTimeout(function () { 4115 var e = 0, 4116 r = t.substr(s); 4117 if ("^" === r.charAt(0)) { 4118 var o = 1; 4119 /^\^\d+/.test(r) && (r = /\d+/.exec(r)[0], o += r.length, e = parseInt(r)), t = t.substring(0, s) + t.substring(s + o) 4120 } 4121 if ("html" === i.contentType) { 4122 var n = t.substr(s).charAt(0);
4123 if ("<" === n || "&" === n) { 4124 var a = "", 4125 h = ""; 4126 for (h = "<" === n ? ">" : ";"; t.substr(s).charAt(0) !== h;) a += t.substr(s).charAt(0), s++; 4127 s++ , a += h 4128 } 4129 } 4130 i.timeout = setTimeout(function () { 4131 if (s === t.length) { 4132 if (i.options.onStringTyped(i.arrayPos), i.arrayPos === i.strings.length - 1 && (i.options.callback(), i.curLoop++ , i.loop === !1 || i.curLoop === i.loopCount)) return; 4133 i.timeout = setTimeout(function () { 4134 i.backspace(t, s) 4135 }, i.backDelay) 4136 } else { 4137 0 === s && i.options.preStringTyped(i.arrayPos); 4138 var e = t.substr(0, s + 1); 4139 i.attr ? i.el.attr(i.attr, e) : i.isInput ? i.el.val(e) : "html" === i.contentType ? i.el.html(e) : i.el.text(e), s++ , i.typewrite(t, s) 4140 } 4141 }, e) 4142 }, e) 4143 } 4144 }, 4145 backspace: function (t, s) { 4146 if (this.stop !== !0) { 4147 var e = Math.round(70 * Math.random()) + this.backSpeed, 4148 i = this; 4149 i.timeout = setTimeout(function () { 4150 if ("html" === i.contentType && ">" === t.substr(s).charAt(0)) { 4151 for (var e = ""; 4152 "<" !== t.substr(s).charAt(0);) e -= t.substr(s).charAt(0), s--; 4153 s-- , e += "<" 4154 } 4155 var r = t.substr(0, s); 4156 i.attr ? i.el.attr(i.attr, r) : i.isInput ? i.el.val(r) : "html" === i.contentType ? i.el.html(r) : i.el.text(r), s > i.stopNum ? (s-- , i.backspace(t, s)) : s <= i.stopNum && (i.arrayPos++ , i.arrayPos === i.strings.length ? (i.arrayPos = 0, i.shuffle && (i.sequence = i.shuffleArray(i.sequence)), i.init()) : i.typewrite(i.strings[i.sequence[i.arrayPos]], s)) 4157 }, e) 4158 } 4159 }, 4160 shuffleArray: function (t) { 4161 var s, e, i = t.length; 4162 if (i) 4163 for (; --i;) e = Math.floor(Math.random() * (i + 1)), s = t[e], t[e] = t[i], t[i] = s; 4164 return t 4165 }, 4166 reset: function () { 4167 var t = this; 4168 clearInterval(t.timeout); 4169 var s = this.el.attr("id"); 4170 this.el.after('<span id="' + s + '"/>'), this.el.remove(), "undefined" != typeof this.cursor && this.cursor.remove(), t.options.resetCallback() 4171 } 4172 }, t.fn.typed = function (e) { 4173 return this.each(function () { 4174 var i = t(this), 4175 r = i.data("typed"), 4176 o = "object" == typeof e && e; 4177 r || i.data("typed", r = new s(this, o)), "string" == typeof e && r[e]() 4178 }) 4179 }, t.fn.typed.defaults = { 4180 strings: ["These are the default values...", "You know what you should do?", "Use your own!", "Have a great day!"], 4181 stringsElement: null, 4182 typeSpeed: 0, 4183 startDelay: 0, 4184 backSpeed: 0, 4185 shuffle: !1, 4186 backDelay: 500, 4187 loop: !1, 4188 loopCount: !1, 4189 showCursor: !0, 4190 cursorChar: "|", 4191 attr: null, 4192 contentType: "html", 4193 callback: function () { }, 4194 preStringTyped: function () { }, 4195 onStringTyped: function () { }, 4196 resetCallback: function () { } 4197 } 4198}(window.jQuery); 4199 4200 4201/* 4202 * Owl carousel 4203 * ----------------------------------------------- 4204 */ 4205! function (a, b, c, d) { 4206 function e(b, c) { 4207 this.settings = null, this.options = a.extend({}, e.Defaults, c), this.$element = a(b), this.drag = a.extend({}, m), this.state = a.extend({}, n), this.e = a.extend({}, o), this._plugins = {}, this._supress = {}, this._current = null, this._speed = null, this._coordinates = [], this._breakpoint = null, this._width = null, this._items = [], this._clones = [], this._mergers = [], this._invalidated = {}, this._pipe = [], a.each(e.Plugins, a.proxy(function (a, b) { 4208 this._plugins[a[0].toLowerCase() + a.slice(1)] = new b(this) 4209 }, this)), a.each(e.Pipe, a.proxy(function (b, c) { 4210 this._pipe.push({ 4211 filter: c.filter, 4212 run: a.proxy(c.run, this) 4213 }) 4214 }, this)), this.setup(), this.initialize() 4215 } 4216 4217 function f(a) { 4218 if (a.touches !== d) return { 4219 x: a.touches[0].pageX, 4220 y: a.touches[0].pageY 4221 }; 4222 if (a.touches === d) { 4223 if (a.pageX !== d) return { 4224 x: a.pageX, 4225 y: a.pageY 4226 }; 4227 if (a.pageX === d) return { 4228 x: a.clientX, 4229 y: a.clientY 4230 } 4231 } 4232 } 4233
4234 function g(a) { 4235 var b, d, e = c.createElement("div"), 4236 f = a; 4237 for (b in f) 4238 if (d = f[b], "undefined" != typeof e.style[d]) return e = null, [d, b]; 4239 return [!1] 4240 } 4241 4242 function h() { 4243 return g(["transition", "WebkitTransition", "MozTransition", "OTransition"])[1] 4244 } 4245 4246 function i() { 4247 return g(["transform", "WebkitTransform", "MozTransform", "OTransform", "msTransform"])[0] 4248 } 4249 4250 function j() { 4251 return g(["perspective", "webkitPerspective", "MozPerspective", "OPerspective", "MsPerspective"])[0] 4252 } 4253 4254 function k() { 4255 return "ontouchstart" in b || !!navigator.msMaxTouchPoints 4256 } 4257 4258 function l() { 4259 return b.navigator.msPointerEnabled 4260 } 4261 var m, n, o; 4262 m = { 4263 start: 0, 4264 startX: 0, 4265 startY: 0, 4266 current: 0, 4267 currentX: 0, 4268 currentY: 0, 4269 offsetX: 0, 4270 offsetY: 0, 4271 distance: null, 4272 startTime: 0, 4273 endTime: 0, 4274 updatedX: 0, 4275 targetEl: null 4276 }, n = { 4277 isTouch: !1, 4278 isScrolling: !1, 4279 isSwiping: !1, 4280 direction: !1, 4281 inMotion: !1 4282 }, o = { 4283 _onDragStart: null, 4284 _onDragMove: null, 4285 _onDragEnd: null, 4286 _transitionEnd: null, 4287 _resizer: null, 4288 _responsiveCall: null, 4289 _goToLoop: null, 4290 _checkVisibile: null 4291 }, e.Defaults = { 4292 items: 3, 4293 loop: !1, 4294 center: !1, 4295 mouseDrag: !0, 4296 touchDrag: !0, 4297 pullDrag: !0, 4298 freeDrag: !1, 4299 margin: 0, 4300 stagePadding: 0, 4301 merge: !1, 4302 mergeFit: !0, 4303 autoWidth: !1, 4304 startPosition: 0, 4305 rtl: !1, 4306 smartSpeed: 250, 4307 fluidSpeed: !1, 4308 dragEndSpeed: !1, 4309 responsive: {}, 4310 responsiveRefreshRate: 200, 4311 responsiveBaseElement: b, 4312 responsiveClass: !1, 4313 fallbackEasing: "swing", 4314 info: !1, 4315 nestedItemSelector: !1, 4316 itemElement: "div", 4317 stageElement: "div", 4318 themeClass: "owl-theme", 4319 baseClass: "owl-carousel", 4320 itemClass: "owl-item", 4321 centerClass: "center", 4322 activeClass: "active" 4323 }, e.Width = { 4324 Default: "default", 4325 Inner: "inner", 4326 Outer: "outer" 4327 }, e.Plugins = {}, e.Pipe = [{ 4328 filter: ["width", "items", "settings"], 4329 run: function (a) { 4330 a.current = this._items && this._items[this.relative(this._current)] 4331 } 4332 }, { 4333 filter: ["items", "settings"], 4334 run: function () { 4335 var a = this._clones, 4336 b = this.$stage.children(".cloned"); 4337 (b.length !== a.length || !this.settings.loop && a.length > 0) && (this.$stage.children(".cloned").remove(), this._clones = []) 4338 } 4339 }, { 4340 filter: ["items", "settings"], 4341 run: function () { 4342 var a, b, c = this._clones, 4343 d = this._items, 4344 e = this.settings.loop ? c.length - Math.max(2 * this.settings.items, 2) : 0; 4345 for (a = 0, b = Math.abs(e / 2); b > a; a++) e > 0 ? (this.$stage.children().eq(d.length + c.length - 1).remove(), c.pop(), this.$stage.children().eq(0).remove(), c.pop()) : (c.push(c.length / 2), this.$stage.append(d[c[c.length - 1]].clone().addClass("cloned")), c.push(d.length - 1 - (c.length - 1) / 2), this.$stage.prepend(d[c[c.length - 1]].clone().addClass("cloned"))) 4346 } 4347 }, { 4348 filter: ["width", "items", "settings"], 4349 run: function () { 4350 var a, b, c, d = this.settings.rtl ? 1 : -1, 4351 e = (this.width() / this.settings.items).toFixed(3), 4352 f = 0; 4353 for (this._coordinates = [], b = 0, c = this._clones.length + this._items.length; c > b; b++) a = this._mergers[this.relative(b)], a = this.settings.mergeFit && Math.min(a, this.settings.items) || a, f += (this.settings.autoWidth ? this._items[this.relative(b)].width() + this.settings.margin : e * a) * d, this._coordinates.push(f) 4354 } 4355 }, { 4356 filter: ["width", "items", "settings"], 4357 run: function () { 4358 var b, c, d = (this.width() / this.settings.items).toFixed(3), 4359 e = { 4360 width: Math.abs(this._coordinates[this._coordinates.length - 1]) + 2 * this.settings.stagePadding, 4361 "padding-left": this.settings.stagePadding || "", 4362 "padding-right": this.settings.stagePadding || "" 4363 }; 4364 if (this.$stage.css(e), e = { 4365 width: this.settings.autoWidth ? "auto" : d - this.settings.margin 4366 }, e[this.settings.rtl ? "margin-left" : "margin-right"] = this.settings.margin, !this.settings.autoWidth && a.grep(this._mergers, function (a) { 4367 return a > 1 4368 }).length > 0) 4369 for (b = 0, c = this._coordinates.length; c > b; b++) e.width = Math.abs(this._coordinates[b]) - Math.abs(this._coordinates[b - 1] || 0) - this.settings.margin, this.$stage.children().eq(b).css(e); 4370 else this.$stage.children().css(e) 4371 } 4372 }, { 4373 filter: ["width", "items", "settings"], 4374 run: function (a) { 4375 a.current && this.reset(this.$stage.children().index(a.current)) 4376 } 4377 }, { 4378 filter: ["position"], 4379 run: function () { 4380 this.animate(this.coordinates(this._current)) 4381 } 4382 }, { 4383 filter: ["width", "position", "items", "settings"], 4384 run: function () { 4385 var a, b, c, d, e = this.settings.rtl ? 1 : -1, 4386 f = 2 * this.settings.stagePadding, 4387 g = this.coordinates(this.current()) + f, 4388 h = g + this.width() * e, 4389 i = []; 4390 for (c = 0, d = this._coordinates.length; d > c; c++) a = this._coordinates[c - 1] || 0, b = Math.abs(this._coordinates[c]) + f * e, (this.op(a, "<=", g) && this.op(a, ">", h) || this.op(b, "<", g) && this.op(b, ">", h)) && i.push(c); 4391 this.$stage.children("." + this.settings.activeClass).removeClass(this.settings.activeClass), this.$stage.children(":eq(" + i.join("), :eq(") + ")").addClass(this.settings.activeClass), this.settings.center && (this.$stage.children("." + this.settings.centerClass).removeClass(this.settings.centerClass), this.$stage.children().eq(this.current()).addClass(this.settings.centerClass)) 4392 } 4393 }], e.prototype.initialize = function () { 4394 if (this.trigger("initialize"), this.$element.addClass(this.settings.baseClass).addClass(this.settings.themeClass).toggleClass("owl-rtl", this.settings.rtl), this.browserSupport(), this.settings.autoWidth && this.state.imagesLoaded !== !0) { 4395 var b, c, e; 4396 if (b = this.$element.find("img"), c = this.settings.nestedItemSelector ? "." + this.settings.nestedItemSelector : d, e = this.$element.children(c).width(), b.length && 0 >= e) return this.preloadAutoWidthImages(b), !1 4397 } 4398 this.$element.addClass("owl-loading"), this.$stage = a("<" + this.settings.stageElement + ' class="owl-stage"/>').wrap('<div class="owl-stage-outer">'), this.$element.append(this.$stage.parent()), this.replace(this.$element.children().not(this.$stage.parent())), this._width = this.$element.width(), this.refresh(), this.$element.removeClass("owl-loading").addClass("owl-loaded"), this.eventsCall(), this.internalEvents(), this.addTriggerableEvents(), this.trigger("initialized") 4399 }, e.prototype.setup = function () { 4400 var b = this.viewport(), 4401 c = this.options.responsive, 4402 d = -1, 4403 e = null; 4404 c ? (a.each(c, function (a) { 4405 b >= a && a > d && (d = Number(a)) 4406 }), e = a.extend({}, this.options, c[d]), delete e.responsive, e.responsiveClass && this.$element.attr("class", function (a, b) { 4407 return b.replace(/\b owl-responsive-\S+/g, "") 4408 }).addClass("owl-responsive-" + d)) : e = a.extend({}, this.options), (null === this.settings || this._breakpoint !== d) && (this.trigger("change", { 4409 property: { 4410 name: "settings", 4411 value: e 4412 } 4413 }), this._breakpoint = d, this.settings = e, this.invalidate("settings"), this.trigger("changed", { 4414 property: { 4415 name: "settings", 4416 value: this.settings 4417 } 4418 })) 4419 }, e.prototype.optionsLogic = function () { 4420 this.$element.toggleClass("owl-center", this.settings.center), this.settings.loop && this._items.length < this.settings.items && (this.settings.loop = !1), this.settings.autoWidth && (this.settings.stagePadding = !1, this.settings.merge = !1) 4421 }, e.prototype.prepare = function (b) { 4422 var c = this.trigger("prepare", { 4423 content: b 4424 }); 4425 return c.data || (c.data = a("<" + this.settings.itemElement + "/>").addClass(this.settings.itemClass).append(b)), this.trigger("prepared", { 4426 content: c.data 4427 }), c.data 4428 }, e.prototype.update = function () { 4429 for (var b = 0, c = this._pipe.length, d = a.proxy(function (a) { 4430 return this[a] 4431 }, this._invalidated), e = {}; c > b;)(this._invalidated.all || a.grep(this._pipe[b].filter, d).length > 0) && this._pipe[b].run(e), b++; 4432 this._invalidated = {} 4433 }, e.prototype.width = function (a) { 4434 switch (a = a || e.Width.Default) { 4435 case e.Width.Inner: 4436 case e.Width.Outer: 4437 return this._width; 4438 default: 4439 return this._width - 2 * this.settings.stagePadding + this.settings.margin 4440 } 4441 }, e.prototype.refresh = function () { 4442 if (0 === this._items.length) return !1; 4443 (new Date).getTime(); 4444 this.trigger("refresh"), this.setup(), this.optionsLogic(), this.$stage.addClass("owl-refresh"), this.update(), this.$stage.removeClass("owl-refresh"), this.state.orientation = b.orientation, this.watchVisibility(), this.trigger("refreshed") 4445 }, e.prototype.eventsCall = function () { 4446 this.e._onDragStart = a.proxy(function (a) { 4447 this.onDragStart(a) 4448 }, this), this.e._onDragMove = a.proxy(function (a) { 4449 this.onDragMove(a) 4450 }, this), this.e._onDragEnd = a.proxy(function (a) { 4451 this.onDragEnd(a) 4452 }, this), this.e._onResize = a.proxy(function (a) { 4453 this.onResize(a) 4454 }, this), this.e._transitionEnd = a.proxy(function (a) { 4455 this.transitionEnd(a) 4456 }, this), this.e._preventClick = a.proxy(function (a) { 4457 this.preventClick(a) 4458 }, this) 4459 }, e.prototype.onThrottledResize = function () { 4460 b.clearTimeout(this.resizeTimer), this.resizeTimer = b.setTimeout(this.e._onResize, this.settings.responsiveRefreshRate) 4461 }, e.prototype.onResize = function () { 4462 return this._items.length ? this._width === this.$element.width() ? !1 : this.trigger("resize").isDefaultPrevented() ? !1 : (this._width = this.$element.width(), this.invalidate("width"), this.refresh(), void this.trigger("resized")) : !1 4463 }, e.prototype.eventsRouter = function (a) { 4464 var b = a.type; 4465 "mousedown" === b || "touchstart" === b ? this.onDragStart(a) : "mousemove" === b || "touchmove" === b ? this.onDragMove(a) : "mouseup" === b || "touchend" === b ? this.onDragEnd(a) : "touchcancel" === b && this.onDragEnd(a) 4466 }, e.prototype.internalEvents = function () { 4467 var c = (k(), l()); 4468 this.settings.mouseDrag ? (this.$stage.on("mousedown", a.proxy(function (a) { 4469 this.eventsRouter(a) 4470 }, this)), this.$stage.on("dragstart", function () { 4471 return !1 4472 }), this.$stage.get(0).onselectstart = function () { 4473 return !1 4474 }) : this.$element.addClass("owl-text-select-on"), this.settings.touchDrag && !c && this.$stage.on("touchstart touchcancel", a.proxy(function (a) { 4475 this.eventsRouter(a) 4476 }, this)), this.transitionEndVendor && this.on(this.$stage.get(0), this.transitionEndVendor, this.e._transitionEnd, !1), this.settings.responsive !== !1 && this.on(b, "resize", a.proxy(this.onThrottledResize, this)) 4477 }, e.prototype.onDragStart = function (d) { 4478 var e, g, h, i;
4479 if (e = d.originalEvent || d || b.event, 3 === e.which || this.state.isTouch) return !1; 4480 if ("mousedown" === e.type && this.$stage.addClass("owl-grab"), this.trigger("drag"), this.drag.startTime = (new Date).getTime(), this.speed(0), this.state.isTouch = !0, this.state.isScrolling = !1, this.state.isSwiping = !1, this.drag.distance = 0, g = f(e).x, h = f(e).y, this.drag.offsetX = this.$stage.position().left, this.drag.offsetY = this.$stage.position().top, this.settings.rtl && (this.drag.offsetX = this.$stage.position().left + this.$stage.width() - this.width() + this.settings.margin), this.state.inMotion && this.support3d) i = this.getTransformProperty(), this.drag.offsetX = i, this.animate(i), this.state.inMotion = !0; 4481 else if (this.state.inMotion && !this.support3d) return this.state.inMotion = !1, !1; 4482 this.drag.startX = g - this.drag.offsetX, this.drag.startY = h - this.drag.offsetY, this.drag.start = g - this.drag.startX, this.drag.targetEl = e.target || e.srcElement, this.drag.updatedX = this.drag.start, ("IMG" === this.drag.targetEl.tagName || "A" === this.drag.targetEl.tagName) && (this.drag.targetEl.draggable = !1), a(c).on("mousemove.owl.dragEvents mouseup.owl.dragEvents touchmove.owl.dragEvents touchend.owl.dragEvents", a.proxy(function (a) { 4483 this.eventsRouter(a) 4484 }, this)) 4485 }, e.prototype.onDragMove = function (a) { 4486 var c, e, g, h, i, j; 4487 this.state.isTouch && (this.state.isScrolling || (c = a.originalEvent || a || b.event, e = f(c).x, g = f(c).y, this.drag.currentX = e - this.drag.startX, this.drag.currentY = g - this.drag.startY, this.drag.distance = this.drag.currentX - this.drag.offsetX, this.drag.distance < 0 ? this.state.direction = this.settings.rtl ? "right" : "left" : this.drag.distance > 0 && (this.state.direction = this.settings.rtl ? "left" : "right"), this.settings.loop ? this.op(this.drag.currentX, ">", this.coordinates(this.minimum())) && "right" === this.state.direction ? this.drag.currentX -= (this.settings.center && this.coordinates(0)) - this.coordinates(this._items.length) : this.op(this.drag.currentX, "<", this.coordinates(this.maximum())) && "left" === this.state.direction && (this.drag.currentX += (this.settings.center && this.coordinates(0)) - this.coordinates(this._items.length)) : (h = this.coordinates(this.settings.rtl ? this.maximum() : this.minimum()), i = this.coordinates(this.settings.rtl ? this.minimum() : this.maximum()), j = this.settings.pullDrag ? this.drag.distance / 5 : 0, this.drag.currentX = Math.max(Math.min(this.drag.currentX, h + j), i + j)), (this.drag.distance > 8 || this.drag.distance < -8) && (c.preventDefault !== d ? c.preventDefault() : c.returnValue = !1, this.state.isSwiping = !0), this.drag.updatedX = this.drag.currentX, (this.drag.currentY > 16 || this.drag.currentY < -16) && this.state.isSwiping === !1 && (this.state.isScrolling = !0, this.drag.updatedX = this.drag.start), this.animate(this.drag.updatedX))) 4488 }, e.prototype.onDragEnd = function (b) { 4489 var d, e, f; 4490 if (this.state.isTouch) { 4491 if ("mouseup" === b.type && this.$stage.removeClass("owl-grab"), this.trigger("dragged"), this.drag.targetEl.removeAttribute("draggable"), this.state.isTouch = !1, this.state.isScrolling = !1, this.state.isSwiping = !1, 0 === this.drag.distance && this.state.inMotion !== !0) return this.state.inMotion = !1, !1; 4492 this.drag.endTime = (new Date).getTime(), d = this.drag.endTime - this.drag.startTime, e = Math.abs(this.drag.distance), (e > 3 || d > 300) && this.removeClick(this.drag.targetEl), f = this.closest(this.drag.updatedX), this.speed(this.settings.dragEndSpeed || this.settings.smartSpeed), this.current(f), this.invalidate("position"), this.update(), this.settings.pullDrag || this.drag.updatedX !== this.coordinates(f) || this.transitionEnd(), this.drag.distance = 0, a(c).off(".owl.dragEvents") 4493 } 4494 }, e.prototype.removeClick = function (c) { 4495 this.drag.targetEl = c, a(c).on("click.preventClick", this.e._preventClick), b.setTimeout(function () { 4496 a(c).off("click.preventClick") 4497 }, 300) 4498 }, e.prototype.preventClick = function (b) { 4499 b.preventDefault ? b.preventDefault() : b.returnValue = !1, b.stopPropagation && b.stopPropagation(), a(b.target).off("click.preventClick") 4500 }, e.prototype.getTransformProperty = function () { 4501 var a, c; 4502 return a = b.getComputedStyle(this.$stage.get(0), null).getPropertyValue(this.vendorName + "transform"), a = a.replace(/matrix(3d)?\(|\)/g, "").split(","), c = 16 === a.length, c !== !0 ? a[4] : a[12] 4503 }, e.prototype.closest = function (b) { 4504 var c = -1, 4505 d = 30, 4506 e = this.width(), 4507 f = this.coordinates();
4508 return this.settings.freeDrag || a.each(f, a.proxy(function (a, g) { 4509 return b > g - d && g + d > b ? c = a : this.op(b, "<", g) && this.op(b, ">", f[a + 1] || g - e) && (c = "left" === this.state.direction ? a + 1 : a), -1 === c 4510 }, this)), this.settings.loop || (this.op(b, ">", f[this.minimum()]) ? c = b = this.minimum() : this.op(b, "<", f[this.maximum()]) && (c = b = this.maximum())), c 4511 }, e.prototype.animate = function (b) { 4512 this.trigger("translate"), this.state.inMotion = this.speed() > 0, this.support3d ? this.$stage.css({ 4513 transform: "translate3d(" + b + "px,0px, 0px)", 4514 transition: this.speed() / 1e3 + "s" 4515 }) : this.state.isTouch ? this.$stage.css({ 4516 left: b + "px" 4517 }) : this.$stage.animate({ 4518 left: b 4519 }, this.speed() / 1e3, this.settings.fallbackEasing, a.proxy(function () { 4520 this.state.inMotion && this.transitionEnd() 4521 }, this)) 4522 }, e.prototype.current = function (a) { 4523 if (a === d) return this._current; 4524 if (0 === this._items.length) return d; 4525 if (a = this.normalize(a), this._current !== a) { 4526 var b = this.trigger("change", { 4527 property: { 4528 name: "position", 4529 value: a 4530 } 4531 }); 4532 b.data !== d && (a = this.normalize(b.data)), this._current = a, this.invalidate("position"), this.trigger("changed", { 4533 property: { 4534 name: "position", 4535 value: this._current 4536 } 4537 }) 4538 } 4539 return this._current 4540 }, e.prototype.invalidate = function (a) { 4541 this._invalidated[a] = !0 4542 }, e.prototype.reset = function (a) { 4543 a = this.normalize(a), a !== d && (this._speed = 0, this._current = a, this.suppress(["translate", "translated"]), this.animate(this.coordinates(a)), this.release(["translate", "translated"])) 4544 }, e.prototype.normalize = function (b, c) { 4545 var e = c ? this._items.length : this._items.length + this._clones.length; 4546 return !a.isNumeric(b) || 1 > e ? d : b = this._clones.length ? (b % e + e) % e : Math.max(this.minimum(c), Math.min(this.maximum(c), b)) 4547 }, e.prototype.relative = function (a) { 4548 return a = this.normalize(a), a -= this._clones.length / 2, this.normalize(a, !0) 4549 }, e.prototype.maximum = function (a) { 4550 var b, c, d, e = 0, 4551 f = this.settings; 4552 if (a) return this._items.length - 1; 4553 if (!f.loop && f.center) b = this._items.length - 1; 4554 else if (f.loop || f.center) 4555 if (f.loop || f.center) b = this._items.length + f.items; 4556 else { 4557 if (!f.autoWidth && !f.merge) throw "Can not detect maximum absolute position."; 4558 for (revert = f.rtl ? 1 : -1, c = this.$stage.width() - this.$element.width(); 4559 (d = this.coordinates(e)) && !(d * revert >= c);) b = ++e 4560 } 4561 else b = this._items.length - f.items; 4562 return b 4563 }, e.prototype.minimum = function (a) { 4564 return a ? 0 : this._clones.length / 2 4565 }, e.prototype.items = function (a) { 4566 return a === d ? this._items.slice() : (a = this.normalize(a, !0), this._items[a]) 4567 }, e.prototype.mergers = function (a) { 4568 return a === d ? this._mergers.slice() : (a = this.normalize(a, !0), this._mergers[a]) 4569 }, e.prototype.clones = function (b) { 4570 var c = this._clones.length / 2, 4571 e = c + this._items.length, 4572 f = function (a) { 4573 return a % 2 === 0 ? e + a / 2 : c - (a + 1) / 2 4574 }; 4575 return b === d ? a.map(this._clones, function (a, b) { 4576 return f(b) 4577 }) : a.map(this._clones, function (a, c) { 4578 return a === b ? f(c) : null 4579 }) 4580 }, e.prototype.speed = function (a) { 4581 return a !== d && (this._speed = a), this._speed 4582 }, e.prototype.coordinates = function (b) { 4583 var c = null; 4584 return b === d ? a.map(this._coordinates, a.proxy(function (a, b) { 4585 return this.coordinates(b) 4586 }, this)) : (this.settings.center ? (c = this._coordinates[b], c += (this.width() - c + (this._coordinates[b - 1] || 0)) / 2 * (this.settings.rtl ? -1 : 1)) : c = this._coordinates[b - 1] || 0, c) 4587 }, e.prototype.duration = function (a, b, c) {
4588 return Math.min(Math.max(Math.abs(b - a), 1), 6) * Math.abs(c || this.settings.smartSpeed) 4589 }, e.prototype.to = function (c, d) { 4590 if (this.settings.loop) { 4591 var e = c - this.relative(this.current()), 4592 f = this.current(), 4593 g = this.current(), 4594 h = this.current() + e, 4595 i = 0 > g - h ? !0 : !1, 4596 j = this._clones.length + this._items.length; 4597 h < this.settings.items && i === !1 ? (f = g + this._items.length, this.reset(f)) : h >= j - this.settings.items && i === !0 && (f = g - this._items.length, this.reset(f)), b.clearTimeout(this.e._goToLoop), this.e._goToLoop = b.setTimeout(a.proxy(function () { 4598 this.speed(this.duration(this.current(), f + e, d)), this.current(f + e), this.update() 4599 }, this), 30) 4600 } else this.speed(this.duration(this.current(), c, d)), this.current(c), this.update() 4601 }, e.prototype.next = function (a) { 4602 a = a || !1, this.to(this.relative(this.current()) + 1, a) 4603 }, e.prototype.prev = function (a) { 4604 a = a || !1, this.to(this.relative(this.current()) - 1, a) 4605 }, e.prototype.transitionEnd = function (a) { 4606 return a !== d && (a.stopPropagation(), (a.target || a.srcElement || a.originalTarget) !== this.$stage.get(0)) ? !1 : (this.state.inMotion = !1, void this.trigger("translated")) 4607 }, e.prototype.viewport = function () { 4608 var d; 4609 if (this.options.responsiveBaseElement !== b) d = a(this.options.responsiveBaseElement).width(); 4610 else if (b.innerWidth) d = b.innerWidth; 4611 else { 4612 if (!c.documentElement || !c.documentElement.clientWidth) throw "Can not detect viewport width."; 4613 d = c.documentElement.clientWidth 4614 } 4615 return d 4616 }, e.prototype.replace = function (b) { 4617 this.$stage.empty(), this._items = [], b && (b = b instanceof jQuery ? b : a(b)), this.settings.nestedItemSelector && (b = b.find("." + this.settings.nestedItemSelector)), b.filter(function () { 4618 return 1 === this.nodeType 4619 }).each(a.proxy(function (a, b) { 4620 b = this.prepare(b), this.$stage.append(b), this._items.push(b), this._mergers.push(1 * b.find("[data-merge]").andSelf("[data-merge]").attr("data-merge") || 1) 4621 }, this)), this.reset(a.isNumeric(this.settings.startPosition) ? this.settings.startPosition : 0), this.invalidate("items") 4622 }, e.prototype.add = function (a, b) { 4623 b = b === d ? this._items.length : this.normalize(b, !0), this.trigger("add", { 4624 content: a, 4625 position: b 4626 }), 0 === this._items.length || b === this._items.length ? (this.$stage.append(a), this._items.push(a), this._mergers.push(1 * a.find("[data-merge]").andSelf("[data-merge]").attr("data-merge") || 1)) : (this._items[b].before(a), this._items.splice(b, 0, a), this._mergers.splice(b, 0, 1 * a.find("[data-merge]").andSelf("[data-merge]").attr("data-merge") || 1)), this.invalidate("items"), this.trigger("added", { 4627 content: a, 4628 position: b 4629 }) 4630 }, e.prototype.remove = function (a) { 4631 a = this.normalize(a, !0), a !== d && (this.trigger("remove", { 4632 content: this._items[a], 4633 position: a 4634 }), this._items[a].remove(), this._items.splice(a, 1), this._mergers.splice(a, 1), this.invalidate("items"), this.trigger("removed", { 4635 content: null, 4636 position: a 4637 })) 4638 }, e.prototype.addTriggerableEvents = function () { 4639 var b = a.proxy(function (b, c) { 4640 return a.proxy(function (a) { 4641 a.relatedTarget !== this && (this.suppress([c]), b.apply(this, [].slice.call(arguments, 1)), this.release([c])) 4642 }, this) 4643 }, this); 4644 a.each({ 4645 next: this.next, 4646 prev: this.prev, 4647 to: this.to, 4648 destroy: this.destroy, 4649 refresh: this.refresh, 4650 replace: this.replace, 4651 add: this.add, 4652 remove: this.remove 4653 }, a.proxy(function (a, c) { 4654 this.$element.on(a + ".owl.carousel", b(c, a + ".owl.carousel")) 4655 }, this)) 4656 }, e.prototype.watchVisibility = function () { 4657 function c(a) { 4658 return a.offsetWidth > 0 && a.offsetHeight > 0 4659 } 4660 4661 function d() { 4662 c(this.$element.get(0)) && (this.$element.removeClass("owl-hidden"), this.refresh(), b.clearInterval(this.e._checkVisibile)) 4663 } 4664 c(this.$element.get(0)) || (this.$element.addClass("owl-hidden"), b.clearInterval(this.e._checkVisibile), this.e._checkVisibile = b.setInterval(a.proxy(d, this), 500)) 4665 }, e.prototype.preloadAutoWidthImages = function (b) { 4666 var c, d, e, f; 4667 c = 0, d = this, b.each(function (g, h) { 4668 e = a(h), f = new Image, f.onload = function () { 4669 c++ , e.attr("src", f.src), e.css("opacity", 1), c >= b.length && (d.state.imagesLoaded = !0, d.initialize()) 4670 }, f.src = e.attr("src") || e.attr("data-src") || e.attr("data-src-retina") 4671 }) 4672 }, e.prototype.destroy = function () { 4673 this.$element.hasClass(this.settings.themeClass) && this.$element.removeClass(this.settings.themeClass), this.settings.responsive !== !1 && a(b).off("resize.owl.carousel"), this.transitionEndVendor && this.off(this.$stage.get(0), this.transitionEndVendor, this.e._transitionEnd); 4674 for (var d in this._plugins) this._plugins[d].destroy(); 4675 (this.settings.mouseDrag || this.settings.touchDrag) && (this.$stage.off("mousedown touchstart touchcancel"), a(c).off(".owl.dragEvents"), this.$stage.get(0).onselectstart = function () { }, this.$stage.off("dragstart", function () { 4676 return !1 4677 })), this.$element.off(".owl"), this.$stage.children(".cloned").remove(), this.e = null, this.$element.removeData("owlCarousel"), this.$stage.children().contents().unwrap(), this.$stage.children().unwrap(), this.$stage.unwrap() 4678 }, e.prototype.op = function (a, b, c) { 4679 var d = this.settings.rtl; 4680 switch (b) { 4681 case "<": 4682 return d ? a > c : c > a; 4683 case ">": 4684 return d ? c > a : a > c; 4685 case ">=": 4686 return d ? c >= a : a >= c; 4687 case "<=": 4688 return d ? a >= c : c >= a 4689 } 4690 }, e.prototype.on = function (a, b, c, d) { 4691 a.addEventListener ? a.addEventListener(b, c, d) : a.attachEvent && a.attachEvent("on" + b, c) 4692 }, e.prototype.off = function (a, b, c, d) { 4693 a.removeEventListener ? a.removeEventListener(b, c, d) : a.detachEvent && a.detachEvent("on" + b, c) 4694 }, e.prototype.trigger = function (b, c, d) { 4695 var e = { 4696 item: { 4697 count: this._items.length, 4698 index: this.current() 4699 } 4700 }, 4701 f = a.camelCase(a.grep(["on", b, d], function (a) { 4702 return a 4703 }).join("-").toLowerCase()), 4704 g = a.Event([b, "owl", d || "carousel"].join(".").toLowerCase(), a.extend({ 4705 relatedTarget: this 4706 }, e, c)); 4707 return this._supress[b] || (a.each(this._plugins, function (a, b) { 4708 b.onTrigger && b.onTrigger(g) 4709 }), this.$element.trigger(g), this.settings && "function" == typeof this.settings[f] && this.settings[f].apply(this, g)), g 4710 }, e.prototype.suppress = function (b) { 4711 a.each(b, a.proxy(function (a, b) { 4712 this._supress[b] = !0 4713 }, this)) 4714 }, e.prototype.release = function (b) { 4715 a.each(b, a.proxy(function (a, b) { 4716 delete this._supress[b] 4717 }, this)) 4718 }, e.prototype.browserSupport = function () { 4719 if (this.support3d = j(), this.support3d) { 4720 this.transformVendor = i(); 4721 var a = ["transitionend", "webkitTransitionEnd", "transitionend", "oTransitionEnd"]; 4722 this.transitionEndVendor = a[h()], this.vendorName = this.transformVendor.replace(/Transform/i, ""), this.vendorName = "" !== this.vendorName ? "-" + this.vendorName.toLowerCase() + "-" : "" 4723 } 4724 this.state.orientation = b.orientation 4725 }, a.fn.owlCarousel = function (b) { 4726 return this.each(function () { 4727 a(this).data("owlCarousel") || a(this).data("owlCarousel", new e(this, b)) 4728 }) 4729 }, a.fn.owlCarousel.Constructor = e 4730}(window.Zepto || window.jQuery, window, document), 4731 function (a, b) { 4732 var c = function (b) { 4733 this._core = b, this._loaded = [], this._handlers = { 4734 "initialized.owl.carousel change.owl.carousel": a.proxy(function (b) { 4735 if (b.namespace && this._core.settings && this._core.settings.lazyLoad && (b.property && "position" == b.property.name || "initialized" == b.type)) 4736 for (var c = this._core.settings, d = c.center && Math.ceil(c.items / 2) || c.items, e = c.center && -1 * d || 0, f = (b.property && b.property.value || this._core.current()) + e, g = this._core.clones().length, h
vendor: 6,697 bytes, lines 4736-4847
4736= a.proxy(function (a, b) { 4737 this.load(b) 4738 }, this); e++ < d;) this.load(g / 2 + this._core.relative(f)), g && a.each(this._core.clones(this._core.relative(f++)), h) 4739 }, this) 4740 }, this._core.options = a.extend({}, c.Defaults, this._core.options), this._core.$element.on(this._handlers) 4741 }; 4742 c.Defaults = { 4743 lazyLoad: !1 4744 }, c.prototype.load = function (c) { 4745 var d = this._core.$stage.children().eq(c), 4746 e = d && d.find(".owl-lazy"); 4747 !e || a.inArray(d.get(0), this._loaded) > -1 || (e.each(a.proxy(function (c, d) { 4748 var e, f = a(d), 4749 g = b.devicePixelRatio > 1 && f.attr("data-src-retina") || f.attr("data-src"); 4750 this._core.trigger("load", { 4751 element: f, 4752 url: g 4753 }, "lazy"), f.is("img") ? f.one("load.owl.lazy", a.proxy(function () { 4754 f.css("opacity", 1), this._core.trigger("loaded", { 4755 element: f, 4756 url: g 4757 }, "lazy") 4758 }, this)).attr("src", g) : (e = new Image, e.onload = a.proxy(function () { 4759 f.css({ 4760 "background-image": "url(" + g + ")", 4761 opacity: "1" 4762 }), this._core.trigger("loaded", { 4763 element: f, 4764 url: g 4765 }, "lazy") 4766 }, this), e.src = g) 4767 }, this)), this._loaded.push(d.get(0))) 4768 }, c.prototype.destroy = function () { 4769 var a, b; 4770 for (a in this.handlers) this._core.$element.off(a, this.handlers[a]); 4771 for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null) 4772 }, a.fn.owlCarousel.Constructor.Plugins.Lazy = c 4773 }(window.Zepto || window.jQuery, window, document), 4774 function (a) { 4775 var b = function (c) { 4776 this._core = c, this._handlers = { 4777 "initialized.owl.carousel": a.proxy(function () { 4778 this._core.settings.autoHeight && this.update() 4779 }, this), 4780 "changed.owl.carousel": a.proxy(function (a) { 4781 this._core.settings.autoHeight && "position" == a.property.name && this.update() 4782 }, this), 4783 "loaded.owl.lazy": a.proxy(function (a) { 4784 this._core.settings.autoHeight && a.element.closest("." + this._core.settings.itemClass) === this._core.$stage.children().eq(this._core.current()) && this.update() 4785 }, this) 4786 }, this._core.options = a.extend({}, b.Defaults, this._core.options), this._core.$element.on(this._handlers) 4787 }; 4788 b.Defaults = { 4789 autoHeight: !1, 4790 autoHeightClass: "owl-height" 4791 }, b.prototype.update = function () { 4792 this._core.$stage.parent().height(this._core.$stage.children().eq(this._core.current()).height()).addClass(this._core.settings.autoHeightClass) 4793 }, b.prototype.destroy = function () { 4794 var a, b; 4795 for (a in this._handlers) this._core.$element.off(a, this._handlers[a]); 4796 for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null) 4797 }, a.fn.owlCarousel.Constructor.Plugins.AutoHeight = b 4798 }(window.Zepto || window.jQuery, window, document), 4799 function (a, b, c) { 4800 var d = function (b) { 4801 this._core = b, this._videos = {}, this._playing = null, this._fullscreen = !1, this._handlers = { 4802 "resize.owl.carousel": a.proxy(function (a) { 4803 this._core.settings.video && !this.isInFullScreen() && a.preventDefault() 4804 }, this), 4805 "refresh.owl.carousel changed.owl.carousel": a.proxy(function () { 4806 this._playing && this.stop() 4807 }, this), 4808 "prepared.owl.carousel": a.proxy(function (b) { 4809 var c = a(b.content).find(".owl-video"); 4810 c.length && (c.css("display", "none"), this.fetch(c, a(b.content))) 4811 }, this) 4812 }, this._core.options = a.extend({}, d.Defaults, this._core.options), this._core.$element.on(this._handlers), this._core.$element.on("click.owl.video", ".owl-video-play-icon", a.proxy(function (a) { 4813 this.play(a) 4814 }, this)) 4815 }; 4816 d.Defaults = { 4817 video: !1, 4818 videoHeight: !1, 4819 videoWidth: !1 4820 }, d.prototype.fetch = function (a, b) { 4821 var c = a.attr("data-vimeo-id") ? "vimeo" : "youtube", 4822 d = a.attr("data-vimeo-id") || a.attr("data-youtube-id"), 4823 e = a.attr("data-width") || this._core.settings.videoWidth, 4824 f = a.attr("data-height") || this._core.settings.videoHeight, 4825 g = a.attr("href"); 4826 if (!g) throw new Error("Missing video URL."); 4827 if (d = g.match(/(http:|https:|)\/\/(player.|www.)?(vimeo\.com|youtu(be\.com|\.be|be\.googleapis\.com))\/(video\/|embed\/|watch\?v=|v\/)?([A-Za-z0-9._%-]*)(\&\S+)?/), d[3].indexOf("youtu") > -1) c = "youtube"; 4828 else { 4829 if (!(d[3].indexOf("vimeo") > -1)) throw new Error("Video URL not supported."); 4830 c = "vimeo" 4831 } 4832 d = d[6], this._videos[g] = { 4833 type: c, 4834 id: d, 4835 width: e, 4836 height: f 4837 }, b.attr("data-video", g), this.thumbnail(a, this._videos[g]) 4838 }, d.prototype.thumbnail = function (b, c) { 4839 var d, e, f, g = c.width && c.height ? 'style="width:' + c.width + "px;height:" + c.height + 'px;"' : "", 4840 h = b.find("img"), 4841 i = "src", 4842 j = "", 4843 k = this._core.settings, 4844 l = function (a) { 4845 e = '<div class="owl-video-play-icon"></div>', d = k.lazyLoad ? '<div class="owl-video-tn ' + j + '" ' + i + '="' + a + '"></div>' : '<div class="owl-video-tn" style="opacity:1;background-image:url(' + a + ')"></div>', b.after(d), b.after(e) 4846 }; 4847 return b.wrap('<div class="owl-video-wrapper"' + g + "></div>"), this._core.settings.lazyLoad && (i = "data-src", j = "owl-lazy"), h.length ? (l(h.attr(i)), h.remove(), !1) : void ("youtube" === c.type ? (f = "http://img.youtube.com/vi/" + c.id + "/hqdefault.jpg", l(f)) : "vimeo" === c.type && a.aja
4847x({ 4848 type: "GET", 4849 url: "http://vimeo.com/api/v2/video/" + c.id + ".json", 4850 jsonp: "callback", 4851 dataType: "jsonp", 4852 success: function (a) { 4853 f = a[0].thumbnail_large, l(f) 4854 } 4855 })) 4856 }, d.prototype.stop = function () { 4857 this._core.trigger("stop", null, "video"), this._playing.find(".owl-video-frame").remove(), this._playing.removeClass("owl-video-playing"), this._playing = null 4858 }, d.prototype.play = function (b) { 4859 this._core.trigger("play", null, "video"), this._playing && this.stop(); 4860 var c, d, e = a(b.target || b.srcElement), 4861 f = e.closest("." + this._core.settings.itemClass), 4862 g = this._videos[f.attr("data-video")], 4863 h = g.width || "100%", 4864 i = g.height || this._core.$stage.height(); 4865 "youtube" === g.type ? c = '<iframe width="' + h + '" height="' + i + '" src="http://www.youtube.com/embed/' + g.id + "?autoplay=1&v=" + g.id + '" allowfullscreen></iframe>' : "vimeo" === g.type && (c = '<iframe src="http://player.vimeo.com/video/' + g.id + '?autoplay=1" width="' + h + '" height="' + i + '" allowfullscreen></iframe>'), f.addClass("owl-video-playing"), this._playing = f, d = a('<div style="height:' + i + "px; width:" + h + 'px" class="owl-video-frame">' + c + "</div>"), e.after(d) 4866 }, d.prototype.isInFullScreen = function () { 4867 var d = c.fullscreenElement || c.mozFullScreenElement || c.webkitFullscreenElement; 4868 return d && a(d).parent().hasClass("owl-video-frame") && (this._core.speed(0), this._fullscreen = !0), d && this._fullscreen && this._playing ? !1 : this._fullscreen ? (this._fullscreen = !1, !1) : this._playing && this._core.state.orientation !== b.orientation ? (this._core.state.orientation = b.orientation, !1) : !0 4869 }, d.prototype.destroy = function () { 4870 var a, b; 4871 this._core.$element.off("click.owl.video"); 4872 for (a in this._handlers) this._core.$element.off(a, this._handlers[a]); 4873 for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null) 4874 }, a.fn.owlCarousel.Constructor.Plugins.Video = d 4875 }(window.Zepto || window.jQuery, window, document), 4876 function (a, b, c, d) { 4877 var e = function (b) { 4878 this.core = b, this.core.options = a.extend({}, e.Defaults, this.core.options), this.swapping = !0, this.previous = d, this.next = d, this.handlers = { 4879 "change.owl.carousel": a.proxy(function (a) { 4880 "position" == a.property.name && (this.previous = this.core.current(), this.next = a.property.value) 4881 }, this), 4882 "drag.owl.carousel dragged.owl.carousel translated.owl.carousel": a.proxy(function (a) { 4883 this.swapping = "translated" == a.type 4884 }, this), 4885 "translate.owl.carousel": a.proxy(function () { 4886 this.swapping && (this.core.options.animateOut || this.core.options.animateIn) && this.swap() 4887 }, this) 4888 }, this.core.$element.on(this.handlers) 4889 }; 4890 e.Defaults = { 4891 animateOut: !1, 4892 animateIn: !1 4893 }, e.prototype.swap = function () { 4894 if (1 === this.core.settings.items && this.core.support3d) { 4895 this.core.speed(0); 4896 var b, c = a.proxy(this.clear, this), 4897 d = this.core.$stage.children().eq(this.previous), 4898 e = this.core.$stage.children().eq(this.next), 4899 f = this.core.settings.animateIn, 4900 g = this.core.settings.animateOut; 4901 this.core.current() !== this.previous && (g && (b = this.core.coordinates(this.previous) - this.core.coordinates(this.next), d.css({ 4902 left: b + "px" 4903 }).addClass("animated owl-animated-out").addClass(g).one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", c)), f && e.addClass("animated owl-animated-in").addClass(f).one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", c)) 4904 } 4905 }, e.prototype.clear = function (b) { 4906 a(b.target).css({ 4907 left: "" 4908 }).removeClass("animated owl-animated-out owl-animated-in").removeClass(this.core.settings.animateIn).removeClass(this.core.settings.animateOut), this.core.transitionEnd() 4909 }, e.prototype.destroy = function () { 4910 var a, b; 4911 for (a in this.handlers) this.core.$element.off(a, this.handlers[a]); 4912 for (b in Object.getOwnPropertyNames(this)) "function" != typeof this[b] && (this[b] = null) 4913 }, a.fn.owlCarousel.Constructor.Plugins.Animate = e 4914 }(window.Zepto || window.jQuery, window, document), 4915 function (a, b, c) { 4916 var d = function (b) { 4917 this.core = b, this.core.options = a.extend({}, d.Defaults, this.core.options), this.handlers = { 4918 "translated.owl.carousel refreshed.owl.carousel": a.proxy(function () { 4919 this.autoplay() 4920 }, this), 4921 "play.owl.autoplay": a.proxy(function (a, b, c) { 4922 this.play(b, c) 4923 }, this), 4924 "stop.owl.autoplay": a.proxy(function () { 4925 this.stop() 4926 }, this), 4927 "mouseover.owl.autoplay": a.proxy(function () { 4928 this.core.settings.autoplayHoverPause && this.pause() 4929 }, this), 4930 "mouseleave.owl.autoplay": a.proxy(function () { 4931 this.core.settings.autoplayHoverPause && this.autoplay() 4932 }, this) 4933 }, this.core.$element.on(this.handlers) 4934 }; 4935 d.Defaults = { 4936 autoplay: !1, 4937 autoplayTimeout: 5e3, 4938 autoplayHoverPause: !1, 4939 autoplaySpeed: !1 4940 }, d.prototype.autoplay = function () { 4941 this.core.settings.autoplay && !this.core.state.videoPlay ? (b.clearInterval(this.interval), this.interval = b.setInterval(a.proxy(function () { 4942 this.play() 4943 }, this), this.core.settings.autoplayTimeout)) : b.clearInterval(this.interval) 4944 }, d.prototype.play = function () { 4945 return c.hidden === !0 || this.core.state.isTouch || this.core.state.isScrolling || this.core.state.isSwiping || this.core.state.inMotion ? void 0 : this.core.settings.autoplay === !1 ? void b.clearInterval(this.interval) : void this.core.next(this.core.settings.autoplaySpeed) 4946 }, d.prototype.stop = function () { 4947 b.clearInterval(this.interval) 4948 }, d.prototype.pause = function () { 4949 b.clearInterval(this.interval) 4950 }, d.prototype.destroy = function () { 4951 var a, c; 4952 b.clearInterval(this.interval); 4953 for (a in this.handlers) this.core.$element.off(a, this.handlers[a]); 4954 for (c in Object.getOwnPropertyNames(this)) "function" != typeof this[c] && (this[c] = null) 4955 }, a.fn.owlCarousel.Constructor.Plugins.autoplay = d 4956 }(window.Zepto || window.jQuery, window, document), 4957 function (a) { 4958 "use strict"; 4959 var b = function (c) { 4960 this._core = c, this._initialized = !1, this._pages = [], this._controls = {}, this._templates = [], this.$element = this._core.$element, this._overrides = { 4961 next: this._core.next, 4962 prev: this._core.prev, 4963 to: this._core.to 4964 }, this._handlers = { 4965 "prepared.owl.carousel": a.proxy(function (b) { 4966 this._core.settings.dotsData && this._templates.push(a(b.content).find("[data-dot]").andSelf("[data-dot]").attr("data-dot")) 4967 }, this), 4968 "add.owl.carousel": a.proxy(function (b) { 4969 this._core.settings.dotsData && this._templates.splice(b.position, 0, a(b.content).find("[data-dot]").andSelf("[data-dot]").attr("data-dot")) 4970 }, this), 4971 "remove.owl.carousel prepared.owl.carousel": a.proxy(function (a) { 4972 this._core.settings.dotsData && this._templates.splice(a.position, 1) 4973 }, this), 4974 "change.owl.carousel": a.proxy(function (a) { 4975 if ("position" == a.property.name && !this._core.state.revert && !this._core.settings.loop && this._core.settings.navRewind) { 4976 var b = this._core.current(), 4977 c = this._core.maximum(), 4978 d = this._core.minimum(); 4979 a.data = a.property.value > c ? b >= c ? d : c : a.property.value < d ? c : a.property.value 4980 } 4981 }, this), 4982 "changed.owl.carousel": a.proxy(function (a) { 4983 "position" == a.property.name && this.draw() 4984 }, this), 4985 "refreshed.owl.carousel": a.proxy(function () { 4986 this._initialized || (this.initialize(), this._initialized = !0), this._core.trigger("refresh", null, "navigation"), this.update(), this.draw(), this._core.trigger("refreshed", null, "navigation") 4987 }, this) 4988 }, this._core.options = a.extend({}, b.Defaults, this._core.options), this.$element.on(this._handlers) 4989 }; 4990 b.Defaults = { 4991 nav: !1, 4992 navRewind: !0, 4993 navText: ["<i class='fa fa-chevron-left'></i>", "<i class='fa fa-chevron-right'></i>"],//Next,Prev Icons 4994 navSpeed: !1, 4995 navElement: "div", 4996 navContainer: !1, 4997 navContainerClass: "owl-nav", 4998 navClass: ["owl-prev", "owl-next"], 4999 slideBy: 1, 5000 dotClass: "owl-dot", 5001 dotsClass: "owl-dots", 5002 dots: !0, 5003 dotsEach: !1, 5004 dotData: !1, 5005 dotsSpeed: !1, 5006 dotsContainer: !1,
5007 controlsClass: "owl-controls" 5008 }, b.prototype.initialize = function () { 5009 var b, c, d = this._core.settings; 5010 d.dotsData || (this._templates = [a("<div>").addClass(d.dotClass).append(a("<span>")).prop("outerHTML")]), d.navContainer && d.dotsContainer || (this._controls.$container = a("<div>").addClass(d.controlsClass).appendTo(this.$element)), this._controls.$indicators = d.dotsContainer ? a(d.dotsContainer) : a("<div>").hide().addClass(d.dotsClass).appendTo(this._controls.$container), this._controls.$indicators.on("click", "div", a.proxy(function (b) { 5011 var c = a(b.target).parent().is(this._controls.$indicators) ? a(b.target).index() : a(b.target).parent().index(); 5012 b.preventDefault(), this.to(c, d.dotsSpeed) 5013 }, this)), b = d.navContainer ? a(d.navContainer) : a("<div>").addClass(d.navContainerClass).prependTo(this._controls.$container), this._controls.$next = a("<" + d.navElement + ">"), this._controls.$previous = this._controls.$next.clone(), this._controls.$previous.addClass(d.navClass[0]).html(d.navText[0]).hide().prependTo(b).on("click", a.proxy(function () { 5014 this.prev(d.navSpeed) 5015 }, this)), this._controls.$next.addClass(d.navClass[1]).html(d.navText[1]).hide().appendTo(b).on("click", a.proxy(function () { 5016 this.next(d.navSpeed) 5017 }, this)); 5018 for (c in this._overrides) this._core[c] = a.proxy(this[c], this) 5019 }, b.prototype.destroy = function () { 5020 var a, b, c, d; 5021 for (a in this._handlers) this.$element.off(a, this._handlers[a]); 5022 for (b in this._controls) this._controls[b].remove(); 5023 for (d in this.overides) this._core[d] = this._overrides[d]; 5024 for (c in Object.getOwnPropertyNames(this)) "function" != typeof this[c] && (this[c] = null) 5025 }, b.prototype.update = function () { 5026 var a, b, c, d = this._core.settings, 5027 e = this._core.clones().length / 2, 5028 f = e + this._core.items().length, 5029 g = d.center || d.autoWidth || d.dotData ? 1 : d.dotsEach || d.items; 5030 if ("page" !== d.slideBy && (d.slideBy = Math.min(d.slideBy, d.items)), d.dots || "page" == d.slideBy) 5031 for (this._pages = [], a = e, b = 0, c = 0; f > a; a++)(b >= g || 0 === b) && (this._pages.push({ 5032 start: a - e, 5033 end: a - e + g - 1 5034 }), b = 0, ++c), b += this._core.mergers(this._core.relative(a)) 5035 }, b.prototype.draw = function () { 5036 var b, c, d = "", 5037 e = this._core.settings, 5038 f = (this._core.$stage.children(), this._core.relative(this._core.current())); 5039 if (!e.nav || e.loop || e.navRewind || (this._controls.$previous.toggleClass("disabled", 0 >= f), this._controls.$next.toggleClass("disabled", f >= this._core.maximum())), this._controls.$previous.toggle(e.nav), this._controls.$next.toggle(e.nav), e.dots) { 5040 if (b = this._pages.length - this._controls.$indicators.children().length, e.dotData && 0 !== b) { 5041 for (c = 0; c < this._controls.$indicators.children().length; c++) d += this._templates[this._core.relative(c)]; 5042 this._controls.$indicators.html(d) 5043 } else b > 0 ? (d = new Array(b + 1).join(this._templates[0]), this._controls.$indicators.append(d)) : 0 > b && this._controls.$indicators.children().slice(b).remove(); 5044 this._controls.$indicators.find(".active").removeClass("active"), this._controls.$indicators.children().eq(a.inArray(this.current(), this._pages)).addClass("active") 5045 } 5046 this._controls.$indicators.toggle(e.dots) 5047 }, b.prototype.onTrigger = function (b) { 5048 var c = this._core.settings; 5049 b.page = { 5050 index: a.inArray(this.current(), this._pages), 5051 count: this._pages.length, 5052 size: c && (c.center || c.autoWidth || c.dotData ? 1 : c.dotsEach || c.items) 5053 } 5054 }, b.prototype.current = function () { 5055 var b = this._core.relative(this._core.current()); 5056 return a.grep(this._pages, function (a) { 5057 return a.start <= b && a.end >= b 5058 }).pop() 5059 }, b.prototype.getPosition = function (b) { 5060 var c, d, e = this._core.settings; 5061 return "page" == e.slideBy ? (c = a.inArray(this.current(), this._pages), d = this._pages.length, b ? ++c : --c, c = this._pages[(c % d + d) % d].start) : (c = this._core.relative(this._core.current()), d = this._core.items().length, b ? c += e.
5061slideBy : c -= e.slideBy), c 5062 }, b.prototype.next = function (b) { 5063 a.proxy(this._overrides.to, this._core)(this.getPosition(!0), b) 5064 }, b.prototype.prev = function (b) { 5065 a.proxy(this._overrides.to, this._core)(this.getPosition(!1), b) 5066 }, b.prototype.to = function (b, c, d) { 5067 var e; 5068 d ? a.proxy(this._overrides.to, this._core)(b, c) : (e = this._pages.length, a.proxy(this._overrides.to, this._core)(this._pages[(b % e + e) % e].start, c)) 5069 }, a.fn.owlCarousel.Constructor.Plugins.Navigation = b 5070 }(window.Zepto || window.jQuery, window, document), 5071 function (a, b) { 5072 "use strict"; 5073 var c = function (d) { 5074 this._core = d, this._hashes = {}, this.$element = this._core.$element, this._handlers = { 5075 "initialized.owl.carousel": a.proxy(function () { 5076 "URLHash" == this._core.settings.startPosition && a(b).trigger("hashchange.owl.navigation") 5077 }, this), 5078 "prepared.owl.carousel": a.proxy(function (b) { 5079 var c = a(b.content).find("[data-hash]").andSelf("[data-hash]").attr("data-hash"); 5080 this._hashes[c] = b.content 5081 }, this) 5082 }, this._core.options = a.extend({}, c.Defaults, this._core.options), this.$element.on(this._handlers), a(b).on("hashchange.owl.navigation", a.proxy(function () { 5083 var a = b.location.hash.substring(1), 5084 c = this._core.$stage.children(), 5085 d = this._hashes[a] && c.index(this._hashes[a]) || 0; 5086 return a ? void this._core.to(d, !1, !0) : !1 5087 }, this)) 5088 }; 5089 c.Defaults = { 5090 URLhashListener: !1 5091 }, c.prototype.destroy = function () { 5092 var c, d; 5093 a(b).off("hashchange.owl.navigation"); 5094 for (c in this._handlers) this._core.$element.off(c, this._handlers[c]); 5095 for (d in Object.getOwnPropertyNames(this)) "function" != typeof this[d] && (this[d] = null) 5096 }, a.fn.owlCarousel.Constructor.Plugins.Hash = c 5097 }(window.Zepto || window.jQuery, window, document); 5098 5099/* 5100 * FlexSlider 5101 * ----------------------------------------------- 5102 */ 5103/* 5104 * jQuery FlexSlider v2.6.0 5105 * Copyright 2012 WooThemes 5106 * Contributing Author: Tyler Smith 5107 */ 5108! function ($) { 5109 var e = !0; 5110 $.flexslider = function (t, a) { 5111 var n = $(t); 5112 n.vars = $.extend({}, $.flexslider.defaults, a); 5113 var i = n.vars.namespace, 5114 s = window.navigator && window.navigator.msPointerEnabled && window.MSGesture, 5115 r = ("ontouchstart" in window || s || window.DocumentTouch && document instanceof DocumentTouch) && n.vars.touch, 5116 o = "click touchend MSPointerUp keyup", 5117 l = "", 5118 c, d = "vertical" === n.vars.direction, 5119 u = n.vars.reverse, 5120 v = n.vars.itemWidth > 0, 5121 p = "fade" === n.vars.animation, 5122 m = "" !== n.vars.asNavFor, 5123 f = {}; 5124 $.data(t, "flexslider", n), f = { 5125 init: function () { 5126 n.animating = !1, n.currentSlide = parseInt(n.vars.startAt ? n.vars.startAt : 0, 10), isNaN(n.currentSlide) && (n.currentSlide = 0), n.animatingTo = n.currentSlide, n.atEnd = 0 === n.currentSlide || n.currentSlide === n.last, n.containerSelector = n.vars.selector.substr(0, n.vars.selector.search(" ")), n.slides = $(n.vars.selector, n), n.container = $(n.containerSelector, n), n.count = n.slides.length, n.syncExists = $(n.vars.sync).length > 0, "slide" === n.vars.animation && (n.vars.animation = "swing"), n.prop = d ? "top" : "marginLeft", n.args = {}, n.manualPause = !1, n.stopped = !1, n.started = !1, n.startTimeout = null, n.transitions = !n.vars.video && !p && n.vars.useCSS && function () { 5127 var e = document.createElement("div"), 5128 t = ["perspectiveProperty", "WebkitPerspective", "MozPerspective", "OPerspective", "msPerspective"]; 5129 for (var a in t) 5130 if (void 0 !== e.style[t[a]]) return n.pfx = t[a].replace("Perspective", "").toLowerCase(), n.prop = "-" + n.pfx + "-transform", !0; 5131 return !1 5132 }(), n.ensureAnimationEnd = "", "" !== n.vars.controlsContainer && (n.controlsContainer = $(n.vars.c
vendor: 31,979 bytes, lines 5132-5578
5132ontrolsContainer).length > 0 && $(n.vars.controlsContainer)), "" !== n.vars.manualControls && (n.manualControls = $(n.vars.manualControls).length > 0 && $(n.vars.manualControls)), "" !== n.vars.customDirectionNav && (n.customDirectionNav = 2 === $(n.vars.customDirectionNav).length && $(n.vars.customDirectionNav)), n.vars.randomize && (n.slides.sort(function () { 5133 return Math.round(Math.random()) - .5 5134 }), n.container.empty().append(n.slides)), n.doMath(), n.setup("init"), n.vars.controlNav && f.controlNav.setup(), n.vars.directionNav && f.directionNav.setup(), n.vars.keyboard && (1 === $(n.containerSelector).length || n.vars.multipleKeyboard) && $(document).bind("keyup", function (e) { 5135 var t = e.keyCode; 5136 if (!n.animating && (39 === t || 37 === t)) { 5137 var a = 39 === t ? n.getTarget("next") : 37 === t ? n.getTarget("prev") : !1; 5138 n.flexAnimate(a, n.vars.pauseOnAction) 5139 } 5140 }), n.vars.mousewheel && n.bind("mousewheel", function (e, t, a, i) { 5141 e.preventDefault(); 5142 var s = 0 > t ? n.getTarget("next") : n.getTarget("prev"); 5143 n.flexAnimate(s, n.vars.pauseOnAction) 5144 }), n.vars.pausePlay && f.pausePlay.setup(), n.vars.slideshow && n.vars.pauseInvisible && f.pauseInvisible.init(), n.vars.slideshow && (n.vars.pauseOnHover && n.hover(function () { 5145 n.manualPlay || n.manualPause || n.pause() 5146 }, function () { 5147 n.manualPause || n.manualPlay || n.stopped || n.play() 5148 }), n.vars.pauseInvisible && f.pauseInvisible.isHidden() || (n.vars.initDelay > 0 ? n.startTimeout = setTimeout(n.play, n.vars.initDelay) : n.play())), m && f.asNav.setup(), r && n.vars.touch && f.touch(), (!p || p && n.vars.smoothHeight) && $(window).bind("resize orientationchange focus", f.resize), n.find("img").attr("draggable", "false"), setTimeout(function () { 5149 n.vars.start(n) 5150 }, 200) 5151 }, 5152 asNav: { 5153 setup: function () { 5154 n.asNav = !0, n.animatingTo = Math.floor(n.currentSlide / n.move), n.currentItem = n.currentSlide, n.slides.removeClass(i + "active-slide").eq(n.currentItem).addClass(i + "active-slide"), s ? (t._slider = n, n.slides.each(function () { 5155 var e = this; 5156 e._gesture = new MSGesture, e._gesture.target = e, e.addEventListener("MSPointerDown", function (e) { 5157 e.preventDefault(), e.currentTarget._gesture && e.currentTarget._gesture.addPointer(e.pointerId) 5158 }, !1), e.addEventListener("MSGestureTap", function (e) { 5159 e.preventDefault(); 5160 var t = $(this), 5161 a = t.index(); 5162 $(n.vars.asNavFor).data("flexslider").animating || t.hasClass("active") || (n.direction = n.currentItem < a ? "next" : "prev", n.flexAnimate(a, n.vars.pauseOnAction, !1, !0, !0)) 5163 }) 5164 })) : n.slides.on(o, function (e) { 5165 e.preventDefault(); 5166 var t = $(this), 5167 a = t.index(), 5168 s = t.offset().left - $(n).scrollLeft(); 5169 0 >= s && t.hasClass(i + "active-slide") ? n.flexAnimate(n.getTarget("prev"), !0) : $(n.vars.asNavFor).data("flexslider").animating || t.hasClass(i + "active-slide") || (n.direction = n.currentItem < a ? "next" : "prev", n.flexAnimate(a, n.vars.pauseOnAction, !1, !0, !0)) 5170 }) 5171 } 5172 }, 5173 controlNav: { 5174 setup: function () { 5175 n.manualControls ? f.controlNav.setupManual() : f.controlNav.setupPaging() 5176 }, 5177 setupPaging: function () { 5178 var e = "thumbnails" === n.vars.controlNav ? "control-thumbs" : "control-paging", 5179 t = 1, 5180 a, s; 5181 if (n.controlNavScaffold = $('<ol class="' + i + "control-nav " + i + e + '"></ol>'), n.pagingCount > 1) 5182 for (var r = 0; r < n.pagingCount; r++) { 5183 if (s = n.slides.eq(r), void 0 === s.attr("data-thumb-alt") && s.attr("data-thumb-alt", ""), altText = "" !== s.attr("data-thumb-alt") ? altText = ' alt="' + s.attr("data-thumb-alt") + '"' : "", a = "thumbnails" === n.vars.controlNav ? '<img src="' + s.attr("data-thumb") + '"' + altText + "/>" : '<a href="#">' + t + "</a>", "thumbnails" === n.vars.controlNav && !0 === n.vars.thumbCaptions) { 5184 var c = s.attr("data-thumbcaption"); 5185 "" !== c && void 0 !== c && (a += '<span class="' + i + 'caption">' + c + "</span>") 5186 } 5187 n.controlNavScaffold.append("<li>" + a + "</li>"), t++ 5188 } 5189 n.controlsContainer ? $(n.controlsContainer).append(n.controlNavScaffold) : n.append(n.controlNavScaffold), f.controlNav.set(), f.controlNav.active(), n.controlNavScaffold.delegate("a, img", o, function (e) { 5190 if (e.preventDefault(), "" === l || l === e.type) { 5191 var t = $(this), 5192 a = n.controlNav.index(t); 5193 t.hasClass(i + "active") || (n.direction = a > n.currentSlide ? "next" : "prev", n.flexAnimate(a, n.vars.pauseOnAction)) 5194 } 5195 "" === l && (l = e.type), f.setToClearWatchedEvent() 5196 }) 5197 }, 5198 setupManual: function () { 5199 n.controlNav = n.manualControls, f.controlNav.active(), n.controlNav.bind(o, function (e) { 5200 if (e.preventDefault(), "" === l || l === e.type) { 5201 var t = $(this), 5202 a = n.controlNav.index(t); 5203 t.hasClass(i + "active") || (a > n.currentSlide ? n.direction = "next" : n.direction = "prev", n.flexAnimate(a, n.vars.pauseOnAction)) 5204 } 5205 "" === l && (l = e.type), f.setToClearWatchedEvent() 5206 }) 5207 }, 5208 set: function () { 5209 var e = "thumbnails" === n.vars.controlNav ? "img" : "a"; 5210 n.controlNav = $("." + i + "control-nav li " + e, n.controlsContainer ? n.controlsContainer : n) 5211 }, 5212 active: function () { 5213 n.controlNav.removeClass(i + "active").eq(n.animatingTo).addClass(i + "active") 5214 }, 5215 update: function (e, t) { 5216 n.pagingCount > 1 && "add" === e ? n.controlNavScaffold.append($('<li><a href="#">' + n.count + "</a></li>")) : 1 === n.pagingCount ? n.controlNavScaffold.find("li").remove() : n.controlNav.eq(t).closest("li").remove(), f.controlNav.set(), n.pagingCount > 1 && n.pagingCount !== n.controlNav.length ? n.update(t, e) : f.controlNav.active() 5217 } 5218 }, 5219 directionNav: { 5220 setup: function () { 5221 var e = $('<ul class="' + i + 'direction-nav"><li class="' + i + 'nav-prev"><a class="' + i + 'prev" href="#">' + n.vars.prevText + '</a></li><li class="' + i + 'nav-next"><a class="' + i + 'next" href="#">' + n.vars.nextText + "</a></li></ul>"); 5222 n.customDirectionNav ? n.directionNav = n.customDirectionNav : n.controlsContainer ? ($(n.controlsContainer).append(e), n.directionNav = $("." + i + "direction-nav li a", n.controlsContainer)) : (n.append(e), n.directionNav = $("." + i + "direction-nav li a", n)), f.directionNav.update(), n.directionNav.bind(o, function (e) { 5223 e.preventDefault(); 5224 var t; 5225 ("" === l || l === e.type) && (t = $(this).hasClass(i + "next") ? n.getTarget("next") : n.getTarget("prev"), n.flexAnimate(t, n.vars.pauseOnAction)), "" === l && (l = e.type), f.setToClearWatchedEvent() 5226 }) 5227 }, 5228 update: function () { 5229 var e = i + "disabled"; 5230 1 === n.pagingCount ? n.directionNav.addClass(e).attr("tabindex", "-1") : n.vars.animationLoop ? n.directionNav.removeClass(e).removeAttr("tabindex") : 0 === n.animatingTo ? n.directionNav.removeClass(e).filter("." + i + "prev").addClass(e).attr("tabindex", "-1") : n.animatingTo === n.last ? n.directionNav.removeClass(e).filter("." + i + "next").addClass(e).attr("tabindex", "-1") : n.directionNav.removeClass(e).removeAttr("tabindex") 5231 } 5232 }, 5233 pausePlay: { 5234 setup: function () { 5235 var e = $('<div class="' + i + 'pauseplay"><a href="#"></a></div>'); 5236 n.controlsContainer ? (n.controlsContainer.append(e), n.pausePlay = $("." + i + "pauseplay a", n.controlsContainer)) : (n.append(e), n.pausePlay = $("." + i + "pauseplay a", n)), f.pausePlay.update(n.vars.slideshow ? i + "pause" : i + "play"), n.pausePlay.bind(o, function (e) { 5237 e.preventDefault(), ("" === l || l === e.type) && ($(this).hasClass(i + "pause") ? (n.manualPause = !0, n.manualPlay = !1, n.pause()) : (n.manualPause = !1, n.manualPlay = !0, n.play())), "" === l && (l = e.type), f.setToClearWatchedEvent() 5238 }) 5239 }, 5240 update: function (e) { 5241 "play" === e ? n.pausePlay.removeClass(i + "pause").addClass(i + "play").html(n.vars.playText) : n.pausePlay.removeClass(i + "play").addClass(i + "pause").html(n.vars.pauseText) 5242 } 5243 }, 5244 touch: function () { 5245 function e(e) { 5246 e.stopPropagation(), n.animating ? e.preventDefault() : (n.pause(), t._gesture.addPointer(e.pointerId), T = 0, c = d ? n.h : n.w, f = Number(new Date), l = v && u && n.animatingTo === n.last ? 0 : v && u ? n.limit - (n.itemW + n.vars.itemMargin) * n.move * n.animatingTo : v && n.currentSlide === n.last ? n.limit : v ? (n.itemW + n.vars.itemMargin) * n.move * n.currentSlide : u ? (n.last - n.currentSlide + n.cloneOffset) * c : (n.currentSlide + n.cloneOffset) * c) 5247 } 5248 5249 function a(e) { 5250 e.stopPropagation(); 5251 var a = e.target._slider; 5252 if (a) { 5253 var n = -e.translationX, 5254 i = -e.translationY; 5255 return T += d ? i : n, m = T, x = d ? Math.abs(T) < Math.abs(-n) : Math.abs(T) < Math.abs(-i), e.detail === e.MSGESTURE_FLAG_INERTIA ? void setImmediate(function () { 5256 t._gesture.stop() 5257 }) : void ((!x || Number(new Date) - f > 500) && (e.preventDefault(), !p && a.transitions && (a.vars.animationLoop || (m = T / (0 === a.currentSlide && 0 > T || a.currentSlide === a.last && T > 0 ? Math.abs(T) / c + 2 : 1)), a.setProps(l + m, "setTouch")))) 5258 } 5259 } 5260 5261 function i(e) { 5262 e.stopPropagation(); 5263 var t = e.target._slider; 5264 if (t) { 5265 if (t.animatingTo === t.currentSlide && !x && null !== m) { 5266 var a = u ? -m : m, 5267 n = a > 0 ? t.getTarget("next") : t.getTarget("prev"); 5268 t.canAdvance(n) && (Number(new Date) - f < 550 && Math.abs(a) > 50 || Math.abs(a) > c / 2) ? t.flexAnimate(n, t.vars.pauseOnAction) : p || t.flexAnimate(t.currentSlide, t.vars.pauseOnAction, !0) 5269 } 5270 r = null, o = null, m = null, l = null, T = 0 5271 } 5272 } 5273 var r, o, l, c, m, f, g, h, S, x = !1, 5274 y = 0, 5275 b = 0, 5276 T = 0; 5277 s ? (t.style.msTouchAction = "none", t._gesture = new MSGesture, t._gesture.target = t, t.addEventListener("MSPointerDown", e, !1), t._slider = n, t.addEventListener("MSGestureChange", a, !1), t.addEventListener("MSGestureEnd", i, !1)) : (g = function (e) { 5278 n.animating ? e.preventDefault() : (window.navigator.msPointerEnabled || 1 === e.touches.length) && (n.pause(), c = d ? n.h : n.w, f = Number(new Date), y = e.touches[0].pageX, b = e.touches[0].pageY, l = v && u && n.animatingTo === n.last ? 0 : v && u ? n.limit - (n.itemW + n.vars.itemMargin) * n.move * n.animatingTo : v && n.currentSlide === n.last ? n.limit : v ? (n.itemW + n.vars.itemMargin) * n.move * n.currentSlide : u ? (n.last - n.currentSlide + n.cloneOffset) * c : (n.currentSlide + n.cloneOffset) * c, r = d ? b : y, o = d ? y : b, t.addEventListener("touchmove", h, !1), t.addEventListener("touchend", S, !1)) 5279 }, h = function (e) { 5280 y = e.touches[0].pageX, b = e.touches[0].pageY, m = d ? r - b : r - y, x = d ? Math.abs(m) < Math.abs(y - o) : Math.abs(m) < Math.abs(b - o); 5281 var t = 500; 5282 (!x || Number(new Date) - f > t) && (e.preventDefault(), !p && n.transitions && (n.vars.animationLoop || (m /= 0 === n.currentSlide && 0 > m || n.currentSlide === n.last && m > 0 ? Math.abs(m) / c + 2 : 1), n.setProps(l + m, "setTouch"))) 5283 }, S = function (e) { 5284 if (t.removeEventListener("touchmove", h, !1), n.animatingTo === n.currentSlide && !x && null !== m) { 5285 var a = u ? -m : m, 5286 i = a > 0 ? n.getTarget("next") : n.getTarget("prev"); 5287 n.canAdvance(i) && (Number(new Date) - f < 550 && Math.abs(a) > 50 || Math.abs(a) > c / 2) ? n.flexAnimate(i, n.vars.pauseOnAction) : p || n.flexAnimate(n.currentSlide, n.vars.pauseOnAction, !0) 5288 } 5289 t.removeEventListener("touchend", S, !1), r = null, o = null, m = null, l = null 5290 }, t.addEventListener("touchstart", g, !1)) 5291 }, 5292 resize: function () { 5293 !n.animating && n.is(":visible") && (v || n.doMath(), p ? f.smoothHeight() : v ? (n.slides.width(n.computedW), n.update(n.pagingCount), n.setProps()) : d ? (n.viewport.height(n.h), n.setProps(n.h, "setTotal")) : (n.vars.smoothHeight && f.smoothHeight(), n.newSlides.width(n.computedW), n.setProps(n.computedW, "setTotal"))) 5294 }, 5295 smoothHeight: function (e) { 5296 if (!d || p) { 5297 var t = p ? n : n.viewport; 5298 e ? t.animate({ 5299 height: n.slides.eq(n.animatingTo).height() 5300 }, e) : t.height(n.slides.eq(n.animatingTo).height()) 5301 } 5302 }, 5303 sync: function (e) { 5304 var t = $(n.vars.sync).data("flexslider"), 5305 a = n.animatingTo; 5306 switch (e) { 5307 case "animate": 5308 t.flexAnimate(a, n.vars.pauseOnAction, !1, !0); 5309 break; 5310 case "play": 5311 t.playing || t.asNav || t.play(); 5312 break; 5313 case "pause": 5314 t.pause() 5315 } 5316 }, 5317 uniqueID: function (e) { 5318 return e.filter("[id]").add(e.find("[id]")).each(function () { 5319 var e = $(this); 5320 e.attr("id", e.attr("id") + "_clone") 5321 }), e 5322 }, 5323 pauseInvisible: { 5324 visProp: null, 5325 init: function () { 5326 var e = f.pauseInvisible.getHiddenProp(); 5327 if (e) { 5328 var t = e.replace(/[H|h]idden/, "") + "visibilitychange"; 5329 document.addEventListener(t, function () { 5330 f.pauseInvisible.isHidden() ? n.startTimeout ? clearTimeout(n.startTimeout) : n.pause() : n.started ? n.play() : n.vars.initDelay > 0 ? setTimeout(n.play, n.vars.initDelay) : n.play() 5331 }) 5332 } 5333 }, 5334 isHidden: function () { 5335 var e = f.pauseInvisible.getHiddenProp(); 5336 return e ? document[e] : !1 5337 }, 5338 getHiddenProp: function () { 5339 var e = ["webkit", "moz", "ms", "o"]; 5340 if ("hidden" in document) return "hidden"; 5341 for (var t = 0; t < e.length; t++) 5342 if (e[t] + "Hidden" in document) return e[t] + "Hidden"; 5343 return null 5344 } 5345 }, 5346 setToClearWatchedEvent: function () { 5347 clearTimeout(c), c = setTimeout(function () { 5348 l = "" 5349 }, 3e3) 5350 } 5351 }, n.flexAnimate = function (e, t, a, s, o) { 5352 if (n.vars.animationLoop || e === n.currentSlide || (n.direction = e > n.currentSlide ? "next" : "prev"), m && 1 === n.pagingCount && (n.direction = n.currentItem < e ? "next" : "prev"), !n.animating && (n.canAdvance(e, o) || a) && n.is(":visible")) { 5353 if (m && s) { 5354 var l = $(n.vars.asNavFor).data("flexslider"); 5355 if (n.atEnd = 0 === e || e === n.count - 1, l.flexAnimate(e, !0, !1, !0, o), n.direction = n.currentItem < e ? "next" : "prev", l.direction = n.direction, Math.ceil((e + 1) / n.visible) - 1 === n.currentSlide || 0 === e) return n.currentItem = e, n.slides.removeClass(i + "active-slide").eq(e).addClass(i + "active-slide"), !1; 5356 n.currentItem = e, n.slides.removeClass(i + "active-slide").eq(e).addClass(i + "active-slide"), e = Math.floor(e / n.visible) 5357 } 5358 if (n.animating = !0, n.animatingTo = e, t && n.pause(), n.vars.before(n), n.syncExists && !o && f.sync("animate"), n.vars.controlNav && f.controlNav.active(), v || n.slides.removeClass(i + "active-slide").eq(e).addClass(i + "active-slide"), n.atEnd = 0 === e || e === n.last, n.vars.directionNav && f.directionNav.update(), e === n.last && (n.vars.end(n), n.vars.animationLoop || n.pause()), p) r ? (n.slides.eq(n.currentSlide).css({ 5359 opacity: 0, 5360 zIndex: 1 5361 }), n.slides.eq(e).css({ 5362 opacity: 1, 5363 zIndex: 2 5364 }), n.wrapup(c)) : (n.slides.eq(n.currentSlide).css({ 5365 zIndex: 1 5366 }).animate({ 5367 opacity: 0 5368 }, n.vars.animationSpeed, n.vars.easing), n.slides.eq(e).css({ 5369 zIndex: 2 5370 }).animate({ 5371 opacity: 1 5372 }, n.vars.animationSpeed, n.vars.easing, n.wrapup)); 5373 else { 5374 var c = d ? n.slides.filter(":first").height() : n.computedW, 5375 g, h, S; 5376 v ? (g = n.vars.itemMargin, S = (n.itemW + g) * n.move * n.animatingTo, h = S > n.limit && 1 !== n.visible ? n.limit : S) : h = 0 === n.currentSlide && e === n.count - 1 && n.vars.animationLoop && "next" !== n.direction ? u ? (n.count + n.cloneOffset) * c : 0 : n.currentSlide === n.last && 0 === e && n.vars.animationLoop && "prev" !== n.direction ? u ? 0 : (n.count + 1) * c : u ? (n.count - 1 - e + n.cloneOffset) * c : (e + n.cloneOffset) * c, n.setProps(h, "", n.vars.animationSpeed), n.transitions ? (n.vars.animationLoop && n.atEnd || (n.animating = !1, n.currentSlide = n.animatingTo), n.container.unbind("webkitTransitionEnd transitionend"), n.container.bind("webkitTransitionEnd transitionend", function () { 5377 clearTimeout(n.ensureAnimationEnd), n.wrapup(c) 5378 }), clearTimeout(n.ensureAnimationEnd), n.ensureAnimationEnd = setTimeout(function () { 5379 n.wrapup(c) 5380 }, n.vars.animationSpeed + 100)) : n.container.animate(n.args, n.vars.animationSpeed, n.vars.easing, function () { 5381 n.wrapup(c) 5382 }) 5383 } 5384 n.vars.smoothHeight && f.smoothHeight(n.vars.animationSpeed) 5385 } 5386 }, n.wrapup = function (e) { 5387 p || v || (0 === n.currentSlide && n.animatingTo === n.last && n.vars.animationLoop ? n.setProps(e, "jumpEnd") : n.currentSlide === n.last && 0 === n.animatingTo && n.vars.animationLoop && n.setProps(e, "jumpStart")), n.animating = !1, n.currentSlide = n.animatingTo, n.vars.after(n) 5388 }, n.animateSlides = function () { 5389 !n.animating && e && n.flexAnimate(n.getTarget("next")) 5390 }, n.pause = function () { 5391 clearInterval(n.animatedSlides), n.animatedSlides = null, n.playing = !1, n.vars.pausePlay && f.pausePlay.update("play"), n.syncExists && f.sync("pause") 5392 }, n.play = function () { 5393 n.playing && clearInterval(n.animatedSlides), n.animatedSlides = n.animatedSlides || setInterval(n.animateSlides, n.vars.slideshowSpeed), n.started = n.playing = !0, n.vars.pausePlay && f.pausePlay.update("pause"), n.syncExists && f.sync("play") 5394 }, n.stop = function () { 5395 n.pause(), n.stopped = !0 5396 }, n.canAdvance = function (e, t) { 5397 var a = m ? n.pagingCount - 1 : n.last; 5398 return t ? !0 : m && n.currentItem === n.count - 1 && 0 === e && "prev" === n.direction ? !0 : m && 0 === n.currentItem && e === n.pagingCount - 1 && "next" !== n.direction ? !1 : e !== n.currentSlide || m ? n.vars.animationLoop ? !0 : n.atEnd && 0 === n.currentSlide && e === a && "next" !== n.direction ? !1 : n.atEnd && n.currentSlide === a && 0 === e && "next" === n.direction ? !1 : !0 : !1 5399 }, n.getTarget = function (e) { 5400 return n.direction = e, "next" === e ? n.currentSlide === n.last ? 0 : n.currentSlide + 1 : 0 === n.currentSlide ? n.last : n.currentSlide - 1 5401 }, n.setProps = function (e, t, a) { 5402 var i = function () { 5403 var a = e ? e : (n.itemW + n.vars.itemMargin) * n.move * n.animatingTo, 5404 i = function () { 5405 if (v) return "setTouch" === t ? e : u && n.animatingTo === n.last ? 0 : u ? n.limit - (n.itemW + n.vars.itemMargin) * n.move * n.animatingTo : n.animatingTo === n.last ? n.limit : a; 5406 switch (t) { 5407 case "setTotal": 5408 return u ? (n.count - 1 - n.currentSlide + n.cloneOffset) * e : (n.currentSlide + n.cloneOffset) * e; 5409 case "setTouch": 5410 return u ? e : e; 5411 case "jumpEnd": 5412 return u ? e : n.count * e; 5413 case "jumpStart": 5414 return u ? n.count * e : e; 5415 default: 5416 return e 5417 } 5418 }(); 5419 return -1 * i + "px" 5420 }(); 5421 n.transitions && (i = d ? "translate3d(0," + i + ",0)" : "translate3d(" + i + ",0,0)", a = void 0 !== a ? a / 1e3 + "s" : "0s", n.container.css("-" + n.pfx + "-transition-duration", a), n.container.css("transition-duration", a)), n.args[n.prop] = i, (n.transitions || void 0 === a) && n.container.css(n.args), n.container.css("transform", i) 5422 }, n.setup = function (e) { 5423 if (p) n.slides.css({ 5424 width: "100%", 5425 "float": "left", 5426 marginRight: "-100%", 5427 position: "relative" 5428 }), "init" === e && (r ? n.slides.css({ 5429 opacity: 0, 5430 display: "block", 5431 webkitTransition: "opacity " + n.vars.animationSpeed / 1e3 + "s ease", 5432 zIndex: 1 5433 }).eq(n.currentSlide).css({ 5434 opacity: 1, 5435 zIndex: 2 5436 }) : 0 == n.vars.fadeFirstSlide ? n.slides.css({ 5437 opacity: 0, 5438 display: "block", 5439 zIndex: 1 5440 }).eq(n.currentSlide).css({ 5441 zIndex: 2 5442 }).css({ 5443 opacity: 1 5444 }) : n.slides.css({ 5445 opacity: 0, 5446 display: "block", 5447 zIndex: 1 5448 }).eq(n.currentSlide).css({ 5449 zIndex: 2 5450 }).animate({ 5451 opacity: 1 5452 }, n.vars.animationSpeed, n.vars.easing)), n.vars.smoothHeight && f.smoothHeight(); 5453 else { 5454 var t, a; 5455 "init" === e && (n.viewport = $('<div class="' + i + 'viewport"></div>').css({ 5456 overflow: "hidden", 5457 position: "relative" 5458 }).appendTo(n).append(n.container), n.cloneCount = 0, n.cloneOffset = 0, u && (a = $.makeArray(n.slides).reverse(), n.slides = $(a), n.container.empty().append(n.slides))), n.vars.animationLoop && !v && (n.cloneCount = 2, n.cloneOffset = 1, "init" !== e && n.container.find(".clone").remove(), n.container.append(f.uniqueID(n.slides.first().clone().addClass("clone")).attr("aria-hidden", "true")).prepend(f.uniqueID(n.slides.last().clone().addClass("clone")).attr("aria-hidden", "true"))), n.newSlides = $(n.vars.selector, n), t = u ? n.count - 1 - n.currentSlide + n.cloneOffset : n.currentSlide + n.cloneOffset, d && !v ? (n.container.height(200 * (n.count + n.cloneCount) + "%").css("position", "absolute").width("100%"), setTimeout(function () { 5459 n.newSlides.css({ 5460 display: "block" 5461 }), n.doMath(), n.viewport.height(n.h), n.setProps(t * n.h, "init") 5462 }, "init" === e ? 100 : 0)) : (n.container.width(200 * (n.count + n.cloneCount) + "%"), n.setProps(t * n.computedW, "init"), setTimeout(function () { 5463 n.doMath(), n.newSlides.css({ 5464 width: n.computedW, 5465 marginRight: n.computedM, 5466 "float": "left", 5467 display: "block" 5468 }), n.vars.smoothHeight && f.smoothHeight() 5469 }, "init" === e ? 100 : 0)) 5470 } 5471 v || n.slides.removeClass(i + "active-slide").eq(n.currentSlide).addClass(i + "active-slide"), n.vars.init(n) 5472 }, n.doMath = function () { 5473 var e = n.slides.first(), 5474 t = n.vars.itemMargin, 5475 a = n.vars.minItems, 5476 i = n.vars.maxItems; 5477 n.w = void 0 === n.viewport ? n.width() : n.viewport.width(), n.h = e.height(), n.boxPadding = e.outerWidth() - e.width(), v ? (n.itemT = n.vars.itemWidth + t, n.itemM = t, n.minW = a ? a * n.itemT : n.w, n.maxW = i ? i * n.itemT - t : n.w, n.itemW = n.minW > n.w ? (n.w - t * (a - 1)) / a : n.maxW < n.w ? (n.w - t * (i - 1)) / i : n.vars.itemWidth > n.w ? n.w : n.vars.itemWidth, n.visible = Math.floor(n.w / n.itemW), n.move = n.vars.move > 0 && n.vars.move < n.visible ? n.vars.move : n.visible, n.pagingCount = Math.ceil((n.count - n.visible) / n.move + 1), n.last = n.pagingCount - 1, n.limit = 1 === n.pagingCount ? 0 : n.vars.itemWidth > n.w ? n.itemW * (n.count - 1) + t * (n.count - 1) : (n.itemW + t) * n.count - n.w - t) : (n.itemW = n.w, n.itemM = t, n.pagingCount = n.count, n.last = n.count - 1), n.computedW = n.itemW - n.boxPadding, n.computedM = n.itemM 5478 }, n.update = function (e, t) { 5479 n.doMath(), v || (e < n.currentSlide ? n.currentSlide += 1 : e <= n.currentSlide && 0 !== e && (n.currentSlide -= 1), n.animatingTo = n.currentSlide), n.vars.controlNav && !n.manualControls && ("add" === t && !v || n.pagingCount > n.controlNav.length ? f.controlNav.update("add") : ("remove" === t && !v || n.pagingCount < n.controlNav.length) && (v && n.currentSlide > n.last && (n.currentSlide -= 1, n.animatingTo -= 1), f.controlNav.update("remove", n.last))), n.vars.directionNav && f.directionNav.update() 5480 }, n.addSlide = function (e, t) { 5481 var a = $(e); 5482 n.count += 1, n.last = n.count - 1, d && u ? void 0 !== t ? n.slides.eq(n.count - t).after(a) : n.container.prepend(a) : void 0 !== t ? n.slides.eq(t).before(a) : n.container.append(a), n.update(t, "add"), n.slides = $(n.vars.selector + ":not(.clone)", n), n.setup(), n.vars.added(n) 5483 }, n.removeSlide = function (e) { 5484 var t = isNaN(e) ? n.slides.index($(e)) : e; 5485 n.count -= 1, n.last = n.count - 1, isNaN(e) ? $(e, n.slides).remove() : d && u ? n.slides.eq(n.last).remove() : n.slides.eq(e).remove(), n.doMath(), n.update(t, "remove"), n.slides = $(n.vars.selector + ":not(.clone)", n), n.setup(), n.vars.removed(n) 5486 }, f.init() 5487 }, $(window).blur(function (t) { 5488 e = !1 5489 }).focus(function (t) { 5490 e = !0 5491 }), $.flexslider.defaults = { 5492 namespace: "flex-", 5493 selector: ".slides > li", 5494 animation: "fade", 5495 easing: "swing", 5496 direction: "horizontal", 5497 reverse: !1, 5498 animationLoop: !0, 5499 smoothHeight: !1, 5500 startAt: 0, 5501 slideshow: !0, 5502 slideshowSpeed: 7e3, 5503 animationSpeed: 600, 5504 initDelay: 0, 5505 randomize: !1, 5506 fadeFirstSlide: !0, 5507 thumbCaptions: !1, 5508 pauseOnAction: !0, 5509 pauseOnHover: !1, 5510 pauseInvisible: !0, 5511 useCSS: !0, 5512 touch: !0, 5513 video: !1, 5514 controlNav: !0, 5515 directionNav: !0, 5516 prevText: "Previous", 5517 nextText: "Next", 5518 keyboard: !0, 5519 multipleKeyboard: !1, 5520 mousewheel: !1, 5521 pausePlay: !1, 5522 pauseText: "Pause", 5523 playText: "Play", 5524 controlsContainer: "", 5525 manualControls: "", 5526 customDirectionNav: "", 5527 sync: "", 5528 asNavFor: "", 5529 itemWidth: 0, 5530 itemMargin: 0, 5531 minItems: 1, 5532 maxItems: 0, 5533 move: 0, 5534 allowOneSlide: !0, 5535 start: function () { }, 5536 before: function () { }, 5537 after: function () { }, 5538 end: function () { }, 5539 added: function () { }, 5540 removed: function () { }, 5541 init: function () { } 5542 }, $.fn.flexslider = function (e) { 5543 if (void 0 === e && (e = {}), "object" == typeof e) return this.each(function () { 5544 var t = $(this), 5545 a = e.selector ? e.selector : ".slides > li", 5546 n = t.find(a); 5547 1 === n.length && e.allowOneSlide === !0 || 0 === n.length ? (n.fadeIn(400), e.start && e.start(t)) : void 0 === t.data("flexslider") && new $.flexslider(this, e) 5548 }); 5549 var t = $(this).data("flexslider"); 5550 switch (e) { 5551 case "play": 5552 t.play(); 5553 break; 5554 case "pause": 5555 t.pause(); 5556 break; 5557 case "stop": 5558 t.stop(); 5559 break; 5560 case "next": 5561 t.flexAnimate(t.getTarget("next"), !0); 5562 break; 5563 case "prev": 5564 case "previous": 5565 t.flexAnimate(t.getTarget("prev"), !0); 5566 break; 5567 default: 5568 "number" == typeof e && t.flexAnimate(e, !0) 5569 } 5570 } 5571}(jQuery); 5572 5573 5574/* 5575 * Magnific Popup 5576 * ----------------------------------------------- 5577 */ 5578/*! Magnific Popup - v1.0.1 - 2015-12-30
5579 * http://dimsemenov.com/plugins/magnific-popup/ 5580 * Copyright (c) 2015 Dmitry Semenov; */ 5581! function (a) { 5582 "function" == typeof define && define.amd ? define(["jquery"], a) : a("object" == typeof exports ? require("jquery") : window.jQuery || window.Zepto) 5583}(function (a) { 5584 var b, c, d, e, f, g, h = "Close", 5585 i = "BeforeClose", 5586 j = "AfterClose", 5587 k = "BeforeAppend", 5588 l = "MarkupParse", 5589 m = "Open", 5590 n = "Change", 5591 o = "mfp", 5592 p = "." + o, 5593 q = "mfp-ready", 5594 r = "mfp-removing", 5595 s = "mfp-prevent-close", 5596 t = function () { }, 5597 u = !!window.jQuery, 5598 v = a(window), 5599 w = function (a, c) { 5600 b.ev.on(o + a + p, c) 5601 }, 5602 x = function (b, c, d, e) { 5603 var f = document.createElement("div"); 5604 return f.className = "mfp-" + b, d && (f.innerHTML = d), e ? c && c.appendChild(f) : (f = a(f), c && f.appendTo(c)), f 5605 }, 5606 y = function (c, d) { 5607 b.ev.triggerHandler(o + c, d), b.st.callbacks && (c = c.charAt(0).toLowerCase() + c.slice(1), b.st.callbacks[c] && b.st.callbacks[c].apply(b, a.isArray(d) ? d : [d])) 5608 }, 5609 z = function (c) { 5610 return c === g && b.currTemplate.closeBtn || (b.currTemplate.closeBtn = a(b.st.closeMarkup.replace("%title%", b.st.tClose)), g = c), b.currTemplate.closeBtn 5611 }, 5612 A = function () { 5613 a.magnificPopup.instance || (b = new t, b.init(), a.magnificPopup.instance = b) 5614 }, 5615 B = function () { 5616 var a = document.createElement("p").style, 5617 b = ["ms", "O", "Moz", "Webkit"]; 5618 if (void 0 !== a.transition) return !0; 5619 for (; b.length;) 5620 if (b.pop() + "Transition" in a) return !0; 5621 return !1 5622 }; 5623 t.prototype = { 5624 constructor: t, 5625 init: function () { 5626 var c = navigator.appVersion; 5627 b.isIE7 = -1 !== c.indexOf("MSIE 7."), b.isIE8 = -1 !== c.indexOf("MSIE 8."), b.isLowIE = b.isIE7 || b.isIE8, b.isAndroid = /android/gi.test(c), b.isIOS = /iphone|ipad|ipod/gi.test(c), b.supportsTransition = B(), b.probablyMobile = b.isAndroid || b.isIOS || /(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent), d = a(document), b.popupsCache = {} 5628 }, 5629 open: function (c) { 5630 var e; 5631 if (c.isObj === !1) { 5632 b.items = c.items.toArray(), b.index = 0; 5633 var g, h = c.items; 5634 for (e = 0; e < h.length; e++) 5635 if (g = h[e], g.parsed && (g = g.el[0]), g === c.el[0]) { 5636 b.index = e; 5637 break 5638 } 5639 } else b.items = a.isArray(c.items) ? c.items : [c.items], b.index = c.index || 0; 5640 if (b.isOpen) return void b.updateItemHTML(); 5641 b.types = [], f = "", c.mainEl && c.mainEl.length ? b.ev = c.mainEl.eq(0) : b.ev = d, c.key ? (b.popupsCache[c.key] || (b.popupsCache[c.key] = {}), b.currTemplate = b.popupsCache[c.key]) : b.currTemplate = {}, b.st = a.extend(!0, {}, a.magnificPopup.defaults, c), b.fixedContentPos = "auto" === b.st.fixedContentPos ? !b.probablyMobile : b.st.fixedContentPos, b.st.modal && (b.st.closeOnContentClick = !1, b.st.closeOnBgClick = !1, b.st.showCloseBtn = !1, b.st.enableEscapeKey = !1), b.bgOverlay || (b.bgOverlay = x("bg").on("click" + p, function () { 5642 b.close() 5643 }), b.wrap = x("wrap").attr("tabindex", -1).on("click" + p, function (a) { 5644 b._checkIfClose(a.target) && b.close() 5645 }), b.container = x("container", b.wrap)), b.contentContainer = x("content"), b.st.preloader && (b.preloader = x("preloader", b.container, b.st.tLoading)); 5646 var i = a.magnificPopup.modules; 5647 for (e = 0; e < i.length; e++) { 5648 var j = i[e]; 5649 j = j.charAt(0).toUpperCase() + j.slice(1), b["init" + j].call(b) 5650 } 5651 y("BeforeOpen"), b.st.showCloseBtn && (b.st.closeBtnInside ? (w(l, function (a, b, c, d) { 5652 c.close_replaceWith = z(d.type) 5653 }), f += " mfp-close-btn-in") : b.wrap.append(z())), b.st.alignTop && (f += " mfp-align-top"), b.fixedContentPos ? b.wrap.css({ 5654 overflow: b.st.overflowY, 5655 overflowX: "hidden", 5656 overflowY: b.st.overflowY 5657 }) : b.wrap.css({ 5658 top: v.scrollTop(), 5659 position: "absolute" 5660 }), (b.st.fixedBgPos === !1 || "auto" === b.st.fixedBgPos && !b.fixedContentPos) && b.bgOverlay.css({ 5661 height: d.height(), 5662 position: "absolute" 5663 }), b.st.enableEscapeKey && d.on("keyup" + p, function (a) { 5664 27 === a.keyCode && b.close() 5665 }), v.on("resize" + p, function () { 5666 b.updateSize() 5667 }), b.st.closeOnContentClick || (f += " mfp-auto-cursor"), f && b.wrap.addClass(f); 5668 var k = b.wH = v.height(), 5669 n = {}; 5670 if (b.fixedContentPos && b._hasScrollBar(k)) { 5671 var o = b._getScrollbarSize(); 5672 o && (n.marginRight = o) 5673 } 5674 b.fixedContentPos && (b.isIE7 ? a("body, html").css("overflow", "hidden") : n.overflow = "hidden"); 5675 var r = b.st.mainClass; 5676 return b.isIE7 && (r += " mfp-ie7"), r && b._addClassToMFP(r), b.updateItemHTML(), y("BuildControls"), a("html").css(n), b.bgOverlay.add(b.
5676wrap).prependTo(b.st.prependTo || a(document.body)), b._lastFocusedEl = document.activeElement, setTimeout(function () { 5677 b.content ? (b._addClassToMFP(q), b._setFocus()) : b.bgOverlay.addClass(q), d.on("focusin" + p, b._onFocusIn) 5678 }, 16), b.isOpen = !0, b.updateSize(k), y(m), c 5679 }, 5680 close: function () { 5681 b.isOpen && (y(i), b.isOpen = !1, b.st.removalDelay && !b.isLowIE && b.supportsTransition ? (b._addClassToMFP(r), setTimeout(function () { 5682 b._close() 5683 }, b.st.removalDelay)) : b._close()) 5684 }, 5685 _close: function () { 5686 y(h); 5687 var c = r + " " + q + " "; 5688 if (b.bgOverlay.detach(), b.wrap.detach(), b.container.empty(), b.st.mainClass && (c += b.st.mainClass + " "), b._removeClassFromMFP(c), b.fixedContentPos) { 5689 var e = { 5690 marginRight: "" 5691 }; 5692 b.isIE7 ? a("body, html").css("overflow", "") : e.overflow = "", a("html").css(e) 5693 } 5694 d.off("keyup" + p + " focusin" + p), b.ev.off(p), b.wrap.attr("class", "mfp-wrap").removeAttr("style"), b.bgOverlay.attr("class", "mfp-bg"), b.container.attr("class", "mfp-container"), !b.st.showCloseBtn || b.st.closeBtnInside && b.currTemplate[b.currItem.type] !== !0 || b.currTemplate.closeBtn && b.currTemplate.closeBtn.detach(), b.st.autoFocusLast && b._lastFocusedEl && a(b._lastFocusedEl).focus(), b.currItem = null, b.content = null, b.currTemplate = null, b.prevHeight = 0, y(j) 5695 }, 5696 updateSize: function (a) { 5697 if (b.isIOS) { 5698 var c = document.documentElement.clientWidth / window.innerWidth, 5699 d = window.innerHeight * c; 5700 b.wrap.css("height", d), b.wH = d 5701 } else b.wH = a || v.height(); 5702 b.fixedContentPos || b.wrap.css("height", b.wH), y("Resize") 5703 }, 5704 updateItemHTML: function () { 5705 var c = b.items[b.index]; 5706 b.contentContainer.detach(), b.content && b.content.detach(), c.parsed || (c = b.parseEl(b.index)); 5707 var d = c.type; 5708 if (y("BeforeChange", [b.currItem ? b.currItem.type : "", d]), b.currItem = c, !b.currTemplate[d]) { 5709 var f = b.st[d] ? b.st[d].markup : !1; 5710 y("FirstMarkupParse", f), f ? b.currTemplate[d] = a(f) : b.currTemplate[d] = !0 5711 } 5712 e && e !== c.type && b.container.removeClass("mfp-" + e + "-holder"); 5713 var g = b["get" + d.charAt(0).toUpperCase() + d.slice(1)](c, b.currTemplate[d]); 5714 b.appendContent(g, d), c.preloaded = !0, y(n, c), e = c.type, b.container.prepend(b.contentContainer), y("AfterChange") 5715 }, 5716 appendContent: function (a, c) { 5717 b.content = a, a ? b.st.showCloseBtn && b.st.closeBtnInside && b.currTemplate[c] === !0 ? b.content.find(".mfp-close").length || b.content.append(z()) : b.content = a : b.content = "", y(k), b.container.addClass("mfp-" + c + "-holder"), b.contentContainer.append(b.content) 5718 }, 5719 parseEl: function (c) { 5720 var d, e = b.items[c]; 5721 if (e.tagName ? e = { 5722 el: a(e) 5723 } : (d = e.type, e = { 5724 data: e, 5725 src: e.src 5726 }), e.el) { 5727 for (var f = b.types, g = 0; g < f.length; g++) 5728 if (e.el.hasClass("mfp-" + f[g])) { 5729 d = f[g]; 5730 break 5731 } e.src = e.el.attr("data-mfp-src"), e.src || (e.src = e.el.attr("href")) 5732 } 5733 return e.type = d || b.st.type || "inline", e.index = c, e.parsed = !0, b.items[c] = e, y("ElementParse", e), b.items[c] 5734 }, 5735 addGroup: function (a, c) { 5736 var d = function (d) { 5737 d.mfpEl = this, b._openClick(d, a, c) 5738 }; 5739 c || (c = {}); 5740 var e = "click.magnificPopup"; 5741 c.mainEl = a, c.items ? (c.isObj = !0, a.off(e).on(e, d)) : (c.isObj = !1, c.delegate ? a.off(e).on(e, c.delegate, d) : (c.items = a, a.off(e).on(e, d))) 5742 }, 5743 _openClick: function (c, d, e) { 5744 var f = void 0 !== e.midClick ? e.midClick : a.magnificPopup.defaults.midClick; 5745 if (f || !(2 === c.which || c.ctrlKey || c.metaKey || c.altKey || c.shift
5745Key)) { 5746 var g = void 0 !== e.disableOn ? e.disableOn : a.magnificPopup.defaults.disableOn; 5747 if (g) 5748 if (a.isFunction(g)) { 5749 if (!g.call(b)) return !0 5750 } else if (v.width() < g) return !0; 5751 c.type && (c.preventDefault(), b.isOpen && c.stopPropagation()), e.el = a(c.mfpEl), e.delegate && (e.items = d.find(e.delegate)), b.open(e) 5752 } 5753 }, 5754 updateStatus: function (a, d) { 5755 if (b.preloader) { 5756 c !== a && b.container.removeClass("mfp-s-" + c), d || "loading" !== a || (d = b.st.tLoading); 5757 var e = { 5758 status: a, 5759 text: d 5760 }; 5761 y("UpdateStatus", e), a = e.status, d = e.text, b.preloader.html(d), b.preloader.find("a").on("click", function (a) { 5762 a.stopImmediatePropagation() 5763 }), b.container.addClass("mfp-s-" + a), c = a 5764 } 5765 }, 5766 _checkIfClose: function (c) { 5767 if (!a(c).hasClass(s)) { 5768 var d = b.st.closeOnContentClick, 5769 e = b.st.closeOnBgClick; 5770 if (d && e) return !0; 5771 if (!b.content || a(c).hasClass("mfp-close") || b.preloader && c === b.preloader[0]) return !0; 5772 if (c === b.content[0] || a.contains(b.content[0], c)) { 5773 if (d) return !0 5774 } else if (e && a.contains(document, c)) return !0; 5775 return !1 5776 } 5777 }, 5778 _addClassToMFP: function (a) { 5779 b.bgOverlay.addClass(a), b.wrap.addClass(a) 5780 }, 5781 _removeClassFromMFP: function (a) { 5782 this.bgOverlay.removeClass(a), b.wrap.removeClass(a) 5783 }, 5784 _hasScrollBar: function (a) { 5785 return (b.isIE7 ? d.height() : document.body.scrollHeight) > (a || v.height()) 5786 }, 5787 _setFocus: function () { 5788 (b.st.focus ? b.content.find(b.st.focus).eq(0) : b.wrap).focus() 5789 }, 5790 _onFocusIn: function (c) { 5791 return c.target === b.wrap[0] || a.contains(b.wrap[0], c.target) ? void 0 : (b._setFocus(), !1) 5792 }, 5793 _parseMarkup: function (b, c, d) { 5794 var e; 5795 d.data && (c = a.extend(d.data, c)), y(l, [b, c, d]), a.each(c, function (a, c) { 5796 if (void 0 === c || c === !1) return !0; 5797 if (e = a.split("_"), e.length > 1) { 5798 var d = b.find(p + "-" + e[0]); 5799 if (d.length > 0) { 5800 var f = e[1]; 5801 "replaceWith" === f ? d[0] !== c[0] && d.replaceWith(c) : "img" === f ? d.is("img") ? d.attr("src", c) : d.replaceWith('<img src="' + c + '" class="' + d.attr("class") + '" />') : d.attr(e[1], c) 5802 } 5803 } else b.find(p + "-" + a).html(c) 5804 }) 5805 }, 5806 _getScrollbarSize: function () { 5807 if (void 0 === b.scrollbarSize) { 5808 var a = document.createElement("div"); 5809 a.style.cssText = "width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;", document.body.appendChild(a), b.scrollbarSize = a.offsetWidth - a.clientWidth, document.body.removeChild(a) 5810 } 5811 return b.scrollbarSize 5812 } 5813 }, a.magnificPopup = { 5814 instance: null, 5815 proto: t.prototype, 5816 modules: [], 5817 open: function (b, c) { 5818 return A(), b = b ? a.extend(!0, {}, b) : {}, b.isObj = !0, b.index = c || 0, this.instance.open(b) 5819 }, 5820 close: function () { 5821 return a.magnificPopup.instance && a.magnificPopup.instance.close() 5822 }, 5823 registerModule: function (b, c) { 5824 c.options && (a.magnificPopup.defaults[b] = c.options), a.extend(this.proto, c.proto), this.modules.push(b) 5825 }, 5826 defaults: { 5827 disableOn: 0, 5828 key: null, 5829 midClick: !1, 5830 mainClass: "", 5831 preloader: !0, 5832 focus: "", 5833 closeOnContentClick: !1, 5834 closeOnBgClick: !0, 5835 closeBtnInside: !0, 5836 showCloseBtn: !0, 5837 enableEscapeKey: !0, 5838 modal: !1, 5839 alignTop: !1, 5840 removalDelay: 0, 5841 prependTo: null, 5842 fixedContentPos: "auto", 5843 fixedBgPos: "auto", 5844 overflowY: "auto", 5845 closeMarkup: '<button title="%title%" type="button" class="mfp-close">×</button>', 5846 tClose: "Close (Esc)", 5847 tLoading: "Loading...", 5848 autoFocusLast: !0 5849 } 5850 }, a.fn.magnificPopup = function (c) { 5851 A(); 5852 var d = a(this); 5853 if ("string" == typeof c) 5854 if ("open" === c) { 5855 var e, f = u ? d.data("magnificPopup") : d[0].magnificPopup, 5856 g = parseInt(arguments[1], 10) || 0; 5857 f.items ? e = f.items[g] : (e = d, f.delegate && (e = e.find(f.delegate)), e = e.eq(g)), b._openClick({ 5858 mfpEl: e 5859 }, d, f) 5860 } else b.isOpen && b[c].apply(b, Array.prototype.slice.call(arguments, 1)); 5861 else c = a.extend(!0, {}, c), u ? d.data("magnificPopup", c) : d[0].magnificPopup = c, b.addGroup(d, c); 5862 return d 5863 }; 5864 var C, D, E, F = "inline", 5865 G = function () { 5866 E && (D.after(E.addClass(C)).detach(), E = null) 5867 }; 5868 a.magnificPopup.registerModule(F, { 5869 options: { 5870 hiddenClass: "hide", 5871 markup: "", 5872 tNotFound: "Content not found" 5873 }, 5874 proto: { 5875 initInline: function () { 5876 b.types.push(F), w(h + "." + F, function () { 5877 G() 5878 }) 5879 }, 5880 getInline: function (c, d) { 5881 if (G(), c.src) { 5882 var e = b.st.inline, 5883 f = a(c.src); 5884 if (f.length) { 5885 var g = f[0].parentNode; 5886 g && g.tagName && (D || (C = e.hiddenClass, D = x(C), C = "mfp-" + C), E = f.after(D).detach().removeClass(C)), b.updateStatus("ready") 5887 } else b.updateStatus("error", e.tNotFound), f = a("<div>"); 5888 return c.inlineElement = f, f 5889 } 5890 return b.updateStatus("ready"), b._parseMarkup(d, {}, c), d 5891 } 5892 } 5893 });
vendor: 5,114 bytes, lines 5894-5991
5894 var H, I = "ajax", 5895 J = function () { 5896 H && a(document.body).removeClass(H) 5897 }, 5898 K = function () { 5899 J(), b.req && b.req.abort() 5900 }; 5901 a.magnificPopup.registerModule(I, { 5902 options: { 5903 settings: null, 5904 cursor: "mfp-ajax-cur", 5905 tError: '<a href="%url%">The content</a> could not be loaded.' 5906 }, 5907 proto: { 5908 initAjax: function () { 5909 b.types.push(I), H = b.st.ajax.cursor, w(h + "." + I, K), w("BeforeChange." + I, K) 5910 }, 5911 getAjax: function (c) { 5912 H && a(document.body).addClass(H), b.updateStatus("loading"); 5913 var d = a.extend({ 5914 url: c.src, 5915 success: function (d, e, f) { 5916 var g = { 5917 data: d, 5918 xhr: f 5919 }; 5920 y("ParseAjax", g), b.appendContent(a(g.data), I), c.finished = !0, J(), b._setFocus(), setTimeout(function () { 5921 b.wrap.addClass(q) 5922 }, 16), b.updateStatus("ready"), y("AjaxContentAdded") 5923 }, 5924 error: function () { 5925 J(), c.finished = c.loadError = !0, b.updateStatus("error", b.st.ajax.tError.replace("%url%", c.src)) 5926 } 5927 }, b.st.ajax.settings); 5928 return b.req = a.ajax(d), "" 5929 } 5930 } 5931 }); 5932 var L, M = function (c) { 5933 if (c.data && void 0 !== c.data.title) return c.data.title; 5934 var d = b.st.image.titleSrc; 5935 if (d) { 5936 if (a.isFunction(d)) return d.call(b, c); 5937 if (c.el) return c.el.attr(d) || "" 5938 } 5939 return "" 5940 }; 5941 a.magnificPopup.registerModule("image", { 5942 options: { 5943 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>', 5944 cursor: "mfp-zoom-out-cur", 5945 titleSrc: "title", 5946 verticalFit: !0, 5947 tError: '<a href="%url%">The image</a> could not be loaded.' 5948 }, 5949 proto: { 5950 initImage: function () { 5951 var c = b.st.image, 5952 d = ".image"; 5953 b.types.push("image"), w(m + d, function () { 5954 "image" === b.currItem.type && c.cursor && a(document.body).addClass(c.cursor) 5955 }), w(h + d, function () { 5956 c.cursor && a(document.body).removeClass(c.cursor), v.off("resize" + p) 5957 }), w("Resize" + d, b.resizeImage), b.isLowIE && w("AfterChange", b.resizeImage) 5958 }, 5959 resizeImage: function () { 5960 var a = b.currItem; 5961 if (a && a.img && b.st.image.verticalFit) { 5962 var c = 0; 5963 b.isLowIE && (c = parseInt(a.img.css("padding-top"), 10) + parseInt(a.img.css("padding-bottom"), 10)), a.img.css("max-height", b.wH - c) 5964 } 5965 }, 5966 _onImageHasSize: function (a) { 5967 a.img && (a.hasSize = !0, L && clearInterval(L), a.isCheckingImgSize = !1, y("ImageHasSize", a), a.imgHidden && (b.content && b.content.removeClass("mfp-loading"), a.imgHidden = !1)) 5968 }, 5969 findImageSize: function (a) { 5970 var c = 0, 5971 d = a.img[0], 5972 e = function (f) { 5973 L && clearInterval(L), L = setInterval(function () { 5974 return d.naturalWidth > 0 ? void b._onImageHasSize(a) : (c > 200 && clearInterval(L), c++ , void (3 === c ? e(10) : 40 === c ? e(50) : 100 === c && e(500))) 5975 }, f) 5976 }; 5977 e(1) 5978 }, 5979 getImage: function (c, d) { 5980 var e = 0, 5981 f = function () { 5982 c && (c.img[0].complete ? (c.img.off(".mfploader"), c === b.currItem && (b._onImageHasSize(c), b.updateStatus("ready")), c.hasSize = !0, c.loaded = !0, y("ImageLoadComplete")) : (e++ , 200 > e ? setTimeout(f, 100) : g())) 5983 }, 5984 g = function () { 5985 c && (c.img.off(".mfploader"), c === b.currItem && (b._onImageHasSize(c), b.updateStatus("error", h.tError.replace("%url%", c.src))), c.hasSize = !0, c.loaded = !0, c.loadError = !0) 5986 }, 5987 h = b.st.image, 5988 i = d.find(".mfp-img"); 5989 if (i.length) { 5990 var j = document.createElement("img"); 5991 j.className = "mfp-img", c.el && c.el.find("img").length && (j.alt = c.el.find("img").attr("alt")), c.img = a(j).on("load.mfploader", f).on("error.mfploader", g), j.src = c.src, i.is("img") && (c.img = c.img.clone()), j = c.img[0], j.naturalWi
5991dth > 0 ? c.hasSize = !0 : j.width || (c.hasSize = !1) 5992 } 5993 return b._parseMarkup(d, { 5994 title: M(c), 5995 img_replaceWith: c.img 5996 }, c), b.resizeImage(), c.hasSize ? (L && clearInterval(L), c.loadError ? (d.addClass("mfp-loading"), b.updateStatus("error", h.tError.replace("%url%", c.src))) : (d.removeClass("mfp-loading"), b.updateStatus("ready")), d) : (b.updateStatus("loading"), c.loading = !0, c.hasSize || (c.imgHidden = !0, d.addClass("mfp-loading"), b.findImageSize(c)), d) 5997 } 5998 } 5999 }); 6000 var N, O = function () { 6001 return void 0 === N && (N = void 0 !== document.createElement("p").style.MozTransform), N 6002 }; 6003 a.magnificPopup.registerModule("zoom", { 6004 options: { 6005 enabled: !1, 6006 easing: "ease-in-out", 6007 duration: 300, 6008 opener: function (a) { 6009 return a.is("img") ? a : a.find("img") 6010 } 6011 }, 6012 proto: { 6013 initZoom: function () { 6014 var a, c = b.st.zoom, 6015 d = ".zoom"; 6016 if (c.enabled && b.supportsTransition) { 6017 var e, f, g = c.duration, 6018 j = function (a) { 6019 var b = a.clone().removeAttr("style").removeAttr("class").addClass("mfp-animated-image"), 6020 d = "all " + c.duration / 1e3 + "s " + c.easing, 6021 e = { 6022 position: "fixed", 6023 zIndex: 9999, 6024 left: 0, 6025 top: 0, 6026 "-webkit-backface-visibility": "hidden" 6027 }, 6028 f = "transition"; 6029 return e["-webkit-" + f] = e["-moz-" + f] = e["-o-" + f] = e[f] = d, b.css(e), b 6030 }, 6031 k = function () { 6032 b.content.css("visibility", "visible") 6033 }; 6034 w("BuildControls" + d, function () { 6035 if (b._allowZoom()) { 6036 if (clearTimeout(e), b.content.css("visibility", "hidden"), a = b._getItemToZoom(), !a) return void k(); 6037 f = j(a), f.css(b._getOffset()), b.wrap.append(f), e = setTimeout(function () { 6038 f.css(b._getOffset(!0)), e = setTimeout(function () { 6039 k(), setTimeout(function () { 6040 f.remove(), a = f = null, y("ZoomAnimationEnded") 6041 }, 16) 6042 }, g) 6043 }, 16) 6044 } 6045 }), w(i + d, function () { 6046 if (b._allowZoom()) { 6047 if (clearTimeout(e), b.st.removalDelay = g, !a) { 6048 if (a = b._getItemToZoom(), !a) return; 6049 f = j(a) 6050 } 6051 f.css(b._getOffset(!0)), b.wrap.append(f), b.content.css("visibility", "hidden"), setTimeout(function () { 6052 f.css(b._getOffset()) 6053 }, 16) 6054 } 6055 }), w(h + d, function () { 6056 b._allowZoom() && (k(), f && f.remove(), a = null) 6057 }) 6058 } 6059 }, 6060 _allowZoom: function () { 6061 return "image" === b.currItem.type 6062 }, 6063 _getItemToZoom: function () { 6064 return b.currItem.hasSize ? b.currItem.img : !1 6065 }, 6066 _getOffset: function (c) { 6067 var d; 6068 d = c ? b.currItem.img : b.st.zoom.opener(b.currItem.el || b.currItem); 6069 var e = d.offset(), 6070 f = parseInt(d.css("padding-top"), 10), 6071 g = parseInt(d.css("padding-bottom"), 10); 6072 e.top -= a(window).scrollTop() - f; 6073 var h = { 6074 width: d.width(), 6075 height: (u ? d.innerHeight() : d[0].offsetHeight) - g - f 6076 }; 6077 return O() ? h["-moz-transform"] = h.transform = "translate(" + e.left + "px," + e.top + "px)" : (h.left = e.left, h.top = e.top), h 6078 } 6079 } 6080 });
6081 var P = "iframe", 6082 Q = "//about:blank", 6083 R = function (a) { 6084 if (b.currTemplate[P]) { 6085 var c = b.currTemplate[P].find("iframe"); 6086 c.length && (a || (c[0].src = Q), b.isIE8 && c.css("display", a ? "block" : "none")) 6087 } 6088 }; 6089 a.magnificPopup.registerModule(P, { 6090 options: { 6091 markup: '<div class="mfp-iframe-scaler"><div class="mfp-close"></div><iframe class="mfp-iframe" src="//about:blank" allowfullscreen></iframe></div>', 6092 srcAction: "iframe_src", 6093 patterns: { 6094 youtube: { 6095 index: "youtube.com", 6096 id: "v=", 6097 src: "//www.youtube.com/embed/%id%?autoplay=1" 6098 }, 6099 vimeo: { 6100 index: "vimeo.com/", 6101 id: "/", 6102 src: "//player.vimeo.com/video/%id%?autoplay=1" 6103 }, 6104 gmaps: { 6105 index: "//maps.google.", 6106 src: "%id%&output=embed" 6107 } 6108 } 6109 }, 6110 proto: { 6111 initIframe: function () { 6112 b.types.push(P), w("BeforeChange", function (a, b, c) { 6113 b !== c && (b === P ? R() : c === P && R(!0)) 6114 }), w(h + "." + P, function () { 6115 R() 6116 }) 6117 }, 6118 getIframe: function (c, d) { 6119 var e = c.src, 6120 f = b.st.iframe; 6121 a.each(f.patterns, function () { 6122 return e.indexOf(this.index) > -1 ? (this.id && (e = "string" == typeof this.id ? e.substr(e.lastIndexOf(this.id) + this.id.length, e.length) : this.id.call(this, e)), e = this.src.replace("%id%", e), !1) : void 0 6123 }); 6124 var g = {}; 6125 return f.srcAction && (g[f.srcAction] = e), b._parseMarkup(d, g, c), b.updateStatus("ready"), d 6126 } 6127 } 6128 }); 6129 var S = function (a) { 6130 var c = b.items.length; 6131 return a > c - 1 ? a - c : 0 > a ? c + a : a 6132 }, 6133 T = function (a, b, c) { 6134 return a.replace(/%curr%/gi, b + 1).replace(/%total%/gi, c) 6135 }; 6136 a.magnificPopup.registerModule("gallery", { 6137 options: { 6138 enabled: !1, 6139 arrowMarkup: '<button title="%title%" type="button" class="mfp-arrow mfp-arrow-%dir%"></button>', 6140 preload: [0, 2], 6141 navigateByImgClick: !0, 6142 arrows: !0, 6143 tPrev: "Previous (Left arrow key)", 6144 tNext: "Next (Right arrow key)", 6145 tCounter: "%curr% of %total%" 6146 }, 6147 proto: { 6148 initGallery: function () { 6149 var c = b.st.gallery, 6150 e = ".mfp-gallery", 6151 g = Boolean(a.fn.mfpFastClick); 6152 return b.direction = !0, c && c.enabled ? (f += " mfp-gallery", w(m + e, function () { 6153 c.navigateByImgClick && b.wrap.on("click" + e, ".mfp-img", function () { 6154 return b.items.length > 1 ? (b.next(), !1) : void 0 6155 }), d.on("keydown" + e, function (a) { 6156 37 === a.keyCode ? b.prev() : 39 === a.keyCode && b.next() 6157 }) 6158 }), w("UpdateStatus" + e, function (a, c) { 6159 c.text && (c.text = T(c.text, b.currItem.index, b.items.length)) 6160 }), w(l + e, function (a, d, e, f) { 6161 var g = b.items.length; 6162 e.counter = g > 1 ? T(c.tCounter, f.index, g) : "" 6163 }), w("BuildControls" + e, function () { 6164 if (b.items.length > 1 && c.arrows && !b.arrowLeft) { 6165 var d = c.arrowMarkup, 6166 e = b.arrowLeft = a(d.replace(/%title%/gi, c.tPrev).replace(/%dir%/gi, "left")).addClass(s), 6167 f = b.arrowRight = a(d.replace(/%title%/gi, c.tNext).replace(/%dir%/gi, "right")).addClass(s), 6168 h = g ? "mfpFastClick" : "click"; 6169 e[h](function () { 6170 b.prev() 6171 }), f[h](function () { 6172 b.next() 6173 }), b.isIE7 && (x("b", e[0], !1, !0), x("a", e[0], !1, !0), x("b", f[0], !1, !0), x("a", f[0], !1, !0)), b.container.append(e.add(f)) 6174 } 6175 }), w(n + e, function () { 6176 b._preloadTimeout && clearTimeout(b._preloadTimeout), b._preloadTimeout = setTimeout(function () { 6177 b.preloadNearbyImages(), b._preloadTimeout = null 6178 }, 16) 6179 }), void w(h + e, function () { 6180 d.off(e), b.wrap.off("click" + e), b.arrowLeft && g && b.arrowLeft.add(b.arrowRight).destroyMfpFastClick(), b.arrowRight = b.arrowLeft = null 6181 })) : !1 6182 }, 6183 next: function () { 6184 b.direction = !0, b.index = S(b.index + 1), b.updateItemHTML() 6185 }, 6186 prev: function () { 6187 b.direction = !1, b.index = S(b.index - 1), b.updateItemHTML() 6188 }, 6189 goTo: function (a) { 6190 b.direction = a >= b.index, b.index = a, b.updateItemHTML() 6191 }, 6192 preloadNearbyImages: function () { 6193 var a, c = b.st.gallery.preload, 6194 d = Math.min(c[0], b.items.length), 6195 e = Math.min(c[1], b.items.length); 6196 for (a = 1; a <= (b.direction ? e : d); a++) b._preloadItem(b.index + a); 6197 for (a = 1; a <= (b.direction ? d : e); a++) b._preloadItem(b.index - a) 6198 }, 6199 _preloadItem: function (c) { 6200 if (c = S(c), !b.items[c].preloaded) { 6201 var d = b.items[c]; 6202 d.parsed || (d = b.parseEl(c)), y("LazyLoad", d), "image" === d.t
6202ype && (d.img = a('<img class="mfp-img" />').on("load.mfploader", function () { 6203 d.hasSize = !0 6204 }).on("error.mfploader", function () { 6205 d.hasSize = !0, d.loadError = !0, y("LazyLoadError", d) 6206 }).attr("src", d.src)), d.preloaded = !0 6207 } 6208 } 6209 } 6210 }); 6211 var U = "retina"; 6212 a.magnificPopup.registerModule(U, { 6213 options: { 6214 replaceSrc: function (a) { 6215 return a.src.replace(/\.\w+$/, function (a) { 6216 return "@2x" + a 6217 }) 6218 }, 6219 ratio: 1 6220 }, 6221 proto: { 6222 initRetina: function () { 6223 if (window.devicePixelRatio > 1) { 6224 var a = b.st.retina, 6225 c = a.ratio; 6226 c = isNaN(c) ? c() : c, c > 1 && (w("ImageHasSize." + U, function (a, b) { 6227 b.img.css({ 6228 "max-width": b.img[0].naturalWidth / c, 6229 width: "100%" 6230 }) 6231 }), w("ElementParse." + U, function (b, d) { 6232 d.src = a.replaceSrc(d, c) 6233 })) 6234 } 6235 } 6236 } 6237 }), 6238 function () { 6239 var b = 1e3, 6240 c = "ontouchstart" in window, 6241 d = function () { 6242 v.off("touchmove" + f + " touchend" + f) 6243 }, 6244 e = "mfpFastClick", 6245 f = "." + e; 6246 a.fn.mfpFastClick = function (e) { 6247 return a(this).each(function () { 6248 var g, h = a(this); 6249 if (c) { 6250 var i, j, k, l, m, n; 6251 h.on("touchstart" + f, function (a) { 6252 l = !1, n = 1, m = a.originalEvent ? a.originalEvent.touches[0] : a.touches[0], j = m.clientX, k = m.clientY, v.on("touchmove" + f, function (a) { 6253 m = a.originalEvent ? a.originalEvent.touches : a.touches, n = m.length, m = m[0], (Math.abs(m.clientX - j) > 10 || Math.abs(m.clientY - k) > 10) && (l = !0, d()) 6254 }).on("touchend" + f, function (a) { 6255 d(), l || n > 1 || (g = !0, a.preventDefault(), clearTimeout(i), i = setTimeout(function () { 6256 g = !1 6257 }, b), e()) 6258 }) 6259 }) 6260 } 6261 h.on("click" + f, function () { 6262 g || e() 6263 }) 6264 }) 6265 }, a.fn.destroyMfpFastClick = function () { 6266 a(this).off("touchstart" + f + " click" + f), c && v.off("touchmove" + f + " touchend" + f) 6267 } 6268 }(), A() 6269}); 6270 6271 6272/* 6273 * Nivo Lightbox 6274 * ----------------------------------------------- 6275 */ 6276/* 6277 * Nivo Lightbox v1.2.0 6278 * http://dev7studios.com/nivo-lightbox 6279 * 6280 * Copyright 2013, Dev7studios 6281 * Free to use and abuse under the MIT license. 6282 * http://www.opensource.org/licenses/mit-license.php 6283 */ 6284(function (e, t, n, r) { 6285 function o(t, n) { 6286 this.el = t; 6287 this.$el = e(this.el); 6288 this.options = e.extend({}, s, n); 6289 this._defaults = s; 6290 this._name = i; 6291 this.init() 6292 } 6293 var i = "nivoLightbox", 6294 s = { 6295 effect: "fade", 6296 theme: "default", 6297 keyboardNav: true, 6298 clickOverlayToClose: true, 6299 onInit: function () { }, 6300 beforeShowLightbox: function () { }, 6301 afterShowLightbox: function (e) { }, 6302 beforeHideLightbox: function () { }, 6303 afterHideLightbox: function () { }, 6304 onPrev: function (e) { }, 6305 onNext: function (e) { }, 6306 errorMessage: "The requested content cannot be loaded. Please try again later." 6307 }; 6308 o.prototype = { 6309 init: function () { 6310 var t = this; 6311 if (!e("html").hasClass("nivo-lightbox-notouch")) e("html").addClass("nivo-lightbox-notouch"); 6312 if ("ontouchstart" in n) e("html").removeClass("nivo-lightbox-notouch"); 6313 this.$el.on("click", function (e) { 6314 t.showLightbox(e) 6315 }); 6316 if (this.options.keyboardNav) { 6317 e("body").off("keyup").on("keyup", function (n) { 6318 var r = n.keyCode ? n.keyCode : n.which; 6319 if (r == 27) t.destructLightbox(); 6320 if (r == 37) e(".nivo-lightbox-prev").trigger("click"); 6321 if (r == 39) e(".nivo-lightbox-next").trigger("click") 6322 }) 6323 } 6324 this.options.onInit.call(this) 6325 }, 6326 showLightbox: function (t) { 6327 var n = this, 6328 r = this.$el; 6329 var i = this.checkContent(r); 6330 if (!i) return; 6331 t.preventDefault(); 6332 this.options.beforeShowLightbox.call(this); 6333 var s = this.constructLightbox(); 6334 if (!s) return; 6335 var o = s.find(".nivo-lightbox-content"); 6336 if (!o) return; 6337 e("body").addClass("nivo-lightbox-body-effect-" + this.options.effect); 6338 this.processContent(o, r); 6339 if (this.$el.attr("data-lightbox-gallery")) { 6340 var u = e('[data-lightbox-gallery="' + this.$el.attr("data-lightbox-gallery") + '"]'); 6341 e(".nivo-lightbox-nav").show(); 6342 e(".nivo-lightbox-prev").off("click").on("click", function (t) { 6343 t.preventDefault(); 6344 var i = u.index(r); 6345 r = u.eq(i - 1); 6346 if (!e(r).length) r = u.last(); 6347 n.processContent(o, r); 6348 n.options.onPrev.call(this, [r]) 6349 }); 6350 e(".nivo-lightbox-next").off("click").on("click", function (t) { 6351 t.preventDefault(); 6352 var i = u.index(r); 6353 r = u.eq(i + 1); 6354 if (!e(r).length) r = u.first(); 6355 n.processContent(o, r); 6356 n.options.onNext.call(this, [r]) 6357 }) 6358 } 6359 setTimeout(function () { 6360 s.addClass("nivo-lightbox-open"); 6361 n.options.afterShowLightbox.call(this, [s]) 6362 }, 1) 6363 }, 6364 checkContent: function (e) { 6365 var t = this, 6366 n = e.attr("href"), 6367 r = n.match(/(youtube|youtu|vimeo)\.(com|be)\/(watch\?v=([\w-]+)|([\w-]+))/); 6368 if (n.match(/\.(jpeg|jpg|gif|png)$/i) !== null) { 6369 return true 6370 } else if (r) { 6371 return true 6372 } else if (e.attr("data-lightbox-type") == "ajax") { 6373 return true 6374 } else if (n.substring(0, 1) == "#" && e.attr("data-lightbox-type") == "inline") { 6375 return true 6376 } else if (e.attr("data-lightbox-type") == "iframe") { 6377 return true 6378 } 6379 return false 6380 }, 6381 processContent: function (n, r) { 6382 var i = this, 6383 s = r.attr("href"), 6384 o = s.match(/(youtube|youtu|vimeo)\.(com|be)\/(watch\?v=([\w-]+)|([\w-]+))/); 6385 n.html("").addClass("nivo-lightbox-loading"); 6386 if (this.isHidpi() && r.attr("data-lightbox-hidpi")) { 6387 s = r.attr("data-lightbox-hidpi") 6388 } 6389 if (s.match(/\.(jpeg|jpg|gif|png)$/i) !== null) { 6390 var u = e("<img>", { 6391 src: s 6392 }); 6393 u.one("load", function () { 6394 var r = e('<div class="nivo-lightbox-image" />'); 6395 r.append(u); 6396 n.html(r).removeClass("nivo-lightbox-loading"); 6397 r.css({ 6398 "line-height": e(".nivo-lightbox-content").height() + "px", 6399 height: e(".nivo-lightbox-content").height() + "px" 6400 }); 6401 e(t).resize(function () { 6402 r.css({ 6403 "line-height": e(".nivo-lightbox-content").height() + "px", 6404 height: e(".nivo-lightbox-content").height() + "px" 6405 }) 6406 }) 6407 }).each(function () { 6408 if (this.complete) e(this).load() 6409 }); 6410 u.error(function () { 6411 var t = e('<div class="nivo-lightbox-error"><p>' + i.options.errorMessage + "</p></div>"); 6412 n.html(t).removeClass("nivo-lightbox-loading") 6413 }) 6414 } else if (o) { 6415 var a = "", 6416 f = "nivo-lightbox-video"; 6417 if (o[1] == "youtube") { 6418 a = "http://www.youtube.com/embed/" + o[4]; 6419 f = "nivo-lightbox-youtube" 6420 } 6421 if (o[1] == "youtu") { 6422 a = "http://www.youtube.com/embed/" + o[3]; 6423 f = "nivo-lightbox-youtube" 6424 } 6425 if (o[1] == "vimeo") { 6426 a = "http://player.vimeo.com/video/" + o[3]; 6427 f = "nivo-lightbox-vimeo" 6428 } 6429 if (a) { 6430 var l = e("<iframe>", { 6431 src: a, 6432 "class": f, 6433 frameborder: 0, 6434 vspace: 0, 6435 hspace: 0, 6436 scrolling: "auto" 6437 }); 6438 n.html(l); 6439 l.load(function () { 6440 n.removeClass("nivo-lightbox-loading") 6441 }) 6442 } 6443 } else if (r.attr("data-lightbox-type") == "ajax") { 6444 e.ajax({
6445 url: s, 6446 cache: false, 6447 success: function (r) { 6448 var i = e('<div class="nivo-lightbox-ajax" />'); 6449 i.append(r); 6450 n.html(i).removeClass("nivo-lightbox-loading"); 6451 if (i.outerHeight() < n.height()) { 6452 i.css({ 6453 position: "relative", 6454 top: "50%", 6455 "margin-top": -(i.outerHeight() / 2) + "px" 6456 }) 6457 } 6458 e(t).resize(function () { 6459 if (i.outerHeight() < n.height()) { 6460 i.css({ 6461 position: "relative", 6462 top: "50%", 6463 "margin-top": -(i.outerHeight() / 2) + "px" 6464 }) 6465 } 6466 }) 6467 }, 6468 error: function () { 6469 var t = e('<div class="nivo-lightbox-error"><p>' + i.options.errorMessage + "</p></div>"); 6470 n.html(t).removeClass("nivo-lightbox-loading") 6471 } 6472 }) 6473 } else if (s.substring(0, 1) == "#" && r.attr("data-lightbox-type") == "inline") { 6474 if (e(s).length) { 6475 var c = e('<div class="nivo-lightbox-inline" />'); 6476 c.append(e(s).clone().show()); 6477 n.html(c).removeClass("nivo-lightbox-loading"); 6478 if (c.outerHeight() < n.height()) { 6479 c.css({ 6480 position: "relative", 6481 top: "50%", 6482 "margin-top": -(c.outerHeight() / 2) + "px" 6483 }) 6484 } 6485 e(t).resize(function () { 6486 if (c.outerHeight() < n.height()) { 6487 c.css({ 6488 position: "relative", 6489 top: "50%", 6490 "margin-top": -(c.outerHeight() / 2) + "px" 6491 }) 6492 } 6493 }) 6494 } else { 6495 var h = e('<div class="nivo-lightbox-error"><p>' + i.options.errorMessage + "</p></div>"); 6496 n.html(h).removeClass("nivo-lightbox-loading") 6497 } 6498 } else if (r.attr("data-lightbox-type") == "iframe") { 6499 var p = e("<iframe>", { 6500 src: s, 6501 "class": "nivo-lightbox-item", 6502 frameborder: 0, 6503 vspace: 0, 6504 hspace: 0, 6505 scrolling: "auto" 6506 }); 6507 n.html(p); 6508 p.load(function () { 6509 n.removeClass("nivo-lightbox-loading") 6510 }) 6511 } else { 6512 return false 6513 } 6514 if (r.attr("title")) { 6515 var d = e("<span>", { 6516 "class": "nivo-lightbox-title" 6517 }); 6518 d.text(r.attr("title")); 6519 e(".nivo-lightbox-title-wrap").html(d) 6520 } else { 6521 e(".nivo-lightbox-title-wrap").html("") 6522 } 6523 }, 6524 constructLightbox: function () { 6525 if (e(".nivo-lightbox-overlay").length) return e(".nivo-lightbox-overlay"); 6526 var t = e("<div>", { 6527 "class": "nivo-lightbox-overlay nivo-lightbox-theme-" + this.options.theme + " nivo-lightbox-effect-" + this.options.effect 6528 }); 6529 var n = e("<div>", { 6530 "class": "nivo-lightbox-wrap" 6531 }); 6532 var r = e("<div>", { 6533 "class": "nivo-lightbox-content" 6534 }); 6535 var i = e('<a href="#" class="nivo-lightbox-nav nivo-lightbox-prev">Previous</a><a href="#" class="nivo-lightbox-nav nivo-lightbox-next">Next</a>'); 6536 var s = e('<a href="#" class="nivo-lightbox-close" title="Close">Close</a>'); 6537 var o = e("<div>", { 6538 "class": "nivo-lightbox-title-wrap" 6539 }); 6540 var u = 0; 6541 if (u) t.addClass("nivo-lightbox-ie"); 6542 n.append(r); 6543 n.append(o); 6544 t.append(n); 6545 t.append(i); 6546 t.append(s); 6547 e("body").append(t); 6548 var a = this; 6549 if (a.options.clickOverlayToClose) { 6550 t.on("click", function (t) { 6551 if (t.target === this || e(t.target).hasClass("nivo-lightbox-content") || e(t.target).hasClass("nivo-lightbox-image")) { 6552 a.destructLightbox() 6553 } 6554 }) 6555 } 6556 s.on("click", function (e) { 6557 e.preventDefault(); 6558 a.destructLightbox() 6559 }); 6560 return t 6561 }, 6562 destructLightbox: function () { 6563 var t = this; 6564 this.options.beforeHideLightbox.call(this); 6565 e(".nivo-lightbox-overlay").removeClass("nivo-lightbox-open"); 6566 e(".nivo-lightbox-nav").hide(); 6567 e("body").removeClass("nivo-lightbox-body-effect-" + t.options.effect); 6568 var n = 0; 6569 if (n) { 6570 e(".nivo-lightbox-overlay iframe").attr("src", " "); 6571 e(".nivo-lightbox-overlay iframe").remove() 6572 } 6573 e(".nivo-lightbox-prev").off("click"); 6574 e(".nivo-lightbox-next").off("click"); 6575 e(".nivo-lightbox-content").empty(); 6576 this.options.afterHideLightbox.call(this) 6577 }, 6578 isHidpi: function () { 6579 var e = "(-webkit-min-device-pixel-ratio: 1.5), (min--moz-device-pixel-ratio: 1.5), (-o-min-device-pixel-ratio: 3/2), (min-resolution: 1.5dppx)"; 6580 if (t.devicePixelRatio > 1) return true; 6581 if (t.matchMedia && t.matchMedia(e).matches) return true; 6582 return false 6583 } 6584 }; 6585 e.fn[i] = function (t) { 6586 return this.each(function () { 6587 if (!e.data(this, i)) { 6588 e.data(this, i, new o(this, t)) 6589 } 6590 }) 6591 } 6592})(jQuery, window, document) 6593 6594/* 6595 * PrettyPhoto Lightbox 6596 * ----------------------------------------------- 6597 */ 6598/* ------------------------------------------------------------------------ 6599 Class: prettyPhoto 6600 Use: Lightbox clone for jQuery 6601 Author: Stephane Caron (http://www.no-margin-for-errors.com) 6602 Version: 3.1.6 6603------------------------------------------------------------------------- */ 6604! function (e) { 6605 function t() { 6606 var e = location.href; 6607 return hashtag = -1 !== e.indexOf("#prettyPhoto") ? decodeURI(e.substring(e.indexOf("#prettyPhoto") + 1, e.length)) : !1, hashtag && (hashtag = hashtag.replace(/<|>/g, "")), hashtag 6608 } 6609 6610 function i() { 6611 "undefined" != typeof theRel && (location.hash = theRel + "/" + rel_index + "/") 6612 } 6613 6614 function p() { 6615 -1 !== location.href.indexOf("#prettyPhoto") && (location.hash = "prettyPhoto") 6616 } 6617 6618 function o(e, t) { 6619 e = e.replace(/[\[]/, "\\[").replace(/[\]]/, "\\]");
6620 var i = "[\\?&]" + e + "=([^&#]*)", 6621 p = new RegExp(i), 6622 o = p.exec(t); 6623 return null == o ? "" : o[1] 6624 } 6625 e.prettyPhoto = { 6626 version: "3.1.6" 6627 }, e.fn.prettyPhoto = function (a) { 6628 function s() { 6629 e(".pp_loaderIcon").hide(), projectedTop = scroll_pos.scrollTop + (I / 2 - f.containerHeight / 2), projectedTop < 0 && (projectedTop = 0), $ppt.fadeTo(settings.animation_speed, 1), $pp_pic_holder.find(".pp_content").animate({ 6630 height: f.contentHeight, 6631 width: f.contentWidth 6632 }, settings.animation_speed), $pp_pic_holder.animate({ 6633 top: projectedTop, 6634 left: j / 2 - f.containerWidth / 2 < 0 ? 0 : j / 2 - f.containerWidth / 2, 6635 width: f.containerWidth 6636 }, settings.animation_speed, function () { 6637 $pp_pic_holder.find(".pp_hoverContainer,#fullResImage").height(f.height).width(f.width), $pp_pic_holder.find(".pp_fade").fadeIn(settings.animation_speed), isSet && "image" == h(pp_images[set_position]) ? $pp_pic_holder.find(".pp_hoverContainer").show() : $pp_pic_holder.find(".pp_hoverContainer").hide(), settings.allow_expand && (f.resized ? e("a.pp_expand,a.pp_contract").show() : e("a.pp_expand").hide()), !settings.autoplay_slideshow || P || v || e.prettyPhoto.startSlideshow(), settings.changepicturecallback(), v = !0 6638 }), m(), a.ajaxcallback() 6639 } 6640 6641 function n(t) { 6642 $pp_pic_holder.find("#pp_full_res object,#pp_full_res embed").css("visibility", "hidden"), $pp_pic_holder.find(".pp_fade").fadeOut(settings.animation_speed, function () { 6643 e(".pp_loaderIcon").show(), t() 6644 }) 6645 } 6646 6647 function r(t) { 6648 t > 1 ? e(".pp_nav").show() : e(".pp_nav").hide() 6649 } 6650 6651 function l(e, t) { 6652 if (resized = !1, d(e, t), imageWidth = e, imageHeight = t, (k > j || b > I) && doresize && settings.allow_resize && !$) { 6653 for (resized = !0, fitting = !1; !fitting;) k > j ? (imageWidth = j - 200, imageHeight = t / e * imageWidth) : b > I ? (imageHeight = I - 200, imageWidth = e / t * imageHeight) : fitting = !0, b = imageHeight, k = imageWidth; 6654 (k > j || b > I) && l(k, b), d(imageWidth, imageHeight) 6655 } 6656 return { 6657 width: Math.floor(imageWidth), 6658 height: Math.floor(imageHeight), 6659 containerHeight: Math.floor(b), 6660 containerWidth: Math.floor(k) + 2 * settings.horizontal_padding, 6661 contentHeight: Math.floor(y), 6662 contentWidth: Math.floor(w), 6663 resized: resized 6664 } 6665 } 6666 6667 function d(t, i) { 6668 t = parseFloat(t), i = parseFloat(i), $pp_details = $pp_pic_holder.find(".pp_details"), $pp_details.width(t), detailsHeight = parseFloat($pp_details.css("marginTop")) + parseFloat($pp_details.css("marginBottom")), $pp_details = $pp_details.clone().addClass(settings.theme).width(t).appendTo(e("body")).css({ 6669 position: "absolute", 6670 top: -1e4 6671 }), detailsHeight += $pp_details.height(), detailsHeight = detailsHeight <= 34 ? 36 : detailsHeight, $pp_details.remove(), $pp_title = $pp_pic_holder.find(".ppt"), $pp_title.width(t), titleHeight = parseFloat($pp_title.css("marginTop")) + parseFloat($pp_title.css("marginBottom")), $pp_title = $pp_title.clone().appendTo(e("body")).css({ 6672 position: "absolute", 6673 top: -1e4 6674 }), titleHeight += $pp_title.height(), $pp_title.remove(), y = i + detailsHeight, w = t, b = y + titleHeight + $pp_pic_holder.find(".pp_top").height() + $pp_pic_holder.find(".pp_bottom").height(), k = t 6675 } 6676 6677 function h(e) { 6678 return e.match(/youtube\.com\/watch/i) || e.match(/youtu\.be/i) ? "youtube" : e.match(/vimeo\.com/i) ? "vimeo" : e.match(/\b.mov\b/i) ? "quicktime" : e.match(/\b.swf\b/i) ? "flash" : e.match(/\biframe=true\b/i) ? "iframe" : e.match(/\bajax=true\b/i) ? "ajax" : e.match(/\bcustom=true\b/i) ? "custom" : "#" == e.substr(0, 1) ? "inline" : "image" 6679 } 6680 6681 function c() { 6682 if (doresize && "undefined" != typeof $pp_pic_holder) { 6683 if (scroll_pos = _(), contentHeight = $pp_pic_holder.height(), contentwidth = $pp_pic_holder.width(), projectedTop = I / 2 + scroll_pos.scrollTop - contentHeight / 2, projectedTop < 0 && (projectedTop = 0), contentHeight > I) return; 6684 $pp_pic_holder.css({ 6685 top: projectedTop, 6686 left: j / 2 + scroll_pos.scrollLeft - contentwidth / 2 6687 }) 6688 } 6689 } 6690 6691 function _() { 6692 return self.pageYOffset ? { 6693 scrollTop: self.pageYOffset, 6694 scrollLeft: self.pageXOffset 6695 } : document.documentElement && document.documentElement.scrollTop ? { 6696 scrollTop: document.documentElement.scrollTop, 6697 scrollLeft: document.documentElement.scrollLeft 6698 } : document.body ? { 6699 scrollTop: document.body.scrollTop, 6700 scrollLeft: document.body.scrollLeft 6701 } : void 0 6702 } 6703 6704 function g() { 6705 I = e(window).height(), j = e(window).width(), "undefined" != typeof $pp_overlay && $pp_overlay.height(e(document).height()).width(j) 6706 } 6707 6708 function m() { 6709 isSet && settings.overlay_gallery && "image" == h(pp_images[set_position]) ? (itemWidth = 57, navWidth = "facebook" == settings.theme || "pp_default" == settings.theme ? 50 : 30, itemsPerPage = Math.floor((f.containerWidth - 100 - navWidth) / itemWidth), itemsPerPage = itemsPerPage < pp_images.length ? itemsPerPage : pp_images.length, totalPage = Math.
6709ceil(pp_images.length / itemsPerPage) - 1, 0 == totalPage ? (navWidth = 0, $pp_gallery.find(".pp_arrow_next,.pp_arrow_previous").hide()) : $pp_gallery.find(".pp_arrow_next,.pp_arrow_previous").show(), galleryWidth = itemsPerPage * itemWidth, fullGalleryWidth = pp_images.length * itemWidth, $pp_gallery.css("margin-left", -(galleryWidth / 2 + navWidth / 2)).find("div:first").width(galleryWidth + 5).find("ul").width(fullGalleryWidth).find("li.selected").removeClass("selected"), goToPage = Math.floor(set_position / itemsPerPage) < totalPage ? Math.floor(set_position / itemsPerPage) : totalPage, e.prettyPhoto.changeGalleryPage(goToPage), $pp_gallery_li.filter(":eq(" + set_position + ")").addClass("selected")) : $pp_pic_holder.find(".pp_content").unbind("mouseenter mouseleave") 6710 } 6711 6712 function u() { 6713 if (settings.social_tools && (facebook_like_link = settings.social_tools.replace("{location_href}", encodeURIComponent(location.href))), settings.markup = settings.markup.replace("{pp_social}", ""), e("body").append(settings.markup), $pp_pic_holder = e(".pp_pic_holder"), $ppt = e(".ppt"), $pp_overlay
6713= e("div.pp_overlay"), isSet && settings.overlay_gallery) { 6714 currentGalleryPage = 0, toInject = ""; 6715 for (var t = 0; t < pp_images.length; t++) pp_images[t].match(/\b(jpg|jpeg|png|gif)\b/gi) ? (classname = "", img_src = pp_images[t]) : (classname = "default", img_src = ""), toInject += "<li class='" + classname + "'><a href='#'><img src='" + img_src + "' width='50' alt='' /></a></li>"; 6716 toInject = settings.gallery_markup.replace(/{gallery}/g, toInject), $pp_pic_holder.find("#pp_full_res").after(toInject), $pp_gallery = e(".pp_pic_holder .pp_gallery"), $pp_gallery_li = $pp_gallery.find("li"), $pp_gallery.find(".pp_arrow_next").click(function () { 6717 return e.prettyPhoto.changeGalleryPage("next"), e.prettyPhoto.stopSlideshow(), !1 6718 }), $pp_gallery.find(".pp_arrow_previous").click(function () { 6719 return e.prettyPhoto.changeGalleryPage("previous"), e.prettyPhoto.stopSlideshow(), !1 6720 }), $pp_pic_holder.find(".pp_content").hover(function () { 6721 $pp_pic_holder.find(".pp_gallery:not(.disabled)").fadeIn() 6722 }, function () { 6723 $pp_pic_holder.find(".pp_gallery:not(.disabled)").fadeOut() 6724 }), itemWidth = 57, $pp_gallery_li.each(function (t) { 6725 e(this).find("a").click(function () { 6726 return e.prettyPhoto.changePage(t), e.prettyPhoto.stopSlideshow(), !1 6727 }) 6728 }) 6729 } 6730 settings.slideshow && ($pp_pic_holder.find(".pp_nav").prepend('<a href="#" class="pp_play">Play</a>'), $pp_pic_holder.find(".pp_nav .pp_play").click(function () { 6731 return e.prettyPhoto.startSlideshow(), !1 6732 })), $pp_pic_holder.attr("class", "pp_pic_holder " + settings.theme), $pp_overlay.css({ 6733 opacity: 0, 6734 height: e(document).height(), 6735 width: e(window).width() 6736 }).bind("click", function () { 6737 settings.modal || e.prettyPhoto.close() 6738 }), e("a.pp_close").bind("click", function () { 6739 return e.prettyPhoto.close(), !1 6740 }), settings.allow_expand && e("a.pp_expand").bind("click", function () { 6741 return e(this).hasClass("pp_expand") ? (e(this).removeClass("pp_expand").addClass("pp_contract"), doresize = !1) : (e(this).removeClass("pp_contract").addClass("pp_expand"), doresize = !0), n(function () { 6742 e.prettyPhoto.open() 6743 }), !1 6744 }), $pp_pic_holder.find(".pp_previous, .pp_nav .pp_arrow_previous").bind("click", function () { 6745 return e.prettyPhoto.changePage("previous"), e.prettyPhoto.stopSlideshow(), !1 6746 }), $pp_pic_holder.find(".pp_next, .pp_nav .pp_arrow_next").bind("click", function () { 6747 return e.prettyPhoto.changePage("next"), e.prettyPhoto.stopSlideshow(), !1 6748 }), c() 6749 } 6750 a = jQuery.extend({ 6751 hook: "rel", 6752 animation_speed: "fast", 6753 ajaxcallback: function () { }, 6754 slideshow: 5e3, 6755 autoplay_slideshow: !1, 6756 opacity: .8, 6757 show_title: !0, 6758 allow_resize: !0, 6759 allow_expand: !0, 6760 default_width: 500, 6761 default_height: 344, 6762 counter_separator_label: "/", 6763 theme: "pp_default", 6764 horizontal_padding: 20, 6765 hideflash: !1, 6766 wmode: "opaque", 6767 autoplay: !0, 6768 modal: !1, 6769 deeplinking: !0, 6770 overlay_gallery: !0, 6771 overlay_gallery_max: 30, 6772 keyboard_shortcuts: !0, 6773 changepicturecallback: function () { }, 6774 callback: function () { }, 6775 ie6_fallback: !0, 6776 markup: '<div class="pp_pic_holder"> <div class="ppt"> </div> <div class="pp_top"> <div class="pp_left"></div> <div class="pp_middle"></div> <div class="pp_right"></div> </div> <div class="pp_content_container"> <div class="pp_left"> <div class="pp_right"> <div class="pp_content"> <div class="pp_loaderIcon"></div> <div class="pp_fade"> <a href="#" class="pp_expand" title="Expand the image">Expand</a> <div class="pp_hoverContainer"> <a class="pp_next" href="#">next</a> <a class="pp_previous" href="#">previous</a> </div> <div id="pp_full_res"></div> <div class="pp_details"> <div class="pp_nav"> <a href="#" class="pp_arrow_previous">Previous</a> <p class="currentTextHolder">0/0</p> <a href="#" class="pp_arrow_next">Next</a> </div> <p class="pp_description"></p> <div class="pp_social">{pp_social}</div> <a class="pp_close" href="#">Close</a> </div> </div> </div> </div> </div> </div> <div class="pp_bottom"> <div class="pp_left"></div> <div class="pp_middle"></div> <div class="pp_right"></div> </div> </div> <div class="pp_overlay"></div>', 6777 gallery_markup: '<div class="pp_gallery"> <a href="#" class="pp_arrow_previous">Previous</a> <div> <ul> {gallery} </ul> </div> <a href="#" class="pp_arrow_next">Next</a> </div>', 6778 image_markup: '<img id="fullResImage" src="{path}" />', 6779 flash_markup: '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="{width}" height="{height}"><param name="wmode" value="{wmode}" /><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="movie" value="{path}" /><embed src="{path}" type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" width="{width}" height="{height}" wmode="{wmode}"></embed></object>', 6780 quicktime_markup: '<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" codebase="http://www.apple.com/qtactivex/qtplugin.cab" height="{height}" width="{width}"><param name="src" value="{path}"><param name="autoplay" value="{autoplay}"><param name="type" value="video/quicktime"><embed src="{path}" height="{height}" width="{width}" autoplay="{autoplay}" type="video/quicktime" pluginspage="http://www.apple.com/quicktime/download/"></embed></object>', 6781 iframe_markup: '<iframe src ="{path}" width="{width}" height="{height}" frameborder="no"></iframe>', 6782 inline_markup: '<div class="pp_inline">{content}</div>', 6783 custom_markup: "", 6784 social_tools: '<div class="twitter"><a href="http://twitter.com/share" class="twitter-share-button" data-count="none">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div><div class="facebook"><iframe src="//www.facebook.com/plugins/like.php?locale=en_US&href={location_href}&layout=button_count&show_faces=true&width=500&action=like&font&colorscheme=light&height=23" scrolling="no" style="border:none; overflow:hidden; width:500px; height:23px;" allowTransparency="true"></iframe></div>' 6785 }, a); 6786 var f, v, y, w, b, k, P, x = this, 6787 $ = !1, 6788 I = e(window).height(), 6789 j = e(window).width(); 6790 return doresize = !0, scroll_pos = _(), e(window).unbind("resize.prettyphoto").bind("resize.prettyphoto", function () { 6791 c(), g() 6792 }
6792), a.keyboard_shortcuts && e(document).unbind("keydown.prettyphoto").bind("keydown.prettyphoto", function (t) { 6793 if ("undefined" != typeof $pp_pic_holder && $pp_pic_holder.is(":visible")) switch (t.keyCode) { 6794 case 37: 6795 e.prettyPhoto.changePage("previous"), t.preventDefault(); 6796 break; 6797 case 39: 6798 e.prettyPhoto.changePage("next"), t.preventDefault(); 6799 break; 6800 case 27: 6801 settings.modal || e.prettyPhoto.close(), t.preventDefault() 6802 } 6803 }), e.prettyPhoto.initialize = function () { 6804 return settings = a, "pp_default" == settings.theme && (settings.horizontal_padding = 16), theRel = e(this).attr(settings.hook), galleryRegExp = /\[(?:.*)\]/, isSet = galleryRegExp.exec(theRel) ? !0 : !1, pp_images = isSet ? jQuery.map(x, function (t) { 6805 return -1 != e(t).attr(settings.hook).indexOf(theRel) ? e(t).attr("href") : void 0 6806 }) : e.makeArray(e(this).attr("href")), pp_titles = isSet ? jQuery.map(x, function (t) { 6807 return -1 != e(t).attr(settings.hook).indexOf(theRel) ? e(t).find("img").attr("alt") ? e(t).find("img").attr("alt") : "" : void 0 6808 }) : e.makeArray(e(this).find("img").attr("alt")), pp_descriptions = isSet ? jQuery.map(x, function (t) { 6809 return -1 != e(t).attr(settings.hook).indexOf(theRel) ? e(t).attr("title") ? e(t).attr("title") : "" : void 0 6810 }) : e.makeArray(e(this).attr("title")), pp_images.length > settings.overlay_gallery_max && (settings.overlay_gallery = !1), set_position = jQuery.inArray(e(this).attr("href"), pp_images), rel_index = isSet ? set_position : e("a[" + settings.hook + "^='" + theRel + "']").index(e(this)), u(this), settings.allow_resize && e(window).bind("scroll.prettyphoto", function () { 6811 c() 6812 }), e.prettyPhoto.open(), !1 6813 }, e.prettyPhoto.open = function (t) { 6814 return "undefined" == typeof settings && (settings = a, pp_images = e.makeArray(arguments[0]), pp_titles = e.makeArray(arguments[1] ? arguments[1] : ""), pp_descriptions = e.makeArray(arguments[2] ? arguments[2] : ""), isSet = pp_images.length > 1 ? !0 : !1, set_position = arguments[3] ? arguments[3] : 0, u(t.target)), settings.hideflash && e("object,embed,iframe[src*=youtube],iframe[src*=vimeo]").css("visibility", "hidden"), r(e(pp_images).size()), e(".pp_loaderIcon").show(), settings.deeplinking && i(), settings.social_tools && (facebook_like_link = settings.social_tools.replace("{location_href}", encodeURIComponent(location.href)), $pp_pic_holder.find(".pp_social").html(facebook_like_link)), $ppt.is(":hidden") && $ppt.css("opacity", 0).show(), $pp_overlay.show().fadeTo(settings.animation_speed, settings.opacity), $pp_pic_holder.find(".currentTextHolder").text(set_position + 1 + settings.counter_separator_label + e(pp_images).size()), "undefined" != typeof pp_descriptions[set_position] && "" != pp_descriptions[set_position] ? $pp_pic_holder.find(".pp_description").show().html(unescape(pp_descriptions[set_position])) : $pp_pic_holder.find(".pp_description").hide(), movie_width = parseFloat(o("width", pp_images[set_position])) ? o("width", pp_images[set_position]) : settings.default_width.toString(), movie_height = parseFloat(o("height", pp_images[set_position])) ? o("height", pp_images[set_position]) : settings.default_height.toString(), $ = !1, -1 != movie_height.indexOf("%") && (movie_height = parseFloat(e(window).height() * parseFloat(movie_height) / 100 - 150), $ = !0), -1 != movie_width.indexOf("%") && (movie_width = parseFloat(e(window).width() * parseFloat(movie_width) / 100 - 150), $ = !0), $pp_pic_holder.fadeIn(function () { 6815 switch ($ppt.html(settings.show_title && "" != pp_titles[set_position] && "undefined" != typeof pp_titles[set_position] ? unescape(pp_titles[set_position]) : " "), imgPreloader = "", skipInjection = !1, h(pp_images[set_position])) { 6816 case "image": 6817 imgPreloader = new Image, nextImage = new Image, isSet && set_position < e(pp_images).size() - 1 && (nextImage.src = pp_images[set_position + 1]), prevImage = new Image, isSet && pp_images[set_position - 1] && (prevImage.src = pp_images[set_position - 1]), $pp_pic_holder.find("#pp_full_res")[0].innerHTML = settings.image_markup.replace(/{path}/g, pp_images[set_position]), imgPreloader.onload = function () { 6818 f = l(imgPreloader.width, imgPreloader.height), s() 6819 }, imgPreloader.onerror = function () { 6820 alert("Image cannot be loaded. Make sure the path is correct and image exist."), e.prettyPhoto.close() 6821 }, imgPreloader.src = pp_images[set_position]; 6822 break; 6823 case "youtube": 6824 f = l(movie_width, movie_height), movie_id = o("v", pp_images[set_position]), "" == movie_id && (movie_id = pp_images[set_position].split("youtu.be/"), movie_id = movie_id[1], movie_id.indexOf("?") > 0 && (movie_id = movie_id.substr(0, movie_id.indexOf("?"))), movie_id.indexOf("&") > 0 && (movie_id = movie_id.substr(0, movie_id.indexOf("&")))), movie = "http://www.youtube.com/embed/" + movie_id, movie += o("rel", pp_images[set_position]) ? "?rel=" + o("rel", pp_images[set_position]) : "?rel=1", settings.autoplay && (movie += "&autoplay=1"), toInject = settings.iframe_markup.replace(/{width}/g, f.width).replace(/{height}/g, f.height).replace(/{wmode}/g, settings.wmode).replace(/{path}/g, movie); 6825 break; 6826 case "vimeo": 6827 f = l(movie_width, movie_height), movie_id = pp_images[set_position]; 6828 var t = /http(s?):\/\/(www\.)?vimeo.com\/(\d+)/, 6829 i = movie_id.match(t); 6830 movie = "http://player.vimeo.com/video/" + i[3] + "?title=0&byline=0&portrait=0", settings.autoplay && (movie += "&autoplay=1;
6830"), vimeo_width = f.width + "/embed/?moog_width=" + f.width, toInject = settings.iframe_markup.replace(/{width}/g, vimeo_width).replace(/{height}/g, f.height).replace(/{path}/g, movie); 6831 break; 6832 case "quicktime": 6833 f = l(movie_width, movie_height), f.height += 15, f.contentHeight += 15, f.containerHeight += 15, toInject = settings.quicktime_markup.replace(/{width}/g, f.width).replace(/{height}/g, f.height).replace(/{wmode}/g, settings.wmode).replace(/{path}/g, pp_images[set_position]).replace(/{autoplay}/g, settings.autoplay); 6834 break; 6835 case "flash": 6836 f = l(movie_width, movie_height), flash_vars = pp_images[set_position], flash_vars = flash_vars.substring(pp_images[set_position].indexOf("flashvars") + 10, pp_images[set_position].length), filename = pp_images[set_position], filename = filename.substring(0, filename.indexOf("?")), toInject = settings.flash_markup.replace(/{width}/g, f.width).replace(/{height}/g, f.height).replace(/{wmode}/g, settings.wmode).replace(/{path}/g, filename + "?" + flash_vars); 6837 break; 6838 case "iframe": 6839 f = l(movie_width, movie_height), frame_url = pp_images[set_position], frame_url = frame_url.substr(0, frame_url.indexOf("iframe") - 1), toInject = settings.iframe_markup.replace(/{width}/g, f.width).replace(/{height}/g, f.height).replace(/{path}/g, frame_url); 6840 break; 6841 case "ajax": 6842 doresize = !1, f = l(movie_width, movie_height), doresize = !0, skipInjection = !0, e.get(pp_images[set_position], function (e) { 6843 toInject = settings.inline_markup.replace(/{content}/g, e), $pp_pic_holder.find("#pp_full_res")[0].innerHTML = toInject, s() 6844 }); 6845 break; 6846 case "custom": 6847 f = l(movie_width, movie_height), toInject = settings.custom_markup; 6848 break; 6849 case "inline": 6850 myClone = e(pp_images[set_position]).clone().append('<br clear="all" />').css({ 6851 width: settings.default_width 6852 }).wrapInner('<div id="pp_full_res"><div class="pp_inline"></div></div>').appendTo(e("body")).show(), doresize = !1, f = l(e(myClone).width(), e(myClone).height()), doresize = !0, e(myClone).remove(), toInject = settings.inline_markup.replace(/{content}/g, e(pp_images[set_position]).html()) 6853 } 6854 imgPreloader || skipInjection || ($pp_pic_holder.find("#pp_full_res")[0].innerHTML = toInject, s()) 6855 }), !1 6856 }, e.prettyPhoto.changePage = function (t) { 6857 currentGalleryPage = 0, "previous" == t ? (set_position-- , set_position < 0 && (set_position = e(pp_images).size() - 1)) : "next" == t ? (set_position++ , set_position > e(pp_images).size() - 1 && (set_position = 0)) : set_position = t, rel_index = set_position, doresize || (doresize = !0), settings.allow_expand && e(".pp_contract").removeClass("pp_contract").addClass("pp_expand"), n(function () { 6858 e.prettyPhoto.open() 6859 }) 6860 }, e.prettyPhoto.changeGalleryPage = function (e) { 6861 "next" == e ? (currentGalleryPage++ , currentGalleryPage > totalPage && (currentGalleryPage = 0)) : "previous" == e ? (currentGalleryPage-- , currentGalleryPage < 0 && (currentGalleryPage = totalPage)) : currentGalleryPage = e, slide_speed = "next" == e || "previous" == e ? settings.animation_speed : 0, slide_to = currentGalleryPage * itemsPerPage * itemWidth, $pp_gallery.find("ul").animate({ 6862 left: -slide_to 6863 }, slide_speed) 6864 }, e.prettyPhoto.startSlideshow = function () { 6865 "undefined" == typeof P ? ($pp_pic_holder.find(".pp_play").unbind("click").removeClass("pp_play").addClass("pp_pause").click(function () { 6866 return e.prettyPhoto.stopSlideshow(), !1 6867 }), P = setInterval(e.prettyPhoto.startSlideshow, settings.slideshow)) : e.prettyPhoto.changePage("next") 6868 }, e.prettyPhoto.stopSlideshow = function () { 6869 $pp_pic_holder.find(".pp_pause").unbind("click").removeClass("pp_pause").addClass("pp_play").click(function () { 6870 return e.prettyPhoto.startSlideshow(), !1 6871 }), clearInterval(P), P = void 0 6872 }, e.prettyPhoto.close = function () { 6873 $pp_overlay.is(":animated") || (e.prettyPhoto.stopSlideshow(), $pp_pic_holder.stop().find("object,embed").css("visibility", "hidden"), e("div.pp_pic_holder,div.ppt,.pp_fade").fadeOut(settings.animation_speed, function () { 6874 e(this).remove() 6875 }), $pp_overlay.fadeOut(settings.animation_speed, function () { 6876 settings.hideflash && e("object,embed,iframe[src*=youtube],iframe[src*=vimeo]").css("visibility", "visible"), e(this).remove(), e(window).unbind("scroll.prettyphoto"), p(), settings.callback(), doresize = !0, v = !1, delete settings 6877 })) 6878 }, !pp_alreadyInitialized && t() && (pp_alreadyInitialized = !0, hashIndex = t(), hashRel = hashIndex, hashIndex = hashIndex.substring(hashIndex.indexOf("/") + 1, hashIndex.length - 1), hashRel = hashRel.substring(0, hashRel.indexOf("/")), setTimeout(function () { 6879 e("a[" + a.hook + "^='" + hashRel + "']:eq(" + hashIndex + ")").trigger("click") 6880 }, 50)), this.unbind("click.prettyphoto").bind("click.prettyphoto", e.prettyPhoto.initialize) 6881 } 6882}(jQuery); 6883var pp_alreadyInitialized = !1; 6884 6885/* 6886 * equalHeights 6887 * ----------------------------------------------- 6888 */ 6889$.fn.equalHeights = function (e) { 6890 return $(this).each(function () { 6891 var t = 0; 6892 $(this).children().each(function () { 6893 $(this).height() > t && (t = $(this).height()) 6894 }), e && Number.prototype.pxToEm || (t = t.pxToEm()), $.browser.msie && 6 == $.browser.version && $(this).children().css({ 6895 height: t 6896 }), $(this).children().css({ 6897 "min-height": t 6898 }) 6899 }), this 6900}, $.fn.equalWidths = function (e) { 6901 return $(this).each(function () { 6902 var t = 0; 6903 $(this).children().each(function () { 6904 $(this).width() > t && (t = $(this).width()) 6905 }), e && Number.prototype.pxToEm || (t = t.pxToEm()), $.browser.msie && 6 == $.browser.version && $(this).children().css({ 6906 width: t 6907 }), $(this).children().css({ 6908 "min-width": t 6909 }) 6910 }), this 6911}, Number.prototype.pxToEm = String.prototype.pxToEm = function (e) { 6912 e = jQuery.extend({ 6913 scope: "body", 6914 reverse: !1 6915 }, e); 6916 var t, i = "" == this ? 0 : parseFloat(this), 6917 s = function () { 6918 var e = document.documentElement; 6919 return self.innerWidth || e && e.clientWidth || document.body.clientWidth 6920 }; 6921 if ("body" == e.scope && $.browser.msie && (parseFloat($("body").css("font-size")) / s()).toFixed(1) > 0) { 6922 var r = function () { 6923 return 16 * (parseFloat($("body").css("font-size")) / s()).toFixed(3) 6924 }; 6925 t = r() 6926 } else t = parseFloat(jQuery(e.scope).css("font-size")); 6927 var o = 1 == e.reverse ? (i * t).toFixed(2) + "px" : (i / t).toFixed(2) + "em"; 6928 return o 6929}; 6930 6931 6932/* 6933 * Maximage Slider 6934 * ----------------------------------------------- 6935 */ 6936/* 6937 * jQuery Cycle Plugin (with Transition Definitions) 6938 */ 6939(function ($) { 6940 var ver = "2.99";
6941 if ($.support == undefined) { 6942 $.support = { 6943 opacity: !($.browser.msie) 6944 }; 6945 } 6946 6947 function debug(s) { 6948 $.fn.cycle.debug && log(s); 6949 } 6950 6951 function log() { 6952 window.console && console.log && console.log("[cycle] " + Array.prototype.join.call(arguments, " ")); 6953 } 6954 $.expr[":"].paused = function (el) { 6955 return el.cyclePause; 6956 }; 6957 $.fn.cycle = function (options, arg2) { 6958 var o = { 6959 s: this.selector, 6960 c: this.context 6961 }; 6962 if (this.length === 0 && options != "stop") { 6963 if (!$.isReady && o.s) { 6964 log("DOM not ready, queuing slideshow"); 6965 $(function () { 6966 $(o.s, o.c).cycle(options, arg2); 6967 }); 6968 return this; 6969 } 6970 log("terminating; zero elements found by selector" + ($.isReady ? "" : " (DOM not ready)")); 6971 return this; 6972 } 6973 return this.each(function () { 6974 var opts = handleArguments(this, options, arg2); 6975 if (opts === false) { 6976 return; 6977 } 6978 opts.updateActivePagerLink = opts.updateActivePagerLink || $.fn.cycle.updateActivePagerLink; 6979 if (this.cycleTimeout) { 6980 clearTimeout(this.cycleTimeout); 6981 } 6982 this.cycleTimeout = this.cyclePause = 0; 6983 var $cont = $(this); 6984 var $slides = opts.slideExpr ? $(opts.slideExpr, this) : $cont.children(); 6985 var els = $slides.get(); 6986 if (els.length < 2) { 6987 log("terminating; too few slides: " + els.length); 6988 return; 6989 } 6990 var opts2 = buildOptions($cont, $slides, els, opts, o); 6991 if (opts2 === false) { 6992 return; 6993 } 6994 var startTime = opts2.continuous ? 10 : getTimeout(els[opts2.currSlide], els[opts2.nextSlide], opts2, !opts2.backwards); 6995 if (startTime) { 6996 startTime += (opts2.delay || 0); 6997 if (startTime < 10) { 6998 startTime = 10; 6999 } 7000 debug("first timeout: " + startTime); 7001 this.cycleTimeout = setTimeout(function () { 7002 go(els, opts2, 0, !opts.backwards); 7003 }, startTime); 7004 } 7005 }); 7006 }; 7007 7008 function handleArguments(cont, options, arg2) { 7009 if (cont.cycleStop == undefined) { 7010 cont.cycleStop = 0; 7011 } 7012 if (options === undefined || options === null) { 7013 options = {}; 7014 } 7015 if (options.constructor == String) { 7016 switch (options) { 7017 case "destroy": 7018 case "stop": 7019 var opts = $(cont).data("cycle.opts"); 7020 if (!opts) { 7021 return false; 7022 } 7023 cont.cycleStop++; 7024 if (cont.cycleTimeout) { 7025 clearTimeout(cont.cycleTimeout); 7026 } 7027 cont.cycleTimeout = 0; 7028 $(cont).removeData("cycle.opts"); 7029 if (options == "destroy") { 7030 destroy(opts); 7031 } 7032 return false; 7033 case "toggle": 7034 cont.cyclePause = (cont.cyclePause === 1) ? 0 : 1; 7035 checkInstantResume(cont.cyclePause, arg2, cont); 7036 return false; 7037 case "pause": 7038 cont.cyclePause = 1; 7039 return false; 7040 case "resume": 7041 cont.cyclePause = 0; 7042 checkInstantResume(false, arg2, cont); 7043 return false; 7044 case "prev": 7045 case "next": 7046 var opts = $(cont).data("cycle.opts"); 7047 if (!opts) { 7048 log('options not found, "prev/next" ignored'); 7049 return false; 7050 } 7051 $.fn.cycle[options](opts); 7052 return false; 7053 default: 7054 options = { 7055 fx: options 7056 }; 7057 } 7058 return options; 7059 } else { 7060 if (options.constructor == Number) { 7061 var num = options; 7062 options = $(cont).data("cycle.opts"); 7063 if (!options) { 7064 log("options not found, can not advance slide"); 7065 return false; 7066 } 7067 if (num < 0 || num >= options.elements.length) { 7068 log("invalid slide index: " + num); 7069 return false; 7070 } 7071 options.nextSlide = num; 7072 if (cont.cycleTimeout) { 7073 clearTimeout(cont.cycleTimeout); 7074 cont.cycleTimeout = 0; 7075 } 7076 if (typeof arg2 == "string") { 7077 options.oneTimeFx = arg2; 7078 } 7079 go(options.elements, options, 1, num >= options.currSlide); 7080 return false; 7081 } 7082 } 7083 return options; 7084 7085 function checkInstantResume(isPaused, arg2, cont) { 7086 if (!isPaused && arg2 === true) { 7087 var options = $(cont).data("cycle.opts"); 7088 if (!options) { 7089 log("options not found, can not resume"); 7090 return false; 7091 } 7092 if (cont.cycleTimeout) { 7093 clearTimeout(cont.cycleTimeout); 7094 cont.cycleTimeout = 0; 7095 } 7096 go(options.elements, options, 1, !options.backwards); 7097 } 7098 } 7099 } 7100 7101 function removeFilter(el, opts) { 7102 if (!$.support.opacity && opts.cleartype && el.style.filter) { 7103 try { 7104 el.style.removeAttribute("filter"); 7105 } catch (smother) { } 7106 } 7107 } 7108 7109 function destroy(opts) { 7110 if (opts.next) { 7111 $(opts.next).unbind(opts.prevNextEvent); 7112 } 7113 if (opts.prev) { 7114 $(opts.prev).unbind(opts.prevNextEvent); 7115 } 7116 if (opts.pager || opts.pagerAnchorBuilder) { 7117 $.each(opts.pagerAnchors || [], function () { 7118 this.unbind().remove(); 7119 }); 7120 } 7121 opts.pagerAnchors = null; 7122 if (opts.destroy) { 7123 opts.destroy(opts); 7124 } 7125 } 7126 7127 function buildOptions($cont, $slides, els, options, o) { 7128 var opts = $.extend({}, $.fn.cycle.defaults, options || {}, $.metadata ? $cont.metadata() : $.meta ? $cont.data() : {}); 7129 if (opts.autostop) { 7130 opts.countdown = opts.autostopCount || els.length; 7131 } 7132 var cont = $cont[0]; 7133 $cont.data("cycle.opts", opts); 7134 opts.$cont = $cont; 7135 opts.stopCount = cont.cycleStop; 7136 opts.elements = els; 7137 opts.before = opts.before ? [opts.before] : []; 7138 opts.after = opts.after ? [opts.after] : []; 7139 if (!$.support.opacity && opts.cleartype) { 7140 opts.after.push(function () { 7141 removeFilter(this, opts); 7142 }); 7143 } 7144 if (opts.continuous) { 7145 opts.after.push(function () { 7146 go(els, opts, 0, !opts.backwards); 7147 }); 7148 } 7149 saveOriginalOpts(opts); 7150 if (!$.support.opacity && opts.cleartype && !opts.cleartypeNoBg) { 7151 clearTypeFix($slides); 7152 } 7153 if ($cont.css("position") == "static") { 7154 $cont.css("position", "relative"); 7155 } 7156 if (opts.width) { 7157 $cont.width(opts.width); 7158 } 7159 if (opts.height && opts.height != "auto") { 7160 $cont.height(opts.height); 7161 } 7162 if (opts.startingSlide) { 7163 opts.startingSlide = parseInt(opts.startingSlide); 7164 } else { 7165 if (opts.backwards) { 7166 opts.startingSlide = els.length - 1; 7167 } 7168 } 7169 if (opts.random) { 7170 opts.randomMap = []; 7171 for (var i = 0; i < els.length; i++) { 7172 opts.randomMap.push(i); 7173 } 7174 opts.randomMap.sort(function (a, b) { 7175 return Math.random() - 0.5; 7176 }); 7177 opts.randomIndex = 1; 7178 opts.startingSlide = opts.randomMap[1]; 7179 } else { 7180 if (opts.startingSlide >= els.length) { 7181 opts.startingSlide = 0; 7182 } 7183 } 7184 opts.currSlide = opts.startingSlide || 0; 7185 var first = opts.startingSlide; 7186 $slides.css({ 7187 position: "absolute",
7188 top: 0, 7189 left: 0 7190 }).hide().each(function (i) { 7191 var z; 7192 if (opts.backwards) { 7193 z = first ? i <= first ? els.length + (i - first) : first - i : els.length - i; 7194 } else { 7195 z = first ? i >= first ? els.length - (i - first) : first - i : els.length - i; 7196 } 7197 $(this).css("z-index", z); 7198 }); 7199 $(els[first]).css("opacity", 1).show(); 7200 removeFilter(els[first], opts); 7201 if (opts.fit && opts.width) { 7202 $slides.width(opts.width); 7203 } 7204 if (opts.fit && opts.height && opts.height != "auto") { 7205 $slides.height(opts.height); 7206 } 7207 var reshape = opts.containerResize && !$cont.innerHeight(); 7208 if (reshape) { 7209 var maxw = 0, 7210 maxh = 0; 7211 for (var j = 0; j < els.length; j++) { 7212 var $e = $(els[j]), 7213 e = $e[0], 7214 w = $e.outerWidth(), 7215 h = $e.outerHeight(); 7216 if (!w) { 7217 w = e.offsetWidth || e.width || $e.attr("width"); 7218 } 7219 if (!h) { 7220 h = e.offsetHeight || e.height || $e.attr("height"); 7221 } 7222 maxw = w > maxw ? w : maxw; 7223 maxh = h > maxh ? h : maxh; 7224 } 7225 if (maxw > 0 && maxh > 0) { 7226 $cont.css({ 7227 width: maxw + "px", 7228 height: maxh + "px" 7229 }); 7230 } 7231 } 7232 if (opts.pause) { 7233 $cont.hover(function () { 7234 this.cyclePause++; 7235 }, function () { 7236 this.cyclePause--; 7237 }); 7238 } 7239 if (supportMultiTransitions(opts) === false) { 7240 return false; 7241 } 7242 var requeue = false; 7243 options.requeueAttempts = options.requeueAttempts || 0; 7244 $slides.each(function () { 7245 var $el = $(this); 7246 this.cycleH = (opts.fit && opts.height) ? opts.height : ($el.height() || this.offsetHeight || this.height || $el.attr("height") || 0); 7247 this.cycleW = (opts.fit && opts.width) ? opts.width : ($el.width() || this.offsetWidth || this.width || $el.attr("width") || 0); 7248 if ($el.is("thumb")) { 7249 var loadingIE = ($.browser.msie && this.cycleW == 28 && this.cycleH == 30 && !this.complete); 7250 var loadingFF = ($.browser.mozilla && this.cycleW == 34 && this.cycleH == 19 && !this.complete); 7251 var loadingOp = ($.browser.opera && ((this.cycleW == 42 && this.cycleH == 19) || (this.cycleW == 37 && this.cycleH == 17)) && !this.complete); 7252 var loadingOther = (this.cycleH == 0 && this.cycleW == 0 && !this.complete); 7253 if (loadingIE || loadingFF || loadingOp || loadingOther) { 7254 if (o.s && opts.requeueOnImageNotLoaded && ++options.requeueAttempts < 100) { 7255 log(options.requeueAttempts, " - img slide not loaded, requeuing slideshow: ", this.src, this.cycleW, this.cycleH); 7256 setTimeout(function () { 7257 $(o.s, o.c).cycle(options); 7258 }, opts.requeueTimeout); 7259 requeue = true; 7260 return false; 7261 } else { 7262 log("could not determine size of image: " + this.src, this.cycleW, this.cycleH); 7263 } 7264 } 7265 } 7266 return true; 7267 }); 7268 if (requeue) { 7269 return false; 7270 } 7271 opts.cssBefore = opts.cssBefore || {}; 7272 opts.cssAfter = opts.cssAfter || {}; 7273 opts.cssFirst = opts.cssFirst || {}; 7274 opts.animIn = opts.animIn || {}; 7275 opts.animOut = opts.animOut || {}; 7276 $slides.not(":eq(" + first + ")").css(opts.cssBefore); 7277 $($slides[first]).css(opts.cssFirst); 7278 if (opts.timeout) { 7279 opts.timeout = parseInt(opts.timeout); 7280 if (opts.speed.constructor == String) { 7281 opts.speed = $.fx.speeds[opts.speed] || parseInt(opts.speed); 7282 } 7283 if (!opts.sync) { 7284 opts.speed = opts.speed / 2; 7285 } 7286 var buffer = opts.fx == "none" ? 0 : opts.fx == "shuffle" ? 500 : 250; 7287 while ((opts.timeout - opts.speed) < buffer) { 7288 opts.timeout += opts.speed; 7289 } 7290 } 7291 if (opts.easing) { 7292 opts.easeIn = opts.easeOut = opts.easing; 7293 } 7294 if (!opts.speedIn) { 7295 opts.speedIn = opts.speed; 7296 } 7297 if (!opts.speedOut) { 7298 opts.speedOut = opts.speed; 7299 } 7300 opts.slideCount = els.length; 7301 opts.currSlide = opts.lastSlide = first; 7302 if (opts.random) { 7303 if (++opts.randomIndex == els.length) { 7304 opts.randomIndex = 0; 7305 } 7306 opts.nextSlide = opts.randomMap[opts.randomIndex]; 7307 } else { 7308 if (opts.backwards) { 7309 opts.nextSlide = opts.startingSlide == 0 ? (els.length - 1) : opts.startingSlide - 1; 7310 } else { 7311 opts.nextSlide = opts.startingSlide >= (els.length - 1) ? 0 : opts.startingSlide + 1; 7312 } 7313 } 7314 if (!opts.multiFx) { 7315 var init = $.fn.cycle.transitions[opts.fx]; 7316 if ($.isFunction(init)) { 7317 init($cont, $slides, opts); 7318 } else { 7319 if (opts.fx != "custom" && !opts.multiFx) { 7320 log("unknown transition: " + opts.fx, "; slideshow terminating"); 7321 return false; 7322 } 7323 } 7324 } 7325 var e0 = $slides[first]; 7326 if (opts.before.length) { 7327 opts.before[0].apply(e0, [e0, e0, opts, true]); 7328 } 7329 if (opts.after.length) { 7330 opts.after[0].apply(e0, [e0, e0, opts, true]); 7331 } 7332 if (opts.next) { 7333 $(opts.next).bind(opts.prevNextEvent, function () { 7334 return advance(opts, 1); 7335 }); 7336 } 7337 if (opts.prev) { 7338 $(opts.prev).bind(opts.prevNextEvent, function () { 7339 return advance(opts, 0); 7340 }); 7341 } 7342 if (opts.pager || opts.pagerAnchorBuilder) { 7343 buildPager(els, opts); 7344 } 7345 exposeAddSlide(opts, els); 7346 return opts; 7347 } 7348 7349 function saveOriginalOpts(opts) { 7350 opts.original = { 7351 before: [], 7352 after: [] 7353 }; 7354 opts.original.cssBefore = $.extend({}, opts.cssBefore); 7355 opts.original.cssAfter = $.extend({}, opts.cssAfter); 7356 opts.original.animIn = $.extend({}, opts.animIn); 7357 opts.original.animOut = $.extend({}, opts.animOut); 7358 $.each(opts.before, function () { 7359 opts.original.before.push(this); 7360 }); 7361 $.each(opts.after, function () { 7362 opts.original.after.push(this); 7363 }); 7364 } 7365 7366 function supportMultiTransitions(opts) { 7367 var i, tx, txs = $.fn.cycle.transitions; 7368 if (opts.fx.indexOf(",") > 0) { 7369 opts.multiFx = true; 7370 opts.fxs = opts.fx.replace(/\s*/g, "").split(","); 7371 for (i = 0; i < opts.fxs.length; i++) { 7372 var fx = opts.fxs[i]; 7373 tx = txs[fx]; 7374 if (!tx || !txs.hasOwnProperty(fx) || !$.isFunction(tx)) { 7375 log("discarding unknown transition: ", fx); 7376 opts.fxs.splice(i, 1); 7377 i--; 7378 } 7379 } 7380 if (!opts.fxs.length) { 7381 log("No valid transitions named; slideshow terminating."); 7382 return false; 7383 } 7384 } else { 7385 if (opts.fx == "all") { 7386 opts.multiFx = true; 7387 opts.fxs = []; 7388 for (p in txs) { 7389 tx = txs[p]; 7390 if (txs.hasOwnProperty(p) && $.isFunction(tx)) { 7391 opts.fxs.push(p); 7392 } 7393 } 7394 } 7395 } 7396 if (opts.multiFx && opts.randomizeEffects) { 7397 var r1 = Math.floor(Math.random() * 20) + 30; 7398 for (i = 0; i < r1; i++) { 7399 var r2 = Math.floor(Math.random() * opts.fxs.length); 7400 opts.fxs.push(opts.fxs.splice(r2, 1)[0]); 7401 } 7402 debug("randomized fx sequence: ", opts.fxs); 7403 } 7404 return true; 7405 } 7406 7407 function exposeAddSlide(opts, els) {
7408 opts.addSlide = function (newSlide, prepend) { 7409 var $s = $(newSlide), 7410 s = $s[0]; 7411 if (!opts.autostopCount) { 7412 opts.countdown++; 7413 } 7414 els[prepend ? "unshift" : "push"](s); 7415 if (opts.els) { 7416 opts.els[prepend ? "unshift" : "push"](s); 7417 } 7418 opts.slideCount = els.length; 7419 $s.css("position", "absolute"); 7420 $s[prepend ? "prependTo" : "appendTo"](opts.$cont); 7421 if (prepend) { 7422 opts.currSlide++; 7423 opts.nextSlide++; 7424 } 7425 if (!$.support.opacity && opts.cleartype && !opts.cleartypeNoBg) { 7426 clearTypeFix($s); 7427 } 7428 if (opts.fit && opts.width) { 7429 $s.width(opts.width); 7430 } 7431 if (opts.fit && opts.height && opts.height != "auto") { 7432 $s.height(opts.height); 7433 } 7434 s.cycleH = (opts.fit && opts.height) ? opts.height : $s.height(); 7435 s.cycleW = (opts.fit && opts.width) ? opts.width : $s.width(); 7436 $s.css(opts.cssBefore); 7437 if (opts.pager || opts.pagerAnchorBuilder) { 7438 $.fn.cycle.createPagerAnchor(els.length - 1, s, $(opts.pager), els, opts); 7439 } 7440 if ($.isFunction(opts.onAddSlide)) { 7441 opts.onAddSlide($s); 7442 } else { 7443 $s.hide(); 7444 } 7445 }; 7446 } 7447 $.fn.cycle.resetState = function (opts, fx) { 7448 fx = fx || opts.fx; 7449 opts.before = []; 7450 opts.after = []; 7451 opts.cssBefore = $.extend({}, opts.original.cssBefore); 7452 opts.cssAfter = $.extend({}, opts.original.cssAfter); 7453 opts.animIn = $.extend({}, opts.original.animIn); 7454 opts.animOut = $.extend({}, opts.original.animOut); 7455 opts.fxFn = null; 7456 $.each(opts.original.before, function () { 7457 opts.before.push(this); 7458 }); 7459 $.each(opts.original.after, function () { 7460 opts.after.push(this); 7461 }); 7462 var init = $.fn.cycle.transitions[fx]; 7463 if ($.isFunction(init)) { 7464 init(opts.$cont, $(opts.elements), opts); 7465 } 7466 }; 7467 7468 function go(els, opts, manual, fwd) { 7469 if (manual && opts.busy && opts.manualTrump) { 7470 debug("manualTrump in go(), stopping active transition"); 7471 $(els).stop(true, true); 7472 opts.busy = 0; 7473 } 7474 if (opts.busy) { 7475 debug("transition active, ignoring new tx request"); 7476 return; 7477 } 7478 var p = opts.$cont[0], 7479 curr = els[opts.currSlide], 7480 next = els[opts.nextSlide]; 7481 if (p.cycleStop != opts.stopCount || p.cycleTimeout === 0 && !manual) { 7482 return; 7483 } 7484 if (!manual && !p.cyclePause && !opts.bounce && ((opts.autostop && (--opts.countdown <= 0)) || (opts.nowrap && !opts.random && opts.nextSlide < opts.currSlide))) { 7485 if (opts.end) { 7486 opts.end(opts); 7487 } 7488 return; 7489 } 7490 var changed = false; 7491 if ((manual || !p.cyclePause) && (opts.nextSlide != opts.currSlide)) { 7492 changed = true; 7493 var fx = opts.fx; 7494 curr.cycleH = curr.cycleH || $(curr).height(); 7495 curr.cycleW = curr.cycleW || $(curr).width(); 7496 next.cycleH = next.cycleH || $(next).height(); 7497 next.cycleW = next.cycleW || $(next).width(); 7498 if (opts.multiFx) { 7499 if (opts.lastFx == undefined || ++opts.lastFx >= opts.fxs.length) { 7500 opts.lastFx = 0; 7501 } 7502 fx = opts.fxs[opts.lastFx]; 7503 opts.currFx = fx; 7504 } 7505 if (opts.oneTimeFx) { 7506 fx = opts.oneTimeFx; 7507 opts.oneTimeFx = null; 7508 } 7509 $.fn.cycle.resetState(opts, fx); 7510 if (opts.before.length) { 7511 $.each(opts.before, function (i, o) { 7512 if (p.cycleStop != opts.stopCount) { 7513 return; 7514 } 7515 o.apply(next, [curr, next, opts, fwd]); 7516 }); 7517 } 7518 var after = function () { 7519 opts.busy = 0; 7520 $.each(opts.after, function (i, o) { 7521 if (p.cycleStop != opts.stopCount) { 7522 return; 7523 } 7524 o.apply(next, [curr, next, opts, fwd]); 7525 }); 7526 }; 7527 debug("tx firing(" + fx + "); currSlide: " + opts.currSlide + "; nextSlide: " + opts.nextSlide); 7528 opts.busy = 1; 7529 if (opts.fxFn) { 7530 opts.fxFn(curr, next, opts, after, fwd, manual && opts.fastOnEvent); 7531 } else { 7532 if ($.isFunction($.fn.cycle[opts.fx])) { 7533 $.fn.cycle[opts.fx](curr, next, opts, after, fwd, manual && opts.fastOnEvent); 7534 } else { 7535 $.fn.cycle.custom(curr, next, opts, after, fwd, manual && opts.fastOnEvent); 7536 } 7537 } 7538 } 7539 if (changed || opts.nextSlide == opts.currSlide) { 7540 opts.lastSlide = opts.currSlide; 7541 if (opts.random) { 7542 opts.currSlide = opts.nextSlide; 7543 if (++opts.randomIndex == els.length) { 7544 opts.randomIndex = 0; 7545 } 7546 opts.nextSlide = opts.randomMap[opts.randomIndex]; 7547 if (opts.nextSlide == opts.currSlide) { 7548 opts.nextSlide = (opts.currSlide == opts.slideCount - 1) ? 0 : opts.currSlide + 1; 7549 } 7550 } else { 7551 if (opts.backwards) { 7552 var roll = (opts.nextSlide - 1) < 0; 7553 if (roll && opts.bounce) { 7554 opts.backwards = !opts.backwards; 7555 opts.nextSlide = 1; 7556 opts.currSlide = 0; 7557 } else { 7558 opts.nextSlide = roll ? (els.length - 1) : opts.nextSlide - 1; 7559 opts.currSlide = roll ? 0 : opts.nextSlide + 1; 7560 } 7561 } else { 7562 var roll = (opts.nextSlide + 1) == els.length; 7563 if (roll && opts.bounce) { 7564 opts.backwards = !opts.backwards; 7565 opts.nextSlide = els.length - 2; 7566 opts.currSlide = els.length - 1; 7567 } else { 7568 opts.nextSlide = roll ? 0 : opts.nextSlide + 1; 7569 opts.currSlide = roll ? els.length - 1 : opts.nextSlide - 1; 7570 } 7571 } 7572 } 7573 } 7574 if (changed && opts.pager) { 7575 opts.updateActivePagerLink(opts.pager, opts.currSlide, opts.activePagerClass); 7576 } 7577 var ms = 0; 7578 if (opts.timeout && !opts.continuous) { 7579 ms = getTimeout(els[opts.currSlide], els[opts.nextSlide], opts, fwd); 7580 } else { 7581 if (opts.continuous && p.cyclePause) { 7582 ms = 10; 7583 } 7584 } 7585 if (ms > 0) { 7586 p.cycleTimeout = setTimeout(function () { 7587 go(els, opts, 0, !opts.backwards); 7588 }, ms); 7589 } 7590 } 7591 $.fn.cycle.updateActivePagerLink = function (pager, currSlide, clsName) { 7592 $(pager).each(function () { 7593 $(this).children().removeClass(clsName).eq(currSlide).addClass(clsName); 7594 }); 7595 }; 7596 7597 function getTimeout(curr, next, opts, fwd) { 7598 if (opts.timeoutFn) { 7599 var t = opts.timeoutFn.call(curr, curr, next, opts, fwd); 7600 while (opts.fx != "none" && (t - opts.speed) < 250) { 7601 t += opts.speed; 7602 }
7603 debug("calculated timeout: " + t + "; speed: " + opts.speed); 7604 if (t !== false) { 7605 return t; 7606 } 7607 } 7608 return opts.timeout; 7609 } 7610 $.fn.cycle.next = function (opts) { 7611 advance(opts, 1); 7612 }; 7613 $.fn.cycle.prev = function (opts) { 7614 advance(opts, 0); 7615 }; 7616 7617 function advance(opts, moveForward) { 7618 var val = moveForward ? 1 : -1; 7619 var els = opts.elements; 7620 var p = opts.$cont[0], 7621 timeout = p.cycleTimeout; 7622 if (timeout) { 7623 clearTimeout(timeout); 7624 p.cycleTimeout = 0; 7625 } 7626 if (opts.random && val < 0) { 7627 opts.randomIndex--; 7628 if (--opts.randomIndex == -2) { 7629 opts.randomIndex = els.length - 2; 7630 } else { 7631 if (opts.randomIndex == -1) { 7632 opts.randomIndex = els.length - 1; 7633 } 7634 } 7635 opts.nextSlide = opts.randomMap[opts.randomIndex]; 7636 } else { 7637 if (opts.random) { 7638 opts.nextSlide = opts.randomMap[opts.randomIndex]; 7639 } else { 7640 opts.nextSlide = opts.currSlide + val; 7641 if (opts.nextSlide < 0) { 7642 if (opts.nowrap) { 7643 return false; 7644 } 7645 opts.nextSlide = els.length - 1; 7646 } else { 7647 if (opts.nextSlide >= els.length) { 7648 if (opts.nowrap) { 7649 return false; 7650 } 7651 opts.nextSlide = 0; 7652 } 7653 } 7654 } 7655 } 7656 var cb = opts.onPrevNextEvent || opts.prevNextClick; 7657 if ($.isFunction(cb)) { 7658 cb(val > 0, opts.nextSlide, els[opts.nextSlide]); 7659 } 7660 go(els, opts, 1, moveForward); 7661 return false; 7662 } 7663 7664 function buildPager(els, opts) { 7665 var $p = $(opts.pager); 7666 $.each(els, function (i, o) { 7667 $.fn.cycle.createPagerAnchor(i, o, $p, els, opts); 7668 }); 7669 opts.updateActivePagerLink(opts.pager, opts.startingSlide, opts.activePagerClass); 7670 } 7671 $.fn.cycle.createPagerAnchor = function (i, el, $p, els, opts) { 7672 var a; 7673 if ($.isFunction(opts.pagerAnchorBuilder)) { 7674 a = opts.pagerAnchorBuilder(i, el); 7675 debug("pagerAnchorBuilder(" + i + ", el) returned: " + a);
7676 } else { 7677 a = '<a href="#">' + (i + 1) + "</a>"; 7678 } 7679 if (!a) { 7680 return; 7681 } 7682 var $a = $(a); 7683 if ($a.parents("body").length === 0) { 7684 var arr = []; 7685 if ($p.length > 1) { 7686 $p.each(function () { 7687 var $clone = $a.clone(true); 7688 $(this).append($clone); 7689 arr.push($clone[0]); 7690 }); 7691 $a = $(arr); 7692 } else { 7693 $a.appendTo($p); 7694 } 7695 } 7696 opts.pagerAnchors = opts.pagerAnchors || []; 7697 opts.pagerAnchors.push($a); 7698 $a.bind(opts.pagerEvent, function (e) { 7699 e.preventDefault(); 7700 opts.nextSlide = i; 7701 var p = opts.$cont[0], 7702 timeout = p.cycleTimeout; 7703 if (timeout) { 7704 clearTimeout(timeout); 7705 p.cycleTimeout = 0; 7706 } 7707 var cb = opts.onPagerEvent || opts.pagerClick; 7708 if ($.isFunction(cb)) { 7709 cb(opts.nextSlide, els[opts.nextSlide]); 7710 } 7711 go(els, opts, 1, opts.currSlide < i); 7712 }); 7713 if (!/^click/.test(opts.pagerEvent) && !opts.allowPagerClickBubble) { 7714 $a.bind("click.cycle", function () { 7715 return false; 7716 }); 7717 } 7718 if (opts.pauseOnPagerHover) { 7719 $a.hover(function () { 7720 opts.$cont[0].cyclePause++; 7721 }, function () { 7722 opts.$cont[0].cyclePause--; 7723 }); 7724 } 7725 }; 7726 $.fn.cycle.hopsFromLast = function (opts, fwd) { 7727 var hops, l = opts.lastSlide, 7728 c = opts.currSlide; 7729 if (fwd) { 7730 hops = c > l ? c - l : opts.slideCount - l; 7731 } else { 7732 hops = c < l ? l - c : l + opts.slideCount - c; 7733 } 7734 return hops; 7735 }; 7736 7737 function clearTypeFix($slides) { 7738 debug("applying clearType background-color hack"); 7739 7740 function hex(s) { 7741 s = parseInt(s).toString(16); 7742 return s.length < 2 ? "0" + s : s; 7743 } 7744 7745 function getBg(e) { 7746 for (; e && e.nodeName.toLowerCase() != "html"; e = e.parentNode) { 7747 var v = $.css(e, "background-color"); 7748 if (v && v.indexOf("rgb") >= 0) { 7749 var rgb = v.match(/\d+/g); 7750 return "#" + hex(rgb[0]) + hex(rgb[1]) + hex(rgb[2]); 7751 } 7752 if (v && v != "transparent") { 7753 return v; 7754 } 7755 } 7756 return "#ffffff"; 7757 } 7758 $slides.each(function () { 7759 $(this).css("background-color", getBg(this)); 7760 }); 7761 } 7762 $.fn.cycle.commonReset = function (curr, next, opts, w, h, rev) { 7763 $(opts.elements).not(curr).hide(); 7764 if (typeof opts.cssBefore.opacity == "undefined") { 7765 opts.cssBefore.opacity = 1; 7766 } 7767 opts.cssBefore.display = "block"; 7768 if (opts.slideResize && w !== false && next.cycleW > 0) { 7769 opts.cssBefore.width = next.cycleW; 7770 } 7771 if (opts.slideResize && h !== false && next.cycleH > 0) { 7772 opts.cssBefore.height = next.cycleH; 7773 } 7774 opts.cssAfter = opts.cssAfter || {}; 7775 opts.cssAfter.display = "none"; 7776 $(curr).css("zIndex", opts.slideCount + (rev === true ? 1 : 0)); 7777 $(next).css("zIndex", opts.slideCount + (rev === true ? 0 : 1)); 7778 }; 7779 $.fn.cycle.custom = function (curr, next, opts, cb, fwd, speedOverride) { 7780 var $l = $(curr), 7781 $n = $(next); 7782 var speedIn = opts.speedIn, 7783 speedOut = opts.speedOut, 7784 easeIn = opts.easeIn, 7785 easeOut = opts.easeOut; 7786 $n.css(opts.cssBefore); 7787 if (speedOverride) { 7788 if (typeof speedOverride == "number") { 7789 speedIn = speedOut = speedOverride; 7790 } else { 7791 speedIn = speedOut = 1; 7792 } 7793 easeIn = easeOut = null; 7794 } 7795 var fn = function () { 7796 $n.animate(opts.animIn, speedIn, easeIn, function () { 7797 cb(); 7798 }); 7799 }; 7800 $l.animate(opts.animOut, speedOut, easeOut, function () { 7801 $l.css(opts.cssAfter); 7802 if (!opts.sync) { 7803 fn(); 7804 } 7805 }); 7806 if (opts.sync) { 7807 fn(); 7808 } 7809 }; 7810 $.fn.cycle.transitions = { 7811 fade: function ($cont, $slides, opts) { 7812 $slides.not(":eq(" + opts.currSlide + ")").css("opacity", 0); 7813 opts.before.push(function (curr, next, opts) { 7814 $.fn.cycle.commonReset(curr, next, opts); 7815 opts.cssBefore.opacity = 0; 7816 }); 7817 opts.animIn = { 7818 opacity: 1 7819 }; 7820 opts.animOut = { 7821 opacity: 0 7822 }; 7823 opts.cssBefore = { 7824 top: 0, 7825 left: 0 7826 }; 7827 } 7828 }; 7829 $.fn.cycle.ver = function () { 7830 return ver; 7831 }; 7832 $.fn.cycle.defaults = { 7833 activePagerClass: "activeSlide", 7834 after: null, 7835 allowPagerClickBubble: false, 7836 animIn: null, 7837 animOut: null, 7838 autostop: 0, 7839 autostopCount: 0, 7840 backwards: false, 7841 before: null, 7842 cleartype: !$.support.opacity, 7843 cleartypeNoBg: false, 7844 containerResize: 1, 7845 continuous: 0, 7846 cssAfter: null, 7847 cssBefore: null, 7848 delay: 0,
7849 easeIn: null, 7850 easeOut: null, 7851 easing: null, 7852 end: null, 7853 fastOnEvent: 0, 7854 fit: 0, 7855 fx: "fade", 7856 fxFn: null, 7857 height: "auto", 7858 manualTrump: true, 7859 next: null, 7860 nowrap: 0, 7861 onPagerEvent: null, 7862 onPrevNextEvent: null, 7863 pager: null, 7864 pagerAnchorBuilder: null, 7865 pagerEvent: "click.cycle", 7866 pause: 0, 7867 pauseOnPagerHover: 0, 7868 prev: null, 7869 prevNextEvent: "click.cycle", 7870 random: 0, 7871 randomizeEffects: 1, 7872 requeueOnImageNotLoaded: true, 7873 requeueTimeout: 250, 7874 rev: 0, 7875 shuffle: null, 7876 slideExpr: null, 7877 slideResize: 1, 7878 speed: 1000, 7879 speedIn: null, 7880 speedOut: null, 7881 startingSlide: 0, 7882 sync: 1, 7883 timeout: 4000, 7884 timeoutFn: null, 7885 updateActivePagerLink: null 7886 }; 7887})(jQuery); 7888/* 7889 * jQuery Cycle Plugin Transition Definitions 7890 */ 7891(function ($) { 7892 $.fn.cycle.transitions.none = function ($cont, $slides, opts) { 7893 opts.fxFn = function (curr, next, opts, after) { 7894 $(next).show(); 7895 $(curr).hide(); 7896 after(); 7897 }; 7898 }; 7899 $.fn.cycle.transitions.fadeout = function ($cont, $slides, opts) { 7900 $slides.not(":eq(" + opts.currSlide + ")").css({ 7901 display: "block", 7902 opacity: 1 7903 }); 7904 opts.before.push(function (curr, next, opts, w, h, rev) { 7905 $(curr).css("zIndex", opts.slideCount + (!rev === true ? 1 : 0)); 7906 $(next).css("zIndex", opts.slideCount + (!rev === true ? 0 : 1)); 7907 }); 7908 opts.animIn.opacity = 1; 7909 opts.animOut.opacity = 0; 7910 opts.cssBefore.opacity = 1; 7911 opts.cssBefore.display = "block"; 7912 opts.cssAfter.zIndex = 0; 7913 }; 7914 $.fn.cycle.transitions.scrollUp = function ($cont, $slides, opts) { 7915 $cont.css("overflow", "hidden"); 7916 opts.before.push($.fn.cycle.commonReset); 7917 var h = $cont.height(); 7918 opts.cssBefore.top = h; 7919 opts.cssBefore.left = 0; 7920 opts.cssFirst.top = 0; 7921 opts.animIn.top = 0; 7922 opts.animOut.top = -h; 7923 }; 7924 $.fn.cycle.transitions.scrollDown = function ($cont, $slides, opts) { 7925 $cont.css("overflow", "hidden"); 7926 opts.before.push($.fn.cycle.commonReset); 7927 var h = $cont.height(); 7928 opts.cssFirst.top = 0; 7929 opts.cssBefore.top = -h; 7930 opts.cssBefore.left = 0; 7931 opts.animIn.top = 0; 7932 opts.animOut.top = h; 7933 }; 7934 $.fn.cycle.transitions.scrollLeft = function ($cont, $slides, opts) { 7935 $cont.css("overflow", "hidden"); 7936 opts.before.push($.fn.cycle.commonReset); 7937 var w = $cont.width(); 7938 opts.cssFirst.left = 0; 7939 opts.cssBefore.left = w; 7940 opts.cssBefore.top = 0; 7941 opts.animIn.left = 0; 7942 opts.animOut.left = 0 - w; 7943 }; 7944 $.fn.cycle.transitions.scrollRight = function ($cont, $slides, opts) { 7945 $cont.css("overflow", "hidden"); 7946 opts.before.push($.fn.cycle.commonReset); 7947 var w = $cont.width(); 7948 opts.cssFirst.left = 0; 7949 opts.cssBefore.left = -w; 7950 opts.cssBefore.top = 0; 7951 opts.animIn.left = 0; 7952 opts.animOut.left = w; 7953 }; 7954 $.fn.cycle.transitions.scrollHorz = function ($cont, $slides, opts) { 7955 $cont.css("overflow", "hidden").width(); 7956 opts.before.push(function (curr, next, opts, fwd) { 7957 if (opts.rev) { 7958 fwd = !fwd; 7959 } 7960 $.fn.cycle.commonReset(curr, next, opts); 7961 opts.cssBefore.left = fwd ? (next.cycleW - 1) : (1 - next.cycleW); 7962 opts.animOut.left = fwd ? -curr.cycleW : curr.cycleW; 7963 }); 7964 opts.cssFirst.left = 0; 7965 opts.cssBefore.top = 0; 7966 opts.animIn.left = 0; 7967 opts.animOut.top = 0; 7968 }; 7969 $.fn.cycle.transitions.scrollVert = function ($cont, $slides, opts) { 7970 $cont.css("overflow", "hidden"); 7971 opts.before.push(function (curr, next, opts, fwd) { 7972 if (opts.rev) { 7973 fwd = !fwd; 7974 } 7975 $.fn.cycle.commonReset(curr, next, opts); 7976 opts.cssBefore.top = fwd ? (1 - next.cycleH) : (next.cycleH - 1); 7977 opts.animOut.top = fwd ? curr.cycleH : -curr.cycleH; 7978 }); 7979 opts.cssFirst.top = 0; 7980 opts.cssBefore.left = 0; 7981 opts.animIn.top = 0; 7982 opts.animOut.left = 0; 7983 }; 7984 $.fn.cycle.transitions.slideX = function ($cont, $slides, opts) { 7985 opts.before.push(function (curr, next, opts) { 7986 $(opts.elements).not(curr).hide(); 7987 $.fn.cycle.commonReset(curr, next, opts, false, true); 7988 opts.animIn.width = next.cycleW; 7989 }); 7990 opts.cssBefore.left = 0; 7991 opts.cssBefore.top = 0; 7992 opts.cssBefore.width = 0; 7993 opts.animIn.width = "show"; 7994 opts.animOut.width = 0; 7995 }; 7996 $.fn.cycle.transitions.slideY = function ($cont, $slides, opts) { 7997 opts.before.push(function (curr, next, opts) { 7998 $(opts.elements).not(curr).hide(); 7999 $.fn.cycle.commonReset(curr, next, opts, true, false); 8000 opts.animIn.height = next.cycleH; 8001 }); 8002 opts.cssBefore.left = 0; 8003 opts.cssBefore.top = 0; 8004 opts.cssBefore.height = 0; 8005 opts.animIn.height = "show"; 8006 opts.animOut.height = 0; 8007 }; 8008 $.fn.cycle.transitions.shuffle = function ($cont, $slides, opts) { 8009 var i, w = $cont.css("overflow", "visible").width(); 8010 $slides.css({ 8011 left: 0, 8012 top: 0 8013 }); 8014 opts.before.push(function (curr, next, opts) { 8015 $.fn.cycle.commonReset(curr, next, opts, true, true, true); 8016 }); 8017 if (!opts.speedAdjusted) { 8018 opts.speed = opts.speed / 2; 8019 opts.speedAdjusted = true; 8020 } 8021 opts.random = 0; 8022 opts.shuffle = opts.shuffle || { 8023 left: -w, 8024 top: 15 8025 }; 8026 opts.els = []; 8027 for (i = 0; i < $slides.length; i++) { 8028 opts.els.push($slides[i]); 8029 } 8030 for (i = 0; i < opts.currSlide; i++) { 8031 opts.els.push(opts.els.shift()); 8032 } 8033 opts.fxFn = function (curr, next, opts, cb, fwd) { 8034 if (opts.rev) { 8035 fwd = !fwd; 8036 } 8037 var $el = fwd ? $(curr) : $(next); 8038 $(next).css(opts.cssBefore); 8039 var count = opts.slideCount; 8040 $el.animate(opts.shuffle, opts.speedIn, opts.easeIn, function () { 8041 var hops = $.fn.cycle.hopsFromLast(opts, fwd); 8042 for (var k = 0; k < hops; k++) { 8043 fwd ? opts.els.push(opts.els.shift()) : opts.els.unshift(opts.els.pop()); 8044 } 8045 if (fwd) { 8046 for (var i = 0, len = opts.els.length; i < len; i++) { 8047 $(opts.els[i]).css("z-index", len - i + count); 8048 } 8049 } else { 8050 var z = $(curr).css("z-index"); 8051 $el.css("z-index", parseInt(z) + 1 + count); 8052 } 8053 $el.animate({ 8054 left: 0, 8055 top: 0 8056 }, opts.speedOut, opts.easeOut, function () {
8057 $(fwd ? this : curr).hide(); 8058 if (cb) { 8059 cb(); 8060 } 8061 }); 8062 }); 8063 }; 8064 $.extend(opts.cssBefore, { 8065 display: "block", 8066 opacity: 1, 8067 top: 0, 8068 left: 0 8069 }); 8070 }; 8071 $.fn.cycle.transitions.turnUp = function ($cont, $slides, opts) { 8072 opts.before.push(function (curr, next, opts) { 8073 $.fn.cycle.commonReset(curr, next, opts, true, false); 8074 opts.cssBefore.top = next.cycleH; 8075 opts.animIn.height = next.cycleH; 8076 opts.animOut.width = next.cycleW; 8077 }); 8078 opts.cssFirst.top = 0; 8079 opts.cssBefore.left = 0; 8080 opts.cssBefore.height = 0; 8081 opts.animIn.top = 0; 8082 opts.animOut.height = 0; 8083 }; 8084 $.fn.cycle.transitions.turnDown = function ($cont, $slides, opts) { 8085 opts.before.push(function (curr, next, opts) { 8086 $.fn.cycle.commonReset(curr, next, opts, true, false); 8087 opts.animIn.height = next.cycleH; 8088 opts.animOut.top = curr.cycleH; 8089 }); 8090 opts.cssFirst.top = 0; 8091 opts.cssBefore.left = 0; 8092 opts.cssBefore.top = 0; 8093 opts.cssBefore.height = 0; 8094 opts.animOut.height = 0; 8095 }; 8096 $.fn.cycle.transitions.turnLeft = function ($cont, $slides, opts) { 8097 opts.before.push(function (curr, next, opts) { 8098 $.fn.cycle.commonReset(curr, next, opts, false, true); 8099 opts.cssBefore.left = next.cycleW; 8100 opts.animIn.width = next.cycleW; 8101 }); 8102 opts.cssBefore.top = 0; 8103 opts.cssBefore.width = 0; 8104 opts.animIn.left = 0; 8105 opts.animOut.width = 0; 8106 }; 8107 $.fn.cycle.transitions.turnRight = function ($cont, $slides, opts) { 8108 opts.before.push(function (curr, next, opts) { 8109 $.fn.cycle.commonReset(curr, next, opts, false, true); 8110 opts.animIn.width = next.cycleW; 8111 opts.animOut.left = curr.cycleW; 8112 }); 8113 $.extend(opts.cssBefore, { 8114 top: 0, 8115 left: 0, 8116 width: 0 8117 }); 8118 opts.animIn.left = 0; 8119 opts.animOut.width = 0; 8120 }; 8121 $.fn.cycle.transitions.zoom = function ($cont, $slides, opts) { 8122 opts.before.push(function (curr, next, opts) { 8123 $.fn.cycle.commonReset(curr, next, opts, false, false, true); 8124 opts.cssBefore.top = next.cycleH / 2; 8125 opts.cssBefore.left = next.cycleW / 2; 8126 $.extend(opts.animIn, { 8127 top: 0, 8128 left: 0, 8129 width: next.cycleW, 8130 height: next.cycleH 8131 }); 8132 $.extend(opts.animOut, { 8133 width: 0, 8134 height: 0, 8135 top: curr.cycleH / 2, 8136 left: curr.cycleW / 2 8137 }); 8138 }); 8139 opts.cssFirst.top = 0; 8140 opts.cssFirst.left = 0; 8141 opts.cssBefore.width = 0; 8142 opts.cssBefore.height = 0; 8143 }; 8144 $.fn.cycle.transitions.fadeZoom = function ($cont, $slides, opts) { 8145 opts.before.push(function (curr, next, opts) { 8146 $.fn.cycle.commonReset(curr, next, opts, false, false); 8147 opts.cssBefore.left = next.cycleW / 2; 8148 opts.cssBefore.top = next.cycleH / 2; 8149 $.extend(opts.animIn, { 8150 top: 0, 8151 left: 0, 8152 width: next.cycleW, 8153 height: next.cycleH 8154 }); 8155 }); 8156 opts.cssBefore.width = 0; 8157 opts.cssBefore.height = 0; 8158 opts.animOut.opacity = 0; 8159 }; 8160 $.fn.cycle.transitions.blindX = function ($cont, $slides, opts) { 8161 var w = $cont.css("overflow", "hidden").width(); 8162 opts.before.push(function (curr, next, opts) { 8163 $.fn.cycle.commonReset(curr, next, opts); 8164 opts.animIn.width = next.cycleW; 8165 opts.animOut.left = curr.cycleW; 8166 }); 8167 opts.cssBefore.left = w; 8168 opts.cssBefore.top = 0; 8169 opts.animIn.left = 0; 8170 opts.animOut.left = w; 8171 }; 8172 $.fn.cycle.transitions.blindY = function ($cont, $slides, opts) { 8173 var h = $cont.css("overflow", "hidden").height(); 8174 opts.before.push(function (curr, next, opts) { 8175 $.fn.cycle.commonReset(curr, next, opts); 8176 opts.animIn.height = next.cycleH; 8177 opts.animOut.top = curr.cycleH; 8178 }); 8179 opts.cssBefore.top = h; 8180 opts.cssBefore.left = 0; 8181 opts.animIn.top = 0; 8182 opts.animOut.top = h; 8183 }; 8184 $.fn.cycle.transitions.blindZ = function ($cont, $slides, opts) { 8185 var h = $cont.css("overflow", "hidden").height(); 8186 var w = $cont.width(); 8187 opts.before.push(function (curr, next, opts) { 8188 $.fn.cycle.commonReset(curr, next, opts); 8189 opts.animIn.height = next.cycleH; 8190 opts.animOut.top = curr.cycleH; 8191 }); 8192 opts.cssBefore.top = h; 8193 opts.cssBefore.left = w; 8194 opts.animIn.top = 0; 8195 opts.animIn.left = 0; 8196 opts.animOut.top = h; 8197 opts.animOut.left = w; 8198 }; 8199 $.fn.cycle.transitions.growX = function ($cont, $slides, opts) { 8200 opts.before.push(function (curr, next, opts) { 8201 $.fn.cycle.commonReset(curr, next, opts, false, true); 8202 opts.cssBefore.left = this.cycleW / 2; 8203 opts.animIn.left = 0; 8204 opts.animIn.width = this.cycleW; 8205 opts.animOut.left = 0; 8206 }); 8207 opts.cssBefore.top = 0; 8208 opts.cssBefore.width = 0; 8209 }; 8210 $.fn.cycle.transitions.growY = function ($cont, $slides, opts) { 8211 opts.before.push(function (curr, next, opts) { 8212 $.fn.cycle.commonReset(curr, next, opts, true, false); 8213 opts.cssBefore.top = this.cycleH / 2; 8214 opts.animIn.top = 0; 8215 opts.animIn.height = this.cycleH; 8216 opts.animOut.top = 0; 8217 }); 8218 opts.cssBefore.height = 0; 8219 opts.cssBefore.left = 0; 8220 }; 8221 $.fn.cycle.transitions.curtainX = function ($cont, $slides, opts) { 8222 opts.before.push(function (curr, next, opts) { 8223 $.fn.cycle.commonReset(curr, next, opts, false, true, true); 8224 opts.cssBefore.left = next.cycleW / 2; 8225 opts.animIn.left = 0; 8226 opts.animIn.width = this.cycleW; 8227 opts.animOut.left = curr.cycleW / 2; 8228 opts.animOut.width = 0; 8229 }); 8230 opts.cssBefore.top = 0; 8231 opts.cssBefore.width = 0; 8232 }; 8233 $.fn.cycle.transitions.curtainY = function ($cont, $slides, opts) { 8234 opts.before.push(function (curr, next, opts) { 8235 $.fn.cycle.commonReset(curr, next, opts, true, false, true); 8236 opts.cssBefore.top = next.cycleH / 2; 8237 opts.animIn.top = 0; 8238 opts.animIn.height = next.cycleH; 8239 opts.animOut.top = curr.cycleH / 2; 8240 opts.animOut.height = 0; 8241 }); 8242 opts.cssBefore.height = 0; 8243 opts.cssBefore.left = 0; 8244 }; 8245 $.fn.cycle.transitions.cover = function ($cont, $slides, opts) { 8246 var d = opts.direction || "left"; 8247 var w = $cont.css("overflow", "hidden").width(); 8248 var h = $cont.height(); 8249 opts.before.push(function (curr, next, opts) { 8250 $.fn.cycle.commonReset(curr, next, opts); 8251 if (d == "right") { 8252 opts.cssBefore.left = -w; 8253 } else { 8254 if (d == "up") { 8255 opts.cssBefore.top = h; 8256 } else { 8257 if (d == "down") { 8258 opts.cssBefore.top = -h; 8259 } else { 8260 opts.cssBefore.left = w; 8261 } 8262 } 8263 } 8264 }); 8265 opts.animIn.left = 0; 8266 opts.animIn.top = 0; 8267 opts.cssBefore.top = 0; 8268 opts.cssBefore.left = 0; 8269 }; 8270 $.fn.cycle.transitions.uncover = function ($cont, $slides, opts) { 8271 var d = opts.direction || "left"; 8272 var w = $cont.css("overflow", "hidden").width(); 8273 var h = $cont.height(); 8274 opts.before.push(function (curr, next, opts) { 8275 $.fn.cycle.commonReset(curr, next, opts, true, true, true); 8276 if (d == "right") { 8277 opts.animOut.left = w; 8278 } else { 8279 if (d == "up") { 8280 opts.animOut.top = -h; 8281 } else { 8282 if (d == "down") { 8283 opts.animOut.top = h; 8284 } else { 8285 opts.animOut.left = -w; 8286 } 8287 } 8288 } 8289 }); 8290 opts.animIn.left = 0; 8291 opts.animIn.top = 0; 8292 opts.cssBefore.top = 0; 8293 opts.cssBefore.left = 0; 8294 }; 8295 $.fn.cycle.transitions.toss = function ($cont, $slides, opts) { 8296 var w = $cont.css("overflow", "visible").width(); 8297 var h = $cont.height(); 8298 opts.before.push(function (curr, next, opts) { 8299 $.fn.cycle.commonReset(curr, next, opts, true, true, true); 8300 if (!opts.animOut.left && !opts.animOut.top) { 8301 $.extend(opts.animOut, { 8302 left: w * 2, 8303 top: -h / 2, 8304 opacity: 0 8305 }); 8306 } else { 8307 opts.animOut.opacity = 0; 8308 } 8309 }); 8310 opts.cssBefore.left = 0; 8311 opts.cssBefore.top = 0; 8312 opts.animIn.left = 0; 8313 }; 8314 $.fn.cycle.transitions.wipe = function ($cont, $slides, opts) { 8315 var w = $cont.css("overflow", "hidden").width(); 8316 var h = $cont.height(); 8317 opts.cssBefore = opts.cssBefore || {}; 8318 var clip; 8319 if (opts.clip) { 8320 if (/l2r/.test(opts.clip)) { 8321 clip = "rect(0px 0px " + h + "px 0px)"; 8322 } else { 8323 if (/r2l/.test(opts.clip)) { 8324 clip = "rect(0px " + w + "px " + h + "px " + w + "px)"; 8325 } else { 8326 if (/t2b/.test(opts.clip)) { 8327 clip = "rect(0px " + w + "px 0px 0px)"; 8328 } else { 8329 if (/b2t/.test(opts.clip)) { 8330 clip = "rect(" + h + "px " + w + "px " + h + "px 0px)"; 8331 } else { 8332 if (/zoom/.test(opts.clip)) { 8333 var top = parseInt(h / 2); 8334 var left = parseInt(w / 2); 8335 clip = "rect(" + top + "px " + left + "px " + top + "px " + left + "px)"; 8336 } 8337 } 8338 } 8339 } 8340 } 8341 } 8342 opts.cssBefore.clip = opts.cssBefore.clip || clip || "rect(0px 0px 0px 0px)"; 8343 var d = opts.cssBefore.clip.match(/(\d+)/g); 8344 var t = parseInt(d[0]), 8345 r = parseInt(d[1]), 8346 b = parseInt(d[2]), 8347 l = parseInt(d[3]); 8348 opts.before.push(function (curr, next, opts) { 8349 if (curr == next) { 8350 return; 8351 } 8352 var $curr = $(curr), 8353 $next = $(next); 8354 $.fn.cycle.commonReset(curr, next, opts, true, true, false); 8355 opts.cssAfter.display = "block"; 8356 var step = 1, 8357 count = parseInt((opts.speedIn / 13)) - 1; 8358 (function f() { 8359 var tt = t ? t - parseInt(step * (t / count)) : 0; 8360 var ll = l ? l - parseInt(step * (l / count)) : 0; 8361 var bb = b < h ? b + parseInt(step * ((h - b) / count || 1)) : h; 8362 var rr = r < w ? r + parseInt(step * ((w - r) / count || 1)) : w; 8363 $next.css({ 8364 clip: "rect(" + tt + "px " + rr + "px " + bb + "px " + ll + "px)" 8365 }); 8366 (step++ <= count) ? setTimeout(f, 13) : $curr.css("display", "none"); 8367 })(); 8368 }); 8369 $.extend(opts.cssBefore, { 8370 display: "block", 8371 opacity: 1, 8372 top: 0, 8373 left: 0 8374 }); 8375 opts.animIn = { 8376 left: 0 8377 }; 8378 opts.animOut = { 8379 left: 0 8380 }; 8381 }; 8382})(jQuery); 8383 8384/*! 8385 * Maximage Version: 2.0.8 (16-Jan-2012) - http://www.aaronvanderzwan.com/maximage/2.0/ 8386 */ 8387(function (a) { 8388 a.fn.maximage = function (d, e) { 8389 var c; 8390 if (typeof d == "object" || d === undefined) { 8391 c = a.extend(a.fn.maximage.defaults, d || {}) 8392 } 8393 if (typeof d == "string") { 8394 c = a.fn.maximage.defaults 8395 } 8396 a.Body = a("body"); 8397 a.Window = a(window); 8398 a.Scroll = a("html, body"); 8399 a.Events = { 8400 RESIZE: "resize" 8401 }; 8402 this.each(function () { 8403 var m = a(this), 8404 f = 0, 8405 j = []; 8406 var i = { 8407 setup: function () { 8408 if (a.Slides.length > 0) { 8409 var r, p = a.Slides.length; 8410 for (r = 0; r < p; r++) { 8411 var q = a.Slides[r]; 8412 m.append('<div class="mc-image ' + q.theclass + '" title="' + q.alt + '" style="background-image:url(\'' + q.url + "');" + q.style + '" data-href="' + q.datahref + '">' + q.content + "</div>") 8413 } 8414 i.preload(0); 8415 i.resize() 8416 } 8417 }, 8418 preload: function (q) { 8419 var p = a("<img/>"); 8420 p.load(function () { 8421 if (f == 0) { 8422 g.setup(); 8423 c.onFirstImageLoaded() 8424 } 8425 if (f == (a.Slides.length - 1)) { 8426 c.onImagesLoaded(m) 8427 } else { 8428 f++; 8429 i.preload(f) 8430 } 8431 }); 8432 p[0].src = a.Slides[q].url; 8433 j.push(p[0]) 8434 }, 8435 resize: function () { 8436 a.Window.bind(a.Events.RESIZE, function () { 8437 a.Scroll.addClass("mc-hide-scrolls"); 8438 a.Window.data("h", k.sizes().h).data("w", k.sizes().w); 8439 m.height(a.Window.data("h")).width(a.Window.data("w")).children().height(a.Window.data("h")).width(a.Window.data("w")); 8440 m.children().each(function () { 8441 this.cycleH = a.Window.data("h"); 8442 this.cycleW = a.Window.data("w") 8443 }); 8444 a(a.Scroll).removeClass("mc-hide-scrolls") 8445 }) 8446 } 8447 }; 8448 var h = { 8449 setup: function () { 8450 var u, s, q, r, p = a.Slides.length; 8451 if (a.BrowserTests.msie && !c.overrideMSIEStop) { 8452 document.execCommand("Stop", false) 8453 } 8454 m.html(""); 8455 a.Body.addClass("mc-old-browser"); 8456 if (a.Slides.length > 0) { 8457 a.Scroll.addClass("mc-hide-scrolls"); 8458 a.Window.data("h", k.sizes().h).data("w", k.sizes().w); 8459 a("body").append(a("<div></div>").attr("class", "mc-loader").css({ 8460 position: "absolute",
8461 left: "-9999px" 8462 })); 8463 for (r = 0; r < p; r++) { 8464 if (a.Slides[r].content.length == 0) { 8465 u = '<img src="' + a.Slides[r].url + '" />' 8466 } else { 8467 u = a.Slides[r].content 8468 } 8469 q = a("<div>" + u + "</div>").attr("class", "mc-image mc-image-n" + r + " " + a.Slides[r].theclass); 8470 m.append(q); 8471 if (a(".mc-image-n" + r).children("img").length == 0) { } else { 8472 a("div.mc-loader").append(a(".mc-image-n" + r).children("img").first().clone().addClass("not-loaded")) 8473 } 8474 } 8475 h.preload(); 8476 h.windowResize() 8477 } 8478 }, 8479 preload: function () { 8480 var p = setInterval(function () { 8481 a(".mc-loader").children("img").each(function (r) { 8482 var q = a(this); 8483 if (q.hasClass("not-loaded")) { 8484 if (q.height() > 0) { 8485 a(this).removeClass("not-loaded"); 8486 var s = a("div.mc-image-n" + r).children("img").first(); 8487 s.data("h", q.height()).data("w", q.width()).data("ar", (q.width() / q.height())); 8488 h.onceLoaded(r) 8489 } 8490 } 8491 }); 8492 if (a(".not-loaded").length == 0) { 8493 a(".mc-loader").remove(); 8494 clearInterval(p) 8495 } 8496 }, 1000) 8497 }, 8498 onceLoaded: function (p) { 8499 h.maximage(p); 8500 if (p == 0) { 8501 m.css({ 8502 visibility: "visible" 8503 }); 8504 c.onFirstImageLoaded() 8505 } else { 8506 if (p == a.Slides.length - 1) { 8507 g.setup(); 8508 a(a.Scroll).removeClass("mc-hide-scrolls"); 8509 c.onImagesLoaded(m); 8510 if (c.debug) { 8511 b(" - Final Maximage - "); 8512 b(m) 8513 } 8514 } 8515 } 8516 }, 8517 maximage: function (q) { 8518 a("div.mc-image-n" + q).height(a.Window.data("h")).width(a.Window.data("w")).children("img").first().each(function () { 8519 n.maxcover(a(this)) 8520 }) 8521 }, 8522 windowResize: function () { 8523 a.Window.bind(a.Events.RESIZE, function () { 8524 clearTimeout(this.id); 8525 this.id = setTimeout(h.doneResizing, 200) 8526 }) 8527 }, 8528 doneResizing: function () { 8529 a(a.Scroll).addClass("mc-hide-scrolls"); 8530 a.Window.data("h", k.sizes().h).data("w", k.sizes().w); 8531 m.height(a.Window.data("h")).width(a.Window.data("w")); 8532 m.find(".mc-image").each(function (q) { 8533 h.maximage(q) 8534 }); 8535 var p = m.data("cycle.opts"); 8536 if (p != undefined) { 8537 p.height = a.Window.data("h"); 8538 p.width = a.Window.data("w"); 8539 jQuery.each(p.elements, function (q, r) { 8540 r.cycleW = a.Window.data("w"); 8541 r.cycleH = a.Window.data("h") 8542 }) 8543 } 8544 a(a.Scroll).removeClass("mc-hide-scrolls") 8545 } 8546 }; 8547 var g = { 8548 setup: function () { 8549 var q, p; 8550 m.addClass("mc-cycle"); 8551 a.Window.data("h", k.sizes().h).data("w", k.sizes().w); 8552 jQuery.easing.easeForCSSTransition = function (v, w, u, A, z, y) { 8553 return u + A 8554 }; 8555 var r = a.extend({ 8556 fit: 1, 8557 containerResize: 0, 8558 height: a.Window.data("h"), 8559 width: a.Window.data("w"), 8560 slideResize: false, 8561 easing: (a.BrowserTests.cssTransitions && c.cssTransitions ? "easeForCSSTransition" : "swing") 8562 }, c.cycleOptions); 8563 m.cycle(r) 8564 } 8565 }; 8566 var n = { 8567 center: function (p) { 8568 if (c.verticalCenter) { 8569 p.css({ 8570 marginTop: ((p.height() - a.Window.data("h")) / 2) * -1 8571 }) 8572 } 8573 if (c.horizontalCenter) { 8574 p.css({ 8575 marginLeft: ((p.width() - a.Window.data("w")) / 2) * -1 8576 }) 8577 } 8578 }, 8579 fill: function (p) { 8580 var q = p.is("object") ? p.parent().first() : p; 8581 if (typeof c.backgroundSize == "function") { 8582 c.backgroundSize(p) 8583 } else { 8584 if (c.backgroundSize == "cover") { 8585 if (a.Window.data("w") / a.Window.data("h") < q.data("ar")) { 8586 p.height(a.Window.data("h")).width((a.Window.data("h") * q.data("ar")).toFixed(0)) 8587 } else { 8588 p.height((a.Window.data("w") / q.data("ar")).toFixed(0)).width(a.Window.data("w")) 8589 } 8590 } else { 8591 if (c.backgroundSize == "contain") { 8592 if (a.Window.data("w") / a.Window.data("h") < q.data("ar")) { 8593 p.height((a.Window.data("w") / q.data("ar")).toFixed(0)).width(a.Window.data("w")) 8594 } else { 8595 p.height(a.Window.data("h")).width((a.Window.data("h") * q.data("ar")).toFixed(0)) 8596 } 8597 } else { 8598 b("The backgroundSize option was not recognized for older browsers.") 8599 } 8600 } 8601 } 8602 }, 8603 maxcover: function (p) { 8604 n.fill(p); 8605 n.center(p) 8606 }, 8607 maxcontain: function (p) { 8608 n.fill(p); 8609 n.center(p) 8610 } 8611 }; 8612 var k = { 8613 browser_tests: function () { 8614 var q = a("<div />")[0], 8615 u = ["Moz", "Webkit", "Khtml", "O", "ms"], 8616 t = "transition", 8617 s = { 8618 cssTransitions: false,
8619 cssBackgroundSize: ("backgroundSize" in q.style && c.cssBackgroundSize), 8620 html5Video: false, 8621 msie: false 8622 }; 8623 if (c.cssTransitions) { 8624 if (typeof q.style[t] == "string") { 8625 s.cssTransitions = true 8626 } 8627 t = t.charAt(0).toUpperCase() + t.substr(1); 8628 for (var r = 0; r < u.length; r++) { 8629 if (u[r] + t in q.style) { 8630 s.cssTransitions = true 8631 } 8632 } 8633 } 8634 if (!!document.createElement("video").canPlayType) { 8635 s.html5Video = true 8636 } 8637 s.msie = (k.msie() !== undefined); 8638 if (c.debug) { 8639 b(" - Browser Test - "); 8640 b(s) 8641 } 8642 return s 8643 }, 8644 construct_slide_object: function () { 8645 var r = new Object(), 8646 p = new Array(), 8647 q = ""; 8648 m.children().each(function (t) { 8649 var s = a(this).is("img") ? a(this).clone() : a(this).find("img").first().clone(); 8650 r = {}; 8651 r.url = s.attr("src"); 8652 r.title = s.attr("title") != undefined ? s.attr("title") : ""; 8653 r.alt = s.attr("alt") != undefined ? s.attr("alt") : ""; 8654 r.theclass = s.attr("class") != undefined ? s.attr("class") : ""; 8655 r.styles = s.attr("style") != undefined ? s.attr("style") : ""; 8656 r.orig = s.clone(); 8657 r.datahref = s.attr("data-href") != undefined ? s.attr("data-href") : ""; 8658 r.content = ""; 8659 if (a(this).find("img").length > 0) { 8660 if (a.BrowserTests.cssBackgroundSize) { 8661 a(this).find("img").first().remove() 8662 } 8663 r.content = a(this).html() 8664 } 8665 s[0].src = ""; 8666 if (a.BrowserTests.cssBackgroundSize) { 8667 a(this).remove() 8668 } 8669 p.push(r) 8670 }); 8671 if (c.debug) { 8672 b(" - Slide Object - "); 8673 b(p) 8674 } 8675 return p 8676 }, 8677 msie: function () { 8678 var r, p = 3, 8679 s = document.createElement("div"), 8680 q = s.getElementsByTagName("i"); 8681 while (s.innerHTML = "<!--[if gt IE " + (++p) + "]><i></i><![endif]-->", q[0]) { } 8682 return p > 4 ? p : r 8683 }, 8684 sizes: function () { 8685 var p = { 8686 h: 0, 8687 w: 0 8688 }; 8689 if (c.fillElement == "window") { 8690 p.h = a.Window.height(); 8691 p.w = a.Window.width() 8692 } else { 8693 var q = m.parents(c.fillElement).first(); 8694 if (q.height() == 0 || q.data("windowHeight") == true) { 8695 q.data("windowHeight", true); 8696 p.h = a.Window.height() 8697 } else { 8698 p.h = q.height() 8699 } 8700 if (q.width() == 0 || q.data("windowWidth") == true) { 8701 q.data("windowWidth", true); 8702 p.w = a.Window.width() 8703 } else { 8704 p.w = q.width() 8705 } 8706 } 8707 return p 8708 } 8709 }; 8710 a.BrowserTests = k.browser_tests(); 8711 if (typeof d == "string") { 8712 if (a.BrowserTests.html5Video || !m.is("video")) { 8713 var l, o = m.is("object") ? m.parent().first() : m; 8714 if (!a.Body.hasClass("mc-old-browser")) { 8715 a.Body.addClass("mc-old-browser") 8716 } 8717 a.Window.data("h", k.sizes().h).data("w", k.sizes().w); 8718 o.data("h", m.height()).data("w", m.width()).data("ar", m.width() / m.height()); 8719 a.Window.bind(a.Events.RESIZE, function () { 8720 a.Window.data("h", k.sizes().h).data("w", k.sizes().w); 8721 l = m.data("resizer"); 8722 clearTimeout(l); 8723 l = setTimeout(n[d](m), 200); 8724 m.data("resizer", l) 8725 }); 8726 n[d](m) 8727 } 8728 } else { 8729 a.Slides = k.construct_slide_object();
8730 if (a.BrowserTests.cssBackgroundSize) { 8731 if (c.debug) { 8732 b(" - Using Modern - ") 8733 } 8734 i.setup() 8735 } else { 8736 if (c.debug) { 8737 b(" - Using Old - ") 8738 } 8739 h.setup() 8740 } 8741 } 8742 }); 8743 8744 function b(f) { 8745 if (window.console && window.console.log) { 8746 window.console.log(f) 8747 } 8748 } 8749 }; 8750 a.fn.maximage.defaults = { 8751 debug: false, 8752 cssBackgroundSize: true, 8753 cssTransitions: true, 8754 verticalCenter: true, 8755 horizontalCenter: true, 8756 scaleInterval: 20, 8757 backgroundSize: "cover", 8758 fillElement: "window", 8759 overrideMSIEStop: false, 8760 onFirstImageLoaded: function () { }, 8761 onImagesLoaded: function () { } 8762 } 8763})(jQuery); 8764 8765/* 8766 * BxSlider 8767 * ----------------------------------------------- 8768 */ 8769 8770/** 8771 * BxSlider v4.1.2 - Fully loaded, responsive content slider 8772 */ 8773! function (t) { 8774 var e = {}, 8775 s = { 8776 mode: "horizontal", 8777 slideSelector: "", 8778 infiniteLoop: !0, 8779 hideControlOnEnd: !1, 8780 speed: 500, 8781 easing: null, 8782 slideMargin: 0, 8783 startSlide: 0, 8784 randomStart: !1, 8785 captions: !1, 8786 ticker: !1, 8787 tickerHover: !1, 8788 adaptiveHeight: !1, 8789 adaptiveHeightSpeed: 500, 8790 video: !1, 8791 useCSS: !0, 8792 preloadImages: "visible", 8793 responsive: !0, 8794 slideZIndex: 50, 8795 touchEnabled: !0, 8796 swipeThreshold: 50, 8797 oneToOneTouch: !0, 8798 preventDefaultSwipeX: !0, 8799 preventDefaultSwipeY: !1, 8800 pager: !0, 8801 pagerType: "full", 8802 pagerShortSeparator: " / ", 8803 pagerSelector: null, 8804 buildPager: null, 8805 pagerCustom: null, 8806 controls: !0, 8807 nextText: "Next", 8808 prevText: "Prev", 8809 nextSelector: null, 8810 prevSelector: null, 8811 autoControls: !1, 8812 startText: "Start", 8813 stopText: "Stop", 8814 autoControlsCombine: !1, 8815 autoControlsSelector: null, 8816 auto: !1, 8817 pause: 4e3, 8818 autoStart: !0, 8819 autoDirection: "next", 8820 autoHover: !1, 8821 autoDelay: 0, 8822 minSlides: 1, 8823 maxSlides: 1, 8824 moveSlides: 0, 8825 slideWidth: 0, 8826 onSliderLoad: function () { }, 8827 onSlideBefore: function () { }, 8828 onSlideAfter: function () { }, 8829 onSlideNext: function () { }, 8830 onSlidePrev: function () { }, 8831 onSliderResize: function () { } 8832 }; 8833 t.fn.bxSlider = function (n) { 8834 if (0 == this.length) return this; 8835 if (this.length > 1) return this.each(function () { 8836 t(this).bxSlider(n) 8837 }), this; 8838 var o = {}, 8839 r = this; 8840 e.el = this; 8841 var a = t(window).width(), 8842 l = t(window).height(), 8843 d = function () { 8844 o.settings = t.extend({}, s, n), o.settings.slideWidth = parseInt(o.settings.slideWidth), o.children = r.children(o.settings.slideSelector), o.children.length < o.settings.minSlides && (o.settings.minSlides = o.children.length), o.children.length < o.settings.maxSlides && (o.settings.maxSlides = o.children.length), o.settings.randomStart && (o.settings.startSlide = Math.floor(Math.random() * o.children.length)), o.active = { 8845 index: o.settings.startSlide 8846 }, o.carousel = o.settings.minSlides > 1 || o.settings.maxSlides > 1, o.carousel && (o.settings.preloadImages = "all"), o.minThreshold = o.settings.minSlides * o.settings.slideWidth + (o.settings.minSlides - 1) * o.settings.slideMargin, o.maxThreshold = o.settings.maxSlides * o.settings.slideWidth + (o.settings.maxSlides - 1) * o.settings.slideMargin, o.working = !1, o.controls = {}, o.interval = null, o.animProp = "vertical" == o.settings.mode ? "top" : "left", o.usingCSS = o.settings.useCSS && "fade" != o.settings.mode && function () { 8847 var t = document.createElement("div"), 8848 e = ["WebkitPerspective", "MozPerspective", "OPerspective", "msPerspective"]; 8849 for (var i in e) 8850 if (void 0 !== t.style[e[i]]) return o.cssPrefix = e[i].replace("Perspective", "").toLowerCase(), o.animProp = "-" + o.cssPrefix + "-transform", !0; 8851 return !1 8852 }(), "vertical" == o.settings.mode && (o.settings.maxSlides = o.settings.minSlides), r.data("origStyle", r.attr("style")), r.children(o.settings.slideSelector).each(function () { 8853 t(this).data("origStyle", t(this).attr("style")) 8854 }), c() 8855 }, 8856 c = function () { 8857 r.wrap('<div class="bx-wrapper"><div class="bx-viewport"></div></div>
8857'), o.viewport = r.parent(), o.loader = t('<div class="bx-loading" />'), o.viewport.prepend(o.loader), r.css({ 8858 width: "horizontal" == o.settings.mode ? 100 * o.children.length + 215 + "%" : "auto", 8859 position: "relative" 8860 }), o.usingCSS && o.settings.easing ? r.css("-" + o.cssPrefix + "-transition-timing-function", o.settings.easing) : o.settings.easing || (o.settings.easing = "swing"), f(), o.viewport.css({ 8861 width: "100%", 8862 overflow: "hidden", 8863 position: "relative" 8864 }), o.viewport.parent().css({ 8865 maxWidth: p() 8866 }), o.settings.pager || o.viewport.parent().css({ 8867 margin: "0 auto 0px" 8868 }), o.children.css({ 8869 "float": "horizontal" == o.settings.mode ? "left" : "none", 8870 listStyle: "none", 8871 position: "relative" 8872 }), o.children.css("width", u()), "horizontal" == o.settings.mode && o.settings.slideMargin > 0 && o.children.css("marginRight", o.settings.slideMargin), "vertical" == o.settings.mode && o.settings.slideMargin > 0 && o.children.css("marginBottom", o.settings.slideMargin), "fade" == o.settings.mode && (o.children.css({ 8873 position: "absolute", 8874 zIndex: 0, 8875 display: "none" 8876 }), o.children.eq(o.settings.startSlide).css({ 8877 zIndex: o.settings.slideZIndex, 8878 display: "block" 8879 })), o.controls.el = t('<div class="bx-controls" />'), o.settings.captions && P(), o.active.last = o.settings.startSlide == x() - 1, o.settings.video && r.fitVids(); 8880 var e = o.children.eq(o.settings.startSlide); 8881 "all" == o.settings.preloadImages && (e = o.children), o.settings.ticker ? o.settings.pager = !1 : (o.settings.pager && T(), o.settings.controls && C(), o.settings.auto && o.settings.autoControls && E(), (o.settings.controls || o.settings.autoControls || o.settings.pager) && o.viewport.after(o.controls.el)), g(e, h) 8882 }, 8883 g = function (e, i) { 8884 var s = e.find("img, iframe").length; 8885 if (0 == s) return i(), void 0; 8886 var n = 0; 8887 e.find("img, iframe").each(function () { 8888 t(this).one("load", function () { 8889 ++n == s && i() 8890 }).each(function () { 8891 this.complete && t(this).load() 8892 }) 8893 }) 8894 }, 8895 h = function () { 8896 if (o.settings.infiniteLoop && "fade" != o.settings.mode && !o.settings.ticker) { 8897 var e = "vertical" == o.settings.mode ? o.settings.minSlides : o.settings.maxSlides, 8898 i = o.children.slice(0, e).clone().addClass("bx-clone"), 8899 s = o.children.slice(-e).clone().addClass("bx-clone"); 8900 r.append(i).prepend(s) 8901 } 8902 o.loader.remove(), S(), "vertical" == o.settings.mode && (o.settings.adaptiveHeight = !0), o.viewport.height(v()), r.redrawSlider(), o.settings.onSliderLoad(o.active.index), o.initialized = !0, o.settings.responsive && t(window).bind("resize", Z), o.settings.auto && o.settings.autoStart && H(), o.settings.ticker && L(), o.settings.pager && q(o.settings.startSlide), o.settings.controls && W(), o.settings.touchEnabled && !o.settings.ticker && O() 8903 }, 8904 v = function () { 8905 var e = 0, 8906 s = t(); 8907 if ("vertical" == o.settings.mode || o.settings.adaptiveHeight) 8908 if (o.carousel) { 8909 var n = 1 == o.settings.moveSlides ? o.active.index : o.active.index * m(); 8910 for (s = o.children.eq(n), i = 1; i <= o.settings.maxSlides - 1; i++) s = n + i >= o.children.length ? s.add(o.children.eq(i - 1)) : s.add(o.children.eq(n + i)) 8911 } else s = o.children.eq(o.active.index); 8912 else s = o.children; 8913 return "vertical" == o.settings.mode ? (s.each(function () { 8914 e += t(this).outerHeight() 8915 }), o.settings.slideMargin > 0 && (e += o.settings.slideMargin * (o.settings.minSlides - 1))) : e = Math.max.apply(Math, s.map(function () { 8916 return t(this).outerHeight(!1) 8917 }).get()), e 8918 }, 8919 p = function () { 8920 var t = "100%"; 8921 return o.settings.slideWidth > 0 && (t = "horizontal" == o.settings.mode ? o.settings.maxSlides * o.settings.slideWidth + (o.settings.maxSlides - 1) * o.settings.slideMargin : o.settings.slideWidth), t 8922 }, 8923 u = function () { 8924 var t = o.settings.slideWidth, 8925 e = o.viewport.width(); 8926 return 0 == o.settings.slideWidth || o.settings.slideWidth > e && !o.carousel || "vertical" == o.settings.mode ? t = e : o.settings.maxSlides > 1 && "horizontal" == o.settings.mode && (e > o.maxThreshold || e < o.minThreshold && (t = (e - o.settings.slideMargin * (o.settings.minSlides - 1)) / o.settings.minSlides)), t 8927 }, 8928 f = function () { 8929 var t = 1; 8930 if ("horizontal" == o.settings.mode && o.settings.slideWidth > 0) 8931 if (o.viewport.width() < o.minThreshold) t = o.settings.minSlides; 8932 else if (o.viewport.width() > o.maxThreshold) t = o.settings.maxSlides; 8933 else { 8934 var e = o.children.first().width(); 8935 t = Math.floor(o.viewport.width() / e) 8936 } else "vertical" == o.settings.mode && (t = o.settings.minSlides); 8937 return t 8938 }, 8939 x = function () { 8940 var t = 0; 8941 if (o.settings.moveSlides > 0) 8942 if (o.settings.infiniteLoop) t = o.children.length / m(); 8943 else 8944 for (var e = 0, i = 0; e < o.children.length;)++t, e = i + f(), i += o.settings.moveSlides <= f() ? o.settings.moveSlides : f();
8945 else t = Math.ceil(o.children.length / f()); 8946 return t 8947 }, 8948 m = function () { 8949 return o.settings.moveSlides > 0 && o.settings.moveSlides <= f() ? o.settings.moveSlides : f() 8950 }, 8951 S = function () { 8952 if (o.children.length > o.settings.maxSlides && o.active.last && !o.settings.infiniteLoop) { 8953 if ("horizontal" == o.settings.mode) { 8954 var t = o.children.last(), 8955 e = t.position(); 8956 b(-(e.left - (o.viewport.width() - t.width())), "reset", 0) 8957 } else if ("vertical" == o.settings.mode) { 8958 var i = o.children.length - o.settings.minSlides, 8959 e = o.children.eq(i).position(); 8960 b(-e.top, "reset", 0) 8961 } 8962 } else { 8963 var e = o.children.eq(o.active.index * m()).position(); 8964 o.active.index == x() - 1 && (o.active.last = !0), void 0 != e && ("horizontal" == o.settings.mode ? b(-e.left, "reset", 0) : "vertical" == o.settings.mode && b(-e.top, "reset", 0)) 8965 } 8966 }, 8967 b = function (t, e, i, s) { 8968 if (o.usingCSS) { 8969 var n = "vertical" == o.settings.mode ? "translate3d(0, " + t + "px, 0)" : "translate3d(" + t + "px, 0, 0)"; 8970 r.css("-" + o.cssPrefix + "-transition-duration", i / 1e3 + "s"), "slide" == e ? (r.css(o.animProp, n), r.bind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd", function () { 8971 r.unbind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd"), D() 8972 })) : "reset" == e ? r.css(o.animProp, n) : "ticker" == e && (r.css("-" + o.cssPrefix + "-transition-timing-function", "linear"), r.css(o.animProp, n), r.bind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd", function () { 8973 r.unbind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd"), b(s.resetValue, "reset", 0), N() 8974 })) 8975 } else { 8976 var a = {}; 8977 a[o.animProp] = t, "slide" == e ? r.animate(a, i, o.settings.easing, function () { 8978 D() 8979 }) : "reset" == e ? r.css(o.animProp, t) : "ticker" == e && r.animate(a, speed, "linear", function () { 8980 b(s.resetValue, "reset", 0), N() 8981 }) 8982 } 8983 }, 8984 w = function () { 8985 for (var e = "", i = x(), s = 0; i > s; s++) { 8986 var n = ""; 8987 o.settings.buildPager && t.isFunction(o.settings.buildPager) ? (n = o.settings.buildPager(s), o.pagerEl.addClass("bx-custom-pager")) : (n = s + 1, o.pagerEl.addClass("bx-default-pager")), e += '<div class="bx-pager-item"><a href="" data-slide-index="' + s + '" class="bx-pager-link">' + n + "</a></div>" 8988 } 8989 o.pagerEl.html(e) 8990 }, 8991 T = function () { 8992 o.settings.pagerCustom ? o.pagerEl = t(o.settings.pagerCustom) : (o.pagerEl = t('<div class="bx-pager" />'), o.settings.pagerSelector ? t(o.settings.pagerSelector).html(o.pagerEl) : o.controls.el.addClass("bx-has-pager").append(o.pagerEl), w()), o.pagerEl.on("click", "a", I) 8993 }, 8994 C = function () { 8995 o.controls.next = t('<a class="bx-next" href="">' + o.settings.nextText + "</a>"), o.controls.prev = t('<a class="bx-prev" href="">' + o.settings.prevText + "</a>"), o.controls.next.bind("click", y), o.controls.prev.bind("click", z), o.settings.nextSelector && t(o.settings.nextSelector).append(o.controls.next), o.settings.prevSelector && t(o.settings.prevSelector).append(o.controls.prev), o.settings.nextSelector || o.settings.prevSelector || (o.controls.directionEl = t('<div class="bx-controls-direction" />'), o.controls.directionEl.append(o.controls.prev).append(o.controls.next), o.controls.el.addClass("bx-has-controls-direction").append(o.controls.directionEl)) 8996 }, 8997 E = function () {
8998 o.controls.start = t('<div class="bx-controls-auto-item"><a class="bx-start" href="">' + o.settings.startText + "</a></div>"), o.controls.stop = t('<div class="bx-controls-auto-item"><a class="bx-stop" href="">' + o.settings.stopText + "</a></div>"), o.controls.autoEl = t('<div class="bx-controls-auto" />'), o.controls.autoEl.on("click", ".bx-start", k), o.controls.autoEl.on("click", ".bx-stop", M), o.settings.autoControlsCombine ? o.controls.autoEl.append(o.controls.start) : o.controls.autoEl.append(o.controls.start).append(o.controls.stop), o.settings.autoControlsSelector ? t(o.settings.autoControlsSelector).html(o.controls.autoEl) : o.controls.el.addClass("bx-has-controls-auto").append(o.controls.autoEl), A(o.settings.autoStart ? "stop" : "start") 8999 }, 9000 P = function () { 9001 o.children.each(function () { 9002 var e = t(this).find("img:first").attr("title"); 9003 void 0 != e && ("" + e).length && t(this).append('<div class="bx-caption"><span>' + e + "</span></div>") 9004 }) 9005 }, 9006 y = function (t) { 9007 o.settings.auto && r.stopAuto(), r.goToNextSlide(), t.preventDefault() 9008 }, 9009 z = function (t) { 9010 o.settings.auto && r.stopAuto(), r.goToPrevSlide(), t.preventDefault() 9011 }, 9012 k = function (t) { 9013 r.startAuto(), t.preventDefault() 9014 }, 9015 M = function (t) { 9016 r.stopAuto(), t.preventDefault() 9017 }, 9018 I = function (e) { 9019 o.settings.auto && r.stopAuto(); 9020 var i = t(e.currentTarget), 9021 s = parseInt(i.attr("data-slide-index")); 9022 s != o.active.index && r.goToSlide(s), e.preventDefault() 9023 }, 9024 q = function (e) { 9025 var i = o.children.length; 9026 return "short" == o.settings.pagerType ? (o.settings.maxSlides > 1 && (i = Math.ceil(o.children.length / o.settings.maxSlides)), o.pagerEl.html(e + 1 + o.settings.pagerShortSeparator + i), void 0) : (o.pagerEl.find("a").removeClass("active"), o.pagerEl.each(function (i, s) { 9027 t(s).find("a").eq(e).addClass("active") 9028 }), void 0) 9029 }, 9030 D = function () { 9031 if (o.settings.infiniteLoop) { 9032 var t = ""; 9033 0 == o.active.index ? t = o.children.eq(0).position() : o.active.index == x() - 1 && o.carousel ? t = o.children.eq((x() - 1) * m()).position() : o.active.index == o.children.length - 1 && (t = o.children.eq(o.children.length - 1).position()), t && ("horizontal" == o.settings.mode ? b(-t.left, "reset", 0) : "vertical" == o.settings.mode && b(-t.top, "reset", 0)) 9034 } 9035 o.working = !1, o.settings.onSlideAfter(o.children.eq(o.active.index), o.oldIndex, o.active.index) 9036 }, 9037 A = function (t) { 9038 o.settings.autoControlsCombine ? o.controls.autoEl.html(o.controls[t]) : (o.controls.autoEl.find("a").removeClass("active"), o.controls.autoEl.find("a:not(.bx-" + t + ")").addClass("active")) 9039 }, 9040 W = function () { 9041 1 == x() ? (o.controls.prev.addClass("disabled"), o.controls.next.addClass("disabled")) : !o.settings.infiniteLoop && o.settings.hideControlOnEnd && (0 == o.active.index ? (o.controls.prev.addClass("disabled"), o.controls.next.removeClass("disabled")) : o.active.index == x() - 1 ? (o.controls.next.addClass("disabled"), o.controls.prev.removeClass("disabled")) : (o.controls.prev.removeClass("disabled"), o.controls.next.removeClass("disabled"))) 9042 }, 9043 H = function () { 9044 o.settings.autoDelay > 0 ? setTimeout(r.startAuto, o.settings.autoDelay) : r.startAuto(), o.settings.autoHover && r.hover(function () { 9045 o.interval && (r.stopAuto(!0), o.autoPaused = !0) 9046 }, function () { 9047 o.autoPaused && (r.startAuto(!0), o.autoPaused = null) 9048 }) 9049 }, 9050 L = function () { 9051 var e = 0; 9052 if ("next" == o.settings.autoDirection) r.append(o.children.clone().addClass("bx-clone")); 9053 else { 9054 r.prepend(o.children.clone().addClass("bx-clone")); 9055 var i = o.children.first().position(); 9056 e = "horizontal" == o.settings.mode ? -i.left : -i.top 9057 } 9058 b(e, "reset", 0), o.settings.pager = !1, o.settings.controls = !1, o.settings.autoControls = !1, o.settings.tickerHover && !o.usingCSS && o.viewport.hover(function () { 9059 r.stop() 9060 }, function () { 9061 var e = 0; 9062 o.children.each(function () { 9063 e += "horizontal" == o.settings.mode ? t(this).outerWidth(!0) : t(this).outerHeight(!0) 9064 }); 9065 var i = o.settings.speed / e, 9066 s = "horizontal" == o.settings.mode ? "left" : "top", 9067 n = i * (e - Math.abs(parseInt(r.css(s))
9067)); 9068 N(n) 9069 }), N() 9070 }, 9071 N = function (t) { 9072 speed = t ? t : o.settings.speed; 9073 var e = { 9074 left: 0, 9075 top: 0 9076 }, 9077 i = { 9078 left: 0, 9079 top: 0 9080 }; 9081 "next" == o.settings.autoDirection ? e = r.find(".bx-clone").first().position() : i = o.children.first().position(); 9082 var s = "horizontal" == o.settings.mode ? -e.left : -e.top, 9083 n = "horizontal" == o.settings.mode ? -i.left : -i.top, 9084 a = { 9085 resetValue: n 9086 }; 9087 b(s, "ticker", speed, a) 9088 }, 9089 O = function () { 9090 o.touch = { 9091 start: { 9092 x: 0, 9093 y: 0 9094 }, 9095 end: { 9096 x: 0, 9097 y: 0 9098 } 9099 }, o.viewport.bind("touchstart", X) 9100 }, 9101 X = function (t) { 9102 if (o.working) t.preventDefault(); 9103 else { 9104 o.touch.originalPos = r.position(); 9105 var e = t.originalEvent; 9106 o.touch.start.x = e.changedTouches[0].pageX, o.touch.start.y = e.changedTouches[0].pageY, o.viewport.bind("touchmove", Y), o.viewport.bind("touchend", V) 9107 } 9108 }, 9109 Y = function (t) { 9110 var e = t.originalEvent, 9111 i = Math.abs(e.changedTouches[0].pageX - o.touch.start.x), 9112 s = Math.abs(e.changedTouches[0].pageY - o.touch.start.y); 9113 if (3 * i > s && o.settings.preventDefaultSwipeX ? t.preventDefault() : 3 * s > i && o.settings.preventDefaultSwipeY && t.preventDefault(), "fade" != o.settings.mode && o.settings.oneToOneTouch) { 9114 var n = 0; 9115 if ("horizontal" == o.settings.mode) { 9116 var r = e.changedTouches[0].pageX - o.touch.start.x; 9117 n = o.touch.originalPos.left + r 9118 } else { 9119 var r = e.changedTouches[0].pageY - o.touch.start.y; 9120 n = o.touch.originalPos.top + r 9121 } 9122 b(n, "reset", 0) 9123 } 9124 }, 9125 V = function (t) { 9126 o.viewport.unbind("touchmove", Y); 9127 var e = t.originalEvent, 9128 i = 0; 9129 if (o.touch.end.x = e.changedTouches[0].pageX, o.touch.end.y = e.changedTouches[0].pageY, "fade" == o.settings.mode) { 9130 var s = Math.abs(o.touch.start.x - o.touch.end.x); 9131 s >= o.settings.swipeThreshold && (o.touch.start.x > o.touch.end.x ? r.goToNextSlide() : r.goToPrevSlide(), r.stopAuto()) 9132 } else { 9133 var s = 0; 9134 "horizontal" == o.settings.mode ? (s = o.touch.end.x - o.touch.start.x, i = o.touch.originalPos.left) : (s = o.touch.end.y - o.touch.start.y, i = o.touch.originalPos.top), !o.settings.infiniteLoop && (0 == o.active.index && s > 0 || o.active.last && 0 > s) ? b(i, "reset", 200) : Math.abs(s) >= o.settings.swipeThreshold ? (0 > s ? r.goToNextSlide() : r.goToPrevSlide(), r.stopAuto()) : b(i, "reset", 200) 9135 } 9136 o.viewport.unbind("touchend", V) 9137 }, 9138 Z = function () { 9139 var e = t(window).width(), 9140 i = t(window).height(); 9141 (a != e || l != i) && (a = e, l = i, r.redrawSlider(), o.settings.onSliderResize.call(r, o.active.index)) 9142 }; 9143 return r.goToSlide = function (e, i) { 9144 if (!o.working && o.active.index != e) 9145 if (o.working = !0, o.oldIndex = o.active.index, o.active.index = 0 > e ? x() - 1 : e >= x() ? 0 : e, o.settings.onSlideBefore(o.children.eq(o.active.index), o.oldIndex, o.active.index), "next" == i ? o.settings.onSlideNext(o.children.eq(o.active.index), o.oldIndex, o.active.index) : "prev" == i && o.settings.onSlidePrev(o.children.eq(o.active.index), o.oldIndex, o.active.index), o.active.last = o.active.index >= x() - 1, o.settings.pager && q(o.active.index), o.settings.controls && W(), "fade" == o.settings.mode) o.settings.adaptiveHeight && o.viewport.height() != v() && o.viewport.animate({ 9146 height: v() 9147 }, o.settings.adaptiveHeightSpeed), o.children.filter(":visible").fadeOut(o.settings.speed).css({ 9148 zIndex: 0 9149 }), o.children.eq(o.active.index).css("zIndex", o.settings.slideZIndex + 1).fadeIn(o.settings.speed, function () { 9150 t(this).css("zIndex", o.settings.slideZIndex), D() 9151 }); 9152 else { 9153 o.settings.adaptiveHeight && o.viewport.height() != v() && o.viewport.animate({ 9154 height: v() 9155 }, o.settings.adaptiveHeightSpeed); 9156 var s = 0, 9157 n = { 9158 left: 0, 9159 top: 0 9160 }; 9161 if (!o.settings.infiniteLoop && o.carousel && o.active.last) 9162 if ("horizontal" == o.settings.mode) { 9163 var a = o.children.eq(o.children.length - 1); 9164 n = a.position(), s = o.viewport.width() - a.outerWidth() 9165 } else { 9166 var l = o.children.length - o.settings.minSlides; 9167 n = o.children.eq(l).position() 9168 } 9169 else if (o.carousel && o.active.last && "prev" == i) { 9170 var d = 1 == o.settings.moveSlides ? o.settings.maxSlides - m() : (x() - 1) * m() - (o.children.length - o.settings.maxSlides), 9171 a = r.children(".bx-clone").eq(d); 9172 n = a.position() 9173 } else if ("next" == i && 0 == o.active.index) n = r.find("> .bx-clone").eq(o.settings.maxSlides).position(), o.active.last = !1; 9174 else if (e >= 0) { 9175 var c = e * m(); 9176 n = o.children.eq(c).position() 9177 } 9178 if ("undefined" != typeof n) { 9179 var g = "horizontal" == o.settings.mode ? -(n.left - s) : -n.top; 9180 b(g, "slide", o.settings.speed) 9181 } 9182 } 9183 }, r.goToNextSlide = function () { 9184 if (o.settings.infiniteLoop || !o.active.last) { 9185 var t = parseInt(o.active.index) + 1; 9186 r.goToSlide(t, "next") 9187 } 9188 }, r.goToPrevSlide = function () { 9189 if (o.settings.infiniteLoop || 0 != o.active.index) { 9190 var t = parseInt(o.active.index) - 1; 9191 r.goToSlide(t, "prev") 9192 } 9193 }, r.startAuto = function (t) { 9194 o.interval || (o.interval = setInterval(function () { 9195 "next" == o.settings.autoDirection ? r.goToNextSlide() : r.goToPrevSlide() 9196 }, o.settings.pause), o.settings.autoControls && 1 != t && A("stop")) 9197 }, r.stopAuto = function (t) { 9198 o.interval && (clearInterval(o.interval), o.interval = null, o.settings.autoControls && 1 != t && A("start")) 9199 }, r.getCurrentSlide = function () { 9200 return o.active.index 9201 }, r.getCurrentSlideElement = function () { 9202 return o.children.eq(o.active.index) 9203 }, r.getSlideCount = function () { 9204 return o.children.length 9205 }, r.redrawSlider = function () { 9206 o.children.add(r.find(".bx-clone")).outerWidth(u()), o.viewport.css("height", v()), o.settings.ticker || S(), o.active.last && (o.active.index = x() - 1), o.active.index >= x() && (o.active.last = !0), o.settings.pager && !o.settings.pagerCustom && (w(), q(o.active.index)) 9207 }, r.destroySlider = function () { 9208 o.initialized && (o.initialized = !1, t(".bx-clone", this).remove(), o.children.each(function () { 9209 void 0 != t(this).data("origStyle") ? t(this).attr("style", t(this).data("origStyle")) : t(this).removeAttr("style") 9210 }), void 0 != t(this).data("origStyle") ? this.attr("style", t(this).data("origStyle")) : t(this).removeAttr("style"), t(this).unwrap().unwrap(), o.controls.el && o.controls.el.remove(), o.controls.next && o.controls.next.remove(), o.controls.prev && o.controls.prev.remove(), o.pagerEl && o.settings.controls && o.pagerEl.remove(), t(".bx-caption", this).remove(), o.controls.autoEl && o.controls.autoEl.remove(), clearInterval(o.interval), o.settings.responsive && t(window).unbind("resize", Z)) 9211 }, r.reloadSlider = function (t) { 9212 void 0 != t && (n = t), r.destroySlider(), d() 9213 }, d(), this 9214 } 9215}(jQuery); 9216 9217 9218/* 9219 * moment.js 9220 * ----------------------------------------------- 9221 */ 9222//! moment.js 9223//! version : 2.11.0 9224//! authors : Tim Wood, Iskren Chernev, Moment.js contributors 9225//! license : MIT 9226//! momentjs.com 9227! function (a, b) { 9228 "object" == typeof exports && "undefined" != typeof module ? module.exports = b() : "function" == typeof define && define.amd ? define(b) : a.moment = b() 9229}(this, function () { 9230 "use strict"; 9231 9232 function a() { 9233 return Qc.apply(null, arguments) 9234 } 9235 9236 function b(a) { 9237 Qc = a 9238 } 9239 9240 function c(a) { 9241 return "[object Array]" === Object.prototype.toString.call(a) 9242 } 9243 9244 function d(a) { 9245 return a instanceof Date || "[object Date]" === Object.prototype.toString.call(a) 9246 } 9247 9248 function e(a, b) { 9249 var c, d = []; 9250 for (c = 0; c < a.length; ++c) d.push(b(a[c], c)); 9251 return d 9252 } 9253 9254 function f(a, b) { 9255 return Object.prototype.hasOwnProperty.call(a, b) 9256 } 9257 9258 function g(a, b) { 9259 for (var c in b) f(b, c) && (a[c] = b[c]); 9260 return f(b, "toString") && (a.toString = b.toString), f(b, "valueOf") && (a.valueOf = b.valueOf), a 9261 } 9262 9263 function h(a, b, c, d) { 9264 return za(a, b, c, d, !0).utc() 9265 } 9266 9267 function i() { 9268 return { 9269 empty: !1, 9270 unusedTokens: [], 9271 unusedInput: [], 9272 overflow: -2, 9273 charsLeftOver: 0, 9274 nullInput: !1, 9275 invalidMonth: null, 9276 invalidFormat: !1, 9277 userInvalidated: !1, 9278 iso: !1 9279 } 9280 } 9281 9282 function j(a) { 9283 return null == a._pf && (a._pf = i()), a._pf 9284 } 9285 9286 function k(a) { 9287 if (null == a._isValid) { 9288 var b = j(a); 9289 a._isValid = !(isNaN(a._d.getTime()) || !(b.overflow < 0) || b.empty || b.invalidMonth || b.invalidWeekday || b.nullInput || b.invalidFormat || b.userInvalidated), a._strict && (a._isValid = a._isValid && 0 === b.charsLeftOver && 0 === b.unusedTokens.length && void 0 === b.bigHour) 9290 } 9291 return a._isValid 9292 } 9293 9294 function l(a) { 9295 var b = h(NaN); 9296 return null != a ? g(j(b), a) : j(b).userInvalidated = !0, b 9297 } 9298 9299 function m(a) { 9300 return void 0 === a 9301 } 9302 9303 function n(a, b) { 9304 var c, d, e; 9305 if (m(b._isAMomentObject) || (a._isAMomentObject = b._isAMomentObject), m(b._i) || (a._i = b._i), m(b._f) || (a._f = b._f), m(b._l) || (a._l = b._l), m(b._strict) || (a._strict = b._strict), m(b._tzm) || (a._tzm = b._tzm), m(b._isUTC) || (a._isUTC = b._isUTC), m(b._offset) || (a._offset = b._offset), m(b._pf) || (a._pf = j(b)), m(b._locale) || (a._locale = b._locale), Sc.length > 0) 9306 for (c in Sc) d = Sc[c], e = b[d], m(e) || (a[d] = e); 9307 return a 9308 } 9309 9310 function o(b) { 9311 n(this, b), this._d = new Date(null != b._d ? b._d.getTime() : NaN), Tc === !1 && (Tc = !0, a.updateOffset(this), Tc = !1) 9312 } 9313 9314 function p(a) { 9315 return a instanceof o || null != a && null != a._isAMomentObject 9316 } 9317 9318 function q(a) { 9319 return 0 > a ? Math.ceil(a) : Math.floor(a) 9320 } 9321 9322 function r(a) { 9323 var b = +a, 9324 c = 0; 9325 return 0 !== b && isFinite(b) && (c = q(b)), c 9326 } 9327 9328 function s(a, b, c) { 9329 var d, e = Math.min(a.length, b.length), 9330 f = Math.abs(a.length - b.length), 9331 g = 0; 9332 for (d = 0; e > d; d++)(c && a[d] !== b[d] || !c && r(a[d]) !== r(b[d])) && g++; 9333 return g + f 9334 } 9335 9336 function t() { } 9337 9338 function u(a) { 9339 return a ? a.toLowerCase().replace("_", "-") : a 9340 } 9341 9342 function v(a) { 9343 for (var b, c, d, e, f = 0; f < a.length;) { 9344 for (e = u(a[f]).split("-"), b = e.length, c = u(a[f + 1]), c = c ? c.split("-") : null; b > 0;) { 9345 if (d = w(e.slice(0, b).join("-"))) return d; 9346 if (c && c.length >= b && s(e, c, !0) >= b - 1) break; 9347 b-- 9348 } 9349 f++ 9350 } 9351 return null 9352 } 9353 9354 function w(a) { 9355 var b = null; 9356 if (!Uc[a] && !m(module) && module && module.exports) try { 9357 b = Rc._abbr, require("./locale/" + a), x(b) 9358 } catch (c) { } 9359 return Uc[a] 9360 } 9361 9362 function x(a, b) { 9363 var c; 9364 return a && (c = m(b) ? z(a) : y(a, b), c && (Rc = c)), Rc._abbr 9365 } 9366 9367 function y(a, b) { 9368 return null !== b ? (b.abbr = a, Uc[a] = Uc[a] || new t, Uc[a].set(b), x(a), Uc[a]) : (delete Uc[a], null) 9369 } 9370 9371 function z(a) { 9372 var b; 9373 if (a && a._locale && a._locale._abbr && (a = a._locale._abbr), !a) return Rc; 9374 if (!c(a)) { 9375 if (b = w(a)) return b; 9376 a = [a] 9377 } 9378 return v(a) 9379 } 9380 9381 function A(a, b) { 9382 var c = a.toLowerCase(); 9383 Vc[c] = Vc[c + "s"] = Vc[b] = a 9384 } 9385 9386 function B(a) { 9387 return "string" == typeof a ? Vc[a] || Vc[a.toLowerCase()] : void 0 9388 } 9389 9390 function C(a) { 9391 var b, c, d = {}; 9392 for (c in a) f(a, c) && (b = B(c), b && (d[b] = a[c])); 9393 return d 9394 } 9395 9396 function D(a) { 9397 return a instanceof Function || "[object Function]" === Object.prototype.toString.call(a) 9398 } 9399 9400 function E(b, c) { 9401 return function (d) { 9402 return null != d ? (G(this, b, d), a.updateOffset(this, c), this) : F(this, b) 9403 } 9404 } 9405 9406 function F(a, b) { 9407 return a.isValid() ? a._d["get" + (a._isUTC ? "UTC" : "") + b]() : NaN 9408 } 9409 9410 function G(a, b, c) { 9411 a.isValid() && a._d["set" + (a._isUTC ? "UTC" : "") + b](c) 9412 } 9413 9414 function H(a, b) { 9415 var c; 9416 if ("object" == typeof a) 9417 for (c in a) this.set(c, a[c]); 9418 else if (a = B(a), D(this[a])) return this[a](b); 9419 return this 9420 } 9421 9422 function I(a, b, c) { 9423 var d = "" + Math.abs(a), 9424 e = b - d.length, 9425 f = a >= 0; 9426 return (f ? c ? "+" : "" : "-") + Math.pow(10, Math.max(0, e)).toString().substr(1) + d 9427 } 9428 9429 function J(a, b, c, d) { 9430 var e = d; 9431 "string" == typeof d && (e = function () { 9432 return this[d]() 9433 }), a && (Zc[a] = e), b && (Zc[b[0]] = function () { 9434 return I(e.apply(this, arguments), b[1], b[2]) 9435 }), c && (Zc[c] = function () { 9436 return this.localeData().ordinal(e.apply(this, arguments), a) 9437 }) 9438 } 9439 9440 function K(a) { 9441 return a.match(/\[[\s\S]/) ? a.replace(/^\[|\]$/g, "") : a.replace(/\\/g, "") 9442 } 9443 9444 function L(a) { 9445 var b, c, d = a.match(Wc); 9446 for (b = 0, c = d.length; c > b; b++) Zc[d[b]] ? d[b] = Zc[d[b]] : d[b] = K(d[b]); 9447 return function (e) { 9448 var f = ""; 9449 for (b = 0; c > b; b++) f += d[b] instanceof Function ? d[b].call(e, a) : d[b]; 9450 return f 9451 } 9452 } 9453 9454 function M(a, b) { 9455 return a.isValid() ? (b = N(b, a.localeData()), Yc[b] = Yc[b] || L(b), Yc[b](a)) : a.localeData().invalidDate() 9456 } 9457 9458 function
vendor: 48,132 bytes, lines 9458-10664
9458N(a, b) { 9459 function c(a) { 9460 return b.longDateFormat(a) || a 9461 } 9462 var d = 5; 9463 for (Xc.lastIndex = 0; d >= 0 && Xc.test(a);) a = a.replace(Xc, c), Xc.lastIndex = 0, d -= 1; 9464 return a 9465 } 9466 9467 function O(a, b, c) { 9468 pd[a] = D(b) ? b : function (a) { 9469 return a && c ? c : b 9470 } 9471 } 9472 9473 function P(a, b) { 9474 return f(pd, a) ? pd[a](b._strict, b._locale) : new RegExp(Q(a)) 9475 } 9476 9477 function Q(a) { 9478 return a.replace("\\", "").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g, function (a, b, c, d, e) { 9479 return b || c || d || e 9480 }).replace(/[-\/\\^$*+?.()|[\]{}]/g, "\\$&") 9481 } 9482 9483 function R(a, b) { 9484 var c, d = b; 9485 for ("string" == typeof a && (a = [a]), "number" == typeof b && (d = function (a, c) { 9486 c[b] = r(a) 9487 }), c = 0; c < a.length; c++) qd[a[c]] = d 9488 } 9489 9490 function S(a, b) { 9491 R(a, function (a, c, d, e) { 9492 d._w = d._w || {}, b(a, d._w, d, e) 9493 }) 9494 } 9495 9496 function T(a, b, c) { 9497 null != b && f(qd, a) && qd[a](b, c._a, c, a) 9498 } 9499 9500 function U(a, b) { 9501 return new Date(Date.UTC(a, b + 1, 0)).getUTCDate() 9502 } 9503 9504 function V(a, b) { 9505 return c(this._months) ? this._months[a.month()] : this._months[Ad.test(b) ? "format" : "standalone"][a.month()] 9506 } 9507 9508 function W(a, b) { 9509 return c(this._monthsShort) ? this._monthsShort[a.month()] : this._monthsShort[Ad.test(b) ? "format" : "standalone"][a.month()] 9510 } 9511 9512 function X(a, b, c) { 9513 var d, e, f; 9514 for (this._monthsParse || (this._monthsParse = [], this._longMonthsParse = [], this._shortMonthsParse = []), d = 0; 12 > d; d++) { 9515 if (e = h([2e3, d]), c && !this._longMonthsParse[d] && (this._longMonthsParse[d] = new RegExp("^" + this.months(e, "").replace(".", "") + "$", "i"), this._shortMonthsParse[d] = new RegExp("^" + this.monthsShort(e, "").replace(".", "") + "$", "i")), c || this._monthsParse[d] || (f = "^" + this.months(e, "") + "|^" + this.monthsShort(e, ""), this._monthsParse[d] = new RegExp(f.replace(".", ""), "i")), c && "MMMM" === b && this._longMonthsParse[d].test(a)) return d; 9516 if (c && "MMM" === b && this._shortMonthsParse[d].test(a)) return d; 9517 if (!c && this._monthsParse[d].test(a)) return d 9518 } 9519 } 9520 9521 function Y(a, b) { 9522 var c; 9523 return a.isValid() ? "string" == typeof b && (b = a.localeData().monthsParse(b), "number" != typeof b) ? a : (c = Math.min(a.date(), U(a.year(), b)), a._d["set" + (a._isUTC ? "UTC" : "") + "Month"](b, c), a) : a 9524 } 9525 9526 function Z(b) { 9527 return null != b ? (Y(this, b), a.updateOffset(this, !0), this) : F(this, "Month") 9528 } 9529 9530 function $() { 9531 return U(this.year(), this.month()) 9532 } 9533 9534 function _(a) { 9535 var b, c = a._a; 9536 return c && -2 === j(a).overflow && (b = c[sd] < 0 || c[sd] > 11 ? sd : c[td] < 1 || c[td] > U(c[rd], c[sd]) ? td : c[ud] < 0 || c[ud] > 24 || 24 === c[ud] && (0 !== c[vd] || 0 !== c[wd] || 0 !== c[xd]) ? ud : c[vd] < 0 || c[vd] > 59 ? vd : c[wd] < 0 || c[wd] > 59 ? wd : c[xd] < 0 || c[xd] > 999 ? xd : -1, j(a)._overflowDayOfYear && (rd > b || b > td) && (b = td), j(a)._overflowWeeks && -1 === b && (b = yd), j(a)._overflowWeekday && -1 === b && (b = zd), j(a).overflow = b), a 9537 } 9538 9539 function aa(b) { 9540 a.suppressDeprecationWarnings === !1 && !m(console) && console.warn && console.warn("Deprecation warning: " + b) 9541 } 9542 9543 function ba(a, b) { 9544 var c = !0; 9545 return g(function () { 9546 return c && (aa(a + "\nArguments: " + Array.prototype.slice.call(arguments).join(", ") + "\n" + (new Error).stack), c = !1), b.apply(this, arguments) 9547 }, b) 9548 } 9549 9550 function ca(a, b) { 9551 Dd[a] || (aa(b), Dd[a] = !0) 9552 } 9553 9554 function da(a) { 9555 var b, c, d, e, f, g, h = a._i, 9556 i = Ed.exec(h) || Fd.exec(h); 9557 if (i) { 9558 for (j(a).iso = !0, b = 0, c = Hd.length; c > b; b++) 9559 if (Hd[b][1].exec(i[1])) { 9560 e = Hd[b][0], d = Hd[b][2] !== !1; 9561 break 9562 } if (null == e) return void (a._isValid = !1); 9563 if (i[3]) { 9564 for (b = 0, c = Id.length; c > b; b++) 9565 if (Id[b][1].exec(i[3])) { 9566 f = (i[2] || " ") + Id[b][0]; 9567 break 9568 } if (null == f) return void (a._isValid = !1) 9569 } 9570 if (!d && null != f) return void (a._isValid = !1); 9571 if (i[4]) { 9572 if (!Gd.exec(i[4])) return void (a._isValid = !1); 9573 g = "Z" 9574 } 9575 a._f = e + (f || "") + (g || ""), sa(a) 9576 } else a._isValid = !1 9577 } 9578 9579 function ea(b) { 9580 var c = Jd.exec(b._i); 9581 return null !== c ? void (b._d = new Date(+c[1])) : (da(b), void (b._isValid === !1 && (delete b._isValid, a.createFromInputFallback(b)))) 9582 } 9583 9584 function fa(a, b, c, d, e, f, g) { 9585 var h = new Date(a, b, c, d, e, f, g); 9586 return 100 > a && a >= 0 && isFinite(h.getFullYear()) && h.setFullYear(a), h 9587 } 9588 9589 function ga(a) { 9590 var b = new Date(Date.UTC.apply(null, arguments)); 9591 return 100 > a && a >= 0 && isFinite(b.getUTCFullYear()) && b.setUTCFullYear(a), b 9592 } 9593 9594 function ha(a) { 9595 return ia(a) ? 366 : 365 9596 } 9597 9598 function ia(a) { 9599 return a % 4 === 0 && a % 100 !== 0 || a % 400 === 0 9600 } 9601 9602 function ja() { 9603 return ia(this.year()) 9604 } 9605 9606 function ka(a, b, c) { 9607 var d = 7 + b - c, 9608 e = (7 + ga(a, 0, d).getUTCDay() - b) % 7; 9609 return -e + d - 1 9610 } 9611 9612 function la(a, b, c, d, e) { 9613 var f, g, h = (7 + c - d) % 7, 9614 i = ka(a, d, e), 9615 j = 1 + 7 * (b - 1) + h + i; 9616 return 0 >= j ? (f = a - 1, g = ha(f) + j) : j > ha(a) ? (f = a + 1, g = j - ha(a)) : (f = a, g = j), { 9617 year: f, 9618 dayOfYear: g 9619 } 9620 } 9621 9622 function ma(a, b, c) { 9623 var d, e, f = ka(a.year(), b, c), 9624 g = Math.floor((a.dayOfYear() - f - 1) / 7) + 1; 9625 return 1 > g ? (e = a.year() - 1, d = g + na(e, b, c)) : g > na(a.year(), b, c) ? (d = g - na(a.year(), b, c), e = a.year() + 1) : (e = a.year(), d = g), { 9626 week: d, 9627 year: e 9628 } 9629 } 9630 9631 function na(a, b, c) { 9632 var d = ka(a, b, c), 9633 e = ka(a + 1, b, c); 9634 return (ha(a) - d + e) / 7 9635 } 9636 9637 function oa(a, b, c) { 9638 return null != a ? a : null != b ? b : c 9639 } 9640 9641 function pa(b) { 9642 var c = new Date(a.now()); 9643 return b._useUTC ? [c.getUTCFullYear(), c.getUTCMonth(), c.getUTCDate()] : [c.getFullYear(), c.getMonth(), c.getDate()] 9644 } 9645 9646 function qa(a) { 9647 var b, c, d, e, f = []; 9648 if (!a._d) { 9649 for (d = pa(a), a._w && null == a._a[td] && null == a._a[sd] && ra(a), a._dayOfYear && (e = oa(a._a[rd], d[rd]), a._dayOfYear > ha(e) && (j(a)._overflowDayOfYear = !0), c = ga(e, 0, a._dayOfYear), a._a[sd] = c.getUTCMonth(), a._a[td] = c.getUTCDate()), b = 0; 3 > b && null == a._a[b]; ++b) a._a[b] = f[b] = d[b]; 9650 for (; 7 > b; b++) a._a[b] = f[b] = null == a._a[b] ? 2 === b ? 1 : 0 : a._a[b]; 9651 24 === a._a[ud] && 0 === a._a[vd] && 0 === a._a[wd] && 0 === a._a[xd] && (a._nextDay = !0, a._a[ud] = 0), a._d = (a._useUTC ? ga : fa).apply(null, f), null != a._tzm && a._d.setUTCMinutes(a._d.getUTCMinutes() - a._tzm), a._nextDay && (a._a[ud] = 24) 9652 } 9653 } 9654 9655 function ra(a) { 9656 var b, c, d, e, f, g, h, i; 9657 b = a._w, null != b.GG || null != b.W || null != b.E ? (f = 1, g = 4, c = oa(b.GG, a._a[rd], ma(Aa(), 1, 4).year), d = oa(b.W, 1), e = oa(b.E, 1), (1 > e || e > 7) && (i = !0)) : (f = a._locale._week.dow, g = a._locale._week.doy, c = oa(b.gg, a._a[rd], ma(Aa(), f, g).year), d = oa(b.w, 1), null != b.d ? (e = b.d, (0 > e || e > 6) && (i = !0)) : null != b.e ? (e = b.e + f, (b.e < 0 || b.e > 6) && (i = !0)) : e = f), 1 > d || d > na(c, f, g) ? j(a)._overflowWeeks = !0 : null != i ? j(a)._overflowWeekday = !0 : (h = la(c, d, e, f, g), a._a[rd] = h.year, a._dayOfYear = h.dayOfYear) 9658 } 9659 9660 function sa(b) { 9661 if (b._f === a.ISO_8601) return void da(b); 9662 b._a = [], j(b).empty = !0; 9663 var c, d, e, f, g, h = "" + b._i, 9664 i = h.length, 9665 k = 0; 9666 for (e = N(b._f, b._locale).match(Wc) || [], c = 0; c < e.length; c++) f = e[c], d = (h.match(P(f, b)) || [])[0], d && (g = h.substr(0, h.indexOf(d)), g.length > 0 && j(b).unusedInput.push(g), h = h.slice(h.indexOf(d) + d.length), k += d.length), Zc[f] ? (d ? j(b).empty = !1 : j(b).unusedTokens.push(f), T(f, d, b)) : b._strict && !d && j(b).unusedTokens.push(f); 9667 j(b).charsLeftOver = i - k, h.length > 0 && j(b).unusedInput.push(h), j(b).bigHour === !0 && b._a[ud] <= 12 && b._a[ud] > 0 && (j(b).bigHour = void 0), b._a[ud] = ta(b._locale, b._a[ud], b._meridiem), qa(b), _(b) 9668 } 9669 9670 function ta(a, b, c) { 9671 var d; 9672 return null == c ? b : null != a.meridiemHour ? a.meridiemHour(b, c) : null != a.isPM ? (d = a.isPM(c), d && 12 > b && (b += 12), d || 12 !== b || (b = 0), b) : b 9673 } 9674 9675 function ua(a) { 9676 var b, c, d, e, f; 9677 if (0 === a._f.length) return j(a).invalidFormat = !0, void (a._d = new Date(NaN)); 9678 for (e = 0; e < a._f.length; e++) f = 0, b = n({}, a), null != a._useUTC && (b._useUTC = a._useUTC), b._f = a._f[e], sa(b), k(b) && (f += j(b).charsLeftOver, f += 10 * j(b).unusedTokens.length, j(b).score = f, (null == d || d > f) && (d = f, c = b)); 9679 g(a, c || b) 9680 } 9681 9682 function va(a) { 9683 if (!a._d) { 9684 var b = C(a._i); 9685 a._a = e([b.year, b.month, b.day || b.date, b.hour, b.minute, b.second, b.millisecond], function (a) { 9686 return a && parseInt(a, 10) 9687 }), qa(a) 9688 } 9689 } 9690 9691 function wa(a) { 9692 var b = new o(_(xa(a))); 9693 return b._nextDay && (b.add(1, "d"), b._nextDay = void 0), b 9694 } 9695 9696 function xa(a) { 9697 var b = a._i, 9698 e = a._f; 9699 return a._locale = a._locale || z(a._l), null === b || void 0 === e && "" === b ? l({ 9700 nullInput: !0 9701 }) : ("string" == typeof b && (a._i = b = a._locale.preparse(b)), p(b) ? new o(_(b)) : (c(e) ? ua(a) : e ? sa(a) : d(b) ? a._d = b : ya(a), k(a) || (a._d = null), a)) 9702 } 9703 9704 function ya(b) { 9705 var f = b._i; 9706 void 0 === f ? b._d = new Date(a.now()) : d(f) ? b._d = new Date(+f) : "string" == typeof f ? ea(b) : c(f) ? (b._a = e(f.slice(0), function (a) { 9707 return parseInt(a, 10) 9708 }), qa(b)) : "object" == typeof f ? va(b) : "number" == typeof f ? b._d = new Date(f) : a.createFromInputFallback(b) 9709 } 9710 9711 function za(a, b, c, d, e) { 9712 var f = {}; 9713 return "boolean" == typeof c && (d = c, c = void 0), f._isAMomentObject = !0, f._useUTC = f._isUTC = e, f._l = c, f._i = a, f._f = b, f._strict = d, wa(f) 9714 } 9715 9716 function Aa(a, b, c, d) { 9717 return za(a, b, c, d, !1) 9718 } 9719 9720 function Ba(a, b) { 9721 var d, e; 9722 if (1 === b.length && c(b[0]) && (b = b[0]), !b.length) return Aa(); 9723 for (d = b[0], e = 1; e < b.length; ++e)(!b[e].isValid() || b[e][a](d)) && (d = b[e]); 9724 return d 9725 } 9726 9727 function Ca() { 9728 var a = [].slice.call(arguments, 0); 9729 return Ba("isBefore", a) 9730 } 9731 9732 function Da() { 9733 var a = [].slice.call(arguments, 0); 9734 return Ba("isAfter", a) 9735 } 9736 9737 function Ea(a) { 9738 var b = C(a), 9739 c = b.year || 0, 9740 d = b.quarter || 0, 9741 e = b.month || 0, 9742 f = b.week || 0, 9743 g = b.day || 0, 9744 h = b.hour || 0, 9745 i = b.minute || 0, 9746 j = b.second || 0, 9747 k = b.millisecond || 0; 9748 this._milliseconds = +k + 1e3 * j + 6e4 * i + 36e5 * h, this._days = +g + 7 * f, this._months = +e + 3 * d + 12 * c, this._data = {}, this._locale = z(), this._bubble() 9749 } 9750 9751 function Fa(a) { 9752 return a instanceof Ea 9753 } 9754 9755 function Ga(a, b) { 9756 J(a, 0, 0, function () { 9757 var a = this.utcOffset(), 9758 c = "+"; 9759 return 0 > a && (a = -a, c = "-"), c + I(~~(a / 60), 2) + b + I(~~a % 60, 2) 9760 }) 9761 } 9762 9763 function Ha(a, b) { 9764 var c = (b || "").match(a) || [], 9765 d = c[c.length - 1] || [], 9766 e = (d + "").match(Od) || ["-", 0, 0], 9767 f = +(60 * e[1]) + r(e[2]); 9768 return "+" === e[0] ? f : -f 9769 } 9770 9771 function Ia(b, c) { 9772 var e, f; 9773 return c._isUTC ? (e = c.clone(), f = (p(b) || d(b) ? +b : +Aa(b)) - +e, e._d.setTime(+e._d + f), a.updateOffset(e, !1), e) : Aa(b).local() 9774 } 9775 9776 function Ja(a) { 9777 return 15 * -Math.round(a._d.getTimezoneOffset() / 15) 9778 } 9779 9780 function Ka(b, c) { 9781 var d, e = this._offset || 0; 9782 return this.isValid() ? null != b ? ("string" == typeof b ? b = Ha(md, b) : Math.abs(b) < 16 && (b = 60 * b), !this._isUTC && c && (d = Ja(this)), this._offset = b, this._isUTC = !0, null != d && this.add(d, "m"), e !== b && (!c || this._changeInProgress ? $a(this, Va(b - e, "m"), 1, !1) : this._changeInProgress || (this._changeInProgress = !0, a.updateOffset(this, !0), this._changeInProgress = null)), this) : this._isUTC ? e : Ja(this) : null != b ? this : NaN 9783 } 9784 9785 function La(a, b) { 9786 return null != a ? ("string" != typeof a && (a = -a), this.utcOffset(a, b), this) : -this.utcOffset() 9787 } 9788 9789 function Ma(a) { 9790 return this.utcOffset(0, a) 9791 } 9792 9793 function Na(a) { 9794 return this._isUTC && (this.utcOffset(0, a), this._isUTC = !1, a && this.subtract(Ja(this), "m")), this 9795 } 9796 9797 function Oa() { 9798 return this._tzm ? this.utcOffset(this._tzm) : "string" == typeof this._i && this.utcOffset(Ha(ld, this._i)), this 9799 } 9800 9801 function Pa(a) { 9802 return this.isValid() ? (a = a ? Aa(a).utcOffset() : 0, (this.utcOffset() - a) % 60 === 0) : !1 9803 } 9804 9805 function Qa() { 9806 return this.utcOffset() > this.clone().month(0).utcOffset() || this.utcOffset() > this.clone().month(5).utcOffset() 9807 } 9808 9809 function Ra() { 9810 if (!m(this._isDSTShifted)) return this._isDSTShifted; 9811 var a = {}; 9812 if (n(a, this), a = xa(a), a._a) { 9813 var b = a._isUTC ? h(a._a) : Aa(a._a); 9814 this._isDSTShifted = this.isValid() && s(a._a, b.toArray()) > 0 9815 } else this._isDSTShifted = !1; 9816 return this._isDSTShifted 9817 } 9818 9819 function Sa() { 9820 return this.isValid() ? !this._isUTC : !1 9821 } 9822 9823 function Ta() { 9824 return this.isValid() ? this._isUTC : !1 9825 } 9826 9827 function Ua() { 9828 return this.isValid() ? this._isUTC && 0 === this._offset : !1 9829 } 9830 9831 function Va(a, b) { 9832 var c, d, e, g = a, 9833 h = null; 9834 return Fa(a) ? g = { 9835 ms: a._milliseconds, 9836 d: a._days, 9837 M: a._months 9838 } : "number" == typeof a ? (g = {}, b ? g[b] = a : g.milliseconds = a) : (h = Pd.exec(a)) ? (c = "-" === h[1] ? -1 : 1, g = { 9839 y: 0, 9840 d: r(h[td]) * c, 9841 h: r(h[ud]) * c, 9842 m: r(h[vd]) * c, 9843 s: r(h[wd]) * c, 9844 ms: r(h[xd]) * c 9845 }) : (h = Qd.exec(a)) ? (c = "-" === h[1] ? -1 : 1, g = { 9846 y: Wa(h[2], c), 9847 M: Wa(h[3], c), 9848 d: Wa(h[4], c), 9849 h: Wa(h[5], c), 9850 m: Wa(h[6], c), 9851 s: Wa(h[7], c), 9852 w: Wa(h[8], c) 9853 }) : null == g ? g = {} : "object" == typeof g && ("from" in g || "to" in g) && (e = Ya(Aa(g.from), Aa(g.to)), g = {}, g.ms = e.milliseconds, g.M = e.months), d = new Ea(g), Fa(a) && f(a, "_locale") && (d._locale = a._locale), d 9854 } 9855 9856 function Wa(a, b) { 9857 var c = a && parseFloat(a.replace(",", ".")); 9858 return (isNaN(c) ? 0 : c) * b 9859 } 9860 9861 function Xa(a, b) { 9862 var c = { 9863 milliseconds: 0, 9864 months: 0 9865 }; 9866 return c.months = b.month() - a.month() + 12 * (b.year() - a.year()), a.clone().add(c.months, "M").isAfter(b) && --c.months, c.milliseconds = +b - +a.clone().add(c.months, "M"), c 9867 } 9868 9869 function Ya(a, b) { 9870 var c; 9871 return a.isValid() && b.isValid() ? (b = Ia(b, a), a.isBefore(b) ? c = Xa(a, b) : (c = Xa(b, a), c.milliseconds = -c.milliseconds, c.months = -c.months), c) : { 9872 milliseconds: 0, 9873 months: 0 9874 } 9875 } 9876 9877 function Za(a, b) { 9878 return function (c, d) { 9879 var e, f; 9880 return null === d || isNaN(+d) || (ca(b, "moment()." + b + "(period, number) is deprecated. Please use moment()." + b + "(number, period)."), f = c, c = d, d = f), c = "string" == typeof c ? +c : c, e = Va(c, d), $a(this, e, a), this 9881 } 9882 } 9883 9884 function $a(b, c, d, e) { 9885 var f = c._milliseconds, 9886 g = c._days, 9887 h = c._months; 9888 b.isValid() && (e = null == e ? !0 : e, f && b._d.setTime(+b._d + f * d), g && G(b, "Date", F(b, "Date") + g * d), h && Y(b, F(b, "Month") + h * d), e && a.updateOffset(b, g || h)) 9889 } 9890 9891 function _a(a, b) { 9892 var c = a || Aa(), 9893 d = Ia(c, this).startOf("day"), 9894 e = this.diff(d, "days", !0), 9895 f = -6 > e ? "sameElse" : -1 > e ? "lastWeek" : 0 > e ? "lastDay" : 1 > e ? "sameDay" : 2 > e ? "nextDay" : 7 > e ? "nextWeek" : "sameElse", 9896 g = b && (D(b[f]) ? b[f]() : b[f]); 9897 return this.format(g || this.localeData().calendar(f, this, Aa(c))) 9898 } 9899 9900 function ab() { 9901 return new o(this) 9902 } 9903 9904 function bb(a, b) { 9905 var c = p(a) ? a : Aa(a); 9906 return this.isValid() && c.isValid() ? (b = B(m(b) ? "millisecond" : b), "millisecond" === b ? +this > +c : +c < +this.clone().startOf(b)) : !1 9907 } 9908 9909 function cb(a, b) { 9910 var c = p(a) ? a : Aa(a); 9911 return this.isValid() && c.isValid() ? (b = B(m(b) ? "millisecond" : b), "millisecond" === b ? +c > +this : +this.clone().endOf(b) < +c) : !1 9912 } 9913 9914 function db(a, b, c) { 9915 return this.isAfter(a, c) && this.isBefore(b, c) 9916 } 9917 9918 function eb(a, b) { 9919 var c, d = p(a) ? a : Aa(a); 9920 return this.isValid() && d.isValid() ? (b = B(b || "millisecond"), "millisecond" === b ? +this === +d : (c = +d, +this.clone().startOf(b) <= c && c <= +this.clone().endOf(b))) : !1 9921 } 9922 9923 function fb(a, b) { 9924 return this.isSame(a, b) || this.isAfter(a, b) 9925 } 9926 9927 function gb(a, b) { 9928 return this.isSame(a, b) || this.isBefore(a, b) 9929 } 9930 9931 function hb(a, b, c) { 9932 var d, e, f, g; 9933 return this.isValid() ? (d = Ia(a, this), d.isValid() ? (e = 6e4 * (d.utcOffset() - this.utcOffset()), b = B(b), "year" === b || "month" === b || "quarter" === b ? (g = ib(this, d), "quarter" === b ? g /= 3 : "year" === b && (g /= 12)) : (f = this - d, g = "second" === b ? f / 1e3 : "minute" === b ? f / 6e4 : "hour" === b ? f / 36e5 : "day" === b ? (f - e) / 864e5 : "week" === b ? (f - e) / 6048e5 : f), c ? g : q(g)) : NaN) : NaN 9934 } 9935 9936 function ib(a, b) { 9937 var c, d, e = 12 * (b.year() - a.year()) + (b.month() - a.month()), 9938 f = a.clone().add(e, "months"); 9939 return 0 > b - f ? (c = a.clone().add(e - 1, "months"), d = (b - f) / (f - c)) : (c = a.clone().add(e + 1, "months"), d = (b - f) / (c - f)), -(e + d) 9940 } 9941 9942 function jb() { 9943 return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ") 9944 } 9945 9946 function kb() { 9947 var a = this.clone().utc(); 9948 return 0 < a.year() && a.year() <= 9999 ? D(Date.prototype.toISOString) ? this.toDate().toISOString() : M(a, "YYYY-MM-DD[T]HH:mm:ss.SSS[Z]") : M(a, "YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]") 9949 } 9950 9951 function lb(b) { 9952 var c = M(this, b || a.defaultFormat); 9953 return this.localeData().postformat(c) 9954 } 9955 9956 function mb(a, b) { 9957 return this.isValid() && (p(a) && a.isValid() || Aa(a).isValid()) ? Va({ 9958 to: this, 9959 from: a 9960 }).locale(this.locale()).humanize(!b) : this.localeData().invalidDate() 9961 } 9962 9963 function nb(a) { 9964 return this.from(Aa(), a) 9965 } 9966 9967 function ob(a, b) { 9968 return this.isValid() && (p(a) && a.isValid() || Aa(a).isValid()) ? Va({ 9969 from: this, 9970 to: a 9971 }).locale(this.locale()).humanize(!b) : this.localeData().invalidDate() 9972 } 9973 9974 function pb(a) { 9975 return this.to(Aa(), a) 9976 } 9977 9978 function qb(a) { 9979 var b; 9980 return void 0 === a ? this._locale._abbr : (b = z(a), null != b && (this._locale = b), this) 9981 } 9982 9983 function rb() { 9984 return this._locale 9985 } 9986 9987 function sb(a) { 9988 switch (a = B(a)) { 9989 case "year": 9990 this.month(0); 9991 case "quarter": 9992 case "month": 9993 this.date(1); 9994 case "week": 9995 case "isoWeek": 9996 case "day": 9997 this.hours(0); 9998 case "hour": 9999 this.minutes(0); 10000 case "minute": 10001 this.seconds(0); 10002 case "second": 10003 this.milliseconds(0) 10004 } 10005 return "week" === a && this.weekday(0), "isoWeek" === a && this.isoWeekday(1), "quarter" === a && this.month(3 * Math.floor(this.month() / 3)), this 10006 } 10007 10008 function tb(a) { 10009 return a = B(a), void 0 === a || "millisecond" === a ? this : this.startOf(a).add(1, "isoWeek" === a ? "week" : a).subtract(1, "ms") 10010 } 10011 10012 function ub() { 10013 return +this._d - 6e4 * (this._offset || 0) 10014 } 10015 10016 function vb() { 10017 return Math.floor(+this / 1e3) 10018 } 10019 10020 function wb() { 10021 return this._offset ? new Date(+this) : this._d 10022 } 10023 10024 function xb() { 10025 var a = this; 10026 return [a.year(), a.month(), a.date(), a.hour(), a.minute(), a.second(), a.millisecond()] 10027 } 10028 10029 function yb() { 10030 var a = this; 10031 return { 10032 years: a.year(), 10033 months: a.month(), 10034 date: a.date(), 10035 hours: a.hours(), 10036 minutes: a.minutes(), 10037 seconds: a.seconds(), 10038 milliseconds: a.milliseconds() 10039 } 10040 } 10041 10042 function zb() { 10043 return this.isValid() ? this.toISOString() : "null" 10044 } 10045 10046 function Ab() { 10047 return k(this) 10048 } 10049 10050 function Bb() { 10051 return g({}, j(this)) 10052 } 10053 10054 function Cb() { 10055 return j(this).overflow 10056 } 10057 10058 function Db() { 10059 return { 10060 input: this._i, 10061 format: this._f, 10062 locale: this._locale, 10063 isUTC: this._isUTC, 10064 strict: this._strict 10065 } 10066 } 10067 10068 function Eb(a, b) { 10069 J(0, [a, a.length], 0, b) 10070 } 10071 10072 function Fb(a) { 10073 return Jb.call(this, a, this.week(), this.weekday(), this.localeData()._week.dow, this.localeData()._week.doy) 10074 } 10075 10076 function Gb(a) { 10077 return Jb.call(this, a, this.isoWeek(), this.isoWeekday(), 1, 4) 10078 } 10079 10080 function Hb() { 10081 return na(this.year(), 1, 4) 10082 } 10083 10084 function Ib() { 10085 var a = this.localeData()._week; 10086 return na(this.year(), a.dow, a.doy) 10087 } 10088 10089 function Jb(a, b, c, d, e) { 10090 var f; 10091 return null == a ? ma(this, d, e).year : (f = na(a, d, e), b > f && (b = f), Kb.call(this, a, b, c, d, e)) 10092 } 10093 10094 function Kb(a, b, c, d, e) { 10095 var f = la(a, b, c, d, e), 10096 g = ga(f.year, 0, f.dayOfYear); 10097 return this.year(g.getUTCFullYear()), this.month(g.getUTCMonth()), this.date(g.getUTCDate()), this 10098 } 10099 10100 function Lb(a) { 10101 return null == a ? Math.ceil((this.month() + 1) / 3) : this.month(3 * (a - 1) + this.month() % 3) 10102 } 10103 10104 function Mb(a) { 10105 return ma(a, this._week.dow, this._week.doy).week 10106 } 10107 10108 function Nb() { 10109 return this._week.dow 10110 } 10111 10112 function Ob() { 10113 return this._week.doy 10114 } 10115 10116 function Pb(a) { 10117 var b = this.localeData().week(this); 10118 return null == a ? b : this.add(7 * (a - b), "d") 10119 } 10120 10121 function Qb(a) { 10122 var b = ma(this, 1, 4).week; 10123 return null == a ? b : this.add(7 * (a - b), "d") 10124 } 10125 10126 function Rb(a, b) { 10127 return "string" != typeof a ? a : isNaN(a) ? (a = b.weekdaysParse(a), "number" == typeof a ? a : null) : parseInt(a, 10) 10128 } 10129 10130 function Sb(a, b) { 10131 return c(this._weekdays) ? this._weekdays[a.day()] : this._weekdays[this._weekdays.isFormat.test(b) ? "format" : "standalone"][a.day()] 10132 } 10133 10134 function Tb(a) { 10135 return this._weekdaysShort[a.day()] 10136 } 10137 10138 function Ub(a) { 10139 return this._weekdaysMin[a.day()] 10140 } 10141 10142 function Vb(a, b, c) { 10143 var d, e, f; 10144 for (this._weekdaysParse || (this._weekdaysParse = [], this._minWeekdaysParse = [], this._shortWeekdaysParse = [], this._fullWeekdaysParse = []), d = 0; 7 > d; d++) { 10145 if (e = Aa([2e3, 1]).day(d), c && !this._fullWeekdaysParse[d] && (this._fullWeekdaysParse[d] = new RegExp("^" + this.weekdays(e, "").replace(".", ".?") + "$", "i"), this._shortWeekdaysParse[d] = new RegExp("^" + this.weekdaysShort(e, "").replace(".", ".?") + "$", "i"), this._minWeekdaysParse[d] = new RegExp("^" + this.weekdaysMin(e, "").replace(".", ".?") + "$", "i")), this._weekdaysParse[d] || (f = "^" + this.weekdays(e, "") + "|^" + this.weekdaysShort(e, "") + "|^" + this.weekdaysMin(e, ""), this._weekdaysParse[d] = new RegExp(f.replace(".", ""), "i")), c && "dddd" === b && this._fullWeekdaysParse[d].test(a)) return d; 10146 if (c && "ddd" === b && this._shortWeekdaysParse[d].test(a)) return d; 10147 if (c && "dd" === b && this._minWeekdaysParse[d].test(a)) return d; 10148 if (!c && this._weekdaysParse[d].test(a)) return d 10149 } 10150 } 10151 10152 function Wb(a) { 10153 if (!this.isValid()) return null != a ? this : NaN; 10154 var b = this._isUTC ? this._d.getUTCDay() : this._d.getDay(); 10155 return null != a ? (a = Rb(a, this.localeData()), this.add(a - b, "d")) : b 10156 } 10157 10158 function Xb(a) { 10159 if (!this.isValid()) return null != a ? this : NaN; 10160 var b = (this.day() + 7 - this.localeData()._week.dow) % 7; 10161 return null == a ? b : this.add(a - b, "d") 10162 } 10163 10164 function Yb(a) { 10165 return this.isValid() ? null == a ? this.day() || 7 : this.day(this.day() % 7 ? a : a - 7) : null != a ? this : NaN 10166 } 10167 10168 function Zb(a) { 10169 var b = Math.round((this.clone().startOf("day") - this.clone().startOf("year")) / 864e5) + 1; 10170 return null == a ? b : this.add(a - b, "d") 10171 } 10172 10173 function $b() { 10174 return this.hours() % 12 || 12 10175 } 10176 10177 function _b(a, b) { 10178 J(a, 0, 0, function () { 10179 return this.localeData().meridiem(this.hours(), this.minutes(), b) 10180 }) 10181 } 10182 10183 function ac(a, b) { 10184 return b._meridiemParse 10185 } 10186 10187 function bc(a) { 10188 return "p" === (a + "").toLowerCase().charAt(0) 10189 } 10190 10191 function cc(a, b, c) { 10192 return a > 11 ? c ? "pm" : "PM" : c ? "am" : "AM" 10193 } 10194 10195 function dc(a, b) { 10196 b[xd] = r(1e3 * ("0." + a)) 10197 } 10198 10199 function ec() { 10200 return this._isUTC ? "UTC" : "" 10201 } 10202 10203 function fc() { 10204 return this._isUTC ? "Coordinated Universal Time" : "" 10205 } 10206 10207 function gc(a) { 10208 return Aa(1e3 * a) 10209 } 10210 10211 function hc() { 10212 return Aa.apply(null, arguments).parseZone() 10213 } 10214 10215 function ic(a, b, c) { 10216 var d = this._calendar[a]; 10217 return D(d) ? d.call(b, c) : d 10218 } 10219 10220 function jc(a) { 10221 var b = this._longDateFormat[a], 10222 c = this._longDateFormat[a.toUpperCase()]; 10223 return b || !c ? b : (this._longDateFormat[a] = c.replace(/MMMM|MM|DD|dddd/g, function (a) { 10224 return a.slice(1) 10225 }), this._longDateFormat[a]) 10226 } 10227 10228 function kc() { 10229 return this._invalidDate 10230 } 10231 10232 function lc(a) { 10233 return this._ordinal.replace("%d", a) 10234 } 10235 10236 function mc(a) { 10237 return a 10238 } 10239 10240 function nc(a, b, c, d) { 10241 var e = this._relativeTime[c]; 10242 return D(e) ? e(a, b, c, d) : e.replace(/%d/i, a) 10243 } 10244 10245 function oc(a, b) { 10246 var c = this._relativeTime[a > 0 ? "future" : "past"]; 10247 return D(c) ? c(b) : c.replace(/%s/i, b) 10248 } 10249 10250 function pc(a) { 10251 var b, c; 10252 for (c in a) b = a[c], D(b) ? this[c] = b : this["_" + c] = b; 10253 this._ordinalParseLenient = new RegExp(this._ordinalParse.source + "|" + /\d{1,2}/.source) 10254 } 10255 10256 function qc(a, b, c, d) { 10257 var e = z(), 10258 f = h().set(d, b); 10259 return e[c](f, a) 10260 } 10261 10262 function rc(a, b, c, d, e) { 10263 if ("number" == typeof a && (b = a, a = void 0), a = a || "", null != b) return qc(a, b, c, e); 10264 var f, g = []; 10265 for (f = 0; d > f; f++) g[f] = qc(a, f, c, e); 10266 return g 10267 } 10268 10269 function sc(a, b) { 10270 return rc(a, b, "months", 12, "month") 10271 } 10272 10273 function tc(a, b) { 10274 return rc(a, b, "monthsShort", 12, "month") 10275 } 10276 10277 function uc(a, b) { 10278 return rc(a, b, "weekdays", 7, "day") 10279 } 10280 10281 function vc(a, b) { 10282 return rc(a, b, "weekdaysShort", 7, "day") 10283 } 10284 10285 function wc(a, b) { 10286 return rc(a, b, "weekdaysMin", 7, "day") 10287 } 10288 10289 function xc() { 10290 var a = this._data; 10291 return this._milliseconds = me(this._milliseconds), this._days = me(this._days), this._months = me(this._months), a.milliseconds = me(a.milliseconds), a.seconds = me(a.seconds), a.minutes = me(a.minutes), a.hours = me(a.hours), a.months = me(a.months), a.years = me(a.years), this 10292 } 10293 10294 function yc(a, b, c, d) { 10295 var e = Va(b, c); 10296 return a._milliseconds += d * e._milliseconds, a._days += d * e._days, a._months += d * e._months, a._bubble() 10297 } 10298 10299 function zc(a, b) { 10300 return yc(this, a, b, 1) 10301 } 10302 10303 function Ac(a, b) { 10304 return yc(this, a, b, -1) 10305 } 10306 10307 function Bc(a) { 10308 return 0 > a ? Math.floor(a) : Math.ceil(a) 10309 } 10310 10311 function Cc() { 10312 var a, b, c, d, e, f = this._milliseconds, 10313 g = this._days, 10314 h = this._months, 10315 i = this._data; 10316 return f >= 0 && g >= 0 && h >= 0 || 0 >= f && 0 >= g && 0 >= h || (f += 864e5 * Bc(Ec(h) + g), g = 0, h = 0), i.milliseconds = f % 1e3, a = q(f / 1e3), i.seconds = a % 60, b = q(a / 60), i.minutes = b % 60, c = q(b / 60), i.hours = c % 24, g += q(c / 24), e = q(Dc(g)), h += e, g -= Bc(Ec(e)), d = q(h / 12), h %= 12, i.days = g, i.months = h, i.years = d, this 10317 } 10318 10319 function Dc(a) { 10320 return 4800 * a / 146097 10321 } 10322 10323 function Ec(a) { 10324 return 146097 * a / 4800 10325 } 10326 10327 function Fc(a) { 10328 var b, c, d = this._milliseconds; 10329 if (a = B(a), "month" === a || "year" === a) return b = this._days + d / 864e5, c = this._months + Dc(b), "month" === a ? c : c / 12; 10330 switch (b = this._days + Math.round(Ec(this._months)), a) { 10331 case "week": 10332 return b / 7 + d / 6048e5; 10333 case "day": 10334 return b + d / 864e5; 10335 case "hour": 10336 return 24 * b + d / 36e5; 10337 case "minute": 10338 return 1440 * b + d / 6e4; 10339 case "second": 10340 return 86400 * b + d / 1e3; 10341 case "millisecond": 10342 return Math.floor(864e5 * b) + d; 10343 default: 10344 throw new Error("Unknown unit " + a) 10345 } 10346 } 10347 10348 function Gc() { 10349 return this._milliseconds + 864e5 * this._days + this._months % 12 * 2592e6 + 31536e6 * r(this._months / 12) 10350 } 10351 10352 function Hc(a) { 10353 return function () { 10354 return this.as(a) 10355 } 10356 } 10357 10358 function Ic(a) { 10359 return a = B(a), this[a + "s"]() 10360 } 10361 10362 function Jc(a) { 10363 return function () { 10364 return this._data[a] 10365 } 10366 } 10367 10368 function Kc() { 10369 return q(this.days() / 7) 10370 } 10371 10372 function Lc(a, b, c, d, e) { 10373 return e.relativeTime(b || 1, !!c, a, d) 10374 } 10375 10376 function Mc(a, b, c) { 10377 var d = Va(a).abs(), 10378 e = Ce(d.as("s")), 10379 f = Ce(d.as("m")), 10380 g = Ce(d.as("h")), 10381 h = Ce(d.as("d")), 10382 i = Ce(d.as("M")), 10383 j = Ce(d.as("y")), 10384 k = e < De.s && ["s", e] || 1 >= f && ["m"] || f < De.m && ["mm", f] || 1 >= g && ["h"] || g < De.h && ["hh", g] || 1 >= h && ["d"] || h < De.d && ["dd", h] || 1 >= i && ["M"] || i < De.M && ["MM", i] || 1 >= j && ["y"] || ["yy", j]; 10385 return k[2] = b, k[3] = +a > 0, k[4] = c, Lc.apply(null, k) 10386 } 10387 10388 function Nc(a, b) { 10389 return void 0 === De[a] ? !1 : void 0 === b ? De[a] : (De[a] = b, !0) 10390 } 10391 10392 function Oc(a) { 10393 var b = this.localeData(), 10394 c = Mc(this, !a, b); 10395 return a && (c = b.pastFuture(+this, c)), b.postformat(c) 10396 } 10397 10398 function Pc() { 10399 var a, b, c, d = Ee(this._milliseconds) / 1e3, 10400 e = Ee(this._days), 10401 f = Ee(this._months); 10402 a = q(d / 60), b = q(a / 60), d %= 60, a %= 60, c = q(f / 12), f %= 12; 10403 var g = c, 10404 h = f, 10405 i = e, 10406 j = b, 10407 k = a, 10408 l = d, 10409 m = this.asSeconds(); 10410 return m ? (0 > m ? "-" : "") + "P" + (g ? g + "Y" : "") + (h ? h + "M" : "") + (i ? i + "D" : "") + (j || k || l ? "T" : "") + (j ? j + "H" : "") + (k ? k + "M" : "") + (l ? l + "S" : "") : "P0D" 10411 } 10412 var Qc, Rc, Sc = a.momentProperties = [], 10413 Tc = !1, 10414 Uc = {}, 10415 Vc = {}, 10416 Wc = /(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g, 10417 Xc = /(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g, 10418 Yc = {}, 10419 Zc = {}, 10420 $c = /\d/, 10421 _c = /\d\d/, 10422 ad = /\d{3}/, 10423 bd = /\d{4}/, 10424 cd = /[+-]?\d{6}/, 10425 dd = /\d\d?/, 10426 ed = /\d\d\d\d?/, 10427 fd = /\d\d\d\d\d\d?/, 10428 gd = /\d{1,3}/, 10429 hd = /\d{1,4}/, 10430 id = /[+-]?\d{1,6}/, 10431 jd = /\d+/, 10432 kd = /[+-]?\d+/, 10433 ld = /Z|[+-]\d\d:?\d\d/gi, 10434 md = /Z|[+-]\d\d(?::?\d\d)?/gi, 10435 nd = /[+-]?\d+(\.\d{1,3})?/, 10436 od = /[0-9]*(a[mn]\s?)?['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF\-]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i, 10437 pd = {}, 10438 qd = {}, 10439 rd = 0, 10440 sd = 1, 10441 td = 2, 10442 ud = 3, 10443 vd = 4, 10444 wd = 5, 10445 xd = 6, 10446 yd = 7, 10447 zd = 8; 10448 J("M", ["MM", 2], "Mo", function () { 10449 return this.month() + 1 10450 }), J("MMM", 0, 0, function (a) { 10451 return this.localeData().monthsShort(this, a) 10452 }), J("MMMM", 0, 0, function (a) { 10453 return this.localeData().months(this, a) 10454 }), A("month", "M"), O("M", dd), O("MM", dd, _c), O("MMM", od), O("MMMM", od), R(["M", "MM"], function (a, b) { 10455 b[sd] = r(a) - 1 10456 }), R(["MMM", "MMMM"], function (a, b, c, d) { 10457 var e = c._locale.monthsParse(a, d, c._strict); 10458 null != e ? b[sd] = e : j(c).invalidMonth = a 10459 }); 10460 var Ad = /D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/, 10461 Bd = "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), 10462 Cd = "Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sept_Oct_Nov_Dec".split("_"), 10463 Dd = {}; 10464 a.suppressDeprecationWarnings = !1; 10465 var Ed = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/, 10466 Fd = /^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?/, 10467 Gd = /Z|[+-]\d\d(?::?\d\d)?/, 10468 Hd = [ 10469 ["YYYYYY-MM-DD", /[+-]\d{6}-\d\d-\d\d/], 10470 ["YYYY-MM-DD", /\d{4}-\d\d-\d\d/], 10471 ["GGGG-[W]WW-E", /\d{4}-W\d\d-\d/], 10472 ["GGGG-[W]WW", /\d{4}-W\d\d/, !1], 10473 ["YYYY-DDD", /\d{4}-\d{3}/], 10474 ["YYYY-MM", /\d{4}-\d\d/, !1], 10475 ["YYYYYYMMDD", /[+-]\d{10}/], 10476 ["YYYYMMDD", /\d{8}/], 10477 ["GGGG[W]WWE", /\d{4}W\d{3}/], 10478 ["GGGG[W]WW", /\d{4}W\d{2}/, !1], 10479 ["YYYYDDD", /\d{7}/] 10480 ], 10481 Id = [ 10482 ["HH:mm:ss.SSSS", /\d\d:\d\d:\d\d\.\d+/], 10483 ["HH:mm:ss,SSSS", /\d\d:\d\d:\d\d,\d+/], 10484 ["HH:mm:ss", /\d\d:\d\d:\d\d/], 10485 ["HH:mm", /\d\d:\d\d/], 10486 ["HHmmss.SSSS", /\d\d\d\d\d\d\.\d+/], 10487 ["HHmmss,SSSS", /\d\d\d\d\d\d,\d+/], 10488 ["HHmmss", /\d\d\d\d\d\d/], 10489 ["HHmm", /\d\d\d\d/], 10490 ["HH", /\d\d/] 10491 ], 10492 Jd = /^\/?Date\((\-?\d+)/i; 10493 a.createFromInputFallback = ba("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.", function (a) { 10494 a._d = new Date(a._i + (a._useUTC ? " UTC" : "")) 10495 }), J(0, ["YY", 2], 0, function () { 10496 return this.year() % 100 10497 }), J(0, ["YYYY", 4], 0, "year"), J(0, ["YYYYY", 5], 0, "year"), J(0, ["YYYYYY", 6, !0], 0, "year"), A("year", "y"), O("Y", kd), O("YY", dd, _c), O("YYYY", hd, bd), O("YYYYY", id, cd), O("YYYYYY", id, cd), R(["YYYYY", "YYYYYY"], rd), R("YYYY", function (b, c) { 10498 c[rd] = 2 === b.length ? a.parseTwoDigitYear(b) : r(b) 10499 }), R("YY", function (b, c) { 10500 c[rd] = a.parseTwoDigitYear(b) 10501 }), a.parseTwoDigitYear = function (a) { 10502 return r(a) + (r(a) > 68 ? 1900 : 2e3) 10503 }; 10504 var Kd = E("FullYear", !1); 10505 a.ISO_8601 = function () { }; 10506 var Ld = ba("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548", function () { 10507 var a = Aa.apply(null, arguments); 10508 return this.isValid() && a.isValid() ? this > a ? this : a : l() 10509 }), 10510 Md = ba("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548", function () { 10511 var a = Aa.apply(null, arguments); 10512 return this.isValid() && a.isValid() ? a > this ? this : a : l() 10513 }), 10514 Nd = Date.now || function () { 10515 return +new Date 10516 }; 10517 Ga("Z", ":"), Ga("ZZ", ""), O("Z", md), O("ZZ", md), R(["Z", "ZZ"], function (a, b, c) { 10518 c._useUTC = !0, c._tzm = Ha(md, a) 10519 }); 10520 var Od = /([\+\-]|\d\d)/gi; 10521 a.updateOffset = function () { }; 10522 var Pd = /(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/, 10523 Qd = /^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/; 10524 Va.fn = Ea.prototype; 10525 var Rd = Za(1, "add"), 10526 Sd = Za(-1, "subtract"); 10527 a.defaultFormat = "YYYY-MM-DDTHH:mm:ssZ"; 10528 var Td = ba("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.", function (a) { 10529 return void 0 === a ? this.localeData() : this.locale(a) 10530 }); 10531 J(0, ["gg", 2], 0, function () { 10532 return this.weekYear() % 100 10533 }), J(0, ["GG", 2], 0, function () { 10534 return this.isoWeekYear() % 100 10535 }), Eb("gggg", "weekYear"), Eb("ggggg", "weekYear"), Eb("GGGG", "isoWeekYear"), Eb("GGGGG", "isoWeekYear"), A("weekYear", "gg"), A("isoWeekYear", "GG"), O("G", kd), O("g", kd), O("GG", dd, _c), O("gg", dd, _c), O("GGGG", hd, bd), O("gggg", hd, bd), O("GGGGG", id, cd), O("ggggg", id, cd), S(["gggg", "ggggg", "GGGG", "GGGGG"], function (a, b, c, d) { 10536 b[d.substr(0, 2)] = r(a) 10537 }), S(["gg", "GG"], function (b, c, d, e) { 10538 c[e] = a.parseTwoDigitYear(b) 10539 }), J("Q", 0, "Qo", "quarter"), A("quarter", "Q"), O("Q", $c), R("Q", function (a, b) { 10540 b[sd] = 3 * (r(a) - 1) 10541 }), J("w", ["ww", 2], "wo", "week"), J("W", ["WW", 2], "Wo", "isoWeek"), A("week", "w"), A("isoWeek", "W"), O("w", dd), O("ww", dd, _c), O("W", dd), O("WW", dd, _c), S(["w", "ww", "W", "WW"], function (a, b, c, d) { 10542 b[d.substr(0, 1)] = r(a) 10543 }); 10544 var Ud = { 10545 dow: 0, 10546 doy: 6 10547 }; 10548 J("D", ["DD", 2], "Do", "date"), A("date", "D"), O("D", dd), O("DD", dd, _c), O("Do", function (a, b) { 10549 return a ? b._ordinalParse : b._ordinalParseLenient 10550 }), R(["D", "DD"], td), R("Do", function (a, b) { 10551 b[td] = r(a.match(dd)[0], 10) 10552 }); 10553 var Vd = E("Date", !0); 10554 J("d", 0, "do", "day"), J("dd", 0, 0, function (a) { 10555 return this.localeData().weekdaysMin(this, a) 10556 }), J("ddd", 0, 0, function (a) { 10557 return this.localeData().weekdaysShort(this, a) 10558 }), J("dddd", 0, 0, function (a) { 10559 return this.localeData().weekdays(this, a) 10560 }), J("e", 0, 0, "weekday"), J("E", 0, 0, "isoWeekday"), A("day", "d"), A("weekday", "e"), A("isoWeekday", "E"), O("d", dd), O("e", dd), O("E", dd), O("dd", od), O("ddd", od), O("dddd", od), S(["dd", "ddd", "dddd"], function (a, b, c, d) { 10561 var e = c._locale.weekdaysParse(a, d, c._strict); 10562 null != e ? b.d = e : j(c).invalidWeekday = a 10563 }), S(["d", "e", "E"], function (a, b, c, d) { 10564 b[d] = r(a) 10565 }); 10566 var Wd = "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), 10567 Xd = "Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"), 10568 Yd = "Su_Mo_Tu_We_Th_Fr_Sa".split("_"); 10569 J("DDD", ["DDDD", 3], "DDDo", "dayOfYear"), A("dayOfYear", "DDD"), O("DDD", gd), O("DDDD", ad), R(["DDD", "DDDD"], function (a, b, c) { 10570 c._dayOfYear = r(a) 10571 }), J("H", ["HH", 2], 0, "hour"), J("h", ["hh", 2], 0, $b), J("hmm", 0, 0, function () { 10572 return "" + $b.apply(this) + I(this.minutes(), 2) 10573 }), J("hmmss", 0, 0, function () { 10574 return "" + $b.apply(this) + I(this.minutes(), 2) + I(this.seconds(), 2) 10575 }), J("Hmm", 0, 0, function () { 10576 return "" + this.hours() + I(this.minutes(), 2) 10577 }), J("Hmmss", 0, 0, function () { 10578 return "" + this.hours() + I(this.minutes(), 2) + I(this.seconds(), 2) 10579 }), _b("a", !0), _b("A", !1), A("hour", "h"), O("a", ac), O("A", ac), O("H", dd), O("h", dd), O("HH", dd, _c), O("hh", dd, _c), O("hmm", ed), O("hmmss", fd), O("Hmm", ed), O("Hmmss", fd), R(["H", "HH"], ud), R(["a", "A"], function (a, b, c) { 10580 c._isPm = c._locale.isPM(a), c._meridiem = a 10581 }), R(["h", "hh"], function (a, b, c) { 10582 b[ud] = r(a), j(c).bigHour = !0 10583 }), R("hmm", function (a, b, c) { 10584 var d = a.length - 2; 10585 b[ud] = r(a.substr(0, d)), b[vd] = r(a.substr(d)), j(c).bigHour = !0 10586 }), R("hmmss", function (a, b, c) { 10587 var d = a.length - 4, 10588 e = a.length - 2; 10589 b[ud] = r(a.substr(0, d)), b[vd] = r(a.substr(d, 2)), b[wd] = r(a.substr(e)), j(c).bigHour = !0 10590 }), R("Hmm", function (a, b, c) { 10591 var d = a.length - 2; 10592 b[ud] = r(a.substr(0, d)), b[vd] = r(a.substr(d)) 10593 }), R("Hmmss", function (a, b, c) { 10594 var d = a.length - 4, 10595 e = a.length - 2; 10596 b[ud] = r(a.substr(0, d)), b[vd] = r(a.substr(d, 2)), b[wd] = r(a.substr(e)) 10597 }); 10598 var Zd = /[ap]\.?m?\.?/i, 10599 $d = E("Hours", !0); 10600 J("m", ["mm", 2], 0, "minute"), A("minute", "m"), O("m", dd), O("mm", dd, _c), R(["m", "mm"], vd); 10601 var _d = E("Minutes", !1); 10602 J("s", ["ss", 2], 0, "second"), A("second", "s"), O("s", dd), O("ss", dd, _c), R(["s", "ss"], wd); 10603 var ae = E("Seconds", !1); 10604 J("S", 0, 0, function () { 10605 return ~~(this.millisecond() / 100) 10606 }), J(0, ["SS", 2], 0, function () { 10607 return ~~(this.millisecond() / 10) 10608 }), J(0, ["SSS", 3], 0, "millisecond"), J(0, ["SSSS", 4], 0, function () { 10609 return 10 * this.millisecond() 10610 }), J(0, ["SSSSS", 5], 0, function () { 10611 return 100 * this.millisecond() 10612 }), J(0, ["SSSSSS", 6], 0, function () { 10613 return 1e3 * this.millisecond() 10614 }), J(0, ["SSSSSSS", 7], 0, function () { 10615 return 1e4 * this.millisecond() 10616 }), J(0, ["SSSSSSSS", 8], 0, function () { 10617 return 1e5 * this.millisecond() 10618 }), J(0, ["SSSSSSSSS", 9], 0, function () { 10619 return 1e6 * this.millisecond() 10620 }), A("millisecond", "ms"), O("S", gd, $c), O("SS", gd, _c), O("SSS", gd, ad); 10621 var be; 10622 for (be = "SSSS"; be.length <= 9; be += "S") O(be, jd); 10623 for (be = "S"; be.length <= 9; be += "S") R(be, dc); 10624 var ce = E("Milliseconds", !1); 10625 J("z", 0, 0, "zoneAbbr"), J("zz", 0, 0, "zoneName"); 10626 var de = o.prototype; 10627 de.add = Rd, de.calendar = _a, de.clone = ab, de.diff = hb, de.endOf = tb, de.format = lb, de.from = mb, de.fromNow = nb, de.to = ob, de.toNow = pb, de.get = H, de.invalidAt = Cb, de.isAfter = bb, de.isBefore = cb, de.isBetween = db, de.isSame = eb, de.isSameOrAfter = fb, de.isSameOrBefore = gb, de.isValid = Ab, de.lang = Td, de.locale = qb, de.localeData = rb, de.max = Md, de.min = Ld, de.parsingFlags = Bb, de.set = H, de.startOf = sb, de.subtract = Sd, de.toArray = xb, de.toObject = yb, de.toDate = wb, de.toISOString = kb, de.toJSON = zb, de.toString = jb, de.unix = vb, de.valueOf = ub, de.creationData = Db, de.year = Kd, de.isLeapYear = ja, de.weekYear = Fb, de.isoWeekYear = Gb, de.quarter = de.quarters = Lb, de.month = Z, de.daysInMonth = $, de.week = de.weeks = Pb, de.isoWeek = de.isoWeeks = Qb, de.weeksInYear = Ib, de.isoWeeksInYear = Hb, de.date = Vd, de.day = de.days = Wb, de.weekday = Xb, de.isoWeekday = Yb, de.dayOfYear = Zb, de.hour = de.hours = $d, de.minute = de.minutes = _d, de.second = de.seconds = ae, de.millisecond = de.milliseconds = ce, de.utcOffset = Ka, de.utc = Ma, de.local = Na, de.parseZone = Oa, de.hasAlignedHourOffset = Pa, de.isDST = Qa, de.isDSTShifted = Ra, de.isLocal = Sa, de.isUtcOffset = Ta, de.isUtc = Ua, de.isUTC = Ua, de.zoneAbbr = ec, de.zoneName = fc, de.dates = ba("dates accessor is deprecated. Use date instead.", Vd), de.months = ba("months accessor is deprecated. Use month instead", Z), de.years = ba("years accessor is deprecated. Use year instead", Kd), de.zone = ba("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779", La); 10628 var ee = de, 10629 fe = { 10630 sameDay: "[Today at] LT", 10631 nextDay: "[Tomorrow at] LT", 10632 nextWeek: "dddd [at] LT", 10633 lastDay: "[Yesterday at] LT", 10634 lastWeek: "[Last] dddd [at] LT", 10635 sameElse: "L" 10636 }, 10637 ge = { 10638 LTS: "h:mm:ss A", 10639 LT: "h:mm A", 10640 L: "MM/DD/YYYY", 10641 LL: "MMMM D, YYYY", 10642 LLL: "MMMM D, YYYY h:mm A", 10643 LLLL: "dddd, MMMM D, YYYY h:mm A" 10644 }, 10645 he = "Invalid date", 10646 ie = "%d", 10647 je = /\d{1,2}/, 10648 ke = { 10649 future: "in %s", 10650 past: "%s ago", 10651 s: "a few seconds", 10652 m: "a minute", 10653 mm: "%d minutes", 10654 h: "an hour", 10655 hh: "%d hours", 10656 d: "a day", 10657 dd: "%d days", 10658 M: "a month", 10659 MM: "%d months", 10660 y: "a year", 10661 yy: "%d years" 10662 }, 10663 le = t.prototype; 10664 le._calendar = fe, le.calendar = ic, le._longDateFormat = ge, le.longDateFormat = jc, le._invalidDate = he, le.invali
10664dDate = kc, le._ordinal = ie, le.ordinal = lc, le._ordinalParse = je, le.preparse = mc, le.postformat = mc, le._relativeTime = ke, le.relativeTime = nc, le.pastFuture = oc, le.set = pc, le.months = V, le._months = Bd, le.monthsShort = W, le._monthsShort = Cd, le.monthsParse = X, le.week = Mb, le._week = Ud, le.firstDayOfYear = Ob, le.firstDayOfWeek = Nb, le.weekdays = Sb, le._weekdays = Wd, le.weekdaysMin = Ub, le._weekdaysMin = Yd, le.weekdaysShort = Tb, le._weekdaysShort = Xd, le.weekdaysParse = Vb, le.isPM = bc, le._meridiemParse = Zd, le.meridiem = cc, x("en", { 10665 monthsParse: [/^jan/i, /^feb/i, /^mar/i, /^apr/i, /^may/i, /^jun/i, /^jul/i, /^aug/i, /^sep/i, /^oct/i, /^nov/i, /^dec/i], 10666 longMonthsParse: [/^january$/i, /^february$/i, /^march$/i, /^april$/i, /^may$/i, /^june$/i, /^july$/i, /^august$/i, /^september$/i, /^october$/i, /^november$/i, /^december$/i], 10667 shortMonthsParse: [/^jan$/i, /^feb$/i, /^mar$/i, /^apr$/i, /^may$/i, /^jun$/i, /^jul$/i, /^aug/i, /^sept?$/i, /^oct$/i, /^nov$/i, /^dec$/i], 10668 ordinalParse: /\d{1,2}(th|st|nd|rd)/, 10669 ordinal: function (a) { 10670 var b = a % 10, 10671 c = 1 === r(a % 100 / 10) ? "th" : 1 === b ? "st" : 2 === b ? "nd" : 3 === b ? "rd" : "th"; 10672 return a + c 10673 } 10674 }), a.lang = ba("moment.lang is deprecated. Use moment.locale instead.", x), a.langData = ba("moment.langData is deprecated. Use moment.localeData instead.", z); 10675 var me = Math.abs, 10676 ne = Hc("ms"), 10677 oe = Hc("s"), 10678 pe = Hc("m"), 10679 qe = Hc("h"), 10680 re = Hc("d"), 10681 se = Hc("w"), 10682 te = Hc("M"), 10683 ue = Hc("y"), 10684 ve = Jc("milliseconds"), 10685 we = Jc("seconds"), 10686 xe = Jc("minutes"), 10687 ye = Jc("hours"), 10688 ze = Jc("days"), 10689 Ae = Jc("months"), 10690 Be = Jc("years"), 10691 Ce = Math.round, 10692 De = { 10693 s: 45, 10694 m: 45, 10695 h: 22, 10696 d: 26, 10697 M: 11 10698 }, 10699 Ee = Math.abs, 10700 Fe = Ea.prototype; 10701 Fe.abs = xc, Fe.add = zc, Fe.subtract = Ac, Fe.as = Fc, Fe.asMilliseconds = ne, Fe.asSeconds = oe, Fe.asMinutes = pe, Fe.asHours = qe, Fe.asDays = re, Fe.asWeeks = se, Fe.asMonths = te, Fe.asYears = ue, Fe.valueOf = Gc, Fe._bubble = Cc, Fe.get = Ic, Fe.milliseconds = ve, Fe.seconds = we, Fe.minutes = xe, Fe.hours = ye, Fe.days = ze, Fe.weeks = Kc, Fe.months = Ae, Fe.years = Be, Fe.humanize = Oc, Fe.toISOString = Pc, Fe.toString = Pc, Fe.toJSON = Pc, Fe.locale = qb, Fe.localeData = rb, Fe.toIsoString = ba("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)", Pc), Fe.lang = Td, J("X", 0, 0, "unix"), J("x", 0, 0, "valueOf"), O("x", kd), O("X", nd), R("X", function (a, b, c) { 10702 c._d = new Date(1e3 * parseFloat(a, 10)) 10703 }), R("x", function (a, b, c) { 10704 c._d = new Date(r(a)) 10705 }), a.version = "2.11.0", b(Aa), a.fn = ee, a.min = Ca, a.max = Da, a.now = Nd, a.utc = h, a.unix = gc, a.months = sc, a.isDate = d, a.locale = x, a.invalid = l, a.duration = Va, a.isMoment = p, a.weekdays = uc, a.parseZone = hc, a.localeData = z, a.isDuration = Fa, a.monthsShort = tc, a.weekdaysMin = wc, a.defineLocale = y, a.weekdaysShort = vc, a.normalizeUnits = B, a.relativeTimeThreshold = Nc, a.prototype = ee; 10706 var Ge = a; 10707 return Ge 10708}); 10709 10710 10711/* 10712 * Clock1 - The Final Countdown 10713 * ----------------------------------------------- 10714 */ 10715/*! 10716 * The Final Countdown for jQuery v2.1.0 (http://hilios.github.io/jQuery.countdown/) 10717 * Copyright (c) 2015 Edson Hilios 10718 * 10719 * Permission is hereby granted, free of charge, to any person obtaining a copy of 10720 * this software and associated documentation files (the "Software"), to deal in 10721 * the Software without restriction, including without limitation the rights to 10722 * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 10723 * the Software, and to permit persons to whom the Software is furnished to do so, 10724 * subject to the following conditions: 10725 * 10726 * The above copyright notice and this permission notice shall be included in all 10727 * copies or substantial portions of the Software. 10728 * 10729 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 10730 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 10731 * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 10732 * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 10733 * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 10734 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10735 */ 10736! function (a) { 10737 "use strict"; 10738 "function" == typeof define && define.amd ? define(["jquery"], a) : a(jQuery) 10739}(function (a) { 10740 "use strict"; 10741 10742 function b(a) { 10743 if (a instanceof Date) return a; 10744 if (String(a).match(g)) return String(a).match(/^[0-9]*$/) && (a = Number(a)), String(a).match(/\-/) && (a = String(a).replace(/\-/g, "/")), new Date(a); 10745 throw new Error("Couldn't cast `" + a + "` to a date object.") 10746 } 10747 10748 function c(a) { 10749 var b = a.toString().replace(/([.?*+^$[\]\\(){}|-])/g, "\\$1"); 10750 return new RegExp(b) 10751 } 10752 10753 function d(a) { 10754 return function (b) { 10755 var d = b.match(/%(-|!)?[A-Z]{1}(:[^;]+;)?/gi); 10756 if (d) 10757 for (var f = 0, g = d.length; g > f; ++f) { 10758 var h = d[f].match(/%(-|!)?([a-zA-Z]{1})(:[^;]+;)?/),
vendor: 4,049 bytes, lines 10759-10839
10759 j = c(h[0]), 10760 k = h[1] || "", 10761 l = h[3] || "", 10762 m = null; 10763 h = h[2], i.hasOwnProperty(h) && (m = i[h], m = Number(a[m])), null !== m && ("!" === k && (m = e(l, m)), "" === k && 10 > m && (m = "0" + m.toString()), b = b.replace(j, m.toString())) 10764 } 10765 return b = b.replace(/%%/, "%") 10766 } 10767 } 10768 10769 function e(a, b) { 10770 var c = "s", 10771 d = ""; 10772 return a && (a = a.replace(/(:|;|\s)/gi, "").split(/\,/), 1 === a.length ? c = a[0] : (d = a[0], c = a[1])), 1 === Math.abs(b) ? d : c 10773 } 10774 var f = [], 10775 g = [], 10776 h = { 10777 precision: 100, 10778 elapse: !1 10779 }; 10780 g.push(/^[0-9]*$/.source), g.push(/([0-9]{1,2}\/){2}[0-9]{4}( [0-9]{1,2}(:[0-9]{2}){2})?/.source), g.push(/[0-9]{4}([\/\-][0-9]{1,2}){2}( [0-9]{1,2}(:[0-9]{2}){2})?/.source), g = new RegExp(g.join("|")); 10781 var i = { 10782 Y: "years", 10783 m: "months", 10784 n: "daysToMonth", 10785 w: "weeks", 10786 d: "daysToWeek", 10787 D: "totalDays", 10788 H: "hours", 10789 M: "minutes", 10790 S: "seconds" 10791 }, 10792 j = function (b, c, d) { 10793 this.el = b, this.$el = a(b), this.interval = null, this.offset = {}, this.options = a.extend({}, h), this.instanceNumber = f.length, f.push(this), this.$el.data("countdown-instance", this.instanceNumber), d && ("function" == typeof d ? (this.$el.on("update.countdown", d), this.$el.on("stoped.countdown", d), this.$el.on("finish.countdown", d)) : this.options = a.extend({}, h, d)), this.setFinalDate(c), this.start() 10794 }; 10795 a.extend(j.prototype, { 10796 start: function () { 10797 null !== this.interval && clearInterval(this.interval); 10798 var a = this; 10799 this.update(), this.interval = setInterval(function () { 10800 a.update.call(a) 10801 }, this.options.precision) 10802 }, 10803 stop: function () { 10804 clearInterval(this.interval), this.interval = null, this.dispatchEvent("stoped") 10805 }, 10806 toggle: function () { 10807 this.interval ? this.stop() : this.start() 10808 }, 10809 pause: function () { 10810 this.stop() 10811 }, 10812 resume: function () { 10813 this.start() 10814 }, 10815 remove: function () { 10816 this.stop.call(this), f[this.instanceNumber] = null, delete this.$el.data().countdownInstance 10817 }, 10818 setFinalDate: function (a) { 10819 this.finalDate = b(a) 10820 }, 10821 update: function () { 10822 if (0 === this.$el.closest("html").length) return void this.remove(); 10823 var b, c = void 0 !== a._data(this.el, "events"), 10824 d = new Date; 10825 b = this.finalDate.getTime() - d.getTime(), b = Math.ceil(b / 1e3), b = !this.options.elapse && 0 > b ? 0 : Math.abs(b), this.totalSecsLeft !== b && c && (this.totalSecsLeft = b, this.elapsed = d >= this.finalDate, this.offset = { 10826 seconds: this.totalSecsLeft % 60, 10827 minutes: Math.floor(this.totalSecsLeft / 60) % 60, 10828 hours: Math.floor(this.totalSecsLeft / 60 / 60) % 24, 10829 days: Math.floor(this.totalSecsLeft / 60 / 60 / 24) % 7, 10830 daysToWeek: Math.floor(this.totalSecsLeft / 60 / 60 / 24) % 7, 10831 daysToMonth: Math.floor(this.totalSecsLeft / 60 / 60 / 24 % 30.4368), 10832 totalDays: Math.floor(this.totalSecsLeft / 60 / 60 / 24), 10833 weeks: Math.floor(this.totalSecsLeft / 60 / 60 / 24 / 7), 10834 months: Math.floor(this.totalSecsLeft / 60 / 60 / 24 / 30.4368), 10835 years: Math.abs(this.finalDate.getFullYear() - d.getFullYear()) 10836 }, this.options.elapse || 0 !== this.totalSecsLeft ? this.dispatchEvent("update") : (this.stop(), this.dispatchEvent("finish"))) 10837 }, 10838 dispatchEvent: function (b) { 10839 var c = a.Event(b + ".countdown");
10840 c.finalDate = this.finalDate, c.elapsed = this.elapsed, c.offset = a.extend({}, this.offset), c.strftime = d(this.offset), this.$el.trigger(c) 10841 } 10842 }), a.fn.countdown = function () { 10843 var b = Array.prototype.slice.call(arguments, 0); 10844 return this.each(function () { 10845 var c = a(this).data("countdown-instance"); 10846 if (void 0 !== c) { 10847 var d = f[c], 10848 e = b[0]; 10849 j.prototype.hasOwnProperty(e) ? d[e].apply(d, b.slice(1)) : null === String(e).match(/^[$A-Z_][0-9A-Z_$]*$/i) ? (d.setFinalDate.call(d, e), d.start()) : a.error("Method %s does not exist on jQuery.countdown".replace(/\%s/gi, e)) 10850 } else new j(this, b[0], b[1]) 10851 }) 10852 } 10853}); 10854 10855 10856/* 10857 * Clock2 - flipclock 10858 * ----------------------------------------------- 10859 */ 10860/*! flipclock 2015-08-31 10861 https://github.com/objectivehtml/FlipClock 10862*/ 10863var Base = function () { }; 10864Base.extend = function (a, b) { 10865 "use strict"; 10866 var c = Base.prototype.extend; 10867 Base._prototyping = !0; 10868 var d = new this; 10869 c.call(d, a), d.base = function () { }, delete Base._prototyping; 10870 var e = d.constructor, 10871 f = d.constructor = function () { 10872 if (!Base._prototyping) 10873 if (this._constructing || this.constructor == f) this._constructing = !0, e.apply(this, arguments), delete this._constructing; 10874 else if (null !== arguments[0]) return (arguments[0].extend || c).call(arguments[0], d) 10875 }; 10876 return f.ancestor = this, f.extend = this.extend, f.forEach = this.forEach, f.implement = this.implement, f.prototype = d, f.toString = this.toString, f.valueOf = function (a) { 10877 return "object" == a ? f : e.valueOf() 10878 }, c.call(f, b), "function" == typeof f.init && f.init(), f 10879}, Base.prototype = { 10880 extend: function (a, b) { 10881 if (arguments.length > 1) { 10882 var c = this[a]; 10883 if (c && "function" == typeof b && (!c.valueOf || c.valueOf() != b.valueOf()) && /\bbase\b/.test(b)) { 10884 var d = b.valueOf(); 10885 b = function () { 10886 var a = this.base || Base.prototype.base; 10887 this.base = c; 10888 var b = d.apply(this, arguments); 10889 return this.base = a, b 10890 }, b.valueOf = function (a) { 10891 return "object" == a ? b : d 10892 }, b.toString = Base.toString 10893 } 10894 this[a] = b 10895 } else if (a) { 10896 var e = Base.prototype.extend; 10897 Base._prototyping || "function" == typeof this || (e = this.extend || e); 10898 for (var f = { 10899 toSource: null 10900 }, g = ["constructor", "toString", "valueOf"], h = Base._prototyping ? 0 : 1; i = g[h++];) a[i] != f[i] && e.call(this, i, a[i]); 10901 for (var i in a) f[i] || e.call(this, i, a[i]) 10902 } 10903 return this 10904 } 10905}, Base = Base.extend({ 10906 constructor: function () { 10907 this.extend(arguments[0]) 10908 } 10909}, { 10910 ancestor: Object, 10911 version: "1.1", 10912 forEach: function (a, b, c) { 10913 for (var d in a) void 0 === this.prototype[d] && b.call(c, a[d], d, a) 10914 }, 10915 implement: function () { 10916 for (var a = 0; a < arguments.length; a++) "function" == typeof arguments[a] ? arguments[a](this.prototype) : this.prototype.extend(arguments[a]); 10917 return this 10918 }, 10919 toString: function () { 10920 return String(this.valueOf()) 10921 } 10922 }); 10923var FlipClock; 10924! function (a) { 10925 "use strict"; 10926 FlipClock = function (a, b, c) { 10927 return b instanceof Object && b instanceof Date == !1 && (c = b, b = 0), new FlipClock.Factory(a, b, c) 10928 }, FlipClock.Lang = {}, FlipClock.Base = Base.extend({ 10929 buildDate: "2014-12-12", 10930 version: "0.7.7", 10931 constructor: function (b, c) { 10932 "object" != typeof b && (b = {}), "object" != typeof c && (c = {}), this.setOptions(a.extend(!0, {}, b, c)) 10933 }, 10934 callback: function (a) { 10935 if ("function" == typeof a) { 10936 for (var b = [], c = 1; c <= arguments.length; c++) arguments[c] && b.push(arguments[c]); 10937 a.apply(this, b) 10938 } 10939 }, 10940 log: function (a) { 10941 window.console && console.log && console.log(a) 10942 }, 10943 getOption: function (a) { 10944 return this[a] ? this[a] : !1 10945 }, 10946 getOptions: function () { 10947 return this 10948 }, 10949 setOption: function (a, b) { 10950 this[a] = b 10951 }, 10952 setOptions: function (a) { 10953 for (var b in a) "undefined" != typeof a[b] && this.setOption(b, a[b]) 10954 } 10955 }) 10956}(jQuery), 10957 function (a) { 10958 "use strict"; 10959 FlipClock.Face = FlipClock.Base.extend({ 10960 autoStart: !0, 10961 dividers: [], 10962 factory: !1, 10963 lists: [], 10964 constructor: function (a, b) { 10965 this.dividers = [], this.lists = [], this.base(b), this.factory = a 10966 }, 10967 build: function () { 10968 this.autoStart && this.start() 10969 }, 10970 createDivider: function (b, c, d) { 10971 "boolean" != typeof c && c || (d = c, c = b); 10972 var e = ['<span class="' + this.factory.classes.dot + ' top"></span>', '<span class="' + this.factory.classes.dot + ' bottom"></span>'].join(""); 10973 d && (e = ""), b = this.factory.localize(b); 10974 var f = ['<span class="' + this.factory.classes.divider + " " + (c ? c : "").toLowerCase() + '">', '<span class="' + this.factory.classes.label + '">' + (b ? b : "") + "</span>
10974", e, "</span>"], 10975 g = a(f.join("")); 10976 return this.dividers.push(g), g 10977 }, 10978 createList: function (a, b) { 10979 "object" == typeof a && (b = a, a = 0); 10980 var c = new FlipClock.List(this.factory, a, b); 10981 return this.lists.push(c), c 10982 }, 10983 reset: function () { 10984 this.factory.time = new FlipClock.Time(this.factory, this.factory.original ? Math.round(this.factory.original) : 0, { 10985 minimumDigits: this.factory.minimumDigits 10986 }), this.flip(this.factory.original, !1) 10987 }, 10988 appendDigitToClock: function (a) { 10989 a.$el.append(!1) 10990 }, 10991 addDigit: function (a) { 10992 var b = this.createList(a, { 10993 classes: { 10994 active: this.factory.classes.active, 10995 before: this.factory.classes.before, 10996 flip: this.factory.classes.flip 10997 } 10998 }); 10999 this.appendDigitToClock(b) 11000 }, 11001 start: function () { }, 11002 stop: function () { }, 11003 autoIncrement: function () { 11004 this.factory.countdown ? this.decrement() : this.increment() 11005 }, 11006 increment: function () { 11007 this.factory.time.addSecond() 11008 }, 11009 decrement: function () { 11010 0 == this.factory.time.getTimeSeconds() ? this.factory.stop() : this.factory.time.subSecond() 11011 }, 11012 flip: function (b, c) { 11013 var d = this; 11014 a.each(b, function (a, b) { 11015 var e = d.lists[a]; 11016 e ? (c || b == e.digit || e.play(), e.select(b)) : d.addDigit(b) 11017 }) 11018 } 11019 }) 11020 }(jQuery), 11021 function (a) { 11022 "use strict"; 11023 FlipClock.Factory = FlipClock.Base.extend({ 11024 animationRate: 1e3, 11025 autoStart: !0, 11026 callbacks: { 11027 destroy: !1, 11028 create: !1, 11029 init: !1, 11030 interval: !1, 11031 start: !1, 11032 stop: !1, 11033 reset: !1 11034 }, 11035 classes: { 11036 active: "flip-clock-active", 11037 before: "flip-clock-before",
11038 divider: "flip-clock-divider", 11039 dot: "flip-clock-dot", 11040 label: "flip-clock-label", 11041 flip: "flip", 11042 play: "play", 11043 wrapper: "flip-clock-wrapper" 11044 }, 11045 clockFace: "HourlyCounter", 11046 countdown: !1, 11047 defaultClockFace: "HourlyCounter", 11048 defaultLanguage: "english", 11049 $el: !1, 11050 face: !0, 11051 lang: !1, 11052 language: "english", 11053 minimumDigits: 0, 11054 original: !1, 11055 running: !1, 11056 time: !1, 11057 timer: !1, 11058 $wrapper: !1, 11059 constructor: function (b, c, d) { 11060 d || (d = {}), this.lists = [], this.running = !1, this.base(d), this.$el = a(b).addClass(this.classes.wrapper), this.$wrapper = this.$el, this.original = c instanceof Date ? c : c ? Math.round(c) : 0, this.time = new FlipClock.Time(this, this.original, { 11061 minimumDigits: this.minimumDigits, 11062 animationRate: this.animationRate 11063 }), this.timer = new FlipClock.Timer(this, d), this.loadLanguage(this.language), this.loadClockFace(this.clockFace, d), this.autoStart && this.start() 11064 }, 11065 loadClockFace: function (a, b) { 11066 var c, d = "Face", 11067 e = !1; 11068 return a = a.ucfirst() + d, this.face.stop && (this.stop(), e = !0), this.$el.html(""), this.time.minimumDigits = this.minimumDigits, c = FlipClock[a] ? new FlipClock[a](this, b) : new FlipClock[this.defaultClockFace + d](this, b), c.build(), this.face = c, e && this.start(), this.face 11069 }, 11070 loadLanguage: function (a) { 11071 var b; 11072 return b = FlipClock.Lang[a.ucfirst()] ? FlipClock.Lang[a.ucfirst()] : FlipClock.Lang[a] ? FlipClock.Lang[a] : FlipClock.Lang[this.defaultLanguage], this.lang = b 11073 }, 11074 localize: function (a, b) { 11075 var c = this.lang; 11076 if (!a) return null; 11077 var d = a.toLowerCase(); 11078 return "object" == typeof b && (c = b), c && c[d] ? c[d] : a 11079 }, 11080 start: function (a) { 11081 var b = this; 11082 b.running || b.countdown && !(b.countdown && b.time.time > 0) ? b.log("Trying to start timer when countdown already at 0") : (b.face.start(b.time), b.timer.start(function () { 11083 b.flip(), "function" == typeof a && a() 11084 })) 11085 }, 11086 stop: function (a) { 11087 this.face.stop(), this.timer.stop(a); 11088 for (var b in this.lists) this.lists.hasOwnProperty(b) && this.lists[b].stop() 11089 }, 11090 reset: function (a) { 11091 this.timer.reset(a), this.face.reset() 11092 }, 11093 setTime: function (a) { 11094 this.time.time = a, this.flip(!0) 11095 }, 11096 getTime: function (a) { 11097 return this.time 11098 }, 11099 setCountdown: function (a) { 11100 var b = this.running; 11101 this.countdown = a ? !0 : !1, b && (this.stop(), this.start()) 11102 }, 11103 flip: function (a) { 11104 this.face.flip(!1, a) 11105 } 11106 }) 11107 }(jQuery), 11108 function (a) { 11109 "use strict"; 11110 FlipClock.List = FlipClock.Base.extend({ 11111 digit: 0, 11112 classes: { 11113 active: "flip-clock-active", 11114 before: "flip-clock-before", 11115 flip: "flip" 11116 }, 11117 factory: !1, 11118 $el: !1, 11119 $obj: !1, 11120 items: [], 11121 lastDigit: 0, 11122 constructor: function (a, b, c) { 11123 this.factory = a, this.digit = b, this.lastDigit = b, this.$el = this.createList(
11123), this.$obj = this.$el, b > 0 && this.select(b), this.factory.$el.append(this.$el) 11124 }, 11125 select: function (a) { 11126 if ("undefined" == typeof a ? a = this.digit : this.digit = a, this.digit != this.lastDigit) { 11127 var b = this.$el.find("." + this.classes.before).removeClass(this.classes.before); 11128 this.$el.find("." + this.classes.active).removeClass(this.classes.active).addClass(this.classes.before), this.appendListItem(this.classes.active, this.digit), b.remove(), this.lastDigit = this.digit 11129 } 11130 }, 11131 play: function () { 11132 this.$el.addClass(this.factory.classes.play) 11133 }, 11134 stop: function () { 11135 var a = this; 11136 setTimeout(function () { 11137 a.$el.removeClass(a.factory.classes.play) 11138 }, this.factory.timer.interval) 11139 }, 11140 createListItem: function (a, b) { 11141 return ['<li class="' + (a ? a : "") + '">', '<a href="#">', '<div class="up">', '<div class="shadow"></div>', '<div class="inn">' + (b ? b : "") + "</div>", "</div>", '<div class="down">', '<div class="shadow"></div>', '<div class="inn">' + (b ? b : "") + "</div>", "</div>", "</a>", "</li>"].join("") 11142 }, 11143 appendListItem: function (a, b) { 11144 var c = this.createListItem(a, b); 11145 this.$el.append(c) 11146 }, 11147 createList: function () { 11148 var b = this.getPrevDigit() ? this.getPrevDigit() : this.digit, 11149 c = a(['<ul class="' + this.classes.flip + " " + (this.factory.running ? this.factory.classes.play : "") + '">', this.createListItem(this.classes.before, b), this.createListItem(this.classes.active, this.digit), "</ul>"].join("")); 11150 return c 11151 }, 11152 getNextDigit: function () { 11153 return 9 == this.digit ? 0 : this.digit + 1 11154 }, 11155 getPrevDigit: function () { 11156 return 0 == this.digit ? 9 : this.digit - 1 11157 } 11158 }) 11159 }(jQuery), 11160 function (a) { 11161 "use strict"; 11162 String.prototype.ucfirst = function () { 11163 return this.substr(0, 1).toUpperCase() + this.substr(1) 11164 }, a.fn.FlipClock = function (b, c) { 11165 return new FlipClock(a(this), b, c) 11166 }, a.fn.flipClock = function (b, c) { 11167 return a.fn.FlipClock(b, c) 11168 } 11169 }(jQuery), 11170 function (a) { 11171 "use strict"; 11172 FlipClock.Time = FlipClock.Base.extend({ 11173 time: 0, 11174 factory: !1, 11175 minimumDigits: 0, 11176 constructor: function (a, b, c) { 11177 "object" != typeof c && (c = {}), c.minimumDigits || (c.minimumDigits = a.minimumDigits), this.base(c), this.factory = a, b && (this.time = b) 11178 }, 11179 convertDigitsToArray: function (a) { 11180 var b = []; 11181 a = a.toString(); 11182 for (var c = 0; c < a.length; c++) a[c].match(/^\d*$/g) && b.push(a[c]); 11183 return b 11184 }, 11185 digit: function (a) { 11186 var b = this.toString(), 11187 c = b.length; 11188 return b[c - a] ? b[c - a] : !1 11189 }, 11190 digitize: function (b) { 11191 var c = []; 11192 if (a.each(b, function (a, b) { 11193 b = b.toString(), 1 == b.length && (b = "0" + b); 11194 for (var d = 0; d < b.length; d++) c.push(b.charAt(d)) 11195 }), c.length > this.minimumDigits && (this.minimumDigits = c.length), this.minimumDigits > c.length) 11196 for (var d = c.length; d < this.minimumDigits; d++) c.unshift("0"); 11197 return c 11198 }, 11199 getDateObject: function () { 11200 return this.time instanceof Date ? this.time : new Date((new Date).getTime() + 1e3 * this.getTimeSeconds()) 11201 }, 11202 getDayCounter: function (a) { 11203 var b = [this.getDays(), this.getHours(!0), this.getMinutes(!0)]; 11204 return a && b.push(this.getSeconds(!0)), this.digitize(b) 11205 }, 11206 getDays: function (a) { 11207 var b = this.getTimeSeconds() / 60 / 60 / 24; 11208 return a && (b %= 7), Math.floor(b) 11209 }, 11210 getHourCounter: function () { 11211 var a = this.digitize([this.getHours(), this.getMinutes(!0), this.get
11211Seconds(!0)]); 11212 return a 11213 }, 11214 getHourly: function () { 11215 return this.getHourCounter() 11216 }, 11217 getHours: function (a) { 11218 var b = this.getTimeSeconds() / 60 / 60; 11219 return a && (b %= 24), Math.floor(b) 11220 }, 11221 getMilitaryTime: function (a, b) { 11222 "undefined" == typeof b && (b = !0), a || (a = this.getDateObject()); 11223 var c = [a.getHours(), a.getMinutes()]; 11224 return b === !0 && c.push(a.getSeconds()), this.digitize(c) 11225 }, 11226 getMinutes: function (a) { 11227 var b = this.getTimeSeconds() / 60; 11228 return a && (b %= 60), Math.floor(b) 11229 }, 11230 getMinuteCounter: function () { 11231 var a = this.digitize([this.getMinutes(), this.getSeconds(!0)]); 11232 return a 11233 }, 11234 getTimeSeconds: function (a) { 11235 return a || (a = new Date), this.time instanceof Date ? this.factory.countdown ? Math.max(this.time.getTime() / 1e3 - a.getTime() / 1e3, 0) : a.getTime() / 1e3 - this.time.getTime() / 1e3 : this.time 11236 }, 11237 getTime: function (a, b) { 11238 "undefined" == typeof b && (b = !0), a || (a = this.getDateObject()), console.log(a); 11239 var c = a.getHours(), 11240 d = [c > 12 ? c - 12 : 0 === c ? 12 : c, a.getMinutes()]; 11241 return b === !0 && d.push(a.getSeconds()), this.digitize(d) 11242 }, 11243 getSeconds: function (a) { 11244 var b = this.getTimeSeconds(); 11245 return a && (60 == b ? b = 0 : b %= 60), Math.ceil(b) 11246 }, 11247 getWeeks: function (a) { 11248 var b = this.getTimeSeconds() / 60 / 60 / 24 / 7; 11249 return a && (b %= 52), Math.floor(b) 11250 }, 11251 removeLeadingZeros: function (b, c) { 11252 var d = 0, 11253 e = []; 11254 return a.each(c, function (a, f) { 11255 b > a ? d += parseInt(c[a], 10) : e.push(c[a]) 11256 }), 0 === d ? e : c 11257 }, 11258 addSeconds: function (a) { 11259 this.time instanceof Date ? this.time.setSeconds(this.time.getSeconds() + a) : this.time += a 11260 }, 11261 addSecond: function () { 11262 this.addSeconds(1) 11263 }, 11264 subSeconds: function (a) { 11265 this.time instanceof Date ? this.time.setSeconds(this.time.getSeconds() - a) : this.time -= a 11266 }, 11267 subSecond: function () { 11268 this.subSeconds(1) 11269 }, 11270 toString: function () { 11271 return this.getTimeSeconds().toString() 11272 } 11273 }) 11274 }(jQuery), 11275 function (a) { 11276 "use strict"; 11277 FlipClock.Timer = FlipClock.Base.extend({ 11278 callbacks: { 11279 destroy: !1, 11280 create: !1, 11281 init: !1, 11282 interval: !1, 11283 start: !1, 11284 stop: !1, 11285 reset: !1 11286 }, 11287 count: 0, 11288 factory: !1, 11289 interval: 1e3, 11290 animationRate: 1e3, 11291 constructor: function (a, b) { 11292 this.base(b), this.factory = a, this.callback(this.callbacks.init), this.callback(this.callbacks.create) 11293 }, 11294 getElapsed: function () { 11295 return this.count * this.interval 11296 }, 11297 getElapsedTime: function () { 11298 return new Date(this.time + this.getElapsed()) 11299 }, 11300 reset: function (a) { 11301 clearInterval(this.timer), this.count = 0, this._setInterval(a), this.callback(this.callbacks.reset) 11302 }, 11303 start: function (a) { 11304 this.factory.running = !0, this._createTimer(a), this.callback(this.callbacks.start) 11305 }, 11306 stop: function (a) { 11307 this.factory.running = !1, this._clearInterval(a), this.callback(this.callbacks.stop), this.callback(a) 11308 }, 11309 _clearInterval: function () { 11310 clearInterval(this.timer) 11311 }, 11312 _createTimer: function (a) { 11313 this._setInterval(a) 11314 }, 11315 _destroyTimer: function (a) { 11316 this._clearInterval(), this.timer = !1, this.callback(a), this.callback(this.callbacks.destroy) 11317 }, 11318 _interval: function (a) { 11319 this.callback(this.callbacks.interval), this.callback(a), this.count++ 11320 }, 11321 _setInterval: function (a) { 11322 var b = this; 11323 b._interval(a), b.timer = setInterval(function () { 11324 b._interval(a) 11325 }, this.interval) 11326 } 11327 }) 11328 }(jQuery), 11329 function (a) { 11330 FlipClock.TwentyFourHourClockFace = FlipClock.Face.extend({ 11331 constructor: function (a, b) { 11332 this.base(a, b) 11333 }, 11334 build: function (b) { 11335 var c = this, 11336 d = this.factory.$el.find("ul"); 11337 this.factory.time.time || (this.factory.original = new Date, this.factory.time = new FlipClock.Time(this.factory, this.factory.original)); 11338 var b = b ? b : this.factory.time.getMilitaryTime(!1, this.showSeconds); 11339 b.length > d.length && a.each(b, function (a, b) { 11340 c.createList(b) 11341 }), this.createDivider(), this.createDivider(), a(this.dividers[0]).insertBefore(this.lists[this.lists.length - 2].$el), a(this.dividers[1]).insertBefore(this.lists[this.lists.length - 4].$el), this.base() 11342 }, 11343 flip: function (a, b) { 11344 this.autoIncrement(), a = a ? a : this.factory.time.getMilitaryTime(!1, this.showSeconds), this.base(a, b) 11345 } 11346 }) 11347 }(jQuery), 11348 function (a) { 11349 FlipClock.CounterFace = FlipClock.Face.extend({ 11350 shouldAutoIncrement: !1, 11351 constructor: function (a, b) { 11352 "object" != typeof b && (b = {}), a.autoStart = b.autoStart ? !0 : !1, b.autoStart && (this.shouldAutoIncrement = !0), a.increment = function () { 11353 a.countdown = !1, a.setTime(a.getTime().getTimeSeconds() + 1) 11354 }, a.decrement = function () { 11355 a.countdown = !0; 11356 var b = a.getTime().getTimeSeconds(); 11357 b > 0 && a.setTime(b - 1) 11358 }, a.setValue = function (b) { 11359 a.setTime(b) 11360 }, a.setCounter = function (b) { 11361 a.setTime(b) 11362 }, this.base(a, b) 11363 }, 11364 build: function () { 11365 var b = this, 11366 c = this.factory.$el.find("ul"), 11367 d = this.factory.getTime().digitize([this.factory.getTime().time]); 11368 d.length > c.length && a.each(d, function (a, c) { 11369 var d = b.createList(c); 11370 d.select(c) 11371 }), a.each(this.lists, function (a, b) { 11372 b.play() 11373 }), this.base() 11374 }, 11375 flip: function (a, b) { 11376 this.shouldAutoIncrement && this.autoIncrement(), a || (a = this.factory.getTime().digitize([this.factory.getTime().time])), this.base(a, b) 11377 }, 11378 reset: function () { 11379 this.factory.time = new FlipClock.Time(this.factory, this.factory.original ? Math.round(this.factory.original) : 0), this.flip() 11380 } 11381 }) 11382 }(jQuery), 11383 function (a) { 11384 FlipClock.DailyCounterFace = FlipClock.Face.extend({ 11385 showSeconds: !0, 11386 constructor: function (a, b) { 11387 this.base(a, b) 11388 }, 11389 build: function (b) { 11390 var c = this, 11391 d = this.factory.$el.find("ul"), 11392 e = 0; 11393 b = b ? b : this.factory.time.getDayCounter(this.showSeconds), b.length > d.length && a.each(b, function (a, b) { 11394 c.createList(b) 11395 }), this.showSeconds ? a(this.createDivider("Seconds")).insertBefore(this.lists[this.lists.length - 2].$el) : e = 2, a(this.createDivider("Minutes")).insertBefore(this.lists[this.lists.length - 4 + e].$el), a(this.createDivider("Hours")).insertBefore(this.lists[this.lists.length - 6 + e].$el), a(this.createDivider("Days", !0)).insertBefore(this.lists[0].$el), this.base() 11396 }, 11397 flip: function (a, b) { 11398 a || (a = this.factory.time.getDayCounter(this.showSeconds)), this.autoIncrement(), this.base(a, b) 11399 } 11400 }) 11401 }(jQuery), 11402 function (a) { 11403 FlipClock.HourlyCounterFace = FlipClock.Face.extend({ 11404 constructor: function (a, b) { 11405 this.base(a, b) 11406 }, 11407 build: function (b, c) { 11408 var d = this, 11409 e = this.factory.$el.find("ul"); 11410 c = c ? c : this.factory.time.getHourCounter(), c.length > e.length && a.each(c, function (a, b) { 11411 d.createList(b) 11412 }), a(this.createDivider("Seconds")).insertBefore(this.lists[this.lists.length - 2].$el), a(this.createDivider("Minutes")).insertBefore(this.lists[this.lists.length - 4].$el), b || a(this.createDivider("Hours", !0)).insertBefore(this.lists[0].$el), this.base() 11413 }, 11414 flip: function (a, b) { 11415 a || (a = this.factory.time.getHourCounter()), this.autoIncrement(), this.base(a, b) 11416 }, 11417 appendDigitToClock: function (a) { 11418 this.base(a), this.dividers[0].insertAfter(this.dividers[0].next()) 11419 } 11420 }) 11421 }(jQuery), 11422 function (a) {
11423 FlipClock.MinuteCounterFace = FlipClock.HourlyCounterFace.extend({ 11424 clearExcessDigits: !1, 11425 constructor: function (a, b) { 11426 this.base(a, b) 11427 }, 11428 build: function () { 11429 this.base(!0, this.factory.time.getMinuteCounter()) 11430 }, 11431 flip: function (a, b) { 11432 a || (a = this.factory.time.getMinuteCounter()), this.base(a, b) 11433 } 11434 }) 11435 }(jQuery), 11436 function (a) { 11437 FlipClock.TwelveHourClockFace = FlipClock.TwentyFourHourClockFace.extend({ 11438 meridium: !1, 11439 meridiumText: "AM", 11440 build: function () { 11441 var b = this.factory.time.getTime(!1, this.showSeconds); 11442 this.base(b), this.meridiumText = this.getMeridium(), this.meridium = a(['<ul class="flip-clock-meridium">', "<li>", '<a href="#">' + this.meridiumText + "</a>", "</li>", "</ul>"].join("")), this.meridium.insertAfter(this.lists[this.lists.length - 1].$el) 11443 }, 11444 flip: function (a, b) { 11445 this.meridiumText != this.getMeridium() && (this.meridiumText = this.getMeridium(), this.meridium.find("a").html(this.meridiumText)), this.base(this.factory.time.getTime(!1, this.showSeconds), b) 11446 }, 11447 getMeridium: function () { 11448 return (new Date).getHours() >= 12 ? "PM" : "AM" 11449 }, 11450 isPM: function () { 11451 return "PM" == this.getMeridium() ? !0 : !1 11452 }, 11453 isAM: function () { 11454 return "AM" == this.getMeridium() ? !0 : !1 11455 } 11456 }) 11457 }(jQuery), 11458 function (a) { 11459 FlipClock.Lang.Arabic = { 11460 years: "سÙÙØ§Øª", 11461 months: "Ø´ÙÙØ±", 11462 days: "Ø£ÙØ§Ù ", 11463 hours: "ساعات", 11464 minutes: "Ø¯ÙØ§Ø¦Ù", 11465 seconds: "Ø«ÙØ§ÙÙ" 11466 }, FlipClock.Lang.ar = FlipClock.Lang.Arabic, FlipClock.Lang["ar-ar"] = FlipClock.Lang.Arabic, FlipClock.Lang.arabic = FlipClock.Lang.Arabic 11467 }(jQuery), 11468 function (a) { 11469 FlipClock.Lang.Danish = { 11470 years: "à r", 11471 months: "MÃ¥neder", 11472 days: "Dage", 11473 hours: "Timer", 11474 minutes: "Minutter", 11475 seconds: "Sekunder" 11476 }, FlipClock.Lang.da = FlipClock.Lang.Danish, FlipClock.Lang["da-dk"] = FlipClock.Lang.Danish, FlipClock.Lang.danish = FlipClock.Lang.Danish 11477 }(jQuery), 11478 function (a) { 11479 FlipClock.Lang.German = { 11480 years: "Jahre", 11481 months: "Monate", 11482 days: "Tage", 11483 hours: "Stunden", 11484 minutes: "Minuten", 11485 seconds: "Sekunden" 11486 }, FlipClock.Lang.de = FlipClock.Lang.German, FlipClock.Lang["de-de"] = FlipClock.Lang.German, FlipClock.Lang.german = FlipClock.Lang.German 11487 }(jQuery), 11488 function (a) { 11489 FlipClock.Lang.English = { 11490 years: "Years", 11491 months: "Months", 11492 days: "Days", 11493 hours: "Hours", 11494 minutes: "Minutes", 11495 seconds: "Seconds" 11496 }, FlipClock.Lang.en = FlipClock.Lang.English, FlipClock.Lang["en-us"] = FlipClock.Lang.English, FlipClock.Lang.english = FlipClock.Lang.English 11497 }(jQuery), 11498 function (a) { 11499 FlipClock.Lang.Spanish = { 11500 years: "Años", 11501 months: "Meses", 11502 days: "DÃas", 11503 hours: "Horas", 11504 minutes: "Minutos", 11505 seconds: "Segundos" 11506 }, FlipClock.Lang.es = FlipClock.Lang.Spanish, FlipClock.Lang["es-es"] = FlipClock.Lang.Spanish, FlipClock.Lang.spanish = FlipClock.Lang.Spanish 11507 }(jQuery), 11508 function (a) { 11509 FlipClock.Lang.Finnish = { 11510 years: "Vuotta", 11511 months: "Kuukautta", 11512 days: "Päivää", 11513 hours: "Tuntia", 11514 minutes: "Minuuttia", 11515 seconds: "Sekuntia" 11516 }, FlipClock.Lang.fi = FlipClock.Lang.Finnish, FlipClock.Lang["fi-fi"] = FlipClock.Lang.Finnish, FlipClock.Lang.finnish = FlipClock.Lang.Finnish 11517 }(jQuery), 11518 function (a) { 11519 FlipClock.Lang.French = { 11520 years: "Ans", 11521 months: "Mois", 11522 days: "Jours", 11523 hours: "Heures", 11524 minutes: "Minutes", 11525 seconds: "Secondes" 11526 }, FlipClock.Lang.fr = FlipClock.Lang.French, FlipClock.Lang["fr-ca"] = FlipClock.Lang.French, FlipClock.Lang.french = FlipClock.Lang.French 11527 }(jQuery), 11528 function (a) { 11529 FlipClock.Lang.Italian = { 11530 years: "Anni", 11531 months: "Mesi", 11532 days: "Giorni", 11533 hours: "Ore", 11534 minutes: "Minuti", 11535 seconds: "Secondi" 11536 }, FlipClock.Lang.it = FlipClock.Lang.Italian, FlipClock.Lang["it-it"] = FlipClock.Lang.Italian, FlipClock.Lang.italian = FlipClock.Lang.Italian 11537 }(jQuery), 11538 function (a) { 11539 FlipClock.Lang.Latvian = { 11540 years: "Gadi", 11541 months: "MÄneÅ¡i", 11542 days: "Dienas", 11543 hours: "Stundas", 11544 minutes: "MinÅ«tes", 11545 seconds: "Sekundes" 11546 }, FlipClock.Lang.lv = FlipClock.Lang.Latvian, FlipClock.Lang["lv-lv"] = FlipClock.Lang.Latvian, FlipClock.Lang.latvian = FlipClock.Lang.Latvian 11547 }(jQuery), 11548 function (a) { 11549 FlipClock.Lang.Dutch = { 11550 years: "Jaren", 11551 months: "Maanden", 11552 days: "Dagen", 11553 hours: "Uren", 11554 minutes: "Minuten", 11555 seconds: "Seconden" 11556 }, FlipClock.Lang.nl = FlipClock.Lang.Dutch, FlipClock.Lang["nl-be"] = FlipClock.Lang.Dutch, FlipClock.Lang.dutch = FlipClock.Lang.Dutch 11557 }(jQuery), 11558 function (a) {
11559 FlipClock.Lang.Norwegian = { 11560 years: "à r", 11561 months: "MÃ¥neder", 11562 days: "Dager", 11563 hours: "Timer", 11564 minutes: "Minutter", 11565 seconds: "Sekunder" 11566 }, FlipClock.Lang.no = FlipClock.Lang.Norwegian, FlipClock.Lang.nb = FlipClock.Lang.Norwegian, FlipClock.Lang["no-nb"] = FlipClock.Lang.Norwegian, FlipClock.Lang.norwegian = FlipClock.Lang.Norwegian 11567 }(jQuery), 11568 function (a) { 11569 FlipClock.Lang.Portuguese = { 11570 years: "Anos", 11571 months: "Meses", 11572 days: "Dias", 11573 hours: "Horas", 11574 minutes: "Minutos", 11575 seconds: "Segundos" 11576 }, FlipClock.Lang.pt = FlipClock.Lang.Portuguese, FlipClock.Lang["pt-br"] = FlipClock.Lang.Portuguese, FlipClock.Lang.portuguese = FlipClock.Lang.Portuguese 11577 }(jQuery), 11578 function (a) { 11579 FlipClock.Lang.Russian = { 11580 years: "леÑ", 11581 months: "меÑÑÑев", 11582 days: "дней", 11583 hours: "ÑаÑов", 11584 minutes: "минÑÑ", 11585 seconds: "ÑекÑнд" 11586 }, FlipClock.Lang.ru = FlipClock.Lang.Russian, FlipClock.Lang["ru-ru"] = FlipClock.Lang.Russian, FlipClock.Lang.russian = FlipClock.Lang.Russian 11587 }(jQuery), 11588 function (a) { 11589 FlipClock.Lang.Swedish = { 11590 years: "à r", 11591 months: "MÃ¥nader", 11592 days: "Dagar", 11593 hours: "Timmar", 11594 minutes: "Minuter", 11595 seconds: "Sekunder" 11596 }, FlipClock.Lang.sv = FlipClock.Lang.Swedish, FlipClock.Lang["sv-se"] = FlipClock.Lang.Swedish, FlipClock.Lang.swedish = FlipClock.Lang.Swedish 11597 }(jQuery), 11598 function (a) { 11599 FlipClock.Lang.Chinese = { 11600 years: "å¹´", 11601 months: "æ", 11602 days: "æ¥", 11603 hours: "æ¶", 11604 minutes: "å", 11605 seconds: "ç§" 11606 }, FlipClock.Lang.zh = FlipClock.Lang.Chinese, FlipClock.Lang["zh-cn"] = FlipClock.Lang.Chinese, FlipClock.Lang.chinese = FlipClock.Lang.Chinese 11607 }(jQuery); 11608 11609 11610/* 11611 * instafeed.js 11612 * ----------------------------------------------- 11613 */ 11614// Generated by CoffeeScript 1.9.3 11615(function () { 11616 var e; 11617 e = function () { 11618 function e(e, t) { 11619 var n, r; 11620 this.options = { 11621 target: "instafeed", 11622 get: "popular", 11623 resolution: "thumbnail", 11624 sortBy: "none", 11625 links: !0, 11626 mock: !1, 11627 useHttp: !1 11628 }; 11629 if (typeof e == "object") 11630 for (n in e) r = e[n], this.options[n] = r; 11631 this.context = t != null ? t : this, this.unique = this._genKey() 11632 } 11633 return e.prototype.hasNext = function () { 11634 return typeof this.context.nextUrl == "string" && this.context.nextUrl.length > 0 11635 }, e.prototype.next = function () { 11636 return this.hasNext() ? this.run(this.context.nextUrl) : !1 11637 }, e.prototype.run = function (t) { 11638 var n, r, i; 11639 if (typeof this.options.clientId != "string" && typeof this.options.accessToken != "string") throw new Error("Missing clientId or accessToken."); 11640 if (typeof this.options.accessToken != "string" && typeof this.options.clientId != "string") throw new Error("Missing clientId or accessToken."); 11641 return this.options.before != null && typeof this.options.before == "function" && this.options.before.call(this), typeof document != "undefined" && document !== null && (i = document.createElement("script"), i.id = "instafeed-fetcher", i.src = t || this._buildUrl(), n = document.getElementsByTagName("head"), n[0].appendChild(i), r = "instafeedCache" + this.unique, window[r] = new e(this.options, this), window[r].unique = this.unique), !0 11642 }, e.prototype.parse = function (e) { 11643 var t, n, r, i, s, o, u, a, f, l, c, h, p, d, v, m, g, y, b, w, E, S, x, T, N, C, k, L, A, O, M, _, D; 11644 if (typeof e != "object") { 11645 if (this.options.error != null && typeof this.options.error == "function") return this.options.error.call(this, "Invalid JSON data"), !1; 11646 throw new Error("Invalid JSON response") 11647 } 11648 if (e.meta.code !== 200) { 11649 if (this.options.error != null && typeof this.options.error == "function") return this.options.error.call(this, e.meta.error_message), !1; 11650 throw new Error("Error from Instagram: " + e.meta.error_message) 11651 } 11652 if (e.data.length === 0) { 11653 if (this.options.error != null && typeof this.options.error == "function") return this.options.error.call(this, "No images were returned from Instagram"), !1; 11654 throw new Error("No images were returned from Instagram") 11655 } 11656 this.options.success != null && typeof this.options.success == "function" && this.options.success.call(this, e), this.context.nextUrl = "", e.pagination != null && (this.context.nextUrl = e.pagination.next_url); 11657 if (this.options.sortBy !== "none") { 11658 this.options.sortBy === "random" ? M = ["", "random"] : M = this.options.sortBy.split("-"), O = M[0] === "least" ? !0 : !1; 11659 switch (M[1]) { 11660 case "random": 11661 e.data.sort(function () { 11662 return .5 - Math.random() 11663 }); 11664 break; 11665 case "recent": 11666 e.data = this._sortBy(e.data, "created_time", O); 11667 break; 11668 case "liked": 11669 e.data = this._sortBy(e.data, "likes.count", O); 11670 break; 11671 case "commented": 11672 e.data = this._sortBy(e.data, "comments.count", O); 11673 break; 11674 default: 11675 throw new Error("Invalid option for sortBy: '" + this.options.sortBy + "'.") 11676 } 11677 } 11678 if (typeof document != "undefined" && document !== null && this.options.mock === !1) { 11679 m = e.data, A = parseInt(this.options.limit, 10), this.options.limit != null && m.length >
11679 A && (m = m.slice(0, A)), u = document.createDocumentFragment(), this.options.filter != null && typeof this.options.filter == "function" && (m = this._filter(m, this.options.filter)); 11680 if (this.options.template != null && typeof this.options.template == "string") { 11681 f = "", d = "", w = "", D = document.createElement("div"); 11682 for (c = 0, N = m.length; c < N; c++) { 11683 h = m[c], p = h.images[this.options.resolution]; 11684 if (typeof p != "object") throw o = "No image found for resolution: " + this.options.resolution + ".", new Error(o); 11685 E = p.width, y = p.height, b = "square", E > y && (b = "landscape"), E < y && (b = "portrait"), v = p.url, l = window.location.protocol.indexOf("http") >= 0, l && !this.options.useHttp && (v = v.replace(/https?:\/\//, "//")), d = this._makeTemplate(this.options.template, { 11686 model: h, 11687 id: h.id, 11688 link: h.link, 11689 type: h.type, 11690 image: v, 11691 width: E, 11692 height: y, 11693 orientation: b, 11694 caption: this._getObjectProperty(h, "caption.text"), 11695 likes: h.likes.count, 11696 comments: h.comments.count, 11697 location: this._getObjectProperty(h, "location.name") 11698 }), f += d 11699 } 11700 D.innerHTML = f, i = [], r = 0, n = D.childNodes.length; 11701 while (r < n) i.push(D.childNodes[r]), r += 1; 11702 for (x = 0, C = i.length; x < C; x++) L = i[x], u.appendChild(L) 11703 } else 11704 for (T = 0, k = m.length; T < k; T++) { 11705 h = m[T], g = document.createElement("img"), p = h.images[this.options.resolution]; 11706 if (typeof p != "object") throw o = "No image found for resolution: " + this.options.resolution + ".", new Error(o); 11707 v = p.url, l = window.location.protocol.indexOf("http") >= 0, l && !this.options.useHttp && (v = v.replace(/https?:\/\//, "//")), g.src = v, this.options.links === !0 ? (t = document.createElement("a"), t.href = h.link, t.appendChild(g), u.appendChild(t)) : u.appendChild(g) 11708 } 11709 _ = this.options.target, typeof _ == "string" && (_ = document.getElementById(_)); 11710 if (_ == null) throw o = 'No element with id="' + this.options.target + '" on page.', new Error(o); 11711 _.appendChild(u), a = document.getElementsByTagName("head")[0], a.removeChild(document.getElementById("instafeed-fetcher")), S = "instafeedCache" + this.unique, window[S] = void 0; 11712 try { 11713 delete window[S] 11714 } catch (P) { 11715 s = P 11716 } 11717 } 11718 return this.options.after != null && typeof this.options.after == "function" && this.options.after.call(this), !0 11719 }, e.prototype._buildUrl = function () { 11720 var e, t, n; 11721 e = "https://api.instagram.com/v1"; 11722 switch (this.options.get) { 11723 case "popular": 11724 t = "media/popular"; 11725 break; 11726 case "tagged": 11727 if (!this.options.tagName) throw new Error("No tag name specified. Use the 'tagName' option."); 11728 t = "tags/" + this.options.tagName + "/media/recent"; 11729 break; 11730 case "location": 11731 if (!this.options.locationId) throw new Error("No location specified. Use the 'locationId' option."); 11732 t = "locations/" + this.options.locationId + "/media/recent"; 11733 break; 11734 case "user": 11735 if (!this.options.userId) throw new Error("No user specified. Use the 'userId' option."); 11736 t = "users/" + this.options.userId + "/media/recent"; 11737 break; 11738 default: 11739 throw new Error("Invalid option for get: '" + this.options.get + "'.") 11740 } 11741 return n = e + "/" + t, this.options.accessToken != null ? n += "?access_token=" + this.options.accessToken : n += "?client_id=" + this.options.clientId, this.options.limit != null && (n += "&count=" + this.options.limit), n += "&callback=instafeedCache" + this.unique + ".parse", n 11742 }, e.prototype._genKey = function () { 11743 var e; 11744 return e = function () { 11745 return ((1 + Math.random()) * 65536 | 0).toString(16).substring(1) 11746 }, "" + e() + e() + e() + e() 11747 }, e.prototype._makeTemplate = function (e, t) { 11748 var n, r, i, s, o; 11749 r = /(?:\{{2})([\w\[\]\.]+)(?:\}{2})/, n = e; 11750 while (r.test(n)) s = n.match(r)[1], o = (i = this._getObjectProperty(t, s)) != null ? i : "", n = n.replace(r, function () { 11751 return "" + o 11752 }); 11753 return n 11754 }, e.prototype._getObjectProperty = function (e, t) { 11755 var n, r; 11756 t = t.replace(/\[(\w+)\]/g, ".$1"), r = t.split("."); 11757 while (r.length) { 11758 n = r.shift(); 11759 if (!(e != null && n in e)) return null; 11760 e = e[n] 11761 } 11762 return e 11763 }, e.prototype._sortBy = function (e, t, n) { 11764 var r; 11765 return r = function (e, r) { 11766 var i, s; 11767 return i = this._getObjectProperty(e, t), s = this._getObjectProperty(r, t), n ? i > s ? 1 : -1 : i < s ? 1 : -1 11768 }, e.sort(r.bind(this)), e 11769 }, e.prototype._filter = function (e, t) { 11770 var n, r, i, s, o; 11771 n = [], r = function (e) { 11772 if (t(e)) return n.push(e) 11773 }; 11774 for (i = 0, o = e.length; i < o; i++) s = e[i], r(s); 11775 return n 11776 }, e 11777 }(), 11778 function (e, t) { 11779 return typeof define == "function" && define.amd ? define([], t) : typeof module == "object" && module.exports ? module.exports = t() : e.Instafeed = t() 11780 }(this, function () { 11781 return e 11782 }) 11783}).call(this); 11784 11785 11786 11787/* 11788 * jQuery Validation 11789 * ----------------------------------------------- 11790 */
vendor: 9,939 bytes, lines 11791-11942
11791/*! jQuery Validation Plugin - v1.14.0 - 6/30/2015 11792 * http://jqueryvalidation.org/ 11793 * Copyright (c) 2015 Jörn Zaefferer; Licensed MIT */ 11794! function (a) { 11795 "function" == typeof define && define.amd ? define(["jquery"], a) : a(jQuery) 11796}(function (a) { 11797 a.extend(a.fn, { 11798 validate: function (b) { 11799 if (!this.length) return void (b && b.debug && window.console && console.warn("Nothing selected, can't validate, returning nothing.")); 11800 var c = a.data(this[0], "validator"); 11801 return c ? c : (this.attr("novalidate", "novalidate"), c = new a.validator(b, this[0]), a.data(this[0], "validator", c), c.settings.onsubmit && (this.on("click.validate", ":submit", function (b) { 11802 c.settings.submitHandler && (c.submitButton = b.target), a(this).hasClass("cancel") && (c.cancelSubmit = !0), void 0 !== a(this).attr("formnovalidate") && (c.cancelSubmit = !0) 11803 }), this.on("submit.validate", function (b) { 11804 function d() { 11805 var d, e; 11806 return c.settings.submitHandler ? (c.submitButton && (d = a("<input type='hidden'/>").attr("name", c.submitButton.name).val(a(c.submitButton).val()).appendTo(c.currentForm)), e = c.settings.submitHandler.call(c, c.currentForm, b), c.submitButton && d.remove(), void 0 !== e ? e : !1) : !0 11807 } 11808 return c.settings.debug && b.preventDefault(), c.cancelSubmit ? (c.cancelSubmit = !1, d()) : c.form() ? c.pendingRequest ? (c.formSubmitted = !0, !1) : d() : (c.focusInvalid(), !1) 11809 })), c) 11810 }, 11811 valid: function () { 11812 var b, c, d; 11813 return a(this[0]).is("form") ? b = this.validate().form() : (d = [], b = !0, c = a(this[0].form).validate(), this.each(function () { 11814 b = c.element(this) && b, d = d.concat(c.errorList) 11815 }), c.errorList = d), b 11816 }, 11817 rules: function (b, c) { 11818 var d, e, f, g, h, i, j = this[0]; 11819 if (b) switch (d = a.data(j.form, "validator").settings, e = d.rules, f = a.validator.staticRules(j), b) { 11820 case "add": 11821 a.extend(f, a.validator.normalizeRule(c)), delete f.messages, e[j.name] = f, c.messages && (d.messages[j.name] = a.extend(d.messages[j.name], c.messages)); 11822 break; 11823 case "remove": 11824 return c ? (i = {}, a.each(c.split(/\s/), function (b, c) { 11825 i[c] = f[c], delete f[c], "required" === c && a(j).removeAttr("aria-required") 11826 }), i) : (delete e[j.name], f) 11827 } 11828 return g = a.validator.normalizeRules(a.extend({}, a.validator.classRules(j), a.validator.attributeRules(j), a.validator.dataRules(j), a.validator.staticRules(j)), j), g.required && (h = g.required, delete g.required, g = a.extend({ 11829 required: h 11830 }, g), a(j).attr("aria-required", "true")), g.remote && (h = g.remote, delete g.remote, g = a.extend(g, { 11831 remote: h 11832 })), g 11833 } 11834 }), a.extend(a.expr[":"], { 11835 blank: function (b) { 11836 return !a.trim("" + a(b).val()) 11837 }, 11838 filled: function (b) { 11839 return !!a.trim("" + a(b).val()) 11840 }, 11841 unchecked: function (b) { 11842 return !a(b).prop("checked") 11843 } 11844 }), a.validator = function (b, c) { 11845 this.settings = a.extend(!0, {}, a.validator.defaults, b), this.currentForm = c, this.init() 11846 }, a.validator.format = function (b, c) { 11847 return 1 === arguments.length ? function () { 11848 var c = a.makeArray(arguments); 11849 return c.unshift(b), a.validator.format.apply(this, c) 11850 } : (arguments.length > 2 && c.constructor !== Array && (c = a.makeArray(arguments).slice(1)), c.constructor !== Array && (c = [c]), a.each(c, function (a, c) { 11851 b = b.replace(new RegExp("\\{" + a + "\\}", "g"), function () { 11852 return c 11853 }) 11854 }), b) 11855 }, a.extend(a.validator, { 11856 defaults: { 11857 messages: {}, 11858 groups: {}, 11859 rules: {}, 11860 errorClass: "error", 11861 validClass: "valid", 11862 errorElement: "label", 11863 focusCleanup: !1, 11864 focusInvalid: !0, 11865 errorContainer: a([]), 11866 errorLabelContainer: a([]), 11867 onsubmit: !0, 11868 ignore: ":hidden", 11869 ignoreTitle: !1, 11870 onfocusin: function (a) { 11871 this.lastActive = a, this.settings.focusCleanup && (this.settings.unhighlight && this.settings.unhighlight.call(this, a, this.settings.errorClass, this.settings.validClass), this.hideThese(this.errorsFor(a))) 11872 }, 11873 onfocusout: function (a) { 11874 this.checkable(a) || !(a.name in this.submitted) && this.optional(a) || this.element(a) 11875 }, 11876 onkeyup: function (b, c) { 11877 var d = [16, 17, 18, 20, 35, 36, 37, 38, 39, 40, 45, 144, 225]; 11878 9 === c.which && "" === this.elementValue(b) || -1 !== a.inArray(c.keyCode, d) || (b.name in this.submitted || b === this.lastElement) && this.element(b) 11879 }, 11880 onclick: function (a) { 11881 a.name in this.submitted ? this.element(a) : a.parentNode.name in this.submitted && this.element(a.parentNode) 11882 }, 11883 highlight: function (b, c, d) { 11884 "radio" === b.type ? this.findByName(b.name).addClass(c).removeClass(d) : a(b).addClass(c).removeClass(d) 11885 }, 11886 unhighlight: function (b, c, d) { 11887 "radio" === b.type ? this.findByName(b.name).removeClass(c).addClass(d) : a(b).removeClass(c).addClass(d) 11888 } 11889 }, 11890 setDefaults: function (b) { 11891 a.extend(a.validator.defaults, b) 11892 }, 11893 messages: { 11894 required: "This field is required.", 11895 remote: "Please fix this field.", 11896 email: "Please enter a valid email address.", 11897 url: "Please enter a valid URL.", 11898 date: "Please enter a valid date.", 11899 dateISO: "Please enter a valid date ( ISO ).", 11900 number: "Please enter a valid number.", 11901 digits: "Please enter only digits.", 11902 creditcard: "Please enter a valid credit card number.", 11903 equalTo: "Please enter the same value again.", 11904 maxlength: a.validator.format("Please enter no more than {0} characters."), 11905 minlength: a.validator.format("Please enter at least {0} characters."), 11906 rangelength: a.validator.format("Please enter a value between {0} and {1} characters long."), 11907 range: a.validator.format("Please enter a value between {0} and {1}."), 11908 max: a.validator.format("Please enter a value less than or equal to {0}."), 11909 min: a.validator.format("Please enter a value greater than or equal to {0}.") 11910 }, 11911 autoCreateRanges: !1, 11912 prototype: { 11913 init: function () { 11914 function b(b) { 11915 var c = a.data(this.form, "validator"), 11916 d = "on" + b.type.replace(/^validate/, ""), 11917 e = c.settings; 11918 e[d] && !a(this).is(e.ignore) && e[d].call(c, this, b) 11919 } 11920 this.labelContainer = a(this.settings.errorLabelContainer), this.errorContext = this.labelContainer.length && this.labelContainer || a(this.currentForm), this.containers = a(this.settings.errorContainer).add(this.settings.errorLabelContainer), this.submitted = {}, this.valueCache = {}, this.pendingRequest = 0, this.pending = {}, this.invalid = {}, this.reset(); 11921 var c, d = this.groups = {}; 11922 a.each(this.settings.groups, function (b, c) { 11923 "string" == typeof c && (c = c.split(/\s/)), a.each(c, function (a, c) { 11924 d[c] = b 11925 }) 11926 }), c = this.settings.rules, a.each(c, function (b, d) { 11927 c[b] = a.validator.normalizeRule(d) 11928 }), a(this.currentForm).on("focusin.validate focusout.validate keyup.validate", ":text, [type='password'], [type='file'], select, textarea, [type='number'], [type='search'], [type='tel'], [type='url'], [type='email'], [type='datetime'], [type='date'], [type='month'], [type='week'], [type='time'], [type='datetime-local'], [type='range'], [type='color'], [type='radio'], [type='checkbox']", b).on("click.validate", "select, option, [type='radio'], [type='checkbox']", b), this.settings.invalidHandler && a(this.currentForm).on("invalid-form.validate", this.settings.invalidHandler), a(this.currentForm).find("[required], [data-rule-required], .required").attr("aria-required", "true") 11929 }, 11930 form: function () { 11931 return this.checkForm(), a.extend(this.submitted, this.errorMap), this.invalid = a.extend({}, this.errorMap), this.valid() || a(this.currentForm).triggerHandler("invalid-form", [this]), this.showErrors(), this.valid() 11932 }, 11933 checkForm: function () { 11934 this.prepareForm(); 11935 for (var a = 0, b = this.currentElements = this.elements(); b[a]; a++) this.check(b[a]); 11936 return this.valid() 11937 }, 11938 element: function (b) { 11939 var c = this.clean(b), 11940 d = this.validationTargetFor(c), 11941 e = !0; 11942 return this.lastElement = d, void 0 === d ? delete this.invalid[c.name] : (this.prepareElement(d), this.currentElements = a(d), e = this.check(d) !== !1, e ? delete this.invalid[d.name] : this.invalid[d.name] = !0), a(b).attr("aria-invalid", !e), this.numberOfInvalids() || (this.toHide = this.toHide.add(this.containers
11942)), this.showErrors(), e 11943 }, 11944 showErrors: function (b) { 11945 if (b) { 11946 a.extend(this.errorMap, b), this.errorList = []; 11947 for (var c in b) this.errorList.push({ 11948 message: b[c], 11949 element: this.findByName(c)[0] 11950 }); 11951 this.successList = a.grep(this.successList, function (a) { 11952 return !(a.name in b) 11953 }) 11954 } 11955 this.settings.showErrors ? this.settings.showErrors.call(this, this.errorMap, this.errorList) : this.defaultShowErrors() 11956 }, 11957 resetForm: function () { 11958 a.fn.resetForm && a(this.currentForm).resetForm(), this.submitted = {}, this.lastElement = null, this.prepareForm(), this.hideErrors(); 11959 var b, c = this.elements().removeData("previousValue").removeAttr("aria-invalid"); 11960 if (this.settings.unhighlight) 11961 for (b = 0; c[b]; b++) this.settings.unhighlight.call(this, c[b], this.settings.errorClass, ""); 11962 else c.removeClass(this.settings.errorClass) 11963 }, 11964 numberOfInvalids: function () { 11965 return this.objectLength(this.invalid) 11966 }, 11967 objectLength: function (a) { 11968 var b, c = 0; 11969 for (b in a) c++; 11970 return c 11971 }, 11972 hideErrors: function () { 11973 this.hideThese(this.toHide) 11974 }, 11975 hideThese: function (a) { 11976 a.not(this.containers).text(""), this.addWrapper(a).hide() 11977 }, 11978 valid: function () { 11979 return 0 === this.size() 11980 }, 11981 size: function () { 11982 return this.errorList.length 11983 }, 11984 focusInvalid: function () { 11985 if (this.settings.focusInvalid) try { 11986 a(this.findLastActive() || this.errorList.length && this.errorList[0].element || []).filter(":visible").focus().trigger("focusin") 11987 } catch (b) { } 11988 }, 11989 findLastActive: function () { 11990 var b = this.lastActive; 11991 return b && 1 === a.grep(this.errorList, function (a) { 11992 return a.element.name === b.name 11993 }).length && b
vendor: 4,937 bytes, lines 11994-12078
11994 }, 11995 elements: function () { 11996 var b = this, 11997 c = {}; 11998 return a(this.currentForm).find("input, select, textarea").not(":submit, :reset, :image, :disabled").not(this.settings.ignore).filter(function () { 11999 return !this.name && b.settings.debug && window.console && console.error("%o has no name assigned", this), this.name in c || !b.objectLength(a(this).rules()) ? !1 : (c[this.name] = !0, !0) 12000 }) 12001 }, 12002 clean: function (b) { 12003 return a(b)[0] 12004 }, 12005 errors: function () { 12006 var b = this.settings.errorClass.split(" ").join("."); 12007 return a(this.settings.errorElement + "." + b, this.errorContext) 12008 }, 12009 reset: function () { 12010 this.successList = [], this.errorList = [], this.errorMap = {}, this.toShow = a([]), this.toHide = a([]), this.currentElements = a([]) 12011 }, 12012 prepareForm: function () { 12013 this.reset(), this.toHide = this.errors().add(this.containers) 12014 }, 12015 prepareElement: function (a) { 12016 this.reset(), this.toHide = this.errorsFor(a) 12017 }, 12018 elementValue: function (b) { 12019 var c, d = a(b), 12020 e = b.type; 12021 return "radio" === e || "checkbox" === e ? this.findByName(b.name).filter(":checked").val() : "number" === e && "undefined" != typeof b.validity ? b.validity.badInput ? !1 : d.val() : (c = d.val(), "string" == typeof c ? c.replace(/\r/g, "") : c) 12022 }, 12023 check: function (b) { 12024 b = this.validationTargetFor(this.clean(b)); 12025 var c, d, e, f = a(b).rules(), 12026 g = a.map(f, function (a, b) { 12027 return b 12028 }).length, 12029 h = !1, 12030 i = this.elementValue(b); 12031 for (d in f) { 12032 e = { 12033 method: d, 12034 parameters: f[d] 12035 }; 12036 try { 12037 if (c = a.validator.methods[d].call(this, i, b, e.parameters), "dependency-mismatch" === c && 1 === g) { 12038 h = !0; 12039 continue 12040 } 12041 if (h = !1, "pending" === c) return void (this.toHide = this.toHide.not(this.errorsFor(b))); 12042 if (!c) return this.formatAndAdd(b, e), !1 12043 } catch (j) { 12044 throw this.settings.debug && window.console && console.log("Exception occurred when checking element " + b.id + ", check the '" + e.method + "' method.", j), j instanceof TypeError && (j.message += ". Exception occurred when checking element " + b.id + ", check the '" + e.method + "' method."), j 12045 } 12046 } 12047 if (!h) return this.objectLength(f) && this.successList.push(b), !0 12048 }, 12049 customDataMessage: function (b, c) { 12050 return a(b).data("msg" + c.charAt(0).toUpperCase() + c.substring(1).toLowerCase()) || a(b).data("msg") 12051 }, 12052 customMessage: function (a, b) { 12053 var c = this.settings.messages[a]; 12054 return c && (c.constructor === String ? c : c[b]) 12055 }, 12056 findDefined: function () { 12057 for (var a = 0; a < arguments.length; a++) 12058 if (void 0 !== arguments[a]) return arguments[a]; 12059 return void 0 12060 }, 12061 defaultMessage: function (b, c) { 12062 return this.findDefined(this.customMessage(b.name, c), this.customDataMessage(b, c), !this.settings.ignoreTitle && b.title || void 0, a.validator.messages[c], "<strong>Warning: No message defined for " + b.name + "</strong>") 12063 }, 12064 formatAndAdd: function (b, c) { 12065 var d = this.defaultMessage(b, c.method), 12066 e = /\$?\{(\d+)\}/g; 12067 "function" == typeof d ? d = d.call(this, c.parameters, b) : e.test(d) && (d = a.validator.format(d.replace(e, "{$1}"), c.parameters)), this.errorList.push({ 12068 message: d, 12069 element: b, 12070 method: c.method 12071 }), this.errorMap[b.name] = d, this.submitted[b.name] = d 12072 }, 12073 addWrapper: function (a) { 12074 return this.settings.wrapper && (a = a.add(a.parent(this.settings.wrapper))), a 12075 }, 12076 defaultShowErrors: function () { 12077 var a, b, c; 12078 for (a = 0; this.errorList[a]; a++) c = this.errorList[a], this.settings.highlight && this.settings.highlight.call(this, c.element, this.settings.errorClass, this.settings.val
12078idClass), this.showLabel(c.element, c.message); 12079 if (this.errorList.length && (this.toShow = this.toShow.add(this.containers)), this.settings.success) 12080 for (a = 0; this.successList[a]; a++) this.showLabel(this.successList[a]); 12081 if (this.settings.unhighlight) 12082 for (a = 0, b = this.validElements(); b[a]; a++) this.settings.unhighlight.call(this, b[a], this.settings.errorClass, this.settings.validClass); 12083 this.toHide = this.toHide.not(this.toShow), this.hideErrors(), this.addWrapper(this.toShow).show() 12084 }, 12085 validElements: function () { 12086 return this.currentElements.not(this.invalidElements()) 12087 }, 12088 invalidElements: function () { 12089 return a(this.errorList).map(function () { 12090 return this.element 12091 }) 12092 }, 12093 showLabel: function (b, c) { 12094 var d, e, f, g = this.errorsFor(b), 12095 h = this.idOrName(b), 12096 i = a(b).attr("aria-describedby"); 12097 g.length ? (g.removeClass(this.settings.validClass).addClass(this.settings.errorClass), g.html(c)) : (g = a("<" + this.settings.errorElement + ">").attr("id", h + "-error").addClass(this.settings.errorClass).html(c || ""), d = g, this.settings.wrapper && (d = g.hide().show().wrap("<" + this.settings.wrapper + "/>").parent()), this.labelContainer.length ? this.labelContainer.append(d) : this.settings.errorPlacement ? this.settings.errorPlacement(d, a(b)) : d.insertAfter(b), g.is("label") ? g.attr("for", h) : 0 === g.parents("label[for='" + h + "']").length && (f = g.attr("id").replace(/(:|\.|\[|\]|\$)/g, "\\$1"), i ? i.match(new RegExp("\\b" + f + "\\b")) || (i += " " + f) : i = f, a(b).attr("aria-describedby", i), e = this.groups[b.n
vendor: 8,367 bytes, lines 12097-12268
12097ame], e && a.each(this.groups, function (b, c) { 12098 c === e && a("[name='" + b + "']", this.currentForm).attr("aria-describedby", g.attr("id")) 12099 }))), !c && this.settings.success && (g.text(""), "string" == typeof this.settings.success ? g.addClass(this.settings.success) : this.settings.success(g, b)), this.toShow = this.toShow.add(g) 12100 }, 12101 errorsFor: function (b) { 12102 var c = this.idOrName(b), 12103 d = a(b).attr("aria-describedby"), 12104 e = "label[for='" + c + "'], label[for='" + c + "'] *"; 12105 return d && (e = e + ", #" + d.replace(/\s+/g, ", #")), this.errors().filter(e) 12106 }, 12107 idOrName: function (a) { 12108 return this.groups[a.name] || (this.checkable(a) ? a.name : a.id || a.name) 12109 }, 12110 validationTargetFor: function (b) { 12111 return this.checkable(b) && (b = this.findByName(b.name)), a(b).not(this.settings.ignore)[0] 12112 }, 12113 checkable: function (a) { 12114 return /radio|checkbox/i.test(a.type) 12115 }, 12116 findByName: function (b) { 12117 return a(this.currentForm).find("[name='" + b + "']") 12118 }, 12119 getLength: function (b, c) { 12120 switch (c.nodeName.toLowerCase()) { 12121 case "select": 12122 return a("option:selected", c).length; 12123 case "input": 12124 if (this.checkable(c)) return this.findByName(c.name).filter(":checked").length 12125 } 12126 return b.length 12127 }, 12128 depend: function (a, b) { 12129 return this.dependTypes[typeof a] ? this.dependTypes[typeof a](a, b) : !0 12130 }, 12131 dependTypes: { 12132 "boolean": function (a) { 12133 return a 12134 }, 12135 string: function (b, c) { 12136 return !!a(b, c.form).length 12137 }, 12138 "function": function (a, b) { 12139 return a(b) 12140 } 12141 }, 12142 optional: function (b) { 12143 var c = this.elementValue(b); 12144 return !a.validator.methods.required.call(this, c, b) && "dependency-mismatch" 12145 }, 12146 startRequest: function (a) { 12147 this.pending[a.name] || (this.pendingRequest++ , this.pending[a.name] = !0) 12148 }, 12149 stopRequest: function (b, c) { 12150 this.pendingRequest-- , this.pendingRequest < 0 && (this.pendingRequest = 0), delete this.pending[b.name], c && 0 === this.pendingRequest && this.formSubmitted && this.form() ? (a(this.currentForm).submit(), this.formSubmitted = !1) : !c && 0 === this.pendingRequest && this.formSubmitted && (a(this.currentForm).triggerHandler("invalid-form", [this]), this.formSubmitted = !1) 12151 }, 12152 previousValue: function (b) { 12153 return a.data(b, "previousValue") || a.data(b, "previousValue", { 12154 old: null, 12155 valid: !0, 12156 message: this.defaultMessage(b, "remote") 12157 }) 12158 }, 12159 destroy: function () { 12160 this.resetForm(), a(this.currentForm).off(".validate").removeData("validator") 12161 } 12162 }, 12163 classRuleSettings: { 12164 required: { 12165 required: !0 12166 }, 12167 email: { 12168 email: !0 12169 }, 12170 url: { 12171 url: !0 12172 }, 12173 date: { 12174 date: !0 12175 }, 12176 dateISO: { 12177 dateISO: !0 12178 }, 12179 number: { 12180 number: !0 12181 }, 12182 digits: { 12183 digits: !0 12184 }, 12185 creditcard: { 12186 creditcard: !0 12187 } 12188 }, 12189 addClassRules: function (b, c) { 12190 b.constructor === String ? this.classRuleSettings[b] = c : a.extend(this.classRuleSettings, b) 12191 }, 12192 classRules: function (b) { 12193 var c = {}, 12194 d = a(b).attr("class"); 12195 return d && a.each(d.split(" "), function () { 12196 this in a.validator.classRuleSettings && a.extend(c, a.validator.classRuleSettings[this]) 12197 }), c 12198 }, 12199 normalizeAttributeRule: function (a, b, c, d) { 12200 /min|max/.test(c) && (null === b || /number|range|text/.test(b)) && (d = Number(d), isNaN(d) && (d = void 0)), d || 0 === d ? a[c] = d : b === c && "range" !== b && (a[c] = !0) 12201 }, 12202 attributeRules: function (b) { 12203 var c, d, e = {}, 12204 f = a(b), 12205 g = b.getAttribute("type"); 12206 for (c in a.validator.methods) "required" === c ? (d = b.getAttribute(c), "" === d && (d = !0), d = !!d) : d = f.attr(c), this.normalizeAttributeRule(e, g, c, d); 12207 return e.maxlength && /-1|2147483647|524288/.test(e.maxlength) && delete e.maxlength, e 12208 }, 12209 dataRules: function (b) { 12210 var c, d, e = {}, 12211 f = a(b), 12212 g = b.getAttribute("type"); 12213 for (c in a.validator.methods) d = f.data("rule" + c.charAt(0).toUpperCase() + c.substring(1).toLowerCase()), this.normalizeAttributeRule(e, g, c, d); 12214 return e 12215 }, 12216 staticRules: function (b) { 12217 var c = {}, 12218 d = a.data(b.form, "validator"); 12219 return d.settings.rules && (c = a.validator.normalizeRule(d.settings.rules[b.name]) || {}), c 12220 }, 12221 normalizeRules: function (b, c) { 12222 return a.each(b, function (d, e) { 12223 if (e === !1) return void delete b[d]; 12224 if (e.param || e.depends) { 12225 var f = !0; 12226 switch (typeof e.depends) { 12227 case "string": 12228 f = !!a(e.depends, c.form).length; 12229 break; 12230 case "function": 12231 f = e.depends.call(c, c) 12232 } 12233 f ? b[d] = void 0 !== e.param ? e.param : !0 : delete b[d] 12234 } 12235 }), a.each(b, function (d, e) { 12236 b[d] = a.isFunction(e) ? e(c) : e 12237 }), a.each(["minlength", "maxlength"], function () { 12238 b[this] && (b[this] = Number(b[this])) 12239 }), a.each(["rangelength", "range"], function () { 12240 var c; 12241 b[this] && (a.isArray(b[this]) ? b[this] = [Number(b[this][0]), Number(b[this][1])] : "string" == typeof b[this] && (c = b[this].replace(/[\[\]]/g, "").split(/[\s,]+/), b[this] = [Number(c[0]), Number(c[1])])) 12242 }), a.validator.autoCreateRanges && (null != b.min && null != b.max && (b.range = [b.min, b.max], delete b.min, delete b.max), null != b.minlength && null != b.maxlength && (b.rangelength = [b.minlength, b.maxlength], delete b.minlength, delete b.maxlength)), b 12243 }, 12244 normalizeRule: function (b) { 12245 if ("string" == typeof b) { 12246 var c = {}; 12247 a.each(b.split(/\s/), function () { 12248 c[this] = !0 12249 }), b = c 12250 } 12251 return b 12252 }, 12253 addMethod: function (b, c, d) { 12254 a.validator.methods[b] = c, a.validator.messages[b] = void 0 !== d ? d : a.validator.messages[b], c.length < 3 && a.validator.addClassRules(b, a.validator.normalizeRule(b)) 12255 }, 12256 methods: { 12257 required: function (b, c, d) { 12258 if (!this.depend(d, c)) return "dependency-mismatch"; 12259 if ("select" === c.nodeName.toLowerCase()) { 12260 var e = a(c).val(); 12261 return e && e.length > 0 12262 } 12263 return this.checkable(c) ? this.getLength(b, c) > 0 : b.length > 0 12264 }, 12265 email: function (a, b) { 12266 return this.optional(b) || /^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/.test(a) 12267 }, 12268 url: function (a, b) {
12269 return this.optional(b) || /^(?:(?:(?:https?|ftp):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)(?:\.(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)*(?:\.(?:[a-z\u00a1-\uffff]{2,})).?)(?::\d{2,5})?(?:[/?#]\S*)?$/i.test(a) 12270 }, 12271 date: function (a, b) { 12272 return this.optional(b) || !/Invalid|NaN/.test(new Date(a).toString()) 12273 }, 12274 dateISO: function (a, b) { 12275 return this.optional(b) || /^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])$/.test(a) 12276 }, 12277 number: function (a, b) { 12278 return this.optional(b) || /^(?:-?\d+|-?\d{1,3}(?:,\d{3})+)?(?:\.\d+)?$/.test(a) 12279 }, 12280 digits: function (a, b) { 12281 return this.optional(b) || /^\d+$/.test(a) 12282 }, 12283 creditcard: function (a, b) { 12284 if (this.optional(b)) return "dependency-mismatch"; 12285 if (/[^0-9 \-]+/.test(a)) return !1; 12286 var c, d, e = 0, 12287 f = 0, 12288 g = !1; 12289 if (a = a.replace(/\D/g, ""), a.length < 13 || a.length > 19) return !1; 12290 for (c = a.length - 1; c >= 0; c--) d = a.charAt(c), f = parseInt(d, 10), g && (f *= 2) > 9 && (f -= 9), e += f, g = !g; 12291 return e % 10 === 0 12292 }, 12293 minlength: function (b, c, d) { 12294 var e = a.isArray(b) ? b.length : this.getLength(b, c); 12295 return this.optional(c) || e >= d 12296 }, 12297 maxlength: function (b, c, d) { 12298 var e = a.isArray(b) ? b.length : this.getLength(b, c); 12299 return this.optional(c) || d >= e 12300 }, 12301 rangelength: function (b, c, d) { 12302 var e = a.isArray(b) ? b.length : this.getLength(b, c); 12303 return this.optional(c) || e >= d[0] && e <= d[1] 12304 }, 12305 min: function (a, b, c) { 12306 return this.optional(b) || a >= c 12307 }, 12308 max: function (a, b, c) { 12309 return this.optional(b) || c >= a 12310 }, 12311 range: function (a, b, c) { 12312 return this.optional(b) || a >= c[0] && a <= c[1] 12313 }, 12314 equalTo: function (b, c, d) { 12315 var e = a(d); 12316 return this.settings.onfocusout && e.off(".validate-equalTo").on("blur.validate-equalTo", function () { 12317 a(c).valid() 12318 }), b === e.val() 12319 }, 12320 remote: function (b, c, d) { 12321 if (this.optional(c)) return "dependency-mismatch"; 12322 var e, f, g = this.previousValue(c); 12323 return this.settings.messages[c.name] || (this.settings.messages[c.name] = {}), g.originalMessage = this.settings.messages[c.name].remote, this.settings.messages[c.name].remote = g.message, d = "string" == typeof d && { 12324 url: d 12325 } || d, g.old === b ? g.valid : (g.old = b, e = this, this.startRequest(c), f = {}, f[c.name] = b, a.ajax(a.extend(!0, { 12326 mode: "abort", 12327 port: "validate" + c.name, 12328 dataType: "json", 12329 data: f, 12330 context: e.currentForm, 12331 success: function (d) { 12332 var f, h, i, j = d === !0 || "true" === d; 12333 e.settings.messages[c.name].remote = g.originalMessage, j ? (i = e.formSubmitted, e.prepareElement(c), e.formSubmitted = i, e.successList.push(c), delete e.invalid[c.name], e.showErrors()) : (f = {}, h = d || e.defaultMessage(c, "remote"), f[c.name] = g.message = a.isFunction(h) ? h(b) : h, e.invalid[c.name] = !0, e.showErrors(f)), g.valid = j, e.stopRequest(c, j) 12334 } 12335 }, d)), "pending") 12336 } 12337 } 12338 });
12339 var b, c = {}; 12340 a.ajaxPrefilter ? a.ajaxPrefilter(function (a, b, d) { 12341 var e = a.port; 12342 "abort" === a.mode && (c[e] && c[e].abort(), c[e] = d) 12343 }) : (b = a.ajax, a.ajax = function (d) { 12344 var e = ("mode" in d ? d : a.ajaxSettings).mode, 12345 f = ("port" in d ? d : a.ajaxSettings).port; 12346 return "abort" === e ? (c[f] && c[f].abort(), c[f] = b.apply(this, arguments), c[f]) : b.apply(this, arguments) 12347 }) 12348}); 12349 12350 12351/* 12352 * jQuery Form 12353 * ----------------------------------------------- 12354 */ 12355/*! 12356 * jQuery Form Plugin 12357 * version: 3.51.0-2014.06.20 12358 * Requires jQuery v1.5 or later 12359 * Copyright (c) 2014 M. Alsup 12360 * Examples and documentation at: http://malsup.com/jquery/form/ 12361 * Project repository: https://github.com/malsup/form 12362 * Dual licensed under the MIT and GPL licenses. 12363 * https://github.com/malsup/form#copyright-and-license 12364 */ 12365! function (e) { 12366 "use strict"; 12367 "function" == typeof define && define.amd ? define(["jquery"], e) : e("undefined" != typeof jQuery ? jQuery : window.Zepto) 12368}(function (e) { 12369 "use strict"; 12370 12371 function t(t) { 12372 var r = t.data; 12373 t.isDefaultPrevented() || (t.preventDefault(), e(t.target).ajaxSubmit(r)) 12374 } 12375 12376 function r(t) { 12377 var r = t.target, 12378 a = e(r); 12379 if (!a.is("[type=submit],[type=image]")) { 12380 var n = a.closest("[type=submit]"); 12381 if (0 === n.length) return; 12382 r = n[0] 12383 } 12384 var i = this; 12385 if (i.clk = r, "image" == r.type) 12386 if (void 0 !== t.offsetX) i.clk_x = t.offsetX, i.clk_y = t.offsetY; 12387 else if ("function" == typeof e.fn.offset) { 12388 var o = a.offset(); 12389 i.clk_x = t.pageX - o.left, i.clk_y = t.pageY - o.top 12390 } else i.clk_x = t.pageX - r.offsetLeft, i.clk_y = t.pageY - r.offsetTop; 12391 setTimeout(function () { 12392 i.clk = i.clk_x = i.clk_y = null 12393 }, 100) 12394 } 12395 12396 function a() { 12397 if (e.fn.ajaxSubmit.debug) { 12398 var t = "[jquery.form] " + Array.prototype.join.call(arguments, ""); 12399 window.console && window.console.log ? window.console.log(t) : window.opera && window.opera.postError && window.opera.postError(t) 12400 } 12401 } 12402 var n = {}; 12403 n.fileapi = void 0 !== e("<input type='file'/>").get(0).files, n.formdata = void 0 !== window.FormData; 12404 var i = !!e.fn.prop; 12405 e.fn.attr2 = function () { 12406 if (!i) return this.attr.apply(this, arguments); 12407 var e = this.prop.apply(this, arguments); 12408 return e && e.jquery || "string" == typeof e ? e : this.attr.apply(this, arguments) 12409 }, e.fn.ajaxSubmit = function (t) { 12410 function r(r) { 12411 var a, n, i = e.param(r, t.traditional).split("&"), 12412 o = i.length, 12413 s = []; 12414 for (a = 0; o > a; a++) i[a] = i[a].replace(/\+/g, " "), n = i[a].split("="), s.push([decodeURIComponent(n[0]), decodeURIComponent(n[1])]); 12415 return s 12416 } 12417 12418 function o(a) { 12419 for (var n = new FormData, i = 0; i < a.length; i++) n.append(a[i].name, a[i].value); 12420 if (t.extraData) { 12421 var o = r(t.extraData); 12422 for (i = 0; i < o.length; i++) o[i] && n.append(o[i][0], o[i][1]) 12423 } 12424 t.data = null; 12425 var s = e.extend(!0, {}, e.ajaxSettings, t, { 12426 contentType: !1, 12427 processData: !1, 12428 cache: !1, 12429 type: u || "POST" 12430 }); 12431 t.uploadProgress && (s.xhr = function () { 12432 var r = e.ajaxSettings.xhr(); 12433 return r.upload && r.upload.addEventListener("progress", function (e) { 12434 var r = 0, 12435 a = e.loaded || e.position, 12436 n = e.total; 12437 e.lengthComputable && (r = Math.ceil(a / n * 100)), t.uploadProgress(e, a, n, r) 12438 }, !1), r 12439 }), s.data = null; 12440 var c = s.beforeSend; 12441 return s.beforeSend = function (e, r) { 12442 t.formData ? r.data = t.formData : r.data = n, c && c.call(this, e, r) 12443 }, e.ajax(s) 12444 } 12445 12446 function s(r) { 12447 function n(e) { 12448 var t = null; 12449 try { 12450 e.contentWindow && (t = e.contentWindow.document) 12451 } catch (r) { 12452 a("cannot get iframe.contentWindow document: " + r) 12453 } 12454 if (t) return t; 12455 try { 12456 t = e.contentDocument ? e.contentDocument : e.document 12457 } catch (r) { 12458 a("cannot get iframe.contentDocument: " + r), t = e.document 12459 } 12460 return t 12461 } 12462 12463 function o() { 12464 function t() { 12465 try { 12466 var e = n(g).readyState; 12467 a("state = " + e), e && "uninitialized" == e.toLowerCase() && setTimeout(t, 50) 12468 } catch (r) { 12469 a("Server abort: ", r, " (", r.name, ")"), s(k), j && clearTimeout(j), j = void 0 12470 } 12471 } 12472 var r = f.attr2("target"), 12473 i = f.attr2("action"), 12474 o = "multipart/form-data", 12475 c = f.attr("enctype") || f.attr("encoding") || o;
vendor: 6,011 bytes, lines 12476-12548
12476 w.setAttribute("target", p), (!u || /post/i.test(u)) && w.setAttribute("method", "POST"), i != m.url && w.setAttribute("action", m.url), m.skipEncodingOverride || u && !/post/i.test(u) || f.attr({ 12477 encoding: "multipart/form-data", 12478 enctype: "multipart/form-data" 12479 }), m.timeout && (j = setTimeout(function () { 12480 T = !0, s(D) 12481 }, m.timeout)); 12482 var l = []; 12483 try { 12484 if (m.extraData) 12485 for (var d in m.extraData) m.extraData.hasOwnProperty(d) && (e.isPlainObject(m.extraData[d]) && m.extraData[d].hasOwnProperty("name") && m.extraData[d].hasOwnProperty("value") ? l.push(e('<input type="hidden" name="' + m.extraData[d].name + '">').val(m.extraData[d].value).appendTo(w)[0]) : l.push(e('<input type="hidden" name="' + d + '">').val(m.extraData[d]).appendTo(w)[0])); 12486 m.iframeTarget || v.appendTo("body"), g.attachEvent ? g.attachEvent("onload", s) : g.addEventListener("load", s, !1), setTimeout(t, 15); 12487 try { 12488 w.submit() 12489 } catch (h) { 12490 var x = document.createElement("form").submit; 12491 x.apply(w) 12492 } 12493 } finally { 12494 w.setAttribute("action", i), w.setAttribute("enctype", c), r ? w.setAttribute("target", r) : f.removeAttr("target"), e(l).remove() 12495 } 12496 } 12497 12498 function s(t) { 12499 if (!x.aborted && !F) { 12500 if (M = n(g), M || (a("cannot access response document"), t = k), t === D && x) return x.abort("timeout"), void S.reject(x, "timeout"); 12501 if (t == k && x) return x.abort("server abort"), void S.reject(x, "error", "server abort"); 12502 if (M && M.location.href != m.iframeSrc || T) { 12503 g.detachEvent ? g.detachEvent("onload", s) : g.removeEventListener("load", s, !1); 12504 var r, i = "success"; 12505 try { 12506 if (T) throw "timeout"; 12507 var o = "xml" == m.dataType || M.XMLDocument || e.isXMLDoc(M); 12508 if (a("isXml=" + o), !o && window.opera && (null === M.body || !M.body.innerHTML) && --O) return a("requeing onLoad callback, DOM not available"), void setTimeout(s, 250); 12509 var u = M.body ? M.body : M.documentElement; 12510 x.responseText = u ? u.innerHTML : null, x.responseXML = M.XMLDocument ? M.XMLDocument : M, o && (m.dataType = "xml"), x.getResponseHeader = function (e) { 12511 var t = { 12512 "content-type": m.dataType 12513 }; 12514 return t[e.toLowerCase()] 12515 }, u && (x.status = Number(u.getAttribute("status")) || x.status, x.statusText = u.getAttribute("statusText") || x.statusText); 12516 var c = (m.dataType || "").toLowerCase(), 12517 l = /(json|script|text)/.test(c); 12518 if (l || m.textarea) { 12519 var f = M.getElementsByTagName("textarea")[0]; 12520 if (f) x.responseText = f.value, x.status = Number(f.getAttribute("status")) || x.status, x.statusText = f.getAttribute("statusText") || x.statusText; 12521 else if (l) { 12522 var p = M.getElementsByTagName("pre")[0], 12523 h = M.getElementsByTagName("body")[0]; 12524 p ? x.responseText = p.textContent ? p.textContent : p.innerText : h && (x.responseText = h.textContent ? h.textContent : h.innerText) 12525 } 12526 } else "xml" == c && !x.responseXML && x.responseText && (x.responseXML = X(x.responseText)); 12527 try { 12528 E = _(x, c, m) 12529 } catch (y) { 12530 i = "parsererror", x.error = r = y || i 12531 } 12532 } catch (y) { 12533 a("error caught: ", y), i = "error", x.error = r = y || i 12534 } 12535 x.aborted && (a("upload aborted"), i = null), x.status && (i = x.status >= 200 && x.status < 300 || 304 === x.status ? "success" : "error"), "success" === i ? (m.success && m.success.call(m.context, E, "success", x), S.resolve(x.responseText, "success", x), d && e.event.trigger("ajaxSuccess", [x, m])) : i && (void 0 === r && (r = x.statusText), m.error && m.error.call(m.context, x, i, r), S.reject(x, "error", r), d && e.event.trigger("ajaxError", [x, m, r])), d && e.event.trigger("ajaxComplete", [x, m]), d && !--e.active && e.event.trigger("ajaxStop"), m.complete && m.complete.call(m.context, x, i), F = !0, m.timeout && clearTimeout(j), setTimeout(function () { 12536 m.iframeTarget ? v.attr("src", m.iframeSrc) : v.remove(), x.responseXML = null 12537 }, 100) 12538 } 12539 } 12540 } 12541 var c, l, m, d, p, v, g, x, y, b, T, j, w = f[0], 12542 S = e.Deferred(); 12543 if (S.abort = function (e) { 12544 x.abort(e) 12545 }, r) 12546 for (l = 0; l < h.length; l++) c = e(h[l]), i ? c.prop("disabled", !1) : c.removeAttr("disabled"); 12547 if (m = e.extend(!0, {}, e.ajaxSettings, t), m.context = m.context || m, p = "jqFormIO" + (new Date).getTime(), m.iframeTarget ? (v = e(m.iframeTarget), b = v.attr2("name"), b ? p = b : v.attr2("name", p)) : (v = e('<iframe name="' + p + '" src="' + m.iframeSrc + '" />'), v.css({ 12548 position: "absolute",
12549 top: "-1000px", 12550 left: "-1000px" 12551 })), g = v[0], x = { 12552 aborted: 0, 12553 responseText: null, 12554 responseXML: null, 12555 status: 0, 12556 statusText: "n/a", 12557 getAllResponseHeaders: function () { }, 12558 getResponseHeader: function () { }, 12559 setRequestHeader: function () { }, 12560 abort: function (t) { 12561 var r = "timeout" === t ? "timeout" : "aborted"; 12562 a("aborting upload... " + r), this.aborted = 1; 12563 try { 12564 g.contentWindow.document.execCommand && g.contentWindow.document.execCommand("Stop") 12565 } catch (n) { } 12566 v.attr("src", m.iframeSrc), x.error = r, m.error && m.error.call(m.context, x, r, t), d && e.event.trigger("ajaxError", [x, m, r]), m.complete && m.complete.call(m.context, x, r) 12567 } 12568 }, d = m.global, d && 0 === e.active++ && e.event.trigger("ajaxStart"), d && e.event.trigger("ajaxSend", [x, m]), m.beforeSend && m.beforeSend.call(m.context, x, m) === !1) return m.global && e.active-- , S.reject(), S; 12569 if (x.aborted) return S.reject(), S; 12570 y = w.clk, y && (b = y.name, b && !y.disabled && (m.extraData = m.extraData || {}, m.extraData[b] = y.value, "image" == y.type && (m.extraData[b + ".x"] = w.clk_x, m.extraData[b + ".y"] = w.clk_y))); 12571 var D = 1, 12572 k = 2, 12573 A = e("meta[name=csrf-token]").attr("content"), 12574 L = e("meta[name=csrf-param]").attr("content"); 12575 L && A && (m.extraData = m.extraData || {}, m.extraData[L] = A), m.forceSync ? o() : setTimeout(o, 10); 12576 var E, M, F, O = 50, 12577 X = e.parseXML || function (e, t) { 12578 return window.ActiveXObject ? (t = new ActiveXObject("Microsoft.XMLDOM"), t.async = "false", t.loadXML(e)) : t = (new DOMParser).parseFromString(e, "text/xml"), t && t.documentElement && "parsererror" != t.documentElement.nodeName ? t : null 12579 }, 12580 C = e.parseJSON || function (e) { 12581 return window.eval("(" + e + ")") 12582 }, 12583 _ = function (t, r, a) { 12584 var n = t.getResponseHeader("content-type") || "", 12585 i = "xml" === r || !r && n.indexOf("xml") >= 0, 12586 o = i ? t.responseXML : t.responseText; 12587 return i && "parsererror" === o.documentElement.nodeName && e.error && e.error("parsererror"), a && a.dataFilter && (o = a.dataFilter(o, r)), "string" == typeof o && ("json" === r || !r && n.indexOf("json") >= 0 ? o = C(o) : ("script" === r || !r && n.indexOf("javascript") >= 0) && e.globalEval(o)), o 12588 }; 12589 return S 12590 } 12591 if (!this.length) return a("ajaxSubmit: skipping submit process - no element selected"), this; 12592 var u, c, l, f = this; 12593 "function" == typeof t ? t = { 12594 success: t 12595 } : void 0 === t && (t = {}), u = t.type || this.attr2("method"), c = t.url || this.attr2("action"), l = "string" == typeof c ? e.trim(c) : "", l = l || window.location.href || "", l && (l = (l.match(/^([^#]+)/) || [])[1]), t = e.extend(!0, { 12596 url: l, 12597 success: e.ajaxSettings.success, 12598 type: u || e.ajaxSettings.type, 12599 iframeSrc: /^https/i.test(window.location.href || "") ? "javascript:false" : "about:blank" 12600 }, t); 12601 var m = {}; 12602 if (this.trigger("form-pre-serialize", [this, t, m]), m.veto) return a("ajaxSubmit: submit vetoed via form-pre-serialize trigger"), this; 12603 if (t.beforeSerialize && t.beforeSerialize(this, t) === !1) return a("ajaxSubmit: submit aborted via beforeSerialize callback"), this; 12604 var d = t.traditional; 12605 void 0 === d && (d = e.ajaxSettings.traditional); 12606 var p, h = [], 12607 v = this.formToArray(t.semantic, h);
12608 if (t.data && (t.extraData = t.data, p = e.param(t.data, d)), t.beforeSubmit && t.beforeSubmit(v, this, t) === !1) return a("ajaxSubmit: submit aborted via beforeSubmit callback"), this; 12609 if (this.trigger("form-submit-validate", [v, this, t, m]), m.veto) return a("ajaxSubmit: submit vetoed via form-submit-validate trigger"), this; 12610 var g = e.param(v, d); 12611 p && (g = g ? g + "&" + p : p), "GET" == t.type.toUpperCase() ? (t.url += (t.url.indexOf("?") >= 0 ? "&" : "?") + g, t.data = null) : t.data = g; 12612 var x = []; 12613 if (t.resetForm && x.push(function () { 12614 f.resetForm() 12615 }), t.clearForm && x.push(function () { 12616 f.clearForm(t.includeHidden) 12617 }), !t.dataType && t.target) { 12618 var y = t.success || function () { }; 12619 x.push(function (r) { 12620 var a = t.replaceTarget ? "replaceWith" : "html"; 12621 e(t.target)[a](r).each(y, arguments) 12622 }) 12623 } else t.success && x.push(t.success); 12624 if (t.success = function (e, r, a) { 12625 for (var n = t.context || this, i = 0, o = x.length; o > i; i++) x[i].apply(n, [e, r, a || f, f]) 12626 }, t.error) { 12627 var b = t.error; 12628 t.error = function (e, r, a) { 12629 var n = t.context || this; 12630 b.apply(n, [e, r, a, f]) 12631 } 12632 } 12633 if (t.complete) { 12634 var T = t.complete; 12635 t.complete = function (e, r) { 12636 var a = t.context || this; 12637 T.apply(a, [e, r, f]) 12638 } 12639 } 12640 var j = e("input[type=file]:enabled", this).filter(function () { 12641 return "" !== e(this).val() 12642 }), 12643 w = j.length > 0, 12644 S = "multipart/form-data", 12645 D = f.attr("enctype") == S || f.attr("encoding") == S, 12646 k = n.fileapi && n.formdata; 12647 a("fileAPI :" + k); 12648 var A, L = (w || D) && !k; 12649 t.iframe !== !1 && (t.iframe || L) ? t.closeKeepAlive ? e.get(t.closeKeepAlive, function () { 12650 A = s(v) 12651 }) : A = s(v) : A = (w || D) && k ? o(v) : e.ajax(t), f.removeData("jqxhr").data("jqxhr", A); 12652 for (var E = 0; E < h.length; E++) h[E] = null; 12653 return this.trigger("form-submit-notify", [this, t]), this 12654 }, e.fn.ajaxForm = function (n) { 12655 if (n = n || {}, n.delegation = n.delegation && e.isFunction(e.fn.on), !n.delegation && 0 === this.length) { 12656 var i = { 12657 s: this.selector, 12658 c: this.context 12659 }; 12660 return !e.isReady && i.s ? (a("DOM not ready, queuing ajaxForm"), e(function () { 12661 e(i.s, i.c).ajaxForm(n) 12662 }), this) : (a("terminating; zero elements found by selector" + (e.isReady ? "" : " (DOM not ready)")), this) 12663 } 12664 return n.delegation ? (e(document).off("submit.form-plugin", this.selector, t).off("click.form-plugin", this.selector, r).on("submit.form-plugin", this.selector, n, t).on("click.form-plugin", this.selector, n, r), this) : this.ajaxFormUnbind().bind("submit.form-plugin", n, t).bind("click.form-plugin", n, r) 12665 }, e.fn.ajaxFormUnbind = function () { 12666 return this.unbind("submit.form-plugin click.form-plugin") 12667 }, e.fn.formToArray = function (t, r) { 12668 var a = []; 12669 if (0 === this.length) return a; 12670 var i, o = this[0], 12671 s = this.attr("id"), 12672 u = t ? o.getElementsByTagName("*") : o.elements; 12673 if (u && !/MSIE [678]/.test(navigator.userAgent) && (u = e(u).get()), s && (i = e(':input[form="' + s + '"]').get(), i.length && (u = (u || []).concat(i))), !u || !u.length) return a; 12674 var c, l, f, m, d, p, h; 12675 for (c = 0, p = u.length; p > c; c++) 12676 if (d = u[c], f = d.name, f && !d.disabled) 12677 if (t && o.clk && "image" == d.type) o.clk == d && (a.push({ 12678 name: f, 12679 value: e(d).val(), 12680 type: d.type 12681 }), a.push({ 12682 name: f + ".x", 12683 value: o.clk_x 12684 }, { 12685 name: f + ".y", 12686 value: o.clk_y 12687 })); 12688 else if (m = e.fieldValue(d, !0), m && m.constructor == Array) 12689 for (r && r.push(d), l = 0, h = m.length; h > l; l++) a.push({ 12690 name: f, 12691 value: m[l] 12692 }); 12693 else if (n.fileapi && "file" == d.type) { 12694 r && r.push(d); 12695 var v = d.files; 12696 if (v.length) 12697 for (l = 0; l < v.length; l++) a.push({ 12698 name: f, 12699 value: v[l], 12700 type: d.type 12701 }); 12702 else a.push({ 12703 name: f, 12704 value: "", 12705 type: d.type 12706 }) 12707 } else null !== m && "undefined" != typeof m && (r && r.push(d), a.push({ 12708 name: f, 12709 value: m, 12710 type: d.type, 12711 required: d.required 12712 })); 12713 if (!t && o.clk) { 12714 var g = e(o.clk), 12715 x = g[0]; 12716 f = x.name, f && !x.disabled && "image" == x.type && (a.push({ 12717 name: f, 12718 value: g.val() 12719 }), a.push({ 12720 name: f + ".x", 12721 value: o.clk_x 12722 }, { 12723 name: f + ".y", 12724 value: o.clk_y 12725 })) 12726 } 12727 return a 12728 }
12728, e.fn.formSerialize = function (t) { 12729 return e.param(this.formToArray(t)) 12730 }, e.fn.fieldSerialize = function (t) { 12731 var r = []; 12732 return this.each(function () { 12733 var a = this.name; 12734 if (a) { 12735 var n = e.fieldValue(this, t); 12736 if (n && n.constructor == Array) 12737 for (var i = 0, o = n.length; o > i; i++) r.push({ 12738 name: a, 12739 value: n[i] 12740 }); 12741 else null !== n && "undefined" != typeof n && r.push({ 12742 name: this.name, 12743 value: n 12744 }) 12745 } 12746 }), e.param(r) 12747 }, e.fn.fieldValue = function (t) { 12748 for (var r = [], a = 0, n = this.length; n > a; a++) { 12749 var i = this[a], 12750 o = e.fieldValue(i, t); 12751 null === o || "undefined" == typeof o || o.constructor == Array && !o.length || (o.constructor == Array ? e.merge(r, o) : r.push(o)) 12752 } 12753 return r 12754 }, e.fieldValue = function (t, r) { 12755 var a = t.name, 12756 n = t.type, 12757 i = t.tagName.toLowerCase(); 12758 if (void 0 === r && (r = !0), r && (!a || t.disabled || "reset" == n || "button" == n || ("checkbox" == n || "radio" == n) && !t.checked || ("submit" == n || "image" == n) && t.form && t.form.clk != t || "select" == i && -1 == t.selectedIndex)) return null; 12759 if ("select" == i) { 12760 var o = t.selectedIndex; 12761 if (0 > o) return null; 12762 for (var s = [], u = t.options, c = "select-one" == n, l = c ? o + 1 : u.length, f = c ? o : 0; l > f; f++) { 12763 var m = u[f]; 12764 if (m.selected) { 12765 var d = m.value; 12766 if (d || (d = m.attributes && m.attributes.value && !m.attributes.value.specified ? m.text : m.value), c) return d; 12767 s.push(d) 12768 } 12769 } 12770 return s 12771 } 12772 return e(t).val() 12773 }, e.fn.clearForm = function (t) { 12774 return this.each(function () { 12775 e("input,select,textarea", this).clearFields(t) 12776 }) 12777 }, e.fn.clearFields = e.fn.clearInputs = function (t) { 12778 var r = /^(?:color|date|datetime|email|month|number|password|range|search|tel|text|time|url|week)$/i; 12779 return this.each(function () { 12780 var a = this.type, 12781 n = this.tagName.toLowerCase(); 12782 r.test(a) || "textarea" == n ? this.value = "" : "checkbox" == a || "radio" == a ? this.checked = !1 : "select" == n ? this.selectedIndex = -1 : "file" == a ? /MSIE/.test(navigator.userAgent) ? e(this).replaceWith(e(this).clone(!0)) : e(this).val("") : t && (t === !0 && /hidden/.test(a) || "string" == typeof t && e(this).is(t)) && (this.value = "") 12783 }) 12784 }, e.fn.resetForm = function () { 12785 return this.each(function () { 12786 ("function" == typeof this.reset || "object" == typeof this.reset && !this.reset.nodeType) && this.reset() 12787 }) 12788 }, e.fn.enable = function (e) { 12789 return void 0 === e && (e = !0), this.each(function () { 12790 this.disabled = !e 12791 }) 12792 }, e.fn.selected = function (t) { 12793 return void 0 === t && (t = !0), this.each(function () { 12794 var r = this.type; 12795 if ("checkbox" == r || "radio" == r) this.checked = t; 12796 else if ("option" == this.tagName.toLowerCase()) { 12797 var a = e(this).parent("select"); 12798 t && a[0] && "select-one" == a[0].type && a.find("option").selected(!1), this.selected = t 12799 } 12800 }) 12801 }, e.fn.ajaxSubmit.debug = !1 12802}); 12803 12804 12805/* 12806 * code highlight 12807 * ----------------------------------------------- 12808 */ 12809/* http://prismjs.com/download.html?themes=prism&languages=markup+css+clike+javascript+aspnet+bash+c+csharp+cpp+coffeescript+css-extras+git+http+ini+java+latex+less+matlab+objectivec+perl+php+php-extras+python+ruby+scss+sql+swift&plugins=line-numbers+show-language */ 12810self = "undefined" != typeof window ? window : "undefined" != typeof WorkerGlobalScope && self instanceof WorkerGlobalScope ? self : {}; 12811var Prism = function () { 12812 var e = /\blang(?:uage)?-(?!\*)(\w+)\b/i, 12813 t = self.Prism = { 12814 util: { 12815 encode: function (e) { 12816 return e instanceof n ? new n(e.type, t.util.encode(e.content), e.alias) : "Array" === t.util.type(e) ? e.map(t.util.encode) : e.replace(/&/g, "&").replace(/</g, "<").replace(/\u00a0/g, " ") 12817 }, 12818 type: function (e) { 12819 return Object.prototype.toString.call(e).match(/\[object (\w+)\]/)[
vendor: 12,534 bytes, lines 12819-13100
128191] 12820 }, 12821 clone: function (e) { 12822 var n = t.util.type(e); 12823 switch (n) { 12824 case "Object": 12825 var a = {}; 12826 for (var r in e) e.hasOwnProperty(r) && (a[r] = t.util.clone(e[r])); 12827 return a; 12828 case "Array": 12829 return e.map(function (e) { 12830 return t.util.clone(e) 12831 }) 12832 } 12833 return e 12834 } 12835 }, 12836 languages: { 12837 extend: function (e, n) { 12838 var a = t.util.clone(t.languages[e]); 12839 for (var r in n) a[r] = n[r]; 12840 return a 12841 }, 12842 insertBefore: function (e, n, a, r) { 12843 r = r || t.languages; 12844 var i = r[e]; 12845 if (2 == arguments.length) { 12846 a = arguments[1]; 12847 for (var l in a) a.hasOwnProperty(l) && (i[l] = a[l]); 12848 return i 12849 } 12850 var s = {}; 12851 for (var o in i) 12852 if (i.hasOwnProperty(o)) { 12853 if (o == n) 12854 for (var l in a) a.hasOwnProperty(l) && (s[l] = a[l]); 12855 s[o] = i[o] 12856 } return t.languages.DFS(t.languages, function (t, n) { 12857 n === r[e] && t != e && (this[t] = s) 12858 }), r[e] = s 12859 }, 12860 DFS: function (e, n, a) { 12861 for (var r in e) e.hasOwnProperty(r) && (n.call(e, r, e[r], a || r), "Object" === t.util.type(e[r]) ? t.languages.DFS(e[r], n) : "Array" === t.util.type(e[r]) && t.languages.DFS(e[r], n, r)) 12862 } 12863 }, 12864 highlightAll: function (e, n) { 12865 for (var a, r = document.querySelectorAll('code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'), i = 0; a = r[i++];) t.highlightElement(a, e === !0, n) 12866 }, 12867 highlightElement: function (a, r, i) { 12868 for (var l, s, o = a; o && !e.test(o.className);) o = o.parentNode; 12869 if (o && (l = (o.className.match(e) || [, ""])[1], s = t.languages[l]), s) { 12870 a.className = a.className.replace(e, "").replace(/\s+/g, " ") + " language-" + l, o = a.parentNode, /pre/i.test(o.nodeName) && (o.className = o.className.replace(e, "").replace(/\s+/g, " ") + " language-" + l); 12871 var u = a.textContent; 12872 if (u) { 12873 u = u.replace(/^(?:\r?\n|\r)/, ""); 12874 var g = { 12875 element: a, 12876 language: l, 12877 grammar: s, 12878 code: u 12879 }; 12880 if (t.hooks.run("before-highlight", g), r && self.Worker) { 12881 var c = new Worker(t.filename); 12882 c.onmessage = function (e) { 12883 g.highlightedCode = n.stringify(JSON.parse(e.data), l), t.hooks.run("before-insert", g), g.element.innerHTML = g.highlightedCode, i && i.call(g.element), t.hooks.run("after-highlight", g) 12884 }, c.postMessage(JSON.stringify({ 12885 language: g.language, 12886 code: g.code 12887 })) 12888 } else g.highlightedCode = t.highlight(g.code, g.grammar, g.language), t.hooks.run("before-insert", g), g.element.innerHTML = g.highlightedCode, i && i.call(a), t.hooks.run("after-highlight", g) 12889 } 12890 } 12891 }, 12892 highlight: function (e, a, r) { 12893 var i = t.tokenize(e, a); 12894 return n.stringify(t.util.encode(i), r) 12895 }, 12896 tokenize: function (e, n) { 12897 var a = t.Token, 12898 r = [e], 12899 i = n.rest; 12900 if (i) { 12901 for (var l in i) n[l] = i[l]; 12902 delete n.rest 12903 } 12904 e: for (var l in n) 12905 if (n.hasOwnProperty(l) && n[l]) { 12906 var s = n[l]; 12907 s = "Array" === t.util.type(s) ? s : [s]; 12908 for (var o = 0; o < s.length; ++o) { 12909 var u = s[o], 12910 g = u.inside, 12911 c = !!u.lookbehind, 12912 f = 0, 12913 h = u.alias; 12914 u = u.pattern || u; 12915 for (var p = 0; p < r.length; p++) { 12916 var d = r[p]; 12917 if (r.length > e.length) break e; 12918 if (!(d instanceof a)) { 12919 u.lastIndex = 0; 12920 var m = u.exec(d); 12921 if (m) { 12922 c && (f = m[1].length); 12923 var y = m.index - 1 + f, 12924 m = m[0].slice(f), 12925 v = m.length, 12926 k = y + v, 12927 b = d.slice(0, y + 1), 12928 w = d.slice(k + 1), 12929 N = [p, 1]; 12930 b && N.push(b); 12931 var O = new a(l, g ? t.tokenize(m, g) : m, h); 12932 N.push(O), w && N.push(w), Array.prototype.splice.apply(r, N) 12933 } 12934 } 12935 } 12936 } 12937 } 12938 return r 12939 }, 12940 hooks: { 12941 all: {}, 12942 add: function (e, n) { 12943 var a = t.hooks.all; 12944 a[e] = a[e] || [], a[e].push(n) 12945 }, 12946 run: function (e, n) { 12947 var a = t.hooks.all[e]; 12948 if (a && a.length) 12949 for (var r, i = 0; r = a[i++];) r(n) 12950 } 12951 } 12952 }, 12953 n = t.Token = function (e, t, n) { 12954 this.type = e, this.content = t, this.alias = n 12955 }; 12956 if (n.stringify = function (e, a, r) { 12957 if ("string" == typeof e) return e; 12958 if ("Array" === t.util.type(e)) return e.map(function (t) { 12959 return n.stringify(t, a, e) 12960 }).join(""); 12961 var i = { 12962 type: e.type, 12963 content: n.stringify(e.content, a, r), 12964 tag: "span", 12965 classes: ["token", e.type], 12966 attributes: {}, 12967 language: a, 12968 parent: r 12969 }; 12970 if ("comment" == i.type && (i.attributes.spellcheck = "true"), e.alias) { 12971 var l = "Array" === t.util.type(e.alias) ? e.alias : [e.alias]; 12972 Array.prototype.push.apply(i.classes, l) 12973 } 12974 t.hooks.run("wrap", i); 12975 var s = ""; 12976 for (var o in i.attributes) s += o + '="' + (i.attributes[o] || "") + '"'; 12977 return "<" + i.tag + ' class="' + i.classes.join(" ") + '" ' + s + ">" + i.content + "</" + i.tag + ">" 12978 }, !self.document) return self.addEventListener ? (self.addEventListener("message", function (e) { 12979 var n = JSON.parse(e.data), 12980 a = n.language, 12981 r = n.code; 12982 self.postMessage(JSON.stringify(t.util.encode(t.tokenize(r, t.languages[a])))), self.close() 12983 }, !1), self.Prism) : self.Prism; 12984 var a = document.getElementsByTagName("script"); 12985 return a = a[a.length - 1], a && (t.filename = a.src, document.addEventListener && !a.hasAttribute("data-manual") && document.addEventListener("DOMContentLoaded", t.highlightAll)), self.Prism 12986}(); 12987"undefined" != typeof module && module.exports && (module.exports = Prism);; 12988Prism.languages.markup = { 12989 comment: /<!--[\w\W]*?-->/, 12990 prolog: /<\?.+?\?>/, 12991 doctype: /<!DOCTYPE.+?>/, 12992 cdata: /<!\[CDATA\[[\w\W]*?]]>/i, 12993 tag: { 12994 pattern: /<\/?[\w:-]+\s*(?:\s+[\w:-]+(?:=(?:("|')(\\?[\w\W])*?\1|[^\s'">=]+))?\s*)*\/?>/i, 12995 inside: { 12996 tag: { 12997 pattern: /^<\/?[\w:-]+/i, 12998 inside: { 12999 punctuation: /^<\/?/, 13000 namespace: /^[\w-]+?:/ 13001 } 13002 }, 13003 "attr-value": { 13004 pattern: /=(?:('|")[\w\W]*?(\1)|[^\s>]+)/i, 13005 inside: { 13006 punctuation: /=|>|"/ 13007 } 13008 }, 13009 punctuation: /\/?>/, 13010 "attr-name": { 13011 pattern: /[\w:-]+/, 13012 inside: { 13013 namespace: /^[\w-]+?:/ 13014 } 13015 } 13016 } 13017 }, 13018 entity: /&#?[\da-z]{1,8};/i 13019}, Prism.hooks.add("wrap", function (t) { 13020 "entity" === t.type && (t.attributes.title = t.content.replace(/&/, "&")) 13021});; 13022Prism.languages.css = { 13023 comment: /\/\*[\w\W]*?\*\//, 13024 atrule: { 13025 pattern: /@[\w-]+?.*?(;|(?=\s*\{))/i, 13026 inside: { 13027 punctuation: /[;:]/ 13028 } 13029 }, 13030 url: /url\((?:(["'])(\\\n|\\?.)*?\1|.*?)\)/i, 13031 selector: /[^\{\}\s][^\{\};]*(?=\s*\{)/, 13032 string: /("|')(\\\n|\\?.)*?\1/, 13033 property: /(\b|\B)[\w-]+(?=\s*:)/i, 13034 important: /\B!important\b/i, 13035 punctuation: /[\{\};:]/, 13036 "function": /[-a-z0-9]+(?=\()/i 13037}, Prism.languages.markup && (Prism.languages.insertBefore("markup", "tag", { 13038 style: { 13039 pattern: /<style[\w\W]*?>[\w\W]*?<\/style>/i, 13040 inside: { 13041 tag: { 13042 pattern: /<style[\w\W]*?>|<\/style>/i, 13043 inside: Prism.languages.markup.tag.inside 13044 }, 13045 rest: Prism.languages.css 13046 }, 13047 alias: "language-css" 13048 } 13049}), Prism.languages.insertBefore("inside", "attr-value", { 13050 "style-attr": { 13051 pattern: /\s*style=("|').*?\1/i, 13052 inside: { 13053 "attr-name": { 13054 pattern: /^\s*style/i, 13055 inside: Prism.languages.markup.tag.inside 13056 }, 13057 punctuation: /^\s*=\s*['"]|['"]\s*$/, 13058 "attr-value": { 13059 pattern: /.+/i, 13060 inside: Prism.languages.css 13061 } 13062 }, 13063 alias: "language-css" 13064 } 13065}, Prism.languages.markup.tag));; 13066Prism.languages.clike = { 13067 comment: [{ 13068 pattern: /(^|[^\\])\/\*[\w\W]*?\*\//, 13069 lookbehind: !0 13070 }, { 13071 pattern: /(^|[^\\:])\/\/.*/, 13072 lookbehind: !0 13073 }], 13074 string: /("|')(\\\n|\\?.)*?\1/, 13075 "class-name": { 13076 pattern: /((?:(?:class|interface|extends|implements|trait|instanceof|new)\s+)|(?:catch\s+\())[a-z0-9_\.\\]+/i, 13077 lookbehind: !0, 13078 inside: { 13079 punctuation: /(\.|\\)/ 13080 } 13081 }, 13082 keyword: /\b(if|else|while|do|for|return|in|instanceof|function|new|try|throw|catch|finally|null|break|continue)\b/, 13083 "boolean": /\b(true|false)\b/, 13084 "function": { 13085 pattern: /[a-z0-9_]+\(/i, 13086 inside: { 13087 punctuation: /\(/ 13088 } 13089 }, 13090 number: /\b-?(0x[\dA-Fa-f]+|\d*\.?\d+([Ee]-?\d+)?)\b/, 13091 operator: /[-+]{1,2}|!|<=?|>=?|={1,3}|&{1,2}|\|?\||\?|\*|\/|~|\^|%/, 13092 ignore: /&(lt|gt|amp);/i, 13093 punctuation: /[{}[\];(),.:]/ 13094};; 13095Prism.languages.javascript = Prism.languages.extend("clike", { 13096 keyword: /\b(break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|false|finally|for|function|get|if|implements|import|in|instanceof|interface|let|new|null|package|private|protected|public|return|set|static|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/, 13097 number: /\b-?(0x[\dA-Fa-f]+|\d*\.?\d+([Ee][+-]?\d+)?|NaN|-?Infinity)\b/, 13098 "function": /(?!\d)[a-z0-9_$]+(?=\()/i 13099}), Prism.languages.insertBefore("javascript", "keyword", { 13100 regex: {
13101 pattern: /(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\r\n])+\/[gim]{0,3}(?=\s*($|[\r\n,.;})]))/, 13102 lookbehind: !0 13103 } 13104}), Prism.languages.markup && Prism.languages.insertBefore("markup", "tag", { 13105 script: { 13106 pattern: /<script[\w\W]*?>[\w\W]*?<\/script>/i, 13107 inside: { 13108 tag: { 13109 pattern: /<script[\w\W]*?>|<\/script>/i, 13110 inside: Prism.languages.markup.tag.inside 13111 }, 13112 rest: Prism.languages.javascript 13113 }, 13114 alias: "language-javascript" 13115 } 13116});; 13117Prism.languages.aspnet = Prism.languages.extend("markup", { 13118 "page-directive tag": { 13119 pattern: /<%\s*@.*%>/i, 13120 inside: { 13121 "page-directive tag": /<%\s*@\s*(?:Assembly|Control|Implements|Import|Master|MasterType|OutputCache|Page|PreviousPageType|Reference|Register)?|%>/i, 13122 rest: Prism.languages.markup.tag.inside 13123 } 13124 }, 13125 "directive tag": { 13126 pattern: /<%.*%>/i, 13127 inside: { 13128 "directive tag": /<%\s*?[$=%#:]{0,2}|%>/i, 13129 rest: Prism.languages.csharp 13130 } 13131 } 13132}), Prism.languages.insertBefore("inside", "punctuation", { 13133 "directive tag": Prism.languages.aspnet["directive tag"] 13134}, Prism.languages.aspnet.tag.inside["attr-value"]), Prism.languages.insertBefore("aspnet", "comment", { 13135 "asp comment": /<%--[\w\W]*?--%>/ 13136}), Prism.languages.insertBefore("aspnet", Prism.languages.javascript ? "script" : "tag", { 13137 "asp script": { 13138 pattern: /<script(?=.*runat=['"]?server['"]?)[\w\W]*?>[\w\W]*?<\/script>/i, 13139 inside: { 13140 tag: { 13141 pattern: /<\/?script\s*(?:\s+[\w:-]+(?:=(?:("|')(\\?[\w\W])*?\1|\w+))?\s*)*\/?>/i, 13142 inside: Prism.languages.aspnet.tag.inside 13143 }, 13144 rest: Prism.languages.csharp || {} 13145 } 13146 } 13147}), Prism.languages.aspnet.style && (Prism.languages.aspnet.style.inside.tag.pattern = /<\/?style\s*(?:\s+[\w:-]+(?:=(?:("|')(\\?[\w\W])*?\1|\w+))?\s*)*\/?>/i, Prism.languages.aspnet.style.inside.tag.inside = Prism.languages.aspnet.tag.inside), Prism.languages.aspnet.script && (Prism.languages.aspnet.script.inside.tag.pattern = Prism.languages.aspnet["asp script"].inside.tag.pattern, Prism.languages.aspnet.script.inside.tag.inside = Prism.languages.aspnet.tag.inside);; 13148Prism.languages.bash = Prism.languages.extend("clike", { 13149 comment: { 13150 pattern: /(^|[^"{\\])(#.*?(\r?\n|$))/, 13151 lookbehind: !0 13152 }, 13153 string: { 13154 pattern: /("|')(\\?[\s\S])*?\1/, 13155 inside: { 13156 property: /\$([a-zA-Z0-9_#\?\-\*!@]+|\{[^\}]+\})/ 13157 } 13158 }, 13159 number: { 13160 pattern: /([^\w\.])-?(0x[\dA-Fa-f]+|\d*\.?\d+([Ee]-?\d+)?)\b/, 13161 lookbehind: !0 13162 }, 13163 "function": /\b(?:alias|apropos|apt-get|aptitude|aspell|awk|basename|bash|bc|bg|builtin|bzip2|cal|cat|cd|cfdisk|chgrp|chmod|chown|chroot|chkconfig|cksum|clear|cmp|comm|command|cp|cron|crontab|csplit|cut|date|dc|dd|ddrescue|declare|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|du|echo|egrep|eject|enable|env|ethtool|eval|exec|exit|expand|expect|export|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|getopts|git|grep|groupadd|groupdel|groupmod|groups|gzip|hash|head|help|hg|history|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|jobs|join|kill|killall|less|link|ln|locate|logname|logout|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|make|man|mkdir|mkfifo|mkisofs|mknod|more|most|mount|mtools|mtr|mv|mmv|nano|netstat|nice|nl|nohup|notify-send|nslookup|open|op|passwd|paste|pathchk|ping|pkill|popd|pr|printcap|printenv|printf|ps|pushd|pv|pwd|quota|quotacheck|quotactl|ram|rar|rcp|read|readarray|readonly|reboot|rename|renice|remsync|rev|rm|rmdir|rsync|screen|scp|sdiff|sed|select|seq|service|sftp|shift|shopt|shutdown|sleep|slocate|sort|source|split|ssh|stat|strace|su|sudo|sum|suspend|sync|tail|tar|tee|test|time|timeout|times|touch|top|traceroute|trap|tr|tsort|tty|type|ulimit|umask|umount|unalias|uname|unexpand|uniq|units|unrar|unshar|until|uptime|useradd|userdel|usermod|users|uuencode|uudecode|v|vdir|vi|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yes|zip)\b/, 13164 keyword: /\b(if|then|else|elif|fi|for|break|continue|while|in|case|function|select|do|done|until|echo|exit|return|set|declare)\b/ 13165}), Prism.languages.insertBefore("bash", "keyword", { 13166 property: /\$([a-zA-Z0-9_#\?\-\*!@]+|\{[^}]+\})/ 13167}), Prism.languages.insertBefore("bash", "comment", { 13168 important: /(^#!\s*\/bin\/bash)|(^#!\s*\/bin\/sh)/ 13169});; 13170Prism.languages.c = Prism.languages.extend("clike", { 13171 string: /("|')([^\n\\\1]|\\.|\\\r*\n)*?\1/, 13172 keyword: /\b(asm|typeof|inline|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|union|unsigned|void|volatile|while)\b/, 13173 operator: /[-+]{1,2}|!=?|<{1,2}=?|>{1,2}=?|\->|={1,2}|\^|~|%|&{1,2}|\|?\||\?|\*|\// 13174}), Prism.languages.insertBefore("c", "string", { 13175 property: { 13176 pattern: /((^|\n)\s*)#\s*[a-z]+([^\n\\]|\\.|\\\r*\n)*/i, 13177 lookbehind: !0, 13178 inside: {
13179 string: { 13180 pattern: /(#\s*include\s*)(<.+?>|("|')(\\?.)+?\3)/, 13181 lookbehind: !0 13182 } 13183 } 13184 } 13185}), delete Prism.languages.c["class-name"], delete Prism.languages.c["boolean"];; 13186Prism.languages.csharp = Prism.languages.extend("clike", { 13187 keyword: /\b(abstract|as|async|await|base|bool|break|byte|case|catch|char|checked|class|const|continue|decimal|default|delegate|do|double|else|enum|event|explicit|extern|false|finally|fixed|float|for|foreach|goto|if|implicit|in|int|interface|internal|is|lock|long|namespace|new|null|object|operator|out|override|params|private|protected|public|readonly|ref|return|sbyte|sealed|short|sizeof|stackalloc|static|string|struct|switch|this|throw|true|try|typeof|uint|ulong|unchecked|unsafe|ushort|using|virtual|void|volatile|while|add|alias|ascending|async|await|descending|dynamic|from|get|global|group|into|join|let|orderby|partial|remove|select|set|value|var|where|yield)\b/, 13188 string: [/@("|')(\1\1|\\\1|\\?(?!\1)[\s\S])*\1/, /("|')(\\?.)*?\1/], 13189 preprocessor: /^\s*#.*/m, 13190 number: /\b-?(0x[\da-f]+|\d*\.?\d+)\b/i 13191});; 13192Prism.languages.cpp = Prism.languages.extend("c", { 13193 keyword: /\b(alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|class|compl|const|constexpr|const_cast|continue|decltype|default|delete|delete\[\]|do|double|dynamic_cast|else|enum|explicit|export|extern|float|for|friend|goto|if|inline|int|long|mutable|namespace|new|new\[\]|noexcept|nullptr|operator|private|protected|public|register|reinterpret_cast|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/, 13194 "boolean": /\b(true|false)\b/, 13195 operator: /[-+]{1,2}|!=?|<{1,2}=?|>{1,2}=?|\->|:{1,2}|={1,2}|\^|~|%|&{1,2}|\|?\||\?|\*|\/|\b(and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/ 13196}), Prism.languages.insertBefore("cpp", "keyword", { 13197 "class-name": { 13198 pattern: /(class\s+)[a-z0-9_]+/i, 13199 lookbehind: !0 13200 } 13201});; 13202! function (e) { 13203 var n = /#(?!\{).+/, 13204 t = { 13205 pattern: /#\{[^}]+\}/, 13206 alias: "variable" 13207 }; 13208 e.languages.coffeescript = e.languages.extend("javascript", { 13209 comment: n, 13210 string: [/'(?:\\?[\s\S])*?'/, { 13211 pattern: /"(?:\\?[\s\S])*?"/, 13212 inside: { 13213 interpolation: t 13214 } 13215 }], 13216 keyword: /\b(and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/, 13217 "class-member": { 13218 pattern: /@(?!\d)\w+/, 13219 alias: "variable" 13220 } 13221 }), e.languages.insertBefore("coffeescript", "comment", { 13222 "multiline-comment": { 13223 pattern: /###[\s\S]+?###/, 13224 alias: "comment" 13225 }, 13226 "block-regex": { 13227 pattern: /\/{3}[\s\S]*?\/{3}/, 13228 alias: "regex", 13229 inside: { 13230 comment: n, 13231 interpolation: t 13232 } 13233 } 13234 }), e.languages.insertBefore("coffeescript", "string", { 13235 "inline-javascript": { 13236 pattern: /`(?:\\?[\s\S])*?`/, 13237 inside: { 13238 delimiter: { 13239 pattern: /^`|`$/, 13240 alias: "punctuation" 13241 }, 13242 rest: e.languages.javascript 13243 } 13244 }, 13245 "multiline-string": [{ 13246 pattern: /'''[\s\S]*?'''/, 13247 alias: "string" 13248 }, { 13249 pattern: /"""[\s\S]*?"""/, 13250 alias: "string", 13251 inside: { 13252 interpolation: t 13253 } 13254 }] 13255 }), e.languages.insertBefore("coffeescript", "keyword", { 13256 property: /(?!\d)\w+(?=\s*:(?!:))/ 13257 }) 13258}(Prism);; 13259Prism.languages.css.selector = { 13260 pattern: /[^\{\}\s][^\{\}]*(?=\s*\{)/, 13261 inside: { 13262 "pseudo-element": /:(?:after|before|first-letter|first-line|selection)|::[-\w]+/, 13263 "pseudo-class": /:[-\w]+(?:\(.*\))?/, 13264 "class": /\.[-:\.\w]+/, 13265 id: /#[-:\.\w]+/ 13266 } 13267}, Prism.languages.insertBefore("css", "function", { 13268 hexcode: /#[\da-f]{3,6}/i, 13269 entity: /\\[\da-f]{1,8}/i, 13270 number: /[\d%\.]+/ 13271});; 13272Prism.languages.git = { 13273 comment: /^#.*$/m, 13274 string: /("|')(\\?.)*?\1/m, 13275 command: { 13276 pattern: /^.*\$ git .*$/m, 13277 inside: { 13278 parameter: /\s(--|-)\w+/m 13279 } 13280 }, 13281 coord: /^@@.*@@$/m, 13282 deleted: /^-(?!-).+$/m, 13283 inserted: /^\+(?!\+).+$/m, 13284 commit_sha1: /^commit \w{40}$/m 13285};; 13286Prism.languages.http = { 13287 "request-line": { 13288 pattern: /^(POST|GET|PUT|DELETE|OPTIONS|PATCH|TRACE|CONNECT)\b\shttps?:\/\/\S+\sHTTP\/[0-9.]+/, 13289 inside: { 13290 property: /^\b(POST|GET|PUT|DELETE|OPTIONS|PATCH|TRACE|CONNECT)\b/, 13291 "attr-name": /:\w+/ 13292 } 13293 }, 13294 "response-status": { 13295 pattern: /^HTTP\/1.[01] [0-9]+.*/, 13296 inside: { 13297 property: /[0-9]+[A-Z\s-]+$/i 13298 } 13299 }, 13300 keyword: /^[\w-]+:(?=.+)/m 13301}; 13302var httpLanguages = { 13303 "application/json": Prism.languages.javascript, 13304 "application/xml": Prism.languages.markup, 13305 "text/xml": Prism.languages.markup, 13306 "text/html": Prism.languages.markup 13307}; 13308for (var contentType in httpLanguages) 13309 if (httpLanguages[contentType]) { 13310 var options = {}; 13311 options[contentType] = { 13312 pattern: new RegExp("(content-type:\\s*" + contentType + "[\\w\\W]*?)\\n\\n[\\w\\W]*", "i"), 13313 lookbehind: !0, 13314 inside: { 13315 rest: httpLanguages[contentType] 13316 } 13317 }, Prism.languages.insertBefore("http", "keyword", options) 13318 }; 13319Prism.languages.ini = { 13320 comment: /^\s*;.*$/m, 13321 important: /\[.*?\]/m, 13322 constant: /^\s*[^\s=]+?(?=[ \t]*=)/m, 13323 "attr-value": { 13324 pattern: /=.*/m, 13325 inside: { 13326 punctuation: /^[=]/ 13327 } 13328 } 13329};; 13330Prism.languages.java = Prism.languages.extend("clike", { 13331 keyword: /\b(abstract|continue|for|new|switch|assert|default|goto|package|synchronized|boolean|do|if|private|this|break|double|implements|protected|throw|byte|else|import|public|throws|case|enum|instanceof|return|transient|catch|extends|int|short|try|char|final|interface|static|void|class|finally|long|strictfp|volatile|const|float|native|super|while)\b/, 13332 number: /\b0b[01]+\b|\b0x[\da-f]*\.?[\da-fp\-]+\b|\b\d*\.?\d+[e]?[\d]*[df]\b|\b\d*\.?\d+\b/i, 13333 operator: { 13334 pattern: /(^|[^\.])(?:\+=|\+\+?|-=|--?|!=?|<{1,2}=?|>{1,3}=?|==?|&=|&&?|\|=|\|\|?|\?|\*=?|\/=?|%=?|\^=?|:|~)/m,
vendor: 4,607 bytes, lines 13335-13421
13335 lookbehind: !0 13336 } 13337});; 13338Prism.languages.latex = { 13339 comment: /%.*?(\r?\n|$)$/m, 13340 string: /(\$)(\\?.)*?\1/, 13341 punctuation: /[{}]/, 13342 selector: /\\[a-z;,:\.]*/i 13343};; 13344Prism.languages.less = Prism.languages.extend("css", { 13345 comment: [/\/\*[\w\W]*?\*\//, { 13346 pattern: /(^|[^\\])\/\/.*/, 13347 lookbehind: !0 13348 }], 13349 atrule: { 13350 pattern: /@[\w-]+?(?:\([^{}]+\)|[^(){};])*?(?=\s*\{)/i, 13351 inside: { 13352 punctuation: /[:()]/ 13353 } 13354 }, 13355 selector: { 13356 pattern: /(?:@\{[\w-]+\}|[^{};\s@])(?:@\{[\w-]+\}|\([^{}]*\)|[^{};@])*?(?=\s*\{)/, 13357 inside: { 13358 variable: /@+[\w-]+/ 13359 } 13360 }, 13361 property: /(\b|\B)(?:@\{[\w-]+\}|[\w-])+(?:\+_?)?(?=\s*:)/i, 13362 punctuation: /[{}();:,]/, 13363 operator: /[+\-*\/]/ 13364}), Prism.languages.insertBefore("less", "punctuation", { 13365 "function": Prism.languages.less.function 13366}), Prism.languages.insertBefore("less", "property", { 13367 variable: [{ 13368 pattern: /@[\w-]+\s*:/, 13369 inside: { 13370 punctuation: /:/ 13371 } 13372 }, /@@?[\w-]+/], 13373 "mixin-usage": { 13374 pattern: /([{;]\s*)[.#](?!\d)[\w-]+.*?(?=[(;])/, 13375 lookbehind: !0, 13376 alias: "function" 13377 } 13378});; 13379Prism.languages.matlab = { 13380 string: { 13381 pattern: /(^|\W)'(?:''|[^'\n])*'/, 13382 lookbehind: !0 13383 }, 13384 comment: [/%\{[\s\S]*?\}%/, /%.+/], 13385 number: /\b-?(?:\d*\.?\d+(?:[eE][+-]?\d+)?(?:[ij])?|[ij])\b/, 13386 keyword: /\b(?:break|case|catch|continue|else|elseif|end|for|function|if|inf|NaN|otherwise|parfor|pause|pi|return|switch|try|while)\b/, 13387 "function": /(?!\d)\w+(?=\s*\()/, 13388 operator: /\.?[*^\/\\']|[+\-:@]|[<>=~]=?|&&?|\|\|?/, 13389 punctuation: /\.{3}|[.,;\[\](){}!]/ 13390};; 13391Prism.languages.objectivec = Prism.languages.extend("c", { 13392 keyword: /(\b(asm|typeof|inline|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|union|unsigned|void|volatile|while|in|self|super)\b)|((?=[\w|@])(@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b)/, 13393 string: /(?:("|')([^\n\\\1]|\\.|\\\r*\n)*?\1)|(@"([^\n\\"]|\\.|\\\r*\n)*?")/, 13394 operator: /[-+]{1,2}|!=?|<{1,2}=?|>{1,2}=?|\->|={1,2}|\^|~|%|&{1,2}|\|?\||\?|\*|\/|@/ 13395});; 13396Prism.languages.perl = { 13397 comment: [{ 13398 pattern: /((?:^|\n)\s*)=\w+[\s\S]*?=cut.*/, 13399 lookbehind: !0 13400 }, { 13401 pattern: /(^|[^\\$])#.*?(\r?\n|$)/, 13402 lookbehind: !0 13403 }], 13404 string: [/\b(?:q|qq|qx|qw)\s*([^a-zA-Z0-9\s\{\(\[<])(\\?.)*?\s*\1/, /\b(?:q|qq|qx|qw)\s+([a-zA-Z0-9])(\\?.)*?\s*\1/, /\b(?:q|qq|qx|qw)\s*\(([^()]|\\.)*\s*\)/, /\b(?:q|qq|qx|qw)\s*\{([^{}]|\\.)*\s*\}/, /\b(?:q|qq|qx|qw)\s*\[([^[\]]|\\.)*\s*\]/, /\b(?:q|qq|qx|qw)\s*<([^<>]|\\.)*\s*>/, /("|'|`)(\\?.)*?\1/], 13405 regex: [/\b(?:m|qr)\s*([^a-zA-Z0-9\s\{\(\[<])(\\?.)*?\s*\1[msixpodualgc]*/, /\b(?:m|qr)\s+([a-zA-Z0-9])(\\?.)*?\s*\1[msixpodualgc]*/, /\b(?:m|qr)\s*\(([^()]|\\.)*\s*\)[msixpodualgc]*/, /\b(?:m|qr)\s*\{([^{}]|\\.)*\s*\}[msixpodualgc]*/, /\b(?:m|qr)\s*\[([^[\]]|\\.)*\s*\][msixpodualgc]*/, /\b(?:m|qr)\s*<([^<>]|\\.)*\s*>[msixpodualgc]*/, /\b(?:s|tr|y)\s*([^a-zA-Z0-9\s\{\(\[<])(\\?.)*?\s*\1\s*((?!\1).|\\.)*\s*\1[msixpodualgcer]*/, /\b(?:s|tr|y)\s+([a-zA-Z0-9])(\\?.)*?\s*\1\s*((?!\1).|\\.)*\s*\1[msixpodualgcer]*/, /\b(?:s|tr|y)\s*\(([^()]|\\.)*\s*\)\s*\(\s*([^()]|\\.)*\s*\)[msixpodualgcer]*/, /\b(?:s|tr|y)\s*\{([^{}]|\\.)*\s*\}\s*\{\s*([^{}]|\\.)*\s*\}[msixpodualgcer]*/, /\b(?:s|tr|y)\s*\[([^[\]]|\\.)*\s*\]\s*\[\s*([^[\]]|\\.)*\s*\][msixpodualgcer]*/, /\b(?:s|tr|y)\s*<([^<>]|\\.)*\s*>\s*<\s*([^<>]|\\.)*\s*>[msixpodualgcer]*/, /\/(\[.+?]|\\.|[^\/\r\n])*\/[msixpodualgc]*(?=\s*($|[\r\n,.;})&|\-+*=~<>!?^]|(lt|gt|le|ge|eq|ne|cmp|not|and|or|xor|x)\b))/], 13406 variable: [/[&*\$@%]\{\^[A-Z]+\}/, /[&*\$@%]\^[A-Z_]/, /[&*\$@%]#?(?=\{)/, /[&*\$@%]#?((::)*'?(?!\d)[\w$]+)+(::)*/i, /[&*\$@%]\d+/, /[\$@%][!"#\$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~]/], 13407 filehandle: { 13408 pattern: /<(?!=).*>|\b_\b/, 13409 alias: "symbol" 13410 }, 13411 vstring: { 13412 pattern: /v\d+(\.\d+)*|\d+(\.\d+){2,}/, 13413 alias: "string" 13414 }, 13415 "function": { 13416 pattern: /sub [a-z0-9_]+/i, 13417 inside: { 13418 keyword: /sub/ 13419 } 13420 }, 13421 keyword: /\b(any|break|continue|default|delete|die|do|else|elsif|eval|for|foreach|given|goto|if|last|local|my|next|our|package|print|redo|require|say|state|sub|switch|undef|unless|until|use|when|while)\b/,
vendor: 4,395 bytes, lines 13422-13503
13422 number: /(\n|\b)-?(0x[\dA-Fa-f](_?[\dA-Fa-f])*|0b[01](_?[01])*|(\d(_?\d)*)?\.?\d(_?\d)*([Ee]-?\d+)?)\b/, 13423 operator: /-[rwxoRWXOezsfdlpSbctugkTBMAC]\b|[-+*=~\/|&]{1,2}|<=?|>=?|\.{1,3}|[!?\\^]|\b(lt|gt|le|ge|eq|ne|cmp|not|and|or|xor|x)\b/, 13424 punctuation: /[{}[\];(),:]/ 13425};; 13426Prism.languages.php = Prism.languages.extend("clike", { 13427 keyword: /\b(and|or|xor|array|as|break|case|cfunction|class|const|continue|declare|default|die|do|else|elseif|enddeclare|endfor|endforeach|endif|endswitch|endwhile|extends|for|foreach|function|include|include_once|global|if|new|return|static|switch|use|require|require_once|var|while|abstract|interface|public|implements|private|protected|parent|throw|null|echo|print|trait|namespace|final|yield|goto|instanceof|finally|try|catch)\b/i, 13428 constant: /\b[A-Z0-9_]{2,}\b/, 13429 comment: { 13430 pattern: /(^|[^\\])(\/\*[\w\W]*?\*\/|(^|[^:])(\/\/).*?(\r?\n|$))/, 13431 lookbehind: !0 13432 } 13433}), Prism.languages.insertBefore("php", "class-name", { 13434 "shell-comment": { 13435 pattern: /(^|[^\\])#.*?(\r?\n|$)/, 13436 lookbehind: !0, 13437 alias: "comment" 13438 } 13439}), Prism.languages.insertBefore("php", "keyword", { 13440 delimiter: /(\?>|<\?php|<\?)/i, 13441 variable: /(\$\w+)\b/i, 13442 "package": { 13443 pattern: /(\\|namespace\s+|use\s+)[\w\\]+/, 13444 lookbehind: !0, 13445 inside: { 13446 punctuation: /\\/ 13447 } 13448 } 13449}), Prism.languages.insertBefore("php", "operator", { 13450 property: { 13451 pattern: /(->)[\w]+/, 13452 lookbehind: !0 13453 } 13454}), Prism.languages.markup && (Prism.hooks.add("before-highlight", function (e) { 13455 "php" === e.language && (e.tokenStack = [], e.backupCode = e.code, e.code = e.code.replace(/(?:<\?php|<\?)[\w\W]*?(?:\?>)/gi, function (n) { 13456 return e.tokenStack.push(n), "{{{PHP" + e.tokenStack.length + "}}}" 13457 })) 13458}), Prism.hooks.add("before-insert", function (e) { 13459 "php" === e.language && (e.code = e.backupCode, delete e.backupCode) 13460}), Prism.hooks.add("after-highlight", function (e) { 13461 if ("php" === e.language) { 13462 for (var n, a = 0; n = e.tokenStack[a]; a++) e.highlightedCode = e.highlightedCode.replace("{{{PHP" + (a + 1) + "}}}", Prism.highlight(n, e.grammar, "php")); 13463 e.element.innerHTML = e.highlightedCode 13464 } 13465}), Prism.hooks.add("wrap", function (e) { 13466 "php" === e.language && "markup" === e.type && (e.content = e.content.replace(/(\{\{\{PHP[0-9]+\}\}\})/g, '<span class="token php">$1</span>')) 13467}), Prism.languages.insertBefore("php", "comment", { 13468 markup: { 13469 pattern: /<[^?]\/?(.*?)>/, 13470 inside: Prism.languages.markup 13471 }, 13472 php: /\{\{\{PHP[0-9]+\}\}\}/ 13473}));; 13474Prism.languages.insertBefore("php", "variable", { 13475 "this": /\$this/, 13476 global: /\$_?(GLOBALS|SERVER|GET|POST|FILES|REQUEST|SESSION|ENV|COOKIE|HTTP_RAW_POST_DATA|argc|argv|php_errormsg|http_response_header)/, 13477 scope: { 13478 pattern: /\b[\w\\]+::/, 13479 inside: { 13480 keyword: /(static|self|parent)/, 13481 punctuation: /(::|\\)/ 13482 } 13483 } 13484});; 13485Prism.languages.python = { 13486 comment: { 13487 pattern: /(^|[^\\])#.*?(\r?\n|$)/, 13488 lookbehind: !0 13489 }, 13490 string: /"""[\s\S]+?"""|'''[\s\S]+?'''|("|')(\\?.)*?\1/, 13491 keyword: /\b(as|assert|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|pass|print|raise|return|try|while|with|yield)\b/, 13492 "boolean": /\b(True|False)\b/, 13493 number: /\b-?(0[box])?(?:[\da-f]+\.?\d*|\.\d+)(?:e[+-]?\d+)?j?\b/i, 13494 operator: /[-+]|<=?|>=?|!|={1,2}|&{1,2}|\|?\||\?|\*|\/|~|\^|%|\b(or|and|not)\b/, 13495 punctuation: /[{}[\];(),.:]/ 13496};; 13497Prism.languages.ruby = Prism.languages.extend("clike", { 13498 comment: /#[^\r\n]*(\r?\n|$)/, 13499 keyword: /\b(alias|and|BEGIN|begin|break|case|class|def|define_method|defined|do|each|else|elsif|END|end|ensure|false|for|if|in|module|new|next|nil|not|or|raise|redo|require|rescue|retry|return|self|super|then|throw|true|undef|unless|until|when|while|yield)\b/, 13500 builtin: /\b(Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Stat|File|Fixnum|Fload|Hash|Integer|IO|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|String|Struct|TMS|Symbol|ThreadGroup|Thread|Time|TrueClass)\b/, 13501 constant: /\b[A-Z][a-zA-Z_0-9]*[?!]?\b/ 13502}), Prism.languages.insertBefore("ruby", "keyword", { 13503 regex: {
13504 pattern: /(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\r\n])+\/[gim]{0,3}(?=\s*($|[\r\n,.;})]))/, 13505 lookbehind: !0 13506 }, 13507 variable: /[@$]+\b[a-zA-Z_][a-zA-Z_0-9]*[?!]?\b/, 13508 symbol: /:\b[a-zA-Z_][a-zA-Z_0-9]*[?!]?\b/ 13509});; 13510Prism.languages.scss = Prism.languages.extend("css", { 13511 comment: { 13512 pattern: /(^|[^\\])(\/\*[\w\W]*?\*\/|\/\/.*?(\r?\n|$))/, 13513 lookbehind: !0 13514 }, 13515 atrule: /@[\w-]+(?=\s+(\(|\{|;))/i, 13516 url: /([-a-z]+-)*url(?=\()/i, 13517 selector: /([^@;\{\}\(\)]?([^@;\{\}\(\)]|&|#\{\$[-_\w]+\})+)(?=\s*\{(\}|\s|[^\}]+(:|\{)[^\}]+))/m 13518}), Prism.languages.insertBefore("scss", "atrule", { 13519 keyword: /@(if|else if|else|for|each|while|import|extend|debug|warn|mixin|include|function|return|content)|(?=@for\s+\$[-_\w]+\s)+from/i 13520}), Prism.languages.insertBefore("scss", "property", { 13521 variable: /((\$[-_\w]+)|(#\{\$[-_\w]+\}))/i 13522}), Prism.languages.insertBefore("scss", "function", { 13523 placeholder: /%[-_\w]+/i, 13524 statement: /\B!(default|optional)\b/i, 13525 "boolean": /\b(true|false)\b/, 13526 "null": /\b(null)\b/, 13527 operator: /\s+([-+]{1,2}|={1,2}|!=|\|?\||\?|\*|\/|%)\s+/ 13528});; 13529Prism.languages.sql = { 13530 comment: { 13531 pattern: /(^|[^\\])(\/\*[\w\W]*?\*\/|((--)|(\/\/)|#).*?(\r?\n|$))/, 13532 lookbehind: !0 13533 }, 13534 string: { 13535 pattern: /(^|[^@])("|')(\\?[\s\S])*?\2/, 13536 lookbehind: !0 13537 }, 13538 variable: /@[\w.$]+|@("|'|`)(\\?[\s\S])+?\1/, 13539 "function": /\b(?:COUNT|SUM|AVG|MIN|MAX|FIRST|LAST|UCASE|LCASE|MID|LEN|ROUND|NOW|FORMAT)(?=\s*\()/i, 13540 keyword: /\b(?:ACTION|ADD|AFTER|ALGORITHM|ALTER|ANALYZE|APPLY|AS|ASC|AUTHORIZATION|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADE|CASCADED|CASE|CHAIN|CHAR VARYING|CHARACTER VARYING|CHECK|CHECKPOINT|CLOSE|CLUSTERED|COALESCE|COLUMN|COLUMNS|COMMENT|COMMIT|COMMITTED|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS|CONTAINSTABLE|CONTINUE|CONVERT|CREATE|CROSS|CURRENT|CURRENT_DATE|CURRENT_TIME|CURRENT_TIMESTAMP|CURRENT_USER|CURSOR|DATA|DATABASE|DATABASES|DATETIME|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DOUBLE PRECISION|DROP|DUMMY|DUMP|DUMPFILE|DUPLICATE KEY|ELSE|ENABLE|ENCLOSED BY|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPE|ESCAPED BY|EXCEPT|EXEC|EXECUTE|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR|FOR EACH ROW|FORCE|FOREIGN|FREETEXT|FREETEXTTABLE|FROM|FULL|FUNCTION|GEOMETRY|GEOMETRYCOLLECTION|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|IDENTITY|IDENTITY_INSERT|IDENTITYCOL|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTO|INVOKER|ISOLATION LEVEL|JOIN|KEY|KEYS|KILL|LANGUAGE SQL|LAST|LEFT|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONGBLOB|LONGTEXT|MATCH|MATCHED|MEDIUMBLOB|MEDIUMINT|MEDIUMTEXT|MERGE|MIDDLEINT|MODIFIES SQL DATA|MODIFY|MULTILINESTRING|MULTIPOINT|MULTIPOLYGON|NATIONAL|NATIONAL CHAR VARYING|NATIONAL CHARACTER|NATIONAL CHARACTER VARYING|NATIONAL VARCHAR|NATURAL|NCHAR|NCHAR VARCHAR|NEXT|NO|NO SQL|NOCHECK|NOCYCLE|NONCLUSTERED|NULLIF|NUMERIC|OF|OFF|OFFSETS|ON|OPEN|OPENDATASOURCE|OPENQUERY|OPENROWSET|OPTIMIZE|OPTION|OPTIONALLY|ORDER|OUT|OUTER|OUTFILE|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREV|PRIMARY|PRINT|PRIVILEGES|PROC|PROCEDURE|PUBLIC|PURGE|QUICK|RAISERROR|READ|READS SQL DATA|READTEXT|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEATABLE|REPLICATION|REQUIRE|RESTORE|RESTRICT|RETURN|RETURNS|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROWCOUNT|ROWGUIDCOL|ROWS?|RTREE|RULE|SAVE|SAVEPOINT|SCHEMA|SELECT|SERIAL|SERIALIZABLE|SESSION|SESSION_USER|SET|SETUSER|SHARE MODE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|START|STARTING BY|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLE|TABLES|TABLESPACE|TEMP(?:ORARY)?|TEMPTABLE|TERMINATED BY|TEXT|TEXTSIZE|THEN|TIMESTAMP|TINYBLOB|TINYINT|TINYTEXT|TO|TOP|TRAN|TRANSACTION|TRANSACTIONS|TRIGGER|TRUNCATE|TSEQUAL|TYPE|TYPES|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNPIVOT|UPDATE|UPDATETEXT|USAGE|USE|USER|USING|VALUE|VALUES|VARBINARY|VARCHAR|VARCHARACTER|VARYING|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH|WITH ROLLUP|WITHIN|WORK|WRITE|WRITETEXT)\b/i, 13541 "boolean": /\b(?:TRUE|FALSE|NULL)\b/i, 13542 number: /\b-?(0x)?\d*\.?[\da-f]+\b/, 13543 operator: /\b(?:ALL|AND|ANY|BETWEEN|EXISTS|IN|LIKE|NOT|OR|IS|UNIQUE|CHARACTER SET|COLLATE|DIV|OF
13543FSET|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b|[-+]|!|[=<>]{1,2}|(&){1,2}|\|?\||\?|\*|\//i, 13544 punctuation: /[;[\]()`,.]/ 13545};; 13546Prism.languages.swift = Prism.languages.extend("clike", { 13547 keyword: /\b(as|associativity|break|case|class|continue|convenience|default|deinit|didSet|do|dynamicType|else|enum|extension|fallthrough|final|for|func|get|if|import|in|infix|init|inout|internal|is|lazy|left|let|mutating|new|none|nonmutating|operator|optional|override|postfix|precedence|prefix|private|protocol|public|required|return|right|safe|self|Self|set|static|struct|subscript|super|switch|Type|typealias|unowned|unowned|unsafe|var|weak|where|while|willSet|__COLUMN__|__FILE__|__FUNCTION__|__LINE__)\b/, 13548 number: /\b([\d_]+(\.[\de_]+)?|0x[a-f0-9_]+(\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i, 13549 constant: /\b(nil|[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/, 13550 atrule: /@\b(IBOutlet|IBDesignable|IBAction|IBInspectable|class_protocol|exported|noreturn|NSCopying|NSManaged|objc|UIApplicationMain|auto_closure)\b/, 13551 builtin: /\b([A-Z]\S+|abs|advance|alignof|alignofValue|assert|contains|count|countElements|debugPrint|debugPrintln|distance|dropFirst|dropLast|dump|enumerate|equal|filter|find|first|getVaList|indices|isEmpty|join|last|lazy|lexicographicalCompare|map|max|maxElement|min|minElement|numericCast|overlaps|partition|prefix|print|println|reduce|reflect|reverse|sizeof|sizeofValue|sort|sorted|split|startsWith|stride|strideof|strideofValue|suffix|swap|toDebugString|toString|transcode|underestimateCount|unsafeBitCast|withExtendedLifetime|withUnsafeMutablePointer|withUnsafeMutablePointers|withUnsafePointer|withUnsafePointers|withVaList)\b/ 13552});; 13553Prism.hooks.add("after-highlight", function (e) { 13554 var t = e.element.parentNode, 13555 s = /\s*\bline-numbers\b\s*/; 13556 if (t && /pre/i.test(t.nodeName) && (s.test(t.className) || s.test(e.element.className))) { 13557 s.test(e.element.className) && (e.element.className = e.element.className.replace(s, "")), s.test(t.className) || (t.className += " line-numbers"); 13558 var a, n = 1 + e.code.split("\n").length, 13559 l = new Array(n);
vendor: 7,635 bytes, lines 13560-13655
13560 l = l.join("<span></span>"), a = document.createElement("span"), a.className = "line-numbers-rows", a.innerHTML = l, t.hasAttribute("data-start") && (t.style.counterReset = "linenumber " + (parseInt(t.getAttribute("data-start"), 10) - 1)), e.element.appendChild(a) 13561 } 13562});; 13563! function () { 13564 if (self.Prism) { 13565 var e = { 13566 csharp: "C#", 13567 cpp: "C++" 13568 }; 13569 Prism.hooks.add("before-highlight", function (a) { 13570 var t = a.element.parentNode; 13571 if (t && /pre/i.test(t.nodeName)) { 13572 var i = e[a.language] || a.language; 13573 t.setAttribute("data-language", i) 13574 } 13575 }) 13576 } 13577}();; 13578 13579 13580 13581/* 13582 * YTPlayer 13583 * ----------------------------------------------- 13584 */ 13585function onYouTubePlayerAPIReady() { 13586 ytp.YTAPIReady || (ytp.YTAPIReady = !0, jQuery(document).trigger("YTAPIReady")) 13587} 13588var ytp = ytp || {}; 13589! function (jQuery, ytp) { 13590 var nAgt = navigator.userAgent; 13591 if (!jQuery.browser) { 13592 jQuery.browser = {}, jQuery.browser.mozilla = !1, jQuery.browser.webkit = !1, jQuery.browser.opera = !1, jQuery.browser.safari = !1, jQuery.browser.chrome = !1, jQuery.browser.msie = !1, jQuery.browser.ua = nAgt, jQuery.browser.name = navigator.appName, jQuery.browser.fullVersion = "" + parseFloat(navigator.appVersion), jQuery.browser.majorVersion = parseInt(navigator.appVersion, 10); 13593 var nameOffset, verOffset, ix; 13594 if (-1 != (verOffset = nAgt.indexOf("Opera"))) jQuery.browser.opera = !0, jQuery.browser.name = "Opera", jQuery.browser.fullVersion = nAgt.substring(verOffset + 6), -1 != (verOffset = nAgt.indexOf("Version")) && (jQuery.browser.fullVersion = nAgt.substring(verOffset + 8)); 13595 else if (-1 != (verOffset = nAgt.indexOf("MSIE"))) jQuery.browser.msie = !0, jQuery.browser.name = "Microsoft Internet Explorer", jQuery.browser.fullVersion = nAgt.substring(verOffset + 5); 13596 else if (-1 != nAgt.indexOf("Trident")) { 13597 jQuery.browser.msie = !0, jQuery.browser.name = "Microsoft Internet Explorer"; 13598 var start = nAgt.indexOf("rv:") + 3, 13599 end = start + 4; 13600 jQuery.browser.fullVersion = nAgt.substring(start, end) 13601 } else -1 != (verOffset = nAgt.indexOf("Chrome")) ? (jQuery.browser.webkit = !0, jQuery.browser.chrome = !0, jQuery.browser.name = "Chrome", jQuery.browser.fullVersion = nAgt.substring(verOffset + 7)) : -1 != (verOffset = nAgt.indexOf("Safari")) ? (jQuery.browser.webkit = !0, jQuery.browser.safari = !0, jQuery.browser.name = "Safari", jQuery.browser.fullVersion = nAgt.substring(verOffset + 7), -1 != (verOffset = nAgt.indexOf("Version")) && (jQuery.browser.fullVersion = nAgt.substring(verOffset + 8))) : -1 != (verOffset = nAgt.indexOf("AppleWebkit")) ? (jQuery.browser.webkit = !0, jQuery.browser.name = "Safari", jQuery.browser.fullVersion = nAgt.substring(verOffset + 7), -1 != (verOffset = nAgt.indexOf("Version")) && (jQuery.browser.fullVersion = nAgt.substring(verOffset + 8))) : -1 != (verOffset = nAgt.indexOf("Firefox")) ? (jQuery.browser.mozilla = !0, jQuery.browser.name = "Firefox", jQuery.browser.fullVersion = nAgt.substring(verOffset + 8)) : (nameOffset = nAgt.lastIndexOf(" ") + 1) < (verOffset = nAgt.lastIndexOf("/")) && (jQuery.browser.name = nAgt.substring(nameOffset, verOffset), jQuery.browser.fullVersion = nAgt.substring(verOffset + 1), jQuery.browser.name.toLowerCase() == jQuery.browser.name.toUpperCase() && (jQuery.browser.name = navigator.appName)); - 1 != (ix = jQuery.browser.fullVersion.indexOf(";")) && (jQuery.browser.fullVersion = jQuery.browser.fullVersion.substring(0, ix)), -1 != (ix = jQuery.browser.fullVersion.indexOf(" ")) && (jQuery.browser.fullVersion = jQuery.browser.fullVersion.substring(0, ix)), jQuery.browser.majorVersion = parseInt("" + jQuery.browser.fullVersion, 10), isNaN(jQuery.browser.majorVersion) && (jQuery.browser.fullVersion = "" + parseFloat(navigator.appVersion), jQuery.browser.majorVersion = parseInt(navigator.appVersion, 10)), jQuery.browser.version = jQuery.browser.majorVersion 13602 } 13603 jQuery.browser.android = /Android/i.test(nAgt), jQuery.browser.blackberry = /BlackBerry|BB|PlayBook/i.test(nAgt), jQuery.browser.ios = /iPhone|iPad|iPod|webOS/i.test(nAgt), jQuery.browser.operaMobile = /Opera Mini/i.test(nAgt), jQuery.browser.kindle = /Kindle|Silk/i.test(nAgt), jQuery.browser.windowsMobile = /IEMobile|Windows Phone/i.test(nAgt), jQuery.browser.mobile = jQuery.browser.android || jQuery.browser.blackberry || jQuery.browser.ios || jQuery.browser.windowsMobile || jQuery.browser.operaMobile || jQuery.browser.kindle, jQuery.fn.CSSAnimate = function (a, b, c, d, e) { 13604 function f(a) { 13605 return a.replace(/([A-Z])/g, function (a) { 13606 return "-" + a.toLowerCase() 13607 }) 13608 } 13609 13610 function g(a, b) { 13611 return "string" != typeof a || a.match(/^[\-0-9\.]+$/) ? "" + a + b : a 13612 } 13613 return jQuery.support.CSStransition = function () { 13614 var a = (document.body || document.documentElement).style; 13615 return void 0 !== a.transition || void 0 !== a.WebkitTransition || void 0 !== a.MozTransition || void 0 !== a.MsTransition || void 0 !== a.OTransition 13616 }(), this.each(function () { 13617 var h = this, 13618 i = jQuery(this); 13619 h.id = h.id || "CSSA_" + (new Date).getTime(); 13620 var j = j || { 13621 type: "noEvent" 13622 }; 13623 if (h.CSSAIsRunning && h.eventType == j.type) h.CSSqueue = function () { 13624 i.CSSAnimate(a, b, c, d, e) 13625 }; 13626 else if (h.CSSqueue = null, h.eventType = j.type, 0 !== i.length && a) { 13627 if (h.CSSAIsRunning = !0, "function" == typeof b && (e = b, b = jQuery.fx.speeds._default), "function" == typeof c && (e = c, c = 0), "function" == typeof d && (e = d, d = "cubic-bezier(0.65,0.03,0.36,0.72)"), "string" == typeof b) 13628 for (var k in jQuery.fx.speeds) { 13629 if (b == k) { 13630 b = jQuery.fx.speeds[k]; 13631 break 13632 } 13633 b = jQuery.fx.speeds._default 13634 } 13635 if (b || (b = jQuery.fx.speeds._default), jQuery.support.CSStransition) { 13636 j = { 13637 "default": "ease", 13638 "in": "ease-in", 13639 out: "ease-out", 13640 "in-out": "ease-in-out", 13641 snap: "cubic-bezier(0,1,.5,1)", 13642 easeOutCubic: "cubic-bezier(.215,.61,.355,1)", 13643 easeInOutCubic: "cubic-bezier(.645,.045,.355,1)", 13644 easeInCirc: "cubic-bezier(.6,.04,.98,.335)", 13645 easeOutCirc: "cubic-bezier(.075,.82,.165,1)", 13646 easeInOutCirc: "cubic-bezier(.785,.135,.15,.86)", 13647 easeInExpo: "cubic-bezier(.95,.05,.795,.035)", 13648 easeOutExpo: "cubic-bezier(.19,1,.22,1)", 13649 easeInOutExpo: "cubic-bezier(1,0,0,1)", 13650 easeInQuad: "cubic-bezier(.55,.085,.68,.53)", 13651 easeOutQuad: "cubic-bezier(.25,.46,.45,.94)", 13652 easeInOutQuad: "cubic-bezier(.455,.03,.515,.955)", 13653 easeInQuart: "cubic-bezier(.895,.03,.685,.22)", 13654 easeOutQuart: "cubic-bezier(.165,.84,.44,1)", 13655 easeInOutQuart: "cubic-bezier(.77,0,.175,1
13655)", 13656 easeInQuint: "cubic-bezier(.755,.05,.855,.06)", 13657 easeOutQuint: "cubic-bezier(.23,1,.32,1)", 13658 easeInOutQuint: "cubic-bezier(.86,0,.07,1)", 13659 easeInSine: "cubic-bezier(.47,0,.745,.715)", 13660 easeOutSine: "cubic-bezier(.39,.575,.565,1)", 13661 easeInOutSine: "cubic-bezier(.445,.05,.55,.95)", 13662 easeInBack: "cubic-bezier(.6,-.28,.735,.045)", 13663 easeOutBack: "cubic-bezier(.175, .885,.32,1.275)", 13664 easeInOutBack: "cubic-bezier(.68,-.55,.265,1.55)" 13665 }, j[d] && (d = j[d]); 13666 var l = "", 13667 m = "transitionEnd"; 13668 jQuery.browser.webkit ? (l = "-webkit-", m = "webkitTransitionEnd") : jQuery.browser.mozilla ? (l = "-moz-", m = "transitionend") : jQuery.browser.opera ? (l = "-o-", m = "otransitionend") : jQuery.browser.msie && (l = "-ms-", m = "msTransitionEnd"), j = []; 13669 for (n in a) k = n, "transform" === k && (k = l + "transform", a[k] = a[n], delete a[n]), "filter" === k && (k = l + "filter", a[k] = a[n], delete a[n]), ("transform-origin" === k || "origin" === k) && (k = l + "transform-origin", a[k] = a[n], delete a[n]), "x" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " translateX(" + g(a[n], "px") + ")", delete a[n]), "y" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " translateY(" + g(a[n], "px") + ")", delete a[n]), "z" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " translateZ(" + g(a[n], "px") + ")", delete a[n]), "rotate" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " rotate(" + g(a[n], "deg") + ")", delete a[n]), "rotateX" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " rotateX(" + g(a[n], "deg") + ")", delete a[n]), "rotateY" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " rotateY(" + g(a[n], "deg") + ")", delete a[n]), "rotateZ" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " rotateZ(" + g(a[n], "deg") + ")", delete a[n]), "scale" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " scale(" + g(a[n], "") + ")", delete a[n]), "scaleX" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " scaleX(" + g(a[n], "") + ")", delete a[n]), "scaleY" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " scaleY(" + g(a[n], "") + ")", delete a[n]), "scaleZ" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " scaleZ(" + g(a[n], "") + ")", delete a[n]), "skew" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " skew(" + g(a[n], "deg") + ")", delete a[n]), "skewX" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " skewX(" + g(a[n], "deg") + ")", delete a[n]), "skewY" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " skewY(" + g(a[n], "deg") + ")", delete a[n]), "perspective" === k && (k = l + "transform", a[k] = a[k] || "", a[k] += " perspective(" + g(a[n], "px") + ")", delete a[n]), 0 > j.indexOf(k) && j.push(f(k)); 13670 var n = j.join(","), 13671 o = function () { 13672 i.off(m + "." + h.id), clearTimeout(h.timeout), i.css(l + "transition", ""), "function" == typeof e && e(i), h.called = !0, h.CSSAIsRunning = !1, "function" == typeof h.CSSqueue && (h.CSSqueue(), h.CSSqueue = null) 13673 }, 13674 p = {}; 13675 jQuery.extend(p, a), p[l + "transition-property"] = n, p[l + "transition-duration"] = b + "ms", p[l + "transition-delay"] = c + "ms", p[l + "transition-style"] = "preserve-3d", p[l + "transition-timing-function"] = d, setTimeout(function () { 13676 i.one(m + "." + h.id, o), i.css(p) 13677 }, 1), h.timeout = setTimeout(function () { 13678 i.called || !e ? (i.called = !1, h.CSSAIsRunning = !1) : (i.css(l + "transition", ""), e(i), h.CSSAIsRunning = !1, "function" == typeof h.CSSqueue && (h.CSSqueue(), h.CSSqueue = null)) 13679 }, b + c + 100) 13680 } else { 13681 for (var n in a) "transform" === n && delete a[n], "filter" === n && delete a[n], "transform-origin" === n && delete a[n], "auto" === a[n] && delete a[n]; 13682 e && "string" != typeof e || (e = "linear"), i.animate(a, b, e) 13683 } 13684 } 13685 }) 13686 }; 13687 var getYTPVideoID = function (a) { 13688 var b, c; 13689 return a.indexOf("youtu.be") > 0 ? (b = a.substr(a.lastIndexOf("/") + 1, a.length), c = b.indexOf("?list=") > 0 ? b.substr(b.lastIndexOf("="), b.length) : null, b = c ? b.substr(0, b.lastIndexOf("?")) : b) : a.indexOf("http") > -1 ? (b = a.match(/[\\?&]v=([^&#]*)/)[1], c = a.indexOf("list=") > 0 ? a.match(/[\\?&]list=([^&#]*)/)[1] : null) : (b = a.length > 15 ? null : a, c = b ? null : a), { 13690 videoID: b, 13691 playlistID: c 13692 } 13693 }; 13694 jQuery.mbYTPlayer = { 13695 name: "jquery.mb.YTPlayer",
13696 version: "2.7.6", 13697 author: "Matteo Bicocchi", 13698 defaults: { 13699 containment: "body", 13700 ratio: "16/9", 13701 videoURL: null, 13702 playlistURL: null, 13703 startAt: 0, 13704 stopAt: 0, 13705 autoPlay: !0, 13706 vol: 100, 13707 addRaster: !1, 13708 opacity: 1, 13709 quality: "default", 13710 mute: !1, 13711 loop: !0, 13712 showControls: !0, 13713 showAnnotations: !1, 13714 showYTLogo: !0, 13715 stopMovieOnClick: !1, 13716 stopMovieOnBlur: !0, 13717 realfullscreen: !0, 13718 gaTrack: !0, 13719 onReady: function () { } 13720 }, 13721 controls: { 13722 play: "P", 13723 pause: "p", 13724 mute: "M", 13725 unmute: "A", 13726 onlyYT: "O", 13727 showSite: "R", 13728 ytLogo: "Y" 13729 }, 13730 locationProtocol: "https:", 13731 buildPlayer: function (options) { 13732 return this.each(function () { 13733 var YTPlayer = this, 13734 $YTPlayer = jQuery(YTPlayer); 13735 YTPlayer.loop = 0, YTPlayer.opt = {}, $YTPlayer.addClass("mb_YTPlayer"); 13736 var property = $YTPlayer.data("property") && "string" == typeof $YTPlayer.data("property") ? eval("(" + $YTPlayer.data("property") + ")") : $YTPlayer.data("property"); 13737 "undefined" != typeof property && "undefined" != typeof property.vol && (property.vol = 0 == property.vol ? property.vol = 1 : property.vol), jQuery.extend(YTPlayer.opt, jQuery.mbYTPlayer.defaults, options, property); 13738 var canGoFullscreen = !(jQuery.browser.msie || jQuery.browser.opera || self.location.href != top.location.href); 13739 canGoFullscreen || (YTPlayer.opt.realfullscreen = !1), $YTPlayer.attr("id") || $YTPlayer.attr("id", "video_" + (new Date).getTime()); 13740 var playerID = "mbYTP_" + YTPlayer.id; 13741 YTPlayer.isAlone = !1, YTPlayer.hasFocus = !0; 13742 var videoID = this.opt.videoURL ? getYTPVideoID(this.opt.videoURL).videoID : $YTPlayer.attr("href") ? getYTPVideoID($YTPlayer.attr("href")).videoID : !1, 13743 playlistID = this.opt.videoURL ? getYTPVideoID(this.opt.videoURL).playlistID : $YTPlayer.attr("href") ? getYTPVideoID($YTPlayer.attr("href")).playlistID : !1; 13744 YTPlayer.videoID = videoID, YTPlayer.playlistID = playlistID, YTPlayer.opt.showAnnotations = YTPlayer.opt.showAnnotations ? "0" : "3"; 13745 var playerVars = { 13746 autoplay: 0, 13747 modestbranding: 1, 13748 controls: 0, 13749 showinfo: 0, 13750 rel: 0, 13751 enablejsapi: 1, 13752 version: 3, 13753 playerapiid: playerID, 13754 origin: "*", 13755 allowfullscreen: !0, 13756 wmode: "transparent", 13757 iv_load_policy: YTPlayer.opt.showAnnotations 13758 }, 13759 canPlayHTML5 = !1, 13760 v = document.createElement("video"); 13761 v.canPlayType && (canPlayHTML5 = !0), canPlayHTML5 && jQuery.extend(playerVars, { 13762 html5: 1 13763 }), jQuery.browser.msie && jQuery.browser.version < 9 && (this.opt.opacity = 1); 13764 var playerBox = jQuery("<div/>").attr("id", playerID).addClass("playerBox"), 13765 overlay = jQuery("<div/>").css({ 13766 position: "absolute", 13767 top: 0, 13768 left: 0, 13769 width: "100%", 13770 height: "100%" 13771 }).addClass("YTPOverlay"); 13772 if (YTPlayer.isSelf = "self" == YTPlayer.opt.containment, YTPlayer.opt.containment = "self" == YTPlayer.opt.containment ? jQuery(this) : jQuery(YTPlayer.opt.containment), YTPlayer.isBackground = "body" == YTPlayer.opt.containment.get(0).tagName.toLowerCase(), !YTPlayer.isBackground || !ytp.backgroundIsInited) { 13773 var isPlayer = YTPlayer.opt.containment.is(jQuery(this)) && 0 == jQuery(this).children().length; 13774 if (isPlayer ? YTPlayer.isPlayer = !0 : $YTPlayer.hide(), jQuery.browser.mobile && YTPlayer.isBackgroun
13774d) return $YTPlayer.remove(), void 0; 13775 if (YTPlayer.opt.addRaster) { 13776 var classN = "dot" == YTPlayer.opt.addRaster ? "raster-dot" : "raster", 13777 retina = window.retina || window.devicePixelRatio > 1; 13778 overlay.addClass(retina ? classN + " retina" : classN) 13779 } else overlay.removeClass(function (a, b) { 13780 var c = b.split(" "), 13781 d = []; 13782 return jQuery.each(c, function (a, b) { 13783 /raster-.*/.test(b) && d.push(b) 13784 }), d.push("retina"), d.join(" ") 13785 }); 13786 var wrapper = jQuery("<div/>").addClass("mbYTP_wrapper").attr("id", "wrapper_" + playerID); 13787 if (wrapper.css({ 13788 position: "absolute", 13789 zIndex: 0, 13790 minWidth: "100%", 13791 minHeight: "100%", 13792 left: 0, 13793 top: 0, 13794 overflow: "hidden", 13795 opacity: 0 13796 }), playerBox.css({ 13797 position: "absolute", 13798 zIndex: 0, 13799 width: "100%", 13800 height: "100%", 13801 top: 0, 13802 left: 0, 13803 overflow: "hidden" 13804 }), wrapper.append(playerBox), YTPlayer.opt.containment.children().not("script, style").each(function () { 13805 "static" == jQuery(this).css("position") && jQuery(this).css("position", "relative") 13806 }), YTPlayer.isBackground ? (jQuery("body").css({ 13807 position: "absolute", 13808 minWidth: "100%", 13809 minHeight: "100%", 13810 zIndex: 1, 13811 boxSizing: "border-box" 13812 }), wrapper.css({ 13813 position: "fixed", 13814 top: 0, 13815 left: 0, 13816 zIndex: 0, 13817 webkitTransform: "translateZ(0)" 13818 }), $YTPlayer.hide()) : "static" == YTPlayer.opt.containment.css("position") && YTPlayer.opt.containment.css({ 13819 position: "relative" 13820 }), YTPlayer.opt.containment.prepend(wrapper), YTPlayer.wrapper = wrapper, playerBox.css({ 13821 opacity: 1 13822 }), jQuery.browser.mobile || (playerBox.after(overlay), YTPlayer.overlay = overlay), YTPlayer.isBackground || overlay.on("mouseenter", function () { 13823 $YTPlayer.find(".mb_YTPBar").addClass("visible") 13824 }).on("mouseleave", function () { 13825 $YTPlayer.find(".mb_YTPBar").removeClass("visible") 13826 }), ytp.YTAPIReady) setTimeout(function () { 13827 jQuery(document).trigger("YTAPIReady") 13828 }, 100); 13829 else { 13830 jQuery("#YTAPI").remove(); 13831 var tag = jQuery("<script></script>").attr({ 13832 src: jQuery.mbYTPlayer.locationProtocol + "//www.youtube.com/player_api?v=" + jQuery.mbYTPlayer.version, 13833 id: "YTAPI" 13834 }); 13835 jQuery("head title").after(tag) 13836 } 13837 jQuery(document).on("YTAPIReady", function () { 13838 YTPlayer.isBackground && ytp.backgroundIsInited || YTPlayer.isInit || (YTPlayer.isBackground && YTPlayer.opt.stopMovieOnClick && jQuery(document).off("mousedown.ytplayer").on("mousedown,.ytplayer", function (a) { 13839 var b = jQuery(a.target); 13840 (b.is("a") || b.parents().is("a")) && $YTPlayer.pauseYTP() 13841 }), YTPlayer.isBackground && (ytp.backgroundIsInited = !0), YTPlayer.opt.autoPlay = "undefined" == typeof YTPlayer.opt.autoPlay ? YTPlayer.isBackgroun
13841d ? !0 : !1 : YTPlayer.opt.autoPlay, YTPlayer.opt.vol = YTPlayer.opt.vol ? YTPlayer.opt.vol : 100, jQuery.mbYTPlayer.getDataFromFeed(YTPlayer), jQuery(YTPlayer).on("YTPChanged", function () { 13842 return YTPlayer.isInit ? void 0 : (YTPlayer.isInit = !0, jQuery.browser.mobile && YTPlayer.isPlayer ? (new YT.Player(playerID, { 13843 videoId: YTPlayer.videoID.toString(), 13844 height: "100%", 13845 width: "100%", 13846 videoId: YTPlayer.videoID, 13847 events: { 13848 onReady: function (a) { 13849 YTPlayer.player = a.target, playerBox.css({ 13850 opacity: 1 13851 }), YTPlayer.wrapper.css({ 13852 opacity: YTPlayer.opt.opacity 13853 }), $YTPlayer.optimizeDisplay() 13854 }, 13855 onStateChange: function () { } 13856 } 13857 }), void 0) : (new YT.Player(playerID, { 13858 videoId: YTPlayer.videoID.toString(), 13859 playerVars: playerVars, 13860 events: { 13861 onReady: function (a) { 13862 if (YTPlayer.player = a.target, !YTPlayer.isReady) { 13863 YTPlayer.isReady = !0, YTPlayer.playerEl = YTPlayer.player.getIframe(), $YTPlayer.optimizeDisplay(), YTPlayer.videoID = videoID, jQuery(window).on("resize.YTP", function () { 13864 $YTPlayer.optimizeDisplay() 13865 }), YTPlayer.opt.showControls && jQuery(YTPlayer).buildYTPControls(); 13866 var b = YTPlayer.opt.startAt ? YTPlayer.opt.startAt : 1; 13867 YTPlayer.player.setVolume(0), jQuery(YTPlayer).muteYTPVolume(), jQuery.mbYTPlayer.checkForState(YTPlayer), YTPlayer.checkForStartAt = setInterval(function () { 13868 var a = YTPlayer.player.getVideoLoadedFraction() > b / YTPlayer.player.getDuration(); 13869 YTPlayer.player.getDuration() > 0 && YTPlayer.player.getCurrentTime() >= b && a ? (clearInterval(YTPlayer.checkForStartAt), YTPlayer.player.setVolume(0), jQuery(YTPlayer).muteYTPVolume(), "function" == typeof YTPlayer.opt.onReady && YTPlayer.opt.onReady(YTPlayer), YTPlayer.opt.mute || jQuery(YTPlayer).unmuteYTP(), jQuery.mbYTPlayer.checkForState(YTPlayer), YTPlayer.player.pauseVideo(), setTimeout(function () { 13870 YTPlayer.canTrigger = !0, YTPlayer.opt.autoPlay ? ($YTPlayer.playYTP(), $YTPlayer.css("background-image", "none"), YTPlayer.wrapper.CSSAnimate({ 13871 opacity: YTPlayer.isAlone ? 1 : YTPlayer.opt.opacity 13872 }, 2e3)) : YTPlayer.player.pauseVideo() 13873 }, 100)) : (YTPlayer.player.playVideo(), YTPlayer.player.seekTo(b, !0)) 13874 }, jQuery.browser.chrome ? 1e3 : 1) 13875 } 13876 }, 13877 onStateChange: function (event) { 13878 if ("function" == typeof event.target.getPlayerState) { 13879 var state = event.target.getPlayerState(); 13880 if (YTPlayer.state != state) { 13881 YTPlayer.state = state; 13882 var controls = jQuery("#controlBar_" + YTPlayer.id), 13883 data = YTPlayer.opt, 13884 eventType; 13885 switch (state) { 13886 case -1: 13887 eventType = "YTPUnstarted"; 13888 break; 13889 case 0: 13890 eventType = "YTPEnd", YTPlayer.player.pauseVideo(); 13891 var startAt = YTPlayer.opt.startAt ? YTPlayer.opt.startAt : 1; 13892 data.loop ? (YTPlayer.wrapper.css({ 13893 opacity: 0 13894 }), $YTPlayer.playYTP(), YTPlayer.player.seekTo(startAt, !0)) : YTPlayer.isBackgroun
13894d || (YTPlayer.player.seekTo(startAt, !0), $YTPlayer.playYTP(), setTimeout(function () { 13895 $YTPlayer.pauseYTP() 13896 }, 10)), !data.loop && YTPlayer.isBackground ? YTPlayer.wrapper.CSSAnimate({ 13897 opacity: 0 13898 }, 2e3) : data.loop && YTPlayer.loop++ , controls.find(".mb_YTPPlaypause").html(jQuery.mbYTPlayer.controls.play); 13899 break; 13900 case 1: 13901 eventType = "YTPStart", jQuery.browser.chrome || YTPlayer.player.setPlaybackQuality(YTPlayer.opt.quality), controls.find(".mb_YTPPlaypause").html(jQuery.mbYTPlayer.controls.pause), "undefined" != typeof _gaq && eval(YTPlayer.opt.gaTrack) && _gaq.push(["_trackEvent", "YTPlayer", "Play", YTPlayer.videoTitle || YTPlayer.videoID.toString()]), "undefined" != typeof ga && eval(YTPlayer.opt.gaTrack) && ga("send", "event", "YTPlayer", "play", YTPlayer.videoTitle || YTPlayer.videoID.toString()); 13902 break; 13903 case 2: 13904 eventType = "YTPPause", controls.find(".mb_YTPPlaypause").html(jQuery.mbYTPlayer.controls.play); 13905 break; 13906 case 3: 13907 eventType = "YTPBuffering", jQuery.browser.chrome || YTPlayer.player.setPlaybackQuality(YTPlayer.opt.quality), controls.find(".mb_YTPPlaypause").html(jQuery.mbYTPlayer.controls.play); 13908 break; 13909 case 5: 13910 eventType = "YTPCued" 13911 } 13912 var YTPevent = jQuery.Event(eventType); 13913 YTPevent.time = YTPlayer.player.time, YTPlayer.canTrigger && jQuery(YTPlayer).trigger(YTPevent) 13914 } 13915 } 13916 }, 13917 onPlaybackQualityChange: function (a) { 13918 var b = a.target.getPlaybackQuality(), 13919 c = jQuery.Event("YTPQualityChange"); 13920 c.quality = b, jQuery(YTPlayer).trigger(c) 13921 }, 13922 onError: function (a) { 13923 150 == a.data && (console.log("Embedding this video is restricted by Youtube."), YTPlayer.isPlayList && jQuery(YTPlayer).playNext()), 2 == a.data && YTPlayer.isPlayList && jQuery(YTPlayer).playNext(), "function" == typeof YTPlayer.opt.onError && YTPlayer.opt.onError($YTPlayer, a) 13924 } 13925 } 13926 }), void 0)) 13927 })) 13928 }) 13929 } 13930 }) 13931 }, 13932 getDataFromFeed: function (a) { 13933 jQuery.browser.msie && jQuery.browser.version <= 9 ? ("auto" == a.opt.ratio ? a.opt.ratio = "16/9" : a.opt.ratio, a.hasData || (a.hasData = !0, setTimeout(function () { 13934 jQuery(a).trigger("YTPChanged") 13935 }, 100))) : (jQuery.getJSON(jQuery.mbYTPlayer.locationProtocol + "//gdata.youtube.com/feeds/api/videos/" + a.videoID + "?v=2&alt=jsonc", function (b) { 13936 a.dataReceived = !0, a.videoData = b.data, jQuery(a).trigger("YTPChanged"); 13937 var e = jQuery.Event("YTPData"); 13938 e.prop = {}; 13939 for (var f in a.videoData) e.prop[f] = a.videoData[f]; 13940 if (jQuery(a).trigger(e), a.videoTitle = a.videoData.title, "auto" == a.opt.ratio && (a.opt.ratio = a.videoData.aspectRatio && "widescreen" === a.videoData.aspectRatio ? "16/9" : "4/3"), !a.hasData && (a.hasData = !0, a.isPlayer)) { 13941 var g = a.videoData.thumbnail.hqDefault; 13942 a.opt.containment.css({ 13943 background: "rgba(0,0,0,0.5) url(" + g + ") center center", 13944 backgroundSize: "cover" 13945 }) 13946 } 13947 }), setTimeout(function () { 13948 a.dataReceived || a.hasData || (a.hasData = !0, jQuery(a).trigger("YTPChanged")) 13949 }, 1500)) 13950 }, 13951 getVideoData: function () { 13952 var a = this.get(0); 13953 return a.videoData 13954 }, 13955 getVideoID: function () { 13956 var a = this.get(0); 13957 return a.videoID || !1 13958 }, 13959 setVideoQuality: function (a) { 13960 var b = this.get(0); 13961 jQuery.browser.chrome || b.player.setPlaybackQuality(a) 13962 }, 13963 YTPlaylist: function (a, b, c) { 13964 var d = this.get(0); 13965 d.isPlayList = !0, b && (a = jQuery.shuffle(a)), d.videoID || (d.videos = a, d.videoCounter = 0, d.videoLength = a.length, jQuery(d).data("property", a[0]), jQuery(d).mb_YTPlayer()), "function" == typeof c && jQuery(d).on("YTPChanged", function () { 13966 c(d) 13967 }), jQuery(d).on("YTPEnd", function () { 13968 jQuery(d).playNext() 13969 }) 13970 }, 13971 playNext: function () { 13972 var a = this.get(0); 13973 a.videoCounter++ , a.videoCounter >= a.videoLength && (a.videoCounter = 0), jQuery(a.playerEl).css({ 13974 opacity: 0 13975 }), jQuery(a).changeMovie(a.videos[a.videoCounter]) 13976 }, 13977 playPrev: function () { 13978 var a = this.get(0); 13979 a.videoCounter-- , a.videoCounter < 0 && (a.videoCounter = a.videoLength - 1), jQuery(a.playerEl).css({ 13980 opacity: 0 13981 }), jQuery(a).changeMovie(a.videos[a.videoCounter]) 13982 }, 13983 changeMovie: function (a) { 13984 var b = this.get(0); 13985 b.opt.startAt = 0, b.opt.stopAt = 0, b.opt.mute = !0, a && jQuery.extend(b.o
13985pt, a), b.videoID = getYTPVideoID(b.opt.videoURL).videoID, jQuery(b).pauseYTP(); 13986 var c = jQuery.browser.msie ? 1e3 : 0; 13987 if (jQuery(b.playerEl).CSSAnimate({ 13988 opacity: 0 13989 }, c), setTimeout(function () { 13990 var a = jQuery.browser.chrome ? "default" : b.opt.quality; 13991 jQuery(b).getPlayer().cueVideoByUrl(encodeURI(jQuery.mbYTPlayer.locationProtocol + "//www.youtube.com/v/" + b.videoID), 1, a), jQuery(b).playYTP(), jQuery(b).one("YTPStart", function () { 13992 b.wrapper.CSSAnimate({ 13993 opacity: b.isAlone ? 1 : b.opt.opacity 13994 }, 1e3), jQuery(b.playerEl).CSSAnimate({ 13995 opacity: 1 13996 }, c), b.opt.startAt && b.player.seekTo(b.opt.startAt), jQuery.mbYTPlayer.checkForState(b), b.opt.autoPlay || jQuery(b).pauseYTP() 13997 }), b.opt.mute ? jQuery(b).muteYTPVolume() : jQuery(b).unmuteYTP() 13998 }, c), b.opt.addRaster) { 13999 var d = window.retina || window.devicePixelRatio > 1; 14000 b.overlay.addClass(d ? "raster retina" : "raster") 14001 } else b.overlay.removeClass("raster"), b.overlay.removeClass("retina"); 14002 jQuery("#controlBar_" + b.id).remove(), b.opt.showControls && jQuery(b).buildYTPControls(), jQuery.mbYTPlayer.getDataFromFeed(b), jQuery(b).optimizeDisplay() 14003 }, 14004 getPlayer: function () { 14005 return jQuery(this).get(0).player 14006 }, 14007 playerDestroy: function () { 14008 var a = this.get(0); 14009 ytp.YTAPIReady = !1, ytp.backgroundIsInited = !1, a.isInit = !1, a.videoID = null; 14010 var b = a.wrapper; 14011 b.remove(), jQuery("#controlBar_" + a.id).remove() 14012 }, 14013 fullscreen: function (real) { 14014 function RunPrefixMethod(a, b) { 14015 for (var e, f, c = ["webkit", "moz", "ms", "o", ""], d = 0; d < c.length && !a[e];) { 14016 if (e = b, "" == c[d] && (e = e.substr(0, 1).toLowerCase() + e.substr(1)), e = c[d] + e, f = typeof a[e], "undefined" != f) return c = [c[d]], "function" == f ? a[e]() : a[e]; 14017 d++ 14018 } 14019 } 14020 14021 function launchFullscreen(a) { 14022 RunPrefixMethod(a, "RequestFullScreen") 14023 } 14024 14025 function cancelFullscreen() { 14026 (RunPrefixMethod(document, "FullScreen") || RunPrefixMethod(document, "IsFullScreen")) && RunPrefixMethod(document, "CancelFullScreen") 14027 } 14028 var YTPlayer = this.get(0); 14029 "undefined" == typeof real && (real = YTPlayer.opt.realfullscreen), real = eval(real); 14030 var controls = jQuery("#controlBar_" + YTPlayer.id), 14031 fullScreenBtn = controls.find(".mb_OnlyYT"), 14032 videoWrapper = YTPlayer.isSelf ? YTPlayer.opt.containment : YTPlayer.wrapper; 14033 if (real) { 14034 var fullscreenchange = jQuery.browser.mozilla ? "mozfullscreenchange" : jQuery.browser.webkit ? "webkitfullscreenchange" : "fullscreenchange"; 14035 jQuery(document).off(fullscreenchange).on(fullscreenchange, function () { 14036 var a = RunPrefixMethod(document, "IsFullScreen") || RunPrefixMethod(document, "FullScreen"); 14037 a ? (jQuery(YTPlayer).setVideoQuality("default"), jQuery(YTPlayer).trigger("YTPFullScreenStart")) : (YTPlayer.isAlone = !1, fullScreenBtn.html(jQuery.mbYTPlayer.controls.onlyYT), jQuery(YTPlayer).setVideoQuality(YTPlayer.opt.quality), videoWrapper.removeClass("fullscreen"), videoWrapper.CSSAnimate({ 14038 opacity: YTPlayer.opt.opacity 14039 }, 500), videoWrapper.css({ 14040 zIndex: 0 14041 }), YTPlayer.isBackground ? jQuery("body").after(controls) : YTPlayer.wrapper.before(controls), jQuery(window).resize(), jQuery(YTPlayer).trigger("YTPFullScreenEnd")) 14042 }) 14043 } 14044 YTPlayer.isAlone ? (real ? cancelFullscreen() : (videoWrapper.CSSAnimate({ 14045 opacity: YTPlayer.opt.opacity 14046 }, 500), videoWrapper.css({ 14047 zIndex: 0 14048 })), fullScreenBtn.html(jQuery.mbYTPlayer.controls.onlyYT), YTPlayer.isAlone = !1) : (real ? (videoWrapper.css({ 14049 opacity: 0 14050 }), videoWrapper.addClass("fullscreen"), launchFullscreen(videoWrapper.get(0)), setTimeout(function () { 14051 videoWrapper.CSSAnimate({ 14052 opacity: 1 14053 }, 1e3), YTPlayer.wrapper.append(controls), jQuery(YTPlayer).optimizeDisplay(), YTPlayer.player.seekTo(YTPlayer.player.getCurrentTime() + .1, !0) 14054 }, 500)) : videoWrapper.css({ 14055 zIndex: 1e4 14056 }).CSSAnimate({ 14057 opacity: 1 14058 }, 1e3), fullScreenBtn.html(jQuery.mbYTPlayer.controls.showSite), YTPlayer.isAlone = !0) 14059 }, 14060 playYTP: function () { 14061 var a = this.get(0); 14062 if ("undefined" != typeof a.player) { 14063 var b = jQuery("#controlBar_" + a.id), 14064 c = b.find(".mb_YTPPlaypause"); 14065 c.html(jQuery.mbYTPlayer.controls.pause), a.player.playVideo(), a.wrapper.CSSAnimate({ 14066 opacity: a.isAlone ? 1 : a.opt.opacity 14067 }, 2e3), jQuery(a).on("YTPStart", function () { 14068 jQuery(a).css("background-image", "none") 14069 }) 14070 } 14071 }, 14072 toggleLoops: function () { 14073 var a = this.get(0), 14074 b = a.opt; 14075 1 == b.loop ? b.loop = 0 : (b.startAt ? a.player.seekTo(b.startAt) : a.player.playVideo(), b.loop = 1) 14076 }, 14077 stopYTP: function () { 14078 var a = this.get(0), 14079 b = jQuery("#controlBar_" + a.id), 14080 c = b.find(".mb_YTPPlaypause"); 14081 c.html(jQuery.mbYTPlayer.controls.play), a.player.stopVideo() 14082 }, 14083 pauseYTP: function () { 14084 var a = this.get(0); 14085 a.opt; 14086 var c = jQuery("#controlBar_" + a.id), 14087 d = c.find(".mb_YTPPlaypause"); 14088 d.html(jQuery.mbYTPlayer.controls.play), a.player.pauseVideo() 14089 }, 14090 seekToYTP: function (a) { 14091 var b = this.get(0); 14092 b.player.seekTo(a, !0) 14093 }, 14094 setYTPVolume: function (a) { 14095 var b = this.get(0); 14096 a || b.opt.vol || 0 != b.player.getVolume() ? !a && b.player.getVolume() > 0 || a && b.player.getVolume() == a ? jQuery(b).muteYTPVolume() : b.opt.vol = a : jQuery(b).unmuteYTP(), b.player.setVolume(b.opt.vol) 14097 }, 14098 muteYTP: function () { 14099 var a = this.get(0); 14100 a.player.mute(), a.player.setVolume(0); 14101 var b = jQuery("#controlBar_" + a.id), 14102 c = b.find(".mb_YTPMuteUnmute"); 14103 c.html(jQuery.mbYTPlayer.controls.unmute), jQuery(a).addClass("isMuted"), jQuery(a).trigger("YTPMuted") 14104 }, 14105 unmuteYTP: function () { 14106 var a = this.get(0); 14107 a.player.unMute(), a.player.setVolume(a.opt.vol); 14108 var b = jQuery("#controlBar_" + a.id), 14109 c = b.find(".mb_YTPMuteUnmute"); 14110 c.html(jQuery.mbYTPlayer.controls.mute), jQuery(a).removeClass("isMuted"), jQuery(a).trigger("YTPUnmuted") 14111 }, 14112 manageYTPProgress: function () { 14113 var a = this.get(0), 14114 b = jQuery("#controlBar_" + a.id), 14115 c = b.find(".mb_YTPProgress"),
14116 d = b.find(".mb_YTPLoaded"), 14117 e = b.find(".mb_YTPseekbar"), 14118 f = c.outerWidth(), 14119 g = Math.floor(a.player.getCurrentTime()), 14120 h = Math.floor(a.player.getDuration()), 14121 i = g * f / h, 14122 j = 0, 14123 k = 100 * a.player.getVideoLoadedFraction(); 14124 return d.css({ 14125 left: j, 14126 width: k + "%" 14127 }), e.css({ 14128 left: 0, 14129 width: i 14130 }), { 14131 totalTime: h, 14132 currentTime: g 14133 } 14134 }, 14135 buildYTPControls: function () { 14136 var YTPlayer = this.get(0), 14137 data = YTPlayer.opt; 14138 if (data.showYTLogo = data.showYTLogo || data.printUrl, !jQuery("#controlBar_" + YTPlayer.id).length) { 14139 var controlBar = jQuery("<span/>").attr("id", "controlBar_" + YTPlayer.id).addClass("mb_YTPBar").css({ 14140 whiteSpace: "noWrap", 14141 position: YTPlayer.isBackground ? "fixed" : "absolute", 14142 zIndex: YTPlayer.isBackground ? 1e4 : 1e3 14143 }).hide(), 14144 buttonBar = jQuery("<div/>").addClass("buttonBar"), 14145 playpause = jQuery("<span>" + jQuery.mbYTPlayer.controls.play + "</span>").addClass("mb_YTPPlaypause ytpicon").click(function () { 14146 1 == YTPlayer.player.getPlayerState() ? jQuery(YTPlayer).pauseYTP() : jQuery(YTPlayer).playYTP() 14147 }), 14148 MuteUnmute = jQuery("<span>" + jQuery.mbYTPlayer.controls.mute + "</span>").addClass("mb_YTPMuteUnmute ytpicon").click(function () { 14149 0 == YTPlayer.player.getVolume() ? jQuery(YTPlayer).unmuteYTP() : jQuery(YTPlayer).muteYTP() 14150 }), 14151 idx = jQuery("<span/>").addClass("mb_YTPTime"), 14152 vURL = data.videoURL ? data.videoURL : ""; 14153 vURL.indexOf("http") < 0 && (vURL = jQuery.mbYTPlayer.locationProtocol + "//www.youtube.com/watch?v=" + data.videoURL); 14154 var movieUrl = jQuery("<span/>").html(jQuery.mbYTPlayer.controls.ytLogo).addClass("mb_YTPUrl ytpicon").attr("title", "view on YouTube").on("click", function () { 14155 window.open(vURL, "viewOnYT") 14156 }), 14157 onlyVideo = jQuery("<span/>").html(jQuery.mbYTPlayer.controls.onlyYT).addClass("mb_OnlyYT ytpicon").on("click", function () { 14158 jQuery(YTPlayer).fullscreen(data.realfullscreen) 14159 }), 14160 progressBar = jQuery("<div/>").addClass("mb_YTPProgress").css("position", "absolute").click(function (a) { 14161 timeBar.css({ 14162 width: a.clientX - timeBar.offset().left 14163 }), YTPlayer.timeW = a.clientX - timeBar.offset().left, controlBar.find(".mb_YTPLoaded").css({ 14164 width: 0 14165 }); 14166 var b = Math.floor(YTPlayer.player.getDuration()); 14167 YTPlayer.goto = timeBar.outerWidth() * b / progressBar.outerWidth(), YTPlayer.player.seekTo(parseFloat(YTPlayer.goto), !0), controlBar.find(".mb_YTPLoaded").css({ 14168 width: 0 14169 }) 14170 }), 14171 loadedBar = jQuery("<div/>").addClass("mb_YTPLoaded").css("position", "absolute"), 14172 timeBar = jQuery("<div/>").addClass("mb_YTPseekbar").css("position", "absolute"); 14173 progressBar.append(loadedBar).append(timeBar), buttonBar.append(playpause).append(MuteUnmute).append(idx), data.showYTLogo && buttonBar.append(movieUrl), (YTPlayer.isBackground || eval(YTPlayer.opt.realfullscreen) && !YTPlayer.isBackground) && buttonBar.append(onlyVideo), controlBar.append(buttonBar).append(progressBar), YTPlayer.isBackground ? jQuery("body").after(controlBar) : (controlBar.addClass("inlinePlayer"), YTPlayer.wrapper.before(controlBar)), controlBar.fadeIn() 14174 } 14175 }, 14176 checkForState: function (a) { 14177 var b = a.opt.showControls ? 10 : 1e3; 14178 clearInterval(a.getState), a.getState = setInterval(function () { 14179 var b = jQuery(a).manageYTPProgress(), 14180 c = jQuery(a), 14181 d = jQuery("#controlBar_" + a.id), 14182 e = a.opt, 14183 f = a.opt.startAt ? a.opt.startAt : 1, 14184 g = a.opt.stopAt > a.opt.startAt ? a.opt.stopAt : 0; 14185 if (g = g < a.player.getDuration() ? g : 0, a.player.time != b.currentTime) { 14186 var h = jQuery.Event("YTPTime"); 14187 h.time = a.player.time, jQuery(a).trigger(h) 14188 } 14189 if (a.player.time = b.currentTime, 0 == a.player.getVolume() ? c.addClass("isMuted") : c.removeClass("isMuted"), a.opt.showControls && (b.totalTime ? d.find(".mb_YTPTime").html(jQuery.mbYTPlayer.formatTime(b.currentTime) + " / " + jQuery.mbYTPlayer.formatTime(b.totalTime)) : d.find(".mb_YTPTime").html("-- : -- / -- : --")), a.opt.stopMovieOnBlur && (document.hasFocus() ? document.hasFocus() && !a.hasFocus && (a.hasFocus = !0, c.playYTP()) : 1 == a.state && (a.hasFocus = !1, c.pauseYTP())), 1 == a.player.getPlayerState() && (parseFloat(a.player.getDuration() - 3) < a.player.getCurrentTime() || g > 0 && parseFloat(a.player.getCurrentTime()) > g)) { 14190 if (a.isEnded) return; 14191 if (a.isEnded = !0, setTimeout(function () { 14192 a.isEnded = !1 14193 }, 2e3), a.isPlayList) { 14194 clearInterval(a.getState); 14195 var i = jQuery.Event("YTPEnd"); 14196 return i.time = a.player.time, jQuery(a).trigger(i), void 0 14197 } 14198 e.loop ? a.player.seekTo(f, !0) : (a.player.pauseVideo(), a.wrapper.CSSAnimate({ 14199 opacity: 0 14200 }, 1e3, function () { 14201 var b = jQuery.Event("YTPEnd"); 14202 if (b.time = a.player.time, jQuery(a).trigger(b), a.player.seekTo(f, !0), !a.isBackgroun
14202d) { 14203 var c = a.videoData.thumbnail.hqDefault; 14204 jQuery(a).css({ 14205 background: "rgba(0,0,0,0.5) url(" + c + ") center center", 14206 backgroundSize: "cover" 14207 }) 14208 } 14209 })) 14210 } 14211 }, b) 14212 }, 14213 formatTime: function (a) { 14214 var b = Math.floor(a / 60), 14215 c = Math.floor(a - 60 * b); 14216 return (9 >= b ? "0" + b : b) + " : " + (9 >= c ? "0" + c : c) 14217 } 14218 }, jQuery.fn.toggleVolume = function () { 14219 var a = this.get(0); 14220 if (a) return a.player.isMuted() ? (jQuery(a).unmuteYTP(), !0) : (jQuery(a).muteYTP(), !1) 14221 }, jQuery.fn.optimizeDisplay = function () { 14222 var a = this.get(0), 14223 b = a.opt, 14224 c = jQuery(a.playerEl), 14225 d = {}, 14226 e = a.wrapper; 14227 d.width = e.outerWidth(), d.height = e.outerHeight(); 14228 var f = 24, 14229 g = 100, 14230 h = {}; 14231 h.width = d.width + d.width * f / 100, h.height = "16/9" == b.ratio ? Math.ceil(9 * d.width / 16) : Math.ceil(3 * d.width / 4), h.marginTop = -((h.height - d.height) / 2), h.marginLeft = -(d.width * (f / 2) / 100), h.height < d.height && (h.height = d.height + d.height * f / 100, h.width = "16/9" == b.ratio ? Math.floor(16 * d.height / 9) : Math.floor(4 * d.height / 3), h.marginTop = -(d.height * (f / 2) / 100), h.marginLeft = -((h.width - d.width) / 2)), h.width += g, h.height += g, h.marginTop -= g / 2, h.marginLeft -= g / 2, c.css({ 14232 width: h.width, 14233 height: h.height, 14234 marginTop: h.marginTop, 14235 marginLeft: h.marginLeft 14236 }) 14237 }, jQuery.shuffle = function (a) { 14238 for (var b = a.slice(), c = b.length, d = c; d--;) { 14239 var e = parseInt(Math.random() * c), 14240 f = b[d]; 14241 b[d] = b[e], b[e] = f 14242 } 14243 return b 14244 }, jQuery.fn.YTPlayer = jQuery.mbYTPlayer.buildPlayer, jQuery.fn.YTPlaylist = jQuery.mbYTPlayer.YTPlaylist, jQuery.fn.playNext = jQuery.mbYTPlayer.playNext, jQuery.fn.playPrev = jQuery.mbYTPlayer.playPrev, jQuery.fn.changeMovie = jQuery.mbYTPlayer.changeMovie, jQuery.fn.getVideoID = jQuery.mbYTPlayer.getVideoID, jQuery.fn.getPlayer = jQuery.mbYTPlayer.getPlayer, jQuery.fn.playerDestroy = jQuery.mbYTPlayer.playerDestroy, jQuery.fn.fullscreen = jQuery.mbYTPlayer.fullscreen, jQuery.fn.buildYTPControls = jQuery.mbYTPlayer.buildYTPControls, jQuery.fn.playYTP = jQuery.mbYTPlayer.playYTP, jQuery.fn.toggleLoops = jQuery.mbYTPlayer.toggleLoops, jQuery.fn.stopYTP = jQuery.mbYTPlayer.stopYTP, jQuery.fn.pauseYTP = jQuery.mbYTPlayer.pauseYTP, jQuery.fn.seekToYTP = jQuery.mbYTPlayer.seekToYTP, jQuery.fn.muteYTP = jQuery.mbYTPlayer.muteYTP, jQuery.fn.unmuteYTP = jQuery.mbYTPlayer.unmuteYTP, jQuery.fn.setYTPVolume = jQuery.mbYTPlayer.setYTPVolume, jQuery.fn.setVideoQuality = jQuery.mbYTPlayer.setVideoQuality, jQuery.fn.manageYTPProgress = jQuery.mbYTPlayer.manageYTPProgress, jQuery.fn.getDataFromFeed = jQuery.mbYTPlayer.getVideoData, jQuery.fn.mb_YTPlayer = jQuery.fn.YTPlayer, jQuery.fn.muteYTPVolume = jQuery.mbYTPlayer.muteYTP, jQuery.fn.unmuteYTPVolume = jQuery.mbYTPlayer.unmuteYTP 14245}(jQuery, ytp); 14246 14247 14248 14249/* 14250 * Infinite Scroll 14251 * ----------------------------------------------- 14252 */ 14253 14254/*! 14255 -------------------------------- 14256 Infinite Scroll 14257 -------------------------------- 14258 + https://github.com/paulirish/infinite-scroll 14259 + version 2.1.0 14260 + Copyright 2011/12 Paul Irish & Luke Shumard 14261 + Licensed under the MIT license 14262 14263 + Documentation: http://infinite-scroll.com/ 14264*/ 14265; 14266(function (e) { 14267 if (typeof define === "function" && define.amd) { 14268 define(["jquery"], e) 14269 } else { 14270 e(jQuery) 14271 } 14272})(function (e, t) { 14273 "use strict"; 14274 e.infinitescroll = function (n, r, i) { 14275 this.element = e(i); 14276 if (!this._create(n, r)) { 14277 this.failed = true 14278 } 14279 }; 14280 e.infinitescroll.defaults = { 14281 loading: { 14282 finished: t, 14283 finishedMsg: "<em>Congratulations, you've reached the end of the internet.</em>", 14284 img: "data:image/gif;
14284base64,R0lGODlh3AATAPQeAPDy+MnQ6LW/4N3h8MzT6rjC4sTM5r/I5NHX7N7j8c7U6tvg8OLl8uXo9Ojr9b3G5MfP6Ovu9tPZ7PT1+vX2+tbb7vf4+8/W69jd7rC73vn5/O/x+K243ai02////wAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQECgD/ACwAAAAA3AATAAAF/6AnjmRpnmiqrmzrvnAsz3Rt33iu73zv/8CgcEj0BAScpHLJbDqf0Kh0Sq1ar9isdioItAKGw+MAKYMFhbF63CW438f0mg1R2O8EuXj/aOPtaHx7fn96goR4hmuId4qDdX95c4+RBIGCB4yAjpmQhZN0YGYGXitdZBIVGAsLoq4BBKQDswm1CQRkcG6ytrYKubq8vbfAcMK9v7q7EMO1ycrHvsW6zcTKsczNz8HZw9vG3cjTsMIYqQkCLBwHCgsMDQ4RDAYIqfYSFxDxEfz88/X38Onr16+Bp4ADCco7eC8hQYMAEe57yNCew4IVBU7EGNDiRn8Z831cGLHhSIgdFf9chIeBg7oA7gjaWUWTVQAGE3LqBDCTlc9WOHfm7PkTqNCh54rePDqB6M+lR536hCpUqs2gVZM+xbrTqtGoWqdy1emValeXKzggYBBB5y1acFNZmEvXAoN2cGfJrTv3bl69Ffj2xZt3L1+/fw3XRVw4sGDGcR0fJhxZsF3KtBTThZxZ8mLMgC3fRatCbYMNFCzwLEqLgE4NsDWs/tvqdezZf13Hvk2A9Szdu2X3pg18N+68xXn7rh1c+PLksI/Dhe6cuO3ow3NfV92bdArTqC2Ebd3A8vjf5QWfH6Bg7Nz17c2fj69+fnq+8N2Lty+fuP78/eV2X13neIcCeBRwxorbZrA1ANoCDGrgoG8RTshahQ9iSKEEzUmYIYfNWViUhheCGJyIP5E4oom7WWjgCeBFAJNv1DVV01MAdJhhjdkplWNzO/5oXI846njjVEIqR2OS2B1pE5PVscajkxhMycqLJghQSwT40PgfAl4GqNSXYdZXJn5gSkmmmmJu1aZYb14V51do+pTOCmA40AqVCIhG5IJ9PvYnhIFOxmdqhpaI6GeHCtpooisuutmg+Eg62KOMKuqoTaXgicQWoIYq6qiklmoqFV0UoeqqrLbq6quwxirrrLTWauutJ4QAACH5BAUKABwALAcABADOAAsAAAX/IPd0D2dyRCoUp/k8gpHOKtseR9yiSmGbuBykler9XLAhkbDavXTL5k2oqFqNOxzUZPU5YYZd1XsD72rZpBjbeh52mSNnMSC8lwblKZGwi+0QfIJ8CncnCoCDgoVnBHmKfByGJimPkIwtiAeBkH6ZHJaKmCeVnKKTHIihg5KNq4uoqmEtcRUtEREMBggtEr4QDrjCuRC8h7/BwxENeicSF8DKy82pyNLMOxzWygzFmdvD2L3P0dze4+Xh1Arkyepi7dfFvvTtLQkZBC0T/FX3CRgCMOBHsJ+EHYQY7OinAGECgQsB+Lu3AOK+CewcWjwxQeJBihtNGHSoQOE+iQ3//4XkwBBhRZMcUS6YSXOAwIL8PGqEaSJCiYt9SNoCmnJPAgUVLChdaoFBURN8MAzl2PQphwQLfDFd6lTowglHve6rKpbjhK7/pG5VinZP1qkiz1rl4+tr2LRwWU64cFEihwEtZgbgR1UiHaMVvxpOSwBA37kzGz9e8G+B5MIEKLutOGEsAH2ATQwYfTmuX8aETWdGPZmiZcccNSzeTCA1Sw0bdiitC7LBWgu8jQr8HRzqgpK6gX88QbrB14z/kF+ELpwB8eVQj/JkqdylAudji/+ts3039vEEfK8Vz2dlvxZKG0CmbkKDBvllRd6fCzDvBLKBDSCeffhRJEFebFk1k/Mv9jVIoIJZSeBggwUaNeB+Qk34IE0cXlihcfRxkOAJFFhwGmKlmWDiakZhUJtnLBpnWWcnKaAZcxI0piFGGLBm1mc90kajSCveeBVWKeYEoU2wqeaQi0PetoE+rr14EpVC7oAbAUHqhYExbn2XHHsVqbcVew9tx8+XJKk5AZsqqdlddGpqAKdbAYBn1pcczmSTdWvdmZ17c1b3FZ99vnTdCRFM8OEcAhLwm1NdXnWcBBSMRWmfkWZqVlsmLIiAp/o1gGV2vpS4lalGYsUOqXrddcKCmK61aZ8SjEpUpVFVoCpTj4r661Km7kBHjrDyc1RAIQAAIfkEBQoAGwAsBwAEAM4ACwAABf/gtmUCd4goQQgFKj6PYKi0yrrbc8i4ohQt12EHcal+MNSQiCP8gigdz7iCioaCIvUmZLp8QBzW0EN2vSlCuDtFKaq4RyHzQLEKZNdiQDhRDVooCwkbfm59EAmKi4SGIm+AjIsKjhsqB4mSjT2IOIOUnICeCaB/mZKFNTSRmqVpmJqklSqskq6PfYYCDwYHDC4REQwGCBLGxxIQDsHMwhAIX8bKzcENgSLGF9PU1j3Sy9zX2NrgzQziChLk1BHWxcjf7N046tvN82715czn9Pryz6Ilc4ACj4EBOCZM8KEnAYYADBRKnACAYUMFv1wotIhCEcaJCisqwJFgAUSQGyX/kCSVUUTIdKMwJlyo0oXHlhskwrTJciZHEXsgaqS4s6PJiCAr1uzYU8kBBSgnWFqpoMJMUjGtDmUwkmfVmVypakWhEKvXsS4nhLW5wNjVroJIoc05wSzTr0PtiigpYe4EC2vj4iWrFu5euWIMRBhacaVJhYQBEFjA9jHjyQ0xEABwGceGAZYjY0YBOrRLCxUp29QM+bRkx5s7ZyYgVbTqwwti2ybJ+vLtDYpycyZbYOlptxdx0kV+V7lC5iJAyyRrwYKxAdiz82ng0/jnAdMJFz0cPi104Ec1Vj9/M6F173vKL/feXv156dw11tlqeMMnv4V5Ap53GmjQQH97nFfg+IFiucfgRX5Z8KAgbUlQ4IULIlghhhdOSB6AgX0IVn8eReghen3NRIBsRgnH4l4LuEidZBjwRpt6NM5WGwoW0KSjCwX6yJSMab2GwwAPDXfaBCtWpluRTQqC5JM5oUZAjUNS+VeOLWpJEQ7VYQANW0INJSZVDFSnZphjSikfmzE5N4EEbQI1QJmnWXCmHulRp2edwDXF43txukenJwvI9xyg9Q26Z3MzGUcBYFEChZh6DVTq34AU8Iflh51Sd+CnKFYQ6mmZkhqfBKfSxZWqA9DZanWjxmhrWwi0qtCrt/43K6WqVjjpmhIqgEGvculaGKklKstAACEAACH5BAUKABwALAcABADOAAsAAAX/ICdyQmaMYyAUqPgIBiHPxNpy79kqRXH8wAPsRmDdXpAWgWdEIYm2llCHqjVHU+jjJkwqBTecwItShMXkEfNWSh8e1NGAcLgpDGlRgk7EJ/6Ae3VKfoF/fDuFhohVeDeCfXkcCQqDVQcQhn+VNDOYmpSWaoqBlUSfmowjEA+iEAEGDRGztAwGCDcXEA60tXEiCrq8vREMEBLIyRLCxMWSH
14284MzExnbRvQ2Sy7vN0zvVtNfU2tLY3rPgLdnDvca4VQS/Cpk3ABwSLQkYAQwT/P309vcI7OvXr94jBQMJ/nskkGA/BQBRLNDncAIAiDcG6LsxAWOLiQzmeURBKWSLCQbv/1F0eDGinJUKR47YY1IEgQASKk7Yc7ACRwZm7mHweRJoz59BJUogisKCUaFMR0x4SlJBVBFTk8pZivTR0K73rN5wqlXEAq5Fy3IYgHbEzQ0nLy4QSoCjXLoom96VOJEeCosK5n4kkFfqXjl94wa+l1gvAcGICbewAOAxY8l/Ky/QhAGz4cUkGxu2HNozhwMGBnCUqUdBg9UuW9eUynqSwLHIBujePef1ZGQZXcM+OFuEBeBhi3OYgLyqcuaxbT9vLkf4SeqyWxSQpKGB2gQpm1KdWbu72rPRzR9Ne2Nu9Kzr/1Jqj0yD/fvqP4aXOt5sW/5qsXXVcv1Nsp8IBUAmgswGF3llGgeU1YVXXKTN1FlhWFXW3gIE+DVChApysACHHo7Q4A35lLichh+ROBmLKAzgYmYEYDAhCgxKGOOMn4WR4kkDaoBBOxJtdNKQxFmg5JIWIBnQc07GaORfUY4AEkdV6jHlCEISSZ5yTXpp1pbGZbkWmcuZmQCaE6iJ0FhjMaDjTMsgZaNEHFRAQVp3bqXnZED1qYcECOz5V6BhSWCoVJQIKuKQi2KFKEkEFAqoAo7uYSmO3jk61wUUMKmknJ4SGimBmAa0qVQBhAAAIfkEBQoAGwAsBwAEAM4ACwAABf/gJm5FmRlEqhJC+bywgK5pO4rHI0D3pii22+Mg6/0Ej96weCMAk7cDkXf7lZTTnrMl7eaYoy10JN0ZFdco0XAuvKI6qkgVFJXYNwjkIBcNBgR8TQoGfRsJCRuCYYQQiI+ICosiCoGOkIiKfSl8mJkHZ4U9kZMbKaI3pKGXmJKrngmug4WwkhA0lrCBWgYFCCMQFwoQDRHGxwwGCBLMzRLEx8iGzMMO0cYNeCMKzBDW19lnF9DXDIY/48Xg093f0Q3s1dcR8OLe8+Y91OTv5wrj7o7B+7VNQqABIoRVCMBggsOHE36kSoCBIcSH3EbFangxogJYFi8CkJhqQciLJEf/LDDJEeJIBT0GsOwYUYJGBS0fjpQAMidGmyVP6sx4Y6VQhzs9VUwkwqaCCh0tmKoFtSMDmBOf9phg4SrVrROuasRQAaxXpVUhdsU6IsECZlvX3kwLUWzRt0BHOLTbNlbZG3vZinArge5Dvn7wbqtQkSYAAgtKmnSsYKVKo2AfW048uaPmG386i4Q8EQMBAIAnfB7xBxBqvapJ9zX9WgRS2YMpnvYMGdPK3aMjt/3dUcNI4blpj7iwkMFWDXDvSmgAlijrt9RTR78+PS6z1uAJZIe93Q8g5zcsWCi/4Y+C8bah5zUv3vv89uft30QP23punGCx5954oBBwnwYaNCDY/wYrsYeggnM9B2Fpf8GG2CEUVWhbWAtGouEGDy7Y4IEJVrbSiXghqGKIo7z1IVcXIkKWWR361QOLWWnIhwERpLaaCCee5iMBGJQmJGyPFTnbkfHVZGRtIGrg5HALEJAZbu39BuUEUmq1JJQIPtZilY5hGeSWsSk52G9XqsmgljdIcABytq13HyIM6RcUA+r1qZ4EBF3WHWB29tBgAzRhEGhig8KmqKFv8SeCeo+mgsF7YFXa1qWSbkDpom/mqR1PmHCqJ3fwNRVXjC7S6CZhFVCQ2lWvZiirhQq42SACt25IK2hv8TprriUV1usGgeka7LFcNmCldMLi6qZMgFLgpw16Cipb7bC1knXsBiEAACH5BAUKABsALAcABADOAAsAAAX/4FZsJPkUmUGsLCEUTywXglFuSg7fW1xAvNWLF6sFFcPb42C8EZCj24EJdCp2yoegWsolS0Uu6fmamg8n8YYcLU2bXSiRaXMGvqV6/KAeJAh8VgZqCX+BexCFioWAYgqNi4qAR4ORhRuHY408jAeUhAmYYiuVlpiflqGZa5CWkzc5fKmbbhIpsAoQDRG8vQwQCBLCwxK6vb5qwhfGxxENahvCEA7NzskSy7vNzzzK09W/PNHF1NvX2dXcN8K55cfh69Luveol3vO8zwi4Yhj+AQwmCBw4IYclDAAJDlQggVOChAoLKkgFkSCAHDwWLKhIEOONARsDKryogFPIiAUb/95gJNIiw4wnI778GFPhzBKFOAq8qLJEhQpiNArjMcHCmlTCUDIouTKBhApELSxFWiGiVKY4E2CAekPgUphDu0742nRrVLJZnyrFSqKQ2ohoSYAMW6IoDpNJ4bLdILTnAj8KUF7UeENjAKuDyxIgOuGiOI0EBBMgLNew5AUrDTMGsFixwBIaNCQuAXJB57qNJ2OWm2Aj4skwCQCIyNkhhtMkdsIuodE0AN4LJDRgfLPtn5YDLdBlraAByuUbBgxQwICxMOnYpVOPej074OFdlfc0TqC62OIbcppHjV4o+LrieWhfT8JC/I/T6W8oCl29vQ0XjLdBaA3s1RcPBO7lFvpX8BVoG4O5jTXRQRDuJ6FDTzEWF1/BCZhgbyAKE9qICYLloQYOFtahVRsWYlZ4KQJHlwHS/IYaZ6sZd9tmu5HQm2xi1UaTbzxYwJk/wBF5g5EEYOBZeEfGZmNdFyFZmZIR4jikbLThlh5kUUVJGmRT7sekkziRWUIACABk3T4qCsedgO4xhgGcY7q5pHJ4klBBTQRJ0CeHcoYHHUh6wgfdn9uJdSdMiebGJ0zUPTcoS286FCkrZxnYoYYKWLkBowhQoBeaOlZAgVhLidrXqg2G
14284iqpQpZ4apwSwRtjqrB3muoF9BboaXKmshlqWqsWiGt2wphJkQbAU5hoCACH5BAUKABsALAcABADOAAsAAAX/oGFw2WZuT5oZROsSQnGaKjRvilI893MItlNOJ5v5gDcFrHhKIWcEYu/xFEqNv6B1N62aclysF7fsZYe5aOx2yL5aAUGSaT1oTYMBwQ5VGCAJgYIJCnx1gIOBhXdwiIl7d0p2iYGQUAQBjoOFSQR/lIQHnZ+Ue6OagqYzSqSJi5eTpTxGcjcSChANEbu8DBAIEsHBChe5vL13G7fFuscRDcnKuM3H0La3EA7Oz8kKEsXazr7Cw9/Gztar5uHHvte47MjktznZ2w0G1+D3BgirAqJmJMAQgMGEgwgn5Ei0gKDBhBMALGRYEOJBb5QcWlQo4cbAihZz3GgIMqFEBSM1/4ZEOWPAgpIIJXYU+PIhRG8ja1qU6VHlzZknJNQ6UanCjQkWCIGSUGEjAwVLjc44+DTqUQtPPS5gejUrTa5TJ3g9sWCr1BNUWZI161StiQUDmLYdGfesibQ3XMq1OPYthrwuA2yU2LBs2cBHIypYQPPlYAKFD5cVvNPtW8eVGbdcQADATsiNO4cFAPkvHpedPzc8kUcPgNGgZ5RNDZG05reoE9s2vSEP79MEGiQGy1qP8LA4ZcdtsJE48ONoLTBtTV0B9LsTnPceoIDBDQvS7W7vfjVY3q3eZ4A339J4eaAmKqU/sV58HvJh2RcnIBsDUw0ABqhBA5aV5V9XUFGiHfVeAiWwoFgJJrIXRH1tEMiDFV4oHoAEGlaWhgIGSGBO2nFomYY3mKjVglidaNYJGJDkWW2xxTfbjCbVaOGNqoX2GloR8ZeTaECS9pthRGJH2g0b3Agbk6hNANtteHD2GJUucfajCQBy5OOTQ25ZgUPvaVVQmbKh9510/qQpwXx3SQdfk8tZJOd5b6JJFplT3ZnmmX3qd5l1eg5q00HrtUkUn0AKaiGjClSAgKLYZcgWXwocGRcCFGCKwSB6ceqphwmYRUFYT/1WKlOdUpipmxW0mlCqHjYkAaeoZlqrqZ4qd+upQKaapn/AmgAegZ8KUtYtFAQQAgAh+QQFCgAbACwHAAQAzgALAAAF/+C2PUcmiCiZGUTrEkKBis8jQEquKwU5HyXIbEPgyX7BYa5wTNmEMwWsSXsqFbEh8DYs9mrgGjdK6GkPY5GOeU6ryz7UFopSQEzygOGhJBjoIgMDBAcBM0V/CYqLCQqFOwobiYyKjn2TlI6GKC2YjJZknouaZAcQlJUHl6eooJwKooobqoewrJSEmyKdt59NhRKFMxLEEA4RyMkMEAjDEhfGycqAG8TQx9IRDRDE3d3R2ctD1RLg0ttKEnbY5wZD3+zJ6M7X2RHi9Oby7u/r9g38UFjTh2xZJBEBMDAboogAgwkQI07IMUORwocSJwCgWDFBAIwZOaJIsOBjRogKJP8wTODw5ESVHVtm3AhzpEeQElOuNDlTZ0ycEUWKWFASqEahGwYUPbnxoAgEdlYSqDBkgoUNClAlIHbSAoOsqCRQnQHxq1axVb06FWFxLIqyaze0Tft1JVqyE+pWXMD1pF6bYl3+HTqAWNW8cRUFzmih0ZAAB2oGKukSAAGGRHWJgLiR6AylBLpuHKKUMlMCngMpDSAa9QIUggZVVvDaJobLeC3XZpvgNgCmtPcuwP3WgmXSq4do0DC6o2/guzcseECtUoO0hmcsGKDgOt7ssBd07wqesAIGZC1YIBa7PQHvb1+SFo+++HrJSQfB33xfav3i5eX3Hnb4CTJgegEq8tH/YQEOcIJzbm2G2EoYRLgBXFpVmFYDcREV4HIcnmUhiGBRouEMJGJGzHIspqgdXxK0yCKHRNXoIX4uorCdTyjkyNtdPWrA4Up82EbAbzMRxxZRR54WXVLDIRmRcag5d2R6ugl3ZXzNhTecchpMhIGVAKAYpgJjjsSklBEd99maZoo535ZvdamjBEpusJyctg3h4X8XqodBMx0tiNeg/oGJaKGABpogS40KSqiaEgBqlQWLUtqoVQnytekEjzo0hHqhRorppOZt2p923M2AAV+oBtpAnnPNoB6HaU6mAAIU+IXmi3j2mtFXuUoHKwXpzVrsjcgGOauKEjQrwq157hitGq2NoWmjh7z6Wmxb0m5w66+2VRAuXN/yFUAIACH5BAUKABsALAcABADOAAsAAAX/4CZuRiaM45MZqBgIRbs9AqTcuFLE7VHLOh7KB5ERdjJaEaU4ClO/lgKWjKKcMiJQ8KgumcieVdQMD8cbBeuAkkC6LYLhOxoQ2PF5Ys9PKPBMen17f0CCg4VSh32JV4t8jSNqEIOEgJKPlkYBlJWRInKdiJdkmQlvKAsLBxdABA4RsbIMBggtEhcQsLKxDBC2TAS6vLENdJLDxMZAubu8vjIbzcQRtMzJz79S08oQEt/guNiyy7fcvMbh4OezdAvGrakLAQwyABsELQkY9BP+//ckyPDD4J9BfAMh1GsBoImMeQUN+lMgUJ9CiRMa5msxoB9Gh/o8GmxYMZXIgxtR/yQ46S/gQAURR0pDwYDfywoyLPip5AdnCwsMFPBU4BPFhKBDi444quCmDKZOfwZ9KEGpCKgcN1jdALSpPqIYsabS+nSqvqplvYqQYAeDPgwKwjaMtiDl0oaqUAyo+3TuWwUAMPpVCfee0cEjVBGQq2ABx7oTWmQk4FglZMGN9fGVDMCuiH2AOVOu/PmyxM630gwM0CCn6q8LjVJ8GXvpa5Uwn95OTC/nNxkda1/dLSK475IjCD6dHbK1ZOa4hXP9DXs5chJ00UpVm5xo2qRpoxptwF2E4/IbJpB/SDz9+q9b1aNfQH08+p4a8uvX8B53fLP+ycAfemjsRUBgp1H20K+BghHgVgt1GXZXZpZ5lt4ECjxYR4ScUWiShEtZqBiIInRGWnERNnjiBglw+JyGnxUmGowsyiiZg189lNtPGACjV2+S9UjbU0JWF6SPvEk3QZEqsZYTk3UAaRSUnznJI5LmESCdBVSyaOWUWLK4I5gDUYVeV1T9l+FZClCAUVA09uSmRHBCKAECFEhW51ht6rnmWBXkaR+NjuHpJ40D3DmnQXt2F+ihZxlqVKOfQRACACH5BAUKABwALAcABADOAAsAAAX/ICdyUCkUo/g8mUG8MCGkKgspeC6j6XEIEBpBUeCNfECaglBcOVfJFK7YQwZHQ6JRZBUqTrSuVEuD3nI45pYjFuWKvjjSkCoRaBUMWxkwBGgJCXspQ36Bh4EEB0oKhoiBgyNLjo8Ki4QElIiWfJqHnISNEI+Ql5J9o6SgkqKkgqYihamPkW6oNBgSfiMMDQkGCBLCwxIQDhHIyQwQCGMKxsnKVyPCF9DREQ3MxMPX0cu4wt7J2uHWx9jlKd3o39MiuefYEcvNkuLt5O8c1ePI2tyELXGQwoGDAQf+iEC2xByDCRAjTlAgIUWCBRgCPJQ4AQBFXAs0coT40WLIjRxL/47AcHLkxIomRXL0CHPERZkpa4q4iVKiyp0tR/7kwHMkTUBBJR5dOCEBAVcKKtCAyOHpowXCpk7goABqBZdcvWploACpBKkpIJI1q5OD2rIWE0R1uTZu1LFwbWL9OlKuWb4c6+o9i3dEgw0RCGDUG9KlRw56gDY2qmCByZBaASi+TACA0TucAaTteCcy0ZuOK3N2vJlx58+LRQyY3Xm0ZsgjZg+oPQLi7dUcNXi0LOJw1pgNtB7XG6CBy+U75SYfPTSQAgZTNUDnQHt67wnbZyvwLgKiMN3oCZB3C76tdewpLFgIP2C88rbi4Y+QT3+8S5USMICZXWj1pkEDeUU3lOYGB3alSoEiMIjgX4WlgNF2EibIwQIXauWXSRg2SAOHIU5IIIMoZkhhWiJaiFVbKo6AQEgQXrTAazO1JhkBrBG3Y2Y6EsUhaGn95hprSN0oWpFE7rhkeaQBchGOEWnwEmc0uKWZj0LeuNV3W4Y2lZHFlQCSRjTIl8uZ+kG5HU/3sRlnTG2ytyadytnD3HrmuRcSn+0h1dycexIK1KCjYaCnjCCVqOFFJTZ5GkUUjESWaUIKU2lgCmAKKQIUjHapXRKE+t2og1VgankNYnohqKJ2CmKplso6GKz7WYCgqxeuyoF8u9IQAgA7", 14285 msg: null, 14286 msgText: "<em>Loading the next set of posts...</em>", 14287 selector: null, 14288 speed: "fast", 14289 start: t 14290 }, 14291 state: { 14292 isDuringAjax: false, 14293 isInvalidPage: false,
14294 isDestroyed: false, 14295 isDone: false, 14296 isPaused: false, 14297 isBeyondMaxPage: false, 14298 currPage: 1 14299 }, 14300 debug: false, 14301 behavior: t, 14302 binder: e(window), 14303 nextSelector: "div.navigation a:first", 14304 navSelector: "div.navigation", 14305 contentSelector: null, 14306 extraScrollPx: 150, 14307 itemSelector: "div.post", 14308 animate: false, 14309 pathParse: t, 14310 dataType: "html", 14311 appendCallback: true, 14312 bufferPx: 40, 14313 errorCallback: function () { }, 14314 infid: 0, 14315 pixelsFromNavToBottom: t, 14316 path: t, 14317 prefill: false, 14318 maxPage: t 14319 }; 14320 e.infinitescroll.prototype = { 14321 _binding: function (n) { 14322 var r = this, 14323 i = r.options; 14324 i.v = "2.0b2.120520"; 14325 if (!!i.behavior && this["_binding_" + i.behavior] !== t) { 14326 this["_binding_" + i.behavior].call(this); 14327 return 14328 } 14329 if (n !== "bind" && n !== "unbind") { 14330 this._debug("Binding value " + n + " not valid"); 14331 return false 14332 } 14333 if (n === "unbind") { 14334 this.options.binder.unbind("smartscroll.infscr." + r.options.infid) 14335 } else { 14336 this.options.binder[n]("smartscroll.infscr." + r.options.infid, function () { 14337 r.scroll() 14338 }) 14339 } 14340 this._debug("Binding", n) 14341 }, 14342 _create: function (r, i) { 14343 var s = e.extend(true, {}, e.infinitescroll.defaults, r); 14344 this.options = s; 14345 var o = e(window); 14346 var u = this; 14347 if (!u._validate(r)) { 14348 return false 14349 } 14350 var a = e(s.nextSelector).attr("href"); 14351 if (!a) { 14352 this._debug("Navigation selector not found"); 14353 return false 14354 } 14355 s.path = s.path || this._determinepath(a); 14356 s.contentSelector = s.contentSelector || this.element; 14357 s.loading.selector = s.loading.selector || s.contentSelector; 14358 s.loading.msg = s.loading.msg || e('<div id="infscr-loading"><img alt="Loading..." src="' + s.loading.img + '" /><div>' + s.loading.msgText + "</div></div>"); 14359 (new Image).src = s.loading.img; 14360 if (s.pixelsFromNavToBottom === t) { 14361 s.pixelsFromNavToBottom = e(document).height() - e(s.navSelector).offset().top; 14362 this._debug("pixelsFromNavToBottom: " + s.pixelsFromNavToBottom) 14363 } 14364 var f = this; 14365 s.loading.start = s.loading.start || function () { 14366 e(s.navSelector).hide(); 14367 s.loading.msg.appendTo(s.loading.selector).show(s.loading.speed, e.proxy(function () { 14368 this.beginAjax(s) 14369 }, f)) 14370 }; 14371 s.loading.finished = s.loading.finished || function () { 14372 if (!s.state.isBeyondMaxPage) s.loading.msg.fadeOut(s.loading.speed) 14373 }; 14374 s.callback = function (n, r, u) { 14375 if (!!s.behavior && n["_callback_" + s.behavior] !== t) { 14376 n["_callback_" + s.behavior].call(e(s.contentSelector)[0], r, u) 14377 } 14378 if (i) { 14379 i.call(e(s.contentSelector)[0], r, s, u) 14380 } 14381 if (s.prefill) { 14382 o.bind("resize.infinite-scroll", n._prefill) 14383 } 14384 }; 14385 if (r.debug) { 14386 if (Function.prototype.bind && (typeof console === "object" || typeof console === "function") && typeof console.log === "object") { 14387 ["log", "info", "warn", "error", "assert", "dir", "clear", "profile", "profileEnd"].forEach(function (e) { 14388 console[e] = this.call(console[e], console) 14389 }, Function.prototype.bind) 14390 } 14391 } 14392 this._setup(); 14393 if (s.prefill) { 14394 this._prefill() 14395 } 14396 return true 14397 }, 14398 _prefill: function () { 14399 function i() { 14400 return e(n.options.contentSelector).height() <= r.height() 14401 } 14402 var n = this; 14403 var r = e(window); 14404 this._prefill = function () { 14405 if (i()) { 14406 n.scroll() 14407 } 14408 r.bind("resize.infinite-scroll", function () { 14409 if (i()) { 14410 r.unbind("resize.infinite-scroll"); 14411 n.scroll() 14412 } 14413 }) 14414 }; 14415 this._prefill() 14416 }, 14417 _debug: function () { 14418 if (true !== this.options.debug) { 14419 return 14420 } 14421 if (typeof console !== "undefined" && typeof console.log === "function") { 14422 if (Array.prototype.slice.call(arguments).length === 1 && typeof Array.prototype.slice.call(arguments)[0] === "string") { 14423 console.log(Array.prototype.slice.call(arguments).toString()) 14424 } else { 14425 console.log(Array.prototype.slice.call(arguments)) 14426 } 14427 } else if (!Function.prototype.bind && typeof console !== "undefined" && typeof console.log === "object") { 14428 Function.prototype.call.call(console.log, console, Array.prototype.slice.call(arguments)) 14429 } 14430 }, 14431 _determinepath: function (n) { 14432 var r = this.options; 14433 if (!!r.behavior && this["_determinepath_" + r.behavior] !== t) { 14434 return this["_determinepath_" + r.behavior].call(this, n) 14435 } 14436 if (!!r.pathParse) { 14437 this._debug("pathParse manual"); 14438 return r.pathParse(n, this.options.state.currPage + 1) 14439 } else if (n.match(/^(.*?)\b2\b(.*?$)/)) { 14440 n = n.match(/^(.*?)\b2\b(.*?$)/).slice(1) 14441 } else if (n.match(/^(.*?)2(.*?$)/)) { 14442 if (n.match(/^(.*?page=)2(\/.*|$)/)) { 14443 n = n.match(/^(.*?page=)2(\/.*|$)/).slice(1); 14444 return n 14445 } 14446 n = n.match(/^(.*?)2(.*?$)/).slice(1) 14447 } else { 14448 if (n.match(/^(.*?page=)1(\/.*|$)/)) { 14449 n = n.match(/^(.*?page=)1(\/.*|$)/).slice(1); 14450 return n 14451 } else { 14452 this._debug("Sorry, we couldn't parse your Next (Previous Posts) URL. Verify your the css selector points to the correct A tag. If you still get this error: yell, scream, and kindly ask for help at infinite-scroll.com."); 14453 r.state.isInvalidPage = true 14454 } 14455 } 14456 this._debug("determinePath", n); 14457 return n 14458 }, 14459 _error: function (n) { 14460 var r = this.options; 14461 if (!!r.behavior && this["_error_" + r.behavior] !== t) { 14462 this["_error_" + r.behavior].call(this, n); 14463 return 14464 } 14465 if (n !== "destroy" && n !== "end") { 14466 n = "unknown" 14467 } 14468 this._debug("Error", n); 14469 if (n === "end" || r.state.isBeyondMaxPage) { 14470 this._showdonemsg() 14471 } 14472 r.state.isDone = true; 14473 r.state.currPage = 1;
14474 r.state.isPaused = false; 14475 r.state.isBeyondMaxPage = false; 14476 this._binding("unbind") 14477 }, 14478 _loadcallback: function (r, i, s) { 14479 var o = this.options, 14480 u = this.options.callback, 14481 a = o.state.isDone ? "done" : !o.appendCallback ? "no-append" : "append", 14482 f; 14483 if (!!o.behavior && this["_loadcallback_" + o.behavior] !== t) { 14484 this["_loadcallback_" + o.behavior].call(this, r, i); 14485 return 14486 } 14487 switch (a) { 14488 case "done": 14489 this._showdonemsg(); 14490 return false; 14491 case "no-append": 14492 if (o.dataType === "html") { 14493 i = "<div>" + i + "</div>"; 14494 i = e(i).find(o.itemSelector) 14495 } 14496 if (i.length === 0) { 14497 return this._error("end") 14498 } 14499 break; 14500 case "append": 14501 var l = r.children(); 14502 if (l.length === 0) { 14503 return this._error("end") 14504 } 14505 f = document.createDocumentFragment(); 14506 while (r[0].firstChild) { 14507 f.appendChild(r[0].firstChild) 14508 } 14509 this._debug("contentSelector", e(o.contentSelector)[0]); 14510 e(o.contentSelector)[0].appendChild(f); 14511 i = l.get(); 14512 break 14513 } 14514 o.loading.finished.call(e(o.contentSelector)[0], o); 14515 if (o.animate) { 14516 var c = e(window).scrollTop() + e(o.loading.msg).height() + o.extraScrollPx + "px"; 14517 e("html,body").animate({ 14518 scrollTop: c 14519 }, 800, function () { 14520 o.state.isDuringAjax = false 14521 }) 14522 } 14523 if (!o.animate) { 14524 o.state.isDuringAjax = false 14525 } 14526 u(this, i, s); 14527 if (o.prefill) { 14528 this._prefill() 14529 } 14530 }, 14531 _nearbottom: function () { 14532 var r = this.options, 14533 i = 0 + e(document).height() - r.binder.scrollTop() - e(window).height(); 14534 if (!!r.behavior && this["_nearbottom_" + r.behavior] !== t) { 14535 return this["_nearbottom_" + r.behavior].call(this) 14536 } 14537 this._debug("math:", i, r.pixelsFromNavToBottom); 14538 return i - r.bufferPx < r.pixelsFromNavToBottom 14539 }, 14540 _pausing: function (n) { 14541 var r = this.options; 14542 if (!!r.behavior && this["_pausing_" + r.behavior] !== t) { 14543 this["_pausing_" + r.behavior].call(this, n); 14544 return 14545 } 14546 if (n !== "pause" && n !== "resume" && n !== null) { 14547 this._debug("Invalid argument. Toggling pause value instead") 14548 } 14549 n = n && (n === "pause" || n === "resume") ? n : "toggle"; 14550 switch (n) { 14551 case "pause":
14552 r.state.isPaused = true; 14553 break; 14554 case "resume": 14555 r.state.isPaused = false; 14556 break; 14557 case "toggle": 14558 r.state.isPaused = !r.state.isPaused; 14559 break 14560 } 14561 this._debug("Paused", r.state.isPaused); 14562 return false 14563 }, 14564 _setup: function () { 14565 var n = this.options; 14566 if (!!n.behavior && this["_setup_" + n.behavior] !== t) { 14567 this["_setup_" + n.behavior].call(this); 14568 return 14569 } 14570 this._binding("bind"); 14571 return false 14572 }, 14573 _showdonemsg: function () { 14574 var r = this.options; 14575 if (!!r.behavior && this["_showdonemsg_" + r.behavior] !== t) { 14576 this["_showdonemsg_" + r.behavior].call(this); 14577 return 14578 } 14579 r.loading.msg.find("img").hide().parent().find("div").html(r.loading.finishedMsg).animate({ 14580 opacity: 1 14581 }, 2e3, function () { 14582 e(this).parent().fadeOut(r.loading.speed) 14583 }); 14584 r.errorCallback.call(e(r.contentSelector)[0], "done") 14585 }, 14586 _validate: function (n) { 14587 for (var r in n) { 14588 if (r.indexOf && r.indexOf("Selector") > -1 && e(n[r]).length === 0) { 14589 this._debug("Your " + r + " found no elements."); 14590 return false 14591 } 14592 } 14593 return true 14594 }, 14595 bind: function () { 14596 this._binding("bind") 14597 }, 14598 destroy: function () { 14599 this.options.state.isDestroyed = true; 14600 this.options.loading.finished(); 14601 return this._error("destroy") 14602 }, 14603 pause: function () { 14604 this._pausing("pause") 14605 }, 14606 resume: function () { 14607 this._pausing("resume") 14608 }, 14609 beginAjax: function (r) { 14610 var i = this, 14611 s = r.path, 14612 o, u, a, f; 14613 r.state.currPage++; 14614 if (r.maxPage !== t && r.state.currPage > r.maxPage) { 14615 r.state.isBeyondMaxPage = true; 14616 this.destroy(); 14617 return 14618 } 14619 o = e(r.contentSelector).is("table, tbody") ? e("<tbody/>") : e("<div/>"); 14620 u = typeof s === "function" ? s(r.state.currPage) : s.join(r.state.currPage); 14621 i._debug("heading into ajax", u); 14622 a = r.dataType === "html" || r.dataType === "json" ? r.dataType : "html+callback"; 14623 if (r.appendCallback && r.dataType === "html") { 14624 a += "+callback" 14625 } 14626 switch (a) { 14627 case "html+callback": 14628 i._debug("Using HTML via .load() method"); 14629 o.load(u + " " + r.itemSelector, t, function (t) { 14630 i._loadcallback(o, t, u) 14631 }); 14632 break; 14633 case "html": 14634 i._debug("Using " + a.toUpperCase() + " via $.ajax() method"); 14635 e.ajax({ 14636 url: u, 14637 dataType: r.dataType, 14638 complete: function (t, n) { 14639 f = typeof t.isResolved !== "undefined" ? t.isResolved() : n === "success" || n === "notmodified"; 14640 if (f) { 14641 i._loadcallback(o, t.responseText, u) 14642 } else { 14643 i._error("end") 14644 } 14645 } 14646 }); 14647 break; 14648 case "json": 14649 i._debug("Using " + a.toUpperCase() + " via $.ajax() method"); 14650 e.ajax({ 14651 dataType: "json", 14652 type: "GET", 14653 url: u, 14654 success: function (e, n, s) { 14655 f = typeof s.isResolved !== "undefined" ? s.isResolved() : n === "success" || n === "
14655notmodified"; 14656 if (r.appendCallback) { 14657 if (r.template !== t) { 14658 var a = r.template(e); 14659 o.append(a); 14660 if (f) { 14661 i._loadcallback(o, a) 14662 } else { 14663 i._error("end") 14664 } 14665 } else { 14666 i._debug("template must be defined."); 14667 i._error("end") 14668 } 14669 } else { 14670 if (f) { 14671 i._loadcallback(o, e, u) 14672 } else { 14673 i._error("end") 14674 } 14675 } 14676 }, 14677 error: function () { 14678 i._debug("JSON ajax request failed."); 14679 i._error("end") 14680 } 14681 }); 14682 break 14683 } 14684 }, 14685 retrieve: function (r) { 14686 r = r || null; 14687 var i = this, 14688 s = i.options; 14689 if (!!s.behavior && this["retrieve_" + s.behavior] !== t) { 14690 this["retrieve_" + s.behavior].call(this, r); 14691 return 14692 } 14693 if (s.state.isDestroyed) { 14694 this._debug("Instance is destroyed"); 14695 return false 14696 } 14697 s.state.isDuringAjax = true; 14698 s.loading.start.call(e(s.contentSelector)[0], s) 14699 }, 14700 scroll: function () { 14701 var n = this.options, 14702 r = n.state; 14703 if (!!n.behavior && this["scroll_" + n.behavior] !== t) { 14704 this["scroll_" + n.behavior].call(this); 14705 return 14706 } 14707 if (r.isDuringAjax || r.isInvalidPage || r.isDone || r.isDestroyed || r.isPaused) { 14708 return 14709 } 14710 if (!this._nearbottom()) { 14711 return 14712 } 14713 this.retrieve() 14714 }, 14715 toggle: function () { 14716 this._pausing() 14717 }, 14718 unbind: function () { 14719 this._binding("unbind") 14720 }, 14721 update: function (n) { 14722 if (e.isPlainObject(n)) { 14723 this.options = e.extend(true, this.options, n) 14724 } 14725 } 14726 }; 14727 e.fn.infinitescroll = function (n, r) { 14728 var i = typeof n; 14729 switch (i) { 14730 case "string": 14731 var s = Array.prototype.slice.call(arguments, 1); 14732 this.each(function () { 14733 var t = e.data(this, "infinitescroll"); 14734 if (!t) { 14735 return false 14736 } 14737 if (!e.isFunction(t[n]) || n.charAt(0) === "_") { 14738 return false 14739 } 14740 t[n].apply(t, s) 14741 }); 14742 break; 14743 case "object": 14744 this.each(function () { 14745 var t = e.data(this, "infinitescroll"); 14746 if (t) { 14747 t.update(n) 14748 } else { 14749 t = new e.infinitescroll(n, r, this); 14750 if (!t.failed) { 14751 e.data(this, "infinitescroll", t) 14752 } 14753 } 14754 }); 14755 break 14756 } 14757 return this 14758 }; 14759 var n = e.event, 14760 r; 14761 n.special.smartscroll = { 14762 setup: function () { 14763 e(this).bind("scroll", n.special.smartscroll.handler) 14764 }, 14765 teardown: function () { 14766 e(this).unbind("scroll", n.special.smartscroll.handler) 14767 }, 14768 handler: function (t, n) { 14769 var i = this, 14770 s = arguments; 14771 t.type = "smartscroll"; 14772 if (r) { 14773 clearTimeout(r) 14774 } 14775 r = setTimeout(function () { 14776 e(i).trigger("smartscroll", s) 14777 }, n === "execAsap" ? 0 : 100) 14778 } 14779 }; 14780 e.fn.smartscroll = function (e) { 14781 return e ? this.bind("smartscroll", e) : this.trigger("smartscroll", ["execAsap"]) 14782 } 14783}); 14784 14785/* 14786 -------------------------------- 14787 Infinite Scroll Behavior 14788 Manual / Twitter-style 14789 -------------------------------- 14790 14791*/ 14792$.extend($.infinitescroll.prototype, { 14793 _setup_twitter: function () { 14794 var t = this.options, 14795 e = this; 14796 $(t.nextSelector).click(function (t) { 14797 1 != t.which || t.metaKey || t.shiftKey || (t.preventDefault(), e.retrieve()) 14798 }
14798), e.options.loading.start = function (t) { 14799 t.loading.msg.appendTo(t.loading.selector).show(t.loading.speed, function () { 14800 e.beginAjax(t) 14801 }) 14802 } 14803 }, 14804 _showdonemsg_twitter: function () { 14805 var t = this.options; 14806 t.loading.msg.find("img").hide().parent().find("div").html(t.loading.finishedMsg).animate({ 14807 opacity: 1 14808 }, 2e3, function () { 14809 $(this).parent().fadeOut("normal") 14810 }), $(t.navSelector).fadeOut("normal"), t.errorCallback.call($(t.contentSelector)[0], "done") 14811 } 14812}); 14813 14814 14815/* 14816 * jQuery Pagination Plugin 14817 * ----------------------------------------------- 14818 */ 14819 14820/* 14821Pajinate - jQuery Pagination Plugin 14822Author: Wesley Nolte 14823*/ 14824; 14825(function ($) { 14826 $.fn.pajinate = function (options) { 14827 var current_page = "current_page"; 14828 var items_per_page = "items_per_page"; 14829 var meta; 14830 var defaults = { 14831 item_container_id: ".content", 14832 items_per_page: 10, 14833 nav_panel_id: ".page_navigation", 14834 nav_info_id: ".info_text", 14835 num_page_links_to_display: 20, 14836 start_page: 0, 14837 wrap_around: false, 14838 nav_label_first: "First", 14839 nav_label_prev: "Prev", 14840 nav_label_next: "Next", 14841 nav_label_last: "Last", 14842 nav_order: ["first", "prev", "num", "next", "last"], 14843 nav_label_info: "Showing {0}-{1} of {2} results", 14844 show_first_last: true, 14845 abort_on_small_lists: false, 14846 jquery_ui: false, 14847 jquery_ui_active: "ui-state-highlight", 14848 jquery_ui_default: "ui-state-default", 14849 jquery_ui_disabled: "ui-state-disabled" 14850 }; 14851 var options = $.extend(defaults, options); 14852 var $item_container; 14853 var $page_container; 14854 var $items; 14855 var $nav_panels; 14856 var total_page_no_links; 14857 var jquery_ui_default_class = options.jquery_ui ? options.jquery_ui_default : ""; 14858 var jquery_ui_active_class = options.jquery_ui ? options.jquery_ui_active : ""; 14859 var jquery_ui_disabled_class = options.jquery_ui ? options.jquery_ui_disabled : ""; 14860 return this.each(function () { 14861 $page_container = $(this); 14862 $item_container = $(this).find(options.item_container_id); 14863 $items = $page_container.find(options.item_container_id).children(); 14864 if (options.abort_on_small_lists && options.items_per_page >= $items.size()) { 14865 return $page_container 14866 } 14867 meta = $page_container; 14868 meta.data(current_page, 0); 14869 meta.data(items_per_page, options.items_per_page); 14870 var total_items = $item_container.children().size(); 14871 var number_of_pages = Math.ceil(total_items / options.items_per_page); 14872 var more = '<li class="disabled ellipse more"><span>...</span></li>'; 14873 var less = '<li class="disabled ellipse less"><span>...</span></li>'; 14874 var first = !options.show_first_last ? "" : '<li class="first_link ' + jquery_ui_default_class + '"><a href="#">' + options.nav_label_first + "</a></li>"; 14875 var last = !options.show_first_last ? "" : '<li class="last_link ' + jquery_ui_default_class + '"><a href="#">' + options.nav_label_last + "</a></li>"; 14876 var navigation_html = ""; 14877 for (var i = 0; i < options.nav_order.length; i++) { 14878 switch (options.nav_order[i]) { 14879 case "first": 14880 navigation_html += first; 14881 break; 14882 case "last": 14883 navigation_html += last; 14884 break; 14885 case "next": 14886 navigation_html += '<li class="next_link ' + jquery_ui_default_class + '"><a href="#">' + options.nav_label_next + "</a></li>"; 14887 break; 14888 case "prev": 14889 navigation_html += '<li class="previous_link ' + jquery_ui_default_class + '"><a href="#">
14889' + options.nav_label_prev + "</a></li>"; 14890 break; 14891 case "num": 14892 navigation_html += less; 14893 var current_link = 0; 14894 while (number_of_pages > current_link) { 14895 navigation_html += '<li class="page_link ' + jquery_ui_default_class + '" longdesc="' + current_link + '"><a href="#">' + (current_link + 1) + "</a></li>"; 14896 current_link++ 14897 } 14898 navigation_html += more; 14899 break; 14900 default: 14901 break 14902 } 14903 } 14904 $nav_panels = $page_container.find(options.nav_panel_id); 14905 $nav_panels.html(navigation_html).each(function () { 14906 $(this).find(".page_link:first").addClass("first"); 14907 $(this).find(".page_link:last").addClass("last") 14908 }); 14909 $nav_panels.children(".ellipse").hide(); 14910 $nav_panels.find(".previous_link").next().next().addClass("active " + jquery_ui_active_class); 14911 $items.hide(); 14912 $items.slice(0, meta.data(items_per_page)).show(); 14913 total_page_no_links = $page_container.find(options.nav_panel_id + ":first").children(".page_link").size(); 14914 options.num_page_links_to_display = Math.min(options.num_page_links_to_display, total_page_no_links); 14915 $nav_panels.children(".page_link").hide(); 14916 $nav_panels.each(function () { 14917 $(this).children(".page_link").slice(0, options.num_page_links_to_display).show() 14918 }); 14919 $page_container.find(".first_link").click(function (e) { 14920 e.preventDefault(); 14921 movePageNumbersRight($(this), 0); 14922 gotopage(0) 14923 }); 14924 $page_container.find(".last_link").click(function (e) { 14925 e.preventDefault(); 14926 var lastPage = total_page_no_links - 1; 14927 movePageNumbersLeft($(this), lastPage); 14928 gotopage(lastPage) 14929 }); 14930 $page_container.find(".previous_link").click(function (e) { 14931 e.preventDefault(); 14932 showPrevPage($(this)) 14933 }); 14934 $page_container.find(".next_link").click(function (e) { 14935 e.preventDefault(); 14936 showNextPage($(this)) 14937 }); 14938 $page_container.find(".page_link").click(function (e) { 14939 e.preventDefault(); 14940 gotopage($(this).attr("longdesc")) 14941 }); 14942 gotopage(parseInt(options.start_page)); 14943 toggleMoreLess(); 14944 if (!options.wrap_around) { 14945 tagNextPrev() 14946 } 14947 }); 14948 14949 function showPrevPage(e) { 14950 new_page = parseInt(meta.data(current_page)) - 1; 14951 if ($(e).siblings(".active").prev(".page_link").length == true) { 14952 movePageNumbersRight(e, new_page); 14953 gotopage(new_page) 14954 } else { 14955 if (options.wrap_around) { 14956 gotopage(total_page_no_links - 1) 14957 } 14958 } 14959 } 14960 14961 function showNextPage(e) { 14962 new_page = parseInt(meta.data(current_page)) + 1; 14963 if ($(e).siblings(".active").next(".page_link").length == true) { 14964 movePageNumbersLeft(e, new_page); 14965 gotopage(new_page) 14966 } else { 14967 if (options.wrap_around) { 14968 gotopage(0) 14969 } 14970 } 14971 } 14972 14973 function gotopage(page_num) { 14974 page_num = parseInt(page_num, 10); 14975 var ipp = parseInt(meta.data(items_per_page)); 14976 start_from = page_num * ipp; 14977 end_on = start_from + ipp; 14978 var items = $items.hide().slice(start_from, end_on); 14979 items.fadeIn(700); 14980 $page_container.find(options.nav_panel_id).children(".page_link[longdesc=" + page_num + "]").addClass("active " + jquery_ui_active_class).siblings(".active").removeClass("active " + jquery_ui_active_class); 14981 meta.data(current_page, page_num); 14982 var $current_page = parseInt(meta.data(current_page) + 1); 14983 var total_items = $item_container.children().size(); 14984 var $number_of_pages = Math.ceil(total_items / options.items_per_page);
14985 $page_container.find(options.nav_info_id).html(options.nav_label_info.replace("{0}", start_from + 1).replace("{1}", start_from + items.length).replace("{2}", $items.length).replace("{3}", $current_page).replace("{4}", $number_of_pages)); 14986 toggleMoreLess(); 14987 tagNextPrev(); 14988 if (typeof (options.onPageDisplayed) !== "undefined") { 14989 options.onPageDisplayed.call(this, page_num + 1) 14990 } 14991 } 14992 14993 function movePageNumbersLeft(e, new_p) { 14994 var new_page = new_p; 14995 var $current_active_link = $(e).siblings(".active"); 14996 if ($current_active_link.siblings(".page_link[longdesc=" + new_page + "]").css("display") == "none") { 14997 $nav_panels.each(function () { 14998 $(this).children(".page_link").hide().slice(parseInt(new_page - options.num_page_links_to_display + 1), new_page + 1).show() 14999 }) 15000 } 15001 } 15002 15003 function movePageNumbersRight(e, new_p) { 15004 var new_page = new_p; 15005 var $current_active_link = $(e).siblings(".active"); 15006 if ($current_active_link.siblings(".page_link[longdesc=" + new_page + "]").css("display") == "none") { 15007 $nav_panels.each(function () { 15008 $(this).children(".page_link").hide().slice(new_page, new_page + parseInt(options.num_page_links_to_display)).show() 15009 }) 15010 } 15011 } 15012 15013 function toggleMoreLess() { } 15014 15015 function tagNextPrev() { 15016 if ($nav_panels.children(".last").hasClass("active")) { 15017 $nav_panels.children(".next_link").add(".last_link").addClass("no_more " + jquery_ui_disabled_class) 15018 } else { 15019 $nav_panels.children(".next_link").add(".last_link").removeClass("no_more " + jquery_ui_disabled_class) 15020 } 15021 if ($nav_panels.children(".first").hasClass("active")) { 15022 $nav_panels.children(".previous_link").add(".first_link").addClass("no_more " + jquery_ui_disabled_class) 15023 } else { 15024 $nav_panels.children(".previous_link").add(".first_link").removeClass("no_more " + jquery_ui_disabled_class) 15025 } 15026 } 15027 } 15028})(jQuery); 15029 15030/* 15031 * Vide jQuery plugin for video backgrounds 15032 * ----------------------------------------------- 15033 */ 15034/* 15035Vide 15036Easy as hell jQuery plugin for video backgrounds. 15037https://github.com/VodkaBears/Vide 15038*/ 15039 15040! function (e, t) { 15041 "function" == typeof define && define.amd ? define(["jquery"], t) : t("object" == typeof exports ? require("jquery") : e.jQuery) 15042}(this, function (e) { 15043 "use strict"; 15044 15045 function t(e) { 15046 var t, o, i, r, s, n, a, p = {}; 15047 for (s = e.replace(/\s*:\s*/g, ":").replace(/\s*,\s*/g, ",").split(","), a = 0, n = s.length; n > a && (o = s[a], -1 === o.search(/^(http|https|ftp):\/\//) && -1 !== o.search(":")); a++) t = o.indexOf(":"), i = o.substring(0, t), r = o.substring(t + 1), r || (r = void 0), "string" == typeof r && (r = "true" === r || ("false" === r ? !1 : r)), "string" == typeof r && (r = isNaN(r) ? r : +r), p[i] = r; 15048 return null == i && null == r ? e : p 15049 } 15050 15051 function o(e) { 15052 e = "" + e; 15053 var t, o, i, r = e.split(/\s+/), 15054 s = "50%", 15055 n = "50%"; 15056 for (i = 0, t = r.length; t > i; i++) o = r[i], "left" === o ? s = "0%" : "right" === o ? s = "100%" : "top" === o ? n = "0%" : "bottom" === o ? n = "100%" : "center" === o ? 0 === i ? s = "50%" : n = "50%" : 0 === i ? s = o : n = o; 15057 return { 15058 x: s, 15059 y: n 15060 } 15061 } 15062 15063 function i(t, o) { 15064 var i = function () { 15065 o(this.src) 15066 }; 15067 e('<img src="' + t + '.gif">').load(i), e('<img src="' + t + '.jpg">').load(i), e('<img src="' + t + '.jpeg">').load(i), e('<img src="' + t + '.png">').load(i) 15068 } 15069 15070 function r(o, i, r) { 15071 if (this.$element = e(o), "string" == typeof i && (i = t(i)), r ? "string" == typeof r && (r = t(r)) : r = {}, "string" == typeof i) i = i.replace(/\.\w*$/, ""); 15072 else if ("object" == typeof i) 15073 for (var s in i) i.hasOwnProperty(s) && (i[s] = i[s].replace(/\.\w*$/, "")); 15074 this.settings = e.extend({}, n, r), this.path = i; 15075 try { 15076 this.init() 15077 } catch (p) { 15078 if (p.message !== a) throw p 15079 } 15080 } 15081 var s = "vide", 15082 n = { 15083 volume: 1, 15084 playbackRate: 1, 15085 muted: !0, 15086 loop: !0, 15087 autoplay: !0, 15088 position: "50% 50%", 15089 posterType: "detect", 15090 resizing: !0, 15091 bgColor: "transparent", 15092 className: "" 15093 }, 15094 a = "Not implemented"; 15095 r.prototype.init = function () { 15096 var t, r, n = this, 15097 p = n.path, 15098 c = p, 15099 d = "", 15100 u = n.$element, 15101 l = n.settings, 15102 g = o(l.position), 15103 f = l.posterType; 15104 r = n.$wrapper = e("<div>").addClass(l.className).css({ 15105 position: "absolute",
vendor: 5,119 bytes, lines 15106-15230
15106 "z-index": -1, 15107 top: 0, 15108 left: 0, 15109 bottom: 0, 15110 right: 0, 15111 overflow: "hidden", 15112 "-webkit-background-size": "cover", 15113 "-moz-background-size": "cover", 15114 "-o-background-size": "cover", 15115 "background-size": "cover", 15116 "background-color": l.bgColor, 15117 "background-repeat": "no-repeat", 15118 "background-position": g.x + " " + g.y 15119 }), "object" == typeof p && (p.poster ? c = p.poster : p.mp4 ? c = p.mp4 : p.webm ? c = p.webm : p.ogv && (c = p.ogv)), "detect" === f ? i(c, function (e) { 15120 r.css("background-image", "url(" + e + ")") 15121 }) : "none" !== f && r.css("background-image", "url(" + c + "." + f + ")"), "static" === u.css("position") && u.css("position", "relative"), u.prepend(r), "object" == typeof p ? (p.mp4 && (d += '<source src="' + p.mp4 + '.mp4" type="video/mp4">'), p.webm && (d += '<source src="' + p.webm + '.webm" type="video/webm">'), p.ogv && (d += '<source src="' + p.ogv + '.ogv" type="video/ogg">'), t = n.$video = e("<video>" + d + "</video>")) : t = n.$video = e('<video><source src="' + p + '.mp4" type="video/mp4"><source src="' + p + '.webm" type="video/webm"><source src="' + p + '.ogv" type="video/ogg"></video>'); 15122 try { 15123 t.prop({ 15124 autoplay: l.autoplay, 15125 loop: l.loop, 15126 volume: l.volume, 15127 muted: l.muted, 15128 defaultMuted: l.muted, 15129 playbackRate: l.playbackRate, 15130 defaultPlaybackRate: l.playbackRate 15131 }) 15132 } catch (h) { 15133 throw new Error(a) 15134 } 15135 t.css({ 15136 margin: "auto", 15137 position: "absolute", 15138 "z-index": -1, 15139 top: g.y, 15140 left: g.x, 15141 "-webkit-transform": "translate(-" + g.x + ", -" + g.y + ")", 15142 "-ms-transform": "translate(-" + g.x + ", -" + g.y + ")", 15143 "-moz-transform": "translate(-" + g.x + ", -" + g.y + ")", 15144 transform: "translate(-" + g.x + ", -" + g.y + ")", 15145 visibility: "hidden", 15146 opacity: 0 15147 }).one("canplaythrough." + s, function () { 15148 n.resize() 15149 }).one("playing." + s, function () { 15150 t.css({ 15151 visibility: "visible", 15152 opacity: 1 15153 }), r.css("background-image", "none") 15154 }), u.on("resize." + s, function () { 15155 l.resizing && n.resize() 15156 }), r.append(t) 15157 }, r.prototype.getVideoObject = function () { 15158 return this.$video[0] 15159 }, r.prototype.resize = function () { 15160 if (this.$video) { 15161 var e = this.$wrapper, 15162 t = this.$video, 15163 o = t[0], 15164 i = o.videoHeight, 15165 r = o.videoWidth, 15166 s = e.height(), 15167 n = e.width(); 15168 n / r > s / i ? t.css({ 15169 width: n + 2, 15170 height: "auto" 15171 }) : t.css({ 15172 width: "auto", 15173 height: s + 2 15174 }) 15175 } 15176 }, r.prototype.destroy = function () { 15177 delete e[s].lookup[this.index], this.$video && this.$video.off(s), this.$element.off(s).removeData(s), this.$wrapper.remove() 15178 }, e[s] = { 15179 lookup: [] 15180 }, e.fn[s] = function (t, o) { 15181 var i; 15182 return this.each(function () { 15183 i = e.data(this, s), i && i.destroy(), i = new r(this, t, o), i.index = e[s].lookup.push(i) - 1, e.data(this, s, i) 15184 }), this 15185 }, e(document).ready(function () { 15186 var t = e(window); 15187 t.on("resize." + s, function () { 15188 for (var t, o = e[s].lookup.length, i = 0; o > i; i++) t = e[s].lookup[i], t && t.settings.resizing && t.resize() 15189 }), t.on("unload." + s, function () { 15190 return !1 15191 }), e(document).find("[data-" + s + "-bg]").each(function (t, o) { 15192 var i = e(o), 15193 r = i.data(s + "-options"), 15194 n = i.data(s + "-bg"); 15195 i[s](n, r) 15196 }) 15197 }) 15198}); 15199 15200 15201/*! 15202 * Datepicker for Bootstrap v1.7.0-dev (https://github.com/eternicode/bootstrap-datepicker) 15203 * 15204 * Copyright 2012 Stefan Petre 15205 * Improvements by Andrew Rowls 15206 * Licensed under the Apache License v2.0 (http://www.apache.org/licenses/LICENSE-2.0) 15207 */ 15208 15209! function (a) { 15210 "function" == typeof define && define.amd ? define(["jquery"], a) : a("object" == typeof exports ? require("jquery") : jQuery) 15211}(function (a, b) { 15212 function c() { 15213 return new Date(Date.UTC.apply(Date, arguments)) 15214 } 15215 15216 function d() { 15217 var a = new Date; 15218 return c(a.getFullYear(), a.getMonth(), a.getDate()) 15219 } 15220 15221 function e(a, b) { 15222 return a.getUTCFullYear() === b.getUTCFullYear() && a.getUTCMonth() === b.getUTCMonth() && a.getUTCDate() === b.getUTCDate() 15223 } 15224 15225 function f(a) { 15226 return function () { 15227 return this[a].apply(this, arguments) 15228 } 15229 } 15230
vendor: 21,610 bytes, lines 15231-15609
15231 function g(a) { 15232 return a && !isNaN(a.getTime()) 15233 } 15234 15235 function h(b, c) { 15236 function d(a, b) { 15237 return b.toLowerCase() 15238 } 15239 var e, f = a(b).data(), 15240 g = {}, 15241 h = new RegExp("^" + c.toLowerCase() + "([A-Z])"); 15242 c = new RegExp("^" + c.toLowerCase()); 15243 for (var i in f) c.test(i) && (e = i.replace(h, d), g[e] = f[i]); 15244 return g 15245 } 15246 15247 function i(b) { 15248 var c = {}; 15249 if (q[b] || (b = b.split("-")[0], q[b])) { 15250 var d = q[b]; 15251 return a.each(p, function (a, b) { 15252 b in d && (c[b] = d[b]) 15253 }), c 15254 } 15255 } 15256 var j = function () { 15257 var b = { 15258 get: function (a) { 15259 return this.slice(a)[0] 15260 }, 15261 contains: function (a) { 15262 for (var b = a && a.valueOf(), c = 0, d = this.length; d > c; c++) 15263 if (0 <= this[c].valueOf() - b && this[c].valueOf() - b < 864e5) return c; 15264 return -1 15265 }, 15266 remove: function (a) { 15267 this.splice(a, 1) 15268 }, 15269 replace: function (b) { 15270 b && (a.isArray(b) || (b = [b]), this.clear(), this.push.apply(this, b)) 15271 }, 15272 clear: function () { 15273 this.length = 0 15274 }, 15275 copy: function () { 15276 var a = new j; 15277 return a.replace(this), a 15278 } 15279 }; 15280 return function () { 15281 var c = []; 15282 return c.push.apply(c, arguments), a.extend(c, b), c 15283 } 15284 }(), 15285 k = function (b, c) { 15286 a.data(b, "datepicker", this), this._process_options(c), this.dates = new j, this.viewDate = this.o.defaultViewDate, this.focusDate = null, this.element = a(b), this.isInput = this.element.is("input"), this.inputField = this.isInput ? this.element : this.element.find("input"), this.component = this.element.hasClass("date") ? this.element.find(".add-on, .input-group-addon, .btn") : !1, this.component && 0 === this.component.length && (this.component = !1), this.isInline = !this.component && this.element.is("div"), this.picker = a(r.template), this._check_template(this.o.templates.leftArrow) && this.picker.find(".prev").html(this.o.templates.leftArrow), this._check_template(this.o.templates.rightArrow) && this.picker.find(".next").html(this.o.templates.rightArrow), this._buildEvents(), this._attachEvents(), this.isInline ? this.picker.addClass("datepicker-inline").appendTo(this.element) : this.picker.addClass("datepicker-dropdown dropdown-menu"), this.o.rtl && this.picker.addClass("datepicker-rtl"), this.o.calendarWeeks && this.picker.find(".datepicker-days .datepicker-switch, thead .datepicker-title, tfoot .today, tfoot .clear").attr("colspan", function (a, b) { 15287 return Number(b) + 1 15288 }), this._allow_update = !1, this.setStartDate(this._o.startDate), this.setEndDate(this._o.endDate), this.setDaysOfWeekDisabled(this.o.daysOfWeekDisabled), this.setDaysOfWeekHighlighted(this.o.daysOfWeekHighlighted), this.setDatesDisabled(this.o.datesDisabled), this.setViewMode(this.o.startView), this.fillDow(), this.fillMonths(), this._allow_update = !0, this.update(), this.isInline && this.show() 15289 }; 15290 k.prototype = { 15291 constructor: k, 15292 _resolveViewName: function (b) { 15293 return a.each(r.viewModes, function (c, d) { 15294 return b === c || -1 !== a.inArray(b, d.names) ? (b = c, !1) : void 0 15295 }), b 15296 }, 15297 _resolveDaysOfWeek: function (b) { 15298 return a.isArray(b) || (b = b.split(/[,\s]*/)), a.map(b, Number) 15299 }, 15300 _check_template: function (c) { 15301 try { 15302 if (c === b || "" === c) return !1; 15303 if ((c.match(/[<>]/g) || []).length <= 0) return !0; 15304 var d = a(c); 15305 return d.length > 0 15306 } catch (e) { 15307 return !1 15308 } 15309 }, 15310 _process_options: function (b) { 15311 this._o = a.extend({}, this._o, b); 15312 var e = this.o = a.extend({}, this._o), 15313 f = e.language; 15314 q[f] || (f = f.split("-")[0], q[f] || (f = o.language)), e.language = f, e.startView = this._resolveViewName(e.startView), e.minViewMode = this._resolveViewName(e.minViewMode), e.maxViewMode = this._resolveViewName(e.maxViewMode), e.startView = Math.max(this.o.minViewMode, Math.min(this.o.maxViewMode, e.startView)), e.multidate !== !0 && (e.multidate = Number(e.multidate) || !1, e.multidate !== !1 && (e.multidate = Math.max(0, e.multidate))), e.multidateSeparator = String(e.multidateSeparator), e.weekStart %= 7, e.weekEnd = (e.weekStart + 6) % 7; 15315 var g = r.parseFormat(e.format); 15316 e.startDate !== -(1 / 0) && (e.startDate ? e.startDate instanceof Date ? e.startDate = this._local_to_utc(this._zero_time(e.startDate)) : e.startDate = r.parseDate(e.startDate, g, e.language, e.assumeNearbyYear) : e.startDate = -(1 / 0)), e.endDate !== 1 / 0 && (e.endDate ? e.endDate instanceof Date ? e.endDate = this._local_to_utc(this._zero_time(e.endDate)) : e.endDate = r.parseDate(e.endDate, g, e.language, e.assumeNearbyYear) : e.endDate = 1 / 0), e.daysOfWeekDisabled = this._resolveDaysOfWeek(e.daysOfWeekDisabled || []), e.daysOfWeekHighlighted = this._resolveDaysOfWeek(e.daysOfWeekHighlighted || []), e.datesDisabled = e.datesDisabled || [], a.isArray(e.datesDisabled) || (e.datesDisabled = [e.datesDisabled]), e.datesDisabled = a.map(e.datesDisabled, function (a) { 15317 return r.parseDate(a, g, e.language, e.assumeNearbyYear) 15318 }); 15319 var h = String(e.orientation).toLowerCase().split(/\s+/g), 15320 i = e.orientation.toLowerCase(); 15321 if (h = a.grep(h, function (a) { 15322 return /^auto|left|right|top|bottom$/.test(a) 15323 }), e.orientation = { 15324 x: "auto", 15325 y: "auto" 15326 }, i && "auto" !== i) 15327 if (1 === h.length) switch (h[0]) { 15328 case "top": 15329 case "bottom": 15330 e.orientation.y = h[0]; 15331 break; 15332 case "left": 15333 case "right": 15334 e.orientation.x = h[0] 15335 } else i = a.grep(h, function (a) { 15336 return /^left|right$/.test(a) 15337 }), e.orientation.x = i[0] || "auto", i = a.grep(h, function (a) { 15338 return /^top|bottom$/.test(a) 15339 }), e.orientation.y = i[0] || "auto"; 15340 else; 15341 if (e.defaultViewDate) { 15342 var j = e.defaultViewDate.year || (new Date).getFullYear(), 15343 k = e.defaultViewDate.month || 0, 15344 l = e.defaultViewDate.day || 1; 15345 e.defaultViewDate = c(j, k, l) 15346 } else e.defaultViewDate = d() 15347 }, 15348 _events: [], 15349 _secondaryEvents: [], 15350 _applyEvents: function (a) { 15351 for (var c, d, e, f = 0; f < a.length; f++) c = a[f][0], 2 === a[f].length ? (d = b, e = a[f][1]) : 3 === a[f].length && (d = a[f][1], e = a[f][2]), c.on(e, d) 15352 }, 15353 _unapplyEvents: function (a) { 15354 for (var c, d, e, f = 0; f < a.length; f++) c = a[f][0], 2 === a[f].length ? (e = b, d = a[f][1]) : 3 === a[f].length && (e = a[f][1], d = a[f][2]), c.off(d, e) 15355 }, 15356 _buildEvents: function () { 15357 var b = { 15358 keyup: a.proxy(function (b) { 15359 -1 === a.inArray(b.keyCode, [27, 37, 39, 38, 40, 32, 13, 9]) && this.update() 15360 }, this), 15361 keydown: a.proxy(this.keydown, this), 15362 paste: a.proxy(this.paste, this) 15363 }; 15364 this.o.showOnFocus === !0 && (b.focus = a.proxy(this.show, this)), this.isInput ? this._events = [ 15365 [this.element, b] 15366 ] : this.component && this.inputField.length ? this._events = [ 15367 [this.inputField, b], 15368 [this.component, { 15369 click: a.proxy(this.show, this) 15370 }] 15371 ] : this._events = [ 15372 [this.element, { 15373 click: a.proxy(this.show, this), 15374 keydown: a.proxy(this.keydown, this) 15375 }] 15376 ], this._events.push([this.element, "*", { 15377 blur: a.proxy(function (a) { 15378 this._focused_from = a.target 15379 }, this) 15380 }], [this.element, { 15381 blur: a.proxy(function (a) { 15382 this._focused_from = a.target 15383 }, this) 15384 }]), this.o.immediateUpdates && this._events.push([this.element, { 15385 "changeYear changeMonth": a.proxy(function (a) { 15386 this.update(a.date) 15387 }, this) 15388 }]), this._secondaryEvents = [ 15389 [this.picker, { 15390 click: a.proxy(this.click, this) 15391 }], 15392 [this.picker, ".prev, .next", { 15393 click: a.proxy(this.navArrowsClick, this) 15394 }], 15395 [a(window), { 15396 resize: a.proxy(this.place, this) 15397 }], 15398 [a(document), { 15399 "mousedown touchstart": a.proxy(function (a) { 15400 this.element.is(a.target) || this.element.find(a.target).length || this.picker.is(a.target) || this.picker.find(a.target).length || this.isInline || this.hide() 15401 }, this) 15402 }] 15403 ] 15404 }, 15405 _attachEvents: function () { 15406 this._detachEvents(), this._applyEvents(this._events) 15407 }, 15408 _detachEvents: function () { 15409 this._unapplyEvents(this._events) 15410 }, 15411 _attachSecondaryEvents: function () { 15412 this._detachSecondaryEvents(), this._applyEvents(this._secondaryEvents) 15413 }, 15414 _detachSecondaryEvents: function () { 15415 this._unapplyEvents(this._secondaryEvents) 15416 }, 15417 _trigger: function (b, c) { 15418 var d = c || this.dates.get(-1), 15419 e = this._utc_to_local(d); 15420 this.element.trigger({ 15421 type: b, 15422 date: e, 15423 dates: a.map(this.dates, this._utc_to_local), 15424 format: a.proxy(function (a, b) { 15425 0 === arguments.length ? (a = this.dates.length - 1, b = this.o.format) : "string" == typeof a && (b = a, a = this.dates.length - 1), b = b || this.o.format; 15426 var c = this.dates.get(a); 15427 return r.formatDate(c, b, this.o.language) 15428 }, this) 15429 }) 15430 }, 15431 show: function () { 15432 return this.inputField.prop("disabled") || this.inputField.prop("readonly") && this.o.enableOnReadonly === !1 ? void 0 : (this.isInline || this.picker.appendTo(this.o.container), this.place(), this.picker.show(), this._attachSecondaryEvents(), this._trigger("show"), (window.navigator.msMaxTouchPoints || "ontouchstart" in document) && this.o.disableTouchKeyboard && a(this.element).blur(), this) 15433 }, 15434 hide: function () { 15435 return this.isInline || !this.picker.is(":visible") ? this : (this.focusDate = null, this.picker.hide().detach(), this._detachSecondaryEvents(), this.setViewMode(this.o.startView), this.o.forceParse && this.inputField.val() && this.setValue(), this._trigger("hide"), this) 15436 }, 15437 destroy: function () { 15438 return this.hide(), this._detachEvents(), this._detachSecondaryEvents(), this.picker.remove(), delete this.element.data().datepicker, this.isInput || delete this.element.data().date, this 15439 }, 15440 paste: function (b) { 15441 var c; 15442 if (b.originalEvent.clipboardData && b.originalEvent.clipboardData.types && -1 !== a.inArray("text/plain", b.originalEvent.clipboardData.types)) c = b.originalEvent.clipboardData.getData("text/plain"); 15443 else { 15444 if (!window.clipboardData) return; 15445 c = window.clipboardData.getData("Text") 15446 } 15447 this.setDate(c), this.update(), b.preventDefault() 15448 }, 15449 _utc_to_local: function (a) { 15450 return a && new Date(a.getTime() + 6e4 * a.getTimezoneOffset()) 15451 }, 15452 _local_to_utc: function (a) { 15453 return a && new Date(a.getTime() - 6e4 * a.getTimezoneOffset()) 15454 }, 15455 _zero_time: function (a) { 15456 return a && new Date(a.getFullYear(), a.getMonth(), a.getDate()) 15457 }, 15458 _zero_utc_time: function (a) { 15459 return a && c(a.getUTCFullYear(), a.getUTCMonth(), a.getUTCDate()) 15460 }, 15461 getDates: function () { 15462 return a.map(this.dates, this._utc_to_local) 15463 }, 15464 getUTCDates: function () { 15465 return a.map(this.dates, function (a) { 15466 return new Date(a) 15467 }) 15468 }, 15469 getDate: function () { 15470 return this._utc_to_local(this.getUTCDate()) 15471 }, 15472 getUTCDate: function () { 15473 var a = this.dates.get(-1); 15474 return a !== b ? new Date(a) : null 15475 }, 15476 clearDates: function () { 15477 this.inputField.val(""), this.update(), this._trigger("changeDate"), this.o.autoclose && this.hide() 15478 }, 15479 setDates: function () { 15480 var b = a.isArray(arguments[0]) ? arguments[0] : arguments; 15481 return this.update.apply(this, b), this._trigger("changeDate"), this.setValue(), this 15482 }, 15483 setUTCDates: function () { 15484 var b = a.isArray(arguments[0]) ? arguments[0] : arguments; 15485 return this.setDates.apply(this, a.map(b, this._utc_to_local)), this 15486 }, 15487 setDate: f("setDates"), 15488 setUTCDate: f("setUTCDates"), 15489 remove: f("destroy"), 15490 setValue: function () { 15491 var a = this.getFormattedDate(); 15492 return this.inputField.val(a), this 15493 }, 15494 getFormattedDate: function (c) { 15495 c === b && (c = this.o.format); 15496 var d = this.o.language; 15497 return a.map(this.dates, function (a) { 15498 return r.formatDate(a, c, d) 15499 }).join(this.o.multidateSeparator) 15500 }, 15501 getStartDate: function () { 15502 return this.o.startDate 15503 }, 15504 setStartDate: function (a) { 15505 return this._process_options({ 15506 startDate: a 15507 }), this.update(), this.updateNavArrows(), this 15508 }, 15509 getEndDate: function () { 15510 return this.o.endDate 15511 }, 15512 setEndDate: function (a) { 15513 return this._process_options({ 15514 endDate: a 15515 }), this.update(), this.updateNavArrows(), this 15516 }, 15517 setDaysOfWeekDisabled: function (a) { 15518 return this._process_options({ 15519 daysOfWeekDisabled: a 15520 }), this.update(), this 15521 }, 15522 setDaysOfWeekHighlighted: function (a) { 15523 return this._process_options({ 15524 daysOfWeekHighlighted: a 15525 }), this.update(), this 15526 }, 15527 setDatesDisabled: function (a) { 15528 return this._process_options({ 15529 datesDisabled: a 15530 }), this.update(), this 15531 }, 15532 place: function () { 15533 if (this.isInline) return this; 15534 var b = this.picker.outerWidth(), 15535 c = this.picker.outerHeight(), 15536 d = 10, 15537 e = a(this.o.container), 15538 f = e.width(), 15539 g = "body" === this.o.container ? a(document).scrollTop() : e.scrollTop(), 15540 h = e.offset(), 15541 i = []; 15542 this.element.parents().each(function () { 15543 var b = a(this).css("z-index"); 15544 "auto" !== b && 0 !== b && i.push(parseInt(b)) 15545 }); 15546 var j = Math.max.apply(Math, i) + this.o.zIndexOffset, 15547 k = this.component ? this.component.parent().offset() : this.element.offset(), 15548 l = this.component ? this.component.outerHeight(!0) : this.element.outerHeight(!1), 15549 m = this.component ? this.component.outerWidth(!0) : this.element.outerWidth(!1), 15550 n = k.left - h.left, 15551 o = k.top - h.top; 15552 "body" !== this.o.container && (o += g), this.picker.removeClass("datepicker-orient-top datepicker-orient-bottom datepicker-orient-right datepicker-orient-left"), "auto" !== this.o.orientation.x ? (this.picker.addClass("datepicker-orient-" + this.o.orientation.x), "right" === this.o.orientation.x && (n -= b - m)) : k.left < 0 ? (this.picker.addClass("datepicker-orient-left"), n -= k.left - d) : n + b > f ? (this.picker.addClass("datepicker-orient-right"), n += m - b) : this.picker.addClass("datepicker-orient-left"); 15553 var p, q = this.o.orientation.y; 15554 if ("auto" === q && (p = -g + o - c, q = 0 > p ? "bottom" : "top"), this.picker.addClass("datepicker-orient-" + q), "top" === q ? o -= c + parseInt(this.picker.css("padding-top")) : o += l, this.o.rtl) { 15555 var r = f - (n + m); 15556 this.picker.css({ 15557 top: o, 15558 right: r, 15559 zIndex: j 15560 }) 15561 } else this.picker.css({ 15562 top: o, 15563 left: n, 15564 zIndex: j 15565 }); 15566 return this 15567 }, 15568 _allow_update: !0, 15569 update: function () { 15570 if (!this._allow_update) return this; 15571 var b = this.dates.copy(), 15572 c = [], 15573 d = !1; 15574 return arguments.length ? (a.each(arguments, a.proxy(function (a, b) { 15575 b instanceof Date && (b = this._local_to_utc(b)), c.push(b) 15576 }, this)), d = !0) : (c = this.isInput ? this.element.val() : this.element.data("date") || this.inputField.val(), c = c && this.o.multidate ? c.split(this.o.multidateSeparator) : [c], delete this.element.data().date), c = a.map(c, a.proxy(function (a) { 15577 return r.parseDate(a, this.o.format, this.o.language, this.o.assumeNearbyYear) 15578 }, this)), c = a.grep(c, a.proxy(function (a) { 15579 return !this.dateWithinRange(a) || !a 15580 }, this), !0), this.dates.replace(c), this.dates.length ? this.viewDate = new Date(this.dates.get(-1)) : this.viewDate < this.o.startDate ? this.viewDate = new Date(this.o.startDate) : this.viewDate > this.o.endDate ? this.viewDate = new Date(this.o.endDate) : this.viewDate = this.o.defaultViewDate, d ? (this.setValue(), this.element.change()) : this.dates.length && String(b) !== String(this.dates) && d && (this._trigger("changeDate"), this.element.change()), !this.dates.length && b.length && (this._trigger("clearDate"), this.element.change()), this.fill(), this 15581 }, 15582 fillDow: function () { 15583 var b = this.o.weekStart, 15584 c = "<tr>"; 15585 for (this.o.calendarWeeks && (c += '<th class="cw"> </th>'); b < this.o.weekStart + 7;) c += '<th class="dow', -1 !== a.inArray(b, this.o.daysOfWeekDisabled) && (c += " disabled"), c += '">' + q[this.o.language].daysMin[b++ % 7] + "</th>"; 15586 c += "</tr>", this.picker.find(".datepicker-days thead").append(c) 15587 }, 15588 fillMonths: function () { 15589 for (var a = this._utc_to_local(this.viewDate), b = "", c = 0; 12 > c;) { 15590 var d = a && a.getMonth() === c ? " focused" : ""; 15591 b += '<span class="month' + d + '">' + q[this.o.language].monthsShort[c++] + "</span>" 15592 } 15593 this.picker.find(".datepicker-months td").html(b) 15594 }, 15595 setRange: function (b) { 15596 b && b.length ? this.range = a.map(b, function (a) { 15597 return a.valueOf() 15598 }) : delete this.range, this.fill() 15599 }, 15600 getClassNames: function (b) { 15601 var c = [], 15602 f = this.viewDate.getUTCFullYear(), 15603 g = this.viewDate.getUTCMonth(), 15604 h = d(); 15605 return b.getUTCFullYear() < f || b.getUTCFullYear() === f && b.getUTCMonth() < g ? c.push("old") : (b.getUTCFullYear() > f || b.getUTCFullYear() === f && b.getUTCMonth() > g) && c.push("new"), this.focusDate && b.valueOf() === this.focusDate.valueOf() && c.push("focused"), this.o.todayHighlight && e(b, h) && c.push("today"), -1 !== this.dates.contains(b) && c.push("active"), this.dateWithinRange(b) || c.push("disabled"), this.dateIsDisabled(b) && c.push("disabled", "disabled-date"), -1 !== a.inArray(b.getUTCDay(), this.o.daysOfWeekHighlighted) && c.push("highlighted"), this.range && (b > this.range[0] && b < this.range[this.range.length - 1] && c.push("range"), -1 !== a.inArray(b.valueOf(), this.range) && c.push("selected"), b.valueOf() === this.range[0] && c.push("range-start"), b.valueOf() === this.range[this.range.length - 1] && c.push("range-end")), c 15606 }, 15607 _fill_yearsView: function (c, d, e, f, g, h, i, j) { 15608 var k, l, m, n, o, p, q, r, s, t, u; 15609 for (k = "", l = this.picker.find(c), m = parseInt(g / e, 10) * e, o = parseInt(h / f,
1560910) * f, p = parseInt(i / f, 10) * f, n = a.map(this.dates, function (a) { 15610 return parseInt(a.getUTCFullYear() / f, 10) * f 15611 }), l.find(".datepicker-switch").text(m + "-" + (m + 9 * f)), q = m - f, r = -1; 11 > r; r += 1) s = [d], t = null, -1 === r ? s.push("old") : 10 === r && s.push("new"), -1 !== a.inArray(q, n) && s.push("active"), (o > q || q > p) && s.push("disabled"), q === this.viewDate.getFullYear() && s.push("focused"), j !== a.noop && (u = j(new Date(q, 0, 1)), u === b ? u = {} : "boolean" == typeof u ? u = { 15612 enabled: u 15613 } : "string" == typeof u && (u = { 15614 classes: u 15615 }), u.enabled === !1 && s.push("disabled"), u.classes && (s = s.concat(u.classes.split(/\s+/))), u.tooltip && (t = u.tooltip)), k += '<span class="' + s.join(" ") + '"' + (t ? ' title="' + t + '"' : "") + ">" + q + "</span>", q += f; 15616 l.find("td").html(k) 15617 }, 15618 fill: function () { 15619 var d, e, f = new Date(this.viewDate), 15620 g = f.getUTCFullYear(), 15621 h = f.getUTCMonth(), 15622 i = this.o.startDate !== -(1 / 0) ? this.o.startDate.getUTCFullYear() : -(1 / 0), 15623 j = this.o.startDate !== -(1 / 0) ? this.o.startDate.getUTCMonth() : -(1 / 0), 15624 k = this.o.endDate !== 1 / 0 ? this.o.endDate.getUTCFullYear() : 1 / 0, 15625 l = this.o.endDate !== 1 / 0 ? this.o.endDate.getUTCMonth() : 1 / 0, 15626 m = q[this.o.language].today || q.en.today || "", 15627 n = q[this.o.language].clear || q.en.clear || "", 15628 o = q[this.o.language].titleFormat || q.en.titleFormat; 15629 if (!isNaN(g) && !isNaN(h)) { 15630 this.picker.find(".datepicker-days .datepicker-switch").text(r.formatDate(f, o, this.o.language)), this.picker.find("tfoot .today").text(m).toggle(this.o.todayBtn !== !1), this.picker.find("tfoot .clear").text(n).toggle(this.o.clearBtn !== !1), this.picker.find("thead .datepicker-title").text(this.o.title).toggle("" !== this.o.title), this.updateNavArrows(), this.fillMonths(); 15631 var p = c(g, h, 0), 15632 s = p.getUTCDate(); 15633 p.setUTCDate(s - (p.getUTCDay() - this.o.weekStart + 7) % 7); 15634 var t = new Date(p); 15635 p.getUTCFullYear() < 100 && t.setUTCFullYear(p.getUTCFullYear()), t.setUTCDate(t.getUTCDate() + 42), t = t.valueOf(); 15636 for (var u, v, w = []; p.valueOf() < t;) { 15637 if (u = p.getUTCDay(), u === this.o.weekStart && (w.push("<tr>"), this.o.calendarWeeks)) { 15638 var x = new Date(+p + (this.o.weekStart - u - 7) % 7 * 864e5), 15639 y = new Date(Number(x) + (11 - x.getUTCDay()) % 7 * 864e5), 15640 z = new Date(Number(z = c(y.getUTCFullYear(), 0, 1)) + (11 - z.getUTCDay()) % 7 * 864e5), 15641 A = (y - z) / 864e5 / 7 + 1; 15642 w.push('<td class="cw">' + A + "</td>") 15643 } 15644 v = this.getClassNames(p), v.push("day"), this.o.beforeShowDay !== a.noop && (e = this.o.beforeShowDay(this._utc_to_local(p)), e === b ? e = {} : "boolean" == typeof e ? e = { 15645 enabled: e 15646 } : "string" == typeof e && (e = { 15647 classes: e 15648 }), e.enabled === !1 && v.push("disabled"), e.classes && (v = v.concat(e.classes.split(/\s+/))), e.tooltip && (d = e.tooltip)), v = a.unique(v), w.push('<td class="' + v.join(" ") + '"' + (d ? ' title="' + d + '"' : "") + (this.o.dateCells ? ' data-date="' + p.getTime().toString() + '"' : "") + ">" + p.getUTCDate() + "</td>"), d = null, u === this.o.weekEnd && w.push("</tr>"), p.setUTCDate(p.getUTCDate() + 1) 15649 } 15650 this.picker.find(".datepicker-days tbody").html(w.join("")); 15651 var B = q[this.o.language].monthsTitle || q.en.monthsTitle || "Months", 15652 C = this.picker.find(".datepicker-months").find(".datepicker-switch").text(this.o.maxViewMode < 2 ? B : g).end().find("tbody span").removeClass("active"); 15653 if (a.each(this.dates, function (a, b) { 15654 b.getUTCFullYear() === g && C.eq(b.getUTCMonth()).addClass("active") 15655 }), (i > g || g > k) && C.addClass("disabled"), g === i && C.slice(0, j).addClass("disabled"), g === k && C.slice(l + 1).addClass("disabled"), this.o.beforeShowMonth !== a.noop) { 15656 var D = this; 15657 a.each(C, function (c, d) { 15658 var e = new Date(g, c, 1), 15659 f = D.o.beforeShowMonth(e); 15660 f === b ? f = {} : "boolean" == typeof f ? f = { 15661 enabled: f 15662 } : "string" == typeof f && (f = { 15663 classes: f 15664 }), f.enabled !== !1 || a(d).hasClass("disabled") || a(d).addClass("disabled"), f.classes && a(d).addClass(f.classes), f.tooltip && a(d).prop("title", f.tooltip) 15665 }) 15666 } 15667 this._fill_yearsView(".datepicker-years", "year", 10, 1, g, i, k, this.o.beforeShowYear), this._fill_yearsView(".datepicker-decades", "decade", 100, 10, g, i, k, this.o.beforeShowDecade), this._fill_yearsView(".datepicker-centuries", "century", 1e3, 100, g, i, k, this.o.beforeShowCentury) 15668 } 15669 }, 15670 updateNavArrows: function () { 15671 if (this._allow_update) { 15672 var a, b, c = new Date(this.viewDate), 15673 d = c.getUTCFullYear(), 15674 e = c.getUTCMonth(); 15675 switch (this.viewMode) { 15676 case 0: 15677 a = this.o.startDate !== -(1 / 0) && d <= this.o.startDate.getUTCFullYear() && e <= this.o.startDate.getUTCMonth(), b = this.o.endDate !== 1 / 0 && d >= this.o.endDate.getUTCFullYear() && e >= this.o.endDate.getUTCMonth(); 15678 break; 15679 case 1: 15680 case 2: 15681 case 3: 15682 case 4: 15683 a = this.o.startDate !== -(1 / 0) && d <= this.o.startDate.getUTCFullYear(), b = this.o.endDate !== 1 / 0 && d >= this.o.endDate.getUTCFullYear() 15684 } 15685 this.picker.find(".prev").toggleClass("disabled", a), this.picker.find(".next").toggleClass("disabled", b) 15686 } 15687 }, 15688 click: function (b) { 15689 b.preventDefault(), b.stopPropagation(); 15690 var e, f, g, h, i;
vendor: 11,755 bytes, lines 15691-15903
15691 e = a(b.target), e.hasClass("datepicker-switch") && this.setViewMode(this.viewMode + 1), e.hasClass("today") && !e.hasClass("day") && (this.setViewMode(0), this._setDate(d(), "linked" === this.o.todayBtn ? null : "view")), e.hasClass("clear") && this.clearDates(), e.hasClass("disabled") || (e.hasClass("day") && (g = Number(e.text()), h = this.viewDate.getUTCFullYear(), i = this.viewDate.getUTCMonth(), (e.hasClass("old") || e.hasClass("new")) && (f = e.hasClass("old") ? -1 : 1, i = (i + f + 12) % 12, (-1 === f && 11 === i || 1 === f && 0 === i) && (h += f, this._trigger("changeYear", this.viewDate)), this._trigger("changeMonth", this.viewDate)), this._setDate(c(h, i, g))), (e.hasClass("month") || e.hasClass("year") || e.hasClass("decade") || e.hasClass("century")) && (this.viewDate.setUTCDate(1), g = 1, 1 === this.viewMode ? (i = e.parent().find("span").index(e), h = this.viewDate.getUTCFullYear(), this.viewDate.setUTCMonth(i)) : (i = 0, h = Number(e.text()), this.viewDate.setUTCFullYear(h)), this._trigger(r.viewModes[this.viewMode - 1].e, this.viewDate), this.viewMode === this.o.minViewMode ? this._setDate(c(h, i, g)) : (this.setViewMode(this.viewMode - 1), this.fill()))), this.picker.is(":visible") && this._focused_from && this._focused_from.focus(), delete this._focused_from 15692 }, 15693 navArrowsClick: function (b) { 15694 var c = a(b.target), 15695 d = c.hasClass("prev") ? -1 : 1; 15696 0 !== this.viewMode && (d *= 12 * r.viewModes[this.viewMode].navStep), this.viewDate = this.moveMonth(this.viewDate, d), this._trigger(r.viewModes[this.viewMode].e, this.viewDate), this.fill() 15697 }, 15698 _toggle_multidate: function (a) { 15699 var b = this.dates.contains(a); 15700 if (a || this.dates.clear(), -1 !== b ? (this.o.multidate === !0 || this.o.multidate > 1 || this.o.toggleActive) && this.dates.remove(b) : this.o.multidate === !1 ? (this.dates.clear(), this.dates.push(a)) : this.dates.push(a), "number" == typeof this.o.multidate) 15701 for (; this.dates.length > this.o.multidate;) this.dates.remove(0) 15702 }, 15703 _setDate: function (a, b) { 15704 b && "date" !== b || this._toggle_multidate(a && new Date(a)), b && "view" !== b || (this.viewDate = a && new Date(a)), this.fill(), this.setValue(), b && "view" === b || this._trigger("changeDate"), this.inputField.trigger("change"), !this.o.autoclose || b && "date" !== b || this.hide() 15705 }, 15706 moveDay: function (a, b) { 15707 var c = new Date(a); 15708 return c.setUTCDate(a.getUTCDate() + b), c 15709 }, 15710 moveWeek: function (a, b) { 15711 return this.moveDay(a, 7 * b) 15712 }, 15713 moveMonth: function (a, b) { 15714 if (!g(a)) return this.o.defaultViewDate; 15715 if (!b) return a; 15716 var c, d, e = new Date(a.valueOf()), 15717 f = e.getUTCDate(), 15718 h = e.getUTCMonth(), 15719 i = Math.abs(b); 15720 if (b = b > 0 ? 1 : -1, 1 === i) d = -1 === b ? function () { 15721 return e.getUTCMonth() === h 15722 } : function () { 15723 return e.getUTCMonth() !== c 15724 }, c = h + b, e.setUTCMonth(c), c = (c + 12) % 12; 15725 else { 15726 for (var j = 0; i > j; j++) e = this.moveMonth(e, b); 15727 c = e.getUTCMonth(), e.setUTCDate(f), d = function () { 15728 return c !== e.getUTCMonth() 15729 } 15730 } 15731 for (; d();) e.setUTCDate(--f), e.setUTCMonth(c); 15732 return e 15733 }, 15734 moveYear: function (a, b) { 15735 return this.moveMonth(a, 12 * b) 15736 }, 15737 moveAvailableDate: function (a, b, c) { 15738 do { 15739 if (a = this[c](a, b), !this.dateWithinRange(a)) return !1; 15740 c = "moveDay" 15741 } while (this.dateIsDisabled(a)); 15742 return a 15743 }, 15744 weekOfDateIsDisabled: function (b) { 15745 return -1 !== a.inArray(b.getUTCDay(), this.o.daysOfWeekDisabled) 15746 }, 15747 dateIsDisabled: function (b) { 15748 return this.weekOfDateIsDisabled(b) || a.grep(this.o.datesDisabled, function (a) { 15749 return e(b, a) 15750 }).length > 0 15751 }, 15752 dateWithinRange: function (a) { 15753 return a >= this.o.startDate && a <= this.o.endDate 15754 }, 15755 keydown: function (a) { 15756 if (!this.picker.is(":visible")) return void ((40 === a.keyCode || 27 === a.keyCode) && (this.show(), a.stopPropagation())); 15757 var b, c, d = !1, 15758 e = this.focusDate || this.viewDate; 15759 switch (a.keyCode) { 15760 case 27: 15761 this.focusDate ? (this.focusDate = null, this.viewDate = this.dates.get(-1) || this.viewDate, this.fill()) : this.hide(), a.preventDefault(), a.stopPropagation(); 15762 break; 15763 case 37: 15764 case 38: 15765 case 39: 15766 case 40: 15767 if (!this.o.keyboardNavigation || 7 === this.o.daysOfWeekDisabled.length) break; 15768 b = 37 === a.keyCode || 38 === a.keyCode ? -1 : 1, 0 === this.viewMode ? a.ctrlKey ? (c = this.moveAvailableDate(e, b, "moveYear"), c && this._trigger("changeYear", this.viewDate)) : a.shiftKey ? (c = this.moveAvailableDate(e, b, "moveMonth"), c && this._trigger("changeMonth", this.viewDate)) : 37 === a.keyCode || 39 === a.keyCode ? c = this.moveAvailableDate(e, b, "moveDay") : this.weekOfDateIsDisabled(e) || (c = this.moveAvailableDate(e, b, "moveWeek")) : 1 === this.viewMode ? ((38 === a.keyCode || 40 === a.keyCode) && (b = 4 * b), c = this.moveAvailableDate(e, b, "moveMonth")) : 2 === this.viewMode && ((38 === a.keyCode || 40 === a.keyCode) && (b = 4 * b), c = this.moveAvailableDate(e, b, "moveYear")), c && (this.focusDate = this.viewDate = c, this.setValue(), this.fill(), a.preventDefault()); 15769 break; 15770 case 13: 15771 if (!this.o.forceParse) break; 15772 e = this.focusDate || this.dates.get(-1) || this.viewDate, this.o.keyboardNavigation && (this._toggle_multidate(e), d = !0), this.focusDate = null, this.viewDate = this.dates.get(-1) || this.viewDate, this.setValue(), this.fill(), this.picker.is(":visible") && (a.preventDefault(), a.stopPropagation(), this.o.autoclose && this.hide()); 15773 break; 15774 case 9: 15775 this.focusDate = null, this.viewDate = this.dates.get(-1) || this.viewDate, this.fill(), this.hide() 15776 } 15777 d && (this.dates.length ? this._trigger("changeDate") : this._trigger("clearDate"), this.inputField.trigger("change")) 15778 }, 15779 setViewMode: function (a) { 15780 this.viewMode = a, this.picker.children("div").hide().filter(".datepicker-" + r.viewModes[this.viewMode].clsName).show(), this.updateNavArrows() 15781 } 15782 }; 15783 var l = function (b, c) { 15784 a.data(b, "datepicker", this), this.element = a(b), this.inputs = a.map(c.inputs, function (a) { 15785 return a.jquery ? a[0] : a 15786 }), delete c.inputs, this.keepEmptyValues = c.keepEmptyValues, delete c.keepEmptyValues, n.call(a(this.inputs), c).on("changeDate", a.proxy(this.dateUpdated, this)), this.pickers = a.map(this.inputs, function (b) { 15787 return a.data(b, "datepicker") 15788 }), this.updateDates() 15789 }; 15790 l.prototype = { 15791 updateDates: function () { 15792 this.dates = a.map(this.pickers, function (a) { 15793 return a.getUTCDate() 15794 }), this.updateRanges() 15795 }, 15796 updateRanges: function () { 15797 var b = a.map(this.dates, function (a) { 15798 return a.valueOf() 15799 }); 15800 a.each(this.pickers, function (a, c) { 15801 c.setRange(b) 15802 }) 15803 }, 15804 dateUpdated: function (c) { 15805 if (!this.updating) { 15806 this.updating = !0; 15807 var d = a.data(c.target, "datepicker"); 15808 if (d !== b) { 15809 var e = d.getUTCDate(), 15810 f = this.keepEmptyValues, 15811 g = a.inArray(c.target, this.inputs), 15812 h = g - 1, 15813 i = g + 1, 15814 j = this.inputs.length; 15815 if (-1 !== g) { 15816 if (a.each(this.pickers, function (a, b) { 15817 b.getUTCDate() || b !== d && f || b.setUTCDate(e) 15818 }), e < this.dates[h]) 15819 for (; h >= 0 && e < this.dates[h];) this.pickers[h--].setUTCDate(e); 15820 else if (e > this.dates[i]) 15821 for (; j > i && e > this.dates[i];) this.pickers[i++].setUTCDate(e); 15822 this.updateDates(), delete this.updating 15823 } 15824 } 15825 } 15826 }, 15827 destroy: function () { 15828 a.map(this.pickers, function (a) { 15829 a.destroy() 15830 }), delete this.element.data().datepicker 15831 }, 15832 remove: f("destroy") 15833 }; 15834 var m = a.fn.datepicker, 15835 n = function (c) { 15836 var d = Array.apply(null, arguments); 15837 d.shift(); 15838 var e; 15839 if (this.each(function () { 15840 var b = a(this), 15841 f = b.data("datepicker"), 15842 g = "object" == typeof c && c; 15843 if (!f) { 15844 var j = h(this, "date"), 15845 m = a.extend({}, o, j, g), 15846 n = i(m.language), 15847 p = a.extend({}, o, n, j, g); 15848 b.hasClass("input-daterange") || p.inputs ? (a.extend(p, { 15849 inputs: p.inputs || b.find("input").toArray() 15850 }), f = new l(this, p)) : f = new k(this, p), b.data("datepicker", f) 15851 } 15852 "string" == typeof c && "function" == typeof f[c] && (e = f[c].apply(f, d)) 15853 }), e === b || e instanceof k || e instanceof l) return this; 15854 if (this.length > 1) throw new Error("Using only allowed for the collection of a single element (" + c + " function)"); 15855 return e 15856 }; 15857 a.fn.datepicker = n; 15858 var o = a.fn.datepicker.defaults = { 15859 assumeNearbyYear: !1, 15860 autoclose: !1, 15861 beforeShowDay: a.noop, 15862 beforeShowMonth: a.noop, 15863 beforeShowYear: a.noop, 15864 beforeShowDecade: a.noop, 15865 beforeShowCentury: a.noop, 15866 calendarWeeks: !1, 15867 clearBtn: !1, 15868 toggleActive: !1, 15869 daysOfWeekDisabled: [], 15870 daysOfWeekHighlighted: [], 15871 datesDisabled: [], 15872 endDate: 1 / 0, 15873 forceParse: !0, 15874 format: "mm/dd/yyyy", 15875 keepEmptyValues: !1, 15876 keyboardNavigation: !0, 15877 language: "en", 15878 minViewMode: 0, 15879 maxViewMode: 4, 15880 multidate: !1, 15881 multidateSeparator: ",", 15882 orientation: "auto", 15883 rtl: !1, 15884 startDate: -(1 / 0), 15885 startView: 0, 15886 todayBtn: !1, 15887 todayHighlight: !1, 15888 weekStart: 0, 15889 disableTouchKeyboard: !1, 15890 enableOnReadonly: !0, 15891 showOnFocus: !0, 15892 zIndexOffset: 10, 15893 container: "body", 15894 immediateUpdates: !1, 15895 dateCells: !1, 15896 title: "", 15897 templates: { 15898 leftArrow: "«", 15899 rightArrow: "»" 15900 } 15901 }, 15902 p = a.fn.datepicker.locale_opts = ["format", "rtl", "weekStart"]; 15903 a.fn.datepicker.Constructor = k;
15904 var q = a.fn.datepicker.dates = { 15905 en: { 15906 days: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"], 15907 daysShort: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], 15908 daysMin: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"], 15909 months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], 15910 monthsShort: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], 15911 today: "Today", 15912 clear: "Clear", 15913 titleFormat: "MM yyyy" 15914 } 15915 }, 15916 r = { 15917 viewModes: [{ 15918 names: ["days", "month"], 15919 clsName: "days", 15920 e: "changeMonth" 15921 }, { 15922 names: ["months", "year"], 15923 clsName: "months", 15924 e: "changeYear", 15925 navStep: 1 15926 }, { 15927 names: ["years", "decade"], 15928 clsName: "years", 15929 e: "changeDecade", 15930 navStep: 10 15931 }, { 15932 names: ["decades", "century"], 15933 clsName: "decades", 15934 e: "changeCentury", 15935 navStep: 100 15936 }, { 15937 names: ["centuries", "millennium"], 15938 clsName: "centuries", 15939 e: "changeMillennium", 15940 navStep: 1e3 15941 }], 15942 validParts: /dd?|DD?|mm?|MM?|yy(?:yy)?/g, 15943 nonpunctuation: /[^ -\/:-@\u5e74\u6708\u65e5\[-`{-~\t\n\r]+/g, 15944 parseFormat: function (a) { 15945 if ("function" == typeof a.toValue && "function" == typeof a.toDisplay) return a; 15946 var b = a.replace(this.validParts, "\x00").split("\x00"), 15947 c = a.match(this.validParts); 15948 if (!b || !b.length || !c || 0 === c.length) throw new Error("Invalid date format."); 15949 return { 15950 separators: b, 15951 parts: c 15952 } 15953 }, 15954 parseDate: function (e, f, g, h) { 15955 function i(a, b) { 15956 return b === !0 && (b = 10), 100 > a && (a += 2e3, a > (new Date).getFullYear() + b && (a -= 100)), a 15957 } 15958 15959 function j() { 15960 var a = this.slice(0, s[n].length), 15961 b = s[n].slice(0, a.length); 15962 return a.toLowerCase() === b.toLowerCase() 15963 } 15964 if (!e) return b; 15965 if (e instanceof Date) return e; 15966 if ("string" == typeof f && (f = r.parseFormat(f)), f.toValue) return f.toValue(e, f, g); 15967 var l, m, n, o, p = /([\-+]\d+)([dmwy])/, 15968 s = e.match(/([\-+]\d+)([dmwy])/g), 15969 t = { 15970 d: "moveDay", 15971 m: "moveMonth", 15972 w: "moveWeek", 15973 y: "moveYear" 15974 }, 15975 u = { 15976 yesterday: "-1d", 15977 today: "+0d", 15978 tomorrow: "+1d" 15979 }; 15980 if (/^[\-+]\d+[dmwy]([\s,]+[\-+]\d+[dmwy])*$/.test(e)) { 15981 for (e = new Date, n = 0; n < s.length; n++) l = p.exec(s[n]), m = parseInt(l[1]), o = t[l[2]], e = k.prototype[o](e, m); 15982 return c(e.getUTCFullYear(), e.getUTCMonth(), e.getUTCDate()) 15983 } 15984 if (e in u && (e = u[e], s = e.match(/([\-+]\d+)([dmwy])/g), /^[\-+]\d+[dmwy]([\s,]+[\-+]\d+[dmwy])*$/.test(e))) { 15985 for (e = new Date, n = 0; n < s.length; n++) l = p.exec(s[n]), m = parseInt(l[1]), o = t[l[2]], e = k.prototype[o](e, m); 15986 return c(e.getUTCFullYear(), e.getUTCMonth(), e.getUTCDate()) 15987 } 15988 s = e && e.match(this.nonpunctuation) || [], e = new Date; 15989 var v, w, x = {}, 15990 y = ["yyyy", "yy", "M", "MM", "m", "mm", "d", "dd"], 15991 z = { 15992 yyyy: function (a, b) { 15993 return a.setUTCFullYear(h ? i(b, h) : b) 15994 }, 15995 m: function (a, b) { 15996 if (isNaN(a)) return a; 15997 for (b -= 1; 0 > b;) b += 12; 15998 for (b %= 12, a.setUTCMonth(b); a.getUTCMonth() !== b;
15998) a.setUTCDate(a.getUTCDate() - 1); 15999 return a 16000 }, 16001 d: function (a, b) { 16002 return a.setUTCDate(b) 16003 } 16004 }; 16005 z.yy = z.yyyy, z.M = z.MM = z.mm = z.m, z.dd = z.d, e = d(); 16006 var A = f.parts.slice(); 16007 if (s.length !== A.length && (A = a(A).filter(function (b, c) { 16008 return -1 !== a.inArray(c, y) 16009 }).toArray()), s.length === A.length) { 16010 var B; 16011 for (n = 0, B = A.length; B > n; n++) { 16012 if (v = parseInt(s[n], 10), l = A[n], isNaN(v)) switch (l) { 16013 case "MM": 16014 w = a(q[g].months).filter(j), v = a.inArray(w[0], q[g].months) + 1; 16015 break; 16016 case "M": 16017 w = a(q[g].monthsShort).filter(j), v = a.inArray(w[0], q[g].monthsShort) + 1 16018 } 16019 x[l] = v 16020 } 16021 var C, D; 16022 for (n = 0; n < y.length; n++) D = y[n], D in x && !isNaN(x[D]) && (C = new Date(e), z[D](C, x[D]), isNaN(C) || (e = C)) 16023 } 16024 return e 16025 }, 16026 formatDate: function (b, c, d) { 16027 if (!b) return ""; 16028 if ("string" == typeof c && (c = r.parseFormat(c)), c.toDisplay) return c.toDisplay(b, c, d); 16029 var e = { 16030 d: b.getUTCDate(), 16031 D: q[d].daysShort[b.getUTCDay()], 16032 DD: q[d].days[b.getUTCDay()], 16033 m: b.getUTCMonth() + 1, 16034 M: q[d].monthsShort[b.getUTCMonth()], 16035 MM: q[d].months[b.getUTCMonth()], 16036 yy: b.getUTCFullYear().toString().substring(2), 16037 yyyy: b.getUTCFullYear() 16038 }; 16039 e.dd = (e.d < 10 ? "0" : "") + e.d, e.mm = (e.m < 10 ? "0" : "") + e.m, b = []; 16040 for (var f = a.extend([], c.separators), g = 0, h = c.parts.length; h >= g; g++) f.length && b.push(f.shift()), b.push(e[c.parts[g]]); 16041 return b.join("") 16042 }, 16043 headTemplate: '<thead><tr><th colspan="7" class="datepicker-title"></th></tr><tr><th class="prev">«</th><th colspan="5" class="datepicker-switch"></th><th class="next">»</th></tr></thead>', 16044 contTemplate: '<tbody><tr><td colspan="7"></td></tr></tbody>', 16045 footTemplate: '<tfoot><tr><th colspan="7" class="today"></th></tr><tr><th colspan="7" class="clear"></th></tr></tfoot>' 16046 }; 16047 r.template = '<div class="datepicker"><div class="datepicker-days"><table class="table-condensed">' + r.headTemplate + "<tbody></tbody>" + r.footTemplate + '</table></div><div class="datepicker-months"><table class="table-condensed">' + r.headTemplate + r.contTemplate + r.footTemplate + '</table></div><div class="datepicker-years"><table class="table-condensed">' + r.headTemplate + r.contTemplate + r.footTemplate + '</table></div><div class="datepicker-decades"><table class="table-condensed">' + r.headTemplate + r.contTemplate + r.footTemplate + '</table></div><div class="datepicker-centuries"><table class="table-condensed">' + r.headTemplate + r.contTemplate + r.footTemplate + "</table></div></div>", 16048 a.fn.datepicker.DPGlobal = r, a.fn.datepicker.noConflict = function () { 16049 return a.fn.datepicker = m, this 16050 }, a.fn.datepicker.version = "1.7.0-dev", a(document).on("focus.datepicker.data-api click.datepicker.data-api", '[data-provide="datepicker"]', function (b) { 16051 var c = a(this); 16052 c.data("datepicker") || (b.preventDefault(), n.call(c, "show")) 16053 }), a(function () { 16054 n.call(a('[data-provide="datepicker-inline"]')) 16055 }) 16056}); 16057 16058 16059 16060/*! 16061 * jquery-timepicker v1.11.1 - A jQuery timepicker plugin inspired by Google Calendar. It supports both mouse and keyboard navigation. 16062 * Copyright (c) 2016 Jon Thornton - http://jonthornton.github.com/jquery-timepicker/ 16063 * License: MIT 16064 */ 16065 16066! function (a) { 16067 "object" == typeof exports && exports && "object" == typeof module && module && module.exports === exports ? a(require("jquery")) : "function" == typeof define && define.amd ? define(["jquery"], a) : a(jQuery) 16068}(function (a) { 16069 function b(a) { 16070 var b = a[0]; 16071 return b.offsetWidth > 0 && b.offsetHeight > 0 16072 } 16073 16074 function c(b) { 16075 if (b.minTime && (b.minTime = t(b.minTime)), b.maxTime && (b.maxTime = t(b.maxTime)), b.durationTime && "function" != typeof b.durationTime && (b.durationTime = t(b.durationTime)), "now" == b.scrollDefault) b.scrollDefault = function () { 16076 return b.roundingFunction(t(new Date), b) 16077 }; 16078 else if (b.scrollDefault && "function" != typeof b.scrollDefault) { 16079 var c = b.scrollDefault; 16080 b.scrollDefault = function () { 16081 return b.roundingFunction(t(c), b) 16082 } 16083 } else b.minTime && (b.scrollDefault = function () { 16084 return b.roundingFunction(b.minTime, b) 16085 }); 16086 if ("string" === a.type(b.timeFormat) && b.timeFormat.match(/[gh]/) && (b._twelveHourTime = !0), b.showOnFocus === !1 && -1 != b.showOn.indexOf("focus") && b.showOn.splice(b.showOn.indexOf("focus"), 1), b.disableTimeRanges.length > 0) { 16087 for (var d in b.disableTimeRanges) b.disableTimeRanges[d] = [t(b.disableTimeRanges[d][0]), t(b.disableTimeRanges[d][1])]; 16088 b.disableTimeRanges = b.disableTimeRanges.sort(function (a, b) { 16089 return a[0] - b[0] 16090 }); 16091 for (var d = b.disableTimeRanges.length - 1; d > 0; d--) b.disableTimeRanges[d][0] <= b.disableTimeRanges[d - 1][1] && (b.disableTimeRanges[d - 1] = [Math.min(b.disableTimeRanges[d][0], b.disableTimeRanges[d - 1][0]), Math.max(b.disableTimeRanges[d][1], b.disableTimeRanges[d - 1][1])], b.disableTimeRanges.splice(d, 1)) 16092 } 16093 return b 16094 } 16095 16096 function d(b) { 16097 var c = b.data("timepicker-settings"), 16098 d = b.data("timepicker-list"); 16099 if (d && d.length && (d.remove(), b.data("timepicker-list", !1)), c.useSelect) { 16100 d = a("<select />", { 16101 "class": "ui-timepicker-select" 16102 }); 16103 var g = d 16104 } else { 16105 d = a("<ul />", { 16106 "class": "ui-timepicker-list"
16107 }); 16108 var g = a("<div />", { 16109 "class": "ui-timepicker-wrapper", 16110 tabindex: -1 16111 }); 16112 g.css({ 16113 display: "none", 16114 position: "absolute" 16115 }).append(d) 16116 } 16117 if (c.noneOption) 16118 if (c.noneOption === !0 && (c.noneOption = c.useSelect ? "Time..." : "None"), a.isArray(c.noneOption)) { 16119 for (var i in c.noneOption) 16120 if (parseInt(i, 10) == i) { 16121 var k = e(c.noneOption[i], c.useSelect); 16122 d.append(k) 16123 } 16124 } else { 16125 var k = e(c.noneOption, c.useSelect); 16126 d.append(k) 16127 } if (c.className && g.addClass(c.className), (null !== c.minTime || null !== c.durationTime) && c.showDuration) { 16128 "function" == typeof c.step ? "function" : c.step; 16129 g.addClass("ui-timepicker-with-duration"), g.addClass("ui-timepicker-step-" + c.step) 16130 } 16131 var l = c.minTime; 16132 "function" == typeof c.durationTime ? l = t(c.durationTime()) : null !== c.durationTime && (l = c.durationTime); 16133 var n = null !== c.minTime ? c.minTime : 0, 16134 o = null !== c.maxTime ? c.maxTime : n + u - 1; 16135 n > o && (o += u), o === u - 1 && "string" === a.type(c.timeFormat) && c.show2400 && (o = u); 16136 var p = c.disableTimeRanges, 16137 v = 0, 16138 x = p.length, 16139 y = c.step; 16140 "function" != typeof y && (y = function () { 16141 return c.step 16142 }); 16143 for (var i = n, z = 0; o >= i; z++ , i += 60 * y(z)) { 16144 var A = i, 16145 B = s(A, c); 16146 if (c.useSelect) { 16147 var C = a("<option />", { 16148 value: B 16149 }); 16150 C.text(B) 16151 } else { 16152 var C = a("<li />"); 16153 C.addClass(43200 > A % 86400 ? "ui-timepicker-am" : "ui-timepicker-pm"), C.data("time", 86400 >= A ? A : A % 86400), C.text(B) 16154 } 16155 if ((null !== c.minTime || null !== c.durationTime) && c.showDuration) { 16156 var D = r(i - l, c.step); 16157 if (c.useSelect) C.text(C.text() + " (" + D + ")"); 16158 else { 16159 var E = a("<span />", { 16160 "class": "ui-timepicker-duration" 16161 }); 16162 E.text(" (" + D + ")"), C.append(E) 16163 } 16164 } 16165 x > v && (A >= p[v][1] && (v += 1), p[v] && A >= p[v][0] && A < p[v][1] && (c.useSelect ? C.prop("disabled", !0) : C.addClass("ui-timepicker-disabled"))), d.append(C) 16166 } 16167 if (g.data("timepicker-input", b), b.data("timepicker-list", g), c.useSelect) b.val() && d.val(f(t(b.val()), c)), d.on("focus", function () { 16168 a(this).data("timepicker-input").trigger("showTimepicker") 16169 }), d.on("blur", function () { 16170 a(this).data("timepicker-input").trigger("hideTimepicker") 16171 }), d.on("change", function () { 16172 m(b, a(this).val(), "select") 16173 }), m(b, d.val(), "initial"), b.hide().after(d); 16174 else { 16175 var F = c.appendTo; 16176 "string" == typeof F ? F = a(F) : "function" == typeof F && (F = F(b)), F.append(g), j(b, d), d.on("mousedown click", "li", function (c) { 16177 b.off("focus.timepicker"), b.on("focus.timepicker-ie-hack", function () { 16178 b.off("focus.timepicker-ie-hack"), b.on("focus.timepicker", w.show) 16179 }), h(b) || b[0].focus(), d.find("li").removeClass("ui-timepicker-selected"), a(this).addClass("ui-timepicker-selected"), q(b) && (b.trigger("hideTimepicker"), d.on("mouseup.timepicker click.timepicker", "li", function (a) { 16180 d.off("mouseup.timepicker click.timepicker"), g.hide() 16181 })) 16182 }) 16183 } 16184 } 16185 16186 function e(b, c) { 16187 var d, e, f; 16188 return "object" == typeof b ? (d = b.label, e = b.className, f = b.value) : "string" == typeof b ? d = b : a.error("Invalid noneOption value"), c ? a("<option />", { 16189 value: f, 16190 "class": e, 16191 text: d 16192 }) : a("<li />", { 16193 "class": e, 16194 text: d 16195 }).data("time", String(f)) 16196 } 16197 16198 function f(a, b) { 16199 return a = b.roundingFunction(a, b), null !== a ? s(a, b) : void 0 16200 } 16201 16202 function g(b) { 16203 if (b.target != window) { 16204 var c = a(b.target); 16205 c.closest(".ui-timepicker-input").length || c.closest(".ui-timepicker-wrapper").length || (w.hide(), a(document).unbind(".ui-timepicker"), a(window).unbind(".ui-timepicker")) 16206 } 16207 } 16208 16209 function h(a) { 16210 var b = a.data("timepicker-settings"); 16211 return (window.navigator.msMaxTouchPoints || "ontouchstart" in document) && b.disableTouchKeyboard 16212 } 16213 16214 function i(b, c, d) { 16215 if (!d && 0 !== d) return !1; 16216 var e = b.data("timepicker-settings"), 16217 f = !1, 16218 d = e.roundingFunction(d, e); 16219 return c.find("li").each(function (b, c) { 16220 var e = a(c); 16221 if ("number" == typeof e.data("time")) return e.data("time") == d ? (f = e, !1) : void 0 16222 }), f
16223 } 16224 16225 function j(a, b) { 16226 b.find("li").removeClass("ui-timepicker-selected"); 16227 var c = t(l(a), a.data("timepicker-settings")); 16228 if (null !== c) { 16229 var d = i(a, b, c); 16230 if (d) { 16231 var e = d.offset().top - b.offset().top; 16232 (e + d.outerHeight() > b.outerHeight() || 0 > e) && b.scrollTop(b.scrollTop() + d.position().top - d.outerHeight()), d.addClass("ui-timepicker-selected") 16233 } 16234 } 16235 } 16236 16237 function k(b, c) { 16238 if ("" !== this.value && "timepicker" != c) { 16239 var d = a(this); 16240 if (!d.is(":focus") || b && "change" == b.type) { 16241 var e = d.data("timepicker-settings"), 16242 f = t(this.value, e); 16243 if (null === f) return void d.trigger("timeFormatError"); 16244 var g = !1; 16245 null !== e.minTime && f < e.minTime && null !== e.maxTime && f > e.maxTime && (g = !0), a.each(e.disableTimeRanges, function () { 16246 return f >= this[0] && f < this[1] ? (g = !0, !1) : void 0 16247 }), e.forceRoundTime && (f = e.roundingFunction(f, e)); 16248 var h = s(f, e); 16249 g ? m(d, h, "error") && d.trigger("timeRangeError") : m(d, h) 16250 } 16251 } 16252 } 16253 16254 function l(a) { 16255 return a.is("input") ? a.val() : a.data("ui-timepicker-value") 16256 } 16257 16258 function m(a, b, c) { 16259 if (a.is("input")) { 16260 a.val(b); 16261 var d = a.data("timepicker-settings"); 16262 d.useSelect && "select" != c && "initial" != c && a.data("timepicker-list").val(f(t(b), d)) 16263 } 16264 return a.data("ui-timepicker-value") != b ? (a.data("ui-timepicker-value", b), "select" == c ? a.trigger("selectTime").trigger("changeTime").trigger("change", "timepicker") : "error" != c && a.trigger("changeTime"), !0) : (a.trigger("selectTime"), !1) 16265 } 16266 16267 function n(a) { 16268 switch (a.keyCode) { 16269 case 13: 16270 case 9: 16271 return; 16272 default: 16273 a.preventDefault() 16274 } 16275 } 16276 16277 function o(c) { 16278 var d = a(this), 16279 e = d.data("timepicker-list"); 16280 if (!e || !b(e)) { 16281 if (40 != c.keyCode) return !0; 16282 w.show.call(d.get(0)), e = d.data("timepicker-list"), h(d) || d.focus() 16283 } 16284 switch (c.keyCode) { 16285 case 13: 16286 return q(d) && w.hide.apply(this), c.preventDefault(), !1; 16287 case 38: 16288 var f = e.find(".ui-timepicker-selected"); 16289 return f.length ? f.is(":first-child") || (f.removeClass("ui-timepicker-selected"), f.prev().addClass("ui-timepicker-selected"), f.prev().position().top < f.outerHeight() && e.scrollTop(e.scrollTop() - f.outerHeight())) : (e.find("li").each(function (b, c) { 16290 return a(c).position().top > 0 ? (f = a(c), !1) : void 0 16291 }), f.addClass("ui-timepicker-selected")), !1; 16292 case 40: 16293 return f = e.find(".ui-timepicker-selected"), 0 === f.length ? (e.find("li").each(function (b, c) { 16294 return a(c).position().top > 0 ? (f = a(c), !1) : void 0 16295 }), f.addClass("ui-timepicker-selected")) : f.is(":last-child") || (f.removeClass("ui-timepicker-selected"), f.next().addClass("ui-timepicker-selected"), f.next().position().top + 2 * f.outerHeight() > e.outerHeight() && e.scrollTop(e.scrollTop() + f.outerHeight())), !1; 16296 case 27: 16297 e.find("li").removeClass("ui-timepicker-selected"), w.hide(); 16298 break; 16299 case 9: 16300 w.hide(); 16301 break; 16302 default: 16303 return !0 16304 } 16305 } 16306 16307 function p(c) { 16308 var d = a(this), 16309 e = d.data("timepicker-list"), 16310 f = d.data("timepicker-settings"); 16311 if (!e || !b(e) || f.disableTextInput) return !0; 16312 switch (c.keyCode) { 16313 case 96: 16314 case 97: 16315 case 98: 16316 case 99: 16317 case 100: 16318 case 101: 16319 case 102: 16320 case 103: 16321 case 104: 16322 case 105: 16323 case 48: 16324 case 49: 16325 case 50: 16326 case 51: 16327 case 52: 16328 case 53: 16329 case 54: 16330 case 55: 16331 case 56: 16332 case 57: 16333 case 65: 16334 case 77: 16335 case 80: 16336 case 186: 16337 case 8: 16338 case 46: 16339 f.typeaheadHighlight ? j(d, e) : e.hide() 16340 } 16341 } 16342 16343 function q(a) { 16344 var b = a.data("timepicker-settings"), 16345 c = a.data("timepicker-list"), 16346 d = null, 16347 e = c.find(".ui-timepicker-selected"); 16348 return e.hasClass("ui-timepicker-disabled") ? !1 : (e.length && (d = e.data("time")), null !== d && ("string" != typeof d && (d = s(d, b)), m(a, d, "select")), !0) 16349 } 16350 16351 function r(a, b) { 16352 a = Math.abs(a); 16353 var c, d, e = Math.round(a / 60), 16354 f = []; 16355 return 60 > e ? f = [e, v.mins] : (c = Math.floor(e / 60), d = e % 60, 30 == b && 30 == d && (c += v.decimal + 5), f.push(c), f.push(1 == c ? v.hr : v.hrs), 30 != b && d && (f.push(d), f.push(v.mins))
16355), f.join(" ") 16356 } 16357 16358 function s(b, c) { 16359 if ("number" != typeof b) return null; 16360 var d = parseInt(b % 60), 16361 e = parseInt(b / 60 % 60), 16362 f = parseInt(b / 3600 % 24), 16363 g = new Date(1970, 0, 2, f, e, d, 0); 16364 if (isNaN(g.getTime())) return null; 16365 if ("function" === a.type(c.timeFormat)) return c.timeFormat(g); 16366 for (var h, i, j = "", k = 0; k < c.timeFormat.length; k++) switch (i = c.timeFormat.charAt(k)) { 16367 case "a": 16368 j += g.getHours() > 11 ? v.pm : v.am; 16369 break; 16370 case "A": 16371 j += g.getHours() > 11 ? v.PM : v.AM; 16372 break; 16373 case "g": 16374 h = g.getHours() % 12, j += 0 === h ? "12" : h; 16375 break; 16376 case "G": 16377 h = g.getHours(), b === u && (h = c.show2400 ? 24 : 0), j += h; 16378 break; 16379 case "h": 16380 h = g.getHours() % 12, 0 !== h && 10 > h && (h = "0" + h), j += 0 === h ? "12" : h; 16381 break; 16382 case "H": 16383 h = g.getHours(), b === u && (h = c.show2400 ? 24 : 0), j += h > 9 ? h : "0" + h; 16384 break; 16385 case "i": 16386 var e = g.getMinutes(); 16387 j += e > 9 ? e : "0" + e; 16388 break; 16389 case "s": 16390 d = g.getSeconds(), j += d > 9 ? d : "0" + d; 16391 break; 16392 case "\\": 16393 k++ , j += c.timeFormat.charAt(k); 16394 break; 16395 default: 16396 j += i 16397 } 16398 return j 16399 } 16400 16401 function t(a, b) { 16402 if ("" === a || null === a) return null; 16403 if ("object" == typeof a) return 3600 * a.getHours() + 60 * a.getMinutes() + a.getSeconds(); 16404 if ("string" != typeof a) return a; 16405 a = a.toLowerCase().replace(/[\s\.]/g, ""), ("a" == a.slice(-1) || "p" == a.slice(-1)) && (a += "m"); 16406 var c = "(" + v.am.replace(".", "") + "|" + v.pm.replace(".", "") + "|" + v.AM.replace(".", "") + "|" + v.PM.replace(".", "") + ")?", 16407 d = new RegExp("^" + c + "([0-9]?[0-9])\\W?([0-5][0-9])?\\W?([0-5][0-9])?" + c + "$"), 16408 e = a.match(d); 16409 if (!e) return null; 16410 var f = parseInt(1 * e[2], 10); 16411 if (f > 24) { 16412 if (b && b.wrapHours === !1) return null; 16413 f %= 24 16414 } 16415 var g = e[1] || e[5], 16416 h = f; 16417 if (12 >= f && g) { 16418 var i = g == v.pm || g == v.PM; 16419 h = 12 == f ? i ? 12 : 0 : f + (i ? 12 : 0) 16420 } 16421 var j = 1 * e[3] || 0, 16422 k = 1 * e[4] || 0, 16423 l = 3600 * h + 60 * j + k; 16424 if (12 > f && !g && b && b._twelveHourTime && b.scrollDefault) { 16425 var m = l - b.scrollDefault(); 16426 0 > m && m >= u / -2 && (l = (l + u / 2) % u) 16427 } 16428 return l 16429 } 16430 var u = 86400, 16431 v = { 16432 am: "am", 16433 pm: "pm", 16434 AM: "AM", 16435 PM: "PM", 16436 decimal: ".", 16437 mins: "mins", 16438 hr: "hr", 16439 hrs: "hrs" 16440 }, 16441 w = { 16442 init: function (b) { 16443 return this.each(function () { 16444 var e = a(this), 16445 f = []; 16446 for (var g in a.fn.timepicker.defaults) e.data(g) && (f[g] = e.data(g)); 16447 var h = a.extend({}, a.fn.timepicker.defaults, f, b); 16448 if (h.lang && (v = a.extend(v, h.lang)), h = c(h), e.data("timepicker-settings", h), e.addClass("ui-timepicker-input"), h.useSelect) d(e); 16449 else { 16450 if (e.prop("autocomplete", "off"), h.showOn) 16451 for (var i in h.showOn) e.on(h.showOn[i] + ".timepicker", w.show); 16452 e.on("change.timepicker", k), e.on("keydown.timepicker", o), e.on("keyup.timepicker", p), h.disableTextInput && e.on("keydown.timepicker", n), k.call(e.get(0)) 16453 } 16454 }) 16455 }, 16456 show: function (c) { 16457 var e = a(this), 16458 f = e.data("timepicker-settings"); 16459 if (c && c.preventDefault(), f.useSelect) return void e.data("timepicker-list").focus(); 16460 h(e) && e.blur(); 16461 var k = e.data("timepicker-list"); 16462 if (!e.prop("readonly") && (k && 0 !== k.length && "function" != typeof f.durationTime || (d(e), k = e.data("timepicker-list")), !b(k))) { 16463 e.data("ui-timepicker-value", e.val()), j(e, k), w.hide(), k.show(); 16464 var m = {}; 16465 f.orientation.match(/r/) ? m.left = e.offset().left + e.outerWidth() - k.outerWidth() + parseInt(k.css("marginLeft").replace("px", ""), 10) : m.left = e.offset().left + parseInt(k.css("marginLeft").replace("px", ""), 10); 16466 var n; 16467 n = f.orientation.match(/t/) ? "t" : f.orientation.match(/b/) ? "b" : e.offset().top + e.outerHeight(!0) + k.outerHeight() > a(window).height() + a(window).scrollTop() ? "t" : "b", "t" == n ? (k.addClass("ui-timepicker-positioned-top"), m.top = e.offset().top - k.outerHeight() + parseInt(k.css("marginTop").replace("px", ""), 10)) : (k.removeClass("ui-timepicker-positioned-top"), m.top = e.offset().top + e.outerHeight() + parseInt(k.css("marginTop").replace("px", ""), 10)), k.offset(m); 16468 var o = k.find(".ui-timepicker-selected"); 16469 if (!o.length) { 16470 var p = t(l(e)); 16471 null !== p ? o = i(e, k, p) : f.scrollDefault && (o = i(e, k, f.scrollDefault())) 16472 } 16473 if (o && o.length) { 16474 var q = k.scrollTop() + o.position().top - o.outerHeight(); 16475 k.scrollTop(q) 16476 } else k.scrollTop(0); 16477 return f.stopScrollPropagation && a(document).on("wheel.ui-timepicker", ".ui-timepicker-wrapper", function (b) { 16478 b.preventDefault(); 16479 var c = a(this).scrollTop(); 16480 a(this).scrollTop(c + b.originalEvent.deltaY) 16481 }), a(document).on("touchstart.ui-timepicker mousedown.ui-timepicker", g), a(window).on("resize.ui-timepicker", g), f.closeOnWindowScroll && a(document).on("scroll.ui-timepicker", g), e.trigger("showTimepicker"), this 16482 } 16483 }, 16484 hide: function (c) { 16485 var d = a(this), 16486 e = d.data("timepicker-settings"); 16487 return e && e.useSelect && d.blur(), a(".ui-timepicker-wrapper").each(function () { 16488 var c = a(this); 16489 if (b(c)) { 16490 var d = c.data("timepicker-input"), 16491 e = d.data("timepicker-settings"); 16492 e && e.selectOnBlur && q(d), c.hide(), d.trigger("hideTimepicker") 16493 } 16494 }), this 16495 }, 16496 option: function (b, e) { 16497 return "string" == typeof b && "undefined" == typeof e ? a(this).data("timepicker-settings")[b] : this.each(function () { 16498 var f = a(this), 16499 g = f.data("timepicker-settings"), 16500 h = f.data("timepicker-list"); 16501 "object" == typeof b ? g = a.extend(g, b) : "string" == typeof b && (g[b] = e), g = c(g), f.data("timepicker-settings", g), h && (h.remove(), f.data("timepicker-list", !1)), g.useSelect && d(f) 16502 }) 16503 }, 16504 getSecondsFromMidnight: function () { 16505 return t(l(this)) 16506 }, 16507 getTime: function (a) { 16508 var b = this, 16509 c = l(b); 16510 if (!c) return null; 16511 var d = t(c); 16512 if (null === d) return null; 16513 a || (a = new Date); 16514 var e = new Date(a); 16515 return e.setHours(d / 3600), e.setMinutes(d % 3600 / 60), e.setSeconds(d % 60), e.setMilliseconds(0), e 16516 }, 16517 isVisible: function () { 16518 var a = this, 16519 c = a.data("timepicker-list"); 16520 return !(!c || !b(c)) 16521 }, 16522 setTime: function (a) { 16523 var b = this, 16524 c = b.data("timepicker-settings"); 16525 if (c.forceRoundTime) var d = f(t(a), c); 16526 else var d = s(t(a), c); 16527 return a && null === d && c.noneOption && (d = a), m(b, d), b.data("timepicker-list") && j(b, b.data("timepicker-list")), this 16528 }, 16529 remove: function () { 16530 var a = this; 16531 if (a.hasClass("ui-timepicker-input")) { 16532 var b = a.data("timepicker-settings"); 16533 return a.removeAttr("autocomplete", "off"), a.removeClass("ui-timepicker-input"), a.removeData("timepicker-settings"), a.off(".timepicker"), a.data("timepicker-list") && a.data("timepicker-list").remove(), b.useSelect && a.show(), a.removeData("timepicker-list"), this 16534 } 16535 } 16536 }; 16537 a.fn.timepicker = function (b) { 16538 return this.length ? w[b] ? this.hasClass("ui-timepicker-input") ? w[b].apply(this, Array.prototype.slice.call(arguments, 1)) : this : "object" != typeof b && b ? void a.error("Method " + b + " does not exist on jQuery.timepicker") : w.init.apply(this, arguments) : this 16539 }, a.fn.timepicker.defaults = { 16540 appendTo: "body", 16541 className: null, 16542 closeOnWindowScroll: !1, 16543 disableTextInput: !1, 16544 disableTimeRanges: [], 16545 disableTouchKeyboard: !1, 16546 durationTime: null, 16547 forceRoundTime: !1, 16548 maxTime: null, 16549 minTime: null, 16550 noneOption: !1, 16551 orientation: "l", 16552 roundingFunction: function (a, b) { 16553 if (null === a) return null; 16554 if ("number" != typeof b.step) return a; 16555 var c = a % (60 * b.step); 16556 return c >= 30 * b.step ? a += 60 * b.step - c : a -= c, a == u && b.show2400 ? a : a % u 16557 }, 16558 scrollDefault: null, 16559 selectOnBlur: !1, 16560 show2400: !1, 16561 showDuration: !1, 16562 showOn: ["click", "focus"], 16563 showOnFocus: !0, 16564 step: 30, 16565 stopScrollPropagation: !1, 16566 timeFormat: "g:ia", 16567 typeaheadHighlight: !0, 16568 useSelect: !1, 16569 wrapHours: !0 16570 } 16571}); 16572 16573 16574/*! version : 4.17.37 16575 ========================================================= 16576 bootstrap-datetimejs 16577 https://github.com/Eonasdan/bootstrap-datetimepicker 16578 Copyright (c) 2015 Jonathan Peterson 16579 ========================================================= 16580 */ 16581! function (a) { 16582 "use strict"; 16583 if ("function" == typeof define && define.amd) define(["jquery", "moment"], a);
vendor: 48,986 bytes, lines 16584-17334
16584 else if ("object" == typeof exports) a(require("jquery"), require("moment")); 16585 else { 16586 if ("undefined" == typeof jQuery) throw "bootstrap-datetimepicker requires jQuery to be loaded first"; 16587 if ("undefined" == typeof moment) throw "bootstrap-datetimepicker requires Moment.js to be loaded first"; 16588 a(jQuery, moment) 16589 } 16590}(function (a, b) { 16591 "use strict"; 16592 if (!b) throw new Error("bootstrap-datetimepicker requires Moment.js to be loaded first"); 16593 var c = function (c, d) { 16594 var e, f, g, h, i, j, k, l = {}, 16595 m = !0, 16596 n = !1, 16597 o = !1, 16598 p = 0, 16599 q = [{ 16600 clsName: "days", 16601 navFnc: "M", 16602 navStep: 1 16603 }, { 16604 clsName: "months", 16605 navFnc: "y", 16606 navStep: 1 16607 }, { 16608 clsName: "years", 16609 navFnc: "y", 16610 navStep: 10 16611 }, { 16612 clsName: "decades", 16613 navFnc: "y", 16614 navStep: 100 16615 }], 16616 r = ["days", "months", "years", "decades"], 16617 s = ["top", "bottom", "auto"], 16618 t = ["left", "right", "auto"], 16619 u = ["default", "top", "bottom"], 16620 v = { 16621 up: 38, 16622 38: "up", 16623 down: 40, 16624 40: "down", 16625 left: 37, 16626 37: "left", 16627 right: 39, 16628 39: "right", 16629 tab: 9, 16630 9: "tab", 16631 escape: 27, 16632 27: "escape", 16633 enter: 13, 16634 13: "enter", 16635 pageUp: 33, 16636 33: "pageUp", 16637 pageDown: 34, 16638 34: "pageDown", 16639 shift: 16, 16640 16: "shift", 16641 control: 17, 16642 17: "control", 16643 space: 32, 16644 32: "space", 16645 t: 84, 16646 84: "t", 16647 "delete": 46, 16648 46: "delete" 16649 }, 16650 w = {}, 16651 x = function (a) { 16652 var c, e, f, g, h, i = !1; 16653 return void 0 !== b.tz && void 0 !== d.timeZone && null !== d.timeZone && "" !== d.timeZone && (i = !0), void 0 === a || null === a ? c = i ? b().tz(d.timeZone).startOf("d") : b().startOf("d") : i ? (e = b().tz(d.timeZone).utcOffset(), f = b(a, j, d.useStrict).utcOffset(), f !== e ? (g = b().tz(d.timeZone).format("Z"), h = b(a, j, d.useStrict).format("YYYY-MM-DD[T]HH:mm:ss") + g, c = b(h, j, d.useStrict).tz(d.timeZone)) : c = b(a, j, d.useStrict).tz(d.timeZone)) : c = b(a, j, d.useStrict), c 16654 }, 16655 y = function (a) { 16656 if ("string" != typeof a || a.length > 1) throw new TypeError("isEnabled expects a single character string parameter"); 16657 switch (a) { 16658 case "y": 16659 return -1 !== i.indexOf("Y"); 16660 case "M": 16661 return -1 !== i.indexOf("M"); 16662 case "d": 16663 return -1 !== i.toLowerCase().indexOf("d"); 16664 case "h": 16665 case "H": 16666 return -1 !== i.toLowerCase().indexOf("h"); 16667 case "m": 16668 return -1 !== i.indexOf("m"); 16669 case "s": 16670 return -1 !== i.indexOf("s"); 16671 default: 16672 return !1 16673 } 16674 }, 16675 z = function () { 16676 return y("h") || y("m") || y("s") 16677 }, 16678 A = function () { 16679 return y("y") || y("M") || y("d") 16680 }, 16681 B = function () { 16682 var b = a("<thead>").append(a("<tr>").append(a("<th>").addClass("prev").attr("data-action", "previous").append(a("<span>").addClass(d.icons.previous))).append(a("<th>").addClass("picker-switch").attr("data-action", "pickerSwitch").attr("colspan", d.calendarWeeks ? "6" : "5")).append(a("<th>").addClass("next").attr("data-action", "next").append(a("<span>").addClass(d.icons.next)))), 16683 c = a("<tbody>").append(a("<tr>").append(a("<td>").attr("colspan", d.calendarWeeks ? "8" : "7"))); 16684 return [a("<div>").addClass("datepicker-days").append(a("<table>").addClass("table-condensed").append(b).append(a("<tbody>"))), a("<div>").addClass("datepicker-months").append(a("<table>").addClass("table-condensed").append(b.clone()).append(c.clone())), a("<div>").addClass("datepicker-years").append(a("<table>").addClass("table-condensed").append(b.clone()).append(c.clone())), a("<div>").addClass("datepicker-decades").append(a("<table>").addClass("table-condensed").append(b.clone()).append(c.clone()))] 16685 }, 16686 C = function () { 16687 var b = a("<tr>"), 16688 c = a("<tr>"), 16689 e = a("<tr>"); 16690 return y("h") && (b.append(a("<td>").append(a("<a>").attr({ 16691 href: "#", 16692 tabindex: "-1", 16693 title: d.tooltips.incrementHour 16694 }).addClass("btn").attr("data-action", "incrementHours").append(a("<span>").addClass(d.icons.up)))), c.append(a("<td>").append(a("<span>").addClass("timepicker-hour").attr({ 16695 "data-time-component": "hours", 16696 title: d.tooltips.pickHour 16697 }).attr("data-action", "showHours"))), e.append(a("<td>").append(a("<a>").attr({ 16698 href: "#", 16699 tabindex: "-1", 16700 title: d.tooltips.decrementHour 16701 }).addClass("btn").attr("data-action", "decrementHours").append(a("<span>").addClass(d.icons.down))))), y("m") && (y("h") && (b.append(a("<td>").addClass("separator")), c.append(a("<td>").addClass("separator").html(":")), e.append(a("<td>").addClass("separator"))), b.append(a("<td>").append(a("<a>").attr({ 16702 href: "#", 16703 tabindex: "-1", 16704 title: d.tooltips.incrementMinute 16705 }).addClass("btn").attr("data-action", "incrementMinutes").append(a("<span>").addClass(d.icons.up)))), c.append(a("<td>").append(a("<span>").addClass("timepicker-minute").attr({ 16706 "data-time-component": "minutes", 16707 title: d.tooltips.pickMinute 16708 }).attr("data-action", "showMinutes"))), e.append(a("<td>").append(a("<a>").attr({ 16709 href: "#", 16710 tabindex: "-1", 16711 title: d.tooltips.decrementMinute 16712 }).addClass("btn").attr("data-action", "decrementMinutes").append(a("<span>").addClass(d.icons.down))))), y("s") && (y("m") && (b.append(a("<td>").addClass("separator")), c.append(a("<td>").addClass("separator").html(":")), e.append(a("<td>").addClass("separator"))), b.append(a("<td>").append(a("<a>").attr({ 16713 href: "#", 16714 tabindex: "-1", 16715 title: d.tooltips.incrementSecond 16716 }).addClass("btn").attr("data-action", "incrementSeconds").append(a("<span>").addClass(d.icons.up)))), c.append(a("<td>").append(a("<span>").addClass("timepicker-second").attr({ 16717 "data-time-component": "seconds", 16718 title: d.tooltips.pickSecond 16719 }).attr("data-action", "showSeconds"))), e.append(a("<td>").append(a("<a>").attr({ 16720 href: "#", 16721 tabindex: "-1", 16722 title: d.tooltips.decrementSecond 16723 }).addClass("btn").attr("data-action", "decrementSeconds").append(a("<span>").addClass(d.icons.down))))), h || (b.append(a("<td>").addClass("separator")), c.append(a("<td>").append(a("<button>").addClass("btn btn-primary").attr({ 16724 "data-action": "togglePeriod", 16725 tabindex: "-1", 16726 title: d.tooltips.togglePeriod 16727 }))), e.append(a("<td>").addClass("separator"))), a("<div>").addClass("timepicker-picker").append(a("<table>").addClass("table-condensed").append([b, c, e])) 16728 }, 16729 D = function () { 16730 var b = a("<div>").addClass("timepicker-hours").append(a("<table>").addClass("table-condensed")), 16731 c = a("<div>").addClass("timepicker-minutes").append(a("<table>").addClass("table-condensed")), 16732 d = a("<div>").addClass("timepicker-seconds").append(a("<table>").addClass("table-condensed")), 16733 e = [C()]; 16734 return y("h") && e.push(b), y("m") && e.push(c), y("s") && e.push(d), e 16735 }, 16736 E = function () { 16737 var b = []; 16738 return d.showTodayButton && b.push(a("<td>").append(a("<a>").attr({ 16739 "data-action": "today", 16740 title: d.tooltips.today 16741 }).append(a("<span>").addClass(d.icons.today)))), !d.sideBySide && A() && z() && b.push(a("<td>").append(a("<a>").attr({ 16742 "data-action": "togglePicker", 16743 title: d.tooltips.selectTime 16744 }).append(a("<span>").addClass(d.icons.time)))), d.showClear && b.push(a("<td>").append(a("<a>").attr({ 16745 "data-action": "clear", 16746 title: d.tooltips.clear 16747 }).append(a("<span>").addClass(d.icons.clear)))), d.showClose && b.push(a("<td>").append(a("<a>").attr({ 16748 "data-action": "close", 16749 title: d.tooltips.close 16750 }).append(a("<span>").addClass(d.icons.close)))), a("<table>").addClass("table-condensed").append(a("<tbody>").append(a("<tr>").append(b))) 16751 }, 16752 F = function () { 16753 var b = a("<div>").addClass("bootstrap-datetimepicker-widget dropdown-menu"), 16754 c = a("<div>").addClass("datepicker").append(B()), 16755 e = a("<div>").addClass("timepicker").append(D()), 16756 f = a("<ul>").addClass("list-unstyled"), 16757 g = a("<li>").addClass("picker-switch" + (d.collapse ? " accordion-toggle" : "")).append(E()); 16758 return d.inline && b.removeClass("dropdown-menu"), h && b.addClass("usetwentyfour"), y("s") && !h && b.addClass("wider"), d.sideBySide && A() && z() ? (b.addClass("timepicker-sbs"), "top" === d.toolbarPlacement && b.append(g), b.append(a("<div>").addClass("row").append(c.addClass("col-md-6")).append(e.addClass("col-md-6"))), "bottom" === d.toolbarPlacement && b.append(g), b) : ("top" === d.toolbarPlacement && f.append(g), A() && f.append(a("<li>").addClass(d.collapse && z() ? "collapse in" : "").append(c)), "default" === d.toolbarPlacement && f.append(g), z() && f.append(a("<li>").addClass(d.collapse && A() ? "collapse" : "").append(e)), "bottom" === d.toolbarPlacement && f.append(g), b.append(f)) 16759 }, 16760 G = function () { 16761 var b, e = {}; 16762 return b = c.is("input") || d.inline ? c.data() : c.find("input").data(), b.dateOptions && b.dateOptions instanceof Object && (e = a.extend(!0, e, b.dateOptions)), a.each(d, function (a) { 16763 var c = "date" + a.charAt(0).toUpperCase() + a.slice(1); 16764 void 0 !== b[c] && (e[a] = b[c]) 16765 }), e 16766 }, 16767 H = function () { 16768 var b, e = (n || c).position(), 16769 f = (n || c).offset(), 16770 g = d.widgetPositioning.vertical, 16771 h = d.widgetPositioning.horizontal; 16772 if (d.widgetParent) b = d.widgetParent.append(o); 16773 else if (c.is("input")) b = c.after(o).parent(); 16774 else { 16775 if (d.inline) return void (b = c.append(o)); 16776 b = c, c.children().first().after(o) 16777 } 16778 if ("auto" === g && (g = f.top + 1.5 * o.height() >= a(window).height() + a(window).scrollTop() && o.height() + c.outerHeight() < f.top ? "top" : "bottom"), "auto" === h && (h = b.width() < f.left + o.outerWidth() / 2 && f.left + o.outerWidth() > a(window).width() ? "right" : "left"), "top" === g ? o.addClass("top").removeClass("bottom") : o.addClass("bottom").removeClass("top"), "right" === h ? o.addClass("pull-right") : o.removeClass("pull-right"), "relative" !== b.css("position") && (b = b.parents().filter(function () { 16779 return "relative" === a(this).css("position") 16780 }).first()), 0 === b.length) throw new Error("datetimepicker component should be placed within a relative positioned container"); 16781 o.css({ 16782 top: "top" === g ? "auto" : e.top + c.outerHeight(), 16783 bottom: "top" === g ? e.top + c.outerHeight() : "auto", 16784 left: "left" === h ? b === c ? 0 : e.left : "auto", 16785 right: "left" === h ? "auto" : b.outerWidth() - c.outerWidth() - (b === c ? 0 : e.left) 16786 }) 16787 }, 16788 I = function (a) { 16789 "dp.change" === a.type && (a.date && a.date.isSame(a.oldDate) || !a.date && !a.oldDate) || c.trigger(a) 16790 }, 16791 J = function (a) { 16792 "y" === a && (a = "YYYY"), I({ 16793 type: "dp.update", 16794 change: a, 16795 viewDate: f.clone() 16796 }) 16797 }, 16798 K = function (a) { 16799 o && (a && (k = Math.max(p, Math.min(3, k + a))), o.find(".datepicker > div").hide().filter(".datepicker-" + q[k].clsName).show()) 16800 }, 16801 L = function () { 16802 var b = a("<tr>"), 16803 c = f.clone().startOf("w").startOf("d"); 16804 for (d.calendarWeeks === !0 && b.append(a("<th>").addClass("cw").text("#")); c.isBefore(f.clone().endOf("w"));) b.append(a("<th>").addClass("dow").text(c.format("dd"))), c.add(1, "d"); 16805 o.find(".datepicker-days thead").append(b) 16806 }, 16807 M = function (a) { 16808 return d.disabledDates[a.format("YYYY-MM-DD")] === !0 16809 }, 16810 N = function (a) { 16811 return d.enabledDates[a.format("YYYY-MM-DD")] === !0 16812 }, 16813 O = function (a) { 16814 return d.disabledHours[a.format("H")] === !0 16815 }, 16816 P = function (a) { 16817 return d.enabledHours[a.format("H")] === !0 16818 }, 16819 Q = function (b, c) { 16820 if (!b.isValid()) return !1; 16821 if (d.disabledDates && "d" === c && M(b)) return !1; 16822 if (d.enabledDates && "d" === c && !N(b)) return !1; 16823 if (d.minDate && b.isBefore(d.minDate, c)) return !1; 16824 if (d.maxDate && b.isAfter(d.maxDate, c)) return !1; 16825 if (d.daysOfWeekDisabled && "d" === c && -1 !== d.daysOfWeekDisabled.indexOf(b.day())) return !1; 16826 if (d.disabledHours && ("h" === c || "m" === c || "s" === c) && O(b)) return !1; 16827 if (d.enabledHours && ("h" === c || "m" === c || "s" === c) && !P(b)) return !1; 16828 if (d.disabledTimeIntervals && ("h" === c || "m" === c || "s" === c)) { 16829 var e = !1; 16830 if (a.each(d.disabledTimeIntervals, function () { 16831 return b.isBetween(this[0], this[1]) ? (e = !0, !1) : void 0 16832 }), e) return !1 16833 } 16834 return !0 16835 }, 16836 R = function () { 16837 for (var b = [], c = f.clone().startOf("y").startOf("d"); c.isSame(f, "y");) b.push(a("<span>").attr("data-action", "selectMonth").addClass("month").text(c.format("MMM"))), c.add(1, "M"); 16838 o.find(".datepicker-months td").empty().append(b) 16839 }, 16840 S = function () { 16841 var b = o.find(".datepicker-months"), 16842 c = b.find("th"), 16843 g = b.find("tbody").find("span"); 16844 c.eq(0).find("span").attr("title", d.tooltips.prevYear), c.eq(1).attr("title", d.tooltips.selectYear), c.eq(2).find("span").attr("title", d.tooltips.nextYear), b.find(".disabled").removeClass("disabled"), Q(f.clone().subtract(1, "y"), "y") || c.eq(0).addClass("disabled"), c.eq(1).text(f.year()), Q(f.clone().add(1, "y"), "y") || c.eq(2).addClass("disabled"), g.removeClass("active"), e.isSame(f, "y") && !m && g.eq(e.month()).addClass("active"), g.each(function (b) { 16845 Q(f.clone().month(b), "M") || a(this).addClass("disabled") 16846 }) 16847 }, 16848 T = function () { 16849 var a = o.find(".datepicker-years"), 16850 b = a.find("th"), 16851 c = f.clone().subtract(5, "y"), 16852 g = f.clone().add(6, "y"), 16853 h = ""; 16854 for (b.eq(0).find("span").attr("title", d.tooltips.prevDecade), b.eq(1).attr("title", d.tooltips.selectDecade), b.eq(2).find("span").attr("title", d.tooltips.nextDecade), a.find(".disabled").removeClass("disabled"), d.minDate && d.minDate.isAfter(c, "y") && b.eq(0).addClass("disabled"), b.eq(1).text(c.year() + "-" + g.year()), d.maxDate && d.maxDate.isBefore(g, "y") && b.eq(2).addClass("disabled"); !c.isAfter(g, "y");) h += '<span data-action="selectYear" class="year' + (c.isSame(e, "y") && !m ? " active" : "") + (Q(c, "y") ? "" : " disabled") + '">' + c.year() + "</span>", c.add(1, "y"); 16855 a.find("td").html(h) 16856 }, 16857 U = function () { 16858 var a = o.find(".datepicker-decades"), 16859 c = a.find("th"), 16860 g = b({ 16861 y: f.year() - f.year() % 100 - 1 16862 }), 16863 h = g.clone().add(100, "y"), 16864 i = g.clone(), 16865 j = ""; 16866 for (c.eq(0).find("span").attr("title", d.tooltips.prevCentury), c.eq(2).find("span").attr("title", d.tooltips.nextCentury), a.find(".disabled").removeClass("disabled"), (g.isSame(b({ 16867 y: 1900 16868 })) || d.minDate && d.minDate.isAfter(g, "y")) && c.eq(0).addClass("disabled"), c.eq(1).text(g.year() + "-" + h.year()), (g.isSame(b({ 16869 y: 2e3 16870 })) || d.maxDate && d.maxDate.isBefore(h, "y")) && c.eq(2).addClass("disabled"); !g.isAfter(h, "y");) j += '<span data-action="selectDecade" class="decade' + (g.isSame(e, "y") ? " active" : "") + (Q(g, "y") ? "" : " disabled") + '" data-selection="' + (g.year() + 6) + '">' + (g.year() + 1) + " - " + (g.year() + 12) + "</span>", g.add(12, "y"); 16871 j += "<span></span><span></span><span></span>", a.find("td").html(j), c.eq(1).text(i.year() + 1 + "-" + g.year()) 16872 }, 16873 V = function () { 16874 var b, c, g, h, i = o.find(".datepicker-days"), 16875 j = i.find("th"), 16876 k = []; 16877 if (A()) { 16878 for (j.eq(0).find("span").attr("title", d.tooltips.prevMonth), j.eq(1).attr("title", d.tooltips.selectMonth), j.eq(2).find("span").attr("title", d.tooltips.nextMonth), i.find(".disabled").removeClass("disabled"), j.eq(1).text(f.format(d.dayViewHeaderFormat)), Q(f.clone().subtract(1, "M"), "M") || j.eq(0).addClass("disabled"), Q(f.clone().add(1, "M"), "M") || j.eq(2).addClass("disabled"), b = f.clone().startOf("M").startOf("w").startOf("d"), h = 0; 42 > h; h++) 0 === b.weekday() && (c = a("<tr>"), d.calendarWeeks && c.append('<td class="cw">' + b.week() + "</td>"), k.push(c)), g = "", b.isBefore(f, "M") && (g += " old"), b.isAfter(f, "M") && (g += " new"), b.isSame(e, "d") && !m && (g += " active"), Q(b, "d") || (g += " disabled"), b.isSame(x(), "d") && (g += " today"), (0 === b.day() || 6 === b.day()) && (g += " weekend"), c.append('<td data-action="selectDay" data-day="' + b.format("L") + '" class="day' + g + '">' + b.date() + "</td>"), b.add(1, "d"); 16879 i.find("tbody").empty().append(k), S(), T(), U() 16880 } 16881 }, 16882 W = function () { 16883 var b = o.find(".timepicker-hours table"), 16884 c = f.clone().startOf("d"), 16885 d = [], 16886 e = a("<tr>"); 16887 for (f.hour() > 11 && !h && c.hour(12); c.isSame(f, "d") && (h || f.hour() < 12 && c.hour() < 12 || f.hour() > 11);) c.hour() % 4 === 0 && (e = a("<tr>"), d.push(e)), e.append('<td data-action="selectHour" class="hour' + (Q(c, "h") ? "" : " disabled") + '">' + c.format(h ? "HH" : "hh") + "</td>"), c.add(1, "h"); 16888 b.empty().append(d) 16889 }, 16890 X = function () { 16891 for (var b = o.find(".timepicker-minutes table"), c = f.clone().startOf("h"), e = [], g = a("<tr>"), h = 1 === d.stepping ? 5 : d.stepping; f.isSame(c, "h");) c.minute() % (4 * h) === 0 && (g = a("<tr>"), e.push(g)), g.append('<td data-action="selectMinute" class="minute' + (Q(c, "m") ? "" : " disabled") + '">' + c.format("mm") + "</td>"), c.add(h, "m"); 16892 b.empty().append(e) 16893 }, 16894 Y = function () { 16895 for (var b = o.find(".timepicker-seconds table"), c = f.clone().startOf("m"), d = [], e = a("<tr>"); f.isSame(c, "m");) c.second() % 20 === 0 && (e = a("<tr>"), d.push(e)), e.append('<td data-action="selectSecond" class="second' + (Q(c, "s") ? "" : " disabled") + '">' + c.format("ss") + "</td>"), c.add(5, "s"); 16896 b.empty().append(d) 16897 }, 16898 Z = function () { 16899 var a, b, c = o.find(".timepicker span[data-time-component]"); 16900 h || (a = o.find(".timepicker [data-action=togglePeriod]"), b = e.clone().add(e.hours() >= 12 ? -12 : 12, "h"), a.text(e.format("A")), Q(b, "h") ? a.removeClass("disabled") : a.addClass("disabled")), c.filter("[data-time-component=hours]").text(e.format(h ? "HH" : "hh")), c.filter("[data-time-component=minutes]").text(e.format("mm")), c.filter("[data-time-component=seconds]").text(e.format("ss")), W(), X(), Y() 16901 }, 16902 $ = function () { 16903 o && (V(), Z()) 16904 }, 16905 _ = function (a) { 16906 var b = m ? null : e; 16907 return a ? (a = a.clone().locale(d.locale), 1 !== d.stepping && a.minutes(Math.round(a.minutes() / d.stepping) * d.stepping % 60).seconds(0), void (Q(a) ? (e = a, f = e.clone(), g.val(e.format(i)), c.data("date", e.format(i)), m = !1, $(), I({ 16908 type: "dp.change", 16909 date: e.clone(), 16910 oldDate: b 16911 })) : (d.keepInvalid || g.val(m ? "" : e.format(i)), I({ 16912 type: "dp.error", 16913 date: a 16914 })))) : (m = !0, g.val(""), c.data("date", ""), I({ 16915 type: "dp.change", 16916 date: !1, 16917 oldDate: b 16918 }), void $()) 16919 }, 16920 aa = function () { 16921 var b = !1; 16922 return o ? (o.find(".collapse").each(function () { 16923 var c = a(this).data("collapse"); 16924 return c && c.transitioning ? (b = !0, !1) : !0 16925 }), b ? l : (n && n.hasClass("btn") && n.toggleClass("active"), o.hide(), a(window).off("resize", H), o.off("click", "[data-action]"), o.off("mousedown", !1), o.remove(), o = !1, I({ 16926 type: "dp.hide", 16927 date: e.clone() 16928 }), g.blur(), l)) : l 16929 }, 16930 ba = function () { 16931 _(null) 16932 }, 16933 ca = { 16934 next: function () { 16935 var a = q[k].navFnc; 16936 f.add(q[k].navStep, a), V(), J(a) 16937 }, 16938 previous: function () { 16939 var a = q[k].navFnc; 16940 f.subtract(q[k].navStep, a), V(), J(a) 16941 }, 16942 pickerSwitch: function () { 16943 K(1) 16944 }, 16945 selectMonth: function (b) { 16946 var c = a(b.target).closest("tbody").find("span").index(a(b.target)); 16947 f.month(c), k === p ? (_(e.clone().year(f.year()).month(f.month())), d.inline || aa()) : (K(-1), V()), J("M") 16948 }, 16949 selectYear: function (b) { 16950 var c = parseInt(a(b.target).text(), 10) || 0; 16951 f.year(c), k === p ? (_(e.clone().year(f.year())), d.inline || aa()) : (K(-1), V()), J("YYYY") 16952 }, 16953 selectDecade: function (b) { 16954 var c = parseInt(a(b.target).data("selection"), 10) || 0; 16955 f.year(c), k === p ? (_(e.clone().year(f.year())), d.inline || aa()) : (K(-1), V()), J("YYYY") 16956 }, 16957 selectDay: function (b) { 16958 var c = f.clone(); 16959 a(b.target).is(".old") && c.subtract(1, "M"), a(b.target).is(".new") && c.add(1, "M"), _(c.date(parseInt(a(b.target).text(), 10))), z() || d.keepOpen || d.inline || aa() 16960 }, 16961 incrementHours: function () { 16962 var a = e.clone().add(1, "h"); 16963 Q(a, "h") && _(a) 16964 }, 16965 incrementMinutes: function () { 16966 var a = e.clone().add(d.stepping, "m"); 16967 Q(a, "m") && _(a) 16968 }, 16969 incrementSeconds: function () { 16970 var a = e.clone().add(1, "s"); 16971 Q(a, "s") && _(a) 16972 }, 16973 decrementHours: function () { 16974 var a = e.clone().subtract(1, "h"); 16975 Q(a, "h") && _(a) 16976 }, 16977 decrementMinutes: function () { 16978 var a = e.clone().subtract(d.stepping, "m"); 16979 Q(a, "m") && _(a) 16980 }, 16981 decrementSeconds: function () { 16982 var a = e.clone().subtract(1, "s"); 16983 Q(a, "s") && _(a) 16984 }, 16985 togglePeriod: function () { 16986 _(e.clone().add(e.hours() >= 12 ? -12 : 12, "h")) 16987 }, 16988 togglePicker: function (b) { 16989 var c, e = a(b.target), 16990 f = e.closest("ul"), 16991 g = f.find(".in"), 16992 h = f.find(".collapse:not(.in)"); 16993 if (g && g.length) { 16994 if (c = g.data("collapse"), c && c.transitioning) return; 16995 g.collapse ? (g.collapse("hide"), h.collapse("show")) : (g.removeClass("in"), h.addClass("in")), e.is("span") ? e.toggleClass(d.icons.time + " " + d.icons.date) : e.find("span").toggleClass(d.icons.time + " " + d.icons.date) 16996 } 16997 }, 16998 showPicker: function () { 16999 o.find(".timepicker > div:not(.timepicker-picker)").hide(), o.find(".timepicker .timepicker-picker").show() 17000 }, 17001 showHours: function () { 17002 o.find(".timepicker .timepicker-picker").hide(), o.find(".timepicker .timepicker-hours").show() 17003 }, 17004 showMinutes: function () { 17005 o.find(".timepicker .timepicker-picker").hide(), o.find(".timepicker .timepicker-minutes").show() 17006 }, 17007 showSeconds: function () { 17008 o.find(".timepicker .timepicker-picker").hide(), o.find(".timepicker .timepicker-seconds").show() 17009 }, 17010 selectHour: function (b) { 17011 var c = parseInt(a(b.target).text(), 10); 17012 h || (e.hours() >= 12 ? 12 !== c && (c += 12) : 12 === c && (c = 0)), _(e.clone().hours(c)), ca.showPicker.call(l) 17013 }, 17014 selectMinute: function (b) { 17015 _(e.clone().minutes(parseInt(a(b.target).text(), 10))), ca.showPicker.call(l) 17016 }, 17017 selectSecond: function (b) { 17018 _(e.clone().seconds(parseInt(a(b.target).text(), 10))), ca.showPicker.call(l) 17019 }, 17020 clear: ba, 17021 today: function () { 17022 var a = x(); 17023 Q(a, "d") && _(a) 17024 }, 17025 close: aa 17026 }, 17027 da = function (b) { 17028 return a(b.currentTarget).is(".disabled") ? !1 : (ca[a(b.currentTarget).data("action")].apply(l, arguments), !1) 17029 }, 17030 ea = function () { 17031 var b, c = { 17032 year: function (a) { 17033 return a.month(0).date(1).hours(0).seconds(0).minutes(0) 17034 }, 17035 month: function (a) { 17036 return a.date(1).hours(0).seconds(0).minutes(0) 17037 }, 17038 day: function (a) { 17039 return a.hours(0).seconds(0).minutes(0) 17040 }, 17041 hour: function (a) { 17042 return a.seconds(0).minutes(0) 17043 }, 17044 minute: function (a) { 17045 return a.seconds(0) 17046 } 17047 }; 17048 return g.prop("disabled") || !d.ignoreReadonly && g.prop("readonly") || o ? l : (void 0 !== g.val() && 0 !== g.val().trim().length ? _(ga(g.val().trim())) : d.useCurrent && m && (g.is("input") && 0 === g.val().trim().length || d.inline) && (b = x(), "string" == typeof d.useCurrent && (b = c[d.useCurrent](b)), _(b)), o = F(), L(), R(), o.find(".timepicker-hours").hide(), o.find(".timepicker-minutes").hide(), o.find(".timepicker-seconds").hide(), $(), K(), a(window).on("resize", H), o.on("click", "[data-action]", da), o.on("mousedown", !1), n && n.hasClass("btn") && n.toggleClass("active"), o.show(), H(), d.focusOnShow && !g.is(":focus") && g.focus(), I({ 17049 type: "dp.show" 17050 }), l) 17051 }, 17052 fa = function () { 17053 return o ? aa() : ea() 17054 }, 17055 ga = function (a) { 17056 return a = void 0 === d.parseInputDate ? b.isMoment(a) || a instanceof Date ? b(a) : x(a) : d.parseInputDate(a), a.locale(d.locale), a 17057 }, 17058 ha = function (a) { 17059 var b, c, e, f, g = null, 17060 h = [], 17061 i = {}, 17062 j = a.which, 17063 k = "p"; 17064 w[j] = k; 17065 for (b in w) w.hasOwnProperty(b) && w[b] === k && (h.push(b), parseInt(b, 10) !== j && (i[b] = !0)); 17066 for (b in d.keyBinds) 17067 if (d.keyBinds.hasOwnProperty(b) && "function" == typeof d.keyBinds[b] && (e = b.split(" "), e.length === h.length && v[j] === e[e.length - 1])) { 17068 for (f = !0, c = e.length - 2; c >= 0; c--) 17069 if (!(v[e[c]] in i)) { 17070 f = !1; 17071 break 17072 } if (f) { 17073 g = d.keyBinds[b]; 17074 break 17075 } 17076 } g && (g.call(l, o), a.stopPropagation(), a.preventDefault()) 17077 }, 17078 ia = function (a) { 17079 w[a.which] = "r", a.stopPropagation(), a.preventDefault() 17080 }, 17081 ja = function (b) { 17082 var c = a(b.target).val().trim(), 17083 d = c ? ga(c) : null; 17084 return _(d), b.stopImmediatePropagation(), !1 17085 }, 17086 ka = function () { 17087 g.on({ 17088 change: ja, 17089 blur: d.debug ? "" : aa, 17090 keydown: ha, 17091 keyup: ia, 17092 focus: d.allowInputToggle ? ea : "" 17093 }), c.is("input") ? g.on({ 17094 focus: ea 17095 }) : n && (n.on("click", fa), n.on("mousedown", !1)) 17096 }, 17097 la = function () { 17098 g.off({ 17099 change: ja, 17100 blur: blur, 17101 keydown: ha, 17102 keyup: ia, 17103 focus: d.allowInputToggle ? aa : "" 17104 }), c.is("input") ? g.off({ 17105 focus: ea 17106 }) : n && (n.off("click", fa), n.off("mousedown", !1)) 17107 }, 17108 ma = function (b) { 17109 var c = {}; 17110 return a.each(b, function () { 17111 var a = ga(this); 17112 a.isValid() && (c[a.format("YYYY-MM-DD")] = !0) 17113 }), Object.keys(c).length ? c : !1 17114 }, 17115 na = function (b) { 17116 var c = {}; 17117 return a.each(b, function () { 17118 c[this] = !0 17119 }), Object.keys(c).length ? c : !1 17120 }, 17121 oa = function () { 17122 var a = d.format || "L LT"; 17123 i = a.replace(/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g, function (a) { 17124 var b = e.localeData().longDateFormat(a) || a; 17125 return b.replace(/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g, function (a) { 17126 return e.localeData().longDateFormat(a) || a 17127 }) 17128 }), j = d.extraFormats ? d.extraFormats.slice() : [], j.indexOf(a) < 0 && j.indexOf(i) < 0 && j.push(i), h = i.toLowerCase().indexOf("a") < 1 && i.replace(/\[.*?\]/g, "").indexOf("h") < 1, y("y") && (p = 2), y("M") && (p = 1), y("d") && (p = 0), k = Math.max(p, k), m || _(e) 17129 }; 17130 if (l.destroy = function () { 17131 aa(), la(), c.removeData("DateTimePicker"), c.removeData("date") 17132 }, l.toggle = fa, l.show = ea, l.hide = aa, l.disable = function () { 17133 return aa(), n && n.hasClass("btn") && n.addClass("disabled"), g.prop("disabled", !0), l 17134 }, l.enable = function () { 17135 return n && n.hasClass("btn") && n.removeClass("disabled"), g.prop("disabled", !1), l 17136 }, l.ignoreReadonly = function (a) { 17137 if (0 === arguments.length) return d.ignoreReadonly; 17138 if ("boolean" != typeof a) throw new TypeError("ignoreReadonly () expects a boolean parameter"); 17139 return d.ignoreReadonly = a, l 17140 }, l.options = function (b) { 17141 if (0 === arguments.length) return a.extend(!0, {}, d); 17142 if (!(b instanceof Object)) throw new TypeError("options() options parameter should be an object"); 17143 return a.extend(!0, d, b), a.each(d, function (a, b) { 17144 if (void 0 === l[a]) throw new TypeError("option " + a + " is not recognized!"); 17145 l[a](b) 17146 }), l 17147 }, l.date = function (a) { 17148 if (0 === arguments.length) return m ? null : e.clone(); 17149 if (!(null === a || "string" == typeof a || b.isMoment(a) || a instanceof Date)) throw new TypeError("date() parameter must be one of [null, string, moment or Date]"); 17150 return _(null === a ? null : ga(a)), l 17151 }, l.format = function (a) { 17152 if (0 === arguments.length) return d.format; 17153 if ("string" != typeof a && ("boolean" != typeof a || a !== !1)) throw new TypeError("format() expects a sting or boolean:false parameter " + a); 17154 return d.format = a, i && oa(), l 17155 }, l.timeZone = function (a) { 17156 return 0 === arguments.length ? d.timeZone : (d.timeZone = a, l) 17157 }, l.dayViewHeaderFormat = function (a) { 17158 if (0 === arguments.length) return d.dayViewHeaderFormat; 17159 if ("string" != typeof a) throw new TypeError("dayViewHeaderFormat() expects a string parameter"); 17160 return d.dayViewHeaderFormat = a, l 17161 }, l.extraFormats = function (a) { 17162 if (0 === arguments.length) return d.extraFormats; 17163 if (a !== !1 && !(a instanceof Array)) throw new TypeError("extraFormats() expects an array or false parameter"); 17164 return d.extraFormats = a, j && oa(), l 17165 }, l.disabledDates = function (b) { 17166 if (0 === arguments.length) return d.disabledDates ? a.extend({}, d.disabledDates) : d.disabledDates; 17167 if (!b) return d.disabledDates = !1, $(), l; 17168 if (!(b instanceof Array)) throw new TypeError("disabledDates() expects an array parameter"); 17169 return d.disabledDates = ma(b), d.enabledDates = !1, $(), l 17170 }, l.enabledDates = function (b) { 17171 if (0 === arguments.length) return d.enabledDates ? a.extend({}, d.enabledDates) : d.enabledDates; 17172 if (!b) return d.enabledDates = !1, $(), l; 17173 if (!(b instanceof Array)) throw new TypeError("enabledDates() expects an array parameter"); 17174 return d.enabledDates = ma(b), d.disabledDates = !1, $(), l 17175 }, l.daysOfWeekDisabled = function (a) { 17176 if (0 === arguments.length) return d.daysOfWeekDisabled.splice(0); 17177 if ("boolean" == typeof a && !a) return d.daysOfWeekDisabled = !1, $(), l; 17178 if (!(a instanceof Array)) throw new TypeError("daysOfWeekDisabled() expects an array parameter"); 17179 if (d.daysOfWeekDisabled = a.reduce(function (a, b) { 17180 return b = parseInt(b, 10), b > 6 || 0 > b || isNaN(b) ? a : (-1 === a.indexOf(b) && a.push(b), a) 17181 }, []).sort(), d.useCurrent && !d.keepInvalid) { 17182 for (var b = 0; !Q(e, "d");) { 17183 if (e.add(1, "d"), 7 === b) throw "Tried 7 times to find a valid date"; 17184 b++ 17185 } 17186 _(e) 17187 } 17188 return $(), l 17189 }, l.maxDate = function (a) { 17190 if (0 === arguments.length) return d.maxDate ? d.maxDate.clone() : d.maxDate; 17191 if ("boolean" == typeof a && a === !1) return d.maxDate = !1, $(), l; 17192 "string" == typeof a && ("now" === a || "moment" === a) && (a = x()); 17193 var b = ga(a); 17194 if (!b.isValid()) throw new TypeError("maxDate() Could not parse date parameter: " + a); 17195 if (d.minDate && b.isBefore(d.minDate)) throw new TypeError("maxDate() date parameter is before options.minDate: " + b.format(i)); 17196 return d.maxDate = b, d.useCurrent && !d.keepInvalid && e.isAfter(a) && _(d.maxDate), f.isAfter(b) && (f = b.clone().subtract(d.stepping, "m")), $(), l 17197 }, l.minDate = function (a) { 17198 if (0 === arguments.length) return d.minDate ? d.minDate.clone() : d.minDate; 17199 if ("boolean" == typeof a && a === !1) return d.minDate = !1, $(), l; 17200 "string" == typeof a && ("now" === a || "moment" === a) && (a = x()); 17201 var b = ga(a); 17202 if (!b.isValid()) throw new TypeError("minDate() Could not parse date parameter: " + a); 17203 if (d.maxDate && b.isAfter(d.maxDate)) throw new TypeError("minDate() date parameter is after options.maxDate: " + b.format(i)); 17204 return d.minDate = b, d.useCurrent && !d.keepInvalid && e.isBefore(a) && _(d.minDate), f.isBefore(b) && (f = b.clone().add(d.stepping, "m")), $(), l 17205 }, l.defaultDate = function (a) { 17206 if (0 === arguments.length) return d.defaultDate ? d.defaultDate.clone() : d.defaultDate; 17207 if (!a) return d.defaultDate = !1, l; 17208 "string" == typeof a && ("now" === a || "moment" === a) && (a = x()); 17209 var b = ga(a); 17210 if (!b.isValid()) throw new TypeError("defaultDate() Could not parse date parameter: " + a); 17211 if (!Q(b)) throw new TypeError("defaultDate() date passed is invalid according to component setup validations"); 17212 return d.defaultDate = b, (d.defaultDate && d.inline || "" === g.val().trim()) && _(d.defaultDate), l 17213 }, l.locale = function (a) { 17214 if (0 === arguments.length) return d.locale; 17215 if (!b.localeData(a)) throw new TypeError("locale() locale " + a + " is not loaded from moment locales!"); 17216 return d.locale = a, e.locale(d.locale), f.locale(d.locale), i && oa(), o && (aa(), ea()), l 17217 }, l.stepping = function (a) { 17218 return 0 === arguments.length ? d.stepping : (a = parseInt(a, 10), (isNaN(a) || 1 > a) && (a = 1), d.stepping = a, l) 17219 }, l.useCurrent = function (a) { 17220 var b = ["year", "month", "day", "hour", "minute"]; 17221 if (0 === arguments.length) return d.useCurrent; 17222 if ("boolean" != typeof a && "string" != typeof a) throw new TypeError("useCurrent() expects a boolean or string parameter"); 17223 if ("string" == typeof a && -1 === b.indexOf(a.toLowerCase())) throw new TypeError("useCurrent() expects a string parameter of " + b.join(", ")); 17224 return d.useCurrent = a, l 17225 }, l.collapse = function (a) { 17226 if (0 === arguments.length) return d.collapse; 17227 if ("boolean" != typeof a) throw new TypeError("collapse() expects a boolean parameter"); 17228 return d.collapse === a ? l : (d.collapse = a, o && (aa(), ea()), l) 17229 }, l.icons = function (b) { 17230 if (0 === arguments.length) return a.extend({}, d.icons); 17231 if (!(b instanceof Object)) throw new TypeError("icons() expects parameter to be an Object"); 17232 return a.extend(d.icons, b), o && (aa(), ea()), l 17233 }, l.tooltips = function (b) { 17234 if (0 === arguments.length) return a.extend({}, d.tooltips); 17235 if (!(b instanceof Object)) throw new TypeError("tooltips() expects parameter to be an Object"); 17236 return a.extend(d.tooltips, b), o && (aa(), ea()), l 17237 }, l.useStrict = function (a) { 17238 if (0 === arguments.length) return d.useStrict; 17239 if ("boolean" != typeof a) throw new TypeError("useStrict() expects a boolean parameter"); 17240 return d.useStrict = a, l 17241 }, l.sideBySide = function (a) { 17242 if (0 === arguments.length) return d.sideBySide; 17243 if ("boolean" != typeof a) throw new TypeError("sideBySide() expects a boolean parameter"); 17244 return d.sideBySide = a, o && (aa(), ea()), l 17245 }, l.viewMode = function (a) { 17246 if (0 === arguments.length) return d.viewMode; 17247 if ("string" != typeof a) throw new TypeError("viewMode() expects a string parameter"); 17248 if (-1 === r.indexOf(a)) throw new TypeError("viewMode() parameter must be one of (" + r.join(", ") + ") value"); 17249 return d.viewMode = a, k = Math.max(r.indexOf(a), p), K(), l 17250 }, l.toolbarPlacement = function (a) { 17251 if (0 === arguments.length) return d.toolbarPlacement; 17252 if ("string" != typeof a) throw new TypeError("toolbarPlacement() expects a string parameter"); 17253 if (-1 === u.indexOf(a)) throw new TypeError("toolbarPlacement() parameter must be one of (" + u.join(", ") + ") value"); 17254 return d.toolbarPlacement = a, o && (aa(), ea()), l 17255 }, l.widgetPositioning = function (b) { 17256 if (0 === arguments.length) return a.extend({}, d.widgetPositioning); 17257 if ("[object Object]" !== {}.toString.call(b)) throw new TypeError("widgetPositioning() expects an object variable"); 17258 if (b.horizontal) { 17259 if ("string" != typeof b.horizontal) throw new TypeError("widgetPositioning() horizontal variable must be a string"); 17260 if (b.horizontal = b.horizontal.toLowerCase(), -1 === t.indexOf(b.horizontal)) throw new TypeError("widgetPositioning() expects horizontal parameter to be one of (" + t.join(", ") + ")"); 17261 d.widgetPositioning.horizontal = b.horizontal 17262 } 17263 if (b.vertical) { 17264 if ("string" != typeof b.vertical) throw new TypeError("widgetPositioning() vertical variable must be a string"); 17265 if (b.vertical = b.vertical.toLowerCase(), -1 === s.indexOf(b.vertical)) throw new TypeError("widgetPositioning() expects vertical parameter to be one of (" + s.join(", ") + ")"); 17266 d.widgetPositioning.vertical = b.vertical 17267 } 17268 return $(), l 17269 }, l.calendarWeeks = function (a) { 17270 if (0 === arguments.length) return d.calendarWeeks; 17271 if ("boolean" != typeof a) throw new TypeError("calendarWeeks() expects parameter to be a boolean value"); 17272 return d.calendarWeeks = a, $(), l 17273 }, l.showTodayButton = function (a) { 17274 if (0 === arguments.length) return d.showTodayButton; 17275 if ("boolean" != typeof a) throw new TypeError("showTodayButton() expects a boolean parameter"); 17276 return d.showTodayButton = a, o && (aa(), ea()), l 17277 }, l.showClear = function (a) { 17278 if (0 === arguments.length) return d.showClear; 17279 if ("boolean" != typeof a) throw new TypeError("showClear() expects a boolean parameter"); 17280 return d.showClear = a, o && (aa(), ea()), l 17281 }, l.widgetParent = function (b) { 17282 if (0 === arguments.length) return d.widgetParent; 17283 if ("string" == typeof b && (b = a(b)), null !== b && "string" != typeof b && !(b instanceof a)) throw new TypeError("widgetParent() expects a string or a jQuery object parameter"); 17284 return d.widgetParent = b, o && (aa(), ea()), l 17285 }, l.keepOpen = function (a) { 17286 if (0 === arguments.length) return d.keepOpen; 17287 if ("boolean" != typeof a) throw new TypeError("keepOpen() expects a boolean parameter"); 17288 return d.keepOpen = a, l 17289 }, l.focusOnShow = function (a) { 17290 if (0 === arguments.length) return d.focusOnShow; 17291 if ("boolean" != typeof a) throw new TypeError("focusOnShow() expects a boolean parameter"); 17292 return d.focusOnShow = a, l 17293 }, l.inline = function (a) { 17294 if (0 === arguments.length) return d.inline; 17295 if ("boolean" != typeof a) throw new TypeError("inline() expects a boolean parameter"); 17296 return d.inline = a, l 17297 }, l.clear = function () { 17298 return ba(), l 17299 }, l.keyBinds = function (a) { 17300 return d.keyBinds = a, l 17301 }, l.getMoment = function (a) { 17302 return x(a) 17303 }, l.debug = function (a) { 17304 if ("boolean" != typeof a) throw new TypeError("debug() expects a boolean parameter"); 17305 return d.debug = a, l 17306 }, l.allowInputToggle = function (a) { 17307 if (0 === arguments.length) return d.allowInputToggle; 17308 if ("boolean" != typeof a) throw new TypeError("allowInputToggle() expects a boolean parameter"); 17309 return d.allowInputToggle = a, l 17310 }, l.showClose = function (a) { 17311 if (0 === arguments.length) return d.showClose; 17312 if ("boolean" != typeof a) throw new TypeError("showClose() expects a boolean parameter"); 17313 return d.showClose = a, l 17314 }, l.keepInvalid = function (a) { 17315 if (0 === arguments.length) return d.keepInvalid; 17316 if ("boolean" != typeof a) throw new TypeError("keepInvalid() expects a boolean parameter"); 17317 return d.keepInvalid = a, l 17318 }, l.datepickerInput = function (a) { 17319 if (0 === arguments.length) return d.datepickerInput; 17320 if ("string" != typeof a) throw new TypeError("datepickerInput() expects a string parameter"); 17321 return d.datepickerInput = a, l 17322 }, l.parseInputDate = function (a) { 17323 if (0 === arguments.length) return d.parseInputDate; 17324 if ("function" != typeof a) throw new TypeError("parseInputDate() sholud be as function"); 17325 return d.parseInputDate = a, l 17326 }, l.disabledTimeIntervals = function (b) { 17327 if (0 === arguments.length) return d.disabledTimeIntervals ? a.extend({}, d.disabledTimeIntervals) : d.disabledTimeIntervals; 17328 if (!b) return d.disabledTimeIntervals = !1, $(), l; 17329 if (!(b instanceof Array)) throw new TypeError("disabledTimeIntervals() expects an array parameter"); 17330 return d.disabledTimeIntervals = b, $(), l 17331 }, l.disabledHours = function (b) { 17332 if (0 === arguments.length) return d.disabledHours ? a.extend({}, d.disabledHours) : d.disabledHours; 17333 if (!b) return d.disabledHours = !1, $(), l; 17334 if (!(b instanceof Array)) throw new TypeError("disabledHours() expects an array parameter");
vendor: 4,308 bytes, lines 17335-17419
17335 if (d.disabledHours = na(b), d.enabledHours = !1, d.useCurrent && !d.keepInvalid) { 17336 for (var c = 0; !Q(e, "h");) { 17337 if (e.add(1, "h"), 24 === c) throw "Tried 24 times to find a valid date"; 17338 c++ 17339 } 17340 _(e) 17341 } 17342 return $(), l 17343 }, l.enabledHours = function (b) { 17344 if (0 === arguments.length) return d.enabledHours ? a.extend({}, d.enabledHours) : d.enabledHours; 17345 if (!b) return d.enabledHours = !1, $(), l; 17346 if (!(b instanceof Array)) throw new TypeError("enabledHours() expects an array parameter"); 17347 if (d.enabledHours = na(b), d.disabledHours = !1, d.useCurrent && !d.keepInvalid) { 17348 for (var c = 0; !Q(e, "h");) { 17349 if (e.add(1, "h"), 24 === c) throw "Tried 24 times to find a valid date"; 17350 c++ 17351 } 17352 _(e) 17353 } 17354 return $(), l 17355 }, l.viewDate = function (a) { 17356 if (0 === arguments.length) return f.clone(); 17357 if (!a) return f = e.clone(), l; 17358 if (!("string" == typeof a || b.isMoment(a) || a instanceof Date)) throw new TypeError("viewDate() parameter must be one of [string, moment or Date]"); 17359 return f = ga(a), J(), l 17360 }, c.is("input")) g = c; 17361 else if (g = c.find(d.datepickerInput), 0 === g.size()) g = c.find("input"); 17362 else if (!g.is("input")) throw new Error('CSS class "' + d.datepickerInput + '" cannot be applied to non input element'); 17363 if (c.hasClass("input-group") && (n = 0 === c.find(".datepickerbutton").size() ? c.find(".input-group-addon") : c.find(".datepickerbutton")), !d.inline && !g.is("input")) throw new Error("Could not initialize DateTimePicker without an input element"); 17364 return e = x(), f = e.clone(), a.extend(!0, d, G()), l.options(d), oa(), ka(), g.prop("disabled") && l.disable(), g.is("input") && 0 !== g.val().trim().length ? _(ga(g.val().trim())) : d.defaultDate && void 0 === g.attr("placeholder") && _(d.defaultDate), d.inline && ea(), l 17365 }; 17366 a.fn.datetimepicker = function (b) { 17367 return this.each(function () { 17368 var d = a(this); 17369 d.data("DateTimePicker") || (b = a.extend(!0, {}, a.fn.datetimepicker.defaults, b), d.data("DateTimePicker", c(d, b))) 17370 }) 17371 }, a.fn.datetimepicker.defaults = { 17372 timeZone: "Etc/UTC", 17373 format: !1, 17374 dayViewHeaderFormat: "MMMM YYYY", 17375 extraFormats: !1, 17376 stepping: 1, 17377 minDate: !1, 17378 maxDate: !1, 17379 useCurrent: !0, 17380 collapse: !0, 17381 locale: b.locale(), 17382 defaultDate: !1, 17383 disabledDates: !1, 17384 enabledDates: !1, 17385 icons: { 17386 time: "glyphicon glyphicon-time", 17387 date: "glyphicon glyphicon-calendar", 17388 up: "glyphicon glyphicon-chevron-up", 17389 down: "glyphicon glyphicon-chevron-down", 17390 previous: "glyphicon glyphicon-chevron-left", 17391 next: "glyphicon glyphicon-chevron-right", 17392 today: "glyphicon glyphicon-screenshot", 17393 clear: "glyphicon glyphicon-trash", 17394 close: "glyphicon glyphicon-remove" 17395 }, 17396 tooltips: { 17397 today: "Go to today", 17398 clear: "Clear selection", 17399 close: "Close the picker", 17400 selectMonth: "Select Month", 17401 prevMonth: "Previous Month", 17402 nextMonth: "Next Month", 17403 selectYear: "Select Year", 17404 prevYear: "Previous Year", 17405 nextYear: "Next Year", 17406 selectDecade: "Select Decade", 17407 prevDecade: "Previous Decade", 17408 nextDecade: "Next Decade", 17409 prevCentury: "Previous Century", 17410 nextCentury: "Next Century", 17411 pickHour: "Pick Hour", 17412 incrementHour: "Increment Hour", 17413 decrementHour: "Decrement Hour", 17414 pickMinute: "Pick Minute", 17415 incrementMinute: "Increment Minute", 17416 decrementMinute: "Decrement Minute", 17417 pickSecond: "Pick Second", 17418 incrementSecond: "Increment Second", 17419 decrementSecond: "Decrement Second",
17420 togglePeriod: "Toggle Period", 17421 selectTime: "Select Time" 17422 }, 17423 useStrict: !1, 17424 sideBySide: !1, 17425 daysOfWeekDisabled: !1, 17426 calendarWeeks: !1, 17427 viewMode: "days", 17428 toolbarPlacement: "default", 17429 showTodayButton: !1, 17430 showClear: !1, 17431 showClose: !1, 17432 widgetPositioning: { 17433 horizontal: "auto", 17434 vertical: "auto" 17435 }, 17436 widgetParent: null, 17437 ignoreReadonly: !1, 17438 keepOpen: !1, 17439 focusOnShow: !0, 17440 inline: !1, 17441 keepInvalid: !1, 17442 datepickerInput: ".datepickerinput", 17443 keyBinds: { 17444 up: function (a) { 17445 if (a) { 17446 var b = this.date() || this.getMoment(); 17447 a.find(".datepicker").is(":visible") ? this.date(b.clone().subtract(7, "d")) : this.date(b.clone().add(this.stepping(), "m")) 17448 } 17449 }, 17450 down: function (a) { 17451 if (!a) return void this.show(); 17452 var b = this.date() || this.getMoment(); 17453 a.find(".datepicker").is(":visible") ? this.date(b.clone().add(7, "d")) : this.date(b.clone().subtract(this.stepping(), "m")) 17454 }, 17455 "control up": function (a) { 17456 if (a) { 17457 var b = this.date() || this.getMoment(); 17458 a.find(".datepicker").is(":visible") ? this.date(b.clone().subtract(1, "y")) : this.date(b.clone().add(1, "h")) 17459 } 17460 }, 17461 "control down": function (a) { 17462 if (a) { 17463 var b = this.date() || this.getMoment(); 17464 a.find(".datepicker").is(":visible") ? this.date(b.clone().add(1, "y")) : this.date(b.clone().subtract(1, "h")) 17465 } 17466 }, 17467 left: function (a) { 17468 if (a) { 17469 var b = this.date() || this.getMoment(); 17470 a.find(".datepicker").is(":visible") && this.date(b.clone().subtract(1, "d")) 17471 } 17472 }, 17473 right: function (a) { 17474 if (a) { 17475 var b = this.date() || this.getMoment(); 17476 a.find(".datepicker").is(":visible") && this.date(b.clone().add(1, "d")) 17477 } 17478 }, 17479 pageUp: function (a) { 17480 if (a) { 17481 var b = this.date() || this.getMoment(); 17482 a.find(".datepicker").is(":visible") && this.date(b.clone().subtract(1, "M")) 17483 } 17484 }, 17485 pageDown: function (a) { 17486 if (a) { 17487 var b = this.date() || this.getMoment(); 17488 a.find(".datepicker").is(":visible") && this.date(b.clone().add(1, "M")) 17489 } 17490 }, 17491 enter: function () { 17492 this.hide() 17493 }, 17494 escape: function () { 17495 this.hide() 17496 }, 17497 "control space": function (a) { 17498 a.find(".timepicker").is(":visible") && a.find('.btn[data-action="togglePeriod"]').click() 17499 }, 17500 t: function () { 17501 this.date(this.getMoment()) 17502 }, 17503 "delete": function () { 17504 this.clear() 17505 } 17506 }, 17507 debug: !1, 17508 allowInputToggle: !1, 17509 disabledTimeIntervals: !1, 17510 disabledHours: !1, 17511 enabledHours: !1, 17512 viewDate: !1 17513 } 17514}); 17515 17516 17517/*! 17518 * datepair.js v0.4.14 - A javascript plugin for intelligently selecting date and time ranges inspired by Google Calendar. 17519 * Copyright (c) 2015 Jon Thornton - http://jonthornton.github.com/Datepair.js 17520 * License: MIT 17521 */ 17522! function (a, b) { 17523 "use strict"; 17524 17525 function c(a, b) { 17526 var c = b || {}; 17527 for (var d in a) d in c || (c[d] = a[d]); 17528 return c 17529 } 17530 17531 function d(a, c) { 17532 if (h) h(a).trigger(c); 17533 else { 17534 var d = b.createEvent("CustomEvent"); 17535 d.initCustomEvent(c, !0, !0, {}), a.dispatchEvent(d) 17536 } 17537 } 17538 17539 function e(a, b) { 17540 return h ? h(a).hasClass(b) : a.classList.contains(b) 17541 } 17542 17543 function f(a, b) { 17544 this.dateDelta = null, this.timeDelta = null, this._defaults = { 17545 startClass: "start", 17546 endClass: "end", 17547 timeClass: "time", 17548 dateClass: "date", 17549 defaultDateDelta: 0, 17550 defaultTimeDelta: 36e5, 17551 anchor: "start", 17552 parseTime: function (a) { 17553 return h(a).timepicker("getTime") 17554 }, 17555 updateTime: function (a, b) { 17556 h(a).timepicker("setTime", b) 17557 }, 17558 setMinTime: function (a, b) { 17559 h(a).timepicker("option", "minTime", b) 17560 }, 17561 parseDate: function (a) { 17562 return a.value && h(a).datepicker("getDate") 17563 }, 17564 updateDate: function (a, b) { 17565 h(a).datepicker("update", b) 17566 } 17567 }, this.container = a, this.settings = c(this._defaults, b), this.startDateInput = this.container.querySelector("." + this.settings.startClass + "." + this.settings.dateClass), this.endDateInput = this.container.querySelector("." + this.settings.endClass + "." + this.settings.dateClass), this.startTimeInput = this.container.querySelector("." + this.settings.startClass + "." + this.settings.timeClass), this.endTimeInput = this.container.querySelector("." + this.settings.endClass + "." + this.settings.timeClass), this.refresh(), this._bindC
17567hangeHandler() 17568 } 17569 var g = 864e5, 17570 h = a.Zepto || a.jQuery; 17571 f.prototype = { 17572 constructor: f, 17573 option: function (a, b) { 17574 if ("object" == typeof a) this.settings = c(this.settings, a); 17575 else if ("string" == typeof a && "undefined" != typeof b) this.settings[a] = b; 17576 else if ("string" == typeof a) return this.settings[a]; 17577 this._updateEndMintime() 17578 }, 17579 getTimeDiff: function () { 17580 var a = this.dateDelta + this.timeDelta; 17581 return !(0 > a) || this.startDateInput && this.endDateInput || (a += g), a 17582 }, 17583 refresh: function () { 17584 if (this.startDateInput && this.startDateInput.value && this.endDateInput && this.endDateInput.value) { 17585 var a = this.settings.parseDate(this.startDateInput), 17586 b = this.settings.parseDate(this.endDateInput); 17587 a && b && (this.dateDelta = b.getTime() - a.getTime()) 17588 } 17589 if (this.startTimeInput && this.startTimeInput.value && this.endTimeInput && this.endTimeInput.value) { 17590 var c = this.settings.parseTime(this.startTimeInput), 17591 d = this.settings.parseTime(this.endTimeInput); 17592 c && d && (this.timeDelta = d.getTime() - c.getTime(), this._updateEndMintime()) 17593 } 17594 }, 17595 remove: function () { 17596 this._unbindChangeHandler() 17597 }, 17598 _bindChangeHandler: function () { 17599 h ? h(this.container).on("change.datepair", h.proxy(this.handleEvent, this)) : this.container.addEventListener("change", this, !1) 17600 }, 17601 _unbindChangeHandler: function () { 17602 h ? h(this.container).off("change.datepair") : this.container.removeEventListener("change", this, !1) 17603 }, 17604 handleEvent: function (a) { 17605 this._unbindChangeHandler(), e(a.target, this.settings.dateClass) ? "" != a.target.value ? (this._dateChanged(a.target), this._timeChanged(a.target)) : this.dateDelta = null : e(a.target, this.settings.timeClass) && ("" != a.target.value ? this._timeChanged(a.target) : this.timeDelta = null), this._validateRanges(), this._updateEndMintime(), this._bindChangeHandler() 17606 }, 17607 _dateChanged: function (a) { 17608 if (this.startDateInput && this.endDateInput) { 17609 var b = this.settings.parseDate(this.startDateInput), 17610 c = this.settings.parseDate(this.endDateInput); 17611 if (b && c) 17612 if ("start" == this.settings.anchor && e(a, this.settings.startClass)) { 17613 var d = new Date(b.getTime() + this.dateDelta); 17614 this.settings.updateDate(this.endDateInput, d) 17615 } else if ("end" == this.settings.anchor && e(a, this.settings.endClass)) { 17616 var d = new Date(c.getTime() - this.dateDelta); 17617 this.settings.updateDate(this.startDateInput, d) 17618 } else if (b > c) { 17619 var f = e(a, this.settings.startClass) ? this.endDateInput : this.startDateInput, 17620 h = this.settings.parseDate(a); 17621 this.dateDelta = 0, this.settings.updateDate(f, h) 17622 } else this.dateDelta = c.getTime() - b.getTime(); 17623 else if (null !== this.settings.defaultDateDelta) { 17624 if (b) { 17625 var i = new Date(b.getTime() + this.settings.defaultDateDelta * g); 17626 this.settings.updateDate(this.endDateInput, i) 17627 } else if (c) { 17628 var j = new Date(c.getTime() - this.settings.defaultDateDelta * g); 17629 this.settings.updateDate(this.startDateInput, j) 17630 } 17631 this.dateDelta = this.settings.defaultDateDelta * g 17632 } else this.dateDelta = null 17633 } 17634 }, 17635 _timeChanged: function (a) { 17636 if (this.startTimeInput && this.endTimeInput) { 17637 var b = this.settings.parseTime(this.startTimeInput), 17638 c = this.settings.parseTime(this.endTimeInput); 17639 if (b && c) 17640 if ("start" == this.settings.anchor && e(a, this.settings.startClass)) { 17641 var d = new Date(b.getTime() + this.timeDelta); 17642 this.settings.updateTime(this.endTimeInput, d), c = this.settings.parseTime(this.endTimeInput), this._doMidnightRollover(b, c) 17643 } else if ("end" == this.settings.anchor && e(a, this.settings.endClass)) { 17644 var d = new Date(c.getTime() - this.timeDelta); 17645 this.settings.updateTime(this.startTimeInput, d), b = this.settings.parseTime(this.startTimeInput), this._doMidnightRollover(b, c) 17646 } else { 17647 this._doMidnightRollover(b, c); 17648 var f, g; 17649 if (this.startDateInput && this.endDateInput && (f = this.settings.parseDate(this.startDateInput), g = this.settings.parseDate(this.endDateInput)), +f == +g && b > c) { 17650 var h = e(a, this.settings.endClass) ? this.endTimeInput : this.startTimeInput, 17651 i = e(a, this.settings.startClass) ? this.endTimeInput : this.startTimeInput, 17652 j = this.settings.parseTime(h); 17653 this.timeDelta = 0, this.settings.updateTime(i, j) 17654 } else this.timeDelta = c.getTime() - b.getTime() 17655 } else if (null !== this.settings.defaultTimeDelta) { 17656 if (b) { 17657 var k = new Date(b.getTime() + this.settings.defaultTimeDelta); 17658 this.settings.updateTime(this.endTimeInput, k) 17659 } else if (c) { 17660 var l = new Date(c.getTime() - this.settings.defaultTimeDelta); 17661 this.settings.updateTime(this.startTimeInput, l) 17662 } 17663 this.timeDelta = this.settings.defaultTimeDelta 17664 } else this.timeDelta = null 17665 } 17666 }, 17667 _doMidnightRollover: function (a, b) { 17668 if (this.startDateInput && this.endDateInput) { 17669 var c = this.settings.parseDate(this.endDateInput), 17670 d = this.settings.parseDate(this.startDateInput), 17671 e = b.getTime() - a.getTime(), 17672 f = a > b ? g : -1 * g; 17673 null !== this.dateDelta && this.dateDelta + this.timeDelta <= g && this.dateDelta + e != 0 && (f > 0 || 0 != this.dateDelta) && (e >= 0 && this.timeDelta < 0 || 0 > e && this.timeDelta >= 0) && ("start" == this.settings.anchor ? (this.settings.updateDate(this.endDateInput, new Date(c.getTime() + f)), this._dateChanged(this.endDateInput)) : "end" == this.settings.anchor && (this.settings.updateDate(this.startDateInput, new Date(d.getTime() - f)), this._dateChanged(this.startDateInput))), this.timeDelta = e 17674 } 17675 }, 17676 _updateEndMintime: function () { 17677 if ("function" == typeof this.settings.setMinTime) { 17678 var a = null; 17679 "start" == this.settings.anchor && (!this.dateDelta || this.dateDelta < g || this.timeDelta && this.dateDelta + this.timeDelta < g) && (a = this.settings.parseTime(this.startTimeInput)), this.settings.setMinTime(this.endTimeInput, a) 17680 } 17681 }, 17682 _validateRanges: function () { 17683 return this.startTimeInput && this.endTimeInput && null === this.timeDelta ? void d(this.container, "rangeIncomplete") : this.startDateInput && this.endDateInput && null === this.dateDelta ? void d(this.container, "rangeIncomplete") : void (!this.startDateInput || !this.endDateInput || this.dateDelta + this.timeDelta >= 0 ? d(this.container, "rangeSelected") : d(this.container, "rangeError")) 17684 } 17685 }, a.Datepair = f 17686}(window, document), 17687 function (a) { 17688 a && (a.fn.datepair = function (b) { 17689 var c; 17690 return this.each(function () { 17691 var d = a(this), 17692 e = d.data("datepair"), 17693 f = "object" == typeof b && b; 17694 e || (e = new Datepair(this, f), d.data("datepair", e)), "string" == typeof b && (c = e[b]()) 17695 }), c || this 17696 }, a("[data-datepair]").each(function () { 17697 var b = a(this); 17698 b.datepair(b.data()) 17699 })) 17700 }(window.Zepto || window.jQuery); 17701 17702 17703/**! 17704 * easy-pie-chart 17705 * Lightweight plugin to render simple, animated and retina optimized pie charts 17706 * 17707 * @license 17708 * @author Robert Fleischmann <[email protected]> (http://robert-fleischmann.de) 17709 * @version 2.1.7 17710 **/ 17711! function (a, b) { 17712 "function" == typeof define && define.amd ? define(["jquery"], function (a) { 17713 return b(a) 17714 }) : "object" == typeof exports ? module.exports = b(require("jquery")) : b(jQuery) 17715}(this, function (a) { 17716 var b = function (a, b) { 17717 var c, d = document.createElement("canvas"); 17718 a.appendChild(d), "object" == typeof G_vmlCanvasManager && G_vmlCanvasManager.initElement(d); 17719 var e = d.getContext("2d"); 17720 d.width = d.height = b.size; 17721 var f = 1; 17722 window.devicePixelRatio > 1 && (f = window.devicePixelRatio, d.style.width = d.style.height = [b.size, "px"].join(""), d.width = d.height = b.size * f, e.scale(f, f)), e.translate(b.size / 2, b.size / 2), e.rotate((-0.5 + b.rotate / 180) * Math.PI); 17723 var g = (b.size - b.lineWidth) / 2; 17724 b.scaleColor && b.scaleLength && (g -= b.scaleLength + 2), Date.now = Date.now || function () { 17725 return +new Date 17726 }; 17727 var h = function (a, b, c) { 17728 c = Math.min(Math.max(-1, c || 0), 1); 17729 var d = 0 >= c ? !0 : !1; 17730 e.beginPath(), e.arc(0, 0, g, 0, 2 * Math.PI * c, d), e.strokeStyle = a, e.lineWidth = b, e.stroke() 17731 }, 17732 i = function () { 17733 var a, c; 17734 e.lineWidth = 1, e.fillStyle = b.scaleColor, e.save(); 17735 for (var d = 24; d > 0; --d) d % 6 === 0 ? (c = b.scaleLength, a = 0) : (c = .6 * b.scaleLength, a = b.scaleLength - c), e.fillRect(-b.size / 2 + a, 0, c, 1), e.rotate(Math.PI / 12);
17736 e.restore() 17737 }, 17738 j = function () { 17739 return window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || function (a) { 17740 window.setTimeout(a, 1e3 / 60) 17741 } 17742 }(), 17743 k = function () { 17744 b.scaleColor && i(), b.trackColor && h(b.trackColor, b.trackWidth || b.lineWidth, 1) 17745 }; 17746 this.getCanvas = function () { 17747 return d 17748 }, this.getCtx = function () { 17749 return e 17750 }, this.clear = function () { 17751 e.clearRect(b.size / -2, b.size / -2, b.size, b.size) 17752 }, this.draw = function (a) { 17753 b.scaleColor || b.trackColor ? e.getImageData && e.putImageData ? c ? e.putImageData(c, 0, 0) : (k(), c = e.getImageData(0, 0, b.size * f, b.size * f)) : (this.clear(), k()) : this.clear(), e.lineCap = b.lineCap; 17754 var d; 17755 d = "function" == typeof b.barColor ? b.barColor(a) : b.barColor, h(d, b.lineWidth, a / 100) 17756 }.bind(this), this.animate = function (a, c) { 17757 var d = Date.now(); 17758 b.onStart(a, c); 17759 var e = function () { 17760 var f = Math.min(Date.now() - d, b.animate.duration), 17761 g = b.easing(this, f, a, c - a, b.animate.duration); 17762 this.draw(g), b.onStep(a, c, g), f >= b.animate.duration ? b.onStop(a, c) : j(e) 17763 }.bind(this); 17764 j(e) 17765 }.bind(this) 17766 }, 17767 c = function (a, c) { 17768 var d = { 17769 barColor: "#ef1e25", 17770 trackColor: "#f9f9f9", 17771 scaleColor: "#dfe0e0", 17772 scaleLength: 5, 17773 lineCap: "round", 17774 lineWidth: 3, 17775 trackWidth: void 0, 17776 size: 110, 17777 rotate: 0, 17778 animate: { 17779 duration: 1e3, 17780 enabled: !0 17781 }, 17782 easing: function (a, b, c, d, e) { 17783 return b /= e / 2, 1 > b ? d / 2 * b * b + c : -d / 2 * (--b * (b - 2) - 1) + c 17784 }, 17785 onStart: function (a, b) { }, 17786 onStep: function (a, b, c) { }, 17787 onStop: function (a, b) { } 17788 }; 17789 if ("undefined" != typeof b) d.renderer = b; 17790 else { 17791 if ("undefined" == typeof SVGRenderer) throw new Error("Please load either the SVG- or the CanvasRenderer"); 17792 d.renderer = SVGRenderer 17793 } 17794 var e = {}, 17795 f = 0, 17796 g = function () { 17797 this.el = a, this.options = e; 17798 for (var b in d) d.hasOwnProperty(b) && (e[b] = c && "undefined" != typeof c[b] ? c[b] : d[b], "function" == typeof e[b] && (e[b] = e[b].bind(this))); 17799 "string" == typeof e.easing && "undefined" != typeof jQuery && jQuery.isFunction(jQuery.easing[e.easing]) ? e.easing = jQuery.easing[e.easing] : e.easing = d.easing, "number" == typeof e.animate && (e.animate = { 17800 duration: e.animate, 17801 enabled: !0 17802 }), "boolean" != typeof e.animate || e.animate || (e.animate = { 17803 duration: 1e3, 17804 enabled: e.animate 17805 }), this.renderer = new e.renderer(a, e), this.renderer.draw(f), a.dataset && a.dataset.percent ? this.update(parseFloat(a.dataset.percent)) : a.getAttribute && a.getAttribute("data-percent") && this.update(parseFloat(a.getAttribute("data-percent"))) 17806 }.bind(this); 17807 this.update = function (a) { 17808 return a = parseFloat(a), e.animate.enabled ? this.renderer.animate(f, a) : this.renderer.draw(a), f = a, this 17809 }.bind(this), this.disableAnimation = function () { 17810 return e.animate.enabled = !1, this 17811 }, this.enableAnimation = function () { 17812 return e.animate.enabled = !0, this 17813 }, g() 17814 }; 17815 a.fn.easyPieChart = function (b) { 17816 return this.each(function () { 17817 var d; 17818 a.data(this, "easyPieChart") || (d = a.extend({}, b, a(this).data()), a.data(this, "easyPieChart", new c(this, d))) 17819 }) 17820 } 17821}); 17822 17823 17824/*! 17825 jquery.ddslick.min.js 17826 */ 17827(function (e) { 17828 e.fn.ddslick = function (l) { 17829 if (c[l]) { 17830 return c[l].apply(this, Array.prototype.slice.call(arguments, 1)) 17831 } else { 17832 if (typeof l === "object" || !l) { 17833 return c.init.apply(this, arguments) 17834 } else { 17835 e.error("Method " + l + " does not exists.") 17836 } 17837 } 17838 }; 17839 var c = {}, 17840 d = { 17841 data: [], 17842 keepJSONItemsOnTop: false, 17843 width: 260, 17844 height: null, 17845 background: "#eee", 17846 selectText: "", 17847 defaultSelectedIndex: null, 17848 truncateDescription: true, 17849 imagePosition: "left", 17850 showSelectedHTML: true, 17851 clickOffToClose: true, 17852 embedCSS: true, 17853 onSelected: function () { } 17854 }, 17855 i = '<div class="dd-select"><input class="dd-selected-value" type="hidden" /><a class="dd-selected"></a><span class="dd-pointer dd-pointer-down"></span></div>', 17856 a = '<ul class="dd-options"></ul>', 17857 b = '<style id="css-ddslick" type="text/css">.dd-select{ border-radius:2px; border:solid 1px #ccc; position:relative; cursor:pointer;}.dd-desc { color:#aaa; display:block; overflow: hidden; font-weight:normal; line-height: 1.4em; }.dd-selected{ overflow:hidden; display:block; padding:10px; font-weight:bold;}.dd-pointer{ width:0; height:0; position:absolute; right:10px; top:50%; margin-top:-3px;}.dd-pointer-down{ border:solid 5px transparent; border-top:solid 5px #000; }.dd-pointer-up{border:solid 5px transparent !important; border-bottom:solid 5px #000 !important; margin-top:-8px;}.dd-options{ border:solid 1px #ccc; border-top:none; list-style:none; box-shadow:0px 1px 5px #ddd; display:none; position:absolute; z-index:2000; margin:0; padding:0;background:#fff; overflow:auto;}.dd-option{ padding:10px; display:block; border-bottom:solid 1px #ddd; overflow:hidden; text-decoration:none; color:#333; cursor:pointer;-webkit-transition: all 0.25s ease-in-out; -moz-transition: all 0.25s ease-in-out;-o-transition: all 0.25s ease-in-out;-ms-transition: all 0.25s ease-in-out; }.dd-options > li:last-child > .dd-option{ border-bottom:none;}.dd-option:hover{ background:#f3f3f3; color:#000;}.dd-selected-description-truncated { text-overflow: ellipsis; white-space:nowrap; }.dd-option-selected { background:#f6f6f6; }.dd-option-image, .dd-selected-image { vertical-align:middle; float:left; margin-right:5px; max-width:64px;}.dd-image-right { float:right; margin-right:15px; margin-left:5px;}.dd-container{ position:relative;}ââ¬â¹ .dd-selected-text { font-weight:bold}ââ¬â¹</style>'; 17858 c.init = function (l) { 17859 var l = e.extend({}, d, l); 17860 if (e("#css-ddslick").length <= 0 && l.embedCSS) { 17861 e(b).appendTo("head") 17862 } 17863 return this.each(function () { 17864 var p = e(this), 17865 q = p.data("ddslick"); 17866 if (!q) { 17867 var n = [], 17868 o = l.data; 17869 p.find("option").each(function () { 17870 var w = e(this), 17871 v = w.data(); 17872 n.push({ 17873 text: e.trim(w.text()), 17874 value: w.val(), 17875 selected: w.is(":selected"), 17876 description: v.description, 17877 imageSrc: v.imagesrc 17878 }) 17879 }); 17880 if (l.keepJSONItemsOnTop) { 17881 e.merge(l.data, n) 17882 } else { 17883 l.data = e.merge(n, l.data) 17884 } 17885 var m = p, 17886 s = e('<div id="' + p.attr("id") + '"></div>'); 17887 p.replaceWith(s);
17888 p = s; 17889 p.addClass("dd-container").append(i).append(a); 17890 var n = p.find(".dd-select"), 17891 u = p.find(".dd-options"); 17892 u.css({ 17893 width: l.width 17894 }); 17895 n.css({ 17896 width: l.width, 17897 background: l.background 17898 }); 17899 p.css({ 17900 width: l.width 17901 }); 17902 if (l.height != null) { 17903 u.css({ 17904 height: l.height, 17905 overflow: "auto" 17906 }) 17907 } 17908 e.each(l.data, function (v, w) { 17909 if (w.selected) { 17910 l.defaultSelectedIndex = v 17911 } 17912 u.append('<li><a class="dd-option">' + (w.value ? ' <input class="dd-option-value" type="hidden" value="' + w.value + '" />' : "") + (w.imageSrc ? ' <img class="dd-option-image' + (l.imagePosition == "right" ? " dd-image-right" : "") + '" src="' + w.imageSrc + '" />' : "") + (w.text ? ' <label class="dd-option-text">' + w.text + "</label>" : "") + (w.description ? ' <small class="dd-option-description dd-desc">' + w.description + "</small>" : "") + "</a></li>") 17913 }); 17914 var t = { 17915 settings: l, 17916 original: m, 17917 selectedIndex: -1, 17918 selectedItem: null, 17919 selectedData: null 17920 }; 17921 p.data("ddslick", t); 17922 if (l.selectText.length > 0 && l.defaultSelectedIndex == null) { 17923 p.find(".dd-selected").html(l.selectText) 17924 } else { 17925 var r = (l.defaultSelectedIndex != null && l.defaultSelectedIndex >= 0 && l.defaultSelectedIndex < l.data.length) ? l.defaultSelectedIndex : 0; 17926 j(p, r) 17927 } 17928 p.find(".dd-select").on("click.ddslick", function () { 17929 f(p) 17930 }); 17931 p.find(".dd-option").on("click.ddslick", function () { 17932 j(p, e(this).closest("li").index()) 17933 }); 17934 if (l.clickOffToClose) { 17935 u.addClass("dd-click-off-close"); 17936 p.on("click.ddslick", function (v) { 17937 v.stopPropagation() 17938 }); 17939 e("body").on("click", function () { 17940 e(".dd-click-off-close").slideUp(50).siblings(".dd-select").find(".dd-pointer").removeClass("dd-pointer-up") 17941 }) 17942 } 17943 } 17944 }) 17945 }; 17946 c.select = function (l) { 17947 return this.each(function () { 17948 if (l.index !== undefined) { 17949 j(e(this), l.index) 17950 } 17951 }) 17952 }; 17953 c.open = function () { 17954 return this.each(function () { 17955 var m = e(this), 17956 l = m.data("ddslick"); 17957 if (l) { 17958 f(m) 17959 } 17960 }) 17961 }; 17962 c.close = function () { 17963 return this.each(function () { 17964 var m = e(this), 17965 l = m.data("ddslick"); 17966 if (l) { 17967 k(m) 17968 } 17969 }) 17970 }; 17971 c.destroy = function () { 17972 return this.each(function () { 17973 var n = e(this), 17974 m = n.data("ddslick"); 17975 if (m) { 17976 var l = m.original; 17977 n.removeData("ddslick").unbind(".ddslick").replaceWith(l) 17978 } 17979 }) 17980 }; 17981 17982 function j(q, s) { 17983 var u = q.data("ddslick"); 17984 var r = q.find(".dd-selected"), 17985 n = r.siblings(".dd-selected-value"), 17986 v = q.find(".dd-options"), 17987 l = r.siblings(".dd-pointer"), 17988 p = q.find(".dd-option").eq(s), 17989 m = p.closest("li"), 17990 o = u.settings, 17991 t = u.settings.data[s]; 17992 q.find(".dd-option").removeClass("dd-option-selected"); 17993 p.addClass("dd-option-selected"); 17994 u.selectedIndex = s; 17995 u.selectedItem = m; 17996 u.selectedData = t; 17997 if (o.showSelectedHTML) { 17998 r.html((t.imageSrc ? '<img class="dd-selected-image' + (o.imagePosition == "right" ? " dd-image-right" : "") + '" src="' + t.imageSrc + '" />' : "") + (t.text ? '<label class="dd-selected-text">' + t.text + "</label>" : "") + (t.description ? '<small class="dd-selected-description dd-desc' + (o.truncateDescription ? " dd-selected-description-truncated" : "") + '" >' + t.description + "</small>" : "")) 17999 } else { 18000 r.html(t.text) 18001 } 18002 n.val(t.value); 18003 u.original.val(t.value); 18004 q.data("ddslick", u); 18005 k(q); 18006 g(q); 18007 if (typeof o.onSelected == "function") { 18008 o.onSelected.call(this, u) 18009 } 18010 } 18011 18012 function f(p) { 18013 var o = p.find(".dd-select"), 18014 m = o.siblings(".dd-options"), 18015 l = o.find(".dd-pointer"), 18016 n = m.is(":visible"); 18017 e(".dd-click-off-close").not(m).slideUp(50); 18018 e(".dd-pointer").removeClass("dd-pointer-up"); 18019 if (n) { 18020 m.slideUp("fast"); 18021 l.removeClass("dd-pointer-up") 18022 } else { 18023 m.slideDown("fast"); 18024 l.addClass("dd-pointer-up") 18025 } 18026 h(p) 18027 } 18028 18029 function k(l) {
18030 l.find(".dd-options").slideUp(50); 18031 l.find(".dd-pointer").removeClass("dd-pointer-up").removeClass("dd-pointer-up") 18032 } 18033 18034 function g(o) { 18035 var n = o.find(".dd-select").css("height"); 18036 var m = o.find(".dd-selected-description"); 18037 var l = o.find(".dd-selected-image"); 18038 if (m.length <= 0 && l.length > 0) { 18039 o.find(".dd-selected-text").css("lineHeight", n) 18040 } 18041 } 18042 18043 function h(l) { 18044 l.find(".dd-option").each(function () { 18045 var p = e(this); 18046 var n = p.css("height"); 18047 var o = p.find(".dd-option-description"); 18048 var m = l.find(".dd-option-image"); 18049 if (o.length <= 0 && m.length > 0) { 18050 p.find(".dd-option-text").css("lineHeight", n) 18051 } 18052 }) 18053 } 18054})(jQuery); 18055 18056 18057/*! 18058 * FullCalendar v2.6.0 18059 * Docs & License: http://fullcalendar.io/ 18060 * (c) 2015 Adam Shaw 18061 */ 18062! function (a) { 18063 "function" == typeof define && define.amd ? define(["jquery", "moment"], a) : "object" == typeof exports ? module.exports = a(require("jquery"), require("moment")) : a(jQuery, moment) 18064}(function (a, b) { 18065 function c(a) { 18066 return Q(a, Ra) 18067 } 18068 18069 function d(b) { 18070 var c, d = { 18071 views: b.views || {} 18072 }; 18073 return a.each(b, function (b, e) { 18074 "views" != b && (a.isPlainObject(e) && !/(time|duration|interval)$/i.test(b) && -1 == a.inArray(b, Ra) ? (c = null, a.each(e, function (a, e) { 18075 /^(month|week|day|default|basic(Week|Day)?|agenda(Week|Day)?)$/.test(a) ? (d.views[a] || (d.views[a] = {}), d.views[a][b] = e) : (c || (c = {}), c[a] = e) 18076 }), c && (d[b] = c)) : d[b] = e) 18077 }), d 18078 } 18079 18080 function e(a, b) { 18081 b.left && a.css({ 18082 "border-left-width": 1, 18083 "margin-left": b.left - 1 18084 }), b.right && a.css({ 18085 "border-right-width": 1, 18086 "margin-right": b.right - 1 18087 }) 18088 } 18089 18090 function f(a) { 18091 a.css({ 18092 "margin-left": "", 18093 "margin-right": "", 18094 "border-left-width": "", 18095 "border-right-width": "" 18096 }) 18097 } 18098 18099 function g() { 18100 a("body").addClass("fc-not-allowed") 18101 } 18102 18103 function h() { 18104 a("body").removeClass("fc-not-allowed") 18105 } 18106 18107 function i(b, c, d) { 18108 var e = Math.floor(c / b.length), 18109 f = Math.floor(c - e * (b.length - 1)), 18110 g = [], 18111 h = [], 18112 i = [], 18113 k = 0; 18114 j(b), b.each(function (c, d) { 18115 var j = c === b.length - 1 ? f : e, 18116 l = a(d).outerHeight(!0); 18117 j > l ? (g.push(d), h.push(l), i.push(a(d).height())) : k += l 18118 }), d && (c -= k, e = Math.floor(c / g.length), f = Math.floor(c - e * (g.length - 1))), a(g).each(function (b, c) { 18119 var d = b === g.length - 1 ? f : e, 18120 j = h[b], 18121 k = i[b], 18122 l = d - (j - k); 18123 d > j && a(c).height(l) 18124 }) 18125 } 18126 18127 function j(a) { 18128 a.height("") 18129 } 18130 18131 function k(b) { 18132 var c = 0; 18133 return b.find("> span").each(function (b, d) { 18134 var e = a(d).outerWidth(); 18135 e > c && (c = e) 18136 }), c++ , b.width(c), c 18137 } 18138 18139 function l(a, b) { 18140 return a.height(b).addClass("fc-scroller"), a[0].scrollHeight - 1 > a[0].clientHeight ? !0 : (m(a), !1) 18141 } 18142 18143 function m(a) { 18144 a.height("").removeClass("fc-scroller") 18145 } 18146 18147 function n(b) { 18148 var c = b.css("position"), 18149 d = b.parents().filter(function () { 18150 var b = a(this); 18151 return /(auto|scroll)/.test(b.css("overflow") + b.css("overflow-y") + b.css("overflow-x")) 18152 }).eq(0); 18153 return "fixed" !== c && d.length ? d : a(b[0].ownerDocument || document) 18154 } 18155 18156 function o(a) { 18157 var b = a.offset(); 18158 return { 18159 left: b.left, 18160 right: b.left + a.outerWidth(), 18161 top: b.top, 18162 bottom: b.top + a.outerHeight() 18163 } 18164 } 18165 18166 function p(a) { 18167 var b = a.offset(), 18168 c = r(a), 18169 d = b.left + u(a, "border-left-width") + c.left, 18170 e = b.top + u(a, "border-top-width") + c.top; 18171 return { 18172 left: d, 18173 right: d + a[0].clientWidth, 18174 top: e, 18175 bottom: e + a[0].clientHeight 18176 } 18177 } 18178 18179 function q(a) { 18180 var b = a.offset(), 18181 c = b.left + u(a, "border-left-width") + u(a, "padding-left"), 18182 d = b.top + u(a, "border-top-width") + u(a, "padding-top"); 18183 return { 18184 left: c, 18185 right: c + a.width(), 18186 top: d, 18187 bottom: d + a.height() 18188 } 18189 } 18190 18191 function r(a) { 18192 var b = a.innerWidth() - a[0].clientWidth, 18193 c = { 18194 left: 0, 18195 right: 0, 18196 top: 0, 18197 bottom: a.innerHeight() - a[0].clientHeight 18198 }; 18199 return s() && "rtl" == a.css("direction") ? c.left = b : c.right = b, c 18200 } 18201 18202 function s() {
18203 return null === Sa && (Sa = t()), Sa 18204 } 18205 18206 function t() { 18207 var b = a("<div><div/></div>").css({ 18208 position: "absolute", 18209 top: -1e3, 18210 left: 0, 18211 border: 0, 18212 padding: 0, 18213 overflow: "scroll", 18214 direction: "rtl" 18215 }).appendTo("body"), 18216 c = b.children(), 18217 d = c.offset().left > b.offset().left; 18218 return b.remove(), d 18219 } 18220 18221 function u(a, b) { 18222 return parseFloat(a.css(b)) || 0 18223 } 18224 18225 function v(a) { 18226 return 1 == a.which && !a.ctrlKey 18227 } 18228 18229 function w(a, b) { 18230 var c = { 18231 left: Math.max(a.left, b.left), 18232 right: Math.min(a.right, b.right), 18233 top: Math.max(a.top, b.top), 18234 bottom: Math.min(a.bottom, b.bottom) 18235 }; 18236 return c.left < c.right && c.top < c.bottom ? c : !1 18237 } 18238 18239 function x(a, b) { 18240 return { 18241 left: Math.min(Math.max(a.left, b.left), b.right), 18242 top: Math.min(Math.max(a.top, b.top), b.bottom) 18243 } 18244 } 18245 18246 function y(a) { 18247 return { 18248 left: (a.left + a.right) / 2, 18249 top: (a.top + a.bottom) / 2 18250 } 18251 } 18252 18253 function z(a, b) { 18254 return { 18255 left: a.left - b.left, 18256 top: a.top - b.top 18257 } 18258 } 18259 18260 function A(b) { 18261 var c, d, e = [], 18262 f = []; 18263 for ("string" == typeof b ? f = b.split(/\s*,\s*/) : "function" == typeof b ? f = [b] : a.isArray(b) && (f = b), c = 0; c < f.length; c++) d = f[c], "string" == typeof d ? e.push("-" == d.charAt(0) ? { 18264 field: d.substring(1), 18265 order: -1 18266 } : { 18267 field: d, 18268 order: 1 18269 }) : "function" == typeof d && e.push({ 18270 func: d 18271 }); 18272 return e 18273 } 18274 18275 function B(a, b, c) { 18276 var d, e; 18277 for (d = 0; d < c.length; d++) 18278 if (e = C(a, b, c[d])) return e; 18279 return 0 18280 } 18281 18282 function C(a, b, c) { 18283 return c.func ? c.func(a, b) : D(a[c.field], b[c.field]) * (c.order || 1) 18284 } 18285 18286 function D(b, c) { 18287 return b || c ? null == c ? -1 : null == b ? 1 : "string" === a.type(b) || "string" === a.type(c) ? String(b).localeCompare(String(c)) : b - c : 0 18288 } 18289 18290 function E(a, b) { 18291 var c, d, e, f, g = a.start, 18292 h = a.end, 18293 i = b.start, 18294 j = b.end; 18295 return h > i && j > g ? (g >= i ? (c = g.clone(), e = !0) : (c = i.clone(), e = !1), j >= h ? (d = h.clone(), f = !0) : (d = j.clone(), f = !1), { 18296 start: c, 18297 end: d, 18298 isStart: e, 18299 isEnd: f 18300 }) : void 0 18301 } 18302 18303 function F(a, c) { 18304 return b.duration({ 18305 days: a.clone().stripTime().diff(c.clone().stripTime(), "days"), 18306 ms: a.time() - c.time() 18307 }) 18308 } 18309 18310 function G(a, c) { 18311 return b.duration({ 18312 days: a.clone().stripTime().diff(c.clone().stripTime(), "days") 18313 }) 18314 } 18315 18316 function H(a, c, d) { 18317 return b.duration(Math.round(a.diff(c, d, !0)), d) 18318 } 18319 18320 function I(a, b) { 18321 var c, d, e; 18322 for (c = 0; c < Ua.length && (d = Ua[c], e = J(d, a, b), !(e >= 1 && ba(e))); c++); 18323 return d 18324 } 18325 18326 function J(a, c, d) { 18327 return null != d ? d.diff(c, a, !0) : b.isDuration(c) ? c.as(a) : c.end.diff(c.start, a, !0) 18328 } 18329 18330 function K(a, b, c) { 18331 var d; 18332 return N(c) ? (b - a) / c : (d = c.asMonths(), Math.abs(d) >= 1 && ba(d) ? b.diff(a, "months", !0) / d : b.diff(a, "days", !0) / c.asDays()) 18333 } 18334 18335 function L(a, b) { 18336 var c, d; 18337 return N(a) || N(b) ? a / b : (c = a.asMonths(), d = b.asMonths(), Math.abs(c) >= 1 && ba(c) && Math.abs(d) >= 1 && ba(d) ? c / d : a.asDays() / b.asDays()) 18338 } 18339 18340 function M(a, c) { 18341 var d; 18342 return N(a) ? b.duration(a * c) : (d = a.asMonths(), Math.abs(d) >= 1 && ba(d) ? b.duration({ 18343 months: d * c 18344 }) : b.duration({ 18345 days: a.asDays() * c 18346 })) 18347 } 18348 18349 function N(a) { 18350 return Boolean(a.hours() || a.minutes() || a.seconds() || a.milliseconds()) 18351 } 18352 18353 function O(a) { 18354 return "[object Date]" === Object.prototype.toString.call(a) || a instanceof Date 18355 } 18356 18357 function P(a) { 18358 return /^\d+\:\d+(?:\:\d+\.?(?:\d{3})?)?$/.test(a) 18359 } 18360 18361 function Q(a, b) { 18362 var c, d, e, f, g, h, i = {}; 18363 if (b) 18364 for (c = 0; c < b.length; c++) { 18365 for (d = b[c], e = [], f = a.length - 1; f >= 0;
18365 f--) 18366 if (g = a[f][d], "object" == typeof g) e.unshift(g); 18367 else if (void 0 !== g) { 18368 i[d] = g; 18369 break 18370 } 18371 e.length && (i[d] = Q(e)) 18372 } 18373 for (c = a.length - 1; c >= 0; c--) { 18374 h = a[c]; 18375 for (d in h) d in i || (i[d] = h[d]) 18376 } 18377 return i 18378 } 18379 18380 function R(a) { 18381 var b = function () { }; 18382 return b.prototype = a, new b 18383 } 18384 18385 function S(a, b) { 18386 for (var c in a) U(a, c) && (b[c] = a[c]) 18387 } 18388 18389 function T(a, b) { 18390 var c, d, e = ["constructor", "toString", "valueOf"]; 18391 for (c = 0; c < e.length; c++) d = e[c], a[d] !== Object.prototype[d] && (b[d] = a[d]) 18392 } 18393 18394 function U(a, b) { 18395 return Ya.call(a, b) 18396 } 18397 18398 function V(b) { 18399 return /undefined|null|boolean|number|string/.test(a.type(b)) 18400 } 18401 18402 function W(b, c, d) { 18403 if (a.isFunction(b) && (b = [b]), b) { 18404 var e, f; 18405 for (e = 0; e < b.length; e++) f = b[e].apply(c, d) || f; 18406 return f 18407 } 18408 } 18409 18410 function X() { 18411 for (var a = 0; a < arguments.length; a++) 18412 if (void 0 !== arguments[a]) return arguments[a] 18413 } 18414 18415 function Y(a) { 18416 return (a + "").replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/'/g, "'").replace(/"/g, """).replace(/\n/g, "<br />") 18417 } 18418 18419 function Z(a) { 18420 return a.replace(/&.*?;/g, "") 18421 } 18422 18423 function $(b) { 18424 var c = []; 18425 return a.each(b, function (a, b) { 18426 null != b && c.push(a + ":" + b) 18427 }), c.join(";") 18428 } 18429 18430 function _(a) { 18431 return a.charAt(0).toUpperCase() + a.slice(1) 18432 } 18433 18434 function aa(a, b) { 18435 return a - b 18436 } 18437 18438 function ba(a) { 18439 return a % 1 === 0 18440 } 18441 18442 function ca(a, b) { 18443 var c = a[b]; 18444 return function () { 18445 return c.apply(a, arguments) 18446 } 18447 } 18448 18449 function da(a, b) { 18450 var c, d, e, f, g = function () { 18451 var h = +new Date - f; 18452 b > h && h > 0 ? c = setTimeout(g, b - h) : (c = null, a.apply(e, d), c || (e = d = null)) 18453 }; 18454 return function () { 18455 e = this, d = arguments, f = +new Date, c || (c = setTimeout(g, b)) 18456 } 18457 } 18458 18459 function ea(c, d, e) { 18460 var f, g, h, i, j = c[0], 18461 k = 1 == c.length && "string" == typeof j; 18462 return b.isMoment(j) ? (i = b.apply(null, c), ga(j, i)) : O(j) || void 0 === j ? i = b.apply(null, c) : (f = !1, g = !1, k ? Za.test(j) ? (j += "-01", c = [j], f = !0, g = !0) : (h = $a.exec(j)) && (f = !h[5], g = !0) : a.isArray(j) && (g = !0), i = d || f ? b.utc.apply(b, c) : b.apply(null, c), f ? (i._ambigTime = !0, i._ambigZone = !0) : e && (g ? i._ambigZone = !0 : k && (i.utcOffset ? i.utcOffset(j) : i.zone(j)))), i._fullCalendar = !0, i 18463 } 18464 18465 function fa(a, c) { 18466 var d, e, f = !1, 18467 g = !1, 18468 h = a.length, 18469 i = []; 18470 for (d = 0; h > d; d++) e = a[d], b.isMoment(e) || (e = Pa.moment.parseZone(e)), f = f || e._ambigTime, g = g || e._ambigZone, i.push(e); 18471 for (d = 0; h > d; d++) e = i[d], c || !f || e._ambigTime ? g && !e._ambigZone && (i[d] = e.clone().stripZone()) : i[d] = e.clone().stripTime(); 18472 return i 18473 } 18474 18475 function ga(a, b) { 18476 a._ambigTime ? b._ambigTime = !0 : b._ambigTime && (b._ambigTime = !1), a._ambigZone ? b._ambigZone = !0 : b._ambigZone && (b._ambigZone = !1) 18477 } 18478 18479 function ha(a, b) { 18480 a.year(b[0] || 0).month(b[1] || 0).date(b[2] || 0).hours(b[3] || 0).minutes(b[4] || 0).seconds(b[5] || 0).milliseconds(b[6] || 0) 18481 } 18482 18483 function ia(a, b) { 18484 return ab.format.call(a, b) 18485 } 18486 18487 function ja(a, b) { 18488 return ka(a, pa(b)) 18489 } 18490 18491 function ka(a, b) { 18492 var c, d = ""; 18493 for (c = 0; c < b.length; c++) d += la(a, b[c]); 18494 return d 18495 } 18496 18497 function la(a, b) { 18498 var c, d; 18499 return "string" == typeof b ? b : (c = b.token) ? bb[c] ? bb[c](a) : ia(a, c) : b.maybe && (d = ka(a, b.maybe), d.match(/[1-9]/)) ? d : "" 18500 } 18501 18502 function ma(a, b, c, d, e) { 18503 var f; 18504 return a = Pa.moment.parseZone(a), b = Pa.moment.parseZone(b), f = (a.localeData || a.lang).call(a), c = f.longDateFormat(c) || c, d = d || " - ", na(a, b, pa(c), d, e) 18505 } 18506 18507 function na(a, b, c, d, e) { 18508 var f, g, h, i, j = a.clone().stripZone(), 18509 k = b.clone().stripZone(), 18510 l = "", 18511 m = "", 18512 n = "", 18513 o = "", 18514 p = ""; 18515 for (g = 0; g < c.length && (f = oa(a, b, j, k, c[g]), f !== !1); g++) l += f; 18516 for (h = c.length - 1; h > g && (f = oa(a, b, j, k, c[h]), f !== !1); h--) m = f + m; 18517 for (i = g; h >= i; i++) n += la(a, c[i]), o += la(b, c[i]); 18518 return (n || o) && (p = e ? o + d + n : n + d + o), l + p + m 18519 } 18520 18521 function oa(a, b, c, d, e) { 18522 var f, g; 18523 return "string" == typeof e ? e : (f = e.token) && (g = cb[f.charAt(0)], g && c.isSame(d, g)) ? ia(a, f) : !1 18524 } 18525 18526 function pa(a) { 18527 return a in db ? db[a] : db[a] = qa(a) 18528 } 18529 18530 function qa(a) { 18531 for (var b, c = [], d = /\[([^\]]*)\]|\(([^\)]*)\)|(LTS|LT|(\w)\4*o?)|([^\w\[\(]+)/g; b = d.exec(a);) b[1] ? c.push(b[1]) : b[2] ? c.push({ 18532 maybe: qa(b[2]) 18533 }) : b[3] ? c.push({ 18534 token: b[3] 18535 }) : b[5] && c.push(b[5]); 18536 return c 18537 } 18538 18539 function ra() { } 18540 18541 function sa(a, b) { 18542 var c; 18543 return U(b, "constructor") && (c = b.constructor), "function" != typeof c && (c = b.constructor = function () { 18544 a.apply(this, arguments) 18545 }), c.prototype = R(a.prototype), S(b, c.prototype), T(b, c.prototype), S(a, c), c 18546 } 18547 18548 function ta(a, b) { 18549 S(b.prototype || b, a.prototype) 18550 } 18551 18552 function ua(a, b) { 18553 return a || b ? a && b ? a.component === b.component && va(a, b) && va(b, a) : !1 : !0 18554 } 18555 18556 function va(a, b) { 18557 for (var c in a) 18558 if (!/^(component|left|right|top|bottom)$/.test(c) && a[c] !== b[c]) return !1; 18559 return !0 18560 } 18561 18562 function wa(a) { 18563 var b = ya(a); 18564 return "background" === b || "inverse-background" === b 18565 } 18566 18567 function xa(a) { 18568 return "inverse-background" === ya(a) 18569 } 18570 18571 function ya(a) { 18572 return X((a.source || {}).rendering, a.rendering) 18573 } 18574 18575 function za(a) { 18576 var b, c, d = {}; 18577 for (b = 0; b < a.length; b++) c = a[b], (d[c._id] || (d[c._id] = [])).push(c); 18578 return d 18579 } 18580 18581 function Aa(a, b) { 18582 return a.start - b.start 18583 } 18584 18585 function Ba(c) { 18586 var d, e, f, g, h = Pa.dataAttrPrefix; 18587 return h && (h += "-"), d = c.data(h + "event") || null, d && (d = "object" == typeof d ? a.extend({}, d) : {}, e = d.start, null == e && (e = d.time), f = d.duration, g = d.stick, delete d.start, delete d.time, delete d.duration, delete d.stick), null == e && (e = c.data(h + "start")), null == e && (e = c.data(h + "time")), null == f && (f = c.data(h + "duration")), null == g && (g = c.data(h + "stick")), e = null != e ? b.duration(e) : null, f = null != f ? b.duration(f) : null, g = Boolean(g), { 18588 eventProps: d, 18589 startTime: e, 18590 duration: f, 18591 stick: g 18592 } 18593 } 18594 18595 function Ca(a, b) { 18596 var c, d; 18597 for (c = 0; c < b.length; c++)
18598 if (d = b[c], d.leftCol <= a.rightCol && d.rightCol >= a.leftCol) return !0; 18599 return !1 18600 } 18601 18602 function Da(a, b) { 18603 return a.leftCol - b.leftCol 18604 } 18605 18606 function Ea(a) { 18607 var b, c, d, e = []; 18608 for (b = 0; b < a.length; b++) { 18609 for (c = a[b], d = 0; d < e.length && Ha(c, e[d]).length; d++); 18610 c.level = d, (e[d] || (e[d] = [])).push(c) 18611 } 18612 return e 18613 } 18614 18615 function Fa(a) { 18616 var b, c, d, e, f; 18617 for (b = 0; b < a.length; b++) 18618 for (c = a[b], d = 0; d < c.length; d++) 18619 for (e = c[d], e.forwardSegs = [], f = b + 1; f < a.length; f++) Ha(e, a[f], e.forwardSegs) 18620 } 18621 18622 function Ga(a) { 18623 var b, c, d = a.forwardSegs, 18624 e = 0; 18625 if (void 0 === a.forwardPressure) { 18626 for (b = 0; b < d.length; b++) c = d[b], Ga(c), e = Math.max(e, 1 + c.forwardPressure); 18627 a.forwardPressure = e 18628 } 18629 } 18630 18631 function Ha(a, b, c) { 18632 c = c || []; 18633 for (var d = 0; d < b.length; d++) Ia(a, b[d]) && c.push(b[d]); 18634 return c 18635 } 18636 18637 function Ia(a, b) { 18638 return a.bottom > b.top && a.top < b.bottom 18639 } 18640 18641 function Ja(c, d) { 18642 function e() { 18643 U ? h() && (k(), i()) : f() 18644 } 18645 18646 function f() { 18647 V = O.theme ? "ui" : "fc", c.addClass("fc"), O.isRTL ? c.addClass("fc-rtl") : c.addClass("fc-ltr"), O.theme ? c.addClass("ui-widget") : c.addClass("fc-unthemed"), U = a("<div class='fc-view-container'/>").prependTo(c), S = N.header = new Ma(N, O), T = S.render(), T && c.prepend(T), i(O.defaultView), O.handleWindowResize && (Y = da(m, O.windowResizeDelay), a(window).resize(Y)) 18648 } 18649 18650 function g() { 18651 W && W.removeElement(), S.removeElement(), U.remove(), c.removeClass("fc fc-ltr fc-rtl fc-unthemed ui-widget"), Y && a(window).unbind("resize", Y) 18652 } 18653 18654 function h() { 18655 return c.is(":visible") 18656 } 18657 18658 function i(b) { 18659 ca++ , W && b && W.type !== b && (S.deactivateButton(W.type), H(), W.removeElement(), W = N.view = null), !W && b && (W = N.view = ba[b] || (ba[b] = N.instantiateView(b)), W.setElement(a("<div class='fc-view fc-" + b + "-view' />").appendTo(U)), S.activateButton(b)), W && (Z = W.massageCurrentDate(Z), W.displaying && Z.isWithin(W.intervalStart, W.intervalEnd) || h() && (W.display(Z), I(), u(), v(), q())), I(), ca-- 18660 } 18661 18662 function j(a) { 18663 return h() ? (a && l(), ca++ , W.updateSize(!0), ca-- , !0) : void 0 18664 } 18665 18666 function k() { 18667 h() && l() 18668 } 18669 18670 function l() { 18671 X = "number" == typeof O.contentHeight ? O.contentHeight : "number" == typeof O.height ? O.height - (T ? T.outerHeight(!0) : 0) : Math.round(U.width() / Math.max(O.aspectRatio, .5)) 18672 } 18673 18674 function m(a) { 18675 !ca && a.target === window && W.start && j(!0) && W.trigger("windowResize", aa) 18676 } 18677 18678 function n() { 18679 p(), r() 18680 } 18681 18682 function o() { 18683 h() && (H(), W.displayEvents(ea), I()) 18684 } 18685 18686 function p() { 18687 H(), W.clearEvents(), I() 18688 } 18689 18690 function q() { 18691 !O.lazyFetching || $(W.start, W.end) ? r() : o() 18692 } 18693 18694 function r() { 18695 _(W.start, W.end) 18696 } 18697 18698 function s(a) { 18699 ea = a, o() 18700 } 18701 18702 function t() { 18703 o() 18704 } 18705 18706 function u() { 18707 S.updateTitle(W.title) 18708 } 18709 18710 function v() { 18711 var a = N.getNow(); 18712 a.isWithin(W.intervalStart, W.intervalEnd) ? S.disableButton("today") : S.enableButton("today") 18713 } 18714 18715 function w(a, b) { 18716 W.select(N.buildSelectSpan.apply(N, arguments)) 18717 } 18718 18719 function x() { 18720 W && W.unselect() 18721 } 18722 18723 function y() { 18724 Z = W.computePrevDate(Z), i() 18725 } 18726 18727 function z() { 18728 Z = W.computeNextDate(Z), i() 18729 } 18730 18731 function A() { 18732 Z.add(-1, "years"), i() 18733 } 18734 18735 function B() { 18736 Z.add(1, "years"), i() 18737 } 18738 18739 function C() { 18740 Z = N.getNow(), i() 18741 } 18742 18743 function D(a) { 18744 Z = N.moment(a).stripZone(), i() 18745 } 18746 18747 function E(a) { 18748 Z.add(b.duration(a)), i() 18749 } 18750 18751 function F(a, b) { 18752 var c; 18753 b = b || "day", c = N.getViewSpec(b) || N.getUnitViewSpec(b), Z = a.clone(), i(c ? c.type : null) 18754 } 18755 18756 function G() { 18757 return N.applyTimezone(Z) 18758 } 18759 18760 function H() { 18761 U.css({ 18762 width: "100%", 18763 height: U.height(), 18764 overflow: "hidden" 18765 }) 18766 } 18767 18768 function I() { 18769 U.css({ 18770 width: "", 18771 height: "", 18772 overflow: "" 18773 }) 18774 } 18775 18776 function J() { 18777 return N 18778 } 18779 18780 function K() { 18781 return W 18782 } 18783 18784 function L(a, b) { 18785 return void 0 === b ? O[a] : void (("height" == a || "contentHeight" == a || "aspectRatio" == a) && (O[a] = b, j(!0))) 18786 } 18787 18788 function M(a, b) { 18789 var c = Array.prototype.slice.call(arguments, 2); 18790 return b = b || aa, this.triggerWith(a, b, c), O[a] ? O[a].apply(b, c) : void 0 18791 } 18792 var N = this; 18793 N.initOptions(d || {}); 18794 var O = this.options; 18795 N.render = e, N.destroy = g, N.refetchEvents = n, N.reportEvents = s, N.reportEventChange = t, N.rerenderEvents = o, N.changeView = i, N.select = w, N.unselect = x, N.prev = y, N.next = z, N.prevYear = A, N.nextYear = B, N.today = C, N.gotoDate = D, N.incrementDate = E, N.zoomTo = F, N.getDate = G, N.getCalendar = J, N.getView = K, N.option = L, N.trigger = M; 18796 var P = R(La(O.lang)); 18797 if (O.monthNames && (P._months = O.monthNames), O.monthNamesShort && (P._monthsShort = O.monthNamesShort), O.dayNames && (P._weekdays = O.dayNames), O.dayNamesShort && (P._weekdaysShort = O.dayNamesShort), null != O.firstDay) { 18798 var Q = R(P._week); 18799 Q.dow = O.firstDay, P._week = Q 18800 } 18801 P._fullCalendar_weekCalc = function (a) { 18802 return "function" == typeof a ? a : "local" === a ? a : "iso" === a || "ISO" === a ? "ISO" : void 0 18803 }(O.weekNumberCalculation), N.defaultAllDayEventDuration = b.duration(O.defaultAllDayEventDuration), N.defaultTimedEventDuration = b.duration(O.defaultTimedEventDuration), N.moment = function () { 18804 var a; 18805 return "local" === O.timezone ? (a = Pa.moment.apply(null, arguments), a.hasTime() && a.local()) : a = "UTC" === O.timezone ? Pa.moment.utc.apply(null, arguments) : Pa.moment.parseZone.apply(null, arguments), "_locale" in a ? a._locale = P : a._lang = P, a 18806 }, N.getIsAmbigTimezone = function () { 18807 return "local" !== O.timezone && "UTC" !== O.timezone 18808 }, N.applyTimezone = function (a) { 18809 if (!a.hasTime()) return a.clone(); 18810 var b, c = N.moment(a.toArray()), 18811 d = a.time() - c.time(); 18812 return d && (b = c.clone().add(d), a.time() - b.time() === 0 && (c = b)), c 18813 }, N.getNow = function () { 18814 var a = O.now; 18815 return "function" == typeof a && (a = a()), N.moment(a).stripZone() 18816 }, N.getEventEnd = function (a) { 18817 return a.end ? a.end.clone() : N.getDefaultEventEnd(a.allDay, a.start) 18818 }, N.getDefaultEventEnd = function (a, b) { 18819 var c = b.clone(); 18820 return a ? c.stripTime().add(N.defaultAllDayEventDuration) : c.add(N.defaultTimedEventDuration), N.getIsAmbigTimezone() && c.stripZone(), c 18821 }, N.humanizeDuration = function (a) { 18822 return (a.locale || a.lang).call(a, O.lang).humanize() 18823 }, Na.call(N, O); 18824 var S, T, U, V, W, X, Y, Z, $ = N.isFetchNeeded, 18825 _ = N.fetchEvents, 18826 aa = c[0], 18827 ba = {}, 18828 ca = 0, 18829 ea = []; 18830 Z = null != O.defaultDate ? N.moment(O.defaultDate).stripZone() : N.getNow(), N.getSuggestedViewHeight = function () { 18831 return void 0 === X && k(), X 18832 }, N.isHeightAuto = function () { 18833 return "auto" === O.contentHeight || "auto" === O.height 18834 }, N.freezeContentHeight = H, N.unfreezeContentHeight = I, N.initialize() 18835 } 18836 18837 function Ka(b) { 18838 a.each(tb, function (a, c) { 18839 null == b[a] && (b[a] = c(b)) 18840 }) 18841 } 18842 18843 function La(a) { 18844 var c = b.localeData || b.langData; 18845 return c.call(b, a) || c.call(b, "en") 18846 } 18847 18848 function Ma(b, c) { 18849 function d() { 18850 var b = c.header; 18851 return n = c.theme ? "ui" : "fc", b ? o = a("<div class='fc-toolbar'/>").append(f("left")).append(f("right")).append(f("center")).append('<div class="fc-clear"/>') : void 0 18852 } 18853 18854 function e() { 18855 o.remove(), o = a() 18856 } 18857 18858 function f(d) {
18859 var e = a('<div class="fc-' + d + '"/>'), 18860 f = c.header[d]; 18861 return f && a.each(f.split(" "), function (d) { 18862 var f, g = a(), 18863 h = !0; 18864 a.each(this.split(","), function (d, e) { 18865 var f, i, j, k, l, m, o, q, r, s; 18866 "title" == e ? (g = g.add(a("<h2> </h2>")), h = !1) : ((f = (b.options.customButtons || {})[e]) ? (j = function (a) { 18867 f.click && f.click.call(s[0], a) 18868 }, k = "", l = f.text) : (i = b.getViewSpec(e)) ? (j = function () { 18869 b.changeView(e) 18870 }, p.push(e), k = i.buttonTextOverride, l = i.buttonTextDefault) : b[e] && (j = function () { 18871 b[e]() 18872 }, k = (b.overrides.buttonText || {})[e], l = c.buttonText[e]), j && (m = f ? f.themeIcon : c.themeButtonIcons[e], o = f ? f.icon : c.buttonIcons[e], q = k ? Y(k) : m && c.theme ? "<span class='ui-icon ui-icon-" + m + "'></span>" : o && !c.theme ? "<span class='fc-icon fc-icon-" + o + "'></span>" : Y(l), r = ["fc-" + e + "-button", n + "-button", n + "-state-default"], s = a('<button type="button" class="' + r.join(" ") + '">' + q + "</button>").click(function (a) { 18873 s.hasClass(n + "-state-disabled") || (j(a), (s.hasClass(n + "-state-active") || s.hasClass(n + "-state-disabled")) && s.removeClass(n + "-state-hover")) 18874 }).mousedown(function () { 18875 s.not("." + n + "-state-active").not("." + n + "-state-disabled").addClass(n + "-state-down") 18876 }).mouseup(function () { 18877 s.removeClass(n + "-state-down") 18878 }).hover(function () { 18879 s.not("." + n + "-state-active").not("." + n + "-state-disabled").addClass(n + "-state-hover") 18880 }, function () { 18881 s.removeClass(n + "-state-hover").removeClass(n + "-state-down") 18882 }), g = g.add(s))) 18883 }), h && g.first().addClass(n + "-corner-left").end().last().addClass(n + "-corner-right").end(), g.length > 1 ? (f = a("<div/>"), h && f.addClass("fc-button-group"), f.append(g), e.append(f)) : e.append(g) 18884 }), e 18885 } 18886 18887 function g(a) { 18888 o.find("h2").text(a) 18889 } 18890 18891 function h(a) { 18892 o.find(".fc-" + a + "-button").addClass(n + "-state-active") 18893 } 18894 18895 function i(a) { 18896 o.find(".fc-" + a + "-button").removeClass(n + "-state-active") 18897 } 18898 18899 function j(a) { 18900 o.find(".fc-" + a + "-button").attr("disabled", "disabled").addClass(n + "-state-disabled") 18901 } 18902 18903 function k(a) { 18904 o.find(".fc-" + a + "-button").removeAttr("disabled").removeClass(n + "-state-disabled") 18905 } 18906 18907 function l() { 18908 return p 18909 } 18910 var m = this; 18911 m.render = d, m.removeElement = e, m.updateTitle = g, m.activateButton = h, m.deactivateButton = i, m.disableButton = j, m.enableButton = k, m.getViewsWithButtons = l; 18912 var n, o = a(), 18913 p = [] 18914 } 18915 18916 function Na(c) { 18917 function d(a, b) { 18918 return !L || L > a || b > M 18919 } 18920 18921 function e(a, b) { 18922 L = a, M = b, T = []; 18923 var c = ++R, 18924 d = Q.length; 18925 S = d; 18926 for (var e = 0; d > e; e++) f(Q[e], c) 18927 } 18928 18929 function f(b, c) { 18930 g(b, function (d) { 18931 var e, f, g, h = a.isArray(b.events); 18932 if (c == R) { 18933 if (d) 18934 for (e = 0; e < d.length; e++) f = d[e], g = h ? f : s(f, b), g && T.push.apply(T, w(g)); 18935 S-- , S || N(T) 18936 } 18937 }) 18938 } 18939 18940 function g(b, d) { 18941 var e, f, h = Pa.sourceFetchers; 18942 for (e = 0; e < h.length; e++) { 18943 if (f = h[e].call(K, b, L.clone(), M.clone(), c.timezone, d), f === !0) return; 18944 if ("object" == typeof f) return void g(f, d) 18945 } 18946 var i = b.events; 18947 if (i) a.isFunction(i) ? (K.pushLoading(), i.call(K, L.clone(), M.clone(), c.timezone, function (a) { 18948 d(a), K.popLoading() 18949 })) : a.isArray(i) ? d(i) : d(); 18950 else { 18951 var j = b.url; 18952 if (j) { 18953 var k, l = b.success, 18954 m = b.error, 18955 n = b.complete; 18956 k = a.isFunction(b.data) ? b.data() : b.data; 18957 var o = a.extend({}, k || {}), 18958 p = X(b.startParam, c.startParam), 18959 q = X(b.endParam, c.endParam), 18960 r = X(b.timezoneParam, c.timezoneParam); 18961 p && (o[p] = L.format()), q && (o[q] = M.format()), c.timezone && "local" != c.timezone && (o[r] = c.timezone), K.pushLoading(), a.aja
18961x(a.extend({}, ub, b, { 18962 data: o, 18963 success: function (b) { 18964 b = b || []; 18965 var c = W(l, this, arguments); 18966 a.isArray(c) && (b = c), d(b) 18967 }, 18968 error: function () { 18969 W(m, this, arguments), d() 18970 }, 18971 complete: function () { 18972 W(n, this, arguments), K.popLoading() 18973 } 18974 })) 18975 } else d() 18976 } 18977 } 18978 18979 function h(a) { 18980 var b = i(a); 18981 b && (Q.push(b), S++ , f(b, R)) 18982 } 18983 18984 function i(b) { 18985 var c, d, e = Pa.sourceNormalizers; 18986 if (a.isFunction(b) || a.isArray(b) ? c = { 18987 events: b 18988 } : "string" == typeof b ? c = { 18989 url: b 18990 } : "object" == typeof b && (c = a.extend({}, b)), c) { 18991 for (c.className ? "string" == typeof c.className && (c.className = c.className.split(/\s+/)) : c.className = [], a.isArray(c.events) && (c.origArray = c.events, c.events = a.map(c.events, function (a) { 18992 return s(a, c) 18993 })), d = 0; d < e.length; d++) e[d].call(K, c); 18994 return c 18995 } 18996 } 18997 18998 function j(b) { 18999 Q = a.grep(Q, function (a) { 19000 return !k(a, b) 19001 }), T = a.grep(T, function (a) { 19002 return !k(a.source, b) 19003 }), N(T) 19004 } 19005 19006 function k(a, b) { 19007 return a && b && l(a) == l(b) 19008 } 19009 19010 function l(a) { 19011 return ("object" == typeof a ? a.origArray || a.googleCalendarId || a.url || a.events : null) || a 19012 } 19013 19014 function m(a) { 19015 a.start = K.moment(a.start), a.end ? a.end = K.moment(a.end) : a.end = null, x(a, n(a)), N(T) 19016 } 19017 19018 function n(b) { 19019 var c = {}; 19020 return a.each(b, function (a, b) { 19021 o(a) && void 0 !== b && V(b) && (c[a] = b) 19022 }), c 19023 } 19024 19025 function o(a) { 19026 return !/^_|^(id|allDay|start|end)$/.test(a) 19027 } 19028 19029 function p(a, b) { 19030 var c, d, e, f = s(a); 19031 if (f) { 19032 for (c = w(f), d = 0; d < c.length; d++) e = c[d], e.source || (b && (O.events.push(e), e.source = O), T.push(e)); 19033 return N(T), c 19034 } 19035 return [] 19036 } 19037 19038 function q(b) { 19039 var c, d; 19040 for (null == b ? b = function () { 19041 return !0 19042 } : a.isFunction(b) || (c = b + "", b = function (a) { 19043 return a._id == c 19044 }), T = a.grep(T, b, !0), d = 0; d < Q.length; d++) a.isArray(Q[d].events) && (Q[d].events = a.grep(Q[d].events, b, !0)); 19045 N(T) 19046 } 19047 19048 function r(b) { 19049 return a.isFunction(b) ? a.grep(T, b) : null != b ? (b += "", a.grep(T, function (a) { 19050 return a._id == b 19051 })) : T 19052 } 19053 19054 function s(d, e) { 19055 var f, g, h, i = {}; 19056 if (c.eventDataTransform && (d = c.eventDataTransform(d)), e && e.eventDataTransform && (d = e.eventDataTransform(d)), a.extend(i, d), e && (i.source = e), i._id = d._id || (void 0 === d.id ? "_fc" + vb++ : d.id + ""), d.className ? "string" == typeof d.className ? i.className = d.className.split(/\s+/) : i.className = d.className : i.className = [], f = d.start || d.date, g = d.end, P(f) && (f = b.duration(f)), P(g) && (g = b.duration(g)), d.dow || b.isDuration(f) || b.isDuration(g)) i.start = f ? b.duration(f) : null, i.end = g ? b.duration(g) : null, i._recurring = !0; 19057 else { 19058 if (f && (f = K.moment(f), !f.isValid())) return !1; 19059 g && (g = K.moment(g), g.isValid() || (g = null)), h = d.allDay, void 0 === h && (h = X(e ? e.allDayDefault : void 0, c.allDayDefault)), t(f, g, h, i) 19060 } 19061 return i 19062 } 19063 19064 function t(a, b, c, d) { 19065 d.start = a, d.end = b, d.allDay = c, u(d), Oa(d) 19066 } 19067 19068 function u(a) { 19069 v(a), a.end && !a.end.isAfter(a.start) && (a.end = null), a.end || (c.forceEventDuration ? a.end = K.getDefaultEventEnd(a.allDay, a.start) : a.end = null) 19070 } 19071 19072 function v(a) { 19073 null == a.allDay && (a.allDay = !(a.start.hasTime() || a.end && a.end.hasTime())), a.allDay ? (a.start.stripTime(), a.end && a.end.stripTime()) : (a.start.hasTime() || (a.start = K.applyTimezone(a.start.time(0))), a.end && !a.end.hasTime() && (a.end =
19073K.applyTimezone(a.end.time(0)))) 19074 } 19075 19076 function w(b, c, d) { 19077 var e, f, g, h, i, j, k, l, m, n = []; 19078 if (c = c || L, d = d || M, b) 19079 if (b._recurring) { 19080 if (f = b.dow) 19081 for (e = {}, g = 0; g < f.length; g++) e[f[g]] = !0; 19082 for (h = c.clone().stripTime(); h.isBefore(d);)(!e || e[h.day()]) && (i = b.start, j = b.end, k = h.clone(), l = null, i && (k = k.time(i)), j && (l = h.clone().time(j)), m = a.extend({}, b), t(k, l, !i && !j, m), n.push(m)), h.add(1, "days") 19083 } else n.push(b); 19084 return n 19085 } 19086 19087 function x(b, c, d) { 19088 function e(a, b) { 19089 return d ? H(a, b, d) : c.allDay ? G(a, b) : F(a, b) 19090 } 19091 var f, g, h, i, j, k, l = {}; 19092 return c = c || {}, c.start || (c.start = b.start.clone()), void 0 === c.end && (c.end = b.end ? b.end.clone() : null), null == c.allDay && (c.allDay = b.allDay), u(c), f = { 19093 start: b._start.clone(), 19094 end: b._end ? b._end.clone() : K.getDefaultEventEnd(b._allDay, b._start), 19095 allDay: c.allDay 19096 }, u(f), g = null !== b._end && null === c.end, h = e(c.start, f.start), c.end ? (i = e(c.end, f.end), j = i.subtract(h)) : j = null, a.each(c, function (a, b) { 19097 o(a) && void 0 !== b && (l[a] = b) 19098 }), k = y(r(b._id), g, c.allDay, h, j, l), { 19099 dateDelta: h, 19100 durationDelta: j, 19101 undo: k 19102 } 19103 } 19104 19105 function y(b, c, d, e, f, g) { 19106 var h = K.getIsAmbigTimezone(), 19107 i = []; 19108 return e && !e.valueOf() && (e = null), f && !f.valueOf() && (f = null), a.each(b, function (b, j) { 19109 var k, l; 19110 k = { 19111 start: j.start.clone(), 19112 end: j.end ? j.end.clone() : null, 19113 allDay: j.allDay 19114 }, a.each(g, function (a) { 19115 k[a] = j[a] 19116 }), l = { 19117 start: j._start, 19118 end: j._end, 19119 allDay: d 19120 }, u(l), c ? l.end = null : f && !l.end && (l.end = K.getDefaultEventEnd(l.allDay, l.start)), e && (l.start.add(e), l.end && l.end.add(e)), f && l.end.add(f), h && !l.allDay && (e || f) && (l.start.stripZone(), l.end && l.end.stripZone()), a.extend(j, g, l), Oa(j), i.push(function () { 19121 a.extend(j, k), Oa(j) 19122 }) 19123 }), 19124 function () { 19125 for (var a = 0; a < i.length; a++) i[a]() 19126 } 19127 } 19128 19129 function z(b) { 19130 var d, e = c.businessHours, 19131 f = { 19132 className: "fc-nonbusiness", 19133 start: "09:00", 19134 end: "17:00", 19135 dow: [1, 2, 3, 4, 5], 19136 rendering: "inverse-background" 19137 }, 19138 g = K.getView(); 19139 return e && (d = a.extend({}, f, "object" == typeof e ? e : {})), d ? (b && (d.start = null, d.end = null), w(s(d), g.start, g.end)) : [] 19140 } 19141 19142 function A(a, b) { 19143 var d = b.source || {}, 19144 e = X(b.constraint, d.constraint, c.eventConstraint), 19145 f = X(b.overlap, d.overlap, c.eventOverlap); 19146 return D(a, e, f, b) 19147 } 19148 19149 function B(b, c, d) { 19150 var e, f; 19151 return d && (e = a.extend({}, d, c), f = w(s(e))[0]), f ? A(b, f) : C(b) 19152 } 19153 19154 function C(a) { 19155 return D(a, c.selectConstraint, c.selectOverlap) 19156 } 19157 19158 function D(a, b, c, d) { 19159 var e, f, g, h, i, j; 19160 if (null != b) { 19161 for (e = E(b), f = !1, h = 0; h < e.length; h++) 19162 if (I(e[h], a)) { 19163 f = !0; 19164 break 19165 } if (!f) return !1 19166 } 19167 for (g = K.getPeerEvents(a, d), h = 0; h < g.length; h++) 19168 if (i = g[h], J(i, a)) { 19169 if (c === !1) return !1; 19170 if ("function" == typeof c && !c(i, d)) return !1; 19171 if (d) { 19172 if (j = X(i.overlap, (i.source || {}).overlap), j === !1) return !1; 19173 if ("function" == typeof j && !j(d, i)) return !1 19174 } 19175 } return !0 19176 } 19177 19178 function E(a) { 19179 return "businessHours" === a ? z() : "object" == typeof a ? w(s(a)) : r(a) 19180 } 19181 19182 function I(a, b) { 19183 var c = a.start.clone().stripZone(), 19184 d = K.getEventEnd(a).stripZone(); 19185 return b.start >= c && b.end <= d 19186 } 19187 19188 function J(a, b) { 19189 var c = a.start.clone().stripZone(), 19190 d = K.getEventEnd(a).stripZone(); 19191 return b.start < d && b.end > c 19192 } 19193 var K = this; 19194 K.isFetchNeeded = d, K.fetchEvents = e, K.addEventSource = h, K.removeEventSource = j, K.updateEvent = m, K.renderEvent = p, K.removeEvents = q, K.clientEvents = r, K.mutateEvent = x, K.normalizeEventDates = u, K.normalizeEventTimes = v; 19195 var L, M, N = K.reportEvents, 19196 O = { 19197 events: [] 19198 }, 19199 Q = [O], 19200 R = 0, 19201 S = 0, 19202 T = [];
19203 a.each((c.events ? [c.events] : []).concat(c.eventSources || []), function (a, b) { 19204 var c = i(b); 19205 c && Q.push(c) 19206 }), K.getBusinessHoursEvents = z, K.isEventSpanAllowed = A, K.isExternalSpanAllowed = B, K.isSelectionSpanAllowed = C, K.getEventCache = function () { 19207 return T 19208 } 19209 } 19210 19211 function Oa(a) { 19212 a._allDay = a.allDay, a._start = a.start.clone(), a._end = a.end ? a.end.clone() : null 19213 } 19214 var Pa = a.fullCalendar = { 19215 version: "2.6.0", 19216 internalApiVersion: 2 19217 }, 19218 Qa = Pa.views = {}; 19219 a.fn.fullCalendar = function (b) { 19220 var c = Array.prototype.slice.call(arguments, 1), 19221 d = this; 19222 return this.each(function (e, f) { 19223 var g, h = a(f), 19224 i = h.data("fullCalendar"); 19225 "string" == typeof b ? i && a.isFunction(i[b]) && (g = i[b].apply(i, c), e || (d = g), "destroy" === b && h.removeData("fullCalendar")) : i || (i = new pb(h, b), h.data("fullCalendar", i), i.render()) 19226 }), d 19227 }; 19228 var Ra = ["header", "buttonText", "buttonIcons", "themeButtonIcons"]; 19229 Pa.intersectRanges = E, Pa.applyAll = W, Pa.debounce = da, Pa.isInt = ba, Pa.htmlEscape = Y, Pa.cssToStr = $, Pa.proxy = ca, Pa.capitaliseFirstLetter = _, Pa.getOuterRect = o, Pa.getClientRect = p, Pa.getContentRect = q, Pa.getScrollbarWidths = r; 19230 var Sa = null; 19231 Pa.intersectRects = w, Pa.parseFieldSpecs = A, Pa.compareByFieldSpecs = B, Pa.compareByFieldSpec = C, Pa.flexibleCompare = D, Pa.computeIntervalUnit = I, Pa.divideRangeByDuration = K, Pa.divideDurationByDuration = L, Pa.multiplyDuration = M, Pa.durationHasTime = N; 19232 var Ta = ["sun", "mon", "tue", "wed", "thu", "fri", "sat"], 19233 Ua = ["year", "month", "week", "day", "hour", "minute", "second", "millisecond"]; 19234 Pa.log = function () { 19235 var a = window.console; 19236 return a && a.log ? a.log.apply(a, arguments) : void 0 19237 }, Pa.warn = function () { 19238 var a = window.console; 19239 return a && a.warn ? a.warn.apply(a, arguments) : Pa.log.apply(Pa, arguments) 19240 }; 19241 var Va, Wa, Xa, Ya = {}.hasOwnProperty, 19242 Za = /^\s*\d{4}-\d\d$/, 19243 $a = /^\s*\d{4}-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?)?$/, 19244 _a = b.fn, 19245 ab = a.extend({}, _a); 19246 Pa.moment = function () { 19247 return ea(arguments) 19248 }, Pa.moment.utc = function () { 19249 var a = ea(arguments, !0); 19250 return a.hasTime() && a.utc(), a 19251 }, Pa.moment.parseZone = function () { 19252 return ea(arguments, !0, !0) 19253 }, _a.clone = function () { 19254 var a = ab.clone.apply(this, arguments); 19255 return ga(this, a), this._fullCalendar && (a._fullCalendar = !0), a 19256 }, _a.week = _a.weeks = function (a) { 19257 var b = (this._locale || this._lang)._fullCalendar_weekCalc; 19258 return null == a && "function" == typeof b ? b(this) : "ISO" === b ? ab.isoWeek.apply(this, arguments) : ab.week.apply(this, arguments) 19259 }, _a.time = function (a) { 19260 if (!this._fullCalendar) return ab.time.apply(this, arguments); 19261 if (null == a) return b.duration({ 19262 hours: this.hours(), 19263 minutes: this.minutes(), 19264 seconds: this.seconds(), 19265 milliseconds: this.milliseconds() 19266 }); 19267 this._ambigTime = !1, b.isDuration(a) || b.isMoment(a) || (a = b.duration(a)); 19268 var c = 0; 19269 return b.isDuration(a) && (c = 24 * Math.floor(a.asDays())), this.hours(c + a.hours()).minutes(a.minutes()).seconds(a.seconds()).milliseconds(a.milliseconds()) 19270 }, _a.stripTime = function () { 19271 var a; 19272 return this._ambigTime || (a = this.toArray(), this.utc(), Wa(this, a.slice(0, 3)), this._ambigTime = !0, this._ambigZone = !0), this 19273 }, _a.hasTime = function () { 19274 return !this._ambigTime 19275 }, _a.stripZone = function () { 19276 var a, b; 19277 return this._ambigZone || (a = this.toArray(), b = this._ambigTime, this.utc(), Wa(this, a), this._ambigTime = b || !1, this._ambigZone = !0), this 19278 }
19278, _a.hasZone = function () { 19279 return !this._ambigZone 19280 }, _a.local = function () { 19281 var a = this.toArray(), 19282 b = this._ambigZone; 19283 return ab.local.apply(this, arguments), this._ambigTime = !1, this._ambigZone = !1, b && Xa(this, a), this 19284 }, _a.utc = function () { 19285 return ab.utc.apply(this, arguments), this._ambigTime = !1, this._ambigZone = !1, this 19286 }, a.each(["zone", "utcOffset"], function (a, b) { 19287 ab[b] && (_a[b] = function (a) { 19288 return null != a && (this._ambigTime = !1, this._ambigZone = !1), ab[b].apply(this, arguments) 19289 }) 19290 }), _a.format = function () { 19291 return this._fullCalendar && arguments[0] ? ja(this, arguments[0]) : this._ambigTime ? ia(this, "YYYY-MM-DD") : this._ambigZone ? ia(this, "YYYY-MM-DD[T]HH:mm:ss") : ab.format.apply(this, arguments) 19292 }, _a.toISOString = function () { 19293 return this._ambigTime ? ia(this, "YYYY-MM-DD") : this._ambigZone ? ia(this, "YYYY-MM-DD[T]HH:mm:ss") : ab.toISOString.apply(this, arguments) 19294 }, _a.isWithin = function (a, b) { 19295 var c = fa([this, a, b]); 19296 return c[0] >= c[1] && c[0] < c[2] 19297 }, _a.isSame = function (a, b) { 19298 var c; 19299 return this._fullCalendar ? b ? (c = fa([this, a], !0), ab.isSame.call(c[0], c[1], b)) : (a = Pa.moment.parseZone(a), ab.isSame.call(this, a) && Boolean(this._ambigTime) === Boolean(a._ambigTime) && Boolean(this._ambigZone) === Boolean(a._ambigZone)) : ab.isSame.apply(this, arguments) 19300 }, a.each(["isBefore", "isAfter"], function (a, b) { 19301 _a[b] = function (a, c) { 19302 var d; 19303 return this._fullCalendar ? (d = fa([this, a]), ab[b].call(d[0], d[1], c)) : ab[b].apply(this, arguments) 19304 } 19305 }), Va = "_d" in b() && "updateOffset" in b, Wa = Va ? function (a, c) { 19306 a._d.setTime(Date.UTC.apply(Date, c)), b.updateOffset(a, !1) 19307 } : ha, Xa = Va ? function (a, c) { 19308 a._d.setTime(+new Date(c[0] || 0, c[1] || 0, c[2] || 0, c[3] || 0, c[4] || 0, c[5] || 0, c[6] || 0)), b.updateOffset(a, !1) 19309 } : ha; 19310 var bb = { 19311 t: function (a) { 19312 return ia(a, "a").charAt(0) 19313 }, 19314 T: function (a) { 19315 return ia(a, "A").charAt(0) 19316 } 19317 }; 19318 Pa.formatRange = ma; 19319 var cb = { 19320 Y: "year", 19321 M: "month", 19322 D: "day", 19323 d: "day", 19324 A: "second", 19325 a: "second", 19326 T: "second", 19327 t: "second", 19328 H: "second", 19329 h: "second", 19330 m: "second", 19331 s: "second" 19332 }, 19333 db = {}; 19334 Pa.Class = ra, ra.extend = function () { 19335 var a, b, c = arguments.length; 19336 for (a = 0; c > a; a++) b = arguments[a], c - 1 > a && ta(this, b); 19337 return sa(this, b || {}) 19338 }, ra.mixin = function (a) { 19339 ta(this, a) 19340 }; 19341 var eb = Pa.Emitter = ra.extend({ 19342 callbackHash: null, 19343 on: function (a, b) { 19344 return this.getCallbacks(a).add(b), this 19345 }, 19346 off: function (a, b) { 19347 return this.getCallbacks(a).remove(b), this 19348 }, 19349 trigger: function (a) { 19350 var b = Array.prototype.slice.call(arguments, 1); 19351 return this.triggerWith(a, this, b), this 19352 }, 19353 triggerWith: function (a, b, c) { 19354 var d = this.getCallbacks(a); 19355 return d.fireWith(b, c), this 19356 }, 19357 getCallbacks: function (b) { 19358 var c; 19359 return this.callbackHash || (this.callbackHash = {}), c = this.callbackHash[b], c || (c = this.callbackHash[b] = a.Callbacks()), c 19360 } 19361 }), 19362 fb = ra.extend({ 19363 isHidden: !0, 19364 options: null, 19365 el: null, 19366 documentMousedownProxy: null, 19367 margin: 10, 19368 constructor: function (a) { 19369 this.options = a || {} 19370 }, 19371 show: function () { 19372 this.isHidden && (this.el || this.render(), this.el.show(), this.position(), this.isHidden = !1, this.trigger("show")) 19373 }, 19374 hide: function () { 19375 this.isHidden || (this.el.hide(), this.isHidden = !0, this.trigger("hide")) 19376 }, 19377 render: function () { 19378 var b = this, 19379 c = this.options; 19380 this.el = a('<div class="fc-popover"/>').addClass(c.className || "").css({ 19381 top: 0, 19382 left: 0 19383 }).append(c.content).appendTo(c.parentEl), this.el.on("click", ".fc-close", function () { 19384 b.hide() 19385 }), c.autoHide && a(document).on("mousedown", this.documentMousedownProxy = ca(this, "documentMousedown")) 19386 }, 19387 documentMousedown: function (b) { 19388 this.el && !a(b.target).closest(this.el).length && this.hide() 19389 }, 19390 removeElement: function () { 19391 this.hide(), this.el && (this.el.remove(), this.el = null), a(document).off("mousedown", this.documentMousedownProxy) 19392 }, 19393 position: function () { 19394 var b, c, d, e, f, g = this.options, 19395 h = this.el.offsetParent().offset(), 19396 i = this.el.outerWidth(), 19397 j = this.el.outerHeight(), 19398 k = a(window), 19399 l = n(this.el); 19400 e = g.top || 0, f = void 0 !== g.left ? g.left : void 0 !== g.right ? g.right - i : 0, l.is(window) || l.is(document) ? (l = k, b = 0, c = 0) : (d = l.offset(), b = d.top, c = d.left), b += k.scrollTop(), c += k.scrollLeft(), g.viewportConstrain !== !1 && (e = Math.min(e, b + l.outerHeight() - j - this.margin), e = Math.max(e, b + this.margin), f = Math.min(f, c + l.outerWidth() - i - this.margin), 19401 f = Math.max(f, c + this.margin)), this.el.css({ 19402 top: e - h.top, 19403 left: f - h.left 19404 }) 19405 }, 19406 trigger: function (a) { 19407 this.options[a] && this.options[a].apply(this, Array.prototype.slice.call(arguments, 1)) 19408 } 19409 }), 19410 gb = Pa.CoordCache = ra.extend({ 19411 els: null, 19412 forcedOffsetParentEl: null, 19413 origin: null, 19414 boundingRect: null, 19415 isHorizontal: !1, 19416 isVertical: !1, 19417 lefts: null, 19418 rights: null, 19419 tops: null, 19420 bottoms: null, 19421 constructor: function (b) { 19422 this.els = a(b.els), this.isHorizontal = b.isHorizontal, this.isVertical = b.isVertical, this.forcedOffsetParentEl = b.offsetParent ? a(b.offsetParent) : null 19423 }, 19424 build: function () { 19425 var a = this.forcedOffsetParentEl || this.els.eq(0).offsetParent(); 19426 this.origin = a.offset(), this.boundingRect = this.queryBoundingRect
19426(), this.isHorizontal && this.buildElHorizontals(), this.isVertical && this.buildElVerticals() 19427 }, 19428 clear: function () { 19429 this.origin = null, this.boundingRect = null, this.lefts = null, this.rights = null, this.tops = null, this.bottoms = null 19430 }, 19431 queryBoundingRect: function () { 19432 var a = n(this.els.eq(0)); 19433 return a.is(document) ? void 0 : p(a) 19434 }, 19435 buildElHorizontals: function () { 19436 var b = [], 19437 c = []; 19438 this.els.each(function (d, e) { 19439 var f = a(e), 19440 g = f.offset().left, 19441 h = f.outerWidth(); 19442 b.push(g), c.push(g + h) 19443 }), this.lefts = b, this.rights = c 19444 }, 19445 buildElVerticals: function () { 19446 var b = [], 19447 c = []; 19448 this.els.each(function (d, e) { 19449 var f = a(e), 19450 g = f.offset().top, 19451 h = f.outerHeight(); 19452 b.push(g), c.push(g + h) 19453 }), this.tops = b, this.bottoms = c 19454 }, 19455 getHorizontalIndex: function (a) { 19456 var b, c = this.boundingRect, 19457 d = this.lefts, 19458 e = this.rights, 19459 f = d.length; 19460 if (!c || a >= c.left && a < c.right) 19461 for (b = 0; f > b; b++) 19462 if (a >= d[b] && a < e[b]) return b 19463 }, 19464 getVerticalIndex: function (a) { 19465 var b, c = this.boundingRect, 19466 d = this.tops, 19467 e = this.bottoms, 19468 f = d.length; 19469 if (!c || a >= c.top && a < c.bottom) 19470 for (b = 0; f > b; b++) 19471 if (a >= d[b] && a < e[b]) return b 19472 }, 19473 getLeftOffset: function (a) { 19474 return this.lefts[a] 19475 }, 19476 getLeftPosition: function (a) { 19477 return this.lefts[a] - this.origin.left 19478 }, 19479 getRightOffset: function (a) { 19480 return this.rights[a] 19481 }, 19482 getRightPosition: function (a) { 19483 return this.rights[a] - this.origin.left 19484 }, 19485 getWidth: function (a) { 19486 return this.rights[a] - this.lefts[a] 19487 }, 19488 getTopOffset: function (a) { 19489 return this.tops[a] 19490 }, 19491 getTopPosition: function (a) { 19492 return this.tops[a] - this.origin.top 19493 }, 19494 getBottomOffset: function (a) { 19495 return this.bottoms[a] 19496 }, 19497 getBottomPosition: function (a) { 19498 return this.bottoms[a] - this.origin.top 19499 }, 19500 getHeight: function (a) { 19501 return this.bottoms[a] - this.tops[a] 19502 } 19503 }), 19504 hb = Pa.DragListener = ra.extend({ 19505 options: null, 19506 isListening: !1, 19507 isDragging: !1, 19508 originX: null, 19509 originY: null, 19510 mousemoveProxy: null, 19511 mouseupProxy: null, 19512 subjectEl: null, 19513 subjectHref: null, 19514 scrollEl: null, 19515 scrollBounds: null, 19516 scrollTopVel: null, 19517 scrollLeftVel: null, 19518 scrollIntervalId: null, 19519 scrollHandlerProxy: null, 19520 scrollSensitivity: 30, 19521 scrollSpeed: 200, 19522 scrollIntervalMs: 50, 19523 constructor: function (a) { 19524 a = a || {}, this.options = a, this.subjectEl = a.subjectEl 19525 }, 19526 mousedown: function (a) { 19527 v(a) && (a.preventDefault(), this.startListening(a), this.options.distance || this.startDrag(a)) 19528 }, 19529 startListening: function (b) { 19530 var c; 19531 this.isListening || (b && this.options.scroll && (c = n(a(b.target)), c.is(window) || c.is(document) || (this.scrollEl = c, this.scrollHandlerProxy = da(ca(this, "scrollHandler"), 100), this.scrollEl.on("scroll", this.scrollHandlerProxy))), a(document).on("mousemove", this.mousemoveProxy = ca(this, "mousemove")).on("mouseup", this.mouseupProxy = ca(this, "mouseup")).on("selectstart", this.preventDefault), b ? (this.originX = b.pageX, this.originY = b.pageY) : (this.originX = 0, this.originY = 0), this.isListening = !0, this.listenStart(b)) 19532 }, 19533 listenStart: function (a) { 19534 this.trigger("listenStart", a) 19535 }, 19536 mousemove: function (a) {
19537 var b, c, d = a.pageX - this.originX, 19538 e = a.pageY - this.originY; 19539 this.isDragging || (b = this.options.distance || 1, c = d * d + e * e, c >= b * b && this.startDrag(a)), this.isDragging && this.drag(d, e, a) 19540 }, 19541 startDrag: function (a) { 19542 this.isListening || this.startListening(), this.isDragging || (this.isDragging = !0, this.dragStart(a)) 19543 }, 19544 dragStart: function (a) { 19545 var b = this.subjectEl; 19546 this.trigger("dragStart", a), (this.subjectHref = b ? b.attr("href") : null) && b.removeAttr("href") 19547 }, 19548 drag: function (a, b, c) { 19549 this.trigger("drag", a, b, c), this.updateScroll(c) 19550 }, 19551 mouseup: function (a) { 19552 this.stopListening(a) 19553 }, 19554 stopDrag: function (a) { 19555 this.isDragging && (this.stopScrolling(), this.dragStop(a), this.isDragging = !1) 19556 }, 19557 dragStop: function (a) { 19558 var b = this; 19559 this.trigger("dragStop", a), setTimeout(function () { 19560 b.subjectHref && b.subjectEl.attr("href", b.subjectHref) 19561 }, 0) 19562 }, 19563 stopListening: function (b) { 19564 this.stopDrag(b), this.isListening && (this.scrollEl && (this.scrollEl.off("scroll", this.scrollHandlerProxy), this.scrollHandlerProxy = null), a(document).off("mousemove", this.mousemoveProxy).off("mouseup", this.mouseupProxy).off("selectstart", this.preventDefault), this.mousemoveProxy = null, this.mouseupProxy = null, this.isListening = !1, this.listenStop(b)) 19565 }, 19566 listenStop: function (a) { 19567 this.trigger("listenStop", a) 19568 }, 19569 trigger: function (a) { 19570 this.options[a] && this.options[a].apply(this, Array.prototype.slice.call(arguments, 1)) 19571 }, 19572 preventDefault: function (a) { 19573 a.preventDefault() 19574 }, 19575 computeScrollBounds: function () { 19576 var a = this.scrollEl; 19577 this.scrollBounds = a ? o(a) : null 19578 }, 19579 updateScroll: function (a) { 19580 var b, c, d, e, f = this.scrollSensitivity, 19581 g = this.scrollBounds, 19582 h = 0, 19583 i = 0; 19584 g && (b = (f - (a.pageY - g.top)) / f, c = (f - (g.bottom - a.pageY)) / f, d = (f - (a.pageX - g.left)) / f, e = (f - (g.right - a.pageX)) / f, b >= 0 && 1 >= b ? h = b * this.scrollSpeed * -1 : c >= 0 && 1 >= c && (h = c * this.scrollSpeed), d >= 0 && 1 >= d ? i = d * this.scrollSpeed * -1 : e >= 0 && 1 >= e && (i = e * this.scrollSpeed)), this.setScrollVel(h, i) 19585 }, 19586 setScrollVel: function (a, b) { 19587 this.scrollTopVel = a, this.scrollLeftVel = b, this.constrainScrollVel(), !this.scrollTopVel && !this.scrollLeftVel || this.scrollIntervalId || (this.scrollIntervalId = setInterval(ca(this, "scrollIntervalFunc"), this.scrollIntervalMs)) 19588 }, 19589 constrainScrollVel: function () { 19590 var a = this.scrollEl; 19591 this.scrollTopVel < 0 ? a.scrollTop() <= 0 && (this.scrollTopVel = 0) : this.scrollTopVel > 0 && a.scrollTop() + a[0].clientHeight >= a[0].scrollHeight && (this.scrollTopVel = 0), this.scrollLeftVel < 0 ? a.scrollLeft() <= 0 && (this.scrollLeftVel = 0) : this.scrollLeftVel > 0 && a.scrollLeft() + a[0].clientWidth >= a[0].scrollWidth && (this.scrollLeftVel = 0) 19592 }, 19593 scrollIntervalFunc: function () { 19594 var a = this.scrollEl, 19595 b = this.scrollIntervalMs / 1e3; 19596 this.scrollTopVel && a.scrollTop(a.scrollTop() + this.scrollTopVel * b), this.scrollLeftVel && a.scrollLeft(a.scrollLeft() + this.scrollLeftVel * b), this.constrainScrollVel(), this.scrollTopVel || this.scrollLeftVel || this.stopScrolling() 19597 }, 19598 stopScrolling: function () { 19599 this.scrollIntervalId && (clearInterval(this.scrollIntervalId), this.scrollIntervalId = null, this.scrollStop()) 19600 }, 19601 scrollHandler: function () { 19602 this.scrollIntervalId || this.scrollStop() 19603 }, 19604 scrollStop: function () { } 19605 }), 19606 ib = hb.extend({ 19607 component: null, 19608 origHit: null, 19609 hit: null, 19610 coordAdjust: null, 19611 constructor: function (a, b) { 19612 hb.call(this, b), this.component = a 19613 }, 19614 listenStart: function (a) { 19615 var b, c, d, e = this.subjectEl; 19616 hb.prototype.listenStart.apply(this, arguments), this.computeCoords(), a ? (c = { 19617 left: a.pageX, 19618 top: a.pageY 19619 }, d = c, e && (b = o(e), d = x(d, b)), this.origHit = this.queryHit(d.left, d.top), e && this.options.subjectCenter && (this.origHit && (b = w(this.origHit, b) || b), d = y(b)), this.coordAdjust = z(d, c)) : (this.origHit = null, this.coordAdjust = null) 19620 }, 19621 computeCoords: function () { 19622 this.component.prepareHits(), this.computeScrollBounds() 19623 }, 19624 dragStart: function (a) { 19625 var b; 19626 hb.prototype.dragStart.apply(this, arguments), b = this.queryHit(a.pageX, a.pageY), b && this.hitOver(b) 19627 }, 19628 drag: function (a, b, c) { 19629 var d; 19630 hb.prototype.drag.apply(this, arguments), d = this.queryHit(c.pageX, c.pageY), ua(d, this.hit) || (this.hit && this.hitOut(), d && this.hitOver(d)) 19631 }, 19632 dragStop: function () { 19633 this.hitDone(), hb.prototype.dragStop.apply(this, arguments) 19634 }, 19635 hitOver: function (a) { 19636 var b = ua(a, this.origHit); 19637 this.hit = a, this.trigger("hitOver", this.hit, b, this.origHit) 19638 }, 19639 hitOut: function () { 19640 this.hit && (this.trigger("hitOut", this.hit), this.hitDone(), this.hit = null) 19641 }, 19642 hitDone: function () { 19643 this.hit && this.trigger("hitDone", this.hit) 19644 }, 19645 listenStop: function () { 19646 hb.prototype.listenStop.apply(this, arguments), this.origHit = null, this.hit = null, this.component.releaseHits() 19647 }, 19648 scrollStop: function () { 19649 hb.prototype.scrollStop.apply(this, arguments), this.computeCoords() 19650 }, 19651 queryHit: function (a, b) { 19652 return this.coordAdjust && (a += this.coordAdjust.left, b += this.coordAdjust.top), this.component.queryHit(a, b) 19653 } 19654 }), 19655 jb = ra.extend({ 19656 options: null, 19657 sourceEl: null, 19658 el: null, 19659 parentEl: null, 19660 top0: null, 19661 left0: null, 19662 mouseY0: null, 19663 mouseX0: null, 19664 topDelta: null, 19665 leftDelta: null, 19666 mousemoveProxy: null, 19667 isFollowing: !1, 19668 isHidden: !1, 19669 isAnimating: !1, 19670 constructor: function (b, c) { 19671 this.options = c = c || {}, this.sourceEl = b, this.parentEl = c.parentEl ? a(c.parentEl) : b.parent() 19672 }, 19673 start: function (b) { 19674 this.isFollowing || (this.isFollowing = !0, this.mouseY0 = b.pageY, this.mouseX0 = b.pageX, this.topDelta = 0, this.leftDelta = 0, this.isHidden || this.updatePosition(), a(document).on("mousemove", this.mousemoveProxy = ca(this, "mousemove"))) 19675 }, 19676 stop: function (b, c) { 19677 function d() { 19678 this.isAnimating = !1, e.removeElement(), this.top0 = this.left0 = null, c && c() 19679 } 19680 var e = this, 19681 f = this.options.revertDuration; 19682 this.isFollowing && !this.isAnimating && (this.isFollowing = !1, a(document).off("mousemove", this.mousemoveProxy), b && f && !this.isHidden ? (this.isAnimating = !0, this.el.animate({ 19683 top: this.top0, 19684 left: this.left0 19685 }, { 19686 duration: f, 19687 complete: d 19688 })) : d()) 19689 }, 19690 getEl: function () { 19691 var a = this.el; 19692 return a || (this.sourceEl.width(), a = this.el = this.sourceEl.clone().css({ 19693 position: "absolute",
19694 visibility: "", 19695 display: this.isHidden ? "none" : "", 19696 margin: 0, 19697 right: "auto", 19698 bottom: "auto", 19699 width: this.sourceEl.width(), 19700 height: this.sourceEl.height(), 19701 opacity: this.options.opacity || "", 19702 zIndex: this.options.zIndex 19703 }).appendTo(this.parentEl)), a 19704 }, 19705 removeElement: function () { 19706 this.el && (this.el.remove(), this.el = null) 19707 }, 19708 updatePosition: function () { 19709 var a, b; 19710 this.getEl(), null === this.top0 && (this.sourceEl.width(), a = this.sourceEl.offset(), b = this.el.offsetParent().offset(), this.top0 = a.top - b.top, this.left0 = a.left - b.left), this.el.css({ 19711 top: this.top0 + this.topDelta, 19712 left: this.left0 + this.leftDelta 19713 }) 19714 }, 19715 mousemove: function (a) { 19716 this.topDelta = a.pageY - this.mouseY0, this.leftDelta = a.pageX - this.mouseX0, this.isHidden || this.updatePosition() 19717 }, 19718 hide: function () { 19719 this.isHidden || (this.isHidden = !0, this.el && this.el.hide()) 19720 }, 19721 show: function () { 19722 this.isHidden && (this.isHidden = !1, this.updatePosition(), this.getEl().show()) 19723 } 19724 }), 19725 kb = Pa.Grid = ra.extend({ 19726 view: null, 19727 isRTL: null, 19728 start: null, 19729 end: null, 19730 el: null, 19731 elsByFill: null, 19732 externalDragStartProxy: null, 19733 eventTimeFormat: null, 19734 displayEventTime: null, 19735 displayEventEnd: null, 19736 minResizeDuration: null, 19737 largeUnit: null, 19738 constructor: function (a) { 19739 this.view = a, this.isRTL = a.opt("isRTL"), this.elsByFill = {}, this.externalDragStartProxy = ca(this, "externalDragStart") 19740 }, 19741 computeEventTimeFormat: function () { 19742 return this.view.opt("smallTimeFormat") 19743 }, 19744 computeDisplayEventTime: function () { 19745 return !0 19746 }, 19747 computeDisplayEventEnd: function () { 19748 return !0 19749 }, 19750 setRange: function (a) { 19751 this.start = a.start.clone(), this.end = a.end.clone(), this.rangeUpdated(), this.processRangeOptions() 19752 }, 19753 rangeUpdated: function () { }, 19754 processRangeOptions: function () { 19755 var a, b, c = this.view; 19756 this.eventTimeFormat = c.opt("eventTimeFormat") || c.opt("timeFormat") || this.computeEventTimeFormat(), a = c.opt("displayEventTime"), null == a && (a = this.computeDisplayEventTime()), b = c.opt("displayEventEnd"), null == b && (b = this.computeDisplayEventEnd()), this.displayEventTime = a, this.displayEventEnd = b 19757 }, 19758 spanToSegs: function (a) { }, 19759 diffDates: function (a, b) { 19760 return this.largeUnit ? H(a, b, this.largeUnit) : F(a, b) 19761 }, 19762 prepareHits: function () { }, 19763 releaseHits: function () { }, 19764 queryHit: function (a, b) { }, 19765 getHitSpan: function (a) { }, 19766 getHitEl: function (a) { }, 19767 setElement: function (b) { 19768 var c = this; 19769 this.el = b, b.on("mousedown", function (b) { 19770 a(b.target).is(".fc-event-container *, .fc-more") || a(b.target).closest(".fc-popover").length || c.dayMousedown(b) 19771 }), this.bindSegHandlers(), this.bindGlobalHandlers() 19772 }, 19773 removeElement: function () { 19774 this.unbindGlobalHandlers(), this.el.remove() 19775 }, 19776 renderSkeleton: function () { }, 19777 renderDates: function () { }, 19778 unrenderDates: function () { }, 19779 bindGlobalHandlers: function () { 19780 a(document).on("dragstart sortstart", this.externalDragStartProxy) 19781 }, 19782 unbindGlobalHandlers: function () { 19783 a(document).off("dragstart sortstart", this.externalDragStartProxy) 19784 }, 19785 dayMousedown: function (a) { 19786 var b, c, d = this, 19787 e = this.view, 19788 f = e.opt("selectable"), 19789 i = new ib(this, { 19790 scroll: e.opt("dragScroll"), 19791 dragStart: function () { 19792 e.unselect() 19793 }, 19794 hitOver: function (a, e, h) { 19795 h && (b = e ? a : null, f && (c = d.computeSelection(d.getHitSpan(h), d.getHitSpan(a)), c ? d.renderSelection(c) : c === !1 && g())) 19796 }, 19797 hitOut: function () { 19798 b = null, c = null, d.unrenderSelection(), h() 19799 }, 19800 listenStop: function (a) { 19801 b && e.triggerDayClick(d.getHitSpan(b), d.getHitEl(b), a), c && e.reportSelection(c, a), h() 19802 } 19803 }); 19804 i.mousedown(a) 19805 }, 19806 renderEventLocationHelper: function (a, b) { 19807 var c = this.fabricateHelperEvent(a, b); 19808 this.renderHelper(c, b) 19809 }, 19810 fabricateHelperEvent: function (a, b) { 19811 var c = b ? R(b.event) : {}; 19812 return c.start = a.start.clone(), c.end = a.end ? a.end.clone() : null, c.allDay = null, this.view.calendar.normalizeEventDates(c), c.className = (c.className || []).concat("fc-helper"), b || (c.editable = !1), c 19813 }, 19814 renderHelper: function (a, b) { }, 19815 unrenderHelper: function () { }, 19816 renderSelection: function (a) { 19817 this.renderHighlight(a) 19818 }, 19819 unrenderSelection: function () { 19820 this.unrenderHighlight() 19821 }, 19822 computeSelection: function (a, b) { 19823 var c = this.computeSelectionSpan(a, b); 19824 return c && !this.view.calendar.isSelectionSpanAllowed(c) ? !1 : c 19825 }, 19826 computeSelectionSpan: function (a, b) { 19827 var c = [a.start, a.end, b.start, b.end]; 19828 return c.sort(aa), { 19829 start: c[0].clone(), 19830 end: c[3].clone() 19831 } 19832 }, 19833 renderHighlight: function (a) { 19834 this.renderFill("highlight", this.spanToSegs(a)) 19835 }, 19836 unrenderHighlight: function () { 19837 this.unrenderFill("highlight") 19838 }, 19839 highlightSegClasses: function () { 19840 return ["fc-highlight"] 19841 }, 19842 renderBusinessHours: function () { }, 19843 unrenderBusinessHours: function () { }, 19844 getNowIndicatorUnit: function () { }, 19845 renderNowIndicator: function (a) { }, 19846 unrenderNowIndicator: function () { }, 19847 renderFill: function (a, b) { }, 19848 unrenderFill: function (a) { 19849 var b = this.elsByFill[a]; 19850 b && (b.remove(), delete this.elsByFill[a]) 19851 }, 19852 renderFillSegEls: function (b, c) { 19853 var d, e = this, 19854 f = this[b + "SegEl"], 19855 g = "", 19856 h = []; 19857 if (c.length) { 19858 for (d = 0; d < c.length; d++) g += this.fillSegHtml(b, c[d]); 19859 a(g).each(function (b, d) { 19860 var g = c[b], 19861 i = a(d); 19862 f && (i = f.call(e, g, i)), i && (i = a(i), i.is(e.fillSegTag) && (g.el = i, h.push(g))) 19863 }) 19864 } 19865 return h 19866 }, 19867 fillSegTag: "div", 19868 fillSegHtml: function (a, b) { 19869 var c = this[a + "SegClasses"], 19870 d = this[a + "SegCss"], 19871 e = c ? c.call(this, b) : [], 19872 f = $(d ? d.call(this, b) : {}); 19873 return "<" + this.fillSegTag + (e.length ? ' class="' + e.join(" ") + '"' : "") + (f ? ' style="' + f + '"' : "") + " />" 19874 }, 19875 getDayClasses: function (a) { 19876 var b = this.view, 19877 c = b.calendar.getNow(), 19878 d = ["fc-" + Ta[a.day()]]; 19879 return 1 == b.intervalDuration.as("months") && a.month() != b.intervalStart.month() && d.push("fc-other-month"), a.isSame(c, "day") ? d.push("fc-today", b.highlightStateClass) : c > a ? d.push("fc-past") : d.push("fc-future"), d 19880 } 19881 }); 19882 kb.mixin({ 19883 mousedOverSeg: null, 19884 isDraggingSeg: !1, 19885 isResizingSeg: !1,
19886 isDraggingExternal: !1, 19887 segs: null, 19888 renderEvents: function (a) { 19889 var b, c = [], 19890 d = []; 19891 for (b = 0; b < a.length; b++)(wa(a[b]) ? c : d).push(a[b]); 19892 this.segs = [].concat(this.renderBgEvents(c), this.renderFgEvents(d)) 19893 }, 19894 renderBgEvents: function (a) { 19895 var b = this.eventsToSegs(a); 19896 return this.renderBgSegs(b) || b 19897 }, 19898 renderFgEvents: function (a) { 19899 var b = this.eventsToSegs(a); 19900 return this.renderFgSegs(b) || b 19901 }, 19902 unrenderEvents: function () { 19903 this.triggerSegMouseout(), this.unrenderFgSegs(), this.unrenderBgSegs(), this.segs = null 19904 }, 19905 getEventSegs: function () { 19906 return this.segs || [] 19907 }, 19908 renderFgSegs: function (a) { }, 19909 unrenderFgSegs: function () { }, 19910 renderFgSegEls: function (b, c) { 19911 var d, e = this.view, 19912 f = "", 19913 g = []; 19914 if (b.length) { 19915 for (d = 0; d < b.length; d++) f += this.fgSegHtml(b[d], c); 19916 a(f).each(function (c, d) { 19917 var f = b[c], 19918 h = e.resolveEventEl(f.event, a(d)); 19919 h && (h.data("fc-seg", f), f.el = h, g.push(f)) 19920 }) 19921 } 19922 return g 19923 }, 19924 fgSegHtml: function (a, b) { }, 19925 renderBgSegs: function (a) { 19926 return this.renderFill("bgEvent", a) 19927 }, 19928 unrenderBgSegs: function () { 19929 this.unrenderFill("bgEvent") 19930 }, 19931 bgEventSegEl: function (a, b) { 19932 return this.view.resolveEventEl(a.event, b) 19933 }, 19934 bgEventSegClasses: function (a) { 19935 var b = a.event, 19936 c = b.source || {}; 19937 return ["fc-bgevent"].concat(b.className, c.className || []) 19938 }, 19939 bgEventSegCss: function (a) { 19940 var b = this.view, 19941 c = a.event, 19942 d = c.source || {}; 19943 return { 19944 "background-color": c.backgroundColor || c.color || d.backgroundColor || d.color || b.opt("eventBackgroundColor") || b.opt("eventColor") 19945 } 19946 }, 19947 businessHoursSegClasses: function (a) { 19948 return ["fc-nonbusiness", "fc-bgevent"] 19949 }, 19950 bindSegHandlers: function () { 19951 var b = this, 19952 c = this.view; 19953 a.each({ 19954 mouseenter: function (a, c) { 19955 b.triggerSegMouseover(a, c) 19956 }, 19957 mouseleave: function (a, c) { 19958 b.triggerSegMouseout(a, c) 19959 }, 19960 click: function (a, b) { 19961 return c.trigger("eventClick", this, a.event, b) 19962 }, 19963 mousedown: function (d, e) { 19964 a(e.target).is(".fc-resizer") && c.isEventResizable(d.event) ? b.segResizeMousedown(d, e, a(e.target).is(".fc-start-resizer")) : c.isEventDraggable(d.event) && b.segDragMousedown(d, e) 19965 } 19966 }, function (c, d) { 19967 b.el.on(c, ".fc-event-container > *", function (c) { 19968 var e = a(this).data("fc-seg"); 19969 return !e || b.isDraggingSeg || b.isResizingSeg ? void 0 : d.call(this, e, c) 19970 }) 19971 }) 19972 }, 19973 triggerSegMouseover: function (a, b) { 19974 this.mousedOverSeg || (this.mousedOverSeg = a, this.view.trigger("eventMouseover", a.el[0], a.event, b)) 19975 }, 19976 triggerSegMouseout: function (a, b) { 19977 b = b || {}, this.mousedOverSeg && (a = a || this.mousedOverSeg, this.mousedOverSeg = null, this.view.trigger("eventMouseout", a.el[0], a.event, b)) 19978 }, 19979 segDragMousedown: function (a, b) { 19980 var c, d = this, 19981 e = this.view, 19982 f = e.calendar, 19983 i = a.el, 19984 j = a.event, 19985 k = new jb(a.el, { 19986 parentEl: e.el, 19987 opacity: e.opt("dragOpacity"), 19988 revertDuration: e.opt("dragRevertDuration"), 19989 zIndex: 2 19990 }), 19991 l = new ib(e, { 19992 distance: 5, 19993 scroll: e.opt("dragScroll"), 19994 subjectEl: i, 19995 subjectCenter: !0, 19996 listenStart: function (a) { 19997 k.hide(), k.start(a) 19998 }, 19999 dragStart: function (b) { 20000 d.triggerSegMouseout(a, b), d.segDragStart(a, b), e.hideEvent(j) 20001 }, 20002 hitOver: function (b, h, i) { 20003 a.hit && (i = a.hit), c = d.computeEventDrop(i.component.getHitSpan(i), b.component.getHitSpan(b), j), c && !f.isEventSpanAllowed(d.eventToSpan(c), j) && (g(), c = null), c && e.renderDrag(c, a) ? k.hide() : k.show(), h && (c = null) 20004 }, 20005 hitOut: function () { 20006 e.unrenderDrag(), k.show(), c = null 20007 }, 20008 hitDone: function () { 20009 h() 20010 }, 20011 dragStop: function (b) { 20012 k.stop(!c, function () { 20013 e.unrenderDrag(), e.showEvent(j), d.segDragStop(a, b), c && e.reportEventDrop(j, c, this.largeUnit, i, b) 20014 }) 20015 }, 20016 listenStop: function () { 20017 k.stop() 20018 } 20019 }); 20020 l.mousedown(b) 20021 }, 20022 segDragStart: function (a, b) { 20023 this.isDraggingSeg = !0, this.view.trigger("eventDragStart", a.el[0], a.event, b, {}) 20024 }, 20025 segDragStop: function (a, b) { 20026 this.isDraggingSeg = !1, this.view.trigger("eventDragStop", a.el[0], a.event, b, {}) 20027 }, 20028 computeEventDrop: function (a, b, c) { 20029 var d, e, f = this.view.calendar, 20030 g = a.start, 20031 h = b.start; 20032 return g.hasTime() === h.hasTime() ? (d = this.diffDates(h, g), c.allDay && N(d) ? (e = { 20033 start: c.start.clone(), 20034 end: f.getEventEnd(c), 20035 allDay: !1 20036 }, f.normalizeEventTimes(e)) : e = { 20037 start: c.start.clone(), 20038 end: c.end ? c.end.clone() : null, 20039 allDay: c.allDay 20040 }, e.start.add(d), e.end && e.end.add(d)) : e = { 20041 start: h.clone(), 20042 end: null, 20043 allDay: !h.hasTime() 20044 }, e 20045 }, 20046 applyDragOpacity: function (a) { 20047 var b = this.view.opt("dragOpacity"); 20048 null != b && a.each(function (a, c) { 20049 c.style.opacity = b 20050 }) 20051 }, 20052 externalDragStart: function (b, c) { 20053 var d, e, f = this.view; 20054 f.opt("droppable") && (d = a((c ? c.item : null) || b.target), e = f.opt("dropAccept"), (a.isFunction(e) ? e.call(d[0], d) : d.is(e)) && (this.isDraggingExter
20054nal || this.listenToExternalDrag(d, b, c))) 20055 }, 20056 listenToExternalDrag: function (a, b, c) { 20057 var d, e = this, 20058 f = this.view.calendar, 20059 i = Ba(a), 20060 j = new ib(this, { 20061 listenStart: function () { 20062 e.isDraggingExternal = !0 20063 }, 20064 hitOver: function (a) { 20065 d = e.computeExternalDrop(a.component.getHitSpan(a), i), d && !f.isExternalSpanAllowed(e.eventToSpan(d), d, i.eventProps) && (g(), d = null), d && e.renderDrag(d) 20066 }, 20067 hitOut: function () { 20068 d = null 20069 }, 20070 hitDone: function () { 20071 h(), e.unrenderDrag() 20072 }, 20073 dragStop: function () { 20074 d && e.view.reportExternalDrop(i, d, a, b, c) 20075 }, 20076 listenStop: function () {
20077 e.isDraggingExternal = !1 20078 } 20079 }); 20080 j.startDrag(b) 20081 }, 20082 computeExternalDrop: function (a, b) { 20083 var c = this.view.calendar, 20084 d = { 20085 start: c.applyTimezone(a.start), 20086 end: null 20087 }; 20088 return b.startTime && !d.start.hasTime() && d.start.time(b.startTime), b.duration && (d.end = d.start.clone().add(b.duration)), d 20089 }, 20090 renderDrag: function (a, b) { }, 20091 unrenderDrag: function () { }, 20092 segResizeMousedown: function (a, b, c) { 20093 var d, e = this, 20094 f = this.view, 20095 i = f.calendar, 20096 j = a.el, 20097 k = a.event, 20098 l = i.getEventEnd(k), 20099 m = new ib(this, { 20100 distance: 5, 20101 scroll: f.opt("dragScroll"), 20102 subjectEl: j, 20103 dragStart: function (b) { 20104 e.triggerSegMouseout(a, b), e.segResizeStart(a, b) 20105 }, 20106 hitOver: function (b, h, j) { 20107 var m = e.getHitSpan(j), 20108 n = e.getHitSpan(b); 20109 d = c ? e.computeEventStartResize(m, n, k) : e.computeEventEndResize(m, n, k), d && (i.isEventSpanAllowed(e.eventToSpan(d), k) ? d.start.isSame(k.start) && d.end.isSame(l) && (d = null) : (g(), d = null)), d && (f.hideEvent(k), e.renderEventResize(d, a)) 20110 }, 20111 hitOut: function () { 20112 d = null 20113 }, 20114 hitDone: function () { 20115 e.unrenderEventResize(), f.showEvent(k), h() 20116 }, 20117 dragStop: function (b) { 20118 e.segResizeStop(a, b), d && f.reportEventResize(k, d, this.largeUnit, j, b) 20119 } 20120 }); 20121 m.mousedown(b) 20122 }, 20123 segResizeStart: function (a, b) { 20124 this.isResizingSeg = !0, this.view.trigger("eventResizeStart", a.el[0], a.event, b, {}) 20125 }, 20126 segResizeStop: function (a, b) { 20127 this.isResizingSeg = !1, this.view.trigger("eventResizeStop", a.el[0], a.event, b, {}) 20128 }, 20129 computeEventStartResize: function (a, b, c) { 20130 return this.computeEventResize("start", a, b, c) 20131 }, 20132 computeEventEndResize: function (a, b, c) { 20133 return this.computeEventResize("end", a, b, c) 20134 }, 20135 computeEventResize: function (a, b, c, d) { 20136 var e, f, g = this.view.calendar, 20137 h = this.diffDates(c[a], b[a]); 20138 return e = { 20139 start: d.start.clone(), 20140 end: g.getEventEnd(d), 20141 allDay: d.allDay 20142 }, e.allDay && N(h) && (e.allDay = !1, g.normalizeEventTimes(e)), e[a].add(h), e.start.isBefore(e.end) || (f = this.minResizeDuration || (d.allDay ? g.defaultAllDayEventDuration : g.defaultTimedEventDuration), "start" == a ? e.start = e.end.clone().subtract(f) : e.end = e.start.clone().add(f)), e 20143 }, 20144 renderEventResize: function (a, b) { }, 20145 unrenderEventResize: function () { }, 20146 getEventTimeText: function (a, b, c) { 20147 return null == b && (b = this.eventTimeFormat), null == c && (c = this.displayEventEnd), this.displayEventTime && a.start.hasTime() ? c && a.end ? this.view.formatRange(a, b) : a.start.format(b) : "" 20148 }, 20149 getSegClasses: function (a, b, c) { 20150 var d = a.event, 20151 e = ["fc-event", a.isStart ? "fc-start" : "fc-not-start", a.isEnd ? "fc-end" : "fc-not-end"].concat(d.className, d.source ? d.source.className : []); 20152 return b && e.push("fc-draggable"), c && e.push("fc-resizable"), e 20153 }, 20154 getEventSkinCss: function (a) { 20155 var b = this.view, 20156 c = a.source || {}, 20157 d = a.color, 20158 e = c.color, 20159 f = b.opt("eventColor"); 20160 return { 20161 "background-color": a.backgroundColor || d || c.backgroundColor || e || b.opt("eventBackgroun
20161dColor") || f, 20162 "border-color": a.borderColor || d || c.borderColor || e || b.opt("eventBorderColor") || f, 20163 color: a.textColor || c.textColor || b.opt("eventTextColor") 20164 } 20165 }, 20166 eventToSegs: function (a) { 20167 return this.eventsToSegs([a]) 20168 }, 20169 eventToSpan: function (a) { 20170 return this.eventToSpans(a)[0] 20171 }, 20172 eventToSpans: function (a) { 20173 var b = this.eventToRange(a); 20174 return this.eventRangeToSpans(b, a) 20175 }, 20176 eventsToSegs: function (b, c) { 20177 var d = this, 20178 e = za(b), 20179 f = []; 20180 return a.each(e, function (a, b) { 20181 var e, g = []; 20182 for (e = 0; e < b.length; e++) g.push(d.eventToRange(b[e])); 20183 if (xa(b[0])) 20184 for (g = d.invertRanges(g), e = 0; e < g.length; e++) f.push.apply(f, d.eventRangeToSegs(g[e], b[0], c)); 20185 else 20186 for (e = 0; e < g.length; e++) f.push.apply(f, d.eventRangeToSegs(g[e], b[e], c)) 20187 }), f 20188 }, 20189 eventToRange: function (a) { 20190 return { 20191 start: a.start.clone().stripZone(), 20192 end: (a.end ? a.end.clone() : this.view.calendar.getDefaultEventEnd(null != a.allDay ? a.allDay : !a.start.hasTime(), a.start)).stripZone() 20193 } 20194 }, 20195 eventRangeToSegs: function (a, b, c) { 20196 var d, e = this.eventRangeToSpans(a, b), 20197 f = []; 20198 for (d = 0; d < e.length; d++) f.push.apply(f, this.eventSpanToSegs(e[d], b, c)); 20199 return f 20200 }, 20201 eventRangeToSpans: function (b, c) { 20202 return [a.extend({}, b)] 20203 }, 20204 eventSpanToSegs: function (a, b, c) { 20205 var d, e, f = c ? c(a) : this.spanToSegs(a); 20206 for (d = 0; d < f.length; d++) e = f[d], e.event = b, e.eventStartMS = +a.start, e.eventDurationMS = a.end - a.start; 20207 return f 20208 }, 20209 invertRanges: function (a) { 20210 var b, c, d = this.view, 20211 e = d.start.clone(), 20212 f = d.end.clone(), 20213 g = [], 20214 h = e; 20215 for (a.sort(Aa), b = 0; b < a.length; b++) c = a[b], c.start > h && g.push({ 20216 start: h, 20217 end: c.start 20218 }), h = c.end; 20219 return f > h && g.push({ 20220 start: h, 20221 end: f 20222 }), g 20223 }, 20224 sortEventSegs: function (a) { 20225 a.sort(ca(this, "compareEventSegs")) 20226 }, 20227 compareEventSegs: function (a, b) { 20228 return a.eventStartMS - b.eventStartMS || b.eventDurationMS - a.eventDurationMS || b.event.allDay - a.event.allDay || B(a.event, b.event, this.view.eventOrderSpecs) 20229 } 20230 }), Pa.isBgEvent = wa, Pa.dataAttrPrefix = ""; 20231 var lb = Pa.DayTableMixin = { 20232 breakOnWeeks: !1, 20233 dayDates: null, 20234 dayIndices: null, 20235 daysPerRow: null, 20236 rowCnt: null, 20237 colCnt: null, 20238 colHeadFormat: null, 20239 updateDayTable: function () { 20240 for (var a, b, c, d = this.view, e = this.start.clone(), f = -1, g = [], h = []; e.isBefore(this.end);) d.isHiddenDay(e) ? g.push(f + .5) : (f++ , g.push(f), h.push(e.clone())), e.add(1, "days"); 20241 if (this.breakOnWeeks) { 20242 for (b = h[0].day(), a = 1; a < h.length && h[a].day() != b; a++); 20243 c = Math.ceil(h.length / a) 20244 } else c = 1, a = h.length; 20245 this.dayDates = h, this.dayIndices = g, this.daysPerRow = a, this.rowCnt = c, this.updateDayTableCols() 20246 }, 20247 updateDayTableCols: function () { 20248 this.colCnt = this.computeColCnt(), this.colHeadFormat = this.view.opt("columnFormat") || this.computeColHeadFormat() 20249 }, 20250 computeColCnt: function () { 20251 return this.daysPerRow 20252 }, 20253 getCellDate: function (a, b) { 20254 return this.dayDates[this.getCellDayIndex(a, b)].clone() 20255 }, 20256 getCellRange: function (a, b) { 20257 var c = this.getCellDate(a, b), 20258 d = c.clone().add(1, "days"); 20259 return { 20260 start: c, 20261 end: d 20262 } 20263 }, 20264 getCellDayIndex: function (a, b) { 20265 return a * this.daysPerRow + this.getColDayIndex(b) 20266 }, 20267 getColDayIndex: function (a) { 20268 return this.isRTL ? this.colCnt - 1 - a : a 20269 }, 20270 getDateDayIndex: function (a) { 20271 var b = this.dayIndices, 20272 c = a.diff(this.start, "days"); 20273 return 0 > c ? b[0] - 1 : c >= b.length ? b[b.length - 1] + 1 : b[c] 20274 }, 20275 computeColHeadFormat: function () { 20276 return this.rowCnt > 1 || this.colCnt > 10 ? "ddd" : this.colCnt > 1 ? this.view.opt("dayOfMonthFormat") : "dddd" 20277 }, 20278 sliceRangeByRow: function (a) { 20279 var b, c, d, e, f, g = this.daysPerRow, 20280 h = this.view.computeDayRange(a), 20281 i = this.getDateDayIndex(h.start), 20282 j = this.getDateDayIndex(h.end.clone().subtract(1, "days")), 20283 k = []; 20284 for (b = 0; b < this.rowCnt; b++) c = b * g, d = c + g - 1, e = Math.max(i, c), f = Math.min(j, d), e = Math.
20284ceil(e), f = Math.floor(f), f >= e && k.push({ 20285 row: b, 20286 firstRowDayIndex: e - c, 20287 lastRowDayIndex: f - c, 20288 isStart: e === i, 20289 isEnd: f === j 20290 }); 20291 return k 20292 }, 20293 sliceRangeByDay: function (a) { 20294 var b, c, d, e, f, g, h = this.daysPerRow, 20295 i = this.view.computeDayRange(a), 20296 j = this.getDateDayIndex(i.start), 20297 k = this.getDateDayIndex(i.end.clone().subtract(1, "days")), 20298 l = []; 20299 for (b = 0; b < this.rowCnt; b++) 20300 for (c = b * h, d = c + h - 1, e = c; d >= e; e++) f = Math.max(j, e), g = Math.min(k, e), f = Math.ceil(f), g = Math.floor(g), g >= f && l.push({ 20301 row: b, 20302 firstRowDayIndex: f - c, 20303 lastRowDayIndex: g - c, 20304 isStart: f === j, 20305 isEnd: g === k 20306 }); 20307 return l 20308 }, 20309 renderHeadHtml: function () { 20310 var a = this.view; 20311 return '<div class="fc-row ' + a.widgetHeaderClass + '"><table><thead>' + this.renderHeadTrHtml() + "</thead></table></div>" 20312 }, 20313 renderHeadIntroHtml: function () { 20314 return this.renderIntroHtml() 20315 }, 20316 renderHeadTrHtml: function () { 20317 return "<tr>" + (this.isRTL ? "" : this.renderHeadIntroHtml()) + this.renderHeadDateCellsHtml() + (this.isRTL ? this.renderHeadIntroHtml() : "") + "</tr>" 20318 }, 20319 renderHeadDateCellsHtml: function () { 20320 var a, b, c = []; 20321 for (a = 0; a < this.colCnt; a++) b = this.getCellDate(0, a), c.push(this.renderHeadDateCellHtml(b)); 20322 return c.join("") 20323 }, 20324 renderHeadDateCellHtml: function (a, b, c) { 20325 var d = this.view; 20326 return '<th class="fc-day-header ' + d.widgetHeaderClass + " fc-" + Ta[a.day()] + '"' + (1 == this.rowCnt ? ' data-date="' + a.format("YYYY-MM-DD") + '"' : "") + (b > 1 ? ' colspan="' + b + '"' : "") + (c ? " " + c : "") + ">" + Y(a.format(this.colHeadFormat)) + "</th>" 20327 }, 20328 renderBgTrHtml: function (a) { 20329 return "<tr>" + (this.isRTL ? "" : this.renderBgIntroHtml(a)) + this.renderBgCellsHtml(a) + (this.isRTL ? this.renderBgIntroHtml(a) : "") + "</tr>" 20330 }, 20331 renderBgIntroHtml: function (a) { 20332 return this.renderIntroHtml() 20333 }, 20334 renderBgCellsHtml: function (a) { 20335 var b, c, d = []; 20336 for (b = 0; b < this.colCnt; b++) c = this.getCellDate(a, b), d.push(this.renderBgCellHtml(c)); 20337 return d.join("") 20338 }, 20339 renderBgCellHtml: function (a, b) { 20340 var c = this.view, 20341 d = this.getDayClasses(a); 20342 return d.unshift("fc-day", c.widgetContentClass), '<td class="' + d.join(" ") + '" data-date="' + a.format("YYYY-MM-DD") + '"' + (b ? " " + b : "") + "></td>" 20343 }, 20344 renderIntroHtml: function () { }, 20345 bookendCells: function (a) { 20346 var b = this.renderIntroHtml(); 20347 b && (this.isRTL ? a.append(b) : a.prepend(b)) 20348 } 20349 }, 20350 mb = Pa.DayGrid = kb.extend(lb, { 20351 numbersVisible: !1, 20352 bottomCoordPadding: 0, 20353 rowEls: null, 20354 cellEls: null, 20355 helperEls: null, 20356 rowCoordCache: null, 20357 colCoordCache: null, 20358 renderDates: function (a) { 20359 var b, c, d = this.view, 20360 e = this.rowCnt, 20361 f = this.colCnt, 20362 g = ""; 20363 for (b = 0; e > b; b++) g += this.renderDayRowHtml(b, a); 20364 for (this.el.html(g), this.rowEls = this.el.find(".fc-row"), this.cellEls = this.el.find(".fc-day"), this.rowCoordCache = new gb({ 20365 els: this.rowEls, 20366 isVertical: !0 20367 }), this.colCoordCache = new gb({ 20368 els: this.cellEls.slice(0, this.colCnt), 20369 isHorizontal: !0 20370 }), b = 0; e > b; b++) 20371 for (c = 0; f > c; c++) d.trigger("dayRender", null, this.getCellDate(b, c), this.getCellEl(b, c)) 20372 }, 20373 unrenderDates: function () { 20374 this.removeSegPopover() 20375 }, 20376 renderBusinessHours: function () { 20377 var a = this.view.calendar.getBusinessHoursEvents(!0), 20378 b = this.eventsToSegs(a); 20379 this.renderFill("businessHours", b, "bgevent") 20380 }, 20381 renderDayRowHtml: function (a, b) { 20382 var c = this.view, 20383 d = ["fc-row", "fc-week", c.widgetContentClass]; 20384 return b && d.push("fc-rigid"), '<div class="' + d.join(" ") + '"><div class="fc-bg"><table>' + this.renderBgTrHtml(a) + '</table></div><div class="fc-content-skeleton"><table>' + (this.numbersVisible ? "<thead>" + this.renderNumberTrHtml(a) + "</thead>" : "") + "</table></div></div>" 20385 }, 20386 renderNumberTrHtml: function (a) { 20387 return "<tr>" + (this.isRTL ? "" : this.renderNumberIntroHtml(a)) + this.renderNumberCellsHtml(a) + (this.isRTL ? this.renderNumberIntroHtml(a) : "") + "</tr>" 20388 }, 20389 renderNumberIntroHtml: function (a) { 20390 return this.renderIntroHtml() 20391 }, 20392 renderNumberCellsHtml: function (a) { 20393 var b, c, d = []; 20394 for (b = 0; b < this.colCnt; b++) c = this.getCellDate(a, b), d.push(this.renderNumberCellHtml(c)); 20395 return d.join("") 20396 }, 20397 renderNumberCellHtml: function (a) { 20398 var b; 20399 return this.view.dayNumbersVisible ? (b = this.getDayClasses(a), b.unshift("fc-day-number"), '<td class="' + b.join(" ") + '" data-date="' + a.format() + '">' + a.date() + "</td>") : "<td/>" 20400 }, 20401 computeEventTimeFormat: function () { 20402 return this.view.opt("extraSmallTimeFormat") 20403 }, 20404 computeDisplayEventEnd: function () { 20405 return 1 == this.colCnt 20406 }, 20407 rangeUpdated: function () { 20408 this.updateDayTable() 20409 }, 20410 spanToSegs: function (a) { 20411 var b, c, d = this.sliceRangeByRow(a); 20412 for (b = 0; b < d.length; b++) c = d[b], this.isRTL ? (c.leftCol = this.daysPerRow - 1 - c.lastRowDayIndex, c.rightCol = this.daysPerRow - 1 - c.firstRowDayIndex) : (c.leftCol = c.firstRowDayIndex, c.rightCol = c.lastRowDayIndex); 20413 return d 20414 }, 20415 prepareHits: function () { 20416 this.colCoordCache.build(), this.rowCoordCache.build(), this.rowCoordCache.bottoms[this.rowCnt - 1] += this.bottomCoordPadding 20417 }, 20418 releaseHits: function () { 20419 this.colCoordCache.clear(), this.rowCoordCache.clear() 20420 }, 20421 queryHit: function (a, b) { 20422 var c = this.colCoordCache.getHorizontalIndex(a), 20423 d = this.rowCoordCache.getVerticalIndex(b); 20424 return null != d && null != c ? this.getCellHit(d, c) : void 0 20425 }, 20426 getHitSpan: function (a) { 20427 return this.getCellRange(a.row, a.col) 20428 }, 20429 getHitEl: function (a) { 20430 return this.getCellEl(a.row, a.col) 20431 }, 20432 getCellHit: function (a, b) { 20433 return { 20434 row: a, 20435 col: b, 20436 component: this, 20437 left: this.colCoordCache.getLeftOffset(b), 20438 right: this.colCoordCache.getRightOffset(b),
20439 top: this.rowCoordCache.getTopOffset(a), 20440 bottom: this.rowCoordCache.getBottomOffset(a) 20441 } 20442 }, 20443 getCellEl: function (a, b) { 20444 return this.cellEls.eq(a * this.colCnt + b) 20445 }, 20446 renderDrag: function (a, b) { 20447 return this.renderHighlight(this.eventToSpan(a)), b && !b.el.closest(this.el).length ? (this.renderEventLocationHelper(a, b), this.applyDragOpacity(this.helperEls), !0) : void 0 20448 }, 20449 unrenderDrag: function () { 20450 this.unrenderHighlight(), this.unrenderHelper() 20451 }, 20452 renderEventResize: function (a, b) { 20453 this.renderHighlight(this.eventToSpan(a)), this.renderEventLocationHelper(a, b) 20454 }, 20455 unrenderEventResize: function () { 20456 this.unrenderHighlight(), this.unrenderHelper() 20457 }, 20458 renderHelper: function (b, c) { 20459 var d, e = [], 20460 f = this.eventToSegs(b); 20461 f = this.renderFgSegEls(f), d = this.renderSegRows(f), this.rowEls.each(function (b, f) { 20462 var g, h = a(f), 20463 i = a('<div class="fc-helper-skeleton"><table/></div>'); 20464 g = c && c.row === b ? c.el.position().top : h.find(".fc-content-skeleton tbody").position().top, i.css("top", g).find("table").append(d[b].tbodyEl), h.append(i), e.push(i[0]) 20465 }), this.helperEls = a(e) 20466 }, 20467 unrenderHelper: function () { 20468 this.helperEls && (this.helperEls.remove(), this.helperEls = null) 20469 }, 20470 fillSegTag: "td", 20471 renderFill: function (b, c, d) { 20472 var e, f, g, h = []; 20473 for (c = this.renderFillSegEls(b, c), e = 0; e < c.length; e++) f = c[e], g = this.renderFillRow(b, f, d), this.rowEls.eq(f.row).append(g), h.push(g[0]); 20474 return this.elsByFill[b] = a(h), c 20475 }, 20476 renderFillRow: function (b, c, d) { 20477 var e, f, g = this.colCnt, 20478 h = c.leftCol, 20479 i = c.rightCol + 1; 20480 return d = d || b.toLowerCase(), e = a('<div class="fc-' + d + '-skeleton"><table><tr/></table></div>'), f = e.find("tr"), h > 0 && f.append('<td colspan="' + h + '"/>'), f.append(c.el.attr("colspan", i - h)), g > i && f.append('<td colspan="' + (g - i) + '"/>'), this.bookendCells(f), e 20481 } 20482 }); 20483 mb.mixin({ 20484 rowStructs: null, 20485 unrenderEvents: function () { 20486 this.removeSegPopover(), kb.prototype.unrenderEvents.apply(this, arguments) 20487 }, 20488 getEventSegs: function () { 20489 return kb.prototype.getEventSegs.call(this).concat(this.popoverSegs || []) 20490 }, 20491 renderBgSegs: function (b) { 20492 var c = a.grep(b, function (a) { 20493 return a.event.allDay 20494 }); 20495 return kb.prototype.renderBgSegs.call(this, c) 20496 }, 20497 renderFgSegs: function (b) { 20498 var c; 20499 return b = this.renderFgSegEls(b), c = this.rowStructs = this.renderSegRows(b), this.rowEls.each(function (b, d) { 20500 a(d).find(".fc-content-skeleton > table").append(c[b].tbodyEl) 20501 }), b 20502 }, 20503 unrenderFgSegs: function () { 20504 for (var a, b = this.rowStructs || []; a = b.pop();) a.tbodyEl.remove(); 20505 this.rowStructs = null 20506 }, 20507 renderSegRows: function (a) { 20508 var b, c, d = []; 20509 for (b = this.groupSegRows(a), c = 0; c < b.length; c++) d.push(this.renderSegRow(c, b[c])); 20510 return d 20511 }, 20512 fgSegHtml: function (a, b) { 20513 var c, d, e = this.view, 20514 f = a.event, 20515 g = e.isEventDraggable(f), 20516 h = !b && f.allDay && a.isStart && e.isEventResizableFromStart(f), 20517 i = !b && f.allDay && a.isEnd && e.isEventResizableFromEnd(f),
20518 j = this.getSegClasses(a, g, h || i), 20519 k = $(this.getEventSkinCss(f)), 20520 l = ""; 20521 return j.unshift("fc-day-grid-event", "fc-h-event"), a.isStart && (c = this.getEventTimeText(f), c && (l = '<span class="fc-time">' + Y(c) + "</span>")), d = '<span class="fc-title">' + (Y(f.title || "") || " ") + "</span>", '<a class="' + j.join(" ") + '"' + (f.url ? ' href="' + Y(f.url) + '"' : "") + (k ? ' style="' + k + '"' : "") + '><div class="fc-content">' + (this.isRTL ? d + " " + l : l + " " + d) + "</div>" + (h ? '<div class="fc-resizer fc-start-resizer" />' : "") + (i ? '<div class="fc-resizer fc-end-resizer" />' : "") + "</a>" 20522 }, 20523 renderSegRow: function (b, c) { 20524 function d(b) { 20525 for (; b > g;) k = (r[e - 1] || [])[g], k ? k.attr("rowspan", parseInt(k.attr("rowspan") || 1, 10) + 1) : (k = a("<td/>"), h.append(k)), q[e][g] = k, r[e][g] = k, g++ 20526 } 20527 var e, f, g, h, i, j, k, l = this.colCnt, 20528 m = this.buildSegLevels(c), 20529 n = Math.max(1, m.length), 20530 o = a("<tbody/>"), 20531 p = [], 20532 q = [], 20533 r = []; 20534 for (e = 0; n > e; e++) { 20535 if (f = m[e], g = 0, h = a("<tr/>"), p.push([]), q.push([]), r.push([]), f) 20536 for (i = 0; i < f.length; i++) { 20537 for (j = f[i], d(j.leftCol), k = a('<td class="fc-event-container"/>').append(j.el), j.leftCol != j.rightCol ? k.attr("colspan", j.rightCol - j.leftCol + 1) : r[e][g] = k; g <= j.rightCol;) q[e][g] = k, p[e][g] = j, g++; 20538 h.append(k) 20539 } 20540 d(l), this.bookendCells(h), o.append(h) 20541 } 20542 return { 20543 row: b, 20544 tbodyEl: o, 20545 cellMatrix: q, 20546 segMatrix: p, 20547 segLevels: m, 20548 segs: c 20549 } 20550 }, 20551 buildSegLevels: function (a) { 20552 var b, c, d, e = []; 20553 for (this.sortEventSegs(a), b = 0; b < a.length; b++) { 20554 for (c = a[b], d = 0; d < e.length && Ca(c, e[d]); d++); 20555 c.level = d, (e[d] || (e[d] = [])).push(c) 20556 } 20557 for (d = 0; d < e.length; d++) e[d].sort(Da); 20558 return e 20559 }, 20560 groupSegRows: function (a) { 20561 var b, c = []; 20562 for (b = 0; b < this.rowCnt; b++) c.push([]); 20563 for (b = 0; b < a.length; b++) c[a[b].row].push(a[b]); 20564 return c 20565 } 20566 }), mb.mixin({ 20567 segPopover: null, 20568 popoverSegs: null, 20569 removeSegPopover: function () { 20570 this.segPopover && this.segPopover.hide() 20571 }, 20572 limitRows: function (a) { 20573 var b, c, d = this.rowStructs || []; 20574 for (b = 0; b < d.length; b++) this.unlimitRow(b), c = a ? "number" == typeof a ? a : this.computeRowLevelLimit(b) : !1, c !== !1 && this.limitRow(b, c) 20575 }, 20576 computeRowLevelLimit: function (b) { 20577 function c(b, c) { 20578 f = Math.max(f, a(c).outerHeight()) 20579 } 20580 var d, e, f, g = this.rowEls.eq(b), 20581 h = g.height(), 20582 i = this.rowStructs[b].tbodyEl.children(); 20583 for (d = 0; d < i.length; d++) 20584 if (e = i.eq(d).removeClass("fc-limited"), f = 0, e.find("> td > :first-child").each(c), e.position().top + f > h) return d; 20585 return !1 20586 }, 20587 limitRow: function (b, c) { 20588 function d(d) { 20589 for (; d > w;) j = t.getCellSegs(b, w, c), j.length && (m = f[c - 1][w], s = t.renderMoreLink(b, w, j), r = a("<div/>").append(s), m.append(r), v.push(r[0])), w++ 20590 } 20591 var e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t = this, 20592 u = this.rowStructs[b], 20593 v = [], 20594 w = 0; 20595 if (c && c < u.segLevels.length) { 20596 for (e = u.segLevels[c - 1], f = u.cellMatrix, g = u.tbodyEl.children().slice(c).addClass("fc-limited").get(), h = 0; h < e.length; h++) { 20597 for (i = e[h], d(i.leftCol), l = [], k = 0; w <= i.rightCol;) j = this.getCellSegs(b, w, c), l.push(j), k += j.length, w++; 20598 if (k) { 20599 for (m = f[c - 1][i.leftCol], n = m.attr("rowspan") || 1, o = [], p
20599= 0; p < l.length; p++) q = a('<td class="fc-more-cell"/>').attr("rowspan", n), j = l[p], s = this.renderMoreLink(b, i.leftCol + p, [i].concat(j)), r = a("<div/>").append(s), q.append(r), o.push(q[0]), v.push(q[0]); 20600 m.addClass("fc-limited").after(a(o)), g.push(m[0]) 20601 } 20602 } 20603 d(this.colCnt), u.moreEls = a(v), u.limitedEls = a(g) 20604 } 20605 }, 20606 unlimitRow: function (a) { 20607 var b = this.rowStructs[a]; 20608 b.moreEls && (b.moreEls.remove(), b.moreEls = null), b.limitedEls && (b.limitedEls.removeClass("fc-limited"), b.limitedEls = null) 20609 }, 20610 renderMoreLink: function (b, c, d) { 20611 var e = this, 20612 f = this.view; 20613 return a('<a class="fc-more"/>').text(this.getMoreLinkText(d.length)).on("click", function (g) { 20614 var h = f.opt("eventLimitClick"), 20615 i = e.getCellDate(b, c), 20616 j = a(this), 20617 k = e.getCellEl(b, c), 20618 l = e.getCellSegs(b, c), 20619 m = e.resliceDaySegs(l, i), 20620 n = e.resliceDaySegs(d, i); 20621 "function" == typeof h && (h = f.trigger("eventLimitClick", null, { 20622 date: i, 20623 dayEl: k, 20624 moreEl: j, 20625 segs: m, 20626 hiddenSegs: n 20627 }, g)), "popover" === h ? e.showSegPopover(b, c, j, m) : "string" == typeof h && f.calendar.zoomTo(i, h) 20628 }) 20629 }, 20630 showSegPopover: function (a, b, c, d) { 20631 var e, f, g = this, 20632 h = this.view, 20633 i = c.parent(); 20634 e = 1 == this.rowCnt ? h.el : this.rowEls.eq(a), f = { 20635 className: "fc-more-popover", 20636 content: this.renderSegPopoverContent(a, b, d), 20637 parentEl: this.el, 20638 top: e.offset().top, 20639 autoHide: !0, 20640 viewportConstrain: h.opt("popoverViewportConstrain"), 20641 hide: function () { 20642 g.segPopover.removeElement(), g.segPopover = null, g.popoverSegs = null 20643 } 20644 }, this.isRTL ? f.right = i.offset().left + i.outerWidth() + 1 : f.left = i.offset().left - 1, this.segPopover = new fb(f), this.segPopover.show() 20645 }, 20646 renderSegPopoverContent: function (b, c, d) { 20647 var e, f = this.view, 20648 g = f.opt("theme"), 20649 h = this.getCellDate(b, c).format(f.opt("dayPopoverFormat")), 20650 i = a('<div class="fc-header ' + f.widgetHeaderClass + '"><span class="fc-close ' + (g ? "ui-icon ui-icon-closethick" : "fc-icon fc-icon-x") + '"></span><span class="fc-title">' + Y(h) + '</span><div class="fc-clear"/></div><div class="fc-body ' + f.widgetContentClass + '"><div class="fc-event-container"></div></div>'), 20651 j = i.find(".fc-event-container"); 20652 for (d = this.renderFgSegEls(d, !0), this.popoverSegs = d, e = 0; e < d.length; e++) this.prepareHits(), d[e].hit = this.getCellHit(b, c), this.releaseHits(), j.append(d[e].el); 20653 return i 20654 }, 20655 resliceDaySegs: function (b, c) { 20656 var d = a.map(b, function (a) { 20657 return a.event 20658 }), 20659 e = c.clone(), 20660 f = e.clone().add(1, "days"), 20661 g = { 20662 start: e, 20663 end: f 20664 }; 20665 return b = this.eventsToSegs(d, function (a) { 20666 var b = E(a, g); 20667 return b ? [b] : [] 20668 }), this.sortEventSegs(b), b 20669 }, 20670 getMoreLinkText: function (a) { 20671 var b = this.view.opt("eventLimitText"); 20672 return "function" == typeof b ? b(a) : "+" + a + " " + b 20673 }, 20674 getCellSegs: function (a, b, c) { 20675 for (var d, e = this.rowStructs[a].segMatrix, f = c || 0, g = []; f < e.length;) d = e[f][b], d && g.push(d), f++; 20676 return g 20677 } 20678 });
20679 var nb = Pa.TimeGrid = kb.extend(lb, { 20680 slotDuration: null, 20681 snapDuration: null, 20682 snapsPerSlot: null, 20683 minTime: null, 20684 maxTime: null, 20685 labelFormat: null, 20686 labelInterval: null, 20687 colEls: null, 20688 slatEls: null, 20689 nowIndicatorEls: null, 20690 colCoordCache: null, 20691 slatCoordCache: null, 20692 constructor: function () { 20693 kb.apply(this, arguments), this.processOptions() 20694 }, 20695 renderDates: function () { 20696 this.el.html(this.renderHtml()), this.colEls = this.el.find(".fc-day"), this.slatEls = this.el.find(".fc-slats tr"), this.colCoordCache = new gb({ 20697 els: this.colEls, 20698 isHorizontal: !0 20699 }), this.slatCoordCache = new gb({ 20700 els: this.slatEls, 20701 isVertical: !0 20702 }), this.renderContentSkeleton() 20703 }, 20704 renderHtml: function () { 20705 return '<div class="fc-bg"><table>' + this.renderBgTrHtml(0) + '</table></div><div class="fc-slats"><table>' + this.renderSlatRowHtml() + "</table></div>" 20706 }, 20707 renderSlatRowHtml: function () { 20708 for (var a, c, d, e = this.view, f = this.isRTL, g = "", h = b.duration(+this.minTime); h < this.maxTime;) a = this.start.clone().time(h), c = ba(L(h, this.labelInterval)), d = '<td class="fc-axis fc-time ' + e.widgetContentClass + '" ' + e.axisStyleAttr() + ">" + (c ? "<span>" + Y(a.format(this.labelFormat)) + "</span>" : "") + "</td>", g += '<tr data-time="' + a.format("HH:mm:ss") + '"' + (c ? "" : ' class="fc-minor"') + ">" + (f ? "" : d) + '<td class="' + e.widgetContentClass + '"/>' + (f ? d : "") + "</tr>", h.add(this.slotDuration); 20709 return g 20710 }, 20711 processOptions: function () { 20712 var c, d = this.view, 20713 e = d.opt("slotDuration"), 20714 f = d.opt("snapDuration"); 20715 e = b.duration(e), f = f ? b.duration(f) : e, this.slotDuration = e, this.snapDuration = f, this.snapsPerSlot = e / f, this.minResizeDuration = f, this.minTime = b.duration(d.opt("minTime")), this.maxTime = b.duration(d.opt("maxTime")), c = d.opt("slotLabelFormat"), a.isArray(c) && (c = c[c.length - 1]), this.labelFormat = c || d.opt("axisFormat") || d.opt("smallTimeFormat"), c = d.opt("slotLabelInterval"), this.labelInterval = c ? b.duration(c) : this.computeLabelInterval(e) 20716 }, 20717 computeLabelInterval: function (a) { 20718 var c, d, e; 20719 for (c = Db.length - 1; c >= 0; c--) 20720 if (d = b.duration(Db[c]), e = L(d, a), ba(e) && e > 1) return d; 20721 return b.duration(a) 20722 }, 20723 computeEventTimeFormat: function () { 20724 return this.view.opt("noMeridiemTimeFormat") 20725 }, 20726 computeDisplayEventEnd: function () { 20727 return !0 20728 }, 20729 prepareHits: function () { 20730 this.colCoordCache.build(), this.slatCoordCache.build() 20731 }, 20732 releaseHits: function () { 20733 this.colCoordCache.clear() 20734 }, 20735 queryHit: function (a, b) { 20736 var c = this.snapsPerSlot, 20737 d = this.colCoordCache, 20738 e = this.slatCoordCache, 20739 f = d.getHorizontalIndex(a), 20740 g = e.getVerticalIndex(b); 20741 if (null != f && null != g) { 20742 var h = e.getTopOffset(g), 20743 i = e.getHeight(g), 20744 j = (b - h) / i, 20745 k = Math.floor(j * c), 20746 l = g * c + k, 20747 m = h + k / c * i, 20748 n = h + (k + 1) / c * i; 20749 return { 20750 col: f, 20751 snap: l, 20752 component: this, 20753 left: d.getLeftOffset(f), 20754 right: d.getRightOffset(f), 20755 top: m, 20756 bottom: n 20757 } 20758 } 20759 }, 20760 getHitSpan: function (a) { 20761 var b, c = this.getCellDate(0, a.col), 20762 d = this.computeSnapTime(a.snap); 20763 return c.time(d), b = c.clone().add(this.snapDuration), { 20764 start: c, 20765 end: b 20766 } 20767 }, 20768 getHitEl: function (a) { 20769 return this.colEls.eq(a.col) 20770 }, 20771 rangeUpdated: function () { 20772 this.updateDayTable() 20773 }, 20774 computeSnapTime: function (a) { 20775 return b.duration(this.minTime + this.snapDuration * a) 20776 }, 20777 spanToSegs: function (a) { 20778 var b, c = this.sliceRangeByTimes(a); 20779 for (b = 0; b < c.length; b++) this.isRTL ? c[b].col = this.daysPerRow - 1 - c[b].dayIndex : c[b].col = c[b].dayIndex; 20780 return c 20781 }, 20782 sliceRangeByTimes: function (a) { 20783 var b, c, d, e, f = []; 20784 for (c = 0; c < this.daysPerRow; c++) d = this.dayDates[c].clone(), e = { 20785 start: d.clone().time(this.minTime), 20786 end: d.clone().time(this.maxTime) 20787 }, b = E(a, e), b && (b.dayIndex = c, f.push(b)); 20788 return f 20789 }, 20790 updateSize: function (a) {
20791 this.slatCoordCache.build(), a && this.updateSegVerticals([].concat(this.fgSegs || [], this.bgSegs || [], this.businessSegs || [])) 20792 }, 20793 computeDateTop: function (a, c) { 20794 return this.computeTimeTop(b.duration(a - c.clone().stripTime())) 20795 }, 20796 computeTimeTop: function (a) { 20797 var b, c, d = this.slatEls.length, 20798 e = (a - this.minTime) / this.slotDuration; 20799 return e = Math.max(0, e), e = Math.min(d, e), b = Math.floor(e), b = Math.min(b, d - 1), c = e - b, this.slatCoordCache.getTopPosition(b) + this.slatCoordCache.getHeight(b) * c 20800 }, 20801 renderDrag: function (a, b) { 20802 if (b) { 20803 this.renderEventLocationHelper(a, b); 20804 for (var c = 0; c < this.helperSegs.length; c++) this.applyDragOpacity(this.helperSegs[c].el); 20805 return !0 20806 } 20807 this.renderHighlight(this.eventToSpan(a)) 20808 }, 20809 unrenderDrag: function () { 20810 this.unrenderHelper(), this.unrenderHighlight() 20811 }, 20812 renderEventResize: function (a, b) { 20813 this.renderEventLocationHelper(a, b) 20814 }, 20815 unrenderEventResize: function () { 20816 this.unrenderHelper() 20817 }, 20818 renderHelper: function (a, b) { 20819 this.renderHelperSegs(this.eventToSegs(a), b) 20820 }, 20821 unrenderHelper: function () { 20822 this.unrenderHelperSegs() 20823 }, 20824 renderBusinessHours: function () { 20825 var a = this.view.calendar.getBusinessHoursEvents(), 20826 b = this.eventsToSegs(a); 20827 this.renderBusinessSegs(b) 20828 }, 20829 unrenderBusinessHours: function () { 20830 this.unrenderBusinessSegs() 20831 }, 20832 getNowIndicatorUnit: function () { 20833 return "minute" 20834 }, 20835 renderNowIndicator: function (b) { 20836 var c, d = this.spanToSegs({ 20837 start: b, 20838 end: b 20839 }), 20840 e = this.computeDateTop(b, b), 20841 f = []; 20842 for (c = 0; c < d.length; c++) f.push(a('<div class="fc-now-indicator fc-now-indicator-line"></div>').css("top", e).appendTo(this.colContainerEls.eq(d[c].col))[0]); 20843 d.length > 0 && f.push(a('<div class="fc-now-indicator fc-now-indicator-arrow"></div>').css("top", e).appendTo(this.el.find(".fc-content-skeleton"))[0]), this.nowIndicatorEls = a(f) 20844 }, 20845 unrenderNowIndicator: function () { 20846 this.nowIndicatorEls && (this.nowIndicatorEls.remove(), this.nowIndicatorEls = null) 20847 }, 20848 renderSelection: function (a) { 20849 this.view.opt("selectHelper") ? this.renderEventLocationHelper(a) : this.renderHighlight(a) 20850 }, 20851 unrenderSelection: function () { 20852 this.unrenderHelper(), this.unrenderHighlight() 20853 }, 20854 renderHighlight: function (a) { 20855 this.renderHighlightSegs(this.spanToSegs(a)) 20856 }, 20857 unrenderHighlight: function () { 20858 this.unrenderHighlightSegs() 20859 } 20860 }); 20861 nb.mixin({ 20862 colContainerEls: null, 20863 fgContainerEls: null, 20864 bgContainerEls: null, 20865 helperContainerEls: null, 20866 highlightContainerEls: null, 20867 businessContainerEls: null, 20868 fgSegs: null, 20869 bgSegs: null, 20870 helperSegs: null, 20871 highlightSegs: null, 20872 businessSegs: null, 20873 renderContentSkeleton: function () { 20874 var b, c, d = ""; 20875 for (b = 0; b < this.colCnt; b++) d += '<td><div class="fc-content-col"><div class="fc-event-container fc-helper-container"></div><div class="fc-event-container"></div><div class="fc-highlight-container"></div><div class="fc-bgevent-container"></div><div class="fc-business-container"></div></div></td>'; 20876 c = a('<div class="fc-content-skeleton"><table><tr>' + d + "</tr></table></div>"), this.colContainerEls = c.find(".fc-content-col"), this.helperContainerEls = c.find(".fc-helper-container"), this.fgContainerEls = c.find(".fc-event-container:not(.fc-helper-container)"), this.bgContainerEls = c.find(".fc-bgevent-container"), this.highlightContainerEls = c.find(".fc-highlight-container"), this.businessContainerEls = c.find(".fc-business-container"), this.bookendCells(c.find("tr")), this.el.append(c) 20877 }, 20878 renderFgSegs: function (a) { 20879 return a = this.renderFgSegsIntoContainers(a, this.fgContainerEls), this.fgSegs = a, a 20880 }, 20881 unrenderFgSegs: function () { 20882 this.unrenderNamedSegs("fgSegs") 20883 }, 20884 renderHelperSegs: function (a, b) { 20885 var c, d, e; 20886 for (a = this.renderFgSegsIntoContainers(a, this.helperContainerEls), c = 0; c < a.length; c++) d = a[c], b && b.col === d.col && (e = b.el, d.el.css({ 20887 left: e.css("left"), 20888 right: e.css("right"), 20889 "margin-left": e.css("margin-left"), 20890 "margin-right": e.css("margin-right") 20891 })); 20892 this.helperSegs = a 20893 }, 20894 unrenderHelperSegs: function () { 20895 this.unrenderNamedSegs("helperSegs") 20896 }, 20897 renderBgSegs: function (a) { 20898 return a = this.renderFillSegEls("bgEvent", a), this.updateSegVerticals(a), this.attachSegsByCol(this.groupSegsByCol(a), this.bgContainerEls), this.bgSegs = a, a 20899 }, 20900 unrenderBgSegs: function () { 20901 this.unrenderNamedSegs("bgSegs") 20902 }, 20903 renderHighlightSegs: function (a) { 20904 a = this.renderFillSegEls("highlight", a), this.updateSegVerticals(a), this.attachSegsByCol(this.groupSegsByCol(a), this.highlightContainerEls), this.highlightSegs = a 20905 }, 20906 unrenderHighlightSegs: function () { 20907 this.unrenderNamedSegs("highlightSegs") 20908 },
20909 renderBusinessSegs: function (a) { 20910 a = this.renderFillSegEls("businessHours", a), this.updateSegVerticals(a), this.attachSegsByCol(this.groupSegsByCol(a), this.businessContainerEls), this.businessSegs = a 20911 }, 20912 unrenderBusinessSegs: function () { 20913 this.unrenderNamedSegs("businessSegs") 20914 }, 20915 groupSegsByCol: function (a) { 20916 var b, c = []; 20917 for (b = 0; b < this.colCnt; b++) c.push([]); 20918 for (b = 0; b < a.length; b++) c[a[b].col].push(a[b]); 20919 return c 20920 }, 20921 attachSegsByCol: function (a, b) { 20922 var c, d, e; 20923 for (c = 0; c < this.colCnt; c++) 20924 for (d = a[c], e = 0; e < d.length; e++) b.eq(c).append(d[e].el) 20925 }, 20926 unrenderNamedSegs: function (a) { 20927 var b, c = this[a]; 20928 if (c) { 20929 for (b = 0; b < c.length; b++) c[b].el.remove(); 20930 this[a] = null 20931 } 20932 }, 20933 renderFgSegsIntoContainers: function (a, b) { 20934 var c, d; 20935 for (a = this.renderFgSegEls(a), c = this.groupSegsByCol(a), d = 0; d < this.colCnt; d++) this.updateFgSegCoords(c[d]); 20936 return this.attachSegsByCol(c, b), a 20937 }, 20938 fgSegHtml: function (a, b) { 20939 var c, d, e, f = this.view, 20940 g = a.event, 20941 h = f.isEventDraggable(g), 20942 i = !b && a.isStart && f.isEventResizableFromStart(g), 20943 j = !b && a.isEnd && f.isEventResizableFromEnd(g), 20944 k = this.getSegClasses(a, h, i || j), 20945 l = $(this.getEventSkinCss(g)); 20946 return k.unshift("fc-time-grid-event", "fc-v-event"), f.isMultiDayEvent(g) ? (a.isStart || a.isEnd) && (c = this.getEventTimeText(a), d = this.getEventTimeText(a, "LT"), e = this.getEventTimeText(a, null, !1)) : (c = this.getEventTimeText(g), d = this.getEventTimeText(g, "LT"), e = this.getEventTimeText(g, null, !1)), '<a class="' + k.join(" ") + '"' + (g.url ? ' href="' + Y(g.url) + '"' : "") + (l ? ' style="' + l + '"' : "") + '><div class="fc-content">' + (c ? '<div class="fc-time" data-start="' + Y(e) + '" data-full="' + Y(d) + '"><span>' + Y(c) + "</span></div>" : "") + (g.title ? '<div class="fc-title">' + Y(g.title) + "</div>" : "") + '</div><div class="fc-bg"/>' + (j ? '<div class="fc-resizer fc-end-resizer" />' : "") + "</a>" 20947 }, 20948 updateSegVerticals: function (a) { 20949 this.computeSegVerticals(a), this.assignSegVerticals(a) 20950 }, 20951 computeSegVerticals: function (a) { 20952 var b, c; 20953 for (b = 0; b < a.length; b++) c = a[b], c.top = this.computeDateTop(c.start, c.start), c.bottom = this.computeDateTop(c.end, c.start) 20954 }, 20955 assignSegVerticals: function (a) { 20956 var b, c; 20957 for (b = 0; b < a.length; b++) c = a[b], c.el.css(this.generateSegVerticalCss(c)) 20958 }, 20959 generateSegVerticalCss: function (a) { 20960 return { 20961 top: a.top, 20962 bottom: -a.bottom 20963 } 20964 }, 20965 updateFgSegCoords: function (a) { 20966 this.computeSegVerticals(a), this.computeFgSegHorizontals(a), this.assignSegVerticals(a), this.assignFgSegHorizontals(a) 20967 }, 20968 computeFgSegHorizontals: function (a) { 20969 var b, c, d; 20970 if (this.sortEventSegs(a), b = Ea(a), Fa(b), c = b[0]) { 20971 for (d = 0; d < c.length; d++) Ga(c[d]); 20972 for (d = 0; d < c.length; d++) this.computeFgSegForwardBack(c[d], 0, 0) 20973 } 20974 }, 20975 computeFgSegForwardBack: function (a, b, c) { 20976 var d, e = a.forwardSegs; 20977 if (void 0 === a.forwardCoord) 20978 for (e.length ? (this.sortForwardSegs(e), this.computeFgSegForwardBack(e[0], b + 1, c), a.forwardCoord = e[0].backwardCoord) : a.forwardCoord = 1, a.backwardCoord = a.forwardCoord - (a.forwardCoord - c) / (b + 1), d = 0; d < e.length; d++) this.computeFgSegForwardBack(e[d], 0, a.forwardCoord) 20979 }, 20980 sortForwardSegs: function (a) { 20981 a.sort(ca(this, "compareForwardSegs")) 20982 }, 20983 compareForwardSegs: function (a, b) { 20984 return b.forwardPressure - a.forwardPressure || (a.backwardCoord || 0) - (b.backwardCoord || 0) || this.compareEventSegs(a, b) 20985 }, 20986 assignFgSegHorizontals: function (a) { 20987 var b, c; 20988 for (b = 0; b < a.length; b++) c = a[b], c.el.css(this.generateFgSegHorizontalCss(c)), c.bottom - c.top < 30 && c.el.addClass("fc-short") 20989 }, 20990 generateFgSegHorizontalCss: function (a) { 20991 var b, c, d = this.view.opt("slotEventOverlap"), 20992 e = a.backwardCoord, 20993 f = a.forwardCoord, 20994 g = this.generateSegVerticalCss(a); 20995 return d && (f = Math.min(1, e + 2 * (f - e))), this.isRTL ? (b = 1 - f, c = e) : (b = e, c = 1 - f), g.zIndex = a.level + 1, g.left = 100 * b + "%", g.right = 100 * c + "%", d && a.forwardPressure && (g[this.isRTL ? "marginLeft" : "marginRight"] = 20), g 20996 } 20997 });
20998 var ob = Pa.View = ra.extend({ 20999 type: null, 21000 name: null, 21001 title: null, 21002 calendar: null, 21003 options: null, 21004 el: null, 21005 displaying: null, 21006 isSkeletonRendered: !1, 21007 isEventsRendered: !1, 21008 start: null, 21009 end: null, 21010 intervalStart: null, 21011 intervalEnd: null, 21012 intervalDuration: null, 21013 intervalUnit: null, 21014 isRTL: !1, 21015 isSelected: !1, 21016 eventOrderSpecs: null, 21017 scrollerEl: null, 21018 scrollTop: null, 21019 widgetHeaderClass: null, 21020 widgetContentClass: null, 21021 highlightStateClass: null, 21022 nextDayThreshold: null, 21023 isHiddenDayHash: null, 21024 documentMousedownProxy: null, 21025 nowIndicatorTimeoutID: null, 21026 nowIndicatorIntervalID: null, 21027 constructor: function (a, c, d, e) { 21028 this.calendar = a, this.type = this.name = c, this.options = d, this.intervalDuration = e || b.duration(1, "day"), this.nextDayThreshold = b.duration(this.opt("nextDayThreshold")), this.initThemingProps(), this.initHiddenDays(), this.isRTL = this.opt("isRTL"), this.eventOrderSpecs = A(this.opt("eventOrder")), this.documentMousedownProxy = ca(this, "documentMousedown"), this.initialize() 21029 }, 21030 initialize: function () { }, 21031 opt: function (a) { 21032 return this.options[a] 21033 }, 21034 trigger: function (a, b) { 21035 var c = this.calendar; 21036 return c.trigger.apply(c, [a, b || this].concat(Array.prototype.slice.call(arguments, 2), [this])) 21037 }, 21038 setDate: function (a) { 21039 this.setRange(this.computeRange(a)) 21040 }, 21041 setRange: function (b) { 21042 a.extend(this, b), this.updateTitle() 21043 }, 21044 computeRange: function (a) { 21045 var b, c, d = I(this.intervalDuration), 21046 e = a.clone().startOf(d), 21047 f = e.clone().add(this.intervalDuration); 21048 return /year|month|week|day/.test(d) ? (e.stripTime(), f.stripTime()) : (e.hasTime() || (e = this.calendar.time(0)), f.hasTime() || (f = this.calendar.time(0))), b = e.clone(), b = this.skipHiddenDays(b), c = f.clone(), c = this.skipHiddenDays(c, -1, !0), { 21049 intervalUnit: d, 21050 intervalStart: e, 21051 intervalEnd: f, 21052 start: b, 21053 end: c 21054 } 21055 }, 21056 computePrevDate: function (a) { 21057 return this.massageCurrentDate(a.clone().startOf(this.intervalUnit).subtract(this.intervalDuration), -1) 21058 }, 21059 computeNextDate: function (a) { 21060 return this.massageCurrentDate(a.clone().startOf(this.intervalUnit).add(this.intervalDuration)) 21061 }, 21062 massageCurrentDate: function (a, b) { 21063 return this.intervalDuration.as("days") <= 1 && this.isHiddenDay(a) && (a = this.skipHiddenDays(a, b), a.startOf("day")), a 21064 }, 21065 updateTitle: function () { 21066 this.title = this.computeTitle() 21067 }, 21068 computeTitle: function () { 21069 return this.formatRange({ 21070 start: this.calendar.applyTimezone(this.intervalStart), 21071 end: this.calendar.applyTimezone(this.intervalEnd) 21072 }, this.opt("titleFormat") || this.computeTitleFormat(), this.opt("titleRangeSeparator")) 21073 }, 21074 computeTitleFormat: function () { 21075 return "year" == this.intervalUnit ? "YYYY" : "month" == this.intervalUnit ? this.opt("monthYearFormat") : this.intervalDuration.as("days") > 1 ? "ll" : "LL" 21076 }, 21077 formatRange: function (a, b, c) { 21078 var d = a.end; 21079 return d.hasTime() || (d = d.clone().subtract(1)), ma(a.start, d, b, c, this.opt("isRTL")) 21080 }, 21081 setElement: function (a) { 21082 this.el = a, this.bindGlobalHandlers() 21083 }, 21084 removeElement: function () { 21085 this.clear(), this.isSkeletonRendered && (this.unrenderSkeleton(), this.isSkeletonRendered = !1), this.unbindGlobalHandlers(), this.el.remove() 21086 }, 21087 display: function (b) { 21088 var c = this, 21089 d = null; 21090 return this.displaying && (d = this.queryScroll()), this.calendar.freezeContentHeight(), this.clear().then(function () { 21091 return c.displaying = a.when(c.displayView(b)).then(function () { 21092 c.forceScroll(c.computeInitialScroll(d)), c.calendar.unfreezeContentHeight(), c.triggerRe
21092nder() 21093 }) 21094 }) 21095 }, 21096 clear: function () { 21097 var b = this, 21098 c = this.displaying; 21099 return c ? c.then(function () { 21100 return b.displaying = null, b.clearEvents(), b.clearView() 21101 }) : a.when() 21102 }, 21103 redisplay: function () { 21104 if (this.isSkeletonRendered) { 21105 var a = this.isEventsRendered; 21106 this.clearEvents(), this.clearView(), this.displayView(), a && this.displayEvents(this.calendar.getEventCache()) 21107 } 21108 }, 21109 displayView: function (a) { 21110 this.isSkeletonRendered || (this.renderSkeleton(), this.isSkeletonRendered = !0), a && this.setDate(a), this.render && this.render(), this.renderDates(), this.updateSize(), this.renderBusinessHours(), this.opt("nowIndicator") && this.startNowIndicator() 21111 }, 21112 clearView: function () { 21113 this.unselect(), this.stopNowIndicator(), this.triggerUnrender(), this.unrenderBusinessHours(), this.unrenderDates(), this.destroy && this.destroy() 21114 }, 21115 renderSkeleton: function () { }, 21116 unrenderSkeleton: function () { }, 21117 renderDates: function () { }, 21118 unrenderDates: function () { }, 21119 triggerRender: function () { 21120 this.trigger("viewRender", this, this, this.el) 21121 }, 21122 triggerUnrender: function () { 21123 this.trigger("viewDestroy", this, this, this.el) 21124 }, 21125 bindGlobalHandlers: function () { 21126 a(document).on("mousedown", this.documentMousedownProxy) 21127 }, 21128 unbindGlobalHandlers: function () { 21129 a(document).off("mousedown", this.documentMousedownProxy) 21130 }, 21131 initThemingProps: function () { 21132 var a = this.opt("theme") ? "ui" : "fc"; 21133 this.widgetHeaderClass = a + "-widget-header", this.widgetContentClass = a + "-widget-content", this.highlightStateClass = a + "-state-highlight" 21134 }, 21135 renderBusinessHours: function () { }, 21136 unrenderBusinessHours: function () { }, 21137 startNowIndicator: function () { 21138 function a() { 21139 f.unrenderNowIndicator(), f.renderNowIndicator(c.clone().add(new Date - d)) 21140 } 21141 var c, d, e, f = this, 21142 g = this.getNowIndicatorUnit(); 21143 g && (c = this.calendar.getNow(), d = +new Date, this.renderNowIndicator(c), e = c.clone().startOf(g).add(1, g) - c, this.nowIndicatorTimeoutID = setTimeout(function () { 21144 this.nowIndicatorTimeoutID = null, a(), e = +b.duration(1, g), e = Math.max(100, e), this.nowIndicatorIntervalID = setInterval(a, e) 21145 }, e)) 21146 }, 21147 stopNowIndicator: function () { 21148 var a = !1; 21149 this.nowIndicatorTimeoutID && (clearTimeout(this.nowIndicatorTimeoutID), a = !0), this.nowIndicatorIntervalID && (clearTimeout(this.nowIndicatorIntervalID), a = !0), a && this.unrenderNowIndicator() 21150 }, 21151 getNowIndicatorUnit: function () { }, 21152 renderNowIndicator: function (a) { }, 21153 unrenderNowIndicator: function () { }, 21154 updateSize: function (a) { 21155 var b; 21156 a && (b = this.queryScroll()), this.updateHeight(a), this.updateWidth(a), a && this.setScroll(b) 21157 }, 21158 updateWidth: function (a) { }, 21159 updateHeight: function (a) { 21160 var b = this.calendar; 21161 this.setHeight(b.getSuggestedViewHeight(), b.isHeightAuto()) 21162 }, 21163 setHeight: function (a, b) { }, 21164 computeScrollerHeight: function (a) { 21165 var b, c, d = this.scrollerEl; 21166 return b = this.el.add(d), b.css({ 21167 position: "relative", 21168 left: -1 21169 }), c = this.el.outerHeight() - d.height(), b.css({ 21170 position: "", 21171 left: "" 21172 }), a - c 21173 }, 21174 computeInitialScroll: function (a) { 21175 return 0 21176 }, 21177 queryScroll: function () { 21178 return this.scrollerEl ? this.scrollerEl.scrollTop() : void 0 21179 }, 21180 setScroll: function (a) { 21181 return this.scrollerEl ? this.scrollerEl.scrollTop(a) : void 0 21182 }, 21183 forceScroll: function (a) { 21184 var b = this; 21185 this.setScroll(a), setTimeout(function () { 21186 b.setScroll(a) 21187 }, 0) 21188 }, 21189 displayEvents: function (a) { 21190 var b = this.queryScroll(); 21191 this.clearEvents(), this.renderEvents(a), this.isEventsRendered = !0, this.setScroll(b), this.triggerEventRender() 21192 }, 21193 clearEvents: function () { 21194 var a; 21195 this.isEventsRendered && (a = this.queryScroll(), this.triggerEventUnrender(), this.destroyEvents && this.destroyEvents(), this.unrenderEvents(), this.setScroll(a), this.isEventsRendered = !1) 21196 }, 21197 renderEvents: function (a) { }, 21198 unrenderEvents: function () { }, 21199 triggerEventRender: function () { 21200 this.renderedEventSegEach(function (a) { 21201 this.trigger("eventAfterRender", a.event, a.event, a.el) 21202 }), this.trigger("eventAfterAllRender") 21203 }, 21204 triggerEventUnrender: function () { 21205 this.renderedEventSegEach(function (a) { 21206 this.trigger("eventDestroy", a.event, a.event, a.el) 21207 }) 21208 }, 21209 resolveEventEl: function (b, c) { 21210 var d = this.trigger("eventRender", b, b, c); 21211 return d === !1 ? c = null : d && d !== !0 && (c = a(d)), c 21212 }, 21213 showEvent: function (a) { 21214 this.renderedEventSegEach(function (a) { 21215 a.el.css("visibility", "") 21216 }, a) 21217 }, 21218 hideEvent: function (a) { 21219 this.renderedEventSegEach(function (a) { 21220 a.el.css("visibility", "hidden") 21221 }, a) 21222 }, 21223 renderedEventSegEach: function (a, b) { 21224 var c, d = this.getEventSegs(); 21225 for (c = 0; c < d.length; c++) b && d[c].event._id !== b._id || d[c].el && a.call(this, d[c]) 21226 }, 21227 getEventSegs: function () { 21228 return [] 21229 }, 21230 isEventDraggable: function (a) { 21231 var b = a.source || {}; 21232 return X(a.startEditable, b.startEditable, this.opt("eventStartEditable"), a.editable, b.editable, this.opt("editable")) 21233 }, 21234 reportEventDrop: function (a, b, c, d, e) { 21235 var f = this.calendar, 21236 g = f.mutateEvent(a, b, c), 21237 h = function () { 21238 g.undo(), f.reportEventChange() 21239 }; 21240 this.triggerEventDrop(a, g.dateDelta, h, d, e), f.reportEventChange() 21241 }, 21242 triggerEventDrop: function (a, b, c, d, e) { 21243 this.trigger("eventDrop", d[0], a, b, c, e, {}) 21244 }, 21245 reportExternalDrop: function (b, c, d, e, f) { 21246 var g, h, i = b.eventProps; 21247 i && (g = a.extend({}, i, c), h = this.calendar.renderEvent(g, b.stick)[0]), this.triggerExternalDrop(h, c, d, e, f) 21248 }, 21249 triggerExternalDrop: function (a, b, c, d, e) { 21250 this.trigger("drop", c[0], b.start, d, e), a && this.trigger("eventReceive", null, a) 21251 }, 21252 renderDrag: function (a, b) { }, 21253 unrenderDrag: function () { }, 21254 isEventResizableFromStart: function (a) { 21255 return this.opt("eventResizableFromStart") && this.isEventResizable(a) 21256 }, 21257 isEventResizableFromEnd: function (a) { 21258 return this.isEventResizable(a) 21259 }, 21260 isEventResizable: function (a) { 21261 var b = a.source || {}; 21262 return X(a.durationEditable, b.durationEditable, this.opt("eventDurationEditable"), a.editable, b.editable, this.opt("editable")) 21263 }, 21264 reportEventResize: function (a, b, c, d, e) { 21265 var f = this.calendar, 21266 g = f.mutateEvent(a, b, c), 21267 h = function () { 21268 g.undo(), f.reportEventChange() 21269 }; 21270 this.triggerEventResize(a, g.durationDelta, h, d, e), f.reportEventChange() 21271 }, 21272 triggerEventResize: function (a, b, c, d, e) { 21273 this.trigger("eventResize", d[0], a, b, c, e, {}) 21274 }, 21275 select: function (a, b) { 21276 this.unselect(b), this.renderSelection(a), this.reportSelection(a, b) 21277 }, 21278 renderSelection: function (a) { }, 21279 reportSelection: function (a, b) { 21280 this.isSelected = !0, this.triggerSelect(a, b) 21281 }, 21282 triggerSelect: function (a, b) { 21283 this.trigger("select", null, this.calendar.applyTimezone(a.start), this.calendar.applyTimezone(a.end), b) 21284 }, 21285 unselect: function (a) { 21286 this.isSelected && (this.isSelected = !1, this.destroySelection && this.destroySelection(), this.unrenderSelection(), this.trigger("unselect", null, a)) 21287 }, 21288 unrenderSelection: function () { }, 21289 documentMousedown: function (b) { 21290 var c; 21291 this.isSelected && this.opt("unselectAuto") && v(b) && (c = this.opt("unselectCancel"), c && a(b.target).closest(c).length || this.unselect(b)) 21292 }, 21293 triggerDayClick: function (a, b, c) { 21294 this.trigger("dayClick", b, this.calendar.applyTimezone(a.start), c) 21295 }, 21296 initHiddenDays: function () { 21297 var b, c = this.opt("hiddenDays") || [], 21298 d = [], 21299 e = 0; 21300 for (this.opt("weekends") === !1 && c.push(0, 6), b = 0; 7 > b; b++)(d[b] = -1 !== a.inArray(b, c)) || e++;
21301 if (!e) throw "invalid hiddenDays"; 21302 this.isHiddenDayHash = d 21303 }, 21304 isHiddenDay: function (a) { 21305 return b.isMoment(a) && (a = a.day()), this.isHiddenDayHash[a] 21306 }, 21307 skipHiddenDays: function (a, b, c) { 21308 var d = a.clone(); 21309 for (b = b || 1; this.isHiddenDayHash[(d.day() + (c ? b : 0) + 7) % 7];) d.add(b, "days"); 21310 return d 21311 }, 21312 computeDayRange: function (a) { 21313 var b, c = a.start.clone().stripTime(), 21314 d = a.end, 21315 e = null; 21316 return d && (e = d.clone().stripTime(), b = +d.time(), b && b >= this.nextDayThreshold && e.add(1, "days")), (!d || c >= e) && (e = c.clone().add(1, "days")), { 21317 start: c, 21318 end: e 21319 } 21320 }, 21321 isMultiDayEvent: function (a) { 21322 var b = this.computeDayRange(a); 21323 return b.end.diff(b.start, "days") > 1 21324 } 21325 }), 21326 pb = Pa.Calendar = ra.extend({ 21327 dirDefaults: null, 21328 langDefaults: null, 21329 overrides: null, 21330 options: null, 21331 viewSpecCache: null, 21332 view: null, 21333 header: null, 21334 loadingLevel: 0, 21335 constructor: Ja, 21336 initialize: function () { }, 21337 initOptions: function (a) { 21338 var b, e, f, g; 21339 a = d(a), b = a.lang, e = qb[b], e || (b = pb.defaults.lang, e = qb[b] || {}), f = X(a.isRTL, e.isRTL, pb.defaults.isRTL), g = f ? pb.rtlDefaults : {}, this.dirDefaults = g, this.langDefaults = e, this.overrides = a, this.options = c([pb.defaults, g, e, a]), Ka(this.options), this.viewSpecCache = {} 21340 }, 21341 getViewSpec: function (a) { 21342 var b = this.viewSpecCache; 21343 return b[a] || (b[a] = this.buildViewSpec(a)) 21344 }, 21345 getUnitViewSpec: function (b) { 21346 var c, d, e; 21347 if (-1 != a.inArray(b, Ua)) 21348 for (c = this.header.getViewsWithButtons(), a.each(Pa.views, function (a) { 21349 c.push(a) 21350 }), d = 0; d < c.length; d++) 21351 if (e = this.getViewSpec(c[d]), e && e.singleUnit == b) return e 21352 }, 21353 buildViewSpec: function (a) { 21354 for (var d, e, f, g, h = this.overrides.views || {}, i = [], j = [], k = [], l = a; l;) d = Qa[l], e = h[l], l = null, "function" == typeof d && (d = { 21355 "class": d 21356 }), d && (i.unshift(d), j.unshift(d.defaults || {}), f = f || d.duration, l = l || d.type), e && (k.unshift(e), f = f || e.duration, l = l || e.type); 21357 return d = Q(i), d.type = a, d["class"] ? (f && (f = b.duration(f), f.valueOf() && (d.duration = f, g = I(f), 1 === f.as(g) && (d.singleUnit = g, k.unshift(h[g] || {})))), d.defaults = c(j), d.overrides = c(k), this.buildViewSpecOptions(d), this.buildViewSpecButtonText(d, a), d) : !1 21358 }, 21359 buildViewSpecOptions: function (a) { 21360 a.options = c([pb.defaults, a.defaults, this.dirDefaults, this.langDefaults, this.overrides, a.overrides]), Ka(a.options) 21361 }, 21362 buildViewSpecButtonText: function (a, b) { 21363 function c(c) { 21364 var d = c.buttonText || {}; 21365 return d[b] || (a.singleUnit ? d[a.singleUnit] : null) 21366 } 21367 a.buttonTextOverride = c(this.overrides) || a.overrides.buttonText, a.buttonTextDefault = c(this.langDefaults) || c(this.dirDefaults) || a.defaults.buttonText || c(pb.defaults) || (a.duration ? this.humanizeDuration(a.duration) : null) || b 21368 }, 21369 instantiateView: function (a) { 21370 var b = this.getViewSpec(a); 21371 return new b["class"](this, a, b.options, b.duration) 21372 }, 21373 isValidViewType: function (a) { 21374 return Boolean(this.getViewSpec(a)) 21375 }, 21376 pushLoading: function () { 21377 this.loadingLevel++ || this.trigger("loading", null, !0, this.view) 21378 }, 21379 popLoading: function () { 21380 --this.loadingLevel || this.trigger("loading", null, !1, this.view) 21381 }, 21382 buildSelectSpan: function (a, b) { 21383 var c, d = this.moment(a).stripZone(); 21384 return c = b ? this.moment(b).stripZone() : d.hasTime() ? d.clone().add(this.defaultTimedEventDuration) : d.
21384clone().add(this.defaultAllDayEventDuration), { 21385 start: d, 21386 end: c 21387 } 21388 } 21389 }); 21390 pb.mixin(eb), pb.defaults = { 21391 titleRangeSeparator: " â ", 21392 monthYearFormat: "MMMM YYYY", 21393 defaultTimedEventDuration: "02:00:00", 21394 defaultAllDayEventDuration: { 21395 days: 1 21396 }, 21397 forceEventDuration: !1, 21398 nextDayThreshold: "09:00:00", 21399 defaultView: "month", 21400 aspectRatio: 1.35, 21401 header: { 21402 left: "title", 21403 center: "", 21404 right: "today prev,next" 21405 }, 21406 weekends: !0, 21407 weekNumbers: !1, 21408 weekNumberTitle: "W", 21409 weekNumberCalculation: "local", 21410 scrollTime: "06:00:00", 21411 lazyFetching: !0, 21412 startParam: "start", 21413 endParam: "end", 21414 timezoneParam: "timezone", 21415 timezone: !1, 21416 isRTL: !1, 21417 buttonText: { 21418 prev: "prev", 21419 next: "next", 21420 prevYear: "prev year", 21421 nextYear: "next year", 21422 year: "year", 21423 today: "today", 21424 month: "month", 21425 week: "week", 21426 day: "day" 21427 }, 21428 buttonIcons: { 21429 prev: "left-single-arrow", 21430 next: "right-single-arrow", 21431 prevYear: "left-double-arrow", 21432 nextYear: "right-double-arrow" 21433 }, 21434 theme: !1, 21435 themeButtonIcons: { 21436 prev: "circle-triangle-w", 21437 next: "circle-triangle-e", 21438 prevYear: "seek-prev", 21439 nextYear: "seek-next" 21440 }, 21441 dragOpacity: .75, 21442 dragRevertDuration: 500, 21443 dragScroll: !0, 21444 unselectAuto: !0, 21445 dropAccept: "*", 21446 eventOrder: "title", 21447 eventLimit: !1, 21448 eventLimitText: "more", 21449 eventLimitClick: "popover", 21450 dayPopoverFormat: "LL", 21451 handleWindowResize: !0, 21452 windowResizeDelay: 200 21453 }, pb.englishDefaults = { 21454 dayPopoverFormat: "dddd, MMMM D" 21455 }, pb.rtlDefaults = { 21456 header: { 21457 left: "next,prev today", 21458 center: "", 21459 right: "title" 21460 }, 21461 buttonIcons: { 21462 prev: "right-single-arrow", 21463 next: "left-single-arrow", 21464 prevYear: "right-double-arrow", 21465 nextYear: "left-double-arrow" 21466 }, 21467 themeButtonIcons: { 21468 prev: "circle-triangle-e", 21469 next: "circle-triangle-w", 21470 nextYear: "seek-prev", 21471 prevYear: "seek-next" 21472 } 21473 }; 21474 var qb = Pa.langs = {}; 21475 Pa.datepickerLang = function (b, c, d) { 21476 var e = qb[b] || (qb[b] = {}); 21477 e.isRTL = d.isRTL, e.weekNumberTitle = d.weekHeader, a.each(rb, function (a, b) { 21478 e[a] = b(d) 21479 }), a.datepicker && (a.datepicker.regional[c] = a.datepicker.regional[b] = d, a.datepicker.regional.en = a.datepicker.regional[""], a.datepicker.setDefaults(d)) 21480 }, Pa.lang = function (b, d) { 21481 var e, f; 21482 e = qb[b] || (qb[b] = {}), d && (e = qb[b] = c([e, d])), f = La(b), a.each(sb, function (a, b) { 21483 null == e[a] && (e[a] = b(f, e)) 21484 }), pb.defaults.lang = b 21485 }; 21486 var rb = { 21487 buttonText: function (a) { 21488 return { 21489 prev: Z(a.prevText), 21490 next: Z(a.nextText), 21491 today: Z(a.currentText) 21492 } 21493 }, 21494 monthYearFormat: function (a) { 21495 return a.showMonthAfterYear ? "YYYY[" + a.yearSuffix + "] MMMM" : "MMMM YYYY[" + a.yearSuffix + "]" 21496 } 21497 }, 21498 sb = { 21499 dayOfMonthFormat: function (a, b) { 21500 var c = a.longDateFormat("l"); 21501 return c = c.replace(/^Y+[^\w\s]*|[^\w\s]*Y+$/g, ""), b.isRTL ? c += " ddd" : c = "ddd " + c, c 21502 }, 21503 mediumTimeFormat: function (a) { 21504 return a.longDateFormat("LT").replace(/\s*a$/i, "a") 21505 }, 21506 smallTimeFormat: function (a) { 21507 return a.longDateFormat("LT").replace(":mm", "(:mm)").replace(/(\Wmm)$/, "($1)").replace(/\s*a$/i, "a") 21508 }, 21509 extraSmallTimeFormat: function (a) { 21510 return a.longDateFormat("LT").replace(":mm", "(:mm)").replace(/(\Wmm)$/, "($1)").replace(/\s*a$/i, "t") 21511 }, 21512 hourFormat: function (a) { 21513 return a.longDateFormat("LT").replace(":mm", "").replace(/(\Wmm)$/, "").replace(/\s*a$/i, "a") 21514 }, 21515 noMeridiemTimeFormat: function (a) { 21516 return a.longDateFormat("LT").replace(/\s*a$/i, "") 21517 } 21518 }, 21519 tb = { 21520 smallDayDateFormat: function (a) { 21521 return a.isRTL ? "D dd" : "dd D"; 21522 }, 21523 weekFormat: function (a) { 21524 return a.isRTL ? "w[ " + a.weekNumberTitle + "]" : "[" + a.weekNumberTitle + " ]w" 21525 }, 21526 smallWeekFormat: function (a) { 21527 return a.isRTL ? "w[" + a.weekNumberTitle + "]" : "[" + a.weekNumberTitle + "]w" 21528 } 21529 }; 21530 Pa.lang("en", pb.englishDefaults), Pa.sourceNormalizers = [], Pa.sourceFetchers = []; 21531 var ub = { 21532 dataType: "json", 21533 cache: !1 21534 }, 21535 vb = 1; 21536 pb.prototype.getPeerEvents = function (a, b) { 21537 var c, d, e = this.getEventCache(), 21538 f = []; 21539 for (c = 0; c < e.length; c++) d = e[c], b && b._id === d._id || f.push(d); 21540 return f 21541 }; 21542 var wb = Pa.BasicView = ob.extend({ 21543 dayGridClass: mb, 21544 dayGrid: null, 21545 dayNumbersVisible: !1, 21546 weekNumbersVisible: !1, 21547 weekNumberWidth: null, 21548 headContainerEl: null, 21549 headRowEl: null, 21550 initialize: function () { 21551 this.dayGrid = this.instantiateDayGrid() 21552 }, 21553 instantiateDayGrid: function () { 21554 var a = this.dayGridClass.extend(xb); 21555 return new a(this) 21556 }, 21557 setRange: function (a) { 21558 ob.prototype.setRange.call(this, a), this.dayGrid.breakOnWeeks = /year|month|week/.test(this.intervalUnit), this.dayGrid.setRange(a) 21559 }, 21560 computeRange: function (a) { 21561 var b = ob.prototype.computeRange.call(this, a); 21562 return /year|month/.test(b.intervalUnit) && (b.start.startOf("week"), b.start = this.skipHiddenDays(b.start), b.end.weekday() && (b.end.add(1, "week").startOf("week"), b.end = this.skipHiddenDays(b.end, -1, !0))), b 21563 }, 21564 renderDates: function () { 21565 this.dayNumbersVisible = this.dayGrid.rowCnt > 1, this.weekNumbersVisible = this.opt("weekNumbers"), this.dayGrid.numbersVisible = this.dayNumbersVisible || this.weekNumbersVisible, this.el.addClass("fc-basic-view").html(this.renderSkeletonHtml()), this.renderHead(), this.scrollerEl = this.el.find(".fc-day-grid-container"), this.dayGrid.setElement(this.el.find(".fc-day-grid")), this.dayGrid.renderDates(this.hasRigidRows()) 21566 }, 21567 renderHead: function () { 21568 this.headContainerEl = this.el.find(".fc-head-container").html(this.dayGrid.renderHeadHtml()), this.headRowEl = this.headContainerEl.find(".fc-row") 21569 }, 21570 unrenderDates: function () { 21571 this.dayGrid.unrenderDates(), this.dayGrid.removeElement() 21572 }, 21573 renderBusinessHours: function () { 21574 this.dayGrid.renderBusinessHours() 21575 }, 21576 renderSkeletonHtml: function () { 21577 return '<table><thead class="fc-head"><tr><td class="fc-head-container ' + this.widgetHeaderClass + '"></td></tr></thead><tbody class="fc-body"><tr><td class="' + this.widgetContentClass + '"><div class="fc-day-grid-container"><div class="fc-day-grid"/></div></td></tr></tbody></table>' 21578 }, 21579 weekNumberStyleAttr: function () { 21580 return null !== this.weekNumberWidth ? 'style="width:' + this.weekNumberWidth + 'px"' : "" 21581 }, 21582 hasRigidRows: function () { 21583 var a = this.opt("eventLimit"); 21584 return a && "number" != typeof a 21585 }, 21586 updateWidth: function () { 21587 this.weekNumbersVisible && (this.weekNumberWidth = k(this.el.find(".fc-week-number"))) 21588 }, 21589 setHeight: function (a, b) { 21590 var c, d = this.opt("eventLimit"); 21591 m(this.scrollerEl), f(this.headRowEl), this.dayGrid.removeSegPopover(), d && "number" == typeof d && this.dayGrid.limitRows(d), c = this.computeScrollerHeight(a), this.setGridHeight(c, b), d && "number" != typeof d && this.dayGrid.limitRows(d), !b && l(this.scrollerEl, c) && (e(this.headRowEl, r(this.scrollerEl)), c = this.computeScrollerHeight(a), this.scrollerEl.height(c)) 21592 }, 21593 setGridHeight: function (a, b) { 21594 b ? j(this.dayGrid.rowEls) : i(this.dayGrid.rowEls, a, !0) 21595 }, 21596 prepareHits: function () { 21597 this.dayGrid.prepareHits() 21598 }, 21599 releaseHits: function () { 21600 this.dayGrid.releaseHits() 21601 }, 21602 queryHit: function (a, b) { 21603 return this.dayGrid.queryHit(a, b) 21604 }, 21605 getHitSpan: function (a) { 21606 return this.dayGrid.getHitSpan(a) 21607 }, 21608 getHitEl: function (a) { 21609 return this.dayGrid.getHitEl(a) 21610 }, 21611 renderEvents: function (a) { 21612 this.dayGrid.renderEvents(a), this.updateHeight() 21613 }, 21614 getEventSegs: function () { 21615 return this.dayGrid.getEventSegs() 21616 }, 21617 unrenderEvents: function () { 21618 this.dayGrid.unrenderEvents() 21619 }, 21620 renderDrag: function (a, b) { 21621 return this.dayGrid.renderDrag(a, b) 21622 }, 21623 unrenderDrag: function () { 21624 this.dayGrid.unrenderDrag() 21625 }, 21626 renderSelection: function (a) { 21627 this.dayGrid.renderSelection(a) 21628 }, 21629 unrenderSelection: function () { 21630 this.dayGrid.unrenderSelection() 21631 } 21632 }), 21633 xb = { 21634 renderHeadIntroHtml: function () { 21635 var a = this.view; 21636 return a.weekNumbersVisible ? '<th class="fc-week-number ' + a.widgetHeaderClass + '" ' + a.weekNumberStyleAttr() + "><span>" + Y(a.opt("weekNumberTitle")) + "</span></th>" : "" 21637 }, 21638 renderNumberIntroHtml: function (a) { 21639 var b = this.view; 21640 return b.weekNumbersVisible ? '<td class="fc-week-number" ' + b.weekNumberStyleAttr() + "><span>" + this.getCellDate(a, 0).format("w") + "</span></td>" : "" 21641 }, 21642 renderBgIntroHtml: function () { 21643 var a = this.view; 21644 return a.weekNumbersVisible ? '<td class="fc-week-number ' + a.widgetContentClass + '" ' + a.weekNumberStyleAttr() + "></td>" : "" 21645 }, 21646 renderIntroHtml: function () { 21647 var a = this.view; 21648 return a.weekNumbersVisible ? '<td class="fc-week-number" ' + a.weekNumberStyleAttr() + "></td>" : "" 21649 } 21650 }, 21651 yb = Pa.MonthView = wb.extend({ 21652 computeRange: function (a) { 21653 var b, c = wb.prototype.computeRange.call(this, a);
21654 return this.isFixedWeeks() && (b = Math.ceil(c.end.diff(c.start, "weeks", !0)), c.end.add(6 - b, "weeks")), c 21655 }, 21656 setGridHeight: function (a, b) { 21657 b = b || "variable" === this.opt("weekMode"), b && (a *= this.rowCnt / 6), i(this.dayGrid.rowEls, a, !b) 21658 }, 21659 isFixedWeeks: function () { 21660 var a = this.opt("weekMode"); 21661 return a ? "fixed" === a : this.opt("fixedWeekCount") 21662 } 21663 }); 21664 Qa.basic = { 21665 "class": wb 21666 }, Qa.basicDay = { 21667 type: "basic", 21668 duration: { 21669 days: 1 21670 } 21671 }, Qa.basicWeek = { 21672 type: "basic", 21673 duration: { 21674 weeks: 1 21675 } 21676 }, Qa.month = { 21677 "class": yb, 21678 duration: { 21679 months: 1 21680 }, 21681 defaults: { 21682 fixedWeekCount: !0 21683 } 21684 }; 21685 var zb = Pa.AgendaView = ob.extend({ 21686 timeGridClass: nb, 21687 timeGrid: null, 21688 dayGridClass: mb, 21689 dayGrid: null, 21690 axisWidth: null, 21691 headContainerEl: null, 21692 noScrollRowEls: null, 21693 bottomRuleEl: null, 21694 bottomRuleHeight: null, 21695 initialize: function () { 21696 this.timeGrid = this.instantiateTimeGrid(), this.opt("allDaySlot") && (this.dayGrid = this.instantiateDayGrid()) 21697 }, 21698 instantiateTimeGrid: function () { 21699 var a = this.timeGridClass.extend(Ab); 21700 return new a(this) 21701 }, 21702 instantiateDayGrid: function () { 21703 var a = this.dayGridClass.extend(Bb); 21704 return new a(this) 21705 }, 21706 setRange: function (a) { 21707 ob.prototype.setRange.call(this, a), this.timeGrid.setRange(a), this.dayGrid && this.dayGrid.setRange(a) 21708 }, 21709 renderDates: function () { 21710 this.el.addClass("fc-agenda-view").html(this.renderSkeletonHtml()), this.renderHead(), this.scrollerEl = this.el.find(".fc-time-grid-container"), this.timeGrid.setElement(this.el.find(".fc-time-grid")), this.timeGrid.renderDates(), this.bottomRuleEl = a('<hr class="fc-divider ' + this.widgetHeaderClass + '"/>').appendTo(this.timeGrid.el), this.dayGrid && (this.dayGrid.setElement(this.el.find(".fc-day-grid")), this.dayGrid.renderDates(), this.dayGrid.bottomCoordPadding = this.dayGrid.el.next("hr").outerHeight()), this.noScrollRowEls = this.el.find(".fc-row:not(.fc-scroller *)") 21711 }, 21712 renderHead: function () { 21713 this.headContainerEl = this.el.find(".fc-head-container").html(this.timeGrid.renderHeadHtml()) 21714 }, 21715 unrenderDates: function () { 21716 this.timeGrid.unrenderDates(), this.timeGrid.removeElement(), this.dayGrid && (this.dayGrid.unrenderDates(), this.dayGrid.removeElement()) 21717 }, 21718 renderSkeletonHtml: function () { 21719 return '<table><thead class="fc-head"><tr><td class="fc-head-container ' + this.widgetHeaderClass + '"></td></tr></thead><tbody class="fc-body"><tr><td class="' + this.widgetContentClass + '">' + (this.dayGrid ? '<div class="fc-day-grid"/><hr class="fc-divider ' + this.widgetHeaderClass + '"/>' : "") + '<div class="fc-time-grid-container"><div class="fc-time-grid"/></div></td></tr></tbody></table>' 21720 }, 21721 axisStyleAttr: function () { 21722 return null !== this.axisWidth ? 'style="width:' + this.axisWidth + 'px"' : "" 21723 }, 21724 renderBusinessHours: function () { 21725 this.timeGrid.renderBusinessHours(), this.dayGrid && this.dayGrid.renderBusinessHours() 21726 }, 21727 unrenderBusinessHours: function () { 21728 this.timeGrid.unrenderBusinessHours(), this.dayGrid && this.dayGrid.unrenderBusinessHours() 21729 }, 21730 getNowIndicatorUnit: function () { 21731 return this.timeGrid.getNowIndicatorUnit() 21732 }, 21733 renderNowIndicator: function (a) { 21734 this.timeGrid.renderNowIndicator(a) 21735 }, 21736 unrenderNowIndicator: function () { 21737 this.timeGrid.unrenderNowIndicator() 21738 }, 21739 updateSize: function (a) { 21740 this.timeGrid.updateSize(a), ob.prototype.updateSize.call(this, a) 21741 }, 21742 updateWidth: function () { 21743 this.axisWidth = k(this.el.find(".fc-axis")) 21744 }, 21745 setHeight: function (a, b) { 21746 var c, d; 21747 null === this.bottomRuleHeight && (this.bottomRuleHeight = this.bottomRuleEl.outerHeight()), this.bottomRuleEl.hide(), this.scrollerEl.css("overflow", ""), m(this.scrollerEl), f(this.noScrollRowEls), this.dayGrid && (this.dayGrid.removeSegPopover(), c = this.opt("eventLimit"), c && "number" != typeof c && (c = Cb), c && this.dayGrid.limitRows(c)), b || (d = this.computeScrollerHeight(a), l(this.scrollerEl, d) ? (e(this.noScrollRowEls, r(this.scrollerEl)), d = this.computeScrollerHeight(a), this.scrollerEl.height(d)) : (this.scrollerEl.height(d).css("overflow", "hidden"), this.bottomRuleEl.show())) 21748 }, 21749 computeInitialScroll: function () { 21750 var a = b.duration(this.opt("scrollTime")), 21751 c = this.timeGrid.computeTimeTop(a); 21752 return c = Math.ceil(c), c && c++ , c 21753 }, 21754 prepareHits: function () { 21755 this.timeGrid.prepareHits(), this.dayGrid && this.dayGrid.prepareHits() 21756 }, 21757 releaseHits: function () { 21758 this.timeGrid.releaseHits(), this.dayGrid && this.dayGrid.releaseHits() 21759 }, 21760 queryHit: function (a, b) { 21761 var c = this.timeGrid.queryHit(a, b); 21762 return !c && this.dayGrid && (c = this.dayGrid.queryHit(a, b)), c 21763 }, 21764 getHitSpan: function (a) { 21765 return a.component.getHitSpan(a) 21766 }, 21767 getHitEl: function (a) { 21768 return a.component.getHitEl(a) 21769 }, 21770 renderEvents: function (a) { 21771 var b, c, d = [], 21772 e = [], 21773 f = []; 21774 for (c = 0; c < a.length; c++) a[c].allDay ? d.push(a[c]) : e.push(a[c]); 21775 b = this.timeGrid.renderEvents(e), this.dayGrid && (f = this.dayGrid.renderEvents(d)), this.updateHeight() 21776 }, 21777 getEventSegs: function () { 21778 return this.timeGrid.getEventSegs().concat(this.dayGrid ? this.dayGrid.getEventSegs() : []) 21779 }, 21780 unrenderEvents: function () { 21781 this.timeGrid.unrenderEvents(), this.dayGrid && this.dayGrid.unrenderEvents() 21782 }, 21783 renderDrag: function (a, b) { 21784 return a.start.hasTime() ? this.timeGrid.renderDrag(a, b) : this.dayGrid ? this.dayGrid.renderDrag(a, b) : void 0 21785 }, 21786 unrenderDrag: function () { 21787 this.timeGrid.unrenderDrag(), this.dayGrid && this.dayGrid.unrenderDrag() 21788 }, 21789 renderSelection: function (a) { 21790 a.start.hasTime() || a.end.hasTime() ? this.timeGrid.renderSelection(a) : this.dayGrid && this.dayGrid.renderSelection(a) 21791 }, 21792 unrenderSelection: function () { 21793 this.timeGrid.unrenderSelection(), this.dayGrid && this.dayGrid.unrenderSelection() 21794 } 21795 }), 21796 Ab = { 21797 renderHeadIntroHtml: function () { 21798 var a, b = this.view; 21799 return b.opt("weekNumbers") ? (a = this.start.format(b.opt("smallWeekFormat")), '<th class="fc-axis fc-week-number ' + b.widgetHeaderClass + '" ' + b.axisStyleAttr() + "><span>" + Y(a) + "</span></th>") : '<th class="fc-axis ' + b.widgetHeaderClass + '" ' + b.axisStyleAttr() + "></th>" 21800 }, 21801 renderBgIntroHtml: function () { 21802 var a = this.view; 21803 return '<td class="fc-axis ' + a.widgetContentClass + '" ' + a.axisStyleAttr() + "></td>" 21804 }, 21805 renderIntroHtml: function () { 21806 var a = this.view; 21807 return '<td class="fc-axis" ' + a.axisStyleAttr() + "></td>" 21808 } 21809 }, 21810 Bb = { 21811 renderBgIntroHtml: function () { 21812 var a = this.view; 21813 return '<td class="fc-axis ' + a.widgetContentClass + '" ' + a.axisStyleAttr() + "><span>" + (a.opt("allDayHtml") || Y(a.opt("allDayText"))) + "</span></td>" 21814 }, 21815 renderIntroHtml: function () { 21816 var a = this.view; 21817 return '<td class="fc-axis" ' + a.axisStyleAttr() + "></td>" 21818 } 21819 }, 21820 Cb = 5, 21821 Db = [{ 21822 hours: 1 21823 }, { 21824 minutes: 30 21825 }, { 21826 minutes: 15 21827 }, { 21828 seconds: 30 21829 }, { 21830 seconds: 15 21831 }]; 21832 return Qa.agenda = { 21833 "class": zb, 21834 defaults: { 21835 allDaySlot: !0, 21836 allDayText: "all-day", 21837 slotDuration: "00:30:00", 21838 minTime: "00:00:00", 21839 maxTime: "24:00:00", 21840 slotEventOverlap: !0 21841 } 21842 }, Qa.agendaDay = { 21843 type: "agenda", 21844 duration: { 21845 days: 1 21846 } 21847 }, Qa.agendaWeek = { 21848 type: "agenda", 21849 duration: { 21850 weeks: 1 21851 } 21852 }, Pa 21853});
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.