Advertisement
Guest User

Untitled

a guest
Mar 11th, 2016
277
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 341.25 KB | None | 0 0
  1. function onYouTubePlayerAPIReady() {
  2. mejs.YouTubeApi.iFrameReady()
  3. }
  4. function onYouTubePlayerReady(a) {
  5. mejs.YouTubeApi.flashReady(a)
  6. }
  7. function refreshWaypoints() {
  8. $.waypoints("refresh")
  9. }
  10. function findInArray(a, b, c) {
  11. for (var d in a)if (a[d].hasOwnProperty(b) && a[d][b] === c)return a[d].post_id;
  12. return !1
  13. }
  14. +function (a) {
  15. "use strict";
  16. function b() {
  17. var a = document.createElement("bootstrap"), b = {
  18. WebkitTransition: "webkitTransitionEnd",
  19. MozTransition: "transitionend",
  20. OTransition: "oTransitionEnd otransitionend",
  21. transition: "transitionend"
  22. };
  23. for (var c in b)if (void 0 !== a.style[c])return {end: b[c]}
  24. }
  25.  
  26. a.fn.emulateTransitionEnd = function (b) {
  27. var c = !1, d = this;
  28. a(this).one(a.support.transition.end, function () {
  29. c = !0
  30. });
  31. var e = function () {
  32. c || a(d).trigger(a.support.transition.end)
  33. };
  34. return setTimeout(e, b), this
  35. }, a(function () {
  36. a.support.transition = b()
  37. })
  38. }(jQuery), +function (a) {
  39. "use strict";
  40. var b = function (c, d) {
  41. this.$element = a(c), this.options = a.extend({}, b.DEFAULTS, d), this.transitioning = null, this.options.parent && (this.$parent = a(this.options.parent)), this.options.toggle && this.toggle()
  42. };
  43. b.DEFAULTS = {toggle: !0}, b.prototype.dimension = function () {
  44. var a = this.$element.hasClass("width");
  45. return a ? "width" : "height"
  46. }, b.prototype.show = function () {
  47. if (!this.transitioning && !this.$element.hasClass("in")) {
  48. var b = a.Event("show.bs.collapse");
  49. if (this.$element.trigger(b), !b.isDefaultPrevented()) {
  50. var c = this.$parent && this.$parent.find("> .panel > .in");
  51. if (c && c.length) {
  52. var d = c.data("bs.collapse");
  53. if (d && d.transitioning)return;
  54. c.collapse("hide"), d || c.data("bs.collapse", null)
  55. }
  56. var e = this.dimension();
  57. this.$element.removeClass("collapse").addClass("collapsing")[e](0), this.transitioning = 1;
  58. var f = function () {
  59. this.$element.removeClass("collapsing").addClass("in")[e]("auto"), this.transitioning = 0, this.$element.trigger("shown.bs.collapse")
  60. };
  61. if (!a.support.transition)return f.call(this);
  62. var g = a.camelCase(["scroll", e].join("-"));
  63. this.$element.one(a.support.transition.end, a.proxy(f, this)).emulateTransitionEnd(350)[e](this.$element[0][g])
  64. }
  65. }
  66. }, b.prototype.hide = function () {
  67. if (!this.transitioning && this.$element.hasClass("in")) {
  68. var b = a.Event("hide.bs.collapse");
  69. if (this.$element.trigger(b), !b.isDefaultPrevented()) {
  70. var c = this.dimension();
  71. this.$element[c](this.$element[c]())[0].offsetHeight, this.$element.addClass("collapsing").removeClass("collapse").removeClass("in"), this.transitioning = 1;
  72. var d = function () {
  73. this.transitioning = 0, this.$element.trigger("hidden.bs.collapse").removeClass("collapsing").addClass("collapse")
  74. };
  75. return a.support.transition ? (this.$element[c](0).one(a.support.transition.end, a.proxy(d, this)).emulateTransitionEnd(350), void 0) : d.call(this)
  76. }
  77. }
  78. }, b.prototype.toggle = function () {
  79. this[this.$element.hasClass("in") ? "hide" : "show"]()
  80. };
  81. var c = a.fn.collapse;
  82. a.fn.collapse = function (c) {
  83. return this.each(function () {
  84. var d = a(this), e = d.data("bs.collapse"), f = a.extend({}, b.DEFAULTS, d.data(), "object" == typeof c && c);
  85. e || d.data("bs.collapse", e = new b(this, f)), "string" == typeof c && e[c]()
  86. })
  87. }, a.fn.collapse.Constructor = b, a.fn.collapse.noConflict = function () {
  88. return a.fn.collapse = c, this
  89. }, a(document).on("click.bs.collapse.data-api", "[data-toggle=collapse]", function (b) {
  90. var c, d = a(this), e = d.attr("data-target") || b.preventDefault() || (c = d.attr("href")) && c.replace(/.*(?=#[^\s]+$)/, ""), f = a(e), g = f.data("bs.collapse"), h = g ? "toggle" : d.data(), i = d.attr("data-parent"), j = i && a(i);
  91. g && g.transitioning || (j && j.find('[data-toggle=collapse][data-parent="' + i + '"]').not(d).addClass("collapsed"), d[f.hasClass("in") ? "addClass" : "removeClass"]("collapsed")), f.collapse(h)
  92. })
  93. }(jQuery), +function (a) {
  94. "use strict";
  95. var b = function (b, c) {
  96. this.options = c, this.$element = a(b), this.$backdrop = this.isShown = null, this.options.remote && this.$element.load(this.options.remote)
  97. };
  98. b.DEFAULTS = {backdrop: !0, keyboard: !0, show: !0}, b.prototype.toggle = function (a) {
  99. return this[this.isShown ? "hide" : "show"](a)
  100. }, b.prototype.show = function (b) {
  101. var c = this, d = a.Event("show.bs.modal", {relatedTarget: b});
  102. this.$element.trigger(d), this.isShown || d.isDefaultPrevented() || (this.isShown = !0, this.escape(), this.$element.on("click.dismiss.modal", '[data-dismiss="modal"]', a.proxy(this.hide, this)), this.backdrop(function () {
  103. var d = a.support.transition && c.$element.hasClass("fade");
  104. c.$element.parent().length || c.$element.appendTo(document.body), c.$element.show(), d && c.$element[0].offsetWidth, c.$element.addClass("in").attr("aria-hidden", !1), c.enforceFocus();
  105. var e = a.Event("shown.bs.modal", {relatedTarget: b});
  106. d ? c.$element.find(".modal-dialog").one(a.support.transition.end, function () {
  107. c.$element.focus().trigger(e)
  108. }).emulateTransitionEnd(300) : c.$element.focus().trigger(e)
  109. }))
  110. }, b.prototype.hide = function (b) {
  111. b && b.preventDefault(), b = a.Event("hide.bs.modal"), this.$element.trigger(b), this.isShown && !b.isDefaultPrevented() && (this.isShown = !1, this.escape(), a(document).off("focusin.bs.modal"), this.$element.removeClass("in").attr("aria-hidden", !0).off("click.dismiss.modal"), a.support.transition && this.$element.hasClass("fade") ? this.$element.one(a.support.transition.end, a.proxy(this.hideModal, this)).emulateTransitionEnd(300) : this.hideModal())
  112. }, b.prototype.enforceFocus = function () {
  113. a(document).off("focusin.bs.modal").on("focusin.bs.modal", a.proxy(function (a) {
  114. this.$element[0] === a.target || this.$element.has(a.target).length || this.$element.focus()
  115. }, this))
  116. }, b.prototype.escape = function () {
  117. this.isShown && this.options.keyboard ? this.$element.on("keyup.dismiss.bs.modal", a.proxy(function (a) {
  118. 27 == a.which && this.hide()
  119. }, this)) : this.isShown || this.$element.off("keyup.dismiss.bs.modal")
  120. }, b.prototype.hideModal = function () {
  121. var a = this;
  122. this.$element.hide(), this.backdrop(function () {
  123. a.removeBackdrop(), a.$element.trigger("hidden.bs.modal")
  124. })
  125. }, b.prototype.removeBackdrop = function () {
  126. this.$backdrop && this.$backdrop.remove(), this.$backdrop = null
  127. }, b.prototype.backdrop = function (b) {
  128. var c = this.$element.hasClass("fade") ? "fade" : "";
  129. if (this.isShown && this.options.backdrop) {
  130. var d = a.support.transition && c;
  131. if (this.$backdrop = a('<div class="modal-backdrop ' + c + '" />').appendTo(document.body), this.$element.on("click.dismiss.modal", a.proxy(function (a) {
  132. a.target === a.currentTarget && ("static" == this.options.backdrop ? this.$element[0].focus.call(this.$element[0]) : this.hide.call(this))
  133. }, this)), d && this.$backdrop[0].offsetWidth, this.$backdrop.addClass("in"), !b)return;
  134. d ? this.$backdrop.one(a.support.transition.end, b).emulateTransitionEnd(150) : b()
  135. } else!this.isShown && this.$backdrop ? (this.$backdrop.removeClass("in"), a.support.transition && this.$element.hasClass("fade") ? this.$backdrop.one(a.support.transition.end, b).emulateTransitionEnd(150) : b()) : b && b()
  136. };
  137. var c = a.fn.modal;
  138. a.fn.modal = function (c, d) {
  139. return this.each(function () {
  140. var e = a(this), f = e.data("bs.modal"), g = a.extend({}, b.DEFAULTS, e.data(), "object" == typeof c && c);
  141. f || e.data("bs.modal", f = new b(this, g)), "string" == typeof c ? f[c](d) : g.show && f.show(d)
  142. })
  143. }, a.fn.modal.Constructor = b, a.fn.modal.noConflict = function () {
  144. return a.fn.modal = c, this
  145. }, a(document).on("click.bs.modal.data-api", '[data-toggle="modal"]', function (b) {
  146. var c = a(this), d = c.attr("href"), e = a(c.attr("data-target") || d && d.replace(/.*(?=#[^\s]+$)/, "")), f = e.data("modal") ? "toggle" : a.extend({remote: !/#/.test(d) && d}, e.data(), c.data());
  147. b.preventDefault(), e.modal(f, this).one("hide", function () {
  148. c.is(":visible") && c.focus()
  149. })
  150. }), a(document).on("show.bs.modal", ".modal", function () {
  151. a(document.body).addClass("modal-open")
  152. }).on("hidden.bs.modal", ".modal", function () {
  153. a(document.body).removeClass("modal-open")
  154. })
  155. }(jQuery), +function (a) {
  156. "use strict";
  157. var b = function (a, b) {
  158. this.type = this.options = this.enabled = this.timeout = this.hoverState = this.$element = null, this.init("tooltip", a, b)
  159. };
  160. b.DEFAULTS = {
  161. animation: !0,
  162. placement: "top",
  163. selector: !1,
  164. template: '<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',
  165. trigger: "hover focus",
  166. title: "",
  167. delay: 0,
  168. html: !1,
  169. container: !1
  170. }, b.prototype.init = function (b, c, d) {
  171. this.enabled = !0, this.type = b, this.$element = a(c), this.options = this.getOptions(d);
  172. for (var e = this.options.trigger.split(" "), f = e.length; f--;) {
  173. var g = e[f];
  174. if ("click" == g)this.$element.on("click." + this.type, this.options.selector, a.proxy(this.toggle, this)); else if ("manual" != g) {
  175. var h = "hover" == g ? "mouseenter" : "focus", i = "hover" == g ? "mouseleave" : "blur";
  176. this.$element.on(h + "." + this.type, this.options.selector, a.proxy(this.enter, this)), this.$element.on(i + "." + this.type, this.options.selector, a.proxy(this.leave, this))
  177. }
  178. }
  179. this.options.selector ? this._options = a.extend({}, this.options, {
  180. trigger: "manual",
  181. selector: ""
  182. }) : this.fixTitle()
  183. }, b.prototype.getDefaults = function () {
  184. return b.DEFAULTS
  185. }, b.prototype.getOptions = function (b) {
  186. return b = a.extend({}, this.getDefaults(), this.$element.data(), b), b.delay && "number" == typeof b.delay && (b.delay = {
  187. show: b.delay,
  188. hide: b.delay
  189. }), b
  190. }, b.prototype.getDelegateOptions = function () {
  191. var b = {}, c = this.getDefaults();
  192. return this._options && a.each(this._options, function (a, d) {
  193. c[a] != d && (b[a] = d)
  194. }), b
  195. }, b.prototype.enter = function (b) {
  196. var c = b instanceof this.constructor ? b : a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs." + this.type);
  197. return clearTimeout(c.timeout), c.hoverState = "in", c.options.delay && c.options.delay.show ? (c.timeout = setTimeout(function () {
  198. "in" == c.hoverState && c.show()
  199. }, c.options.delay.show), void 0) : c.show()
  200. }, b.prototype.leave = function (b) {
  201. var c = b instanceof this.constructor ? b : a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs." + this.type);
  202. return clearTimeout(c.timeout), c.hoverState = "out", c.options.delay && c.options.delay.hide ? (c.timeout = setTimeout(function () {
  203. "out" == c.hoverState && c.hide()
  204. }, c.options.delay.hide), void 0) : c.hide()
  205. }, b.prototype.show = function () {
  206. var b = a.Event("show.bs." + this.type);
  207. if (this.hasContent() && this.enabled) {
  208. if (this.$element.trigger(b), b.isDefaultPrevented())return;
  209. var c = this.tip();
  210. this.setContent(), this.options.animation && c.addClass("fade");
  211. var d = "function" == typeof this.options.placement ? this.options.placement.call(this, c[0], this.$element[0]) : this.options.placement, e = /\s?auto?\s?/i, f = e.test(d);
  212. f && (d = d.replace(e, "") || "top"), c.detach().css({
  213. top: 0,
  214. left: 0,
  215. display: "block"
  216. }).addClass(d), this.options.container ? c.appendTo(this.options.container) : c.insertAfter(this.$element);
  217. var g = this.getPosition(), h = c[0].offsetWidth, i = c[0].offsetHeight;
  218. if (f) {
  219. var j = this.$element.parent(), k = d, l = document.documentElement.scrollTop || document.body.scrollTop, m = "body" == this.options.container ? window.innerWidth : j.outerWidth(), n = "body" == this.options.container ? window.innerHeight : j.outerHeight(), o = "body" == this.options.container ? 0 : j.offset().left;
  220. d = "bottom" == d && g.top + g.height + i - l > n ? "top" : "top" == d && g.top - l - i < 0 ? "bottom" : "right" == d && g.right + h > m ? "left" : "left" == d && g.left - h < o ? "right" : d, c.removeClass(k).addClass(d)
  221. }
  222. var p = this.getCalculatedOffset(d, g, h, i);
  223. this.applyPlacement(p, d), this.$element.trigger("shown.bs." + this.type)
  224. }
  225. }, b.prototype.applyPlacement = function (a, b) {
  226. var c, d = this.tip(), e = d[0].offsetWidth, f = d[0].offsetHeight, g = parseInt(d.css("margin-top"), 10), h = parseInt(d.css("margin-left"), 10);
  227. isNaN(g) && (g = 0), isNaN(h) && (h = 0), a.top = a.top + g, a.left = a.left + h, d.offset(a).addClass("in");
  228. var i = d[0].offsetWidth, j = d[0].offsetHeight;
  229. if ("top" == b && j != f && (c = !0, a.top = a.top + f - j), /bottom|top/.test(b)) {
  230. var k = 0;
  231. a.left < 0 && (k = -2 * a.left, a.left = 0, d.offset(a), i = d[0].offsetWidth, j = d[0].offsetHeight), this.replaceArrow(k - e + i, i, "left")
  232. } else this.replaceArrow(j - f, j, "top");
  233. c && d.offset(a)
  234. }, b.prototype.replaceArrow = function (a, b, c) {
  235. this.arrow().css(c, a ? 50 * (1 - a / b) + "%" : "")
  236. }, b.prototype.setContent = function () {
  237. var a = this.tip(), b = this.getTitle();
  238. a.find(".tooltip-inner")[this.options.html ? "html" : "text"](b), a.removeClass("fade in top bottom left right")
  239. }, b.prototype.hide = function () {
  240. function b() {
  241. "in" != c.hoverState && d.detach()
  242. }
  243.  
  244. var c = this, d = this.tip(), e = a.Event("hide.bs." + this.type);
  245. return this.$element.trigger(e), e.isDefaultPrevented() ? void 0 : (d.removeClass("in"), a.support.transition && this.$tip.hasClass("fade") ? d.one(a.support.transition.end, b).emulateTransitionEnd(150) : b(), this.$element.trigger("hidden.bs." + this.type), this)
  246. }, b.prototype.fixTitle = function () {
  247. var a = this.$element;
  248. (a.attr("title") || "string" != typeof a.attr("data-original-title")) && a.attr("data-original-title", a.attr("title") || "").attr("title", "")
  249. }, b.prototype.hasContent = function () {
  250. return this.getTitle()
  251. }, b.prototype.getPosition = function () {
  252. var b = this.$element[0];
  253. return a.extend({}, "function" == typeof b.getBoundingClientRect ? b.getBoundingClientRect() : {
  254. width: b.offsetWidth,
  255. height: b.offsetHeight
  256. }, this.$element.offset())
  257. }, b.prototype.getCalculatedOffset = function (a, b, c, d) {
  258. return "bottom" == a ? {
  259. top: b.top + b.height,
  260. left: b.left + b.width / 2 - c / 2
  261. } : "top" == a ? {
  262. top: b.top - d,
  263. left: b.left + b.width / 2 - c / 2
  264. } : "left" == a ? {top: b.top + b.height / 2 - d / 2, left: b.left - c} : {
  265. top: b.top + b.height / 2 - d / 2,
  266. left: b.left + b.width
  267. }
  268. }, b.prototype.getTitle = function () {
  269. var a, b = this.$element, c = this.options;
  270. return a = b.attr("data-original-title") || ("function" == typeof c.title ? c.title.call(b[0]) : c.title)
  271. }, b.prototype.tip = function () {
  272. return this.$tip = this.$tip || a(this.options.template)
  273. }, b.prototype.arrow = function () {
  274. return this.$arrow = this.$arrow || this.tip().find(".tooltip-arrow")
  275. }, b.prototype.validate = function () {
  276. this.$element[0].parentNode || (this.hide(), this.$element = null, this.options = null)
  277. }, b.prototype.enable = function () {
  278. this.enabled = !0
  279. }, b.prototype.disable = function () {
  280. this.enabled = !1
  281. }, b.prototype.toggleEnabled = function () {
  282. this.enabled = !this.enabled
  283. }, b.prototype.toggle = function (b) {
  284. var c = b ? a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs." + this.type) : this;
  285. c.tip().hasClass("in") ? c.leave(c) : c.enter(c)
  286. }, b.prototype.destroy = function () {
  287. this.hide().$element.off("." + this.type).removeData("bs." + this.type)
  288. };
  289. var c = a.fn.tooltip;
  290. a.fn.tooltip = function (c) {
  291. return this.each(function () {
  292. var d = a(this), e = d.data("bs.tooltip"), f = "object" == typeof c && c;
  293. e || d.data("bs.tooltip", e = new b(this, f)), "string" == typeof c && e[c]()
  294. })
  295. }, a.fn.tooltip.Constructor = b, a.fn.tooltip.noConflict = function () {
  296. return a.fn.tooltip = c, this
  297. }
  298. }(jQuery), +function (a) {
  299. "use strict";
  300. var b = function (b) {
  301. this.element = a(b)
  302. };
  303. b.prototype.show = function () {
  304. var b = this.element, c = b.closest("ul:not(.dropdown-menu)"), d = b.data("target");
  305. if (d || (d = b.attr("href"), d = d && d.replace(/.*(?=#[^\s]*$)/, "")), !b.parent("li").hasClass("active")) {
  306. var e = c.find(".active:last a")[0], f = a.Event("show.bs.tab", {relatedTarget: e});
  307. if (b.trigger(f), !f.isDefaultPrevented()) {
  308. var g = a(d);
  309. this.activate(b.parent("li"), c), this.activate(g, g.parent(), function () {
  310. b.trigger({type: "shown.bs.tab", relatedTarget: e})
  311. })
  312. }
  313. }
  314. }, b.prototype.activate = function (b, c, d) {
  315. function e() {
  316. f.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"), b.addClass("active"), g ? (b[0].offsetWidth, b.addClass("in")) : b.removeClass("fade"), b.parent(".dropdown-menu") && b.closest("li.dropdown").addClass("active"), d && d()
  317. }
  318.  
  319. var f = c.find("> .active"), g = d && a.support.transition && f.hasClass("fade");
  320. g ? f.one(a.support.transition.end, e).emulateTransitionEnd(150) : e(), f.removeClass("in")
  321. };
  322. var c = a.fn.tab;
  323. a.fn.tab = function (c) {
  324. return this.each(function () {
  325. var d = a(this), e = d.data("bs.tab");
  326. e || d.data("bs.tab", e = new b(this)), "string" == typeof c && e[c]()
  327. })
  328. }, a.fn.tab.Constructor = b, a.fn.tab.noConflict = function () {
  329. return a.fn.tab = c, this
  330. }, a(document).on("click.bs.tab.data-api", '[data-toggle="tab"], [data-toggle="pill"]', function (b) {
  331. b.preventDefault(), a(this).tab("show")
  332. })
  333. }(jQuery), function (a) {
  334. "function" == typeof define && define.amd ? define(["jquery"], a) : a(jQuery)
  335. }(function (a) {
  336. function b(a) {
  337. return a
  338. }
  339.  
  340. function c(a) {
  341. return decodeURIComponent(a.replace(e, " "))
  342. }
  343.  
  344. function d(a) {
  345. 0 === a.indexOf('"') && (a = a.slice(1, -1).replace(/\\"/g, '"').replace(/\\\\/g, "\\"));
  346. try {
  347. return f.json ? JSON.parse(a) : a
  348. } catch (b) {
  349. }
  350. }
  351.  
  352. var e = /\+/g, f = a.cookie = function (e, g, h) {
  353. if (void 0 !== g) {
  354. if (h = a.extend({}, f.defaults, h), "number" == typeof h.expires) {
  355. var i = h.expires, j = h.expires = new Date;
  356. j.setDate(j.getDate() + i)
  357. }
  358. return g = f.json ? JSON.stringify(g) : String(g), document.cookie = [f.raw ? e : encodeURIComponent(e), "=", f.raw ? g : encodeURIComponent(g), h.expires ? "; expires=" + h.expires.toUTCString() : "", h.path ? "; path=" + h.path : "", h.domain ? "; domain=" + h.domain : "", h.secure ? "; secure" : ""].join("")
  359. }
  360. for (var k = f.raw ? b : c, l = document.cookie.split("; "), m = e ? void 0 : {}, n = 0, o = l.length; o > n; n++) {
  361. var p = l[n].split("="), q = k(p.shift()), r = k(p.join("="));
  362. if (e && e === q) {
  363. m = d(r);
  364. break
  365. }
  366. e || (m[q] = d(r))
  367. }
  368. return m
  369. };
  370. f.defaults = {}, a.removeCookie = function (b, c) {
  371. return void 0 !== a.cookie(b) ? (a.cookie(b, "", a.extend({}, c, {expires: -1})), !0) : !1
  372. }
  373. }), function (a) {
  374. a.flexslider = function (b, c) {
  375. var d = a(b);
  376. d.vars = a.extend({}, a.flexslider.defaults, c);
  377. var e, f = d.vars.namespace, g = window.navigator && window.navigator.msPointerEnabled && window.MSGesture, h = ("ontouchstart"in window || g || window.DocumentTouch && document instanceof DocumentTouch) && d.vars.touch, i = "click touchend MSPointerUp", j = "", k = "vertical" === d.vars.direction, l = d.vars.reverse, m = d.vars.itemWidth > 0, n = "fade" === d.vars.animation, o = "" !== d.vars.asNavFor, p = {}, q = !0;
  378. a.data(b, "flexslider", d), p = {
  379. init: function () {
  380. d.animating = !1, d.currentSlide = parseInt(d.vars.startAt ? d.vars.startAt : 0), isNaN(d.currentSlide) && (d.currentSlide = 0), d.animatingTo = d.currentSlide, d.atEnd = 0 === d.currentSlide || d.currentSlide === d.last, d.containerSelector = d.vars.selector.substr(0, d.vars.selector.search(" ")), d.slides = a(d.vars.selector, d), d.container = a(d.containerSelector, d), d.count = d.slides.length, d.syncExists = a(d.vars.sync).length > 0, "slide" === d.vars.animation && (d.vars.animation = "swing"), d.prop = k ? "top" : "marginLeft", d.args = {}, d.manualPause = !1, d.stopped = !1, d.started = !1, d.startTimeout = null, d.transitions = !d.vars.video && !n && d.vars.useCSS && function () {
  381. var a = document.createElement("div"), b = ["perspectiveProperty", "WebkitPerspective", "MozPerspective", "OPerspective", "msPerspective"];
  382. for (var c in b)if (void 0 !== a.style[b[c]])return d.pfx = b[c].replace("Perspective", "").toLowerCase(), d.prop = "-" + d.pfx + "-transform", !0;
  383. return !1
  384. }(), "" !== d.vars.controlsContainer && (d.controlsContainer = a(d.vars.controlsContainer).length > 0 && a(d.vars.controlsContainer)), "" !== d.vars.manualControls && (d.manualControls = a(d.vars.manualControls).length > 0 && a(d.vars.manualControls)), d.vars.randomize && (d.slides.sort(function () {
  385. return Math.round(Math.random()) - .5
  386. }), d.container.empty().append(d.slides)), d.doMath(), d.setup("init"), d.vars.controlNav && p.controlNav.setup(), d.vars.directionNav && p.directionNav.setup(), d.vars.keyboard && (1 === a(d.containerSelector).length || d.vars.multipleKeyboard) && a(document).bind("keyup", function (a) {
  387. var b = a.keyCode;
  388. if (!d.animating && (39 === b || 37 === b)) {
  389. var c = 39 === b ? d.getTarget("next") : 37 === b ? d.getTarget("prev") : !1;
  390. d.flexAnimate(c, d.vars.pauseOnAction)
  391. }
  392. }), d.vars.mousewheel && d.bind("mousewheel", function (a, b) {
  393. a.preventDefault();
  394. var c = 0 > b ? d.getTarget("next") : d.getTarget("prev");
  395. d.flexAnimate(c, d.vars.pauseOnAction)
  396. }), d.vars.pausePlay && p.pausePlay.setup(), d.vars.slideshow && d.vars.pauseInvisible && p.pauseInvisible.init(), d.vars.slideshow && (d.vars.pauseOnHover && d.hover(function () {
  397. d.manualPlay || d.manualPause || d.pause()
  398. }, function () {
  399. d.manualPause || d.manualPlay || d.stopped || d.play()
  400. }), d.vars.pauseInvisible && p.pauseInvisible.isHidden() || (d.vars.initDelay > 0 ? d.startTimeout = setTimeout(d.play, d.vars.initDelay) : d.play())), o && p.asNav.setup(), h && d.vars.touch && p.touch(), (!n || n && d.vars.smoothHeight) && a(window).bind("resize orientationchange focus", p.resize), d.find("img").attr("draggable", "false"), setTimeout(function () {
  401. d.vars.start(d)
  402. }, 200)
  403. }, asNav: {
  404. setup: function () {
  405. d.asNav = !0, d.animatingTo = Math.floor(d.currentSlide / d.move), d.currentItem = d.currentSlide, d.slides.removeClass(f + "active-slide").eq(d.currentItem).addClass(f + "active-slide"), g ? (b._slider = d, d.slides.each(function () {
  406. var b = this;
  407. b._gesture = new MSGesture, b._gesture.target = b, b.addEventListener("MSPointerDown", function (a) {
  408. a.preventDefault(), a.currentTarget._gesture && a.currentTarget._gesture.addPointer(a.pointerId)
  409. }, !1), b.addEventListener("MSGestureTap", function (b) {
  410. b.preventDefault();
  411. var c = a(this), e = c.index();
  412. a(d.vars.asNavFor).data("flexslider").animating || c.hasClass("active") || (d.direction = d.currentItem < e ? "next" : "prev", d.flexAnimate(e, d.vars.pauseOnAction, !1, !0, !0))
  413. })
  414. })) : d.slides.click(function (b) {
  415. b.preventDefault();
  416. var c = a(this), e = c.index(), g = c.offset().left - a(d).scrollLeft();
  417. 0 >= g && c.hasClass(f + "active-slide") ? d.flexAnimate(d.getTarget("prev"), !0) : a(d.vars.asNavFor).data("flexslider").animating || c.hasClass(f + "active-slide") || (d.direction = d.currentItem < e ? "next" : "prev", d.flexAnimate(e, d.vars.pauseOnAction, !1, !0, !0))
  418. })
  419. }
  420. }, controlNav: {
  421. setup: function () {
  422. d.manualControls ? p.controlNav.setupManual() : p.controlNav.setupPaging()
  423. }, setupPaging: function () {
  424. var b, c, e = "thumbnails" === d.vars.controlNav ? "control-thumbs" : "control-paging", g = 1;
  425. if (d.controlNavScaffold = a('<ol class="' + f + "control-nav " + f + e + '"></ol>'), d.pagingCount > 1)for (var h = 0; h < d.pagingCount; h++) {
  426. if (c = d.slides.eq(h), b = "thumbnails" === d.vars.controlNav ? '<img src="' + c.attr("data-thumb") + '"/>' : "<a>" + g + "</a>", "thumbnails" === d.vars.controlNav && !0 === d.vars.thumbCaptions) {
  427. var k = c.attr("data-thumbcaption");
  428. "" != k && void 0 != k && (b += '<span class="' + f + 'caption">' + k + "</span>")
  429. }
  430. d.controlNavScaffold.append("<li>" + b + "</li>"), g++
  431. }
  432. d.controlsContainer ? a(d.controlsContainer).append(d.controlNavScaffold) : d.append(d.controlNavScaffold), p.controlNav.set(), p.controlNav.active(), d.controlNavScaffold.delegate("a, img", i, function (b) {
  433. if (b.preventDefault(), "" === j || j === b.type) {
  434. var c = a(this), e = d.controlNav.index(c);
  435. c.hasClass(f + "active") || (d.direction = e > d.currentSlide ? "next" : "prev", d.flexAnimate(e, d.vars.pauseOnAction))
  436. }
  437. "" === j && (j = b.type), p.setToClearWatchedEvent()
  438. })
  439. }, setupManual: function () {
  440. d.controlNav = d.manualControls, p.controlNav.active(), d.controlNav.bind(i, function (b) {
  441. if (b.preventDefault(), "" === j || j === b.type) {
  442. var c = a(this), e = d.controlNav.index(c);
  443. c.hasClass(f + "active") || (d.direction = e > d.currentSlide ? "next" : "prev", d.flexAnimate(e, d.vars.pauseOnAction))
  444. }
  445. "" === j && (j = b.type), p.setToClearWatchedEvent()
  446. })
  447. }, set: function () {
  448. var b = "thumbnails" === d.vars.controlNav ? "img" : "a";
  449. d.controlNav = a("." + f + "control-nav li " + b, d.controlsContainer ? d.controlsContainer : d)
  450. }, active: function () {
  451. d.controlNav.removeClass(f + "active").eq(d.animatingTo).addClass(f + "active")
  452. }, update: function (b, c) {
  453. d.pagingCount > 1 && "add" === b ? d.controlNavScaffold.append(a("<li><a>" + d.count + "</a></li>")) : 1 === d.pagingCount ? d.controlNavScaffold.find("li").remove() : d.controlNav.eq(c).closest("li").remove(), p.controlNav.set(), d.pagingCount > 1 && d.pagingCount !== d.controlNav.length ? d.update(c, b) : p.controlNav.active()
  454. }
  455. }, directionNav: {
  456. setup: function () {
  457. var b = a('<ul class="' + f + 'direction-nav"><li><a class="' + f + 'prev" href="#">' + d.vars.prevText + '</a></li><li><a class="' + f + 'next" href="#">' + d.vars.nextText + "</a></li></ul>");
  458. d.controlsContainer ? (a(d.controlsContainer).append(b), d.directionNav = a("." + f + "direction-nav li a", d.controlsContainer)) : (d.append(b), d.directionNav = a("." + f + "direction-nav li a", d)), p.directionNav.update(), d.directionNav.bind(i, function (b) {
  459. b.preventDefault();
  460. var c;
  461. ("" === j || j === b.type) && (c = a(this).hasClass(f + "next") ? d.getTarget("next") : d.getTarget("prev"), d.flexAnimate(c, d.vars.pauseOnAction)), "" === j && (j = b.type), p.setToClearWatchedEvent()
  462. })
  463. }, update: function () {
  464. var a = f + "disabled";
  465. 1 === d.pagingCount ? d.directionNav.addClass(a).attr("tabindex", "-1") : d.vars.animationLoop ? d.directionNav.removeClass(a).removeAttr("tabindex") : 0 === d.animatingTo ? d.directionNav.removeClass(a).filter("." + f + "prev").addClass(a).attr("tabindex", "-1") : d.animatingTo === d.last ? d.directionNav.removeClass(a).filter("." + f + "next").addClass(a).attr("tabindex", "-1") : d.directionNav.removeClass(a).removeAttr("tabindex")
  466. }
  467. }, pausePlay: {
  468. setup: function () {
  469. var b = a('<div class="' + f + 'pauseplay"><a></a></div>');
  470. d.controlsContainer ? (d.controlsContainer.append(b), d.pausePlay = a("." + f + "pauseplay a", d.controlsContainer)) : (d.append(b), d.pausePlay = a("." + f + "pauseplay a", d)), p.pausePlay.update(d.vars.slideshow ? f + "pause" : f + "play"), d.pausePlay.bind(i, function (b) {
  471. b.preventDefault(), ("" === j || j === b.type) && (a(this).hasClass(f + "pause") ? (d.manualPause = !0, d.manualPlay = !1, d.pause()) : (d.manualPause = !1, d.manualPlay = !0, d.play())), "" === j && (j = b.type), p.setToClearWatchedEvent()
  472. })
  473. }, update: function (a) {
  474. "play" === a ? d.pausePlay.removeClass(f + "pause").addClass(f + "play").html(d.vars.playText) : d.pausePlay.removeClass(f + "play").addClass(f + "pause").html(d.vars.pauseText)
  475. }
  476. }, touch: function () {
  477. function a(a) {
  478. d.animating ? a.preventDefault() : (window.navigator.msPointerEnabled || 1 === a.touches.length) && (d.pause(), q = k ? d.h : d.w, s = Number(new Date), u = a.touches[0].pageX, v = a.touches[0].pageY, p = m && l && d.animatingTo === d.last ? 0 : m && l ? d.limit - (d.itemW + d.vars.itemMargin) * d.move * d.animatingTo : m && d.currentSlide === d.last ? d.limit : m ? (d.itemW + d.vars.itemMargin) * d.move * d.currentSlide : l ? (d.last - d.currentSlide + d.cloneOffset) * q : (d.currentSlide + d.cloneOffset) * q, j = k ? v : u, o = k ? u : v, b.addEventListener("touchmove", c, !1), b.addEventListener("touchend", e, !1))
  479. }
  480.  
  481. function c(a) {
  482. r = k ? j - a.touches[0].pageY : j - a.touches[0].pageX, t = k ? Math.abs(r) < Math.abs(a.touches[0].pageX - o) : Math.abs(r) < Math.abs(a.touches[0].pageY - o), t ? b.removeEventListener("touchmove", c, !1) : (distance = Math.abs(j - a.touches[0].pageX), a.preventDefault(), !n && d.transitions && (vars.animationLoop || (r /= 0 === d.currentSlide && 0 > r || d.currentSlide === d.last && r > 0 ? Math.abs(r) / q + 2 : 1), d.setProps(p + r, "setTouch")))
  483. }
  484.  
  485. function e() {
  486. if (b.removeEventListener("touchmove", c, !1), d.animatingTo === d.currentSlide && !t && null !== r) {
  487. var a = l ? -r : r, f = a > 0 ? d.getTarget("next") : d.getTarget("prev");
  488. d.canAdvance(f) && (Number(new Date) - s < 550 && Math.abs(a) > 50 || Math.abs(a) > q / 2) ? d.flexAnimate(f, d.vars.pauseOnAction) : n || d.flexAnimate(d.currentSlide, d.vars.pauseOnAction, !0)
  489. }
  490. b.removeEventListener("touchend", e, !1), j = null, o = null, r = null, p = null
  491. }
  492.  
  493. function f(a) {
  494. a.stopPropagation(), d.animating ? a.preventDefault() : (d.pause(), b._gesture.addPointer(a.pointerId), w = 0, q = k ? d.h : d.w, s = Number(new Date), p = m && l && d.animatingTo === d.last ? 0 : m && l ? d.limit - (d.itemW + d.vars.itemMargin) * d.move * d.animatingTo : m && d.currentSlide === d.last ? d.limit : m ? (d.itemW + d.vars.itemMargin) * d.move * d.currentSlide : l ? (d.last - d.currentSlide + d.cloneOffset) * q : (d.currentSlide + d.cloneOffset) * q)
  495. }
  496.  
  497. function h(a) {
  498. a.stopPropagation();
  499. var c = a.target._slider;
  500. if (c) {
  501. var d = -a.translationX, e = -a.translationY;
  502. return w += k ? e : d, r = w, t = k ? Math.abs(w) < Math.abs(-d) : Math.abs(w) < Math.abs(-e), a.detail === a.MSGESTURE_FLAG_INERTIA ? (setImmediate(function () {
  503. b._gesture.stop()
  504. }), void 0) : ((!t || Number(new Date) - s > 500) && (a.preventDefault(), !n && c.transitions && (c.vars.animationLoop || (r = w / (0 === c.currentSlide && 0 > w || c.currentSlide === c.last && w > 0 ? Math.abs(w) / q + 2 : 1)), c.setProps(p + r, "setTouch"))), void 0)
  505. }
  506. }
  507.  
  508. function i(a) {
  509. a.stopPropagation();
  510. var b = a.target._slider;
  511. if (b) {
  512. if (b.animatingTo === b.currentSlide && !t && null !== r) {
  513. var c = l ? -r : r, d = c > 0 ? b.getTarget("next") : b.getTarget("prev");
  514. b.canAdvance(d) && (Number(new Date) - s < 550 && Math.abs(c) > 50 || Math.abs(c) > q / 2) ? b.flexAnimate(d, b.vars.pauseOnAction) : n || b.flexAnimate(b.currentSlide, b.vars.pauseOnAction, !0)
  515. }
  516. j = null, o = null, r = null, p = null, w = 0
  517. }
  518. }
  519.  
  520. var j, o, p, q, r, s, t = !1, u = 0, v = 0, w = 0;
  521. g ? (b.style.msTouchAction = "none", b._gesture = new MSGesture, b._gesture.target = b, b.addEventListener("MSPointerDown", f, !1), b._slider = d, b.addEventListener("MSGestureChange", h, !1), b.addEventListener("MSGestureEnd", i, !1)) : b.addEventListener("touchstart", a, !1)
  522. }, resize: function () {
  523. !d.animating && d.is(":visible") && (m || d.doMath(), n ? p.smoothHeight() : m ? (d.slides.width(d.computedW), d.update(d.pagingCount), d.setProps()) : k ? (d.viewport.height(d.h), d.setProps(d.h, "setTotal")) : (d.vars.smoothHeight && p.smoothHeight(), d.newSlides.width(d.computedW), d.setProps(d.computedW, "setTotal")))
  524. }, smoothHeight: function (a) {
  525. if (!k || n) {
  526. var b = n ? d : d.viewport;
  527. a ? b.animate({height: d.slides.eq(d.animatingTo).height()}, a) : b.height(d.slides.eq(d.animatingTo).height())
  528. }
  529. }, sync: function (b) {
  530. var c = a(d.vars.sync).data("flexslider"), e = d.animatingTo;
  531. switch (b) {
  532. case"animate":
  533. c.flexAnimate(e, d.vars.pauseOnAction, !1, !0);
  534. break;
  535. case"play":
  536. c.playing || c.asNav || c.play();
  537. break;
  538. case"pause":
  539. c.pause()
  540. }
  541. }, pauseInvisible: {
  542. visProp: null, init: function () {
  543. var a = ["webkit", "moz", "ms", "o"];
  544. if ("hidden"in document)return "hidden";
  545. for (var b = 0; b < a.length; b++)a[b] + "Hidden"in document && (p.pauseInvisible.visProp = a[b] + "Hidden");
  546. if (p.pauseInvisible.visProp) {
  547. var c = p.pauseInvisible.visProp.replace(/[H|h]idden/, "") + "visibilitychange";
  548. document.addEventListener(c, function () {
  549. p.pauseInvisible.isHidden() ? d.startTimeout ? clearTimeout(d.startTimeout) : d.pause() : d.started ? d.play() : d.vars.initDelay > 0 ? setTimeout(d.play, d.vars.initDelay) : d.play()
  550. })
  551. }
  552. }, isHidden: function () {
  553. return document[p.pauseInvisible.visProp] || !1
  554. }
  555. }, setToClearWatchedEvent: function () {
  556. clearTimeout(e), e = setTimeout(function () {
  557. j = ""
  558. }, 3e3)
  559. }
  560. }, d.flexAnimate = function (b, c, e, g, i) {
  561. if (d.vars.animationLoop || b === d.currentSlide || (d.direction = b > d.currentSlide ? "next" : "prev"), o && 1 === d.pagingCount && (d.direction = d.currentItem < b ? "next" : "prev"), !d.animating && (d.canAdvance(b, i) || e) && d.is(":visible")) {
  562. if (o && g) {
  563. var j = a(d.vars.asNavFor).data("flexslider");
  564. if (d.atEnd = 0 === b || b === d.count - 1, j.flexAnimate(b, !0, !1, !0, i), d.direction = d.currentItem < b ? "next" : "prev", j.direction = d.direction, Math.ceil((b + 1) / d.visible) - 1 === d.currentSlide || 0 === b)return d.currentItem = b, d.slides.removeClass(f + "active-slide").eq(b).addClass(f + "active-slide"), !1;
  565. d.currentItem = b, d.slides.removeClass(f + "active-slide").eq(b).addClass(f + "active-slide"), b = Math.floor(b / d.visible)
  566. }
  567. if (d.animating = !0, d.animatingTo = b, c && d.pause(), d.vars.before(d), d.syncExists && !i && p.sync("animate"), d.vars.controlNav && p.controlNav.active(), m || d.slides.removeClass(f + "active-slide").eq(b).addClass(f + "active-slide"), d.atEnd = 0 === b || b === d.last, d.vars.directionNav && p.directionNav.update(), b === d.last && (d.vars.end(d), d.vars.animationLoop || d.pause()), n)h ? (d.slides.eq(d.currentSlide).css({
  568. opacity: 0,
  569. zIndex: 1
  570. }), d.slides.eq(b).css({
  571. opacity: 1,
  572. zIndex: 2
  573. }), d.wrapup(t)) : (d.slides.eq(d.currentSlide).css({zIndex: 1}).animate({opacity: 0}, d.vars.animationSpeed, d.vars.easing), d.slides.eq(b).css({zIndex: 2}).animate({opacity: 1}, d.vars.animationSpeed, d.vars.easing, d.wrapup)); else {
  574. var q, r, s, t = k ? d.slides.filter(":first").height() : d.computedW;
  575. m ? (q = d.vars.itemMargin, s = (d.itemW + q) * d.move * d.animatingTo, r = s > d.limit && 1 !== d.visible ? d.limit : s) : r = 0 === d.currentSlide && b === d.count - 1 && d.vars.animationLoop && "next" !== d.direction ? l ? (d.count + d.cloneOffset) * t : 0 : d.currentSlide === d.last && 0 === b && d.vars.animationLoop && "prev" !== d.direction ? l ? 0 : (d.count + 1) * t : l ? (d.count - 1 - b + d.cloneOffset) * t : (b + d.cloneOffset) * t, d.setProps(r, "", d.vars.animationSpeed), d.transitions ? (d.vars.animationLoop && d.atEnd || (d.animating = !1, d.currentSlide = d.animatingTo), d.container.unbind("webkitTransitionEnd transitionend"), d.container.bind("webkitTransitionEnd transitionend", function () {
  576. d.wrapup(t)
  577. })) : d.container.animate(d.args, d.vars.animationSpeed, d.vars.easing, function () {
  578. d.wrapup(t)
  579. })
  580. }
  581. d.vars.smoothHeight && p.smoothHeight(d.vars.animationSpeed)
  582. }
  583. }, d.wrapup = function (a) {
  584. n || m || (0 === d.currentSlide && d.animatingTo === d.last && d.vars.animationLoop ? d.setProps(a, "jumpEnd") : d.currentSlide === d.last && 0 === d.animatingTo && d.vars.animationLoop && d.setProps(a, "jumpStart")), d.animating = !1, d.currentSlide = d.animatingTo, d.vars.after(d)
  585. }, d.animateSlides = function () {
  586. !d.animating && q && d.flexAnimate(d.getTarget("next"))
  587. }, d.pause = function () {
  588. clearInterval(d.animatedSlides), d.animatedSlides = null, d.playing = !1, d.vars.pausePlay && p.pausePlay.update("play"), d.syncExists && p.sync("pause")
  589. }, d.play = function () {
  590. d.playing && clearInterval(d.animatedSlides), d.animatedSlides = d.animatedSlides || setInterval(d.animateSlides, d.vars.slideshowSpeed), d.started = d.playing = !0, d.vars.pausePlay && p.pausePlay.update("pause"), d.syncExists && p.sync("play")
  591. }, d.stop = function () {
  592. d.pause(), d.stopped = !0
  593. }, d.canAdvance = function (a, b) {
  594. var c = o ? d.pagingCount - 1 : d.last;
  595. return b ? !0 : o && d.currentItem === d.count - 1 && 0 === a && "prev" === d.direction ? !0 : o && 0 === d.currentItem && a === d.pagingCount - 1 && "next" !== d.direction ? !1 : a !== d.currentSlide || o ? d.vars.animationLoop ? !0 : d.atEnd && 0 === d.currentSlide && a === c && "next" !== d.direction ? !1 : d.atEnd && d.currentSlide === c && 0 === a && "next" === d.direction ? !1 : !0 : !1
  596. }, d.getTarget = function (a) {
  597. return d.direction = a, "next" === a ? d.currentSlide === d.last ? 0 : d.currentSlide + 1 : 0 === d.currentSlide ? d.last : d.currentSlide - 1
  598. }, d.setProps = function (a, b, c) {
  599. var e = function () {
  600. var c = a ? a : (d.itemW + d.vars.itemMargin) * d.move * d.animatingTo, e = function () {
  601. if (m)return "setTouch" === b ? a : l && d.animatingTo === d.last ? 0 : l ? d.limit - (d.itemW + d.vars.itemMargin) * d.move * d.animatingTo : d.animatingTo === d.last ? d.limit : c;
  602. switch (b) {
  603. case"setTotal":
  604. return l ? (d.count - 1 - d.currentSlide + d.cloneOffset) * a : (d.currentSlide + d.cloneOffset) * a;
  605. case"setTouch":
  606. return l ? a : a;
  607. case"jumpEnd":
  608. return l ? a : d.count * a;
  609. case"jumpStart":
  610. return l ? d.count * a : a;
  611. default:
  612. return a
  613. }
  614. }();
  615. return -1 * e + "px"
  616. }();
  617. d.transitions && (e = k ? "translate3d(0," + e + ",0)" : "translate3d(" + e + ",0,0)", c = void 0 !== c ? c / 1e3 + "s" : "0s", d.container.css("-" + d.pfx + "-transition-duration", c)), d.args[d.prop] = e, (d.transitions || void 0 === c) && d.container.css(d.args)
  618. }, d.setup = function (b) {
  619. if (n)d.slides.css({
  620. width: "100%",
  621. "float": "left",
  622. marginRight: "-100%",
  623. position: "relative"
  624. }), "init" === b && (h ? d.slides.css({
  625. opacity: 0,
  626. display: "block",
  627. webkitTransition: "opacity " + d.vars.animationSpeed / 1e3 + "s ease",
  628. zIndex: 1
  629. }).eq(d.currentSlide).css({opacity: 1, zIndex: 2}) : d.slides.css({
  630. opacity: 0,
  631. display: "block",
  632. zIndex: 1
  633. }).eq(d.currentSlide).css({zIndex: 2}).animate({opacity: 1}, d.vars.animationSpeed, d.vars.easing)), d.vars.smoothHeight && p.smoothHeight(); else {
  634. var c, e;
  635. "init" === b && (d.viewport = a('<div class="' + f + 'viewport"></div>').css({
  636. overflow: "hidden",
  637. position: "relative"
  638. }).appendTo(d).append(d.container), d.cloneCount = 0, d.cloneOffset = 0, l && (e = a.makeArray(d.slides).reverse(), d.slides = a(e), d.container.empty().append(d.slides))), d.vars.animationLoop && !m && (d.cloneCount = 2, d.cloneOffset = 1, "init" !== b && d.container.find(".clone").remove(), d.container.append(d.slides.first().clone().addClass("clone").attr("aria-hidden", "true")).prepend(d.slides.last().clone().addClass("clone").attr("aria-hidden", "true"))), d.newSlides = a(d.vars.selector, d), c = l ? d.count - 1 - d.currentSlide + d.cloneOffset : d.currentSlide + d.cloneOffset, k && !m ? (d.container.height(200 * (d.count + d.cloneCount) + "%").css("position", "absolute").width("100%"), setTimeout(function () {
  639. d.newSlides.css({display: "block"}), d.doMath(), d.viewport.height(d.h), d.setProps(c * d.h, "init")
  640. }, "init" === b ? 100 : 0)) : (d.container.width(200 * (d.count + d.cloneCount) + "%"), d.setProps(c * d.computedW, "init"), setTimeout(function () {
  641. d.doMath(), d.newSlides.css({
  642. width: d.computedW,
  643. "float": "left",
  644. display: "block"
  645. }), d.vars.smoothHeight && p.smoothHeight()
  646. }, "init" === b ? 100 : 0))
  647. }
  648. m || d.slides.removeClass(f + "active-slide").eq(d.currentSlide).addClass(f + "active-slide")
  649. }, d.doMath = function () {
  650. var a = d.slides.first(), b = d.vars.itemMargin, c = d.vars.minItems, e = d.vars.maxItems;
  651. d.w = void 0 === d.viewport ? d.width() : d.viewport.width(), d.h = a.height(), d.boxPadding = a.outerWidth() - a.width(), m ? (d.itemT = d.vars.itemWidth + b, d.minW = c ? c * d.itemT : d.w, d.maxW = e ? e * d.itemT - b : d.w, d.itemW = d.minW > d.w ? (d.w - b * (c - 1)) / c : d.maxW < d.w ? (d.w - b * (e - 1)) / e : d.vars.itemWidth > d.w ? d.w : d.vars.itemWidth, d.visible = Math.floor(d.w / d.itemW), d.move = d.vars.move > 0 && d.vars.move < d.visible ? d.vars.move : d.visible, d.pagingCount = Math.ceil((d.count - d.visible) / d.move + 1), d.last = d.pagingCount - 1, d.limit = 1 === d.pagingCount ? 0 : d.vars.itemWidth > d.w ? d.itemW * (d.count - 1) + b * (d.count - 1) : (d.itemW + b) * d.count - d.w - b) : (d.itemW = d.w, d.pagingCount = d.count, d.last = d.count - 1), d.computedW = d.itemW - d.boxPadding
  652. }, d.update = function (a, b) {
  653. d.doMath(), m || (a < d.currentSlide ? d.currentSlide += 1 : a <= d.currentSlide && 0 !== a && (d.currentSlide -= 1), d.animatingTo = d.currentSlide), d.vars.controlNav && !d.manualControls && ("add" === b && !m || d.pagingCount > d.controlNav.length ? p.controlNav.update("add") : ("remove" === b && !m || d.pagingCount < d.controlNav.length) && (m && d.currentSlide > d.last && (d.currentSlide -= 1, d.animatingTo -= 1), p.controlNav.update("remove", d.last))), d.vars.directionNav && p.directionNav.update()
  654. }, d.addSlide = function (b, c) {
  655. var e = a(b);
  656. d.count += 1, d.last = d.count - 1, k && l ? void 0 !== c ? d.slides.eq(d.count - c).after(e) : d.container.prepend(e) : void 0 !== c ? d.slides.eq(c).before(e) : d.container.append(e), d.update(c, "add"), d.slides = a(d.vars.selector + ":not(.clone)", d), d.setup(), d.vars.added(d)
  657. }, d.removeSlide = function (b) {
  658. var c = isNaN(b) ? d.slides.index(a(b)) : b;
  659. d.count -= 1, d.last = d.count - 1, isNaN(b) ? a(b, d.slides).remove() : k && l ? d.slides.eq(d.last).remove() : d.slides.eq(b).remove(), d.doMath(), d.update(c, "remove"), d.slides = a(d.vars.selector + ":not(.clone)", d), d.setup(), d.vars.removed(d)
  660. }, p.init()
  661. }, a(window).blur(function () {
  662. focused = !1
  663. }).focus(function () {
  664. focused = !0
  665. }), a.flexslider.defaults = {
  666. namespace: "flex-",
  667. selector: ".slides > li",
  668. animation: "fade",
  669. easing: "swing",
  670. direction: "horizontal",
  671. reverse: !1,
  672. animationLoop: !0,
  673. smoothHeight: !1,
  674. startAt: 0,
  675. slideshow: !0,
  676. slideshowSpeed: 7e3,
  677. animationSpeed: 600,
  678. initDelay: 0,
  679. randomize: !1,
  680. thumbCaptions: !1,
  681. pauseOnAction: !0,
  682. pauseOnHover: !1,
  683. pauseInvisible: !0,
  684. useCSS: !0,
  685. touch: !0,
  686. video: !1,
  687. controlNav: !0,
  688. directionNav: !0,
  689. prevText: "Previous",
  690. nextText: "Next",
  691. keyboard: !0,
  692. multipleKeyboard: !1,
  693. mousewheel: !1,
  694. pausePlay: !1,
  695. pauseText: "Pause",
  696. playText: "Play",
  697. controlsContainer: "",
  698. manualControls: "",
  699. sync: "",
  700. asNavFor: "",
  701. itemWidth: 0,
  702. itemMargin: 0,
  703. minItems: 1,
  704. maxItems: 0,
  705. move: 0,
  706. allowOneSlide: !0,
  707. start: function () {
  708. },
  709. before: function () {
  710. },
  711. after: function () {
  712. },
  713. end: function () {
  714. },
  715. added: function () {
  716. },
  717. removed: function () {
  718. }
  719. }, a.fn.flexslider = function (b) {
  720. if (void 0 === b && (b = {}), "object" == typeof b)return this.each(function () {
  721. var c = a(this), d = b.selector ? b.selector : ".slides > li", e = c.find(d);
  722. 1 === e.length && b.allowOneSlide === !0 || 0 === e.length ? (e.fadeIn(400), b.start && b.start(c)) : void 0 === c.data("flexslider") && new a.flexslider(this, b)
  723. });
  724. var c = a(this).data("flexslider");
  725. switch (b) {
  726. case"play":
  727. c.play();
  728. break;
  729. case"pause":
  730. c.pause();
  731. break;
  732. case"stop":
  733. c.stop();
  734. break;
  735. case"next":
  736. c.flexAnimate(c.getTarget("next"), !0);
  737. break;
  738. case"prev":
  739. case"previous":
  740. c.flexAnimate(c.getTarget("prev"), !0);
  741. break;
  742. default:
  743. "number" == typeof b && c.flexAnimate(b, !0)
  744. }
  745. }
  746. }(jQuery), new function (a) {
  747. a.fn.placeholder = function (b) {
  748. b = b || {};
  749. var c = b.dataKey || "placeholderValue", d = b.attr || "placeholder", e = b.className || "placeholder", f = b.values || [], g = b.blockSubmit || !1, h = b.blankSubmit || !1, i = b.onSubmit || !1, j = b.value || "", k = b.cursor_position || 0;
  750. return this.filter(":input").each(function (b) {
  751. a.data(this, c, f[b] || a(this).attr(d))
  752. }).each(function () {
  753. "" === a.trim(a(this).val()) && a(this).addClass(e).val(a.data(this, c))
  754. }).focus(function () {
  755. a.trim(a(this).val()) === a.data(this, c) && a(this).removeClass(e).val(j), a.fn.setCursorPosition && a(this).setCursorPosition(k)
  756. }).blur(function () {
  757. a.trim(a(this).val()) === j && a(this).addClass(e).val(a.data(this, c))
  758. }).each(function (b, d) {
  759. g ? new function (b) {
  760. a(b.form).submit(function () {
  761. return a.trim(a(b).val()) != a.data(b, c)
  762. })
  763. }(d) : h ? new function (b) {
  764. a(b.form).submit(function () {
  765. return a.trim(a(b).val()) == a.data(b, c) && a(b).removeClass(e).val(""), !0
  766. })
  767. }(d) : i && new function (b) {
  768. a(b.form).submit(i)
  769. }(d)
  770. })
  771. }
  772. }(jQuery), function (a) {
  773. var b = function () {
  774. a(".gform_wrapper .gplaceholder").find("input, textarea").filter(function () {
  775. a(this);
  776. if ("INPUT" == this.nodeName) {
  777. var b = this.type;
  778. return !("hidden" == b || "file" == b || "radio" == b || "checkbox" == b)
  779. }
  780. return !0
  781. }).each(function () {
  782. var b = a(this), c = this.id, d = a("label[for=" + c + "]").hide(), e = d.last().text();
  783. e.length > 0 && "*" == e[e.length - 1] && (e = e.substring(0, e.length - 1) + "*"), b[0].setAttribute("placeholder", e)
  784. });
  785. var b = !("placeholder"in document.createElement("input"));
  786. b && a("input[placeholder], textarea[placeholder]").placeholder({blankSubmit: !0})
  787. };
  788. a(document).ready(function () {
  789. b(), a(document).bind("gform_page_loaded", b)
  790. })
  791. }(jQuery), function (a) {
  792. var b, c, d, e, f, g, h, i = "Close", j = "BeforeClose", k = "AfterClose", l = "BeforeAppend", m = "MarkupParse", n = "Open", o = "Change", p = "mfp", q = "." + p, r = "mfp-ready", s = "mfp-removing", t = "mfp-prevent-close", u = function () {
  793. }, v = !!window.jQuery, w = a(window), x = function (a, c) {
  794. b.ev.on(p + a + q, c)
  795. }, y = function (b, c, d, e) {
  796. var f = document.createElement("div");
  797. return f.className = "mfp-" + b, d && (f.innerHTML = d), e ? c && c.appendChild(f) : (f = a(f), c && f.appendTo(c)), f
  798. }, z = function (c, d) {
  799. b.ev.triggerHandler(p + 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]))
  800. }, A = function () {
  801. (b.st.focus ? b.content.find(b.st.focus).eq(0) : b.wrap).focus()
  802. }, B = function (c) {
  803. return c === h && b.currTemplate.closeBtn || (b.currTemplate.closeBtn = a(b.st.closeMarkup.replace("%title%", b.st.tClose)), h = c), b.currTemplate.closeBtn
  804. }, C = function () {
  805. a.magnificPopup.instance || (b = new u, b.init(), a.magnificPopup.instance = b)
  806. }, D = function (c) {
  807. if (!a(c).hasClass(t)) {
  808. var d = b.st.closeOnContentClick, e = b.st.closeOnBgClick;
  809. if (d && e)return !0;
  810. if (!b.content || a(c).hasClass("mfp-close") || b.preloader && c === b.preloader[0])return !0;
  811. if (c === b.content[0] || a.contains(b.content[0], c)) {
  812. if (d)return !0
  813. } else if (e && a.contains(document, c))return !0;
  814. return !1
  815. }
  816. }, E = function () {
  817. var a = document.createElement("p").style, b = ["ms", "O", "Moz", "Webkit"];
  818. if (void 0 !== a.transition)return !0;
  819. for (; b.length;)if (b.pop() + "Transition"in a)return !0;
  820. return !1
  821. };
  822. u.prototype = {
  823. constructor: u, init: function () {
  824. var c = navigator.appVersion;
  825. 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 = E(), b.probablyMobile = b.isAndroid || b.isIOS || /(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent), d = a(document.body), e = a(document), b.popupsCache = {}
  826. }, open: function (c) {
  827. var d;
  828. if (c.isObj === !1) {
  829. b.items = c.items.toArray(), b.index = 0;
  830. var f, h = c.items;
  831. for (d = 0; d < h.length; d++)if (f = h[d], f.parsed && (f = f.el[0]), f === c.el[0]) {
  832. b.index = d;
  833. break
  834. }
  835. } else b.items = a.isArray(c.items) ? c.items : [c.items], b.index = c.index || 0;
  836. if (b.isOpen)return b.updateItemHTML(), void 0;
  837. b.types = [], g = "", b.ev = c.mainEl && c.mainEl.length ? c.mainEl.eq(0) : e, 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 = y("bg").on("click" + q, function () {
  838. b.close()
  839. }), b.wrap = y("wrap").attr("tabindex", -1).on("click" + q, function (a) {
  840. D(a.target) && b.close()
  841. }), b.container = y("container", b.wrap)), b.contentContainer = y("content"), b.st.preloader && (b.preloader = y("preloader", b.container, b.st.tLoading));
  842. var i = a.magnificPopup.modules;
  843. for (d = 0; d < i.length; d++) {
  844. var j = i[d];
  845. j = j.charAt(0).toUpperCase() + j.slice(1), b["init" + j].call(b)
  846. }
  847. z("BeforeOpen"), b.st.showCloseBtn && (b.st.closeBtnInside ? (x(m, function (a, b, c, d) {
  848. c.close_replaceWith = B(d.type)
  849. }), g += " mfp-close-btn-in") : b.wrap.append(B())), b.st.alignTop && (g += " mfp-align-top"), b.fixedContentPos ? b.wrap.css({
  850. overflow: b.st.overflowY,
  851. overflowX: "hidden",
  852. overflowY: b.st.overflowY
  853. }) : b.wrap.css({
  854. top: w.scrollTop(),
  855. position: "absolute"
  856. }), (b.st.fixedBgPos === !1 || "auto" === b.st.fixedBgPos && !b.fixedContentPos) && b.bgOverlay.css({
  857. height: e.height(),
  858. position: "absolute"
  859. }), b.st.enableEscapeKey && e.on("keyup" + q, function (a) {
  860. 27 === a.keyCode && b.close()
  861. }), w.on("resize" + q, function () {
  862. b.updateSize()
  863. }), b.st.closeOnContentClick || (g += " mfp-auto-cursor"), g && b.wrap.addClass(g);
  864. var k = b.wH = w.height(), l = {};
  865. if (b.fixedContentPos && b._hasScrollBar(k)) {
  866. var o = b._getScrollbarSize();
  867. o && (l.paddingRight = o)
  868. }
  869. b.fixedContentPos && (b.isIE7 ? a("body, html").css("overflow", "hidden") : l.overflow = "hidden");
  870. var p = b.st.mainClass;
  871. return b.isIE7 && (p += " mfp-ie7"), p && b._addClassToMFP(p), b.updateItemHTML(), z("BuildControls"), a("html").css(l), b.bgOverlay.add(b.wrap).prependTo(document.body), b._lastFocusedEl = document.activeElement, setTimeout(function () {
  872. b.content ? (b._addClassToMFP(r), A()) : b.bgOverlay.addClass(r), e.on("focusin" + q, function (c) {
  873. return c.target === b.wrap[0] || a.contains(b.wrap[0], c.target) ? void 0 : (A(), !1)
  874. })
  875. }, 16), b.isOpen = !0, b.updateSize(k), z(n), c
  876. }, close: function () {
  877. b.isOpen && (z(j), b.isOpen = !1, b.st.removalDelay && !b.isLowIE && b.supportsTransition ? (b._addClassToMFP(s), setTimeout(function () {
  878. b._close()
  879. }, b.st.removalDelay)) : b._close())
  880. }, _close: function () {
  881. z(i);
  882. var c = s + " " + r + " ";
  883. if (b.bgOverlay.detach(), b.wrap.detach(), b.container.empty(), b.st.mainClass && (c += b.st.mainClass + " "), b._removeClassFromMFP(c), b.fixedContentPos) {
  884. var d = {paddingRight: ""};
  885. b.isIE7 ? a("body, html").css("overflow", "") : d.overflow = "", a("html").css(d)
  886. }
  887. e.off("keyup" + q + " focusin" + q), b.ev.off(q), 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._lastFocusedEl && a(b._lastFocusedEl).focus(), b.currItem = null, b.content = null, b.currTemplate = null, b.prevHeight = 0, z(k)
  888. }, updateSize: function (a) {
  889. if (b.isIOS) {
  890. var c = document.documentElement.clientWidth / window.innerWidth, d = window.innerHeight * c;
  891. b.wrap.css("height", d), b.wH = d
  892. } else b.wH = a || w.height();
  893. b.fixedContentPos || b.wrap.css("height", b.wH), z("Resize")
  894. }, updateItemHTML: function () {
  895. var c = b.items[b.index];
  896. b.contentContainer.detach(), b.content && b.content.detach(), c.parsed || (c = b.parseEl(b.index));
  897. var d = c.type;
  898. if (z("BeforeChange", [b.currItem ? b.currItem.type : "", d]), b.currItem = c, !b.currTemplate[d]) {
  899. var e = b.st[d] ? b.st[d].markup : !1;
  900. z("FirstMarkupParse", e), b.currTemplate[d] = e ? a(e) : !0
  901. }
  902. f && f !== c.type && b.container.removeClass("mfp-" + f + "-holder");
  903. var g = b["get" + d.charAt(0).toUpperCase() + d.slice(1)](c, b.currTemplate[d]);
  904. b.appendContent(g, d), c.preloaded = !0, z(o, c), f = c.type, b.container.prepend(b.contentContainer), z("AfterChange")
  905. }, appendContent: function (a, c) {
  906. b.content = a, a ? b.st.showCloseBtn && b.st.closeBtnInside && b.currTemplate[c] === !0 ? b.content.find(".mfp-close").length || b.content.append(B()) : b.content = a : b.content = "", z(l), b.container.addClass("mfp-" + c + "-holder"), b.contentContainer.append(b.content)
  907. }, parseEl: function (c) {
  908. var d = b.items[c], e = d.type;
  909. if (d = d.tagName ? {el: a(d)} : {data: d, src: d.src}, d.el) {
  910. for (var f = b.types, g = 0; g < f.length; g++)if (d.el.hasClass("mfp-" + f[g])) {
  911. e = f[g];
  912. break
  913. }
  914. d.src = d.el.attr("data-mfp-src"), d.src || (d.src = d.el.attr("href"))
  915. }
  916. return d.type = e || b.st.type || "inline", d.index = c, d.parsed = !0, b.items[c] = d, z("ElementParse", d), b.items[c]
  917. }, addGroup: function (a, c) {
  918. var d = function (d) {
  919. d.mfpEl = this, b._openClick(d, a, c)
  920. };
  921. c || (c = {});
  922. var e = "click.magnificPopup";
  923. 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)))
  924. }, _openClick: function (c, d, e) {
  925. var f = void 0 !== e.midClick ? e.midClick : a.magnificPopup.defaults.midClick;
  926. if (f || 2 !== c.which && !c.ctrlKey && !c.metaKey) {
  927. var g = void 0 !== e.disableOn ? e.disableOn : a.magnificPopup.defaults.disableOn;
  928. if (g)if (a.isFunction(g)) {
  929. if (!g.call(b))return !0
  930. } else if (w.width() < g)return !0;
  931. c.type && (c.preventDefault(), b.isOpen && c.stopPropagation()), e.el = a(c.mfpEl), e.delegate && (e.items = d.find(e.delegate)), b.open(e)
  932. }
  933. }, updateStatus: function (a, d) {
  934. if (b.preloader) {
  935. c !== a && b.container.removeClass("mfp-s-" + c), d || "loading" !== a || (d = b.st.tLoading);
  936. var e = {status: a, text: d};
  937. z("UpdateStatus", e), a = e.status, d = e.text, b.preloader.html(d), b.preloader.find("a").on("click", function (a) {
  938. a.stopImmediatePropagation()
  939. }), b.container.addClass("mfp-s-" + a), c = a
  940. }
  941. }, _addClassToMFP: function (a) {
  942. b.bgOverlay.addClass(a), b.wrap.addClass(a)
  943. }, _removeClassFromMFP: function (a) {
  944. this.bgOverlay.removeClass(a), b.wrap.removeClass(a)
  945. }, _hasScrollBar: function (a) {
  946. return (b.isIE7 ? e.height() : document.body.scrollHeight) > (a || w.height())
  947. }, _parseMarkup: function (b, c, d) {
  948. var e;
  949. d.data && (c = a.extend(d.data, c)), z(m, [b, c, d]), a.each(c, function (a, c) {
  950. if (void 0 === c || c === !1)return !0;
  951. if (e = a.split("_"), e.length > 1) {
  952. var d = b.find(q + "-" + e[0]);
  953. if (d.length > 0) {
  954. var f = e[1];
  955. "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)
  956. }
  957. } else b.find(q + "-" + a).html(c)
  958. })
  959. }, _getScrollbarSize: function () {
  960. if (void 0 === b.scrollbarSize) {
  961. var a = document.createElement("div");
  962. a.id = "mfp-sbm", 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)
  963. }
  964. return b.scrollbarSize
  965. }
  966. }, a.magnificPopup = {
  967. instance: null,
  968. proto: u.prototype,
  969. modules: [],
  970. open: function (b, c) {
  971. return C(), b = b ? a.extend(!0, {}, b) : {}, b.isObj = !0, b.index = c || 0, this.instance.open(b)
  972. },
  973. close: function () {
  974. return a.magnificPopup.instance && a.magnificPopup.instance.close()
  975. },
  976. registerModule: function (b, c) {
  977. c.options && (a.magnificPopup.defaults[b] = c.options), a.extend(this.proto, c.proto), this.modules.push(b)
  978. },
  979. defaults: {
  980. disableOn: 0,
  981. key: null,
  982. midClick: !1,
  983. mainClass: "",
  984. preloader: !0,
  985. focus: "",
  986. closeOnContentClick: !1,
  987. closeOnBgClick: !0,
  988. closeBtnInside: !0,
  989. showCloseBtn: !0,
  990. enableEscapeKey: !0,
  991. modal: !1,
  992. alignTop: !1,
  993. removalDelay: 0,
  994. fixedContentPos: "auto",
  995. fixedBgPos: "auto",
  996. overflowY: "auto",
  997. closeMarkup: '<button title="%title%" type="button" class="mfp-close">&times;</button>',
  998. tClose: "Close (Esc)",
  999. tLoading: "Loading..."
  1000. }
  1001. }, a.fn.magnificPopup = function (c) {
  1002. C();
  1003. var d = a(this);
  1004. if ("string" == typeof c)if ("open" === c) {
  1005. var e, f = v ? d.data("magnificPopup") : d[0].magnificPopup, g = parseInt(arguments[1], 10) || 0;
  1006. f.items ? e = f.items[g] : (e = d, f.delegate && (e = e.find(f.delegate)), e = e.eq(g)), b._openClick({mfpEl: e}, d, f)
  1007. } else b.isOpen && b[c].apply(b, Array.prototype.slice.call(arguments, 1)); else c = a.extend(!0, {}, c), v ? d.data("magnificPopup", c) : d[0].magnificPopup = c, b.addGroup(d, c);
  1008. return d
  1009. };
  1010. var F, G, H, I = "inline", J = function () {
  1011. H && (G.after(H.addClass(F)).detach(), H = null)
  1012. };
  1013. a.magnificPopup.registerModule(I, {
  1014. options: {hiddenClass: "hide", markup: "", tNotFound: "Content not found"},
  1015. proto: {
  1016. initInline: function () {
  1017. b.types.push(I), x(i + "." + I, function () {
  1018. J()
  1019. })
  1020. }, getInline: function (c, d) {
  1021. if (J(), c.src) {
  1022. var e = b.st.inline, f = a(c.src);
  1023. if (f.length) {
  1024. var g = f[0].parentNode;
  1025. g && g.tagName && (G || (F = e.hiddenClass, G = y(F), F = "mfp-" + F), H = f.after(G).detach().removeClass(F)), b.updateStatus("ready")
  1026. } else b.updateStatus("error", e.tNotFound), f = a("<div>");
  1027. return c.inlineElement = f, f
  1028. }
  1029. return b.updateStatus("ready"), b._parseMarkup(d, {}, c), d
  1030. }
  1031. }
  1032. });
  1033. var K, L = "ajax", M = function () {
  1034. K && d.removeClass(K)
  1035. }, N = function () {
  1036. M(), b.req && b.req.abort()
  1037. };
  1038. a.magnificPopup.registerModule(L, {
  1039. options: {
  1040. settings: null,
  1041. cursor: "mfp-ajax-cur",
  1042. tError: '<a href="%url%">The content</a> could not be loaded.'
  1043. }, proto: {
  1044. initAjax: function () {
  1045. b.types.push(L), K = b.st.ajax.cursor, x(i + "." + L, N), x("BeforeChange." + L, N)
  1046. }, getAjax: function (c) {
  1047. K && d.addClass(K), b.updateStatus("loading");
  1048. var e = a.extend({
  1049. url: c.src, success: function (d, e, f) {
  1050. var g = {data: d, xhr: f};
  1051. z("ParseAjax", g), b.appendContent(a(g.data), L), c.finished = !0, M(), A(), setTimeout(function () {
  1052. b.wrap.addClass(r)
  1053. }, 16), b.updateStatus("ready"), z("AjaxContentAdded")
  1054. }, error: function () {
  1055. M(), c.finished = c.loadError = !0, b.updateStatus("error", b.st.ajax.tError.replace("%url%", c.src))
  1056. }
  1057. }, b.st.ajax.settings);
  1058. return b.req = a.ajax(e), ""
  1059. }
  1060. }
  1061. });
  1062. var O, P = function (c) {
  1063. if (c.data && void 0 !== c.data.title)return c.data.title;
  1064. var d = b.st.image.titleSrc;
  1065. if (d) {
  1066. if (a.isFunction(d))return d.call(b, c);
  1067. if (c.el)return c.el.attr(d) || ""
  1068. }
  1069. return ""
  1070. };
  1071. a.magnificPopup.registerModule("image", {
  1072. options: {
  1073. markup: '<div class="mfp-figure"><div class="mfp-close"></div><div class="mfp-img"></div><div class="mfp-bottom-bar"><div class="mfp-title"></div><div class="mfp-counter"></div></div></div>',
  1074. cursor: "mfp-zoom-out-cur",
  1075. titleSrc: "title",
  1076. verticalFit: !0,
  1077. tError: '<a href="%url%">The image</a> could not be loaded.'
  1078. }, proto: {
  1079. initImage: function () {
  1080. var a = b.st.image, c = ".image";
  1081. b.types.push("image"), x(n + c, function () {
  1082. "image" === b.currItem.type && a.cursor && d.addClass(a.cursor)
  1083. }), x(i + c, function () {
  1084. a.cursor && d.removeClass(a.cursor), w.off("resize" + q)
  1085. }), x("Resize" + c, b.resizeImage), b.isLowIE && x("AfterChange", b.resizeImage)
  1086. }, resizeImage: function () {
  1087. var a = b.currItem;
  1088. if (a && a.img && b.st.image.verticalFit) {
  1089. var c = 0;
  1090. 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)
  1091. }
  1092. }, _onImageHasSize: function (a) {
  1093. a.img && (a.hasSize = !0, O && clearInterval(O), a.isCheckingImgSize = !1, z("ImageHasSize", a), a.imgHidden && (b.content && b.content.removeClass("mfp-loading"), a.imgHidden = !1))
  1094. }, findImageSize: function (a) {
  1095. var c = 0, d = a.img[0], e = function (f) {
  1096. O && clearInterval(O), O = setInterval(function () {
  1097. return d.naturalWidth > 0 ? (b._onImageHasSize(a), void 0) : (c > 200 && clearInterval(O), c++, 3 === c ? e(10) : 40 === c ? e(50) : 100 === c && e(500), void 0)
  1098. }, f)
  1099. };
  1100. e(1)
  1101. }, getImage: function (c, d) {
  1102. var e = 0, f = function () {
  1103. c && (c.img[0].complete ? (c.img.off(".mfploader"), c === b.currItem && (b._onImageHasSize(c), b.updateStatus("ready")), c.hasSize = !0, c.loaded = !0, z("ImageLoadComplete")) : (e++, 200 > e ? setTimeout(f, 100) : g()))
  1104. }, g = function () {
  1105. 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)
  1106. }, h = b.st.image, i = d.find(".mfp-img");
  1107. if (i.length) {
  1108. var j = document.createElement("img");
  1109. j.className = "mfp-img", c.img = a(j).on("load.mfploader", f).on("error.mfploader", g), j.src = c.src, i.is("img") && (c.img = c.img.clone()), c.img[0].naturalWidth > 0 && (c.hasSize = !0)
  1110. }
  1111. return b._parseMarkup(d, {
  1112. title: P(c),
  1113. img_replaceWith: c.img
  1114. }, c), b.resizeImage(), c.hasSize ? (O && clearInterval(O), 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)
  1115. }
  1116. }
  1117. });
  1118. var Q, R = function () {
  1119. return void 0 === Q && (Q = void 0 !== document.createElement("p").style.MozTransform), Q
  1120. };
  1121. a.magnificPopup.registerModule("zoom", {
  1122. options: {
  1123. enabled: !1,
  1124. easing: "ease-in-out",
  1125. duration: 300,
  1126. opener: function (a) {
  1127. return a.is("img") ? a : a.find("img")
  1128. }
  1129. }, proto: {
  1130. initZoom: function () {
  1131. var a, c = b.st.zoom, d = ".zoom";
  1132. if (c.enabled && b.supportsTransition) {
  1133. var e, f, g = c.duration, h = function (a) {
  1134. var b = a.clone().removeAttr("style").removeAttr("class").addClass("mfp-animated-image"), d = "all " + c.duration / 1e3 + "s " + c.easing, e = {
  1135. position: "fixed",
  1136. zIndex: 9999,
  1137. left: 0,
  1138. top: 0,
  1139. "-webkit-backface-visibility": "hidden"
  1140. }, f = "transition";
  1141. return e["-webkit-" + f] = e["-moz-" + f] = e["-o-" + f] = e[f] = d, b.css(e), b
  1142. }, k = function () {
  1143. b.content.css("visibility", "visible")
  1144. };
  1145. x("BuildControls" + d, function () {
  1146. if (b._allowZoom()) {
  1147. if (clearTimeout(e), b.content.css("visibility", "hidden"), a = b._getItemToZoom(), !a)return k(), void 0;
  1148. f = h(a), f.css(b._getOffset()), b.wrap.append(f), e = setTimeout(function () {
  1149. f.css(b._getOffset(!0)), e = setTimeout(function () {
  1150. k(), setTimeout(function () {
  1151. f.remove(), a = f = null, z("ZoomAnimationEnded")
  1152. }, 16)
  1153. }, g)
  1154. }, 16)
  1155. }
  1156. }), x(j + d, function () {
  1157. if (b._allowZoom()) {
  1158. if (clearTimeout(e), b.st.removalDelay = g, !a) {
  1159. if (a = b._getItemToZoom(), !a)return;
  1160. f = h(a)
  1161. }
  1162. f.css(b._getOffset(!0)), b.wrap.append(f), b.content.css("visibility", "hidden"), setTimeout(function () {
  1163. f.css(b._getOffset())
  1164. }, 16)
  1165. }
  1166. }), x(i + d, function () {
  1167. b._allowZoom() && (k(), f && f.remove(), a = null)
  1168. })
  1169. }
  1170. }, _allowZoom: function () {
  1171. return "image" === b.currItem.type
  1172. }, _getItemToZoom: function () {
  1173. return b.currItem.hasSize ? b.currItem.img : !1
  1174. }, _getOffset: function (c) {
  1175. var d;
  1176. d = c ? b.currItem.img : b.st.zoom.opener(b.currItem.el || b.currItem);
  1177. var e = d.offset(), f = parseInt(d.css("padding-top"), 10), g = parseInt(d.css("padding-bottom"), 10);
  1178. e.top -= a(window).scrollTop() - f;
  1179. var h = {width: d.width(), height: (v ? d.innerHeight() : d[0].offsetHeight) - g - f};
  1180. return R() ? h["-moz-transform"] = h.transform = "translate(" + e.left + "px," + e.top + "px)" : (h.left = e.left, h.top = e.top), h
  1181. }
  1182. }
  1183. });
  1184. var S = "iframe", T = "//about:blank", U = function (a) {
  1185. if (b.currTemplate[S]) {
  1186. var c = b.currTemplate[S].find("iframe");
  1187. c.length && (a || (c[0].src = T), b.isIE8 && c.css("display", a ? "block" : "none"))
  1188. }
  1189. };
  1190. a.magnificPopup.registerModule(S, {
  1191. options: {
  1192. markup: '<div class="mfp-iframe-scaler"><div class="mfp-close"></div><iframe class="mfp-iframe" src="//about:blank" frameborder="0" allowfullscreen></iframe></div>',
  1193. srcAction: "iframe_src",
  1194. patterns: {
  1195. youtube: {index: "youtube.com", id: "v=", src: "//www.youtube.com/embed/%id%?autoplay=1"},
  1196. vimeo: {index: "vimeo.com/", id: "/", src: "//player.vimeo.com/video/%id%?autoplay=1"},
  1197. gmaps: {index: "//maps.google.", src: "%id%&output=embed"}
  1198. }
  1199. }, proto: {
  1200. initIframe: function () {
  1201. b.types.push(S), x("BeforeChange", function (a, b, c) {
  1202. b !== c && (b === S ? U() : c === S && U(!0))
  1203. }), x(i + "." + S, function () {
  1204. U()
  1205. })
  1206. }, getIframe: function (c, d) {
  1207. var e = c.src, f = b.st.iframe;
  1208. a.each(f.patterns, function () {
  1209. 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
  1210. });
  1211. var g = {};
  1212. return f.srcAction && (g[f.srcAction] = e), b._parseMarkup(d, g, c), b.updateStatus("ready"), d
  1213. }
  1214. }
  1215. });
  1216. var V = function (a) {
  1217. var c = b.items.length;
  1218. return a > c - 1 ? a - c : 0 > a ? c + a : a
  1219. }, W = function (a, b, c) {
  1220. return a.replace("%curr%", b + 1).replace("%total%", c)
  1221. };
  1222. a.magnificPopup.registerModule("gallery", {
  1223. options: {
  1224. enabled: !1,
  1225. arrowMarkup: '<button title="%title%" type="button" class="mfp-arrow mfp-arrow-%dir%"></button>',
  1226. preload: [0, 2],
  1227. navigateByImgClick: !0,
  1228. arrows: !0,
  1229. tPrev: "Previous (Left arrow key)",
  1230. tNext: "Next (Right arrow key)",
  1231. tCounter: "%curr% of %total%"
  1232. }, proto: {
  1233. initGallery: function () {
  1234. var c = b.st.gallery, d = ".mfp-gallery", f = Boolean(a.fn.mfpFastClick);
  1235. return b.direction = !0, c && c.enabled ? (g += " mfp-gallery", x(n + d, function () {
  1236. c.navigateByImgClick && b.wrap.on("click" + d, ".mfp-img", function () {
  1237. return b.items.length > 1 ? (b.next(), !1) : void 0
  1238. }), e.on("keydown" + d, function (a) {
  1239. 37 === a.keyCode ? b.prev() : 39 === a.keyCode && b.next()
  1240. })
  1241. }), x("UpdateStatus" + d, function (a, c) {
  1242. c.text && (c.text = W(c.text, b.currItem.index, b.items.length))
  1243. }), x(m + d, function (a, d, e, f) {
  1244. var g = b.items.length;
  1245. e.counter = g > 1 ? W(c.tCounter, f.index, g) : ""
  1246. }), x("BuildControls" + d, function () {
  1247. if (b.items.length > 1 && c.arrows && !b.arrowLeft) {
  1248. var d = c.arrowMarkup, e = b.arrowLeft = a(d.replace("%title%", c.tPrev).replace("%dir%", "left")).addClass(t), g = b.arrowRight = a(d.replace("%title%", c.tNext).replace("%dir%", "right")).addClass(t), h = f ? "mfpFastClick" : "click";
  1249. e[h](function () {
  1250. b.prev()
  1251. }), g[h](function () {
  1252. b.next()
  1253. }), b.isIE7 && (y("b", e[0], !1, !0), y("a", e[0], !1, !0), y("b", g[0], !1, !0), y("a", g[0], !1, !0)), b.container.append(e.add(g))
  1254. }
  1255. }), x(o + d, function () {
  1256. b._preloadTimeout && clearTimeout(b._preloadTimeout), b._preloadTimeout = setTimeout(function () {
  1257. b.preloadNearbyImages(), b._preloadTimeout = null
  1258. }, 16)
  1259. }), x(i + d, function () {
  1260. e.off(d), b.wrap.off("click" + d), b.arrowLeft && f && b.arrowLeft.add(b.arrowRight).destroyMfpFastClick(), b.arrowRight = b.arrowLeft = null
  1261. }), void 0) : !1
  1262. }, next: function () {
  1263. b.direction = !0, b.index = V(b.index + 1), b.updateItemHTML()
  1264. }, prev: function () {
  1265. b.direction = !1, b.index = V(b.index - 1), b.updateItemHTML()
  1266. }, goTo: function (a) {
  1267. b.direction = a >= b.index, b.index = a, b.updateItemHTML()
  1268. }, preloadNearbyImages: function () {
  1269. var a, c = b.st.gallery.preload, d = Math.min(c[0], b.items.length), e = Math.min(c[1], b.items.length);
  1270. for (a = 1; a <= (b.direction ? e : d); a++)b._preloadItem(b.index + a);
  1271. for (a = 1; a <= (b.direction ? d : e); a++)b._preloadItem(b.index - a)
  1272. }, _preloadItem: function (c) {
  1273. if (c = V(c), !b.items[c].preloaded) {
  1274. var d = b.items[c];
  1275. d.parsed || (d = b.parseEl(c)), z("LazyLoad", d), "image" === d.type && (d.img = a('<img class="mfp-img" />').on("load.mfploader", function () {
  1276. d.hasSize = !0
  1277. }).on("error.mfploader", function () {
  1278. d.hasSize = !0, d.loadError = !0, z("LazyLoadError", d)
  1279. }).attr("src", d.src)), d.preloaded = !0
  1280. }
  1281. }
  1282. }
  1283. });
  1284. var X = "retina";
  1285. a.magnificPopup.registerModule(X, {
  1286. options: {
  1287. replaceSrc: function (a) {
  1288. return a.src.replace(/\.\w+$/, function (a) {
  1289. return "@2x" + a
  1290. })
  1291. }, ratio: 1
  1292. }, proto: {
  1293. initRetina: function () {
  1294. if (window.devicePixelRatio > 1) {
  1295. var a = b.st.retina, c = a.ratio;
  1296. c = isNaN(c) ? c() : c, c > 1 && (x("ImageHasSize." + X, function (a, b) {
  1297. b.img.css({"max-width": b.img[0].naturalWidth / c, width: "100%"})
  1298. }), x("ElementParse." + X, function (b, d) {
  1299. d.src = a.replaceSrc(d, c)
  1300. }))
  1301. }
  1302. }
  1303. }
  1304. }), function () {
  1305. var b = 1e3, c = "ontouchstart"in window, d = function () {
  1306. w.off("touchmove" + f + " touchend" + f)
  1307. }, e = "mfpFastClick", f = "." + e;
  1308. a.fn.mfpFastClick = function (e) {
  1309. return a(this).each(function () {
  1310. var g, h = a(this);
  1311. if (c) {
  1312. var i, j, k, l, m, n;
  1313. h.on("touchstart" + f, function (a) {
  1314. l = !1, n = 1, m = a.originalEvent ? a.originalEvent.touches[0] : a.touches[0], j = m.clientX, k = m.clientY, w.on("touchmove" + f, function (a) {
  1315. 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())
  1316. }).on("touchend" + f, function (a) {
  1317. d(), l || n > 1 || (g = !0, a.preventDefault(), clearTimeout(i), i = setTimeout(function () {
  1318. g = !1
  1319. }, b), e())
  1320. })
  1321. })
  1322. }
  1323. h.on("click" + f, function () {
  1324. g || e()
  1325. })
  1326. })
  1327. }, a.fn.destroyMfpFastClick = function () {
  1328. a(this).off("touchstart" + f + " click" + f), c && w.off("touchmove" + f + " touchend" + f)
  1329. }
  1330. }()
  1331. }(window.jQuery || window.Zepto), function (a, b, c) {
  1332. var d = function (d, e) {
  1333. this.elem = d, this.$elem = a(d), this.options = e, this.metadata = this.$elem.data("plugin-options"), this.$nav = this.$elem.find("a"), this.$win = a(b), this.sections = {}, this.didScroll = !1, this.$doc = a(c), this.docHeight = this.$doc.height()
  1334. };
  1335. d.prototype = {
  1336. defaults: {
  1337. currentClass: "current",
  1338. changeHash: !1,
  1339. easing: "swing",
  1340. filter: "",
  1341. scrollSpeed: 750,
  1342. scrollOffset: 0,
  1343. scrollThreshold: .5,
  1344. begin: !1,
  1345. end: !1,
  1346. scrollChange: !1
  1347. }, init: function () {
  1348. var b = this;
  1349. return b.config = a.extend({}, b.defaults, b.options, b.metadata), "" !== b.config.filter && (b.$nav = b.$nav.filter(b.config.filter)), b.$nav.on("click.onePageNav", a.proxy(b.handleClick, b)), b.getPositions(), b.bindInterval(), b.$win.on("resize.onePageNav", a.proxy(b.getPositions, b)), this
  1350. }, adjustNav: function (a, b) {
  1351. a.$elem.find("." + a.config.currentClass).removeClass(a.config.currentClass), b.addClass(a.config.currentClass)
  1352. }, bindInterval: function () {
  1353. var a, b = this;
  1354. b.$win.on("scroll.onePageNav", function () {
  1355. b.didScroll = !0
  1356. }), b.t = setInterval(function () {
  1357. a = b.$doc.height(), b.didScroll && (b.didScroll = !1, b.scrollChange()), a !== b.docHeight && (b.docHeight = a, b.getPositions())
  1358. }, 250)
  1359. }, getHash: function (a) {
  1360. return a.attr("href").split("#")[1]
  1361. }, getPositions: function () {
  1362. var b, c, d, e = this;
  1363. e.$nav.each(function () {
  1364. b = e.getHash(a(this)), d = a("#" + b), d.length && (c = d.offset().top, e.sections[b] = Math.round(c) - e.config.scrollOffset)
  1365. })
  1366. }, getSection: function (a) {
  1367. var b = null, c = Math.round(this.$win.height() * this.config.scrollThreshold);
  1368. for (var d in this.sections)this.sections[d] - c < a && (b = d);
  1369. return b
  1370. }, handleClick: function (c) {
  1371. var d = this, e = a(c.currentTarget), f = e.parent(), g = "#" + d.getHash(e);
  1372. f.hasClass(d.config.currentClass) || (d.config.begin && d.config.begin(), d.adjustNav(d, f), d.unbindInterval(), a.scrollTo(g, d.config.scrollSpeed, {
  1373. axis: "y",
  1374. easing: d.config.easing,
  1375. offset: {top: -d.config.scrollOffset},
  1376. onAfter: function () {
  1377. d.config.changeHash && (b.location.hash = g), d.bindInterval(), d.config.end && d.config.end()
  1378. }
  1379. })), c.preventDefault()
  1380. }, scrollChange: function () {
  1381. var a, b = this.$win.scrollTop(), c = this.getSection(b);
  1382. null !== c && (a = this.$elem.find('a[href$="#' + c + '"]').parent(), a.hasClass(this.config.currentClass) || (this.adjustNav(this, a), this.config.scrollChange && this.config.scrollChange(a)))
  1383. }, unbindInterval: function () {
  1384. clearInterval(this.t), this.$win.unbind("scroll.onePageNav")
  1385. }
  1386. }, d.defaults = d.prototype.defaults, a.fn.onePageNav = function (a) {
  1387. return this.each(function () {
  1388. new d(this, a).init()
  1389. })
  1390. }
  1391. }(jQuery, window, document), function (a) {
  1392. function b(a) {
  1393. return "object" == typeof a ? a : {top: a, left: a}
  1394. }
  1395.  
  1396. var c = a.scrollTo = function (b, c, d) {
  1397. a(window).scrollTo(b, c, d)
  1398. };
  1399. c.defaults = {axis: "xy", duration: parseFloat(a.fn.jquery) >= 1.3 ? 0 : 1, limit: !0}, c.window = function () {
  1400. return a(window)._scrollable()
  1401. }, a.fn._scrollable = function () {
  1402. return this.map(function () {
  1403. var b = this, c = !b.nodeName || -1 != a.inArray(b.nodeName.toLowerCase(), ["iframe", "#document", "html", "body"]);
  1404. if (!c)return b;
  1405. var d = (b.contentWindow || b).document || b.ownerDocument || b;
  1406. return /webkit/i.test(navigator.userAgent) || "BackCompat" == d.compatMode ? d.body : d.documentElement
  1407. })
  1408. }, a.fn.scrollTo = function (d, e, f) {
  1409. return "object" == typeof e && (f = e, e = 0), "function" == typeof f && (f = {onAfter: f}), "max" == d && (d = 9e9), f = a.extend({}, c.defaults, f), e = e || f.duration, f.queue = f.queue && f.axis.length > 1, f.queue && (e /= 2), f.offset = b(f.offset), f.over = b(f.over), this._scrollable().each(function () {
  1410. function g(a) {
  1411. j.animate(l, e, f.easing, a && function () {
  1412. a.call(this, d, f)
  1413. })
  1414. }
  1415.  
  1416. if (d) {
  1417. var h, i = this, j = a(i), k = d, l = {}, m = j.is("html,body");
  1418. switch (typeof k) {
  1419. case"number":
  1420. case"string":
  1421. if (/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(k)) {
  1422. k = b(k);
  1423. break
  1424. }
  1425. if (k = a(k, this), !k.length)return;
  1426. case"object":
  1427. (k.is || k.style) && (h = (k = a(k)).offset())
  1428. }
  1429. a.each(f.axis.split(""), function (a, b) {
  1430. var d = "x" == b ? "Left" : "Top", e = d.toLowerCase(), n = "scroll" + d, o = i[n], p = c.max(i, b);
  1431. if (h)l[n] = h[e] + (m ? 0 : o - j.offset()[e]), f.margin && (l[n] -= parseInt(k.css("margin" + d)) || 0, l[n] -= parseInt(k.css("border" + d + "Width")) || 0), l[n] += f.offset[e] || 0, f.over[e] && (l[n] += k["x" == b ? "width" : "height"]() * f.over[e]); else {
  1432. var q = k[e];
  1433. l[n] = q.slice && "%" == q.slice(-1) ? parseFloat(q) / 100 * p : q
  1434. }
  1435. f.limit && /^\d+$/.test(l[n]) && (l[n] = l[n] <= 0 ? 0 : Math.min(l[n], p)), !a && f.queue && (o != l[n] && g(f.onAfterFirst), delete l[n])
  1436. }), g(f.onAfter)
  1437. }
  1438. }).end()
  1439. }, c.max = function (b, c) {
  1440. var d = "x" == c ? "Width" : "Height", e = "scroll" + d;
  1441. if (!a(b).is("html,body"))return b[e] - a(b)[d.toLowerCase()]();
  1442. var f = "client" + d, g = b.ownerDocument.documentElement, h = b.ownerDocument.body;
  1443. return Math.max(g[e], h[e]) - Math.min(g[f], h[f])
  1444. }
  1445. }(jQuery), function (a, b) {
  1446. function c() {
  1447. this._state = [], this._defaults = {
  1448. classHolder: "sbHolder",
  1449. classHolderDisabled: "sbHolderDisabled",
  1450. classSelector: "sbSelector",
  1451. classOptions: "sbOptions",
  1452. classGroup: "sbGroup",
  1453. classSub: "sbSub",
  1454. classDisabled: "sbDisabled",
  1455. classToggleOpen: "sbToggleOpen",
  1456. classToggle: "sbToggle",
  1457. classFocus: "sbFocus",
  1458. speed: 200,
  1459. effect: "slide",
  1460. onChange: null,
  1461. onOpen: null,
  1462. onClose: null
  1463. }
  1464. }
  1465.  
  1466. var d = "selectbox", e = !1, f = !0;
  1467. a.extend(c.prototype, {
  1468. _isOpenSelectbox: function (a) {
  1469. if (!a)return e;
  1470. var b = this._getInst(a);
  1471. return b.isOpen
  1472. }, _isDisabledSelectbox: function (a) {
  1473. if (!a)return e;
  1474. var b = this._getInst(a);
  1475. return b.isDisabled
  1476. }, _attachSelectbox: function (b, c) {
  1477. function g() {
  1478. var b, c, d = this.attr("id").split("_")[1];
  1479. for (b in n._state)b !== d && n._state.hasOwnProperty(b) && (c = a("select[sb='" + b + "']")[0], c && n._closeSelectbox(c))
  1480. }
  1481.  
  1482. function h() {
  1483. var c = arguments[1] && arguments[1].sub ? !0 : !1, d = arguments[1] && arguments[1].disabled ? !0 : !1;
  1484. arguments[0].each(function (e) {
  1485. var g, h = a(this), i = a("<li>");
  1486. h.is(":selected") && (j.text(h.text()), p = f), e === r - 1 && i.addClass("last"), h.is(":disabled") || d ? (g = a("<span>", {text: h.text()}).addClass(o.settings.classDisabled), c && g.addClass(o.settings.classSub), g.appendTo(i)) : (g = a("<a>", {
  1487. href: "#" + h.val(),
  1488. rel: h.val()
  1489. }).text(h.text()).bind("click.sb", function (c) {
  1490. c && c.preventDefault && c.preventDefault();
  1491. {
  1492. var d = k, e = a(this);
  1493. d.attr("id").split("_")[1]
  1494. }
  1495. n._changeSelectbox(b, e.attr("rel"), e.text()), n._closeSelectbox(b)
  1496. }).bind("mouseover.sb", function () {
  1497. var b = a(this);
  1498. b.parent().siblings().find("a").removeClass(o.settings.classFocus), b.addClass(o.settings.classFocus)
  1499. }).bind("mouseout.sb", function () {
  1500. a(this).removeClass(o.settings.classFocus)
  1501. }), c && g.addClass(o.settings.classSub), h.is(":selected") && g.addClass(o.settings.classFocus), g.appendTo(i)), i.appendTo(l)
  1502. })
  1503. }
  1504.  
  1505. if (this._getInst(b))return e;
  1506. var i, j, k, l, m = a(b), n = this, o = n._newInst(m), p = e, q = (m.find("optgroup"), m.find("option")), r = q.length;
  1507. m.attr("sb", o.uid), a.extend(o.settings, n._defaults, c), n._state[o.uid] = e, m.hide(), i = a("<div>", {
  1508. id: "sbHolder_" + o.uid,
  1509. "class": o.settings.classHolder,
  1510. tabindex: m.attr("tabindex")
  1511. }), j = a("<a>", {
  1512. id: "sbSelector_" + o.uid, href: "#", "class": o.settings.classSelector, click: function (c) {
  1513. c.preventDefault(), g.apply(a(this), []);
  1514. var d = a(this).attr("id").split("_")[1];
  1515. n._state[d] ? n._closeSelectbox(b) : n._openSelectbox(b)
  1516. }
  1517. }), k = a("<a>", {
  1518. id: "sbToggle_" + o.uid, href: "#", "class": o.settings.classToggle, click: function (c) {
  1519. c.preventDefault(), g.apply(a(this), []);
  1520. var d = a(this).attr("id").split("_")[1];
  1521. n._state[d] ? n._closeSelectbox(b) : n._openSelectbox(b)
  1522. }
  1523. }), k.appendTo(i), l = a("<ul>", {
  1524. id: "sbOptions_" + o.uid,
  1525. "class": o.settings.classOptions,
  1526. css: {display: "none"}
  1527. }), m.children().each(function () {
  1528. var b, c = a(this), d = {};
  1529. c.is("option") ? h(c) : c.is("optgroup") && (b = a("<li>"), a("<span>", {text: c.attr("label")}).addClass(o.settings.classGroup).appendTo(b), b.appendTo(l), c.is(":disabled") && (d.disabled = !0), d.sub = !0, h(c.find("option"), d))
  1530. }), p || j.text(q.first().text()), a.data(b, d, o), i.data("uid", o.uid).bind("keydown.sb", function (b) {
  1531. var c = b.charCode ? b.charCode : b.keyCode ? b.keyCode : 0, e = a(this), f = e.data("uid"), g = e.siblings("select[sb='" + f + "']").data(d), h = e.siblings(["select[sb='", f, "']"].join("")).get(0), i = e.find("ul").find("a." + g.settings.classFocus);
  1532. switch (c) {
  1533. case 37:
  1534. case 38:
  1535. if (i.length > 0) {
  1536. var j;
  1537. a("a", e).removeClass(g.settings.classFocus), j = i.parent().prevAll("li:has(a)").eq(0).find("a"), j.length > 0 && (j.addClass(g.settings.classFocus).focus(), a("#sbSelector_" + f).text(j.text()))
  1538. }
  1539. break;
  1540. case 39:
  1541. case 40:
  1542. var j;
  1543. a("a", e).removeClass(g.settings.classFocus), j = i.length > 0 ? i.parent().nextAll("li:has(a)").eq(0).find("a") : e.find("ul").find("a").eq(0), j.length > 0 && (j.addClass(g.settings.classFocus).focus(), a("#sbSelector_" + f).text(j.text()));
  1544. break;
  1545. case 13:
  1546. i.length > 0 && n._changeSelectbox(h, i.attr("rel"), i.text()), n._closeSelectbox(h);
  1547. break;
  1548. case 9:
  1549. if (h) {
  1550. var g = n._getInst(h);
  1551. g && (i.length > 0 && n._changeSelectbox(h, i.attr("rel"), i.text()), n._closeSelectbox(h))
  1552. }
  1553. var k = parseInt(e.attr("tabindex"), 10);
  1554. b.shiftKey ? k-- : k++, a("*[tabindex='" + k + "']").focus();
  1555. break;
  1556. case 27:
  1557. n._closeSelectbox(h)
  1558. }
  1559. return b.stopPropagation(), !1
  1560. }).delegate("a", "mouseover", function () {
  1561. a(this).addClass(o.settings.classFocus)
  1562. }).delegate("a", "mouseout", function () {
  1563. a(this).removeClass(o.settings.classFocus)
  1564. }), j.appendTo(i), l.appendTo(i), i.insertAfter(m), a("html").on("mousedown", function (b) {
  1565. b.stopPropagation(), a("select").selectbox("close")
  1566. }), a([".", o.settings.classHolder, ", .", o.settings.classSelector].join("")).mousedown(function (a) {
  1567. a.stopPropagation()
  1568. })
  1569. }, _detachSelectbox: function (b) {
  1570. var c = this._getInst(b);
  1571. return c ? (a("#sbHolder_" + c.uid).remove(), a.data(b, d, null), a(b).show(), void 0) : e
  1572. }, _changeSelectbox: function (b, c, d) {
  1573. var g, h = this._getInst(b);
  1574. h && (g = this._get(h, "onChange"), a("#sbSelector_" + h.uid).text(d)), c = c.replace(/\'/g, "\\'"), a(b).find("option").attr("selected", e), a(b).find("option[value='" + c + "']").attr("selected", f), h && g ? g.apply(h.input ? h.input[0] : null, [c, h]) : h && h.input && h.input.trigger("change")
  1575. }, _enableSelectbox: function (b) {
  1576. var c = this._getInst(b);
  1577. return c && c.isDisabled ? (a("#sbHolder_" + c.uid).removeClass(c.settings.classHolderDisabled), c.isDisabled = e, a.data(b, d, c), void 0) : e
  1578. }, _disableSelectbox: function (b) {
  1579. var c = this._getInst(b);
  1580. return !c || c.isDisabled ? e : (a("#sbHolder_" + c.uid).addClass(c.settings.classHolderDisabled), c.isDisabled = f, a.data(b, d, c), void 0)
  1581. }, _optionSelectbox: function (b, c, f) {
  1582. var g = this._getInst(b);
  1583. return g ? (g[c] = f, a.data(b, d, g), void 0) : e
  1584. }, _openSelectbox: function (b) {
  1585. var c = this._getInst(b);
  1586. if (c && !c.isOpen && !c.isDisabled) {
  1587. var e = a("#sbOptions_" + c.uid), g = parseInt(a(window).height(), 10), h = a("#sbHolder_" + c.uid).offset(), i = a(window).scrollTop(), j = e.prev().height(), k = g - (h.top - i) - j / 2, l = this._get(c, "onOpen");
  1588. e.css({
  1589. top: j + "px",
  1590. maxHeight: k - j + "px"
  1591. }), "fade" === c.settings.effect ? e.fadeIn(c.settings.speed) : e.slideDown(c.settings.speed), a("#sbToggle_" + c.uid).addClass(c.settings.classToggleOpen), this._state[c.uid] = f, c.isOpen = f, l && l.apply(c.input ? c.input[0] : null, [c]), a.data(b, d, c)
  1592. }
  1593. }, _closeSelectbox: function (b) {
  1594. var c = this._getInst(b);
  1595. if (c && c.isOpen) {
  1596. var f = this._get(c, "onClose");
  1597. "fade" === c.settings.effect ? a("#sbOptions_" + c.uid).fadeOut(c.settings.speed) : a("#sbOptions_" + c.uid).slideUp(c.settings.speed), a("#sbToggle_" + c.uid).removeClass(c.settings.classToggleOpen), this._state[c.uid] = e, c.isOpen = e, f && f.apply(c.input ? c.input[0] : null, [c]), a.data(b, d, c)
  1598. }
  1599. }, _newInst: function (a) {
  1600. var b = a[0].id.replace(/([^A-Za-z0-9_-])/g, "\\\\$1");
  1601. return {id: b, input: a, uid: Math.floor(99999999 * Math.random()), isOpen: e, isDisabled: e, settings: {}}
  1602. }, _getInst: function (b) {
  1603. try {
  1604. return a.data(b, d)
  1605. } catch (c) {
  1606. throw"Missing instance data for this selectbox"
  1607. }
  1608. }, _get: function (a, c) {
  1609. return a.settings[c] !== b ? a.settings[c] : this._defaults[c]
  1610. }
  1611. }), a.fn.selectbox = function (b) {
  1612. var c = Array.prototype.slice.call(arguments, 1);
  1613. return "string" == typeof b && "isDisabled" == b ? a.selectbox["_" + b + "Selectbox"].apply(a.selectbox, [this[0]].concat(c)) : "option" == b && 2 == arguments.length && "string" == typeof arguments[1] ? a.selectbox["_" + b + "Selectbox"].apply(a.selectbox, [this[0]].concat(c)) : this.each(function () {
  1614. "string" == typeof b ? a.selectbox["_" + b + "Selectbox"].apply(a.selectbox, [this].concat(c)) : a.selectbox._attachSelectbox(this, b)
  1615. })
  1616. }, a.selectbox = new c, a.selectbox.version = "0.2"
  1617. }(jQuery), function (a, b, c) {
  1618. function d(b, c) {
  1619. this.element = b, this.$element = a(b), this.options = a.extend(!0, {}, r, c), this.attributes = this._readDataAttributes(), this._defaults = r, this._name = i, this.init(), this.bind()
  1620. }
  1621.  
  1622. function e(a, b, d) {
  1623. var e = "";
  1624. if (d) {
  1625. var f = new Date;
  1626. f.setTime(f.getTime() + 24 * d * 60 * 60 * 1e3), e = "; expires=" + f.toGMTString()
  1627. }
  1628. var g = escape(a) + "=" + escape(b) + e + "; path=/";
  1629. c.cookie = g
  1630. }
  1631.  
  1632. function f(a) {
  1633. e(a, "", -1)
  1634. }
  1635.  
  1636. function g(a) {
  1637. for (var b = escape(a) + "=", d = c.cookie.split(";"), e = 0; e < d.length; e++) {
  1638. for (var f = d[e]; " " === f.charAt(0);)f = f.substring(1, f.length);
  1639. if (0 === f.indexOf(b)) {
  1640. var g = unescape(f.substring(b.length, f.length));
  1641. return g
  1642. }
  1643. }
  1644. return !1
  1645. }
  1646.  
  1647. function h(a, b) {
  1648. for (var c = Array.prototype.slice.call(arguments).splice(2), d = a.split("."), e = d.pop(), f = 0; f < d.length; f++)b = b[d[f]];
  1649. return b[e].apply(this, c)
  1650. }
  1651.  
  1652. var i = "twoClickSocial", j = "tcs_facebook", k = "tcs_pinterest", l = "tcs_facebook_share", m = "tcs_facebook_like", n = "tcs_facebook", o = "tcs_pinterest", p = {
  1653. loaded: !1,
  1654. active: !1
  1655. }, q = {loaded: !1, active: !1}, r = {
  1656. url: c.URL,
  1657. description: c.description,
  1658. expiration: 28,
  1659. facebook: {app_id: "152941331548334", hideComments: !0, like: !1, share: !1},
  1660. pinterest: {pinterest: !1},
  1661. selector: {
  1662. name: "name",
  1663. caption: "caption",
  1664. description: "description",
  1665. url: "url",
  1666. picture: "picture",
  1667. callback: "callback"
  1668. },
  1669. onSDKLoaded: function (a) {
  1670. this.console && console.log("SDK loaded: " + a)
  1671. },
  1672. tooltip: {
  1673. headline: "Jetzt soziale Netzwerke aktivieren!",
  1674. text: "Deine Privatsphäre ist uns wichtig, deshalb wird der Button erst aktiv, wenn du den Schieberegler betätigst.",
  1675. linkname: "Mehr erfahren",
  1676. url: c.location,
  1677. direction: "bottom"
  1678. }
  1679. };
  1680. d.prototype.init = function () {
  1681. this.$element.addClass("tcs"), q.active = "1" === g(j), p.active = "1" === g(k), this.$element.append(this._createUI())
  1682. }, d.prototype._createUI = function () {
  1683. var b = a('<ul class="tcs_container">'), c = this.options;
  1684. return (c.facebook.like || c.facebook.share) && this._appendEntry(b, n), c.pinterest.pinterest && this._appendEntry(b, o), b
  1685. }, d.prototype._appendEntry = function (b, c) {
  1686. var d = this.options, e = a('<li class="' + c + '">'), f = a('<span class="tcs_switch off"></span>');
  1687. switch (c) {
  1688. case n:
  1689. if (d.facebook.like) {
  1690. var g = _createButton(m);
  1691. if (e.append(g), q.active) {
  1692. g.hide(), f.removeClass("off").addClass("on");
  1693. var h = this.createLikeButton();
  1694. e.append(h)
  1695. }
  1696. }
  1697. if (d.facebook.share) {
  1698. var i = _createButton(l);
  1699. if (e.append(i), q.active) {
  1700. i.hide(), f.removeClass("off").addClass("on");
  1701. var j = this.createShareButton();
  1702. e.append(j)
  1703. }
  1704. }
  1705. q.active ? q.active && !q.loaded && _loadFacebookSDK(d) : this.handleTooltip(e, !0);
  1706. break;
  1707. case o:
  1708. var k = _createButton(c);
  1709. if (e.append(k), p.active) {
  1710. k.hide(), f.removeClass("off").addClass("on");
  1711. var r = this.createPinterestButton();
  1712. e.append(r)
  1713. } else this.handleTooltip(e, !0);
  1714. p.active && !p.loaded && _loadPinterestSDK(d, function () {
  1715. });
  1716. break;
  1717. default:
  1718. return
  1719. }
  1720. e.append(_createTooltip(d.tooltip)), e.prepend(f), b.append(e)
  1721. }, d.prototype._readDataAttributes = function () {
  1722. var b = {}, c = this.$element, d = this.options;
  1723. return a.each(d.selector, function (a, e) {
  1724. var f = c.data(e);
  1725. "undefined" != typeof f && "" !== f ? b[a] = f : ("url" === a || "description" === a) && (b[a] = d[a])
  1726. }), b
  1727. }, d.prototype.createLikeButton = function () {
  1728. var b = this.options.url, c = a('<div class="fb-like" data-href="' + b + '" data-width="450" data-layout="button_count" data-show-faces="false" data-send="false"></div>');
  1729. return this.options.facebook.hideComments && c.addClass("hide-comments"), c
  1730. }, d.prototype.createShareButton = function () {
  1731. var b = this, c = a('<div class="fb-share">');
  1732. return c.on("click", function () {
  1733. var a = b._readDataAttributes();
  1734. console.log(a), _openShareDialog(a)
  1735. }), c
  1736. }, d.prototype.createPinterestButton = function () {
  1737. var b = a('<div class="pinterest-btn">'), c = a("<a>").append('<img src="//assets.pinterest.com/images/pidgets/pin_it_button.png" />'), d = this._readDataAttributes(), e = encodeURI(d.url), f = d.description, g = encodeURI(d.picture), h = "//pinterest.com/pin/create/button/?url=" + e + "&description=" + f + "&media=" + g;
  1738. return c.attr("href", h), c.data("pin-do", "buttonPin"), c.data("pin-config", "beside"), c.on("click", function (a) {
  1739. return a.preventDefault(), !1
  1740. }), b.append(c), b
  1741. }, d.prototype.handleTooltip = function (b, c) {
  1742. c === !0 ? a.isFunction(jQuery().hoverIntent) ? b.hoverIntent(this.mouseEnterHandler, this.mouseLeaveHandler) : b.on("mouseenter", this.mouseEnterHandler).on("mouseleave", this.mouseLeaveHandler) : (b.find(".tcs_tooltip").hide(), b.off("mouseenter").off("mouseleave"))
  1743. }, d.prototype.mouseEnterHandler = function () {
  1744. var b = a(this).find(".tcs_tooltip");
  1745. clearTimeout(a(this).data("timeoutId")), b.fadeIn("slow")
  1746. }, d.prototype.mouseLeaveHandler = function () {
  1747. var b = a(this).find(".tcs_tooltip"), c = setTimeout(function () {
  1748. b.fadeOut("slow")
  1749. }, 650);
  1750. a(this).data("timeoutId", c)
  1751. }, d.prototype.bind = function () {
  1752. {
  1753. var b = this, c = this.$element, d = this.options;
  1754. this.attributes
  1755. }
  1756. c.find(".tcs_switch").on("click", function () {
  1757. var g = a(this).parent().attr("class"), h = a(this).hasClass("off"), i = a("." + g).find(".tcs_switch");
  1758. if (_toggleSwitches(i, h), g === n)h ? ("undefined" == typeof FB && _loadFacebookSDK(d), _replaceFacebookLikeButtons(), _replaceFacebookShareButtons(), e(j, "1", d.expiration), q.active = !0) : (a(".fb-like").hide(), a(".fb-share").hide(), a("." + m).show(), a("." + l).show(), f(j), q.active = !1); else if (g === o)if (h) {
  1759. {
  1760. c.data(d.pinterest.url), c.data(d.pinterest.description)
  1761. }
  1762. p.loaded === !1 ? (_replacePinterestButtons(), _loadPinterestSDK(d, function () {
  1763. })) : _replacePinterestButtons(), e(k, "1", d.expiration), p.active = !0
  1764. } else a(".pinterest-btn").hide(), a("." + o + ".tcs_btn").show(), f(k), p.active = !1;
  1765. b.handleTooltip(a("." + g), !h)
  1766. })
  1767. }, _replaceFacebookLikeButtons = function () {
  1768. var b = a("." + m);
  1769. 0 !== b.length && b.each(function () {
  1770. a(this).hide();
  1771. var b = a(this).siblings(".fb-like");
  1772. if (b.length > 0)return b.show(), !0;
  1773. var c = a(this).parents(".tcs").data().plugin_twoClickSocial.createLikeButton();
  1774. a(this).parent("li").append(c)
  1775. })
  1776. }, _replaceFacebookShareButtons = function () {
  1777. var b = a("." + l);
  1778. 0 !== b.length && b.each(function () {
  1779. a(this).hide();
  1780. var b = a(this).siblings(".fb-share");
  1781. return b.length > 0 ? (b.show(), !0) : (b = a(this).parents(".tcs").data().plugin_twoClickSocial.createShareButton(), a(this).parent("li").append(b), void 0)
  1782. })
  1783. }, _replacePinterestButtons = function () {
  1784. var b = a("." + o + ".tcs_btn");
  1785. 0 !== b.length && b.each(function () {
  1786. a(this).hide();
  1787. var b = a(this).siblings(".pinterest-btn");
  1788. return b.length > 0 ? (b.show(), !0) : (b = a(this).parents(".tcs").data().plugin_twoClickSocial.createPinterestButton(), a(this).parent("li").append(b), void 0)
  1789. })
  1790. }, _createButton = function (b) {
  1791. return a('<div class="tcs_btn ' + b + '">')
  1792. }, _createTooltip = function (b) {
  1793. var c = a('<div class="tcs_tooltip ' + b.direction + '">'), d = a('<div class="tcs_tooltip_content">'), e = a('<h3 class="tcs_tooltip_headline">').text(b.headline), f = a('<p class="tcs_tooltip_text">').text(b.text), g = a('<a class="tcs_tooltip_link" target="_blank">').attr("href", b.url).text(b.linkname);
  1794. return d.append(e).append(f).append(g), c.append(d).hide()
  1795. }, _toggleSwitches = function (a, b) {
  1796. b ? a.removeClass("off").addClass("on") : a.removeClass("on").addClass("off")
  1797. }, _loadFacebookSDK = function (a) {
  1798. b.fbAsyncInit = function () {
  1799. FB.init({
  1800. appId: a.facebook.app_id,
  1801. status: !1,
  1802. cookie: !0,
  1803. oauth: !0,
  1804. xfbml: !0
  1805. }), a.onSDKLoaded("facebook"), q.loaded = !0
  1806. }, function (a) {
  1807. var b, c = "facebook-jssdk";
  1808. a.getElementById(c) || (b = a.createElement("script"), b.id = c, b.async = !0, b.src = "//connect.facebook.net/de_DE/all.js", a.getElementsByTagName("head")[0].appendChild(b))
  1809. }(c)
  1810. }, _loadPinterestSDK = function (b, c) {
  1811. var d = a.Deferred(), e = d.promise();
  1812. a.ajaxSetup({cache: !0}), a.getScript("//assets.pinterest.com/js/pinit.js", function () {
  1813. var f = setInterval(function () {
  1814. var b = a('script[id^="PIN_"]');
  1815. b.length > 0 && d.resolve()
  1816. }, 500);
  1817. e.done(function () {
  1818. clearInterval(f), b.onSDKLoaded("pinterest"), c && "function" == typeof c && c(), p.loaded = !0
  1819. })
  1820. })
  1821. }, _openShareDialog = function (a) {
  1822. var c = {
  1823. method: "feed",
  1824. name: a.name,
  1825. caption: a.caption,
  1826. description: a.description,
  1827. picture: a.picture,
  1828. link: a.url
  1829. };
  1830. FB.ui(c, function (c) {
  1831. if (c && c.post_id) {
  1832. this.console && console.log(c);
  1833. var d = a.callback;
  1834. a.callback && h(d, b)
  1835. } else this.console && console.log(c)
  1836. })
  1837. }, a.fn[i] = function (b) {
  1838. return this.each(function () {
  1839. a.data(this, "plugin_" + i) || a.data(this, "plugin_" + i, new d(this, b))
  1840. })
  1841. }
  1842. }(jQuery, window, document), function (a) {
  1843. a.fn.unveil = function (b, c) {
  1844. function d() {
  1845. f = l.filter(function () {
  1846. var b = a(this), c = h.scrollTop(), d = c + h.height(), e = b.offset().top, f = e + b.height();
  1847. return f >= c - i && d + i >= e
  1848. }), e = f.trigger("unveil"), l = l.not(e)
  1849. }
  1850.  
  1851. var e, f, g, h = a(window), i = b || 0, j = window.devicePixelRatio > 1, k = j ? "data-src-retina" : "data-src", l = this;
  1852. return this.one("unveil", function () {
  1853. g = this.getAttribute(k), g = g || this.getAttribute("data-src"), g && (this.setAttribute("src", g), this.onload = function () {
  1854. c && "function" == typeof c && c(), a(this).removeClass("unveil")
  1855. })
  1856. }), h.scroll(d), h.resize(d), d(), this
  1857. }
  1858. }(window.jQuery || window.Zepto), function () {
  1859. var a = [].indexOf || function (a) {
  1860. for (var b = 0, c = this.length; c > b; b++)if (b in this && this[b] === a)return b;
  1861. return -1
  1862. }, b = [].slice;
  1863. !function (a, b) {
  1864. return "function" == typeof define && define.amd ? define("waypoints", ["jquery"], function (c) {
  1865. return b(c, a)
  1866. }) : b(a.jQuery, a)
  1867. }(this, function (c, d) {
  1868. var e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t;
  1869. return e = c(d), l = a.call(d, "ontouchstart") >= 0, h = {
  1870. horizontal: {},
  1871. vertical: {}
  1872. }, i = 1, k = {}, j = "waypoints-context-id", o = "resize.waypoints", p = "scroll.waypoints", q = 1, r = "waypoints-waypoint-ids", s = "waypoint", t = "waypoints", f = function () {
  1873. function a(a) {
  1874. var b = this;
  1875. this.$element = a, this.element = a[0], this.didResize = !1, this.didScroll = !1, this.id = "context" + i++, this.oldScroll = {
  1876. x: a.scrollLeft(),
  1877. y: a.scrollTop()
  1878. }, this.waypoints = {
  1879. horizontal: {},
  1880. vertical: {}
  1881. }, a.data(j, this.id), k[this.id] = this, a.bind(p, function () {
  1882. var a;
  1883. return b.didScroll || l ? void 0 : (b.didScroll = !0, a = function () {
  1884. return b.doScroll(), b.didScroll = !1
  1885. }, d.setTimeout(a, c[t].settings.scrollThrottle))
  1886. }), a.bind(o, function () {
  1887. var a;
  1888. return b.didResize ? void 0 : (b.didResize = !0, a = function () {
  1889. return c[t]("refresh"), b.didResize = !1
  1890. }, d.setTimeout(a, c[t].settings.resizeThrottle))
  1891. })
  1892. }
  1893.  
  1894. return a.prototype.doScroll = function () {
  1895. var a, b = this;
  1896. return a = {
  1897. horizontal: {
  1898. newScroll: this.$element.scrollLeft(),
  1899. oldScroll: this.oldScroll.x,
  1900. forward: "right",
  1901. backward: "left"
  1902. },
  1903. vertical: {
  1904. newScroll: this.$element.scrollTop(),
  1905. oldScroll: this.oldScroll.y,
  1906. forward: "down",
  1907. backward: "up"
  1908. }
  1909. }, !l || a.vertical.oldScroll && a.vertical.newScroll || c[t]("refresh"), c.each(a, function (a, d) {
  1910. var e, f, g;
  1911. return g = [], f = d.newScroll > d.oldScroll, e = f ? d.forward : d.backward, c.each(b.waypoints[a], function (a, b) {
  1912. var c, e;
  1913. return d.oldScroll < (c = b.offset) && c <= d.newScroll ? g.push(b) : d.newScroll < (e = b.offset) && e <= d.oldScroll ? g.push(b) : void 0
  1914. }), g.sort(function (a, b) {
  1915. return a.offset - b.offset
  1916. }), f || g.reverse(), c.each(g, function (a, b) {
  1917. return b.options.continuous || a === g.length - 1 ? b.trigger([e]) : void 0
  1918. })
  1919. }), this.oldScroll = {x: a.horizontal.newScroll, y: a.vertical.newScroll}
  1920. }, a.prototype.refresh = function () {
  1921. var a, b, d, e = this;
  1922. return d = c.isWindow(this.element), b = this.$element.offset(), this.doScroll(), a = {
  1923. horizontal: {
  1924. contextOffset: d ? 0 : b.left,
  1925. contextScroll: d ? 0 : this.oldScroll.x,
  1926. contextDimension: this.$element.width(),
  1927. oldScroll: this.oldScroll.x,
  1928. forward: "right",
  1929. backward: "left",
  1930. offsetProp: "left"
  1931. },
  1932. vertical: {
  1933. contextOffset: d ? 0 : b.top,
  1934. contextScroll: d ? 0 : this.oldScroll.y,
  1935. contextDimension: d ? c[t]("viewportHeight") : this.$element.height(),
  1936. oldScroll: this.oldScroll.y,
  1937. forward: "down",
  1938. backward: "up",
  1939. offsetProp: "top"
  1940. }
  1941. }, c.each(a, function (a, b) {
  1942. return c.each(e.waypoints[a], function (a, d) {
  1943. var e, f, g, h, i;
  1944. return e = d.options.offset, g = d.offset, f = c.isWindow(d.element) ? 0 : d.$element.offset()[b.offsetProp], c.isFunction(e) ? e = e.apply(d.element) : "string" == typeof e && (e = parseFloat(e), d.options.offset.indexOf("%") > -1 && (e = Math.ceil(b.contextDimension * e / 100))), d.offset = f - b.contextOffset + b.contextScroll - e, d.options.onlyOnScroll && null != g || !d.enabled ? void 0 : null !== g && g < (h = b.oldScroll) && h <= d.offset ? d.trigger([b.backward]) : null !== g && g > (i = b.oldScroll) && i >= d.offset ? d.trigger([b.forward]) : null === g && b.oldScroll >= d.offset ? d.trigger([b.forward]) : void 0
  1945. })
  1946. })
  1947. }, a.prototype.checkEmpty = function () {
  1948. return c.isEmptyObject(this.waypoints.horizontal) && c.isEmptyObject(this.waypoints.vertical) ? (this.$element.unbind([o, p].join(" ")), delete k[this.id]) : void 0
  1949. }, a
  1950. }(), g = function () {
  1951. function a(a, b, d) {
  1952. var e, f;
  1953. d = c.extend({}, c.fn[s].defaults, d), "bottom-in-view" === d.offset && (d.offset = function () {
  1954. var a;
  1955. return a = c[t]("viewportHeight"), c.isWindow(b.element) || (a = b.$element.height()), a - c(this).outerHeight()
  1956. }), this.$element = a, this.element = a[0], this.axis = d.horizontal ? "horizontal" : "vertical", this.callback = d.handler, this.context = b, this.enabled = d.enabled, this.id = "waypoints" + q++, this.offset = null, this.options = d, b.waypoints[this.axis][this.id] = this, h[this.axis][this.id] = this, e = null != (f = a.data(r)) ? f : [], e.push(this.id), a.data(r, e)
  1957. }
  1958.  
  1959. return a.prototype.trigger = function (a) {
  1960. return this.enabled ? (null != this.callback && this.callback.apply(this.element, a), this.options.triggerOnce ? this.destroy() : void 0) : void 0
  1961. }, a.prototype.disable = function () {
  1962. return this.enabled = !1
  1963. }, a.prototype.enable = function () {
  1964. return this.context.refresh(), this.enabled = !0
  1965. }, a.prototype.destroy = function () {
  1966. return delete h[this.axis][this.id], delete this.context.waypoints[this.axis][this.id], this.context.checkEmpty()
  1967. }, a.getWaypointsByElement = function (a) {
  1968. var b, d;
  1969. return (d = c(a).data(r)) ? (b = c.extend({}, h.horizontal, h.vertical), c.map(d, function (a) {
  1970. return b[a]
  1971. })) : []
  1972. }, a
  1973. }(), n = {
  1974. init: function (a, b) {
  1975. var d;
  1976. return null == b && (b = {}), null == (d = b.handler) && (b.handler = a), this.each(function () {
  1977. var a, d, e, h;
  1978. return a = c(this), e = null != (h = b.context) ? h : c.fn[s].defaults.context, c.isWindow(e) || (e = a.closest(e)), e = c(e), d = k[e.data(j)], d || (d = new f(e)), new g(a, d, b)
  1979. }), c[t]("refresh"), this
  1980. }, disable: function () {
  1981. return n._invoke(this, "disable")
  1982. }, enable: function () {
  1983. return n._invoke(this, "enable")
  1984. }, destroy: function () {
  1985. return n._invoke(this, "destroy")
  1986. }, prev: function (a, b) {
  1987. return n._traverse.call(this, a, b, function (a, b, c) {
  1988. return b > 0 ? a.push(c[b - 1]) : void 0
  1989. })
  1990. }, next: function (a, b) {
  1991. return n._traverse.call(this, a, b, function (a, b, c) {
  1992. return b < c.length - 1 ? a.push(c[b + 1]) : void 0
  1993. })
  1994. }, _traverse: function (a, b, e) {
  1995. var f, g;
  1996. return null == a && (a = "vertical"), null == b && (b = d), g = m.aggregate(b), f = [], this.each(function () {
  1997. var b;
  1998. return b = c.inArray(this, g[a]), e(f, b, g[a])
  1999. }), this.pushStack(f)
  2000. }, _invoke: function (a, b) {
  2001. return a.each(function () {
  2002. var a;
  2003. return a = g.getWaypointsByElement(this), c.each(a, function (a, c) {
  2004. return c[b](), !0
  2005. })
  2006. }), this
  2007. }
  2008. }, c.fn[s] = function () {
  2009. var a, d;
  2010. return d = arguments[0], a = 2 <= arguments.length ? b.call(arguments, 1) : [], n[d] ? n[d].apply(this, a) : c.isFunction(d) ? n.init.apply(this, arguments) : c.isPlainObject(d) ? n.init.apply(this, [null, d]) : d ? c.error("The " + d + " method does not exist in jQuery Waypoints.") : c.error("jQuery Waypoints needs a callback function or handler option.")
  2011. }, c.fn[s].defaults = {
  2012. context: d,
  2013. continuous: !0,
  2014. enabled: !0,
  2015. horizontal: !1,
  2016. offset: 0,
  2017. triggerOnce: !1
  2018. }, m = {
  2019. refresh: function () {
  2020. return c.each(k, function (a, b) {
  2021. return b.refresh()
  2022. })
  2023. }, viewportHeight: function () {
  2024. var a;
  2025. return null != (a = d.innerHeight) ? a : e.height()
  2026. }, aggregate: function (a) {
  2027. var b, d, e;
  2028. return b = h, a && (b = null != (e = k[c(a).data(j)]) ? e.waypoints : void 0), b ? (d = {
  2029. horizontal: [],
  2030. vertical: []
  2031. }, c.each(d, function (a, e) {
  2032. return c.each(b[a], function (a, b) {
  2033. return e.push(b)
  2034. }), e.sort(function (a, b) {
  2035. return a.offset - b.offset
  2036. }), d[a] = c.map(e, function (a) {
  2037. return a.element
  2038. }), d[a] = c.unique(d[a])
  2039. }), d) : []
  2040. }, above: function (a) {
  2041. return null == a && (a = d), m._filter(a, "vertical", function (a, b) {
  2042. return b.offset <= a.oldScroll.y
  2043. })
  2044. }, below: function (a) {
  2045. return null == a && (a = d), m._filter(a, "vertical", function (a, b) {
  2046. return b.offset > a.oldScroll.y
  2047. })
  2048. }, left: function (a) {
  2049. return null == a && (a = d), m._filter(a, "horizontal", function (a, b) {
  2050. return b.offset <= a.oldScroll.x
  2051. })
  2052. }, right: function (a) {
  2053. return null == a && (a = d), m._filter(a, "horizontal", function (a, b) {
  2054. return b.offset > a.oldScroll.x
  2055. })
  2056. }, enable: function () {
  2057. return m._invoke("enable")
  2058. }, disable: function () {
  2059. return m._invoke("disable")
  2060. }, destroy: function () {
  2061. return m._invoke("destroy")
  2062. }, extendFn: function (a, b) {
  2063. return n[a] = b
  2064. }, _invoke: function (a) {
  2065. var b;
  2066. return b = c.extend({}, h.vertical, h.horizontal), c.each(b, function (b, c) {
  2067. return c[a](), !0
  2068. })
  2069. }, _filter: function (a, b, d) {
  2070. var e, f;
  2071. return (e = k[c(a).data(j)]) ? (f = [], c.each(e.waypoints[b], function (a, b) {
  2072. return d(e, b) ? f.push(b) : void 0
  2073. }), f.sort(function (a, b) {
  2074. return a.offset - b.offset
  2075. }), c.map(f, function (a) {
  2076. return a.element
  2077. })) : []
  2078. }
  2079. }, c[t] = function () {
  2080. var a, c;
  2081. return c = arguments[0], a = 2 <= arguments.length ? b.call(arguments, 1) : [], m[c] ? m[c].apply(null, a) : m.aggregate.call(null, c)
  2082. }, c[t].settings = {resizeThrottle: 100, scrollThrottle: 30}, e.load(function () {
  2083. return c[t]("refresh")
  2084. })
  2085. })
  2086. }.call(this), function () {
  2087. !function (a, b) {
  2088. return "function" == typeof define && define.amd ? define(["jquery", "waypoints"], b) : b(a.jQuery)
  2089. }(this, function (a) {
  2090. var b, c;
  2091. return b = {wrapper: '<div class="sticky-wrapper" />', stuckClass: "stuck"}, c = function (a, b) {
  2092. return a.wrap(b.wrapper), a.parent()
  2093. }, a.waypoints("extendFn", "sticky", function (d) {
  2094. var e, f, g;
  2095. return f = a.extend({}, a.fn.waypoint.defaults, b, d), e = c(this, f), g = f.handler, f.handler = function (b) {
  2096. var c, d;
  2097. return c = a(this).children(":first"), d = "down" === b || "right" === b, c.toggleClass(f.stuckClass, d), e.height(d ? c.outerHeight() : ""), null != g ? g.call(this, b) : void 0
  2098. }, e.waypoint(f), this.data("stuckClass", f.stuckClass)
  2099. }), a.waypoints("extendFn", "unsticky", function () {
  2100. return this.parent().waypoint("destroy"), this.unwrap(), this.removeClass(this.data("stuckClass"))
  2101. })
  2102. })
  2103. }.call(this), function (a, b) {
  2104. function c(b, c) {
  2105. this.element = b, this.$element = a(b), this.options = a.extend(!0, {}, e, c), this._defaults = e, this._name = d, this.init(), this.bind(), this.draw()
  2106. }
  2107.  
  2108. var d = "lines", e = {
  2109. direction: "up",
  2110. isMobile: !1,
  2111. color: {top: "rgba(0, 0, 0, 0)", bottom: "rgba(0, 0, 0, 0)"},
  2112. shadow: {type: "outer", color: {R: 0, G: 0, B: 0}, opacity: .3, height: 20}
  2113. };
  2114. c.prototype.init = function () {
  2115. var a = this.element, b = this.$element.parent();
  2116. if (a.width = b.width(), a.getContext) {
  2117. var c = a.getContext("2d");
  2118. this.ctx = c;
  2119. var d = this.$element.data("top-color");
  2120. "undefined" != typeof d && "" !== d && (this.options.color.top = d);
  2121. var e = this.$element.data("bottom-color");
  2122. "undefined" != typeof e && "" !== e && (this.options.color.bottom = e)
  2123. }
  2124. }, c.prototype.bind = function () {
  2125. var a = this, c = this.element, d = this.$element.parent(), e = this.options.isMobile;
  2126. e ? b.addEventListener("orientationchange", function () {
  2127. c.width = d.width(), devicePixelRatio > 1 && (c.height = 70), a.draw()
  2128. }, !1) : b.attachEvent ? b.attachEvent("onresize", function () {
  2129. c.width = d.width(), a.draw()
  2130. }) : b.addEventListener && b.addEventListener("resize", function () {
  2131. c.width = d.width(), a.draw()
  2132. }, !1)
  2133. }, c.prototype.draw = function () {
  2134. var a = this.options.isMobile, c = this.element, d = this.ctx, e = parseInt(this.$element.attr("height"), 10), g = parseInt(this.$element.attr("width"), 10);
  2135. if ("undefined" != typeof d) {
  2136. if (a && (devicePixelRatio = b.devicePixelRatio || 1, backingStoreRatio = d.webkitBackingStorePixelRatio || d.mozBackingStorePixelRatio || d.msBackingStorePixelRatio || d.oBackingStorePixelRatio || d.backingStorePixelRatio || 1, ratio = devicePixelRatio / backingStoreRatio, devicePixelRatio !== backingStoreRatio)) {
  2137. var i = g, j = e;
  2138. c.width = i * ratio, c.height = j * ratio, c.style.width = i + "px", c.style.height = j + "px", d.scale(ratio, ratio)
  2139. }
  2140. var k = h(g, e), l = this.options.shadow.height, m = "up" === this.options.direction ? -1 : 1, n = this.options.color.top, o = this.options.color.bottom, p = {
  2141. color: n,
  2142. x: -k,
  2143. y: -e / 2,
  2144. w: g + 2 * k,
  2145. h: e
  2146. }, q = {color: o, x: -k, y: e / 2, w: g + 2 * k, h: e};
  2147. d.translate(g / 2, e / 2), d.rotate(m * Math.atan((e - 2 * l) / g)), d.translate(-g / 2, -e / 2), "transparent" !== n && (d.fillStyle = p.color, d.fillRect(p.x, p.y, p.w, p.h)), "transparent" !== o && (d.fillStyle = q.color, d.fillRect(q.x, q.y, q.w, q.h)), f(d, e, g, k, this.options.shadow)
  2148. }
  2149. };
  2150. var f = function (a, b, c, d, e) {
  2151. var f = 0, h = a.createLinearGradient(0, 0, 0, e.height);
  2152. "inner" === e.type ? (f = e.height, h.addColorStop(0, g(e.color, 0)), h.addColorStop(1, g(e.color, e.opacity))) : (f = 0, h.addColorStop(0, g(e.color, e.opacity)), h.addColorStop(1, g(e.color, 0))), a.save(), a.translate(0, b / 2 - f), a.fillStyle = h, a.fillRect(-d, 0, c + 2 * d, e.height), a.restore()
  2153. }, g = function (a, b) {
  2154. return "rgba(" + a.R + ", " + a.G + ", " + a.B + ", " + b + ")"
  2155. }, h = function () {
  2156. return 50
  2157. };
  2158. a.fn[d] = function (b) {
  2159. return this.each(function () {
  2160. a.data(this, "plugin_" + d) || a.data(this, "plugin_" + d, new c(this, b))
  2161. })
  2162. }
  2163. }(jQuery, window, document), function (a) {
  2164. a.fn.hoverIntent = function (b, c, d) {
  2165. var e = {interval: 100, sensitivity: 7, timeout: 0};
  2166. e = "object" == typeof b ? a.extend(e, b) : a.isFunction(c) ? a.extend(e, {
  2167. over: b,
  2168. out: c,
  2169. selector: d
  2170. }) : a.extend(e, {over: b, out: b, selector: c});
  2171. var f, g, h, i, j = function (a) {
  2172. f = a.pageX, g = a.pageY
  2173. }, k = function (b, c) {
  2174. return c.hoverIntent_t = clearTimeout(c.hoverIntent_t), Math.abs(h - f) + Math.abs(i - g) < e.sensitivity ? (a(c).off("mousemove.hoverIntent", j), c.hoverIntent_s = 1, e.over.apply(c, [b])) : (h = f, i = g, c.hoverIntent_t = setTimeout(function () {
  2175. k(b, c)
  2176. }, e.interval), void 0)
  2177. }, l = function (a, b) {
  2178. return b.hoverIntent_t = clearTimeout(b.hoverIntent_t), b.hoverIntent_s = 0, e.out.apply(b, [a])
  2179. }, m = function (b) {
  2180. var c = jQuery.extend({}, b), d = this;
  2181. d.hoverIntent_t && (d.hoverIntent_t = clearTimeout(d.hoverIntent_t)), "mouseenter" == b.type ? (h = c.pageX, i = c.pageY, a(d).on("mousemove.hoverIntent", j), 1 != d.hoverIntent_s && (d.hoverIntent_t = setTimeout(function () {
  2182. k(c, d)
  2183. }, e.interval))) : (a(d).off("mousemove.hoverIntent", j), 1 == d.hoverIntent_s && (d.hoverIntent_t = setTimeout(function () {
  2184. l(c, d)
  2185. }, e.timeout)))
  2186. };
  2187. return this.on({"mouseenter.hoverIntent": m, "mouseleave.hoverIntent": m}, e.selector)
  2188. }
  2189. }(jQuery), jQuery(function (a) {
  2190. function b() {
  2191. var b = a("script:first"), c = b.css("color"), d = !1;
  2192. if (/^rgba/.test(c))d = !0; else try {
  2193. d = c !== b.css("color", "rgba(0, 0, 0, 0.5)").css("color"), b.css("color", c)
  2194. } catch (e) {
  2195. }
  2196. return b.removeAttr("style"), d
  2197. }
  2198.  
  2199. function c(b, c, d) {
  2200. var e = [];
  2201. return a.each(b, function (f) {
  2202. var g = [], h = b[f], i = c[f];
  2203. if (h.inset && g.push("inset"), "undefined" != typeof i.left && g.push(parseFloat(h.left + d * (i.left - h.left)) + "px " + parseFloat(h.top + d * (i.top - h.top)) + "px"), "undefined" != typeof i.blur && g.push(parseFloat(h.blur + d * (i.blur - h.blur)) + "px"), "undefined" != typeof i.spread && g.push(parseFloat(h.spread + d * (i.spread - h.spread)) + "px"), "undefined" != typeof i.color) {
  2204. var j = "rgb" + (a.support.rgba ? "a" : "") + "(" + parseInt(h.color[0] + d * (i.color[0] - h.color[0]), 10) + "," + parseInt(h.color[1] + d * (i.color[1] - h.color[1]), 10) + "," + parseInt(h.color[2] + d * (i.color[2] - h.color[2]), 10);
  2205. a.support.rgba && (j += "," + parseFloat(h.color[3] + d * (i.color[3] - h.color[3]))), j += ")", g.push(j)
  2206. }
  2207. e.push(g.join(" "))
  2208. }), e.join(", ")
  2209. }
  2210.  
  2211. function d(b) {
  2212. function c() {
  2213. var a = /^inset\b/.exec(b.substring(j));
  2214. return null !== a && a.length > 0 ? (l.inset = !0, j += a[0].length, !0) : !1
  2215. }
  2216.  
  2217. function d() {
  2218. var a = /^(-?[0-9\.]+)(?:px)?\s+(-?[0-9\.]+)(?:px)?(?:\s+(-?[0-9\.]+)(?:px)?)?(?:\s+(-?[0-9\.]+)(?:px)?)?/.exec(b.substring(j));
  2219. return null !== a && a.length > 0 ? (l.left = parseInt(a[1], 10), l.top = parseInt(a[2], 10), l.blur = a[3] ? parseInt(a[3], 10) : 0, l.spread = a[4] ? parseInt(a[4], 10) : 0, j += a[0].length, !0) : !1
  2220. }
  2221.  
  2222. function e() {
  2223. var a = /^#([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})/.exec(b.substring(j));
  2224. return null !== a && a.length > 0 ? (l.color = [parseInt(a[1], 16), parseInt(a[2], 16), parseInt(a[3], 16), 1], j += a[0].length, !0) : (a = /^#([0-9a-fA-F])([0-9a-fA-F])([0-9a-fA-F])/.exec(b.substring(j)), null !== a && a.length > 0 ? (l.color = [17 * parseInt(a[1], 16), 17 * parseInt(a[2], 16), 17 * parseInt(a[3], 16), 1], j += a[0].length, !0) : (a = /^rgb\(\s*([0-9\.]+)\s*,\s*([0-9\.]+)\s*,\s*([0-9\.]+)\s*\)/.exec(b.substring(j)), null !== a && a.length > 0 ? (l.color = [parseInt(a[1], 10), parseInt(a[2], 10), parseInt(a[3], 10), 1], j += a[0].length, !0) : (a = /^rgba\(\s*([0-9\.]+)\s*,\s*([0-9\.]+)\s*,\s*([0-9\.]+)\s*,\s*([0-9\.]+)\s*\)/.exec(b.substring(j)), null !== a && a.length > 0 ? (l.color = [parseInt(a[1], 10), parseInt(a[2], 10), parseInt(a[3], 10), parseFloat(a[4])], j += a[0].length, !0) : !1)))
  2225. }
  2226.  
  2227. function f() {
  2228. var a = /^\s+/.exec(b.substring(j));
  2229. return null !== a && a.length > 0 ? (j += a[0].length, !0) : !1
  2230. }
  2231.  
  2232. function g() {
  2233. var a = /^\s*,\s*/.exec(b.substring(j));
  2234. return null !== a && a.length > 0 ? (j += a[0].length, !0) : !1
  2235. }
  2236.  
  2237. function h(b) {
  2238. if (a.isPlainObject(b)) {
  2239. var c, d, e = 0, f = [];
  2240. for (a.isArray(b.color) && (d = b.color, e = d.length), c = 0; 4 > c; c++)e > c ? f.push(d[c]) : 3 === c ? f.push(1) : f.push(0)
  2241. }
  2242. return a.extend({left: 0, top: 0, blur: 0, spread: 0}, b)
  2243. }
  2244.  
  2245. for (var i = [], j = 0, k = b.length, l = h(); k > j;)if (c())f(); else if (d())f(); else if (e())f(); else {
  2246. if (!g())break;
  2247. i.push(h(l)), l = {}
  2248. }
  2249. return i.push(h(l)), i
  2250. }
  2251.  
  2252. a.extend(!0, a, {support: {rgba: b()}});
  2253. var e, f = a("html").prop("style");
  2254. a.each(["boxShadow", "MozBoxShadow", "WebkitBoxShadow"], function (a, b) {
  2255. var c = f[b];
  2256. return "undefined" != typeof c ? (e = b, !1) : void 0
  2257. }), e && (a.Tween.propHooks.boxShadow = {
  2258. get: function (b) {
  2259. return a(b.elem).css(e)
  2260. }, set: function (b) {
  2261. var f, g = b.elem.style, h = d(a(b.elem)[0].style[e] || a(b.elem).css(e)), i = d(b.end), j = Math.max(h.length, i.length);
  2262. for (f = 0; j > f; f++)i[f] = a.extend({}, h[f], i[f]), h[f] ? "color"in h[f] && a.isArray(h[f].color) !== !1 || (h[f].color = i[f].color || [0, 0, 0, 0]) : h[f] = d("0 0 0 0 rgba(0,0,0,0)")[0];
  2263. b.run = function (a) {
  2264. var b = c(h, i, a);
  2265. g[e] = b
  2266. }
  2267. }
  2268. })
  2269. }), jQuery.easing.jswing = jQuery.easing.swing, jQuery.extend(jQuery.easing, {
  2270. def: "easeOutQuad",
  2271. swing: function (a, b, c, d, e) {
  2272. return jQuery.easing[jQuery.easing.def](a, b, c, d, e)
  2273. },
  2274. easeInQuad: function (a, b, c, d, e) {
  2275. return d * (b /= e) * b + c
  2276. },
  2277. easeOutQuad: function (a, b, c, d, e) {
  2278. return -d * (b /= e) * (b - 2) + c
  2279. },
  2280. easeInOutQuad: function (a, b, c, d, e) {
  2281. return (b /= e / 2) < 1 ? d / 2 * b * b + c : -d / 2 * (--b * (b - 2) - 1) + c
  2282. },
  2283. easeInCubic: function (a, b, c, d, e) {
  2284. return d * (b /= e) * b * b + c
  2285. },
  2286. easeOutCubic: function (a, b, c, d, e) {
  2287. return d * ((b = b / e - 1) * b * b + 1) + c
  2288. },
  2289. easeInOutCubic: function (a, b, c, d, e) {
  2290. return (b /= e / 2) < 1 ? d / 2 * b * b * b + c : d / 2 * ((b -= 2) * b * b + 2) + c
  2291. },
  2292. easeInQuart: function (a, b, c, d, e) {
  2293. return d * (b /= e) * b * b * b + c
  2294. },
  2295. easeOutQuart: function (a, b, c, d, e) {
  2296. return -d * ((b = b / e - 1) * b * b * b - 1) + c
  2297. },
  2298. easeInOutQuart: function (a, b, c, d, e) {
  2299. return (b /= e / 2) < 1 ? d / 2 * b * b * b * b + c : -d / 2 * ((b -= 2) * b * b * b - 2) + c
  2300. },
  2301. easeInQuint: function (a, b, c, d, e) {
  2302. return d * (b /= e) * b * b * b * b + c
  2303. },
  2304. easeOutQuint: function (a, b, c, d, e) {
  2305. return d * ((b = b / e - 1) * b * b * b * b + 1) + c
  2306. },
  2307. easeInOutQuint: function (a, b, c, d, e) {
  2308. return (b /= e / 2) < 1 ? d / 2 * b * b * b * b * b + c : d / 2 * ((b -= 2) * b * b * b * b + 2) + c
  2309. },
  2310. easeInSine: function (a, b, c, d, e) {
  2311. return -d * Math.cos(b / e * (Math.PI / 2)) + d + c
  2312. },
  2313. easeOutSine: function (a, b, c, d, e) {
  2314. return d * Math.sin(b / e * (Math.PI / 2)) + c
  2315. },
  2316. easeInOutSine: function (a, b, c, d, e) {
  2317. return -d / 2 * (Math.cos(Math.PI * b / e) - 1) + c
  2318. },
  2319. easeInExpo: function (a, b, c, d, e) {
  2320. return 0 == b ? c : d * Math.pow(2, 10 * (b / e - 1)) + c
  2321. },
  2322. easeOutExpo: function (a, b, c, d, e) {
  2323. return b == e ? c + d : d * (-Math.pow(2, -10 * b / e) + 1) + c
  2324. },
  2325. easeInOutExpo: function (a, b, c, d, e) {
  2326. return 0 == b ? c : b == e ? c + d : (b /= e / 2) < 1 ? d / 2 * Math.pow(2, 10 * (b - 1)) + c : d / 2 * (-Math.pow(2, -10 * --b) + 2) + c
  2327. },
  2328. easeInCirc: function (a, b, c, d, e) {
  2329. return -d * (Math.sqrt(1 - (b /= e) * b) - 1) + c
  2330. },
  2331. easeOutCirc: function (a, b, c, d, e) {
  2332. return d * Math.sqrt(1 - (b = b / e - 1) * b) + c
  2333. },
  2334. easeInOutCirc: function (a, b, c, d, e) {
  2335. return (b /= e / 2) < 1 ? -d / 2 * (Math.sqrt(1 - b * b) - 1) + c : d / 2 * (Math.sqrt(1 - (b -= 2) * b) + 1) + c
  2336. },
  2337. easeInElastic: function (a, b, c, d, e) {
  2338. var f = 1.70158, g = 0, h = d;
  2339. if (0 == b)return c;
  2340. if (1 == (b /= e))return c + d;
  2341. if (g || (g = .3 * e), h < Math.abs(d)) {
  2342. h = d;
  2343. var f = g / 4
  2344. } else var f = g / (2 * Math.PI) * Math.asin(d / h);
  2345. return -(h * Math.pow(2, 10 * (b -= 1)) * Math.sin(2 * (b * e - f) * Math.PI / g)) + c
  2346. },
  2347. easeOutElastic: function (a, b, c, d, e) {
  2348. var f = 1.70158, g = 0, h = d;
  2349. if (0 == b)return c;
  2350. if (1 == (b /= e))return c + d;
  2351. if (g || (g = .3 * e), h < Math.abs(d)) {
  2352. h = d;
  2353. var f = g / 4
  2354. } else var f = g / (2 * Math.PI) * Math.asin(d / h);
  2355. return h * Math.pow(2, -10 * b) * Math.sin(2 * (b * e - f) * Math.PI / g) + d + c
  2356. },
  2357. easeInOutElastic: function (a, b, c, d, e) {
  2358. var f = 1.70158, g = 0, h = d;
  2359. if (0 == b)return c;
  2360. if (2 == (b /= e / 2))return c + d;
  2361. if (g || (g = .3 * e * 1.5), h < Math.abs(d)) {
  2362. h = d;
  2363. var f = g / 4
  2364. } else var f = g / (2 * Math.PI) * Math.asin(d / h);
  2365. return 1 > b ? -.5 * h * Math.pow(2, 10 * (b -= 1)) * Math.sin(2 * (b * e - f) * Math.PI / g) + c : h * Math.pow(2, -10 * (b -= 1)) * Math.sin(2 * (b * e - f) * Math.PI / g) * .5 + d + c
  2366. },
  2367. easeInBack: function (a, b, c, d, e, f) {
  2368. return void 0 == f && (f = 1.70158), d * (b /= e) * b * ((f + 1) * b - f) + c
  2369. },
  2370. easeOutBack: function (a, b, c, d, e, f) {
  2371. return void 0 == f && (f = 1.70158), d * ((b = b / e - 1) * b * ((f + 1) * b + f) + 1) + c
  2372. },
  2373. easeInOutBack: function (a, b, c, d, e, f) {
  2374. return void 0 == f && (f = 1.70158), (b /= e / 2) < 1 ? d / 2 * b * b * (((f *= 1.525) + 1) * b - f) + c : d / 2 * ((b -= 2) * b * (((f *= 1.525) + 1) * b + f) + 2) + c
  2375. },
  2376. easeInBounce: function (a, b, c, d, e) {
  2377. return d - jQuery.easing.easeOutBounce(a, e - b, 0, d, e) + c
  2378. },
  2379. easeOutBounce: function (a, b, c, d, e) {
  2380. return (b /= e) < 1 / 2.75 ? 7.5625 * d * b * b + c : 2 / 2.75 > b ? d * (7.5625 * (b -= 1.5 / 2.75) * b + .75) + c : 2.5 / 2.75 > b ? d * (7.5625 * (b -= 2.25 / 2.75) * b + .9375) + c : d * (7.5625 * (b -= 2.625 / 2.75) * b + .984375) + c
  2381. },
  2382. easeInOutBounce: function (a, b, c, d, e) {
  2383. return e / 2 > b ? .5 * jQuery.easing.easeInBounce(a, 2 * b, 0, d, e) + c : .5 * jQuery.easing.easeOutBounce(a, 2 * b - e, 0, d, e) + .5 * d + c
  2384. }
  2385. });
  2386. var requirejs, require, define;
  2387. !function (global) {
  2388. function isFunction(a) {
  2389. return "[object Function]" === ostring.call(a)
  2390. }
  2391.  
  2392. function isArray(a) {
  2393. return "[object Array]" === ostring.call(a)
  2394. }
  2395.  
  2396. function each(a, b) {
  2397. if (a) {
  2398. var c;
  2399. for (c = 0; c < a.length && (!a[c] || !b(a[c], c, a)); c += 1);
  2400. }
  2401. }
  2402.  
  2403. function eachReverse(a, b) {
  2404. if (a) {
  2405. var c;
  2406. for (c = a.length - 1; c > -1 && (!a[c] || !b(a[c], c, a)); c -= 1);
  2407. }
  2408. }
  2409.  
  2410. function hasProp(a, b) {
  2411. return hasOwn.call(a, b)
  2412. }
  2413.  
  2414. function getOwn(a, b) {
  2415. return hasProp(a, b) && a[b]
  2416. }
  2417.  
  2418. function eachProp(a, b) {
  2419. var c;
  2420. for (c in a)if (hasProp(a, c) && b(a[c], c))break
  2421. }
  2422.  
  2423. function mixin(a, b, c, d) {
  2424. return b && eachProp(b, function (b, e) {
  2425. (c || !hasProp(a, e)) && (d && "string" != typeof b ? (a[e] || (a[e] = {}), mixin(a[e], b, c, d)) : a[e] = b)
  2426. }), a
  2427. }
  2428.  
  2429. function bind(a, b) {
  2430. return function () {
  2431. return b.apply(a, arguments)
  2432. }
  2433. }
  2434.  
  2435. function scripts() {
  2436. return document.getElementsByTagName("script")
  2437. }
  2438.  
  2439. function defaultOnError(a) {
  2440. throw a
  2441. }
  2442.  
  2443. function getGlobal(a) {
  2444. if (!a)return a;
  2445. var b = global;
  2446. return each(a.split("."), function (a) {
  2447. b = b[a]
  2448. }), b
  2449. }
  2450.  
  2451. function makeError(a, b, c, d) {
  2452. var e = new Error(b + "\nhttp://requirejs.org/docs/errors.html#" + a);
  2453. return e.requireType = a, e.requireModules = d, c && (e.originalError = c), e
  2454. }
  2455.  
  2456. function newContext(a) {
  2457. function b(a) {
  2458. var b, c;
  2459. for (b = 0; a[b]; b += 1)if (c = a[b], "." === c)a.splice(b, 1), b -= 1; else if (".." === c) {
  2460. if (1 === b && (".." === a[2] || ".." === a[0]))break;
  2461. b > 0 && (a.splice(b - 1, 2), b -= 2)
  2462. }
  2463. }
  2464.  
  2465. function c(a, c, d) {
  2466. var e, f, g, h, i, j, k, l, m, n, o, p = c && c.split("/"), q = p, r = x.map, s = r && r["*"];
  2467. if (a && "." === a.charAt(0) && (c ? (q = getOwn(x.pkgs, c) ? p = [c] : p.slice(0, p.length - 1), a = q.concat(a.split("/")), b(a), f = getOwn(x.pkgs, e = a[0]), a = a.join("/"), f && a === e + "/" + f.main && (a = e)) : 0 === a.indexOf("./") && (a = a.substring(2))), d && r && (p || s)) {
  2468. for (h = a.split("/"), i = h.length; i > 0; i -= 1) {
  2469. if (k = h.slice(0, i).join("/"), p)for (j = p.length; j > 0; j -= 1)if (g = getOwn(r, p.slice(0, j).join("/")), g && (g = getOwn(g, k))) {
  2470. l = g, m = i;
  2471. break
  2472. }
  2473. if (l)break;
  2474. !n && s && getOwn(s, k) && (n = getOwn(s, k), o = i)
  2475. }
  2476. !l && n && (l = n, m = o), l && (h.splice(0, m, l), a = h.join("/"))
  2477. }
  2478. return a
  2479. }
  2480.  
  2481. function d(a) {
  2482. isBrowser && each(scripts(), function (b) {
  2483. return b.getAttribute("data-requiremodule") === a && b.getAttribute("data-requirecontext") === u.contextName ? (b.parentNode.removeChild(b), !0) : void 0
  2484. })
  2485. }
  2486.  
  2487. function e(a) {
  2488. var b = getOwn(x.paths, a);
  2489. return b && isArray(b) && b.length > 1 ? (d(a), b.shift(), u.require.undef(a), u.require([a]), !0) : void 0
  2490. }
  2491.  
  2492. function f(a) {
  2493. var b, c = a ? a.indexOf("!") : -1;
  2494. return c > -1 && (b = a.substring(0, c), a = a.substring(c + 1, a.length)), [b, a]
  2495. }
  2496.  
  2497. function g(a, b, d, e) {
  2498. var g, h, i, j, k = null, l = b ? b.name : null, m = a, n = !0, o = "";
  2499. return a || (n = !1, a = "_@r" + (E += 1)), j = f(a), k = j[0], a = j[1], k && (k = c(k, l, e), h = getOwn(C, k)), a && (k ? o = h && h.normalize ? h.normalize(a, function (a) {
  2500. return c(a, l, e)
  2501. }) : c(a, l, e) : (o = c(a, l, e), j = f(o), k = j[0], o = j[1], d = !0, g = u.nameToUrl(o))), i = !k || h || d ? "" : "_unnormalized" + (F += 1), {
  2502. prefix: k,
  2503. name: o,
  2504. parentMap: b,
  2505. unnormalized: !!i,
  2506. url: g,
  2507. originalName: m,
  2508. isDefine: n,
  2509. id: (k ? k + "!" + o : o) + i
  2510. }
  2511. }
  2512.  
  2513. function h(a) {
  2514. var b = a.id, c = getOwn(y, b);
  2515. return c || (c = y[b] = new u.Module(a)), c
  2516. }
  2517.  
  2518. function i(a, b, c) {
  2519. var d = a.id, e = getOwn(y, d);
  2520. !hasProp(C, d) || e && !e.defineEmitComplete ? (e = h(a), e.error && "error" === b ? c(e.error) : e.on(b, c)) : "defined" === b && c(C[d])
  2521. }
  2522.  
  2523. function j(a, b) {
  2524. var c = a.requireModules, d = !1;
  2525. b ? b(a) : (each(c, function (b) {
  2526. var c = getOwn(y, b);
  2527. c && (c.error = a, c.events.error && (d = !0, c.emit("error", a)))
  2528. }), d || req.onError(a))
  2529. }
  2530.  
  2531. function k() {
  2532. globalDefQueue.length && (apsp.apply(B, [B.length - 1, 0].concat(globalDefQueue)), globalDefQueue = [])
  2533. }
  2534.  
  2535. function l(a) {
  2536. delete y[a], delete z[a]
  2537. }
  2538.  
  2539. function m(a, b, c) {
  2540. var d = a.map.id;
  2541. a.error ? a.emit("error", a.error) : (b[d] = !0, each(a.depMaps, function (d, e) {
  2542. var f = d.id, g = getOwn(y, f);
  2543. !g || a.depMatched[e] || c[f] || (getOwn(b, f) ? (a.defineDep(e, C[f]), a.check()) : m(g, b, c))
  2544. }), c[d] = !0)
  2545. }
  2546.  
  2547. function n() {
  2548. var a, b, c, f, g = 1e3 * x.waitSeconds, h = g && u.startTime + g < (new Date).getTime(), i = [], k = [], l = !1, o = !0;
  2549. if (!s) {
  2550. if (s = !0, eachProp(z, function (c) {
  2551. if (a = c.map, b = a.id, c.enabled && (a.isDefine || k.push(c), !c.error))if (!c.inited && h)e(b) ? (f = !0, l = !0) : (i.push(b), d(b)); else if (!c.inited && c.fetched && a.isDefine && (l = !0, !a.prefix))return o = !1
  2552. }), h && i.length)return c = makeError("timeout", "Load timeout for modules: " + i, null, i), c.contextName = u.contextName, j(c);
  2553. o && each(k, function (a) {
  2554. m(a, {}, {})
  2555. }), h && !f || !l || !isBrowser && !isWebWorker || w || (w = setTimeout(function () {
  2556. w = 0, n()
  2557. }, 50)), s = !1
  2558. }
  2559. }
  2560.  
  2561. function o(a) {
  2562. hasProp(C, a[0]) || h(g(a[0], null, !0)).init(a[1], a[2])
  2563. }
  2564.  
  2565. function p(a, b, c, d) {
  2566. a.detachEvent && !isOpera ? d && a.detachEvent(d, b) : a.removeEventListener(c, b, !1)
  2567. }
  2568.  
  2569. function q(a) {
  2570. var b = a.currentTarget || a.srcElement;
  2571. return p(b, u.onScriptLoad, "load", "onreadystatechange"), p(b, u.onScriptError, "error"), {
  2572. node: b,
  2573. id: b && b.getAttribute("data-requiremodule")
  2574. }
  2575. }
  2576.  
  2577. function r() {
  2578. var a;
  2579. for (k(); B.length;) {
  2580. if (a = B.shift(), null === a[0])return j(makeError("mismatch", "Mismatched anonymous define() module: " + a[a.length - 1]));
  2581. o(a)
  2582. }
  2583. }
  2584.  
  2585. var s, t, u, v, w, x = {
  2586. waitSeconds: 7,
  2587. baseUrl: "./",
  2588. paths: {},
  2589. pkgs: {},
  2590. shim: {},
  2591. config: {}
  2592. }, y = {}, z = {}, A = {}, B = [], C = {}, D = {}, E = 1, F = 1;
  2593. return v = {
  2594. require: function (a) {
  2595. return a.require ? a.require : a.require = u.makeRequire(a.map)
  2596. }, exports: function (a) {
  2597. return a.usingExports = !0, a.map.isDefine ? a.exports ? a.exports : a.exports = C[a.map.id] = {} : void 0
  2598. }, module: function (a) {
  2599. return a.module ? a.module : a.module = {
  2600. id: a.map.id, uri: a.map.url, config: function () {
  2601. var b, c = getOwn(x.pkgs, a.map.id);
  2602. return b = c ? getOwn(x.config, a.map.id + "/" + c.main) : getOwn(x.config, a.map.id), b || {}
  2603. }, exports: C[a.map.id]
  2604. }
  2605. }
  2606. }, t = function (a) {
  2607. this.events = getOwn(A, a.id) || {}, this.map = a, this.shim = getOwn(x.shim, a.id), this.depExports = [], this.depMaps = [], this.depMatched = [], this.pluginMaps = {}, this.depCount = 0
  2608. }, t.prototype = {
  2609. init: function (a, b, c, d) {
  2610. d = d || {}, this.inited || (this.factory = b, c ? this.on("error", c) : this.events.error && (c = bind(this, function (a) {
  2611. this.emit("error", a)
  2612. })), this.depMaps = a && a.slice(0), this.errback = c, this.inited = !0, this.ignore = d.ignore, d.enabled || this.enabled ? this.enable() : this.check())
  2613. }, defineDep: function (a, b) {
  2614. this.depMatched[a] || (this.depMatched[a] = !0, this.depCount -= 1, this.depExports[a] = b)
  2615. }, fetch: function () {
  2616. if (!this.fetched) {
  2617. this.fetched = !0, u.startTime = (new Date).getTime();
  2618. var a = this.map;
  2619. return this.shim ? (u.makeRequire(this.map, {enableBuildCallback: !0})(this.shim.deps || [], bind(this, function () {
  2620. return a.prefix ? this.callPlugin() : this.load()
  2621. })), void 0) : a.prefix ? this.callPlugin() : this.load()
  2622. }
  2623. }, load: function () {
  2624. var a = this.map.url;
  2625. D[a] || (D[a] = !0, u.load(this.map.id, a))
  2626. }, check: function () {
  2627. if (this.enabled && !this.enabling) {
  2628. var a, b, c = this.map.id, d = this.depExports, e = this.exports, f = this.factory;
  2629. if (this.inited) {
  2630. if (this.error)this.emit("error", this.error); else if (!this.defining) {
  2631. if (this.defining = !0, this.depCount < 1 && !this.defined) {
  2632. if (isFunction(f)) {
  2633. if (this.events.error && this.map.isDefine || req.onError !== defaultOnError)try {
  2634. e = u.execCb(c, f, d, e)
  2635. } catch (g) {
  2636. a = g
  2637. } else e = u.execCb(c, f, d, e);
  2638. if (this.map.isDefine && (b = this.module, b && void 0 !== b.exports && b.exports !== this.exports ? e = b.exports : void 0 === e && this.usingExports && (e = this.exports)), a)return a.requireMap = this.map, a.requireModules = this.map.isDefine ? [this.map.id] : null, a.requireType = this.map.isDefine ? "define" : "require", j(this.error = a)
  2639. } else e = f;
  2640. this.exports = e, this.map.isDefine && !this.ignore && (C[c] = e, req.onResourceLoad && req.onResourceLoad(u, this.map, this.depMaps)), l(c), this.defined = !0
  2641. }
  2642. this.defining = !1, this.defined && !this.defineEmitted && (this.defineEmitted = !0, this.emit("defined", this.exports), this.defineEmitComplete = !0)
  2643. }
  2644. } else this.fetch()
  2645. }
  2646. }, callPlugin: function () {
  2647. var a = this.map, b = a.id, d = g(a.prefix);
  2648. this.depMaps.push(d), i(d, "defined", bind(this, function (d) {
  2649. var e, f, k, m = this.map.name, n = this.map.parentMap ? this.map.parentMap.name : null, o = u.makeRequire(a.parentMap, {enableBuildCallback: !0});
  2650. return this.map.unnormalized ? (d.normalize && (m = d.normalize(m, function (a) {
  2651. return c(a, n, !0)
  2652. }) || ""), f = g(a.prefix + "!" + m, this.map.parentMap), i(f, "defined", bind(this, function (a) {
  2653. this.init([], function () {
  2654. return a
  2655. }, null, {enabled: !0, ignore: !0})
  2656. })), k = getOwn(y, f.id), k && (this.depMaps.push(f), this.events.error && k.on("error", bind(this, function (a) {
  2657. this.emit("error", a)
  2658. })), k.enable()), void 0) : (e = bind(this, function (a) {
  2659. this.init([], function () {
  2660. return a
  2661. }, null, {enabled: !0})
  2662. }), e.error = bind(this, function (a) {
  2663. this.inited = !0, this.error = a, a.requireModules = [b], eachProp(y, function (a) {
  2664. 0 === a.map.id.indexOf(b + "_unnormalized") && l(a.map.id)
  2665. }), j(a)
  2666. }), e.fromText = bind(this, function (c, d) {
  2667. var f = a.name, i = g(f), k = useInteractive;
  2668. d && (c = d), k && (useInteractive = !1), h(i), hasProp(x.config, b) && (x.config[f] = x.config[b]);
  2669. try {
  2670. req.exec(c)
  2671. } catch (l) {
  2672. return j(makeError("fromtexteval", "fromText eval for " + b + " failed: " + l, l, [b]))
  2673. }
  2674. k && (useInteractive = !0), this.depMaps.push(i), u.completeLoad(f), o([f], e)
  2675. }), d.load(a.name, o, e, x), void 0)
  2676. })), u.enable(d, this), this.pluginMaps[d.id] = d
  2677. }, enable: function () {
  2678. z[this.map.id] = this, this.enabled = !0, this.enabling = !0, each(this.depMaps, bind(this, function (a, b) {
  2679. var c, d, e;
  2680. if ("string" == typeof a) {
  2681. if (a = g(a, this.map.isDefine ? this.map : this.map.parentMap, !1, !this.skipMap), this.depMaps[b] = a, e = getOwn(v, a.id))return this.depExports[b] = e(this), void 0;
  2682. this.depCount += 1, i(a, "defined", bind(this, function (a) {
  2683. this.defineDep(b, a), this.check()
  2684. })), this.errback && i(a, "error", bind(this, this.errback))
  2685. }
  2686. c = a.id, d = y[c], hasProp(v, c) || !d || d.enabled || u.enable(a, this)
  2687. })), eachProp(this.pluginMaps, bind(this, function (a) {
  2688. var b = getOwn(y, a.id);
  2689. b && !b.enabled && u.enable(a, this)
  2690. })), this.enabling = !1, this.check()
  2691. }, on: function (a, b) {
  2692. var c = this.events[a];
  2693. c || (c = this.events[a] = []), c.push(b)
  2694. }, emit: function (a, b) {
  2695. each(this.events[a], function (a) {
  2696. a(b)
  2697. }), "error" === a && delete this.events[a]
  2698. }
  2699. }, u = {
  2700. config: x,
  2701. contextName: a,
  2702. registry: y,
  2703. defined: C,
  2704. urlFetched: D,
  2705. defQueue: B,
  2706. Module: t,
  2707. makeModuleMap: g,
  2708. nextTick: req.nextTick,
  2709. onError: j,
  2710. configure: function (a) {
  2711. a.baseUrl && "/" !== a.baseUrl.charAt(a.baseUrl.length - 1) && (a.baseUrl += "/");
  2712. var b = x.pkgs, c = x.shim, d = {paths: !0, config: !0, map: !0};
  2713. eachProp(a, function (a, b) {
  2714. d[b] ? "map" === b ? (x.map || (x.map = {}), mixin(x[b], a, !0, !0)) : mixin(x[b], a, !0) : x[b] = a
  2715. }), a.shim && (eachProp(a.shim, function (a, b) {
  2716. isArray(a) && (a = {deps: a}), !a.exports && !a.init || a.exportsFn || (a.exportsFn = u.makeShimExports(a)), c[b] = a
  2717. }), x.shim = c), a.packages && (each(a.packages, function (a) {
  2718. var c;
  2719. a = "string" == typeof a ? {name: a} : a, c = a.location, b[a.name] = {
  2720. name: a.name,
  2721. location: c || a.name,
  2722. main: (a.main || "main").replace(currDirRegExp, "").replace(jsSuffixRegExp, "")
  2723. }
  2724. }), x.pkgs = b), eachProp(y, function (a, b) {
  2725. a.inited || a.map.unnormalized || (a.map = g(b))
  2726. }), (a.deps || a.callback) && u.require(a.deps || [], a.callback)
  2727. },
  2728. makeShimExports: function (a) {
  2729. function b() {
  2730. var b;
  2731. return a.init && (b = a.init.apply(global, arguments)), b || a.exports && getGlobal(a.exports)
  2732. }
  2733.  
  2734. return b
  2735. },
  2736. makeRequire: function (b, d) {
  2737. function e(c, f, i) {
  2738. var k, l, m;
  2739. return d.enableBuildCallback && f && isFunction(f) && (f.__requireJsBuild = !0), "string" == typeof c ? isFunction(f) ? j(makeError("requireargs", "Invalid require call"), i) : b && hasProp(v, c) ? v[c](y[b.id]) : req.get ? req.get(u, c, b, e) : (l = g(c, b, !1, !0), k = l.id, hasProp(C, k) ? C[k] : j(makeError("notloaded", 'Module name "' + k + '" has not been loaded yet for context: ' + a + (b ? "" : ". Use require([])")))) : (r(), u.nextTick(function () {
  2740. r(), m = h(g(null, b)), m.skipMap = d.skipMap, m.init(c, f, i, {enabled: !0}), n()
  2741. }), e)
  2742. }
  2743.  
  2744. return d = d || {}, mixin(e, {
  2745. isBrowser: isBrowser, toUrl: function (a) {
  2746. var d, e = a.lastIndexOf("."), f = a.split("/")[0], g = "." === f || ".." === f;
  2747. return -1 !== e && (!g || e > 1) && (d = a.substring(e, a.length), a = a.substring(0, e)), u.nameToUrl(c(a, b && b.id, !0), d, !0)
  2748. }, defined: function (a) {
  2749. return hasProp(C, g(a, b, !1, !0).id)
  2750. }, specified: function (a) {
  2751. return a = g(a, b, !1, !0).id, hasProp(C, a) || hasProp(y, a)
  2752. }
  2753. }), b || (e.undef = function (a) {
  2754. k();
  2755. var c = g(a, b, !0), d = getOwn(y, a);
  2756. delete C[a], delete D[c.url], delete A[a], d && (d.events.defined && (A[a] = d.events), l(a))
  2757. }), e
  2758. },
  2759. enable: function (a) {
  2760. var b = getOwn(y, a.id);
  2761. b && h(a).enable()
  2762. },
  2763. completeLoad: function (a) {
  2764. var b, c, d, f = getOwn(x.shim, a) || {}, g = f.exports;
  2765. for (k(); B.length;) {
  2766. if (c = B.shift(), null === c[0]) {
  2767. if (c[0] = a, b)break;
  2768. b = !0
  2769. } else c[0] === a && (b = !0);
  2770. o(c)
  2771. }
  2772. if (d = getOwn(y, a), !b && !hasProp(C, a) && d && !d.inited) {
  2773. if (!(!x.enforceDefine || g && getGlobal(g)))return e(a) ? void 0 : j(makeError("nodefine", "No define call for " + a, null, [a]));
  2774. o([a, f.deps || [], f.exportsFn])
  2775. }
  2776. n()
  2777. },
  2778. nameToUrl: function (a, b, c) {
  2779. var d, e, f, g, h, i, j, k, l;
  2780. if (req.jsExtRegExp.test(a))k = a + (b || ""); else {
  2781. for (d = x.paths, e = x.pkgs, h = a.split("/"), i = h.length; i > 0; i -= 1) {
  2782. if (j = h.slice(0, i).join("/"), f = getOwn(e, j), l = getOwn(d, j)) {
  2783. isArray(l) && (l = l[0]), h.splice(0, i, l);
  2784. break
  2785. }
  2786. if (f) {
  2787. g = a === f.name ? f.location + "/" + f.main : f.location, h.splice(0, i, g);
  2788. break
  2789. }
  2790. }
  2791. k = h.join("/"), k += b || (/\?/.test(k) || c ? "" : ".js"), k = ("/" === k.charAt(0) || k.match(/^[\w\+\.\-]+:/) ? "" : x.baseUrl) + k
  2792. }
  2793. return x.urlArgs ? k + ((-1 === k.indexOf("?") ? "?" : "&") + x.urlArgs) : k
  2794. },
  2795. load: function (a, b) {
  2796. req.load(u, a, b)
  2797. },
  2798. execCb: function (a, b, c, d) {
  2799. return b.apply(d, c)
  2800. },
  2801. onScriptLoad: function (a) {
  2802. if ("load" === a.type || readyRegExp.test((a.currentTarget || a.srcElement).readyState)) {
  2803. interactiveScript = null;
  2804. var b = q(a);
  2805. u.completeLoad(b.id)
  2806. }
  2807. },
  2808. onScriptError: function (a) {
  2809. var b = q(a);
  2810. return e(b.id) ? void 0 : j(makeError("scripterror", "Script error for: " + b.id, a, [b.id]))
  2811. }
  2812. }, u.require = u.makeRequire(), u
  2813. }
  2814.  
  2815. function getInteractiveScript() {
  2816. return interactiveScript && "interactive" === interactiveScript.readyState ? interactiveScript : (eachReverse(scripts(), function (a) {
  2817. return "interactive" === a.readyState ? interactiveScript = a : void 0
  2818. }), interactiveScript)
  2819. }
  2820.  
  2821. var req, s, head, baseElement, dataMain, src, interactiveScript, currentlyAddingScript, mainScript, subPath, version = "2.1.8", commentRegExp = /(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/gm, cjsRequireRegExp = /[^.]\s*require\s*\(\s*["']([^'"\s]+)["']\s*\)/g, jsSuffixRegExp = /\.js$/, currDirRegExp = /^\.\//, op = Object.prototype, ostring = op.toString, hasOwn = op.hasOwnProperty, ap = Array.prototype, apsp = ap.splice, isBrowser = !("undefined" == typeof window || !navigator || !window.document), isWebWorker = !isBrowser && "undefined" != typeof importScripts, readyRegExp = isBrowser && "PLAYSTATION 3" === navigator.platform ? /^complete$/ : /^(complete|loaded)$/, defContextName = "_", isOpera = "undefined" != typeof opera && "[object Opera]" === opera.toString(), contexts = {}, cfg = {}, globalDefQueue = [], useInteractive = !1;
  2822. if ("undefined" == typeof define) {
  2823. if ("undefined" != typeof requirejs) {
  2824. if (isFunction(requirejs))return;
  2825. cfg = requirejs, requirejs = void 0
  2826. }
  2827. "undefined" == typeof require || isFunction(require) || (cfg = require, require = void 0), req = requirejs = function (a, b, c, d) {
  2828. var e, f, g = defContextName;
  2829. return isArray(a) || "string" == typeof a || (f = a, isArray(b) ? (a = b, b = c, c = d) : a = []), f && f.context && (g = f.context), e = getOwn(contexts, g), e || (e = contexts[g] = req.s.newContext(g)), f && e.configure(f), e.require(a, b, c)
  2830. }, req.config = function (a) {
  2831. return req(a)
  2832. }, req.nextTick = "undefined" != typeof setTimeout ? function (a) {
  2833. setTimeout(a, 4)
  2834. } : function (a) {
  2835. a()
  2836. }, require || (require = req), req.version = version, req.jsExtRegExp = /^\/|:|\?|\.js$/, req.isBrowser = isBrowser, s = req.s = {
  2837. contexts: contexts,
  2838. newContext: newContext
  2839. }, req({}), each(["toUrl", "undef", "defined", "specified"], function (a) {
  2840. req[a] = function () {
  2841. var b = contexts[defContextName];
  2842. return b.require[a].apply(b, arguments)
  2843. }
  2844. }), isBrowser && (head = s.head = document.getElementsByTagName("head")[0], baseElement = document.getElementsByTagName("base")[0], baseElement && (head = s.head = baseElement.parentNode)), req.onError = defaultOnError, req.createNode = function (a) {
  2845. var b = a.xhtml ? document.createElementNS("http://www.w3.org/1999/xhtml", "html:script") : document.createElement("script");
  2846. return b.type = a.scriptType || "text/javascript", b.charset = "utf-8", b.async = !0, b
  2847. }, req.load = function (a, b, c) {
  2848. var d, e = a && a.config || {};
  2849. if (isBrowser)return d = req.createNode(e, b, c), d.setAttribute("data-requirecontext", a.contextName), d.setAttribute("data-requiremodule", b), !d.attachEvent || d.attachEvent.toString && d.attachEvent.toString().indexOf("[native code") < 0 || isOpera ? (d.addEventListener("load", a.onScriptLoad, !1), d.addEventListener("error", a.onScriptError, !1)) : (useInteractive = !0, d.attachEvent("onreadystatechange", a.onScriptLoad)), d.src = c, currentlyAddingScript = d, baseElement ? head.insertBefore(d, baseElement) : head.appendChild(d), currentlyAddingScript = null, d;
  2850. if (isWebWorker)try {
  2851. importScripts(c), a.completeLoad(b)
  2852. } catch (f) {
  2853. a.onError(makeError("importscripts", "importScripts failed for " + b + " at " + c, f, [b]))
  2854. }
  2855. }, isBrowser && eachReverse(scripts(), function (a) {
  2856. return head || (head = a.parentNode), dataMain = a.getAttribute("data-main"), dataMain ? (mainScript = dataMain, cfg.baseUrl || (src = mainScript.split("/"), mainScript = src.pop(), subPath = src.length ? src.join("/") + "/" : "./", cfg.baseUrl = subPath), mainScript = mainScript.replace(jsSuffixRegExp, ""), req.jsExtRegExp.test(mainScript) && (mainScript = dataMain), cfg.deps = cfg.deps ? cfg.deps.concat(mainScript) : [mainScript], !0) : void 0
  2857. }), define = function (a, b, c) {
  2858. var d, e;
  2859. "string" != typeof a && (c = b, b = a, a = null), isArray(b) || (c = b, b = null), !b && isFunction(c) && (b = [], c.length && (c.toString().replace(commentRegExp, "").replace(cjsRequireRegExp, function (a, c) {
  2860. b.push(c)
  2861. }), b = (1 === c.length ? ["require"] : ["require", "exports", "module"]).concat(b))), useInteractive && (d = currentlyAddingScript || getInteractiveScript(), d && (a || (a = d.getAttribute("data-requiremodule")), e = contexts[d.getAttribute("data-requirecontext")])), (e ? e.defQueue : globalDefQueue).push([a, b, c])
  2862. }, define.amd = {jQuery: !0}, req.exec = function (text) {
  2863. return eval(text)
  2864. }, req(cfg)
  2865. }
  2866. }(this), function () {
  2867. var a = this, b = a._, c = {}, d = Array.prototype, e = Object.prototype, f = Function.prototype, g = d.push, h = d.slice, i = d.concat, j = e.toString, k = e.hasOwnProperty, l = d.forEach, m = d.map, n = d.reduce, o = d.reduceRight, p = d.filter, q = d.every, r = d.some, s = d.indexOf, t = d.lastIndexOf, u = Array.isArray, v = Object.keys, w = f.bind, x = function (a) {
  2868. return a instanceof x ? a : this instanceof x ? (this._wrapped = a, void 0) : new x(a)
  2869. };
  2870. "undefined" != typeof exports ? ("undefined" != typeof module && module.exports && (exports = module.exports = x), exports._ = x) : a._ = x, x.VERSION = "1.4.4";
  2871. var y = x.each = x.forEach = function (a, b, d) {
  2872. if (null != a)if (l && a.forEach === l)a.forEach(b, d); else if (a.length === +a.length) {
  2873. for (var e = 0, f = a.length; f > e; e++)if (b.call(d, a[e], e, a) === c)return
  2874. } else for (var g in a)if (x.has(a, g) && b.call(d, a[g], g, a) === c)return
  2875. };
  2876. x.map = x.collect = function (a, b, c) {
  2877. var d = [];
  2878. return null == a ? d : m && a.map === m ? a.map(b, c) : (y(a, function (a, e, f) {
  2879. d[d.length] = b.call(c, a, e, f)
  2880. }), d)
  2881. };
  2882. var z = "Reduce of empty array with no initial value";
  2883. x.reduce = x.foldl = x.inject = function (a, b, c, d) {
  2884. var e = arguments.length > 2;
  2885. if (null == a && (a = []), n && a.reduce === n)return d && (b = x.bind(b, d)), e ? a.reduce(b, c) : a.reduce(b);
  2886. if (y(a, function (a, f, g) {
  2887. e ? c = b.call(d, c, a, f, g) : (c = a, e = !0)
  2888. }), !e)throw new TypeError(z);
  2889. return c
  2890. }, x.reduceRight = x.foldr = function (a, b, c, d) {
  2891. var e = arguments.length > 2;
  2892. if (null == a && (a = []), o && a.reduceRight === o)return d && (b = x.bind(b, d)), e ? a.reduceRight(b, c) : a.reduceRight(b);
  2893. var f = a.length;
  2894. if (f !== +f) {
  2895. var g = x.keys(a);
  2896. f = g.length
  2897. }
  2898. if (y(a, function (h, i, j) {
  2899. i = g ? g[--f] : --f, e ? c = b.call(d, c, a[i], i, j) : (c = a[i], e = !0)
  2900. }), !e)throw new TypeError(z);
  2901. return c
  2902. }, x.find = x.detect = function (a, b, c) {
  2903. var d;
  2904. return A(a, function (a, e, f) {
  2905. return b.call(c, a, e, f) ? (d = a, !0) : void 0
  2906. }), d
  2907. }, x.filter = x.select = function (a, b, c) {
  2908. var d = [];
  2909. return null == a ? d : p && a.filter === p ? a.filter(b, c) : (y(a, function (a, e, f) {
  2910. b.call(c, a, e, f) && (d[d.length] = a)
  2911. }), d)
  2912. }, x.reject = function (a, b, c) {
  2913. return x.filter(a, function (a, d, e) {
  2914. return !b.call(c, a, d, e)
  2915. }, c)
  2916. }, x.every = x.all = function (a, b, d) {
  2917. b || (b = x.identity);
  2918. var e = !0;
  2919. return null == a ? e : q && a.every === q ? a.every(b, d) : (y(a, function (a, f, g) {
  2920. return (e = e && b.call(d, a, f, g)) ? void 0 : c
  2921. }), !!e)
  2922. };
  2923. var A = x.some = x.any = function (a, b, d) {
  2924. b || (b = x.identity);
  2925. var e = !1;
  2926. return null == a ? e : r && a.some === r ? a.some(b, d) : (y(a, function (a, f, g) {
  2927. return e || (e = b.call(d, a, f, g)) ? c : void 0
  2928. }), !!e)
  2929. };
  2930. x.contains = x.include = function (a, b) {
  2931. return null == a ? !1 : s && a.indexOf === s ? -1 != a.indexOf(b) : A(a, function (a) {
  2932. return a === b
  2933. })
  2934. }, x.invoke = function (a, b) {
  2935. var c = h.call(arguments, 2), d = x.isFunction(b);
  2936. return x.map(a, function (a) {
  2937. return (d ? b : a[b]).apply(a, c)
  2938. })
  2939. }, x.pluck = function (a, b) {
  2940. return x.map(a, function (a) {
  2941. return a[b]
  2942. })
  2943. }, x.where = function (a, b, c) {
  2944. return x.isEmpty(b) ? c ? null : [] : x[c ? "find" : "filter"](a, function (a) {
  2945. for (var c in b)if (b[c] !== a[c])return !1;
  2946. return !0
  2947. })
  2948. }, x.findWhere = function (a, b) {
  2949. return x.where(a, b, !0)
  2950. }, x.max = function (a, b, c) {
  2951. if (!b && x.isArray(a) && a[0] === +a[0] && 65535 > a.length)return Math.max.apply(Math, a);
  2952. if (!b && x.isEmpty(a))return -1 / 0;
  2953. var d = {computed: -1 / 0, value: -1 / 0};
  2954. return y(a, function (a, e, f) {
  2955. var g = b ? b.call(c, a, e, f) : a;
  2956. g >= d.computed && (d = {value: a, computed: g})
  2957. }), d.value
  2958. }, x.min = function (a, b, c) {
  2959. if (!b && x.isArray(a) && a[0] === +a[0] && 65535 > a.length)return Math.min.apply(Math, a);
  2960. if (!b && x.isEmpty(a))return 1 / 0;
  2961. var d = {computed: 1 / 0, value: 1 / 0};
  2962. return y(a, function (a, e, f) {
  2963. var g = b ? b.call(c, a, e, f) : a;
  2964. d.computed > g && (d = {value: a, computed: g})
  2965. }), d.value
  2966. }, x.shuffle = function (a) {
  2967. var b, c = 0, d = [];
  2968. return y(a, function (a) {
  2969. b = x.random(c++), d[c - 1] = d[b], d[b] = a
  2970. }), d
  2971. };
  2972. var B = function (a) {
  2973. return x.isFunction(a) ? a : function (b) {
  2974. return b[a]
  2975. }
  2976. };
  2977. x.sortBy = function (a, b, c) {
  2978. var d = B(b);
  2979. return x.pluck(x.map(a, function (a, b, e) {
  2980. return {value: a, index: b, criteria: d.call(c, a, b, e)}
  2981. }).sort(function (a, b) {
  2982. var c = a.criteria, d = b.criteria;
  2983. if (c !== d) {
  2984. if (c > d || void 0 === c)return 1;
  2985. if (d > c || void 0 === d)return -1
  2986. }
  2987. return a.index < b.index ? -1 : 1
  2988. }), "value")
  2989. };
  2990. var C = function (a, b, c, d) {
  2991. var e = {}, f = B(b || x.identity);
  2992. return y(a, function (b, g) {
  2993. var h = f.call(c, b, g, a);
  2994. d(e, h, b)
  2995. }), e
  2996. };
  2997. x.groupBy = function (a, b, c) {
  2998. return C(a, b, c, function (a, b, c) {
  2999. (x.has(a, b) ? a[b] : a[b] = []).push(c)
  3000. })
  3001. }, x.countBy = function (a, b, c) {
  3002. return C(a, b, c, function (a, b) {
  3003. x.has(a, b) || (a[b] = 0), a[b]++
  3004. })
  3005. }, x.sortedIndex = function (a, b, c, d) {
  3006. c = null == c ? x.identity : B(c);
  3007. for (var e = c.call(d, b), f = 0, g = a.length; g > f;) {
  3008. var h = f + g >>> 1;
  3009. e > c.call(d, a[h]) ? f = h + 1 : g = h
  3010. }
  3011. return f
  3012. }, x.toArray = function (a) {
  3013. return a ? x.isArray(a) ? h.call(a) : a.length === +a.length ? x.map(a, x.identity) : x.values(a) : []
  3014. }, x.size = function (a) {
  3015. return null == a ? 0 : a.length === +a.length ? a.length : x.keys(a).length
  3016. }, x.first = x.head = x.take = function (a, b, c) {
  3017. return null == a ? void 0 : null == b || c ? a[0] : h.call(a, 0, b)
  3018. }, x.initial = function (a, b, c) {
  3019. return h.call(a, 0, a.length - (null == b || c ? 1 : b))
  3020. }, x.last = function (a, b, c) {
  3021. return null == a ? void 0 : null == b || c ? a[a.length - 1] : h.call(a, Math.max(a.length - b, 0))
  3022. }, x.rest = x.tail = x.drop = function (a, b, c) {
  3023. return h.call(a, null == b || c ? 1 : b)
  3024. }, x.compact = function (a) {
  3025. return x.filter(a, x.identity)
  3026. };
  3027. var D = function (a, b, c) {
  3028. return y(a, function (a) {
  3029. x.isArray(a) ? b ? g.apply(c, a) : D(a, b, c) : c.push(a)
  3030. }), c
  3031. };
  3032. x.flatten = function (a, b) {
  3033. return D(a, b, [])
  3034. }, x.without = function (a) {
  3035. return x.difference(a, h.call(arguments, 1))
  3036. }, x.uniq = x.unique = function (a, b, c, d) {
  3037. x.isFunction(b) && (d = c, c = b, b = !1);
  3038. var e = c ? x.map(a, c, d) : a, f = [], g = [];
  3039. return y(e, function (c, d) {
  3040. (b ? d && g[g.length - 1] === c : x.contains(g, c)) || (g.push(c), f.push(a[d]))
  3041. }), f
  3042. }, x.union = function () {
  3043. return x.uniq(i.apply(d, arguments))
  3044. }, x.intersection = function (a) {
  3045. var b = h.call(arguments, 1);
  3046. return x.filter(x.uniq(a), function (a) {
  3047. return x.every(b, function (b) {
  3048. return x.indexOf(b, a) >= 0
  3049. })
  3050. })
  3051. }, x.difference = function (a) {
  3052. var b = i.apply(d, h.call(arguments, 1));
  3053. return x.filter(a, function (a) {
  3054. return !x.contains(b, a)
  3055. })
  3056. }, x.zip = function () {
  3057. for (var a = h.call(arguments), b = x.max(x.pluck(a, "length")), c = Array(b), d = 0; b > d; d++)c[d] = x.pluck(a, "" + d);
  3058. return c
  3059. }, x.object = function (a, b) {
  3060. if (null == a)return {};
  3061. for (var c = {}, d = 0, e = a.length; e > d; d++)b ? c[a[d]] = b[d] : c[a[d][0]] = a[d][1];
  3062. return c
  3063. }, x.indexOf = function (a, b, c) {
  3064. if (null == a)return -1;
  3065. var d = 0, e = a.length;
  3066. if (c) {
  3067. if ("number" != typeof c)return d = x.sortedIndex(a, b), a[d] === b ? d : -1;
  3068. d = 0 > c ? Math.max(0, e + c) : c
  3069. }
  3070. if (s && a.indexOf === s)return a.indexOf(b, c);
  3071. for (; e > d; d++)if (a[d] === b)return d;
  3072. return -1
  3073. }, x.lastIndexOf = function (a, b, c) {
  3074. if (null == a)return -1;
  3075. var d = null != c;
  3076. if (t && a.lastIndexOf === t)return d ? a.lastIndexOf(b, c) : a.lastIndexOf(b);
  3077. for (var e = d ? c : a.length; e--;)if (a[e] === b)return e;
  3078. return -1
  3079. }, x.range = function (a, b, c) {
  3080. 1 >= arguments.length && (b = a || 0, a = 0), c = arguments[2] || 1;
  3081. for (var d = Math.max(Math.ceil((b - a) / c), 0), e = 0, f = Array(d); d > e;)f[e++] = a, a += c;
  3082. return f
  3083. }, x.bind = function (a, b) {
  3084. if (a.bind === w && w)return w.apply(a, h.call(arguments, 1));
  3085. var c = h.call(arguments, 2);
  3086. return function () {
  3087. return a.apply(b, c.concat(h.call(arguments)))
  3088. }
  3089. }, x.partial = function (a) {
  3090. var b = h.call(arguments, 1);
  3091. return function () {
  3092. return a.apply(this, b.concat(h.call(arguments)))
  3093. }
  3094. }, x.bindAll = function (a) {
  3095. var b = h.call(arguments, 1);
  3096. return 0 === b.length && (b = x.functions(a)), y(b, function (b) {
  3097. a[b] = x.bind(a[b], a)
  3098. }), a
  3099. }, x.memoize = function (a, b) {
  3100. var c = {};
  3101. return b || (b = x.identity), function () {
  3102. var d = b.apply(this, arguments);
  3103. return x.has(c, d) ? c[d] : c[d] = a.apply(this, arguments)
  3104. }
  3105. }, x.delay = function (a, b) {
  3106. var c = h.call(arguments, 2);
  3107. return setTimeout(function () {
  3108. return a.apply(null, c)
  3109. }, b)
  3110. }, x.defer = function (a) {
  3111. return x.delay.apply(x, [a, 1].concat(h.call(arguments, 1)))
  3112. }, x.throttle = function (a, b) {
  3113. var c, d, e, f, g = 0, h = function () {
  3114. g = new Date, e = null, f = a.apply(c, d)
  3115. };
  3116. return function () {
  3117. var i = new Date, j = b - (i - g);
  3118. return c = this, d = arguments, 0 >= j ? (clearTimeout(e), e = null, g = i, f = a.apply(c, d)) : e || (e = setTimeout(h, j)), f
  3119. }
  3120. }, x.debounce = function (a, b, c) {
  3121. var d, e;
  3122. return function () {
  3123. var f = this, g = arguments, h = function () {
  3124. d = null, c || (e = a.apply(f, g))
  3125. }, i = c && !d;
  3126. return clearTimeout(d), d = setTimeout(h, b), i && (e = a.apply(f, g)), e
  3127. }
  3128. }, x.once = function (a) {
  3129. var b, c = !1;
  3130. return function () {
  3131. return c ? b : (c = !0, b = a.apply(this, arguments), a = null, b)
  3132. }
  3133. }, x.wrap = function (a, b) {
  3134. return function () {
  3135. var c = [a];
  3136. return g.apply(c, arguments), b.apply(this, c)
  3137. }
  3138. }, x.compose = function () {
  3139. var a = arguments;
  3140. return function () {
  3141. for (var b = arguments, c = a.length - 1; c >= 0; c--)b = [a[c].apply(this, b)];
  3142. return b[0]
  3143. }
  3144. }, x.after = function (a, b) {
  3145. return 0 >= a ? b() : function () {
  3146. return 1 > --a ? b.apply(this, arguments) : void 0
  3147. }
  3148. }, x.keys = v || function (a) {
  3149. if (a !== Object(a))throw new TypeError("Invalid object");
  3150. var b = [];
  3151. for (var c in a)x.has(a, c) && (b[b.length] = c);
  3152. return b
  3153. }, x.values = function (a) {
  3154. var b = [];
  3155. for (var c in a)x.has(a, c) && b.push(a[c]);
  3156. return b
  3157. }, x.pairs = function (a) {
  3158. var b = [];
  3159. for (var c in a)x.has(a, c) && b.push([c, a[c]]);
  3160. return b
  3161. }, x.invert = function (a) {
  3162. var b = {};
  3163. for (var c in a)x.has(a, c) && (b[a[c]] = c);
  3164. return b
  3165. }, x.functions = x.methods = function (a) {
  3166. var b = [];
  3167. for (var c in a)x.isFunction(a[c]) && b.push(c);
  3168. return b.sort()
  3169. }, x.extend = function (a) {
  3170. return y(h.call(arguments, 1), function (b) {
  3171. if (b)for (var c in b)a[c] = b[c]
  3172. }), a
  3173. }, x.pick = function (a) {
  3174. var b = {}, c = i.apply(d, h.call(arguments, 1));
  3175. return y(c, function (c) {
  3176. c in a && (b[c] = a[c])
  3177. }), b
  3178. }, x.omit = function (a) {
  3179. var b = {}, c = i.apply(d, h.call(arguments, 1));
  3180. for (var e in a)x.contains(c, e) || (b[e] = a[e]);
  3181. return b
  3182. }, x.defaults = function (a) {
  3183. return y(h.call(arguments, 1), function (b) {
  3184. if (b)for (var c in b)null == a[c] && (a[c] = b[c])
  3185. }), a
  3186. }, x.clone = function (a) {
  3187. return x.isObject(a) ? x.isArray(a) ? a.slice() : x.extend({}, a) : a
  3188. }, x.tap = function (a, b) {
  3189. return b(a), a
  3190. };
  3191. var E = function (a, b, c, d) {
  3192. if (a === b)return 0 !== a || 1 / a == 1 / b;
  3193. if (null == a || null == b)return a === b;
  3194. a instanceof x && (a = a._wrapped), b instanceof x && (b = b._wrapped);
  3195. var e = j.call(a);
  3196. if (e != j.call(b))return !1;
  3197. switch (e) {
  3198. case"[object String]":
  3199. return a == b + "";
  3200. case"[object Number]":
  3201. return a != +a ? b != +b : 0 == a ? 1 / a == 1 / b : a == +b;
  3202. case"[object Date]":
  3203. case"[object Boolean]":
  3204. return +a == +b;
  3205. case"[object RegExp]":
  3206. return a.source == b.source && a.global == b.global && a.multiline == b.multiline && a.ignoreCase == b.ignoreCase
  3207. }
  3208. if ("object" != typeof a || "object" != typeof b)return !1;
  3209. for (var f = c.length; f--;)if (c[f] == a)return d[f] == b;
  3210. c.push(a), d.push(b);
  3211. var g = 0, h = !0;
  3212. if ("[object Array]" == e) {
  3213. if (g = a.length, h = g == b.length)for (; g-- && (h = E(a[g], b[g], c, d)););
  3214. } else {
  3215. var i = a.constructor, k = b.constructor;
  3216. if (i !== k && !(x.isFunction(i) && i instanceof i && x.isFunction(k) && k instanceof k))return !1;
  3217. for (var l in a)if (x.has(a, l) && (g++, !(h = x.has(b, l) && E(a[l], b[l], c, d))))break;
  3218. if (h) {
  3219. for (l in b)if (x.has(b, l) && !g--)break;
  3220. h = !g
  3221. }
  3222. }
  3223. return c.pop(), d.pop(), h
  3224. };
  3225. x.isEqual = function (a, b) {
  3226. return E(a, b, [], [])
  3227. }, x.isEmpty = function (a) {
  3228. if (null == a)return !0;
  3229. if (x.isArray(a) || x.isString(a))return 0 === a.length;
  3230. for (var b in a)if (x.has(a, b))return !1;
  3231. return !0
  3232. }, x.isElement = function (a) {
  3233. return !(!a || 1 !== a.nodeType)
  3234. }, x.isArray = u || function (a) {
  3235. return "[object Array]" == j.call(a)
  3236. }, x.isObject = function (a) {
  3237. return a === Object(a)
  3238. }, y(["Arguments", "Function", "String", "Number", "Date", "RegExp"], function (a) {
  3239. x["is" + a] = function (b) {
  3240. return j.call(b) == "[object " + a + "]"
  3241. }
  3242. }), x.isArguments(arguments) || (x.isArguments = function (a) {
  3243. return !(!a || !x.has(a, "callee"))
  3244. }), "function" != typeof/./ && (x.isFunction = function (a) {
  3245. return "function" == typeof a
  3246. }), x.isFinite = function (a) {
  3247. return isFinite(a) && !isNaN(parseFloat(a))
  3248. }, x.isNaN = function (a) {
  3249. return x.isNumber(a) && a != +a
  3250. }, x.isBoolean = function (a) {
  3251. return a === !0 || a === !1 || "[object Boolean]" == j.call(a)
  3252. }, x.isNull = function (a) {
  3253. return null === a
  3254. }, x.isUndefined = function (a) {
  3255. return void 0 === a
  3256. }, x.has = function (a, b) {
  3257. return k.call(a, b)
  3258. }, x.noConflict = function () {
  3259. return a._ = b, this
  3260. }, x.identity = function (a) {
  3261. return a
  3262. }, x.times = function (a, b, c) {
  3263. for (var d = Array(a), e = 0; a > e; e++)d[e] = b.call(c, e);
  3264. return d
  3265. }, x.random = function (a, b) {
  3266. return null == b && (b = a, a = 0), a + Math.floor(Math.random() * (b - a + 1))
  3267. };
  3268. var F = {escape: {"&": "&amp;", "<": "&lt;", ">": "&gt;", '"': "&quot;", "'": "&#x27;", "/": "&#x2F;"}};
  3269. F.unescape = x.invert(F.escape);
  3270. var G = {
  3271. escape: RegExp("[" + x.keys(F.escape).join("") + "]", "g"),
  3272. unescape: RegExp("(" + x.keys(F.unescape).join("|") + ")", "g")
  3273. };
  3274. x.each(["escape", "unescape"], function (a) {
  3275. x[a] = function (b) {
  3276. return null == b ? "" : ("" + b).replace(G[a], function (b) {
  3277. return F[a][b]
  3278. })
  3279. }
  3280. }), x.result = function (a, b) {
  3281. if (null == a)return null;
  3282. var c = a[b];
  3283. return x.isFunction(c) ? c.call(a) : c
  3284. }, x.mixin = function (a) {
  3285. y(x.functions(a), function (b) {
  3286. var c = x[b] = a[b];
  3287. x.prototype[b] = function () {
  3288. var a = [this._wrapped];
  3289. return g.apply(a, arguments), L.call(this, c.apply(x, a))
  3290. }
  3291. })
  3292. };
  3293. var H = 0;
  3294. x.uniqueId = function (a) {
  3295. var b = ++H + "";
  3296. return a ? a + b : b
  3297. }, x.templateSettings = {evaluate: /<%([\s\S]+?)%>/g, interpolate: /<%=([\s\S]+?)%>/g, escape: /<%-([\s\S]+?)%>/g};
  3298. var I = /(.)^/, J = {
  3299. "'": "'",
  3300. "\\": "\\",
  3301. "\r": "r",
  3302. "\n": "n",
  3303. " ": "t",
  3304. "\u2028": "u2028",
  3305. "\u2029": "u2029"
  3306. }, K = /\\|'|\r|\n|\t|\u2028|\u2029/g;
  3307. x.template = function (a, b, c) {
  3308. var d;
  3309. c = x.defaults({}, c, x.templateSettings);
  3310. var e = RegExp([(c.escape || I).source, (c.interpolate || I).source, (c.evaluate || I).source].join("|") + "|$", "g"), f = 0, g = "__p+='";
  3311. a.replace(e, function (b, c, d, e, h) {
  3312. return g += a.slice(f, h).replace(K, function (a) {
  3313. return "\\" + J[a]
  3314. }), c && (g += "'+\n((__t=(" + c + "))==null?'':_.escape(__t))+\n'"), d && (g += "'+\n((__t=(" + d + "))==null?'':__t)+\n'"), e && (g += "';\n" + e + "\n__p+='"), f = h + b.length, b
  3315. }), g += "';\n", c.variable || (g = "with(obj||{}){\n" + g + "}\n"), g = "var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n" + g + "return __p;\n";
  3316. try {
  3317. d = Function(c.variable || "obj", "_", g)
  3318. } catch (h) {
  3319. throw h.source = g, h
  3320. }
  3321. if (b)return d(b, x);
  3322. var i = function (a) {
  3323. return d.call(this, a, x)
  3324. };
  3325. return i.source = "function(" + (c.variable || "obj") + "){\n" + g + "}", i
  3326. }, x.chain = function (a) {
  3327. return x(a).chain()
  3328. };
  3329. var L = function (a) {
  3330. return this._chain ? x(a).chain() : a
  3331. };
  3332. x.mixin(x), y(["pop", "push", "reverse", "shift", "sort", "splice", "unshift"], function (a) {
  3333. var b = d[a];
  3334. x.prototype[a] = function () {
  3335. var c = this._wrapped;
  3336. return b.apply(c, arguments), "shift" != a && "splice" != a || 0 !== c.length || delete c[0], L.call(this, c)
  3337. }
  3338. }), y(["concat", "join", "slice"], function (a) {
  3339. var b = d[a];
  3340. x.prototype[a] = function () {
  3341. return L.call(this, b.apply(this._wrapped, arguments))
  3342. }
  3343. }), x.extend(x.prototype, {
  3344. chain: function () {
  3345. return this._chain = !0, this
  3346. }, value: function () {
  3347. return this._wrapped
  3348. }
  3349. })
  3350. }.call(this);
  3351. var mejs = mejs || {};
  3352. mejs.version = "2.13.1", mejs.meIndex = 0, mejs.plugins = {
  3353. silverlight: [{
  3354. version: [3, 0],
  3355. types: ["video/mp4", "video/m4v", "video/mov", "video/wmv", "audio/wma", "audio/m4a", "audio/mp3", "audio/wav", "audio/mpeg"]
  3356. }],
  3357. flash: [{
  3358. version: [9, 0, 124],
  3359. types: ["video/mp4", "video/m4v", "video/mov", "video/flv", "video/rtmp", "video/x-flv", "audio/flv", "audio/x-flv", "audio/mp3", "audio/m4a", "audio/mpeg", "video/youtube", "video/x-youtube"]
  3360. }],
  3361. youtube: [{version: null, types: ["video/youtube", "video/x-youtube", "audio/youtube", "audio/x-youtube"]}],
  3362. vimeo: [{version: null, types: ["video/vimeo", "video/x-vimeo"]}]
  3363. }, mejs.Utility = {
  3364. encodeUrl: function (a) {
  3365. return encodeURIComponent(a)
  3366. }, escapeHTML: function (a) {
  3367. return a.toString().split("&").join("&amp;").split("<").join("&lt;").split('"').join("&quot;")
  3368. }, absolutizeUrl: function (a) {
  3369. var b = document.createElement("div");
  3370. return b.innerHTML = '<a href="' + this.escapeHTML(a) + '">x</a>', b.firstChild.href
  3371. }, getScriptPath: function (a) {
  3372. for (var b, c, d, e = 0, f = "", g = "", h = document.getElementsByTagName("script"), i = h.length, j = a.length; i > e; e++) {
  3373. for (c = h[e].src, b = c.lastIndexOf("/"), b > -1 ? (d = c.substring(b + 1), c = c.substring(0, b + 1)) : (d = c, c = ""), b = 0; j > b; b++)if (g = a[b], g = d.indexOf(g), g > -1) {
  3374. f = c;
  3375. break
  3376. }
  3377. if ("" !== f)break
  3378. }
  3379. return f
  3380. }, secondsToTimeCode: function (a, b, c, d) {
  3381. "undefined" == typeof c ? c = !1 : "undefined" == typeof d && (d = 25);
  3382. var e = Math.floor(a / 3600) % 24, f = Math.floor(a / 60) % 60, g = Math.floor(a % 60);
  3383. return a = Math.floor((a % 1 * d).toFixed(3)), (b || e > 0 ? (10 > e ? "0" + e : e) + ":" : "") + (10 > f ? "0" + f : f) + ":" + (10 > g ? "0" + g : g) + (c ? ":" + (10 > a ? "0" + a : a) : "")
  3384. }, timeCodeToSeconds: function (a, b, c, d) {
  3385. "undefined" == typeof c ? c = !1 : "undefined" == typeof d && (d = 25), a = a.split(":"), b = parseInt(a[0], 10);
  3386. var e = parseInt(a[1], 10), f = parseInt(a[2], 10), g = 0, h = 0;
  3387. return c && (g = parseInt(a[3]) / d), h = 3600 * b + 60 * e + f + g
  3388. }, convertSMPTEtoSeconds: function (a) {
  3389. if ("string" != typeof a)return !1;
  3390. a = a.replace(",", ".");
  3391. var b = 0, c = -1 != a.indexOf(".") ? a.split(".")[1].length : 0, d = 1;
  3392. a = a.split(":").reverse();
  3393. for (var e = 0; e < a.length; e++)d = 1, e > 0 && (d = Math.pow(60, e)), b += Number(a[e]) * d;
  3394. return Number(b.toFixed(c))
  3395. }, removeSwf: function (a) {
  3396. var b = document.getElementById(a);
  3397. b && /object|embed/i.test(b.nodeName) && (mejs.MediaFeatures.isIE ? (b.style.display = "none", function () {
  3398. 4 == b.readyState ? mejs.Utility.removeObjectInIE(a) : setTimeout(arguments.callee, 10)
  3399. }()) : b.parentNode.removeChild(b))
  3400. }, removeObjectInIE: function (a) {
  3401. if (a = document.getElementById(a)) {
  3402. for (var b in a)"function" == typeof a[b] && (a[b] = null);
  3403. a.parentNode.removeChild(a)
  3404. }
  3405. }
  3406. }, mejs.PluginDetector = {
  3407. hasPluginVersion: function (a, b) {
  3408. var c = this.plugins[a];
  3409. return b[1] = b[1] || 0, b[2] = b[2] || 0, c[0] > b[0] || c[0] == b[0] && c[1] > b[1] || c[0] == b[0] && c[1] == b[1] && c[2] >= b[2] ? !0 : !1
  3410. },
  3411. nav: window.navigator,
  3412. ua: window.navigator.userAgent.toLowerCase(),
  3413. plugins: [],
  3414. addPlugin: function (a, b, c, d, e) {
  3415. this.plugins[a] = this.detectPlugin(b, c, d, e)
  3416. },
  3417. detectPlugin: function (a, b, c, d) {
  3418. var e, f = [0, 0, 0];
  3419. if ("undefined" != typeof this.nav.plugins && "object" == typeof this.nav.plugins[a]) {
  3420. if ((c = this.nav.plugins[a].description) && ("undefined" == typeof this.nav.mimeTypes || !this.nav.mimeTypes[b] || this.nav.mimeTypes[b].enabledPlugin))for (f = c.replace(a, "").replace(/^\s+/, "").replace(/\sr/gi, ".").split("."), a = 0; a < f.length; a++)f[a] = parseInt(f[a].match(/\d+/), 10)
  3421. } else if ("undefined" != typeof window.ActiveXObject)try {
  3422. (e = new ActiveXObject(c)) && (f = d(e))
  3423. } catch (g) {
  3424. }
  3425. return f
  3426. }
  3427. }, mejs.PluginDetector.addPlugin("flash", "Shockwave Flash", "application/x-shockwave-flash", "ShockwaveFlash.ShockwaveFlash", function (a) {
  3428. var b = [];
  3429. return (a = a.GetVariable("$version")) && (a = a.split(" ")[1].split(","), b = [parseInt(a[0], 10), parseInt(a[1], 10), parseInt(a[2], 10)]), b
  3430. }), mejs.PluginDetector.addPlugin("silverlight", "Silverlight Plug-In", "application/x-silverlight-2", "AgControl.AgControl", function (a) {
  3431. var b = [0, 0, 0, 0], c = function (a, b, c, d) {
  3432. for (; a.isVersionSupported(b[0] + "." + b[1] + "." + b[2] + "." + b[3]);)b[c] += d;
  3433. b[c] -= d
  3434. };
  3435. return c(a, b, 0, 1), c(a, b, 1, 1), c(a, b, 2, 1e4), c(a, b, 2, 1e3), c(a, b, 2, 100), c(a, b, 2, 10), c(a, b, 2, 1), c(a, b, 3, 1), b
  3436. }), mejs.MediaFeatures = {
  3437. init: function () {
  3438. var a, b = this, c = document, d = mejs.PluginDetector.nav, e = mejs.PluginDetector.ua.toLowerCase(), f = ["source", "track", "audio", "video"];
  3439. b.isiPad = null !== e.match(/ipad/i), b.isiPhone = null !== e.match(/iphone/i), b.isiOS = b.isiPhone || b.isiPad, b.isAndroid = null !== e.match(/android/i), b.isBustedAndroid = null !== e.match(/android 2\.[12]/), b.isBustedNativeHTTPS = "https:" === location.protocol && (null !== e.match(/android [12]\./) || null !== e.match(/macintosh.* version.* safari/)), b.isIE = null !== d.appName.toLowerCase().match(/trident/gi), b.isChrome = null !== e.match(/chrome/gi), b.isFirefox = null !== e.match(/firefox/gi), b.isWebkit = null !== e.match(/webkit/gi), b.isGecko = null !== e.match(/gecko/gi) && !b.isWebkit && !b.isIE, b.isOpera = null !== e.match(/opera/gi), b.hasTouch = "ontouchstart"in window && null != window.ontouchstart, b.svg = !!document.createElementNS && !!document.createElementNS("http://www.w3.org/2000/svg", "svg").createSVGRect;
  3440. for (d = 0; d < f.length; d++)a = document.createElement(f[d]);
  3441. b.supportsMediaTag = "undefined" != typeof a.canPlayType || b.isBustedAndroid;
  3442. try {
  3443. a.canPlayType("video/mp4")
  3444. } catch (g) {
  3445. b.supportsMediaTag = !1
  3446. }
  3447. b.hasSemiNativeFullScreen = "undefined" != typeof a.webkitEnterFullscreen, b.hasNativeFullscreen = "undefined" != typeof a.requestFullscreen, b.hasWebkitNativeFullScreen = "undefined" != typeof a.webkitRequestFullScreen, b.hasMozNativeFullScreen = "undefined" != typeof a.mozRequestFullScreen, b.hasMsNativeFullScreen = "undefined" != typeof a.msRequestFullscreen, b.hasTrueNativeFullScreen = b.hasWebkitNativeFullScreen || b.hasMozNativeFullScreen || b.hasMsNativeFullScreen, b.nativeFullScreenEnabled = b.hasTrueNativeFullScreen, b.hasMozNativeFullScreen ? b.nativeFullScreenEnabled = document.mozFullScreenEnabled : b.hasMsNativeFullScreen && (b.nativeFullScreenEnabled = document.msFullscreenEnabled), b.isChrome && (b.hasSemiNativeFullScreen = !1), b.hasTrueNativeFullScreen && (b.fullScreenEventName = "", b.hasWebkitNativeFullScreen ? b.fullScreenEventName = "webkitfullscreenchange" : b.hasMozNativeFullScreen ? b.fullScreenEventName = "mozfullscreenchange" : b.hasMsNativeFullScreen && (b.fullScreenEventName = "MSFullscreenChange"), b.isFullScreen = function () {
  3448. return a.mozRequestFullScreen ? c.mozFullScreen : a.webkitRequestFullScreen ? c.webkitIsFullScreen : a.hasMsNativeFullScreen ? null !== c.msFullscreenElement : void 0
  3449. }, b.requestFullScreen = function (a) {
  3450. b.hasWebkitNativeFullScreen ? a.webkitRequestFullScreen() : b.hasMozNativeFullScreen ? a.mozRequestFullScreen() : b.hasMsNativeFullScreen && a.msRequestFullscreen()
  3451. }, b.cancelFullScreen = function () {
  3452. b.hasWebkitNativeFullScreen ? document.webkitCancelFullScreen() : b.hasMozNativeFullScreen ? document.mozCancelFullScreen() : b.hasMsNativeFullScreen && document.msExitFullscreen()
  3453. }), b.hasSemiNativeFullScreen && e.match(/mac os x 10_5/i) && (b.hasNativeFullScreen = !1, b.hasSemiNativeFullScreen = !1)
  3454. }
  3455. }, mejs.MediaFeatures.init(), mejs.HtmlMediaElement = {
  3456. pluginType: "native",
  3457. isFullScreen: !1,
  3458. setCurrentTime: function (a) {
  3459. this.currentTime = a
  3460. },
  3461. setMuted: function (a) {
  3462. this.muted = a
  3463. },
  3464. setVolume: function (a) {
  3465. this.volume = a
  3466. },
  3467. stop: function () {
  3468. this.pause()
  3469. },
  3470. setSrc: function (a) {
  3471. for (var b = this.getElementsByTagName("source"); b.length > 0;)this.removeChild(b[0]);
  3472. if ("string" == typeof a)this.src = a; else {
  3473. var c;
  3474. for (b = 0; b < a.length; b++)if (c = a[b], this.canPlayType(c.type)) {
  3475. this.src = c.src;
  3476. break
  3477. }
  3478. }
  3479. },
  3480. setVideoSize: function (a, b) {
  3481. this.width = a, this.height = b
  3482. }
  3483. }, mejs.PluginMediaElement = function (a, b, c) {
  3484. this.id = a, this.pluginType = b, this.src = c, this.events = {}, this.attributes = {}
  3485. }, mejs.PluginMediaElement.prototype = {
  3486. pluginElement: null,
  3487. pluginType: "",
  3488. isFullScreen: !1,
  3489. playbackRate: -1,
  3490. defaultPlaybackRate: -1,
  3491. seekable: [],
  3492. played: [],
  3493. paused: !0,
  3494. ended: !1,
  3495. seeking: !1,
  3496. duration: 0,
  3497. error: null,
  3498. tagName: "",
  3499. muted: !1,
  3500. volume: 1,
  3501. currentTime: 0,
  3502. play: function () {
  3503. null != this.pluginApi && ("youtube" == this.pluginType ? this.pluginApi.playVideo() : this.pluginApi.playMedia(), this.paused = !1)
  3504. },
  3505. load: function () {
  3506. null != this.pluginApi && ("youtube" != this.pluginType && this.pluginApi.loadMedia(), this.paused = !1)
  3507. },
  3508. pause: function () {
  3509. null != this.pluginApi && ("youtube" == this.pluginType ? this.pluginApi.pauseVideo() : this.pluginApi.pauseMedia(), this.paused = !0)
  3510. },
  3511. stop: function () {
  3512. null != this.pluginApi && ("youtube" == this.pluginType ? this.pluginApi.stopVideo() : this.pluginApi.stopMedia(), this.paused = !0)
  3513. },
  3514. canPlayType: function (a) {
  3515. var b, c, d, e = mejs.plugins[this.pluginType];
  3516. for (b = 0; b < e.length; b++)if (d = e[b], mejs.PluginDetector.hasPluginVersion(this.pluginType, d.version))for (c = 0; c < d.types.length; c++)if (a == d.types[c])return "probably";
  3517. return ""
  3518. },
  3519. positionFullscreenButton: function (a, b, c) {
  3520. null != this.pluginApi && this.pluginApi.positionFullscreenButton && this.pluginApi.positionFullscreenButton(Math.floor(a), Math.floor(b), c)
  3521. },
  3522. hideFullscreenButton: function () {
  3523. null != this.pluginApi && this.pluginApi.hideFullscreenButton && this.pluginApi.hideFullscreenButton()
  3524. },
  3525. setSrc: function (a) {
  3526. if ("string" == typeof a)this.pluginApi.setSrc(mejs.Utility.absolutizeUrl(a)), this.src = mejs.Utility.absolutizeUrl(a); else {
  3527. var b, c;
  3528. for (b = 0; b < a.length; b++)if (c = a[b], this.canPlayType(c.type)) {
  3529. this.pluginApi.setSrc(mejs.Utility.absolutizeUrl(c.src)), this.src = mejs.Utility.absolutizeUrl(a);
  3530. break
  3531. }
  3532. }
  3533. },
  3534. setCurrentTime: function (a) {
  3535. null != this.pluginApi && ("youtube" == this.pluginType ? this.pluginApi.seekTo(a) : this.pluginApi.setCurrentTime(a), this.currentTime = a)
  3536. },
  3537. setVolume: function (a) {
  3538. null != this.pluginApi && ("youtube" == this.pluginType ? this.pluginApi.setVolume(100 * a) : this.pluginApi.setVolume(a), this.volume = a)
  3539. },
  3540. setMuted: function (a) {
  3541. null != this.pluginApi && ("youtube" == this.pluginType ? (a ? this.pluginApi.mute() : this.pluginApi.unMute(), this.muted = a, this.dispatchEvent("volumechange")) : this.pluginApi.setMuted(a), this.muted = a)
  3542. },
  3543. setVideoSize: function (a, b) {
  3544. this.pluginElement.style && (this.pluginElement.style.width = a + "px", this.pluginElement.style.height = b + "px"), null != this.pluginApi && this.pluginApi.setVideoSize && this.pluginApi.setVideoSize(a, b)
  3545. },
  3546. setFullscreen: function (a) {
  3547. null != this.pluginApi && this.pluginApi.setFullscreen && this.pluginApi.setFullscreen(a)
  3548. },
  3549. enterFullScreen: function () {
  3550. null != this.pluginApi && this.pluginApi.setFullscreen && this.setFullscreen(!0)
  3551. },
  3552. exitFullScreen: function () {
  3553. null != this.pluginApi && this.pluginApi.setFullscreen && this.setFullscreen(!1)
  3554. },
  3555. addEventListener: function (a, b) {
  3556. this.events[a] = this.events[a] || [], this.events[a].push(b)
  3557. },
  3558. removeEventListener: function (a, b) {
  3559. if (!a)return this.events = {}, !0;
  3560. var c = this.events[a];
  3561. if (!c)return !0;
  3562. if (!b)return this.events[a] = [], !0;
  3563. for (i = 0; i < c.length; i++)if (c[i] === b)return this.events[a].splice(i, 1), !0;
  3564. return !1
  3565. },
  3566. dispatchEvent: function (a) {
  3567. var b, c, d = this.events[a];
  3568. if (d)for (c = Array.prototype.slice.call(arguments, 1), b = 0; b < d.length; b++)d[b].apply(null, c)
  3569. },
  3570. hasAttribute: function (a) {
  3571. return a in this.attributes
  3572. },
  3573. removeAttribute: function (a) {
  3574. delete this.attributes[a]
  3575. },
  3576. getAttribute: function (a) {
  3577. return this.hasAttribute(a) ? this.attributes[a] : ""
  3578. },
  3579. setAttribute: function (a, b) {
  3580. this.attributes[a] = b
  3581. },
  3582. remove: function () {
  3583. mejs.Utility.removeSwf(this.pluginElement.id), mejs.MediaPluginBridge.unregisterPluginElement(this.pluginElement.id)
  3584. }
  3585. }, mejs.MediaPluginBridge = {
  3586. pluginMediaElements: {}, htmlMediaElements: {}, registerPluginElement: function (a, b, c) {
  3587. this.pluginMediaElements[a] = b, this.htmlMediaElements[a] = c
  3588. }, unregisterPluginElement: function (a) {
  3589. delete this.pluginMediaElements[a], delete this.htmlMediaElements[a]
  3590. }, initPlugin: function (a) {
  3591. var b = this.pluginMediaElements[a], c = this.htmlMediaElements[a];
  3592. if (b) {
  3593. switch (b.pluginType) {
  3594. case"flash":
  3595. b.pluginElement = b.pluginApi = document.getElementById(a);
  3596. break;
  3597. case"silverlight":
  3598. b.pluginElement = document.getElementById(b.id), b.pluginApi = b.pluginElement.Content.MediaElementJS
  3599. }
  3600. null != b.pluginApi && b.success && b.success(b, c)
  3601. }
  3602. }, fireEvent: function (a, b, c) {
  3603. var d, e;
  3604. if (a = this.pluginMediaElements[a]) {
  3605. b = {type: b, target: a};
  3606. for (d in c)a[d] = c[d], b[d] = c[d];
  3607. e = c.bufferedTime || 0, b.target.buffered = b.buffered = {
  3608. start: function () {
  3609. return 0
  3610. }, end: function () {
  3611. return e
  3612. }, length: 1
  3613. }, a.dispatchEvent(b.type, b)
  3614. }
  3615. }
  3616. }, mejs.MediaElementDefaults = {
  3617. mode: "auto",
  3618. plugins: ["flash", "silverlight", "youtube", "vimeo"],
  3619. enablePluginDebug: !1,
  3620. httpsBasicAuthSite: !1,
  3621. type: "",
  3622. pluginPath: mejs.Utility.getScriptPath(["mediaelement.js", "mediaelement.min.js", "mediaelement-and-player.js", "mediaelement-and-player.min.js"]),
  3623. flashName: "flashmediaelement.swf",
  3624. flashStreamer: "",
  3625. enablePluginSmoothing: !1,
  3626. enablePseudoStreaming: !1,
  3627. pseudoStreamingStartQueryParam: "start",
  3628. silverlightName: "silverlightmediaelement.xap",
  3629. defaultVideoWidth: 480,
  3630. defaultVideoHeight: 270,
  3631. pluginWidth: -1,
  3632. pluginHeight: -1,
  3633. pluginVars: [],
  3634. timerRate: 250,
  3635. startVolume: .8,
  3636. success: function () {
  3637. },
  3638. error: function () {
  3639. }
  3640. }, mejs.MediaElement = function (a, b) {
  3641. return mejs.HtmlMediaElementShim.create(a, b)
  3642. }, mejs.HtmlMediaElementShim = {
  3643. create: function (a, b) {
  3644. var c = mejs.MediaElementDefaults, d = "string" == typeof a ? document.getElementById(a) : a, e = d.tagName.toLowerCase(), f = "audio" === e || "video" === e, g = f ? d.getAttribute("src") : d.getAttribute("href");
  3645. e = d.getAttribute("poster");
  3646. var h, i = d.getAttribute("autoplay"), j = d.getAttribute("preload"), k = d.getAttribute("controls");
  3647. for (h in b)c[h] = b[h];
  3648. return g = "undefined" == typeof g || null === g || "" == g ? null : g, e = "undefined" == typeof e || null === e ? "" : e, j = "undefined" == typeof j || null === j || "false" === j ? "none" : j, i = !("undefined" == typeof i || null === i || "false" === i), k = !("undefined" == typeof k || null === k || "false" === k), h = this.determinePlayback(d, c, mejs.MediaFeatures.supportsMediaTag, f, g), h.url = null !== h.url ? mejs.Utility.absolutizeUrl(h.url) : "", "native" == h.method ? (mejs.MediaFeatures.isBustedAndroid && (d.src = h.url, d.addEventListener("click", function () {
  3649. d.play()
  3650. }, !1)), this.updateNative(h, c, i, j)) : "" !== h.method ? this.createPlugin(h, c, e, i, j, k) : (this.createErrorMessage(h, c, e), this)
  3651. }, determinePlayback: function (a, b, c, d, e) {
  3652. var f, g, h, i, j = [], k = {
  3653. method: "",
  3654. url: "",
  3655. htmlMediaElement: a,
  3656. isVideo: "audio" != a.tagName.toLowerCase()
  3657. };
  3658. if ("undefined" != typeof b.type && "" !== b.type)if ("string" == typeof b.type)j.push({
  3659. type: b.type,
  3660. url: e
  3661. }); else for (f = 0; f < b.type.length; f++)j.push({
  3662. type: b.type[f],
  3663. url: e
  3664. }); else if (null !== e)h = this.formatType(e, a.getAttribute("type")), j.push({
  3665. type: h,
  3666. url: e
  3667. }); else for (f = 0; f < a.childNodes.length; f++)g = a.childNodes[f], 1 == g.nodeType && "source" == g.tagName.toLowerCase() && (e = g.getAttribute("src"), h = this.formatType(e, g.getAttribute("type")), g = g.getAttribute("media"), (!g || !window.matchMedia || window.matchMedia && window.matchMedia(g).matches) && j.push({
  3668. type: h,
  3669. url: e
  3670. }));
  3671. if (!d && j.length > 0 && null !== j[0].url && this.getTypeFromFile(j[0].url).indexOf("audio") > -1 && (k.isVideo = !1), mejs.MediaFeatures.isBustedAndroid && (a.canPlayType = function (a) {
  3672. return null !== a.match(/video\/(mp4|m4v)/gi) ? "maybe" : ""
  3673. }), !(!c || "auto" !== b.mode && "auto_plugin" !== b.mode && "native" !== b.mode || mejs.MediaFeatures.isBustedNativeHTTPS && b.httpsBasicAuthSite === !0)) {
  3674. for (d || (f = document.createElement(k.isVideo ? "video" : "audio"), a.parentNode.insertBefore(f, a), a.style.display = "none", k.htmlMediaElement = a = f), f = 0; f < j.length; f++)if ("" !== a.canPlayType(j[f].type).replace(/no/, "") || "" !== a.canPlayType(j[f].type.replace(/mp3/, "mpeg")).replace(/no/, "")) {
  3675. k.method = "native", k.url = j[f].url;
  3676. break
  3677. }
  3678. if ("native" === k.method && (null !== k.url && (a.src = k.url), "auto_plugin" !== b.mode))return k
  3679. }
  3680. if ("auto" === b.mode || "auto_plugin" === b.mode || "shim" === b.mode)for (f = 0; f < j.length; f++)for (h = j[f].type, a = 0; a < b.plugins.length; a++)for (e = b.plugins[a], g = mejs.plugins[e], c = 0; c < g.length; c++)if (i = g[c], null == i.version || mejs.PluginDetector.hasPluginVersion(e, i.version))for (d = 0; d < i.types.length; d++)if (h == i.types[d])return k.method = e, k.url = j[f].url, k;
  3681. return "auto_plugin" === b.mode && "native" === k.method ? k : ("" === k.method && j.length > 0 && (k.url = j[0].url), k)
  3682. }, formatType: function (a, b) {
  3683. return a && !b ? this.getTypeFromFile(a) : b && ~b.indexOf(";") ? b.substr(0, b.indexOf(";")) : b
  3684. }, getTypeFromFile: function (a) {
  3685. return a = a.split("?")[0], a = a.substring(a.lastIndexOf(".") + 1).toLowerCase(), (/(mp4|m4v|ogg|ogv|webm|webmv|flv|wmv|mpeg|mov)/gi.test(a) ? "video" : "audio") + "/" + this.getTypeFromExtension(a)
  3686. }, getTypeFromExtension: function (a) {
  3687. switch (a) {
  3688. case"mp4":
  3689. case"m4v":
  3690. return "mp4";
  3691. case"webm":
  3692. case"webma":
  3693. case"webmv":
  3694. return "webm";
  3695. case"ogg":
  3696. case"oga":
  3697. case"ogv":
  3698. return "ogg";
  3699. default:
  3700. return a
  3701. }
  3702. }, createErrorMessage: function (a, b, c) {
  3703. var d = a.htmlMediaElement, e = document.createElement("div");
  3704. e.className = "me-cannotplay";
  3705. try {
  3706. e.style.width = d.width + "px", e.style.height = d.height + "px"
  3707. } catch (f) {
  3708. }
  3709. e.innerHTML = b.customError ? b.customError : "" !== c ? '<a href="' + a.url + '"><img src="' + c + '" width="100%" height="100%" /></a>' : '<a href="' + a.url + '"><span>' + mejs.i18n.t("Download File") + "</span></a>", d.parentNode.insertBefore(e, d), d.style.display = "none", b.error(d)
  3710. }, createPlugin: function (a, b, c, d, e, f) {
  3711. c = a.htmlMediaElement;
  3712. var g, h = 1, i = 1, j = "me_" + a.method + "_" + mejs.meIndex++, k = new mejs.PluginMediaElement(j, a.method, a.url), l = document.createElement("div");
  3713. for (k.tagName = c.tagName, g = 0; g < c.attributes.length; g++) {
  3714. var m = c.attributes[g];
  3715. 1 == m.specified && k.setAttribute(m.name, m.value)
  3716. }
  3717. for (g = c.parentNode; null !== g && "body" != g.tagName.toLowerCase();) {
  3718. if ("p" == g.parentNode.tagName.toLowerCase()) {
  3719. g.parentNode.parentNode.insertBefore(g, g.parentNode);
  3720. break
  3721. }
  3722. g = g.parentNode
  3723. }
  3724. switch (a.isVideo ? (h = b.pluginWidth > 0 ? b.pluginWidth : b.videoWidth > 0 ? b.videoWidth : null !== c.getAttribute("width") ? c.getAttribute("width") : b.defaultVideoWidth, i = b.pluginHeight > 0 ? b.pluginHeight : b.videoHeight > 0 ? b.videoHeight : null !== c.getAttribute("height") ? c.getAttribute("height") : b.defaultVideoHeight, h = mejs.Utility.encodeUrl(h), i = mejs.Utility.encodeUrl(i)) : b.enablePluginDebug && (h = 320, i = 240), k.success = b.success, mejs.MediaPluginBridge.registerPluginElement(j, k, c), l.className = "me-plugin", l.id = j + "_container", a.isVideo ? c.parentNode.insertBefore(l, c) : document.body.insertBefore(l, document.body.childNodes[0]), d = ["id=" + j, "isvideo=" + (a.isVideo ? "true" : "false"), "autoplay=" + (d ? "true" : "false"), "preload=" + e, "width=" + h, "startvolume=" + b.startVolume, "timerrate=" + b.timerRate, "flashstreamer=" + b.flashStreamer, "height=" + i, "pseudostreamstart=" + b.pseudoStreamingStartQueryParam], null !== a.url && ("flash" == a.method ? d.push("file=" + mejs.Utility.encodeUrl(a.url)) : d.push("file=" + a.url)), b.enablePluginDebug && d.push("debug=true"), b.enablePluginSmoothing && d.push("smoothing=true"), b.enablePseudoStreaming && d.push("pseudostreaming=true"), f && d.push("controls=true"), b.pluginVars && (d = d.concat(b.pluginVars)), a.method) {
  3725. case"silverlight":
  3726. l.innerHTML = '<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" id="' + j + '" name="' + j + '" width="' + h + '" height="' + i + '" class="mejs-shim"><param name="initParams" value="' + d.join(",") + '" /><param name="windowless" value="true" /><param name="background" value="black" /><param name="minRuntimeVersion" value="3.0.0.0" /><param name="autoUpgrade" value="true" /><param name="source" value="' + b.pluginPath + b.silverlightName + '" /></object>';
  3727. break;
  3728. case"flash":
  3729. mejs.MediaFeatures.isIE ? (a = document.createElement("div"), l.appendChild(a), a.outerHTML = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="//download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab" id="' + j + '" width="' + h + '" height="' + i + '" class="mejs-shim"><param name="movie" value="' + b.pluginPath + b.flashName + "?x=" + new Date + '" /><param name="flashvars" value="' + d.join("&amp;") + '" /><param name="quality" value="high" /><param name="bgcolor" value="#000000" /><param name="wmode" value="transparent" /><param name="allowScriptAccess" value="always" /><param name="allowFullScreen" value="true" /></object>') : l.innerHTML = '<embed id="' + j + '" name="' + j + '" play="true" loop="false" quality="high" bgcolor="#000000" wmode="transparent" allowScriptAccess="always" allowFullScreen="true" type="application/x-shockwave-flash" pluginspage="//www.macromedia.com/go/getflashplayer" src="' + b.pluginPath + b.flashName + '" flashvars="' + d.join("&") + '" width="' + h + '" height="' + i + '" class="mejs-shim"></embed>';
  3730. break;
  3731. case"youtube":
  3732. b = a.url.substr(a.url.lastIndexOf("=") + 1), youtubeSettings = {
  3733. container: l,
  3734. containerId: l.id,
  3735. pluginMediaElement: k,
  3736. pluginId: j,
  3737. videoId: b,
  3738. height: i,
  3739. width: h
  3740. }, mejs.PluginDetector.hasPluginVersion("flash", [10, 0, 0]) ? mejs.YouTubeApi.createFlash(youtubeSettings) : mejs.YouTubeApi.enqueueIframe(youtubeSettings);
  3741. break;
  3742. case"vimeo":
  3743. k.vimeoid = a.url.substr(a.url.lastIndexOf("/") + 1), l.innerHTML = '<iframe src="http://player.vimeo.com/video/' + k.vimeoid + '?portrait=0&byline=0&title=0" width="' + h + '" height="' + i + '" frameborder="0" class="mejs-shim"></iframe>'
  3744. }
  3745. return c.style.display = "none", c.removeAttribute("autoplay"), k
  3746. }, updateNative: function (a, b) {
  3747. var c, d = a.htmlMediaElement;
  3748. for (c in mejs.HtmlMediaElement)d[c] = mejs.HtmlMediaElement[c];
  3749. return b.success(d, d), d
  3750. }
  3751. }, mejs.YouTubeApi = {
  3752. isIframeStarted: !1, isIframeLoaded: !1, loadIframeApi: function () {
  3753. if (!this.isIframeStarted) {
  3754. var a = document.createElement("script");
  3755. a.src = "//www.youtube.com/player_api";
  3756. var b = document.getElementsByTagName("script")[0];
  3757. b.parentNode.insertBefore(a, b), this.isIframeStarted = !0
  3758. }
  3759. }, iframeQueue: [], enqueueIframe: function (a) {
  3760. this.isLoaded ? this.createIframe(a) : (this.loadIframeApi(), this.iframeQueue.push(a))
  3761. }, createIframe: function (a) {
  3762. var b = a.pluginMediaElement, c = new YT.Player(a.containerId, {
  3763. height: a.height,
  3764. width: a.width,
  3765. videoId: a.videoId,
  3766. playerVars: {controls: 0},
  3767. events: {
  3768. onReady: function () {
  3769. a.pluginMediaElement.pluginApi = c, mejs.MediaPluginBridge.initPlugin(a.pluginId), setInterval(function () {
  3770. mejs.YouTubeApi.createEvent(c, b, "timeupdate")
  3771. }, 250)
  3772. }, onStateChange: function (a) {
  3773. mejs.YouTubeApi.handleStateChange(a.data, c, b)
  3774. }
  3775. }
  3776. })
  3777. }, createEvent: function (a, b, c) {
  3778. if (c = {type: c, target: b}, a && a.getDuration) {
  3779. b.currentTime = c.currentTime = a.getCurrentTime(), b.duration = c.duration = a.getDuration(), c.paused = b.paused, c.ended = b.ended, c.muted = a.isMuted(), c.volume = a.getVolume() / 100, c.bytesTotal = a.getVideoBytesTotal(), c.bufferedBytes = a.getVideoBytesLoaded();
  3780. var d = c.bufferedBytes / c.bytesTotal * c.duration;
  3781. c.target.buffered = c.buffered = {
  3782. start: function () {
  3783. return 0
  3784. }, end: function () {
  3785. return d
  3786. }, length: 1
  3787. }
  3788. }
  3789. b.dispatchEvent(c.type, c)
  3790. }, iFrameReady: function () {
  3791. for (this.isIframeLoaded = this.isLoaded = !0; this.iframeQueue.length > 0;)this.createIframe(this.iframeQueue.pop())
  3792. }, flashPlayers: {}, createFlash: function (a) {
  3793. this.flashPlayers[a.pluginId] = a;
  3794. var b, c = "//www.youtube.com/apiplayer?enablejsapi=1&amp;playerapiid=" + a.pluginId + "&amp;version=3&amp;autoplay=0&amp;controls=0&amp;modestbranding=1&loop=0";
  3795. mejs.MediaFeatures.isIE ? (b = document.createElement("div"), a.container.appendChild(b), b.outerHTML = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="//download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab" id="' + a.pluginId + '" width="' + a.width + '" height="' + a.height + '" class="mejs-shim"><param name="movie" value="' + c + '" /><param name="wmode" value="transparent" /><param name="allowScriptAccess" value="always" /><param name="allowFullScreen" value="true" /></object>') : a.container.innerHTML = '<object type="application/x-shockwave-flash" id="' + a.pluginId + '" data="' + c + '" width="' + a.width + '" height="' + a.height + '" style="visibility: visible; " class="mejs-shim"><param name="allowScriptAccess" value="always"><param name="wmode" value="transparent"></object>'
  3796. }, flashReady: function (a) {
  3797. var b = this.flashPlayers[a], c = document.getElementById(a), d = b.pluginMediaElement;
  3798. d.pluginApi = d.pluginElement = c, mejs.MediaPluginBridge.initPlugin(a), c.cueVideoById(b.videoId), a = b.containerId + "_callback", window[a] = function (a) {
  3799. mejs.YouTubeApi.handleStateChange(a, c, d)
  3800. }, c.addEventListener("onStateChange", a), setInterval(function () {
  3801. mejs.YouTubeApi.createEvent(c, d, "timeupdate")
  3802. }, 250)
  3803. }, handleStateChange: function (a, b, c) {
  3804. switch (a) {
  3805. case-1:
  3806. c.paused = !0, c.ended = !0, mejs.YouTubeApi.createEvent(b, c, "loadedmetadata");
  3807. break;
  3808. case 0:
  3809. c.paused = !1, c.ended = !0, mejs.YouTubeApi.createEvent(b, c, "ended");
  3810. break;
  3811. case 1:
  3812. c.paused = !1, c.ended = !1, mejs.YouTubeApi.createEvent(b, c, "play"), mejs.YouTubeApi.createEvent(b, c, "playing");
  3813. break;
  3814. case 2:
  3815. c.paused = !0, c.ended = !1, mejs.YouTubeApi.createEvent(b, c, "pause");
  3816. break;
  3817. case 3:
  3818. mejs.YouTubeApi.createEvent(b, c, "progress")
  3819. }
  3820. }
  3821. }, window.mejs = mejs, window.MediaElement = mejs.MediaElement, function (a, b) {
  3822. var c = {locale: {language: "", strings: {}}, methods: {}};
  3823. c.locale.getLanguage = function () {
  3824. return c.locale.language || navigator.language
  3825. }, "undefined" != typeof mejsL10n && (c.locale.language = mejsL10n.language), c.locale.INIT_LANGUAGE = c.locale.getLanguage(), c.methods.checkPlain = function (a) {
  3826. var b, c, d = {"&": "&amp;", '"': "&quot;", "<": "&lt;", ">": "&gt;"};
  3827. a = String(a);
  3828. for (b in d)d.hasOwnProperty(b) && (c = RegExp(b, "g"), a = a.replace(c, d[b]));
  3829. return a
  3830. }, c.methods.formatString = function (a, b) {
  3831. for (var d in b) {
  3832. switch (d.charAt(0)) {
  3833. case"@":
  3834. b[d] = c.methods.checkPlain(b[d]);
  3835. break;
  3836. case"!":
  3837. break;
  3838. default:
  3839. b[d] = '<em class="placeholder">' + c.methods.checkPlain(b[d]) + "</em>"
  3840. }
  3841. a = a.replace(d, b[d])
  3842. }
  3843. return a
  3844. }, c.methods.t = function (a, b, d) {
  3845. return c.locale.strings && c.locale.strings[d.context] && c.locale.strings[d.context][a] && (a = c.locale.strings[d.context][a]), b && (a = c.methods.formatString(a, b)), a
  3846. }, c.t = function (a, b, d) {
  3847. if ("string" == typeof a && a.length > 0) {
  3848. var e = c.locale.getLanguage();
  3849. return d = d || {context: e}, c.methods.t(a, b, d)
  3850. }
  3851. throw{name: "InvalidArgumentException", message: "First argument is either not a string or empty."}
  3852. }, b.i18n = c
  3853. }(document, mejs), function (a) {
  3854. "undefined" != typeof mejsL10n && (a[mejsL10n.language] = mejsL10n.strings)
  3855. }(mejs.i18n.locale.strings), function (a) {
  3856. a.de = {
  3857. Fullscreen: "Vollbild",
  3858. "Go Fullscreen": "Vollbild an",
  3859. "Turn off Fullscreen": "Vollbild aus",
  3860. Close: "Schließen"
  3861. }
  3862. }(mejs.i18n.locale.strings), function (a) {
  3863. a.zh = {Fullscreen: "全螢幕", "Go Fullscreen": "全屏模式", "Turn off Fullscreen": "退出全屏模式", Close: "關閉"}
  3864. }(mejs.i18n.locale.strings), "undefined" != typeof jQuery ? mejs.$ = jQuery : "undefined" != typeof ender && (mejs.$ = ender), function (a) {
  3865. mejs.MepDefaults = {
  3866. poster: "",
  3867. showPosterWhenEnded: !1,
  3868. defaultVideoWidth: 480,
  3869. defaultVideoHeight: 270,
  3870. videoWidth: -1,
  3871. videoHeight: -1,
  3872. defaultAudioWidth: 400,
  3873. defaultAudioHeight: 30,
  3874. defaultSeekBackwardInterval: function (a) {
  3875. return .05 * a.duration
  3876. },
  3877. defaultSeekForwardInterval: function (a) {
  3878. return .05 * a.duration
  3879. },
  3880. audioWidth: -1,
  3881. audioHeight: -1,
  3882. startVolume: .8,
  3883. loop: !1,
  3884. autoRewind: !0,
  3885. enableAutosize: !0,
  3886. alwaysShowHours: !1,
  3887. showTimecodeFrameCount: !1,
  3888. framesPerSecond: 25,
  3889. autosizeProgress: !0,
  3890. alwaysShowControls: !1,
  3891. hideVideoControlsOnLoad: !1,
  3892. clickToPlayPause: !0,
  3893. iPadUseNativeControls: !1,
  3894. iPhoneUseNativeControls: !1,
  3895. AndroidUseNativeControls: !1,
  3896. features: ["playpause", "current", "progress", "duration", "tracks", "volume", "fullscreen"],
  3897. isVideo: !0,
  3898. enableKeyboard: !0,
  3899. pauseOtherPlayers: !0,
  3900. keyActions: [{
  3901. keys: [32, 179], action: function (a, b) {
  3902. b.paused || b.ended ? b.play() : b.pause()
  3903. }
  3904. }, {
  3905. keys: [38], action: function (a, b) {
  3906. b.setVolume(Math.min(b.volume + .1, 1))
  3907. }
  3908. }, {
  3909. keys: [40], action: function (a, b) {
  3910. b.setVolume(Math.max(b.volume - .1, 0))
  3911. }
  3912. }, {
  3913. keys: [37, 227], action: function (a, b) {
  3914. if (!isNaN(b.duration) && b.duration > 0) {
  3915. a.isVideo && (a.showControls(), a.startControlsTimer());
  3916. var c = Math.max(b.currentTime - a.options.defaultSeekBackwardInterval(b), 0);
  3917. b.setCurrentTime(c)
  3918. }
  3919. }
  3920. }, {
  3921. keys: [39, 228], action: function (a, b) {
  3922. if (!isNaN(b.duration) && b.duration > 0) {
  3923. a.isVideo && (a.showControls(), a.startControlsTimer());
  3924. var c = Math.min(b.currentTime + a.options.defaultSeekForwardInterval(b), b.duration);
  3925. b.setCurrentTime(c)
  3926. }
  3927. }
  3928. }, {
  3929. keys: [70], action: function (a) {
  3930. "undefined" != typeof a.enterFullScreen && (a.isFullScreen ? a.exitFullScreen() : a.enterFullScreen())
  3931. }
  3932. }]
  3933. }, mejs.mepIndex = 0, mejs.players = {}, mejs.MediaElementPlayer = function (b, c) {
  3934. return this instanceof mejs.MediaElementPlayer ? (this.$media = this.$node = a(b), this.node = this.media = this.$media[0], "undefined" != typeof this.node.player ? this.node.player : (this.node.player = this, "undefined" == typeof c && (c = this.$node.data("mejsoptions")), this.options = a.extend({}, mejs.MepDefaults, c), this.id = "mep_" + mejs.mepIndex++, mejs.players[this.id] = this, this.init(), this)) : new mejs.MediaElementPlayer(b, c)
  3935. }, mejs.MediaElementPlayer.prototype = {
  3936. hasFocus: !1, controlsAreVisible: !0, init: function () {
  3937. var b = this, c = mejs.MediaFeatures, d = a.extend(!0, {}, b.options, {
  3938. success: function (a, c) {
  3939. b.meReady(a, c)
  3940. }, error: function (a) {
  3941. b.handleError(a)
  3942. }
  3943. }), e = b.media.tagName.toLowerCase();
  3944. b.isDynamic = "audio" !== e && "video" !== e, b.isVideo = b.isDynamic ? b.options.isVideo : "audio" !== e && b.options.isVideo, c.isiPad && b.options.iPadUseNativeControls || c.isiPhone && b.options.iPhoneUseNativeControls ? (b.$media.attr("controls", "controls"), c.isiPad && null !== b.media.getAttribute("autoplay") && (b.media.load(), b.media.play())) : c.isAndroid && b.options.AndroidUseNativeControls || (b.$media.removeAttr("controls"), b.container = a('<div id="' + b.id + '" class="mejs-container ' + (mejs.MediaFeatures.svg ? "svg" : "no-svg") + '"><div class="mejs-inner"><div class="mejs-mediaelement"></div><div class="mejs-layers"></div><div class="mejs-controls"></div><div class="mejs-clear"></div></div></div>').addClass(b.$media[0].className).insertBefore(b.$media), b.container.addClass((c.isAndroid ? "mejs-android " : "") + (c.isiOS ? "mejs-ios " : "") + (c.isiPad ? "mejs-ipad " : "") + (c.isiPhone ? "mejs-iphone " : "") + (b.isVideo ? "mejs-video " : "mejs-audio ")), c.isiOS ? (c = b.$media.clone(), b.container.find(".mejs-mediaelement").append(c), b.$media.remove(), b.$node = b.$media = c, b.node = b.media = c[0]) : b.container.find(".mejs-mediaelement").append(b.$media), b.controls = b.container.find(".mejs-controls"), b.layers = b.container.find(".mejs-layers"), c = b.isVideo ? "video" : "audio", e = c.substring(0, 1).toUpperCase() + c.substring(1), b.width = b.options[c + "Width"] > 0 || b.options[c + "Width"].toString().indexOf("%") > -1 ? b.options[c + "Width"] : "" !== b.media.style.width && null !== b.media.style.width ? b.media.style.width : null !== b.media.getAttribute("width") ? b.$media.attr("width") : b.options["default" + e + "Width"], b.height = b.options[c + "Height"] > 0 || b.options[c + "Height"].toString().indexOf("%") > -1 ? b.options[c + "Height"] : "" !== b.media.style.height && null !== b.media.style.height ? b.media.style.height : null !== b.$media[0].getAttribute("height") ? b.$media.attr("height") : b.options["default" + e + "Height"], b.setPlayerSize(b.width, b.height), d.pluginWidth = b.width, d.pluginHeight = b.height), mejs.MediaElement(b.$media[0], d), "undefined" != typeof b.container && b.controlsAreVisible && b.container.trigger("controlsshown")
  3945. }, showControls: function (a) {
  3946. var b = this;
  3947. a = "undefined" == typeof a || a, b.controlsAreVisible || (a ? (b.controls.css("visibility", "visible").stop(!0, !0).fadeIn(200, function () {
  3948. b.controlsAreVisible = !0, b.container.trigger("controlsshown")
  3949. }), b.container.find(".mejs-control").css("visibility", "visible").stop(!0, !0).fadeIn(200, function () {
  3950. b.controlsAreVisible = !0
  3951. })) : (b.controls.css("visibility", "visible").css("display", "block"), b.container.find(".mejs-control").css("visibility", "visible").css("display", "block"), b.controlsAreVisible = !0, b.container.trigger("controlsshown")), b.setControlsSize())
  3952. }, hideControls: function (b) {
  3953. var c = this;
  3954. b = "undefined" == typeof b || b, c.controlsAreVisible && !c.options.alwaysShowControls && (b ? (c.controls.stop(!0, !0).fadeOut(200, function () {
  3955. a(this).css("visibility", "hidden").css("display", "block"), c.controlsAreVisible = !1, c.container.trigger("controlshidden")
  3956. }), c.container.find(".mejs-control").stop(!0, !0).fadeOut(200, function () {
  3957. a(this).css("visibility", "hidden").css("display", "block")
  3958. })) : (c.controls.css("visibility", "hidden").css("display", "block"), c.container.find(".mejs-control").css("visibility", "hidden").css("display", "block"), c.controlsAreVisible = !1, c.container.trigger("controlshidden")))
  3959. }, controlsTimer: null, startControlsTimer: function (a) {
  3960. var b = this;
  3961. a = "undefined" != typeof a ? a : 1500, b.killControlsTimer("start"), b.controlsTimer = setTimeout(function () {
  3962. b.hideControls(), b.killControlsTimer("hide")
  3963. }, a)
  3964. }, killControlsTimer: function () {
  3965. null !== this.controlsTimer && (clearTimeout(this.controlsTimer), delete this.controlsTimer, this.controlsTimer = null)
  3966. }, controlsEnabled: !0, disableControls: function () {
  3967. this.killControlsTimer(), this.hideControls(!1), this.controlsEnabled = !1
  3968. }, enableControls: function () {
  3969. this.showControls(!1), this.controlsEnabled = !0
  3970. }, meReady: function (a, b) {
  3971. var c = this, d = mejs.MediaFeatures, e = b.getAttribute("autoplay");
  3972. e = !("undefined" == typeof e || null === e || "false" === e);
  3973. var f;
  3974. if (!c.created) {
  3975. if (c.created = !0, c.media = a, c.domNode = b, !(d.isAndroid && c.options.AndroidUseNativeControls || d.isiPad && c.options.iPadUseNativeControls || d.isiPhone && c.options.iPhoneUseNativeControls)) {
  3976. c.buildposter(c, c.controls, c.layers, c.media), c.buildkeyboard(c, c.controls, c.layers, c.media), c.buildoverlays(c, c.controls, c.layers, c.media), c.findTracks();
  3977. for (f in c.options.features)if (d = c.options.features[f], c["build" + d])try {
  3978. c["build" + d](c, c.controls, c.layers, c.media)
  3979. } catch (g) {
  3980. }
  3981. c.container.trigger("controlsready"), c.setPlayerSize(c.width, c.height), c.setControlsSize(), c.isVideo && (mejs.MediaFeatures.hasTouch ? c.$media.bind("touchstart", function () {
  3982. c.controlsAreVisible ? c.hideControls(!1) : c.controlsEnabled && c.showControls(!1)
  3983. }) : (mejs.MediaElementPlayer.prototype.clickToPlayPauseCallback = function () {
  3984. c.options.clickToPlayPause && (c.media.paused ? c.media.play() : c.media.pause())
  3985. }, c.media.addEventListener("click", c.clickToPlayPauseCallback, !1), c.container.bind("mouseenter mouseover", function () {
  3986. c.controlsEnabled && (c.options.alwaysShowControls || (c.killControlsTimer("enter"), c.showControls(), c.startControlsTimer(2500)))
  3987. }).bind("mousemove", function () {
  3988. c.controlsEnabled && (c.controlsAreVisible || c.showControls(), c.options.alwaysShowControls || c.startControlsTimer(2500))
  3989. }).bind("mouseleave", function () {
  3990. c.controlsEnabled && !c.media.paused && !c.options.alwaysShowControls && c.startControlsTimer(1e3)
  3991. })), c.options.hideVideoControlsOnLoad && c.hideControls(!1), e && !c.options.alwaysShowControls && c.hideControls(), c.options.enableAutosize && c.media.addEventListener("loadedmetadata", function (a) {
  3992. c.options.videoHeight <= 0 && null === c.domNode.getAttribute("height") && !isNaN(a.target.videoHeight) && (c.setPlayerSize(a.target.videoWidth, a.target.videoHeight), c.setControlsSize(), c.media.setVideoSize(a.target.videoWidth, a.target.videoHeight))
  3993. }, !1)), a.addEventListener("play", function () {
  3994. for (var a in mejs.players) {
  3995. var b = mejs.players[a];
  3996. b.id != c.id && c.options.pauseOtherPlayers && !b.paused && !b.ended && b.pause(), b.hasFocus = !1
  3997. }
  3998. c.hasFocus = !0
  3999. }, !1), c.media.addEventListener("ended", function () {
  4000. if (c.options.autoRewind)try {
  4001. c.media.setCurrentTime(0)
  4002. } catch (a) {
  4003. }
  4004. c.media.pause(), c.setProgressRail && c.setProgressRail(), c.setCurrentRail && c.setCurrentRail(), c.options.loop ? c.media.play() : !c.options.alwaysShowControls && c.controlsEnabled && c.showControls()
  4005. }, !1), c.media.addEventListener("loadedmetadata", function () {
  4006. c.updateDuration && c.updateDuration(), c.updateCurrent && c.updateCurrent(), c.isFullScreen || (c.setPlayerSize(c.width, c.height), c.setControlsSize())
  4007. }, !1), setTimeout(function () {
  4008. c.setPlayerSize(c.width, c.height), c.setControlsSize()
  4009. }, 50), c.globalBind("resize", function () {
  4010. c.isFullScreen || mejs.MediaFeatures.hasTrueNativeFullScreen && document.webkitIsFullScreen || c.setPlayerSize(c.width, c.height), c.setControlsSize()
  4011. }), "youtube" == c.media.pluginType && c.container.find(".mejs-overlay-play").hide()
  4012. }
  4013. e && "native" == a.pluginType && (a.load(), a.play()), c.options.success && ("string" == typeof c.options.success ? window[c.options.success](c.media, c.domNode, c) : c.options.success(c.media, c.domNode, c))
  4014. }
  4015. }, handleError: function (a) {
  4016. this.controls.hide(), this.options.error && this.options.error(a)
  4017. }, setPlayerSize: function (b, c) {
  4018. if ("undefined" != typeof b && (this.width = b), "undefined" != typeof c && (this.height = c), this.height.toString().indexOf("%") > 0 || "100%" === this.$node.css("max-width") || parseInt(this.$node.css("max-width").replace(/px/, ""), 10) / this.$node.offsetParent().width() === 1 || this.$node[0].currentStyle && "100%" === this.$node[0].currentStyle.maxWidth) {
  4019. var d = this.isVideo ? this.media.videoWidth && this.media.videoWidth > 0 ? this.media.videoWidth : this.options.defaultVideoWidth : this.options.defaultAudioWidth, e = this.isVideo ? this.media.videoHeight && this.media.videoHeight > 0 ? this.media.videoHeight : this.options.defaultVideoHeight : this.options.defaultAudioHeight, f = this.container.parent().closest(":visible").width();
  4020. d = this.isVideo || !this.options.autosizeProgress ? parseInt(f * e / d, 10) : e, "body" === this.container.parent()[0].tagName.toLowerCase() && (f = a(window).width(), d = a(window).height()), 0 != d && 0 != f && (this.container.width(f).height(d), this.$media.add(this.container.find(".mejs-shim")).width("100%").height("100%"), this.isVideo && this.media.setVideoSize && this.media.setVideoSize(f, d), this.layers.children(".mejs-layer").width("100%").height("100%"))
  4021. } else this.container.width(this.width).height(this.height), this.layers.children(".mejs-layer").width(this.width).height(this.height);
  4022. f = this.layers.find(".mejs-overlay-play"), d = f.find(".mejs-overlay-button"), f.height(this.container.height() - this.controls.height()), d.css("margin-top", "-" + (d.height() / 2 - this.controls.height() / 2).toString() + "px")
  4023. }, setControlsSize: function () {
  4024. var b = 0, c = 0, d = this.controls.find(".mejs-time-rail"), e = this.controls.find(".mejs-time-total");
  4025. this.controls.find(".mejs-time-current"), this.controls.find(".mejs-time-loaded");
  4026. var f = d.siblings();
  4027. this.options && !this.options.autosizeProgress && (c = parseInt(d.css("width"))), 0 !== c && c || (f.each(function () {
  4028. var c = a(this);
  4029. "absolute" != c.css("position") && c.is(":visible") && (b += a(this).outerWidth(!0))
  4030. }), c = this.controls.width() - b - (d.outerWidth(!0) - d.width())), d.width(c), e.width(c - (e.outerWidth(!0) - e.width())), this.setProgressRail && this.setProgressRail(), this.setCurrentRail && this.setCurrentRail()
  4031. }, buildposter: function (b, c, d, e) {
  4032. var f = a('<div class="mejs-poster mejs-layer"></div>').appendTo(d);
  4033. c = b.$media.attr("poster"), "" !== b.options.poster && (c = b.options.poster), "" !== c && null != c ? this.setPoster(c) : f.hide(), e.addEventListener("play", function () {
  4034. f.hide()
  4035. }, !1), b.options.showPosterWhenEnded && b.options.autoRewind && e.addEventListener("ended", function () {
  4036. f.show()
  4037. }, !1)
  4038. }, setPoster: function (b) {
  4039. var c = this.container.find(".mejs-poster"), d = c.find("img");
  4040. 0 == d.length && (d = a('<img width="100%" height="100%" />').appendTo(c)), d.attr("src", b), c.css({"background-image": "url(" + b + ")"})
  4041. }, buildoverlays: function (b, c, d, e) {
  4042. var f = this;
  4043. if (b.isVideo) {
  4044. var g = a('<div class="mejs-overlay mejs-layer"><div class="mejs-overlay-loading"><span></span></div></div>').hide().appendTo(d), h = a('<div class="mejs-overlay mejs-layer"><div class="mejs-overlay-error"></div></div>').hide().appendTo(d), i = a('<div class="mejs-overlay mejs-layer mejs-overlay-play"><div class="mejs-overlay-button"></div></div>').appendTo(d).click(function () {
  4045. f.options.clickToPlayPause && (e.paused ? e.play() : e.pause())
  4046. });
  4047. e.addEventListener("play", function () {
  4048. i.hide(), g.hide(), c.find(".mejs-time-buffering").hide(), h.hide()
  4049. }, !1), e.addEventListener("playing", function () {
  4050. i.hide(), g.hide(), c.find(".mejs-time-buffering").hide(), h.hide()
  4051. }, !1), e.addEventListener("seeking", function () {
  4052. g.show(), c.find(".mejs-time-buffering").show()
  4053. }, !1), e.addEventListener("seeked", function () {
  4054. g.hide(), c.find(".mejs-time-buffering").hide()
  4055. }, !1), e.addEventListener("pause", function () {
  4056. mejs.MediaFeatures.isiPhone || i.show()
  4057. }, !1), e.addEventListener("waiting", function () {
  4058. g.show(), c.find(".mejs-time-buffering").show()
  4059. }, !1), e.addEventListener("loadeddata", function () {
  4060. g.show(), c.find(".mejs-time-buffering").show()
  4061. }, !1), e.addEventListener("canplay", function () {
  4062. g.hide(), c.find(".mejs-time-buffering").hide()
  4063. }, !1), e.addEventListener("error", function () {
  4064. g.hide(), c.find(".mejs-time-buffering").hide(), h.show(), h.find("mejs-overlay-error").html("Error loading this resource")
  4065. }, !1)
  4066. }
  4067. }, buildkeyboard: function (b, c, d, e) {
  4068. this.globalBind("keydown", function (a) {
  4069. if (b.hasFocus && b.options.enableKeyboard)for (var c = 0, d = b.options.keyActions.length; d > c; c++)for (var f = b.options.keyActions[c], g = 0, h = f.keys.length; h > g; g++)if (a.keyCode == f.keys[g])return a.preventDefault(), f.action(b, e, a.keyCode), !1;
  4070. return !0
  4071. }), this.globalBind("click", function (c) {
  4072. 0 == a(c.target).closest(".mejs-container").length && (b.hasFocus = !1)
  4073. })
  4074. }, findTracks: function () {
  4075. var b = this, c = b.$media.find("track");
  4076. b.tracks = [], c.each(function (c, d) {
  4077. d = a(d), b.tracks.push({
  4078. srclang: d.attr("srclang") ? d.attr("srclang").toLowerCase() : "",
  4079. src: d.attr("src"),
  4080. kind: d.attr("kind"),
  4081. label: d.attr("label") || "",
  4082. entries: [],
  4083. isLoaded: !1
  4084. })
  4085. })
  4086. }, changeSkin: function (a) {
  4087. this.container[0].className = "mejs-container " + a, this.setPlayerSize(this.width, this.height), this.setControlsSize()
  4088. }, play: function () {
  4089. this.media.play()
  4090. }, pause: function () {
  4091. try {
  4092. this.media.pause()
  4093. } catch (a) {
  4094. }
  4095. }, load: function () {
  4096. this.media.load()
  4097. }, setMuted: function (a) {
  4098. this.media.setMuted(a)
  4099. }, setCurrentTime: function (a) {
  4100. this.media.setCurrentTime(a)
  4101. }, getCurrentTime: function () {
  4102. return this.media.currentTime
  4103. }, setVolume: function (a) {
  4104. this.media.setVolume(a)
  4105. }, getVolume: function () {
  4106. return this.media.volume
  4107. }, setSrc: function (a) {
  4108. this.media.setSrc(a)
  4109. }, remove: function () {
  4110. var a, b;
  4111. for (a in this.options.features)if (b = this.options.features[a], this["clean" + b])try {
  4112. this["clean" + b](this)
  4113. } catch (c) {
  4114. }
  4115. this.isDynamic ? this.$node.insertBefore(this.container) : (this.$media.prop("controls", !0), this.$node.clone().show().insertBefore(this.container), this.$node.remove()), "native" !== this.media.pluginType && this.media.remove(), delete mejs.players[this.id], this.container.remove(), this.globalUnbind(), delete this.node.player
  4116. }
  4117. }, function () {
  4118. function b(b, d) {
  4119. var e = {d: [], w: []};
  4120. return a.each((b || "").split(" "), function (a, b) {
  4121. var f = b + "." + d;
  4122. 0 === f.indexOf(".") ? (e.d.push(f), e.w.push(f)) : e[c.test(b) ? "w" : "d"].push(f)
  4123. }), e.d = e.d.join(" "), e.w = e.w.join(" "), e
  4124. }
  4125.  
  4126. var c = /^((after|before)print|(before)?unload|hashchange|message|o(ff|n)line|page(hide|show)|popstate|resize|storage)\b/;
  4127. mejs.MediaElementPlayer.prototype.globalBind = function (c, d, e) {
  4128. c = b(c, this.id), c.d && a(document).bind(c.d, d, e), c.w && a(window).bind(c.w, d, e)
  4129. }, mejs.MediaElementPlayer.prototype.globalUnbind = function (c, d) {
  4130. c = b(c, this.id), c.d && a(document).unbind(c.d, d), c.w && a(window).unbind(c.w, d)
  4131. }
  4132. }(), "undefined" != typeof jQuery && (jQuery.fn.mediaelementplayer = function (a) {
  4133. return a === !1 ? this.each(function () {
  4134. var a = jQuery(this).data("mediaelementplayer");
  4135. a && a.remove(), jQuery(this).removeData("mediaelementplayer")
  4136. }) : this.each(function () {
  4137. jQuery(this).data("mediaelementplayer", new mejs.MediaElementPlayer(this, a))
  4138. }), this
  4139. }), a(document).ready(function () {
  4140. a(".mejs-player").mediaelementplayer()
  4141. }), window.MediaElementPlayer = mejs.MediaElementPlayer
  4142. }(mejs.$), function (a) {
  4143. a.extend(mejs.MepDefaults, {playpauseText: mejs.i18n.t("Play/Pause")}), a.extend(MediaElementPlayer.prototype, {
  4144. buildplaypause: function (b, c, d, e) {
  4145. var f = a('<div class="mejs-button mejs-playpause-button mejs-play" ><button type="button" aria-controls="' + this.id + '" title="' + this.options.playpauseText + '" aria-label="' + this.options.playpauseText + '"></button></div>').appendTo(c).click(function (a) {
  4146. return a.preventDefault(), e.paused ? e.play() : e.pause(), !1
  4147. });
  4148. e.addEventListener("play", function () {
  4149. f.removeClass("mejs-play").addClass("mejs-pause")
  4150. }, !1), e.addEventListener("playing", function () {
  4151. f.removeClass("mejs-play").addClass("mejs-pause")
  4152. }, !1), e.addEventListener("pause", function () {
  4153. f.removeClass("mejs-pause").addClass("mejs-play")
  4154. }, !1), e.addEventListener("paused", function () {
  4155. f.removeClass("mejs-pause").addClass("mejs-play")
  4156. }, !1)
  4157. }
  4158. })
  4159. }(mejs.$), function (a) {
  4160. a.extend(mejs.MepDefaults, {stopText: "Stop"}), a.extend(MediaElementPlayer.prototype, {
  4161. buildstop: function (b, c, d, e) {
  4162. a('<div class="mejs-button mejs-stop-button mejs-stop"><button type="button" aria-controls="' + this.id + '" title="' + this.options.stopText + '" aria-label="' + this.options.stopText + '"></button></div>').appendTo(c).click(function () {
  4163. e.paused || e.pause(), e.currentTime > 0 && (e.setCurrentTime(0), e.pause(), c.find(".mejs-time-current").width("0px"), c.find(".mejs-time-handle").css("left", "0px"), c.find(".mejs-time-float-current").html(mejs.Utility.secondsToTimeCode(0)), c.find(".mejs-currenttime").html(mejs.Utility.secondsToTimeCode(0)), d.find(".mejs-poster").show())
  4164. })
  4165. }
  4166. })
  4167. }(mejs.$), function (a) {
  4168. a.extend(MediaElementPlayer.prototype, {
  4169. buildprogress: function (b, c, d, e) {
  4170. a('<div class="mejs-time-rail"><span class="mejs-time-total"><span class="mejs-time-buffering"></span><span class="mejs-time-loaded"></span><span class="mejs-time-current"></span><span class="mejs-time-handle"></span><span class="mejs-time-float"><span class="mejs-time-float-current">00:00</span><span class="mejs-time-float-corner"></span></span></span></div>').appendTo(c), c.find(".mejs-time-buffering").hide();
  4171. var f = this, g = c.find(".mejs-time-total");
  4172. d = c.find(".mejs-time-loaded");
  4173. var h = c.find(".mejs-time-current"), i = c.find(".mejs-time-handle"), j = c.find(".mejs-time-float"), k = c.find(".mejs-time-float-current"), l = function (a) {
  4174. a = a.pageX;
  4175. var b = g.offset(), c = g.outerWidth(!0), d = 0, f = d = 0;
  4176. e.duration && (a < b.left ? a = b.left : a > c + b.left && (a = c + b.left), f = a - b.left, d = f / c, d = .02 >= d ? 0 : d * e.duration, m && d !== e.currentTime && e.setCurrentTime(d), mejs.MediaFeatures.hasTouch || (j.css("left", f), k.html(mejs.Utility.secondsToTimeCode(d)), j.show()))
  4177. }, m = !1;
  4178. g.bind("mousedown", function (a) {
  4179. return 1 === a.which ? (m = !0, l(a), f.globalBind("mousemove.dur", function (a) {
  4180. l(a)
  4181. }), f.globalBind("mouseup.dur", function () {
  4182. m = !1, j.hide(), f.globalUnbind(".dur")
  4183. }), !1) : void 0
  4184. }).bind("mouseenter", function () {
  4185. f.globalBind("mousemove.dur", function (a) {
  4186. l(a)
  4187. }), mejs.MediaFeatures.hasTouch || j.show()
  4188. }).bind("mouseleave", function () {
  4189. m || (f.globalUnbind(".dur"), j.hide())
  4190. }), e.addEventListener("progress", function (a) {
  4191. b.setProgressRail(a), b.setCurrentRail(a)
  4192. }, !1), e.addEventListener("timeupdate", function (a) {
  4193. b.setProgressRail(a), b.setCurrentRail(a)
  4194. }, !1), f.loaded = d, f.total = g, f.current = h, f.handle = i
  4195. }, setProgressRail: function (a) {
  4196. var b = void 0 != a ? a.target : this.media, c = null;
  4197. b && b.buffered && b.buffered.length > 0 && b.buffered.end && b.duration ? c = b.buffered.end(0) / b.duration : b && void 0 != b.bytesTotal && b.bytesTotal > 0 && void 0 != b.bufferedBytes ? c = b.bufferedBytes / b.bytesTotal : a && a.lengthComputable && 0 != a.total && (c = a.loaded / a.total), null !== c && (c = Math.min(1, Math.max(0, c)), this.loaded && this.total && this.loaded.width(this.total.width() * c))
  4198. }, setCurrentRail: function () {
  4199. if (void 0 != this.media.currentTime && this.media.duration && this.total && this.handle) {
  4200. var a = Math.round(this.total.width() * this.media.currentTime / this.media.duration), b = a - Math.round(this.handle.outerWidth(!0) / 2);
  4201. this.current.width(a), this.handle.css("left", b)
  4202. }
  4203. }
  4204. })
  4205. }(mejs.$), function (a) {
  4206. a.extend(mejs.MepDefaults, {
  4207. duration: -1,
  4208. timeAndDurationSeparator: "<span> | </span>"
  4209. }), a.extend(MediaElementPlayer.prototype, {
  4210. buildcurrent: function (b, c, d, e) {
  4211. a('<div class="mejs-time"><span class="mejs-currenttime">' + (b.options.alwaysShowHours ? "00:" : "") + (b.options.showTimecodeFrameCount ? "00:00:00" : "00:00") + "</span></div>").appendTo(c), this.currenttime = this.controls.find(".mejs-currenttime"), e.addEventListener("timeupdate", function () {
  4212. b.updateCurrent()
  4213. }, !1)
  4214. }, buildduration: function (b, c, d, e) {
  4215. c.children().last().find(".mejs-currenttime").length > 0 ? a(this.options.timeAndDurationSeparator + '<span class="mejs-duration">' + (this.options.duration > 0 ? mejs.Utility.secondsToTimeCode(this.options.duration, this.options.alwaysShowHours || this.media.duration > 3600, this.options.showTimecodeFrameCount, this.options.framesPerSecond || 25) : (b.options.alwaysShowHours ? "00:" : "") + (b.options.showTimecodeFrameCount ? "00:00:00" : "00:00")) + "</span>").appendTo(c.find(".mejs-time")) : (c.find(".mejs-currenttime").parent().addClass("mejs-currenttime-container"), a('<div class="mejs-time mejs-duration-container"><span class="mejs-duration">' + (this.options.duration > 0 ? mejs.Utility.secondsToTimeCode(this.options.duration, this.options.alwaysShowHours || this.media.duration > 3600, this.options.showTimecodeFrameCount, this.options.framesPerSecond || 25) : (b.options.alwaysShowHours ? "00:" : "") + (b.options.showTimecodeFrameCount ? "00:00:00" : "00:00")) + "</span></div>").appendTo(c)), this.durationD = this.controls.find(".mejs-duration"), e.addEventListener("timeupdate", function () {
  4216. b.updateDuration()
  4217. }, !1)
  4218. }, updateCurrent: function () {
  4219. this.currenttime && this.currenttime.html(mejs.Utility.secondsToTimeCode(this.media.currentTime, this.options.alwaysShowHours || this.media.duration > 3600, this.options.showTimecodeFrameCount, this.options.framesPerSecond || 25))
  4220. }, updateDuration: function () {
  4221. this.container.toggleClass("mejs-long-video", this.media.duration > 3600), this.durationD && (this.options.duration > 0 || this.media.duration) && this.durationD.html(mejs.Utility.secondsToTimeCode(this.options.duration > 0 ? this.options.duration : this.media.duration, this.options.alwaysShowHours, this.options.showTimecodeFrameCount, this.options.framesPerSecond || 25))
  4222. }
  4223. })
  4224. }(mejs.$), function (a) {
  4225. a.extend(mejs.MepDefaults, {
  4226. muteText: mejs.i18n.t("Mute Toggle"),
  4227. hideVolumeOnTouchDevices: !0,
  4228. audioVolume: "horizontal",
  4229. videoVolume: "vertical"
  4230. }), a.extend(MediaElementPlayer.prototype, {
  4231. buildvolume: function (b, c, d, e) {
  4232. if (!mejs.MediaFeatures.hasTouch || !this.options.hideVolumeOnTouchDevices) {
  4233. var f = this, g = f.isVideo ? f.options.videoVolume : f.options.audioVolume, h = "horizontal" == g ? a('<div class="mejs-button mejs-volume-button mejs-mute"><button type="button" aria-controls="' + f.id + '" title="' + f.options.muteText + '" aria-label="' + f.options.muteText + '"></button></div><div class="mejs-horizontal-volume-slider"><div class="mejs-horizontal-volume-total"></div><div class="mejs-horizontal-volume-current"></div><div class="mejs-horizontal-volume-handle"></div></div>').appendTo(c) : a('<div class="mejs-button mejs-volume-button mejs-mute"><button type="button" aria-controls="' + f.id + '" title="' + f.options.muteText + '" aria-label="' + f.options.muteText + '"></button><div class="mejs-volume-slider"><div class="mejs-volume-total"></div><div class="mejs-volume-current"></div><div class="mejs-volume-handle"></div></div></div>').appendTo(c), i = f.container.find(".mejs-volume-slider, .mejs-horizontal-volume-slider"), j = f.container.find(".mejs-volume-total, .mejs-horizontal-volume-total"), k = f.container.find(".mejs-volume-current, .mejs-horizontal-volume-current"), l = f.container.find(".mejs-volume-handle, .mejs-horizontal-volume-handle"), m = function (a, b) {
  4234. if (i.is(":visible") || "undefined" != typeof b)if (a = Math.max(0, a), a = Math.min(a, 1), 0 == a ? h.removeClass("mejs-mute").addClass("mejs-unmute") : h.removeClass("mejs-unmute").addClass("mejs-mute"), "vertical" == g) {
  4235. var c = j.height(), d = j.position(), e = c - c * a;
  4236. l.css("top", Math.round(d.top + e - l.height() / 2)), k.height(c - e), k.css("top", d.top + e)
  4237. } else c = j.width(), d = j.position(), c *= a, l.css("left", Math.round(d.left + c - l.width() / 2)), k.width(Math.round(c)); else i.show(), m(a, !0), i.hide()
  4238. }, n = function (a) {
  4239. var b = null, c = j.offset();
  4240. if ("vertical" == g) {
  4241. if (b = j.height(), parseInt(j.css("top").replace(/px/, ""), 10), b = (b - (a.pageY - c.top)) / b, 0 == c.top || 0 == c.left)return
  4242. } else b = j.width(), b = (a.pageX - c.left) / b;
  4243. b = Math.max(0, b), b = Math.min(b, 1), m(b), 0 == b ? e.setMuted(!0) : e.setMuted(!1), e.setVolume(b)
  4244. }, o = !1, p = !1;
  4245. h.hover(function () {
  4246. i.show(), p = !0
  4247. }, function () {
  4248. p = !1, !o && "vertical" == g && i.hide()
  4249. }), i.bind("mouseover", function () {
  4250. p = !0
  4251. }).bind("mousedown", function (a) {
  4252. return n(a), f.globalBind("mousemove.vol", function (a) {
  4253. n(a)
  4254. }), f.globalBind("mouseup.vol", function () {
  4255. o = !1, f.globalUnbind(".vol"), !p && "vertical" == g && i.hide()
  4256. }), o = !0, !1
  4257. }), h.find("button").click(function () {
  4258. e.setMuted(!e.muted)
  4259. }), e.addEventListener("volumechange", function () {
  4260. o || (e.muted ? (m(0), h.removeClass("mejs-mute").addClass("mejs-unmute")) : (m(e.volume), h.removeClass("mejs-unmute").addClass("mejs-mute")))
  4261. }, !1), f.container.is(":visible") && (m(b.options.startVolume), 0 === b.options.startVolume && e.setMuted(!0), "native" === e.pluginType && e.setVolume(b.options.startVolume))
  4262. }
  4263. }
  4264. })
  4265. }(mejs.$), function (a) {
  4266. a.extend(mejs.MepDefaults, {
  4267. usePluginFullScreen: !0, newWindowCallback: function () {
  4268. return ""
  4269. }, fullscreenText: mejs.i18n.t("Fullscreen")
  4270. }), a.extend(MediaElementPlayer.prototype, {
  4271. isFullScreen: !1,
  4272. isNativeFullScreen: !1,
  4273. isInIframe: !1,
  4274. buildfullscreen: function (b, c, d, e) {
  4275. if (b.isVideo) {
  4276. b.isInIframe = window.location != window.parent.location, mejs.MediaFeatures.hasTrueNativeFullScreen && (d = function () {
  4277. b.isFullScreen && (mejs.MediaFeatures.isFullScreen() ? (b.isNativeFullScreen = !0, b.setControlsSize()) : (b.isNativeFullScreen = !1, b.exitFullScreen()))
  4278. }, mejs.MediaFeatures.hasMozNativeFullScreen ? b.globalBind(mejs.MediaFeatures.fullScreenEventName, d) : b.container.bind(mejs.MediaFeatures.fullScreenEventName, d));
  4279. var f = this, g = a('<div class="mejs-button mejs-fullscreen-button"><button type="button" aria-controls="' + f.id + '" title="' + f.options.fullscreenText + '" aria-label="' + f.options.fullscreenText + '"></button></div>').appendTo(c);
  4280. if ("native" === f.media.pluginType || !f.options.usePluginFullScreen && !mejs.MediaFeatures.isFirefox)g.click(function () {
  4281. mejs.MediaFeatures.hasTrueNativeFullScreen && mejs.MediaFeatures.isFullScreen() || b.isFullScreen ? b.exitFullScreen() : b.enterFullScreen()
  4282. }); else {
  4283. var h = null;
  4284. if (function () {
  4285. var a = document.createElement("x"), b = document.documentElement, c = window.getComputedStyle;
  4286. return "pointerEvents"in a.style ? (a.style.pointerEvents = "auto", a.style.pointerEvents = "x", b.appendChild(a), c = c && "auto" === c(a, "").pointerEvents, b.removeChild(a), !!c) : !1
  4287. }() && !mejs.MediaFeatures.isOpera) {
  4288. var i = !1, j = function () {
  4289. if (i) {
  4290. for (var a in k)k[a].hide();
  4291. g.css("pointer-events", ""), f.controls.css("pointer-events", ""), f.media.removeEventListener("click", f.clickToPlayPauseCallback), i = !1
  4292. }
  4293. }, k = {};
  4294. c = ["top", "left", "right", "bottom"];
  4295. var l, m = function () {
  4296. var a = g.offset().left - f.container.offset().left, b = g.offset().top - f.container.offset().top, c = g.outerWidth(!0), d = g.outerHeight(!0), e = f.container.width(), h = f.container.height();
  4297. for (l in k)k[l].css({position: "absolute", top: 0, left: 0});
  4298. k.top.width(e).height(b), k.left.width(a).height(d).css({top: b}), k.right.width(e - a - c).height(d).css({
  4299. top: b,
  4300. left: a + c
  4301. }), k.bottom.width(e).height(h - d - b).css({top: b + d})
  4302. };
  4303. for (f.globalBind("resize", function () {
  4304. m()
  4305. }), l = 0, d = c.length; d > l; l++)k[c[l]] = a('<div class="mejs-fullscreen-hover" />').appendTo(f.container).mouseover(j).hide();
  4306. g.on("mouseover", function () {
  4307. if (!f.isFullScreen) {
  4308. var a = g.offset(), c = b.container.offset();
  4309. e.positionFullscreenButton(a.left - c.left, a.top - c.top, !1), g.css("pointer-events", "none"), f.controls.css("pointer-events", "none"), f.media.addEventListener("click", f.clickToPlayPauseCallback);
  4310. for (l in k)k[l].show();
  4311. m(), i = !0
  4312. }
  4313. }), e.addEventListener("fullscreenchange", function () {
  4314. f.isFullScreen = !f.isFullScreen, f.isFullScreen ? f.media.removeEventListener("click", f.clickToPlayPauseCallback) : f.media.addEventListener("click", f.clickToPlayPauseCallback), j()
  4315. }), f.globalBind("mousemove", function (a) {
  4316. if (i) {
  4317. var b = g.offset();
  4318. (a.pageY < b.top || a.pageY > b.top + g.outerHeight(!0) || a.pageX < b.left || a.pageX > b.left + g.outerWidth(!0)) && (g.css("pointer-events", ""), f.controls.css("pointer-events", ""), i = !1)
  4319. }
  4320. })
  4321. } else g.on("mouseover", function () {
  4322. null !== h && (clearTimeout(h), delete h);
  4323. var a = g.offset(), c = b.container.offset();
  4324. e.positionFullscreenButton(a.left - c.left, a.top - c.top, !0)
  4325. }).on("mouseout", function () {
  4326. null !== h && (clearTimeout(h), delete h), h = setTimeout(function () {
  4327. e.hideFullscreenButton()
  4328. }, 1500)
  4329. })
  4330. }
  4331. b.fullscreenBtn = g, f.globalBind("keydown", function (a) {
  4332. (mejs.MediaFeatures.hasTrueNativeFullScreen && mejs.MediaFeatures.isFullScreen() || f.isFullScreen) && 27 == a.keyCode && b.exitFullScreen()
  4333. })
  4334. }
  4335. },
  4336. cleanfullscreen: function (a) {
  4337. a.exitFullScreen()
  4338. },
  4339. containerSizeTimeout: null,
  4340. enterFullScreen: function () {
  4341. var b = this;
  4342. if ("native" === b.media.pluginType || !mejs.MediaFeatures.isFirefox && !b.options.usePluginFullScreen) {
  4343. if (a(document.documentElement).addClass("mejs-fullscreen"), normalHeight = b.container.height(), normalWidth = b.container.width(), "native" === b.media.pluginType)if (mejs.MediaFeatures.hasTrueNativeFullScreen)mejs.MediaFeatures.requestFullScreen(b.container[0]), b.isInIframe && setTimeout(function d() {
  4344. b.isNativeFullScreen && (a(window).width() !== screen.width ? b.exitFullScreen() : setTimeout(d, 500))
  4345. }, 500); else if (mejs.MediaFeatures.hasSemiNativeFullScreen)return b.media.webkitEnterFullscreen(), void 0;
  4346. if (b.isInIframe) {
  4347. var c = b.options.newWindowCallback(this);
  4348. if ("" !== c) {
  4349. if (!mejs.MediaFeatures.hasTrueNativeFullScreen)return b.pause(), window.open(c, b.id, "top=0,left=0,width=" + screen.availWidth + ",height=" + screen.availHeight + ",resizable=yes,scrollbars=no,status=no,toolbar=no"), void 0;
  4350. setTimeout(function () {
  4351. b.isNativeFullScreen || (b.pause(), window.open(c, b.id, "top=0,left=0,width=" + screen.availWidth + ",height=" + screen.availHeight + ",resizable=yes,scrollbars=no,status=no,toolbar=no"))
  4352. }, 250)
  4353. }
  4354. }
  4355. b.container.addClass("mejs-container-fullscreen").width("100%").height("100%"), b.containerSizeTimeout = setTimeout(function () {
  4356. b.container.css({width: "100%", height: "100%"}), b.setControlsSize()
  4357. }, 500), "native" === b.media.pluginType ? b.$media.width("100%").height("100%") : (b.container.find(".mejs-shim").width("100%").height("100%"), b.media.setVideoSize(a(window).width(), a(window).height())), b.layers.children("div").width("100%").height("100%"), b.fullscreenBtn && b.fullscreenBtn.removeClass("mejs-fullscreen").addClass("mejs-unfullscreen"), b.setControlsSize(), b.isFullScreen = !0
  4358. }
  4359. },
  4360. exitFullScreen: function () {
  4361. clearTimeout(this.containerSizeTimeout), "native" !== this.media.pluginType && mejs.MediaFeatures.isFirefox ? this.media.setFullscreen(!1) : (mejs.MediaFeatures.hasTrueNativeFullScreen && (mejs.MediaFeatures.isFullScreen() || this.isFullScreen) && mejs.MediaFeatures.cancelFullScreen(), a(document.documentElement).removeClass("mejs-fullscreen"), this.container.removeClass("mejs-container-fullscreen").width(normalWidth).height(normalHeight), "native" === this.media.pluginType ? this.$media.width(normalWidth).height(normalHeight) : (this.container.find(".mejs-shim").width(normalWidth).height(normalHeight), this.media.setVideoSize(normalWidth, normalHeight)), this.layers.children("div").width(normalWidth).height(normalHeight), this.fullscreenBtn.removeClass("mejs-unfullscreen").addClass("mejs-fullscreen"), this.setControlsSize(), this.isFullScreen = !1)
  4362. }
  4363. })
  4364. }(mejs.$), function (a) {
  4365. a.extend(mejs.MepDefaults, {
  4366. startLanguage: "",
  4367. tracksText: mejs.i18n.t("Captions/Subtitles"),
  4368. hideCaptionsButtonWhenEmpty: !0,
  4369. toggleCaptionsButtonWhenOnlyOne: !1,
  4370. slidesSelector: ""
  4371. }), a.extend(MediaElementPlayer.prototype, {
  4372. hasChapters: !1, buildtracks: function (b, c, d, e) {
  4373. if (0 != b.tracks.length) {
  4374. var f;
  4375. if (this.domNode.textTracks)for (f = this.domNode.textTracks.length - 1; f >= 0; f--)this.domNode.textTracks[f].mode = "hidden";
  4376. for (b.chapters = a('<div class="mejs-chapters mejs-layer"></div>').prependTo(d).hide(), b.captions = a('<div class="mejs-captions-layer mejs-layer"><div class="mejs-captions-position mejs-captions-position-hover"><span class="mejs-captions-text"></span></div></div>').prependTo(d).hide(), b.captionsText = b.captions.find(".mejs-captions-text"), b.captionsButton = a('<div class="mejs-button mejs-captions-button"><button type="button" aria-controls="' + this.id + '" title="' + this.options.tracksText + '" aria-label="' + this.options.tracksText + '"></button><div class="mejs-captions-selector"><ul><li><input type="radio" name="' + b.id + '_captions" id="' + b.id + '_captions_none" value="none" checked="checked" /><label for="' + b.id + '_captions_none">' + mejs.i18n.t("None") + "</label></li></ul></div></div>").appendTo(c), f = c = 0; f < b.tracks.length; f++)"subtitles" == b.tracks[f].kind && c++;
  4377. for (this.options.toggleCaptionsButtonWhenOnlyOne && 1 == c ? b.captionsButton.on("click", function () {
  4378. b.setTrack(null == b.selectedTrack ? b.tracks[0].srclang : "none")
  4379. }) : b.captionsButton.hover(function () {
  4380. a(this).find(".mejs-captions-selector").css("visibility", "visible")
  4381. }, function () {
  4382. a(this).find(".mejs-captions-selector").css("visibility", "hidden")
  4383. }).on("click", "input[type=radio]", function () {
  4384. lang = this.value, b.setTrack(lang)
  4385. }), b.options.alwaysShowControls ? b.container.find(".mejs-captions-position").addClass("mejs-captions-position-hover") : b.container.bind("controlsshown", function () {
  4386. b.container.find(".mejs-captions-position").addClass("mejs-captions-position-hover")
  4387. }).bind("controlshidden", function () {
  4388. e.paused || b.container.find(".mejs-captions-position").removeClass("mejs-captions-position-hover")
  4389. }), b.trackToLoad = -1, b.selectedTrack = null, b.isLoadingTrack = !1, f = 0; f < b.tracks.length; f++)"subtitles" == b.tracks[f].kind && b.addTrackButton(b.tracks[f].srclang, b.tracks[f].label);
  4390. b.loadNextTrack(), e.addEventListener("timeupdate", function () {
  4391. b.displayCaptions()
  4392. }, !1), "" != b.options.slidesSelector && (b.slidesContainer = a(b.options.slidesSelector), e.addEventListener("timeupdate", function () {
  4393. b.displaySlides()
  4394. }, !1)), e.addEventListener("loadedmetadata", function () {
  4395. b.displayChapters()
  4396. }, !1), b.container.hover(function () {
  4397. b.hasChapters && (b.chapters.css("visibility", "visible"), b.chapters.fadeIn(200).height(b.chapters.find(".mejs-chapter").outerHeight()))
  4398. }, function () {
  4399. b.hasChapters && !e.paused && b.chapters.fadeOut(200, function () {
  4400. a(this).css("visibility", "hidden"), a(this).css("display", "block")
  4401. })
  4402. }), null !== b.node.getAttribute("autoplay") && b.chapters.css("visibility", "hidden")
  4403. }
  4404. }, setTrack: function (a) {
  4405. var b;
  4406. if ("none" == a)this.selectedTrack = null, this.captionsButton.removeClass("mejs-captions-enabled"); else for (b = 0; b < this.tracks.length; b++)if (this.tracks[b].srclang == a) {
  4407. null == this.selectedTrack && this.captionsButton.addClass("mejs-captions-enabled"), this.selectedTrack = this.tracks[b], this.captions.attr("lang", this.selectedTrack.srclang), this.displayCaptions();
  4408. break
  4409. }
  4410. }, loadNextTrack: function () {
  4411. this.trackToLoad++, this.trackToLoad < this.tracks.length ? (this.isLoadingTrack = !0, this.loadTrack(this.trackToLoad)) : (this.isLoadingTrack = !1, this.checkForTracks())
  4412. }, loadTrack: function (b) {
  4413. var c = this, d = c.tracks[b];
  4414. a.ajax({
  4415. url: d.src, dataType: "text", success: function (a) {
  4416. d.entries = "string" == typeof a && /<tt\s+xml/gi.exec(a) ? mejs.TrackFormatParser.dfxp.parse(a) : mejs.TrackFormatParser.webvvt.parse(a), d.isLoaded = !0, c.enableTrackButton(d.srclang, d.label), c.loadNextTrack(), "chapters" == d.kind && c.media.addEventListener("play", function () {
  4417. c.media.duration > 0 && c.displayChapters(d)
  4418. }, !1), "slides" == d.kind && c.setupSlides(d)
  4419. }, error: function () {
  4420. c.loadNextTrack()
  4421. }
  4422. })
  4423. }, enableTrackButton: function (b, c) {
  4424. "" === c && (c = mejs.language.codes[b] || b), this.captionsButton.find("input[value=" + b + "]").prop("disabled", !1).siblings("label").html(c), this.options.startLanguage == b && a("#" + this.id + "_captions_" + b).click(), this.adjustLanguageBox()
  4425. }, addTrackButton: function (b, c) {
  4426. "" === c && (c = mejs.language.codes[b] || b), this.captionsButton.find("ul").append(a('<li><input type="radio" name="' + this.id + '_captions" id="' + this.id + "_captions_" + b + '" value="' + b + '" disabled="disabled" /><label for="' + this.id + "_captions_" + b + '">' + c + " (loading)</label></li>")), this.adjustLanguageBox(), this.container.find(".mejs-captions-translations option[value=" + b + "]").remove()
  4427. }, adjustLanguageBox: function () {
  4428. this.captionsButton.find(".mejs-captions-selector").height(this.captionsButton.find(".mejs-captions-selector ul").outerHeight(!0) + this.captionsButton.find(".mejs-captions-translations").outerHeight(!0))
  4429. }, checkForTracks: function () {
  4430. var a = !1;
  4431. if (this.options.hideCaptionsButtonWhenEmpty) {
  4432. for (i = 0; i < this.tracks.length; i++)if ("subtitles" == this.tracks[i].kind) {
  4433. a = !0;
  4434. break
  4435. }
  4436. a || (this.captionsButton.hide(), this.setControlsSize())
  4437. }
  4438. }, displayCaptions: function () {
  4439. if ("undefined" != typeof this.tracks) {
  4440. var a, b = this.selectedTrack;
  4441. if (null != b && b.isLoaded)for (a = 0; a < b.entries.times.length; a++)if (this.media.currentTime >= b.entries.times[a].start && this.media.currentTime <= b.entries.times[a].stop)return this.captionsText.html(b.entries.text[a]), this.captions.show().height(0), void 0;
  4442. this.captions.hide()
  4443. }
  4444. }, setupSlides: function (a) {
  4445. this.slides = a, this.slides.entries.imgs = [this.slides.entries.text.length], this.showSlide(0)
  4446. }, showSlide: function (b) {
  4447. if ("undefined" != typeof this.tracks && "undefined" != typeof this.slidesContainer) {
  4448. var c = this, d = c.slides.entries.text[b], e = c.slides.entries.imgs[b];
  4449. "undefined" == typeof e || "undefined" == typeof e.fadeIn ? c.slides.entries.imgs[b] = e = a('<img src="' + d + '">').on("load", function () {
  4450. e.appendTo(c.slidesContainer).hide().fadeIn().siblings(":visible").fadeOut()
  4451. }) : !e.is(":visible") && !e.is(":animated") && e.fadeIn().siblings(":visible").fadeOut()
  4452. }
  4453. }, displaySlides: function () {
  4454. if ("undefined" != typeof this.slides) {
  4455. var a, b = this.slides;
  4456. for (a = 0; a < b.entries.times.length; a++)if (this.media.currentTime >= b.entries.times[a].start && this.media.currentTime <= b.entries.times[a].stop) {
  4457. this.showSlide(a);
  4458. break
  4459. }
  4460. }
  4461. }, displayChapters: function () {
  4462. var a;
  4463. for (a = 0; a < this.tracks.length; a++)if ("chapters" == this.tracks[a].kind && this.tracks[a].isLoaded) {
  4464. this.drawChapters(this.tracks[a]), this.hasChapters = !0;
  4465. break
  4466. }
  4467. }, drawChapters: function (b) {
  4468. var c, d, e = this, f = d = 0;
  4469. for (e.chapters.empty(), c = 0; c < b.entries.times.length; c++)d = b.entries.times[c].stop - b.entries.times[c].start, d = Math.floor(d / e.media.duration * 100), (d + f > 100 || c == b.entries.times.length - 1 && 100 > d + f) && (d = 100 - f), e.chapters.append(a('<div class="mejs-chapter" rel="' + b.entries.times[c].start + '" style="left: ' + f.toString() + "%;width: " + d.toString() + '%;"><div class="mejs-chapter-block' + (c == b.entries.times.length - 1 ? " mejs-chapter-block-last" : "") + '"><span class="ch-title">' + b.entries.text[c] + '</span><span class="ch-time">' + mejs.Utility.secondsToTimeCode(b.entries.times[c].start) + "&ndash;" + mejs.Utility.secondsToTimeCode(b.entries.times[c].stop) + "</span></div></div>")), f += d;
  4470. e.chapters.find("div.mejs-chapter").click(function () {
  4471. e.media.setCurrentTime(parseFloat(a(this).attr("rel"))), e.media.paused && e.media.play()
  4472. }), e.chapters.show()
  4473. }
  4474. }), mejs.language = {
  4475. codes: {
  4476. af: "Afrikaans",
  4477. sq: "Albanian",
  4478. ar: "Arabic",
  4479. be: "Belarusian",
  4480. bg: "Bulgarian",
  4481. ca: "Catalan",
  4482. zh: "Chinese",
  4483. "zh-cn": "Chinese Simplified",
  4484. "zh-tw": "Chinese Traditional",
  4485. hr: "Croatian",
  4486. cs: "Czech",
  4487. da: "Danish",
  4488. nl: "Dutch",
  4489. en: "English",
  4490. et: "Estonian",
  4491. tl: "Filipino",
  4492. fi: "Finnish",
  4493. fr: "French",
  4494. gl: "Galician",
  4495. de: "German",
  4496. el: "Greek",
  4497. ht: "Haitian Creole",
  4498. iw: "Hebrew",
  4499. hi: "Hindi",
  4500. hu: "Hungarian",
  4501. is: "Icelandic",
  4502. id: "Indonesian",
  4503. ga: "Irish",
  4504. it: "Italian",
  4505. ja: "Japanese",
  4506. ko: "Korean",
  4507. lv: "Latvian",
  4508. lt: "Lithuanian",
  4509. mk: "Macedonian",
  4510. ms: "Malay",
  4511. mt: "Maltese",
  4512. no: "Norwegian",
  4513. fa: "Persian",
  4514. pl: "Polish",
  4515. pt: "Portuguese",
  4516. ro: "Romanian",
  4517. ru: "Russian",
  4518. sr: "Serbian",
  4519. sk: "Slovak",
  4520. sl: "Slovenian",
  4521. es: "Spanish",
  4522. sw: "Swahili",
  4523. sv: "Swedish",
  4524. tl: "Tagalog",
  4525. th: "Thai",
  4526. tr: "Turkish",
  4527. uk: "Ukrainian",
  4528. vi: "Vietnamese",
  4529. cy: "Welsh",
  4530. yi: "Yiddish"
  4531. }
  4532. }, mejs.TrackFormatParser = {
  4533. webvvt: {
  4534. pattern_identifier: /^([a-zA-z]+-)?[0-9]+$/,
  4535. pattern_timecode: /^([0-9]{2}:[0-9]{2}:[0-9]{2}([,.][0-9]{1,3})?) --\> ([0-9]{2}:[0-9]{2}:[0-9]{2}([,.][0-9]{3})?)(.*)$/,
  4536. parse: function (b) {
  4537. var c = 0;
  4538. b = mejs.TrackFormatParser.split2(b, /\r?\n/);
  4539. for (var d, e, f = {
  4540. text: [],
  4541. times: []
  4542. }; c < b.length; c++)if (this.pattern_identifier.exec(b[c]) && (c++, (d = this.pattern_timecode.exec(b[c])) && c < b.length)) {
  4543. for (c++, e = b[c], c++; "" !== b[c] && c < b.length;)e = e + "\n" + b[c], c++;
  4544. e = a.trim(e).replace(/(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/gi, "<a href='$1' target='_blank'>$1</a>"), f.text.push(e), f.times.push({
  4545. start: 0 == mejs.Utility.convertSMPTEtoSeconds(d[1]) ? .2 : mejs.Utility.convertSMPTEtoSeconds(d[1]),
  4546. stop: mejs.Utility.convertSMPTEtoSeconds(d[3]),
  4547. settings: d[5]
  4548. })
  4549. }
  4550. return f
  4551. }
  4552. }, dfxp: {
  4553. parse: function (b) {
  4554. b = a(b).filter("tt");
  4555. var c = 0;
  4556. c = b.children("div").eq(0);
  4557. var d = c.find("p");
  4558. c = b.find("#" + c.attr("style"));
  4559. var e, f;
  4560. if (b = {
  4561. text: [],
  4562. times: []
  4563. }, c.length && (f = c.removeAttr("id").get(0).attributes, f.length))for (e = {}, c = 0; c < f.length; c++)e[f[c].name.split(":")[1]] = f[c].value;
  4564. for (c = 0; c < d.length; c++) {
  4565. var g;
  4566. if (f = {
  4567. start: null,
  4568. stop: null,
  4569. style: null
  4570. }, d.eq(c).attr("begin") && (f.start = mejs.Utility.convertSMPTEtoSeconds(d.eq(c).attr("begin"))), !f.start && d.eq(c - 1).attr("end") && (f.start = mejs.Utility.convertSMPTEtoSeconds(d.eq(c - 1).attr("end"))), d.eq(c).attr("end") && (f.stop = mejs.Utility.convertSMPTEtoSeconds(d.eq(c).attr("end"))), !f.stop && d.eq(c + 1).attr("begin") && (f.stop = mejs.Utility.convertSMPTEtoSeconds(d.eq(c + 1).attr("begin"))), e) {
  4571. g = "";
  4572. for (var h in e)g += h + ":" + e[h] + ";"
  4573. }
  4574. g && (f.style = g), 0 == f.start && (f.start = .2), b.times.push(f), f = a.trim(d.eq(c).html()).replace(/(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/gi, "<a href='$1' target='_blank'>$1</a>"), b.text.push(f), 0 == b.times.start && (b.times.start = 2)
  4575. }
  4576. return b
  4577. }
  4578. }, split2: function (a, b) {
  4579. return a.split(b)
  4580. }
  4581. }, 3 != "x\n\ny".split(/\n/gi).length && (mejs.TrackFormatParser.split2 = function (a, b) {
  4582. var c, d = [], e = "";
  4583. for (c = 0; c < a.length; c++)e += a.substring(c, c + 1), b.test(e) && (d.push(e.replace(b, "")), e = "");
  4584. return d.push(e), d
  4585. })
  4586. }(mejs.$), function (a) {
  4587. a.extend(mejs.MepDefaults, {
  4588. contextMenuItems: [{
  4589. render: function (a) {
  4590. return "undefined" == typeof a.enterFullScreen ? null : a.isFullScreen ? mejs.i18n.t("Turn off Fullscreen") : mejs.i18n.t("Go Fullscreen")
  4591. }, click: function (a) {
  4592. a.isFullScreen ? a.exitFullScreen() : a.enterFullScreen()
  4593. }
  4594. }, {
  4595. render: function (a) {
  4596. return a.media.muted ? mejs.i18n.t("Unmute") : mejs.i18n.t("Mute")
  4597. }, click: function (a) {
  4598. a.media.muted ? a.setMuted(!1) : a.setMuted(!0)
  4599. }
  4600. }, {isSeparator: !0}, {
  4601. render: function () {
  4602. return mejs.i18n.t("Download Video")
  4603. }, click: function (a) {
  4604. window.location.href = a.media.currentSrc
  4605. }
  4606. }]
  4607. }), a.extend(MediaElementPlayer.prototype, {
  4608. buildcontextmenu: function (b) {
  4609. b.contextMenu = a('<div class="mejs-contextmenu"></div>').appendTo(a("body")).hide(), b.container.bind("contextmenu", function (a) {
  4610. return b.isContextMenuEnabled ? (a.preventDefault(), b.renderContextMenu(a.clientX - 1, a.clientY - 1), !1) : void 0
  4611. }), b.container.bind("click", function () {
  4612. b.contextMenu.hide()
  4613. }), b.contextMenu.bind("mouseleave", function () {
  4614. b.startContextMenuTimer()
  4615. })
  4616. }, cleancontextmenu: function (a) {
  4617. a.contextMenu.remove()
  4618. }, isContextMenuEnabled: !0, enableContextMenu: function () {
  4619. this.isContextMenuEnabled = !0
  4620. }, disableContextMenu: function () {
  4621. this.isContextMenuEnabled = !1
  4622. }, contextMenuTimeout: null, startContextMenuTimer: function () {
  4623. var a = this;
  4624. a.killContextMenuTimer(), a.contextMenuTimer = setTimeout(function () {
  4625. a.hideContextMenu(), a.killContextMenuTimer()
  4626. }, 750)
  4627. }, killContextMenuTimer: function () {
  4628. var a = this.contextMenuTimer;
  4629. null != a && (clearTimeout(a), delete a)
  4630. }, hideContextMenu: function () {
  4631. this.contextMenu.hide()
  4632. }, renderContextMenu: function (b, c) {
  4633. for (var d = this, e = "", f = d.options.contextMenuItems, g = 0, h = f.length; h > g; g++)if (f[g].isSeparator)e += '<div class="mejs-contextmenu-separator"></div>'; else {
  4634. var i = f[g].render(d);
  4635. null != i && (e += '<div class="mejs-contextmenu-item" data-itemindex="' + g + '" id="element-' + 1e6 * Math.random() + '">' + i + "</div>")
  4636. }
  4637. d.contextMenu.empty().append(a(e)).css({
  4638. top: c,
  4639. left: b
  4640. }).show(), d.contextMenu.find(".mejs-contextmenu-item").each(function () {
  4641. var b = a(this), c = parseInt(b.data("itemindex"), 10), e = d.options.contextMenuItems[c];
  4642. "undefined" != typeof e.show && e.show(b, d), b.click(function () {
  4643. "undefined" != typeof e.click && e.click(d), d.contextMenu.hide()
  4644. })
  4645. }), setTimeout(function () {
  4646. d.killControlsTimer("rev3")
  4647. }, 100)
  4648. }
  4649. })
  4650. }(mejs.$), function (a) {
  4651. a.extend(mejs.MepDefaults, {postrollCloseText: mejs.i18n.t("Close")}), a.extend(MediaElementPlayer.prototype, {
  4652. buildpostroll: function (b, c, d) {
  4653. var e = this.container.find('link[rel="postroll"]').attr("href");
  4654. "undefined" != typeof e && (b.postroll = a('<div class="mejs-postroll-layer mejs-layer"><a class="mejs-postroll-close" onclick="$(this).parent().hide();return false;">' + this.options.postrollCloseText + '</a><div class="mejs-postroll-layer-content"></div></div>').prependTo(d).hide(), this.media.addEventListener("ended", function () {
  4655. a.ajax({
  4656. dataType: "html", url: e, success: function (a) {
  4657. d.find(".mejs-postroll-layer-content").html(a)
  4658. }
  4659. }), b.postroll.show()
  4660. }, !1))
  4661. }
  4662. })
  4663. }(mejs.$);
  4664. var CarGame = function (a) {
  4665. function b(b) {
  4666. requirejs.config({
  4667. baseUrl: pickup_vars.template + "/assets/js",
  4668. paths: {
  4669. settings: ["pickup/CarGame/build/Settings"],
  4670. game: ["pickup/CarGame/build/Game"],
  4671. highscore: ["pickup/CarGame/build/Highscore"]
  4672. }
  4673. }), requirejs(["settings"], function (d) {
  4674. i = a(b)[0], i.getContext && (k = i.getContext("2d"), l = d, k && (a("body").hasClass("tablet") ? a("#game-tablet-placeholder").show() : c(), window.addEventListener("resize", e, !1), e()))
  4675. })
  4676. }
  4677.  
  4678. function c() {
  4679. a("#car-game").waypoint(function () {
  4680. a("#game-intro-logo").show().animate({marginTop: "130px"}, 2e3, "easeOutElastic", function () {
  4681. a("#game-intro-background").fadeIn(800), a("#game-intro .pickup-button").fadeIn(800).one("click", function () {
  4682. a("#game-intro").hide(), a("#hud").fadeIn(), f()
  4683. })
  4684. })
  4685. }, {offset: "50%", triggerOnce: !0})
  4686. }
  4687.  
  4688. function d() {
  4689. var a = i.width, b = i.height, c = [{x: a, y: b}, {x: 0, y: b}, {x: 0, y: b - l.RISE - l.H_OFFSET}, {
  4690. x: a,
  4691. y: b - l.H_OFFSET
  4692. }];
  4693. k.fillStyle = "#000", k.fillRect(0, 0, a, b), k.beginPath(), k.fillStyle = l.HILL_COLOR;
  4694. var d = c.length - 1;
  4695. k.moveTo(c[d].x, c[d].y);
  4696. for (var e = 0; e < c.length; e++)k.lineTo(c[e].x, c[e].y);
  4697. k.closePath(), k.fill()
  4698. }
  4699.  
  4700. function e() {
  4701. j = a("#bergaufundup").width(), i.width !== j && (i.width = a("#bergaufundup").width(), d())
  4702. }
  4703.  
  4704. function f() {
  4705. Loading.show(), requirejs(["game", "highscore"], function (b, c) {
  4706. Tracking.track("click", "BergaufundupSpieldaten", "Auszeitzone Berg auf und up Spieldaten geladen", !0);
  4707. var d = new createjs.LoadQueue;
  4708. d.installPlugin(createjs.Sound), d.loadManifest([{
  4709. id: "collect",
  4710. src: l.SOUND_COLLECT_PICKUP
  4711. }, {id: "speedup", src: l.SOUND_TRUCK_SPEED_UP}, {
  4712. id: "outOfFuel",
  4713. src: l.SOUND_TRUCK_OUT_OF_FUEL
  4714. }, {id: "idle", src: l.SOUND_TRUCK_IDLE}, {id: "drive", src: l.SOUND_TRUCK_DRIVE}, {
  4715. id: "background",
  4716. src: l.SOUND_GAME_BACKGROUND
  4717. }]), d.addEventListener("complete", function () {
  4718. Loading.hide(), b.start(i, g)
  4719. }), "undefined" == typeof m && (m = new c);
  4720. var e = a("#game-mute");
  4721. e.on("click", function () {
  4722. a(this).hasClass("btn-mute") ? (a(this).removeClass("btn-mute").addClass("btn-unmute"), b.mute(!0)) : (a(this).removeClass("btn-unmute").addClass("btn-mute"), b.mute(!1))
  4723. }), m.setClickListener(function () {
  4724. a("#game-status").hide(), a("#game-play-again").hide(), Tracking.track("click", "BergaufundupReplay", "Auszeitzone Berg auf und up Replay aus Highscore", !0), b.start(i, g)
  4725. }, function () {
  4726. var c = a("#game-play-again").show();
  4727. c.one("click", function () {
  4728. a(this).hide(), a("#game-status").hide(), Tracking.track("click", "BergaufundupReplay", "Auszeitzone Berg auf und up Replay", !0), b.start(i, g)
  4729. })
  4730. })
  4731. })
  4732. }
  4733.  
  4734. function g(b) {
  4735. a("#game-status").html("Game Over").fadeIn(4e3, function () {
  4736. Loading.show(), h(b)
  4737. })
  4738. }
  4739.  
  4740. function h(a) {
  4741. m.set(a);
  4742. var b = m.get();
  4743. b.done(function (a) {
  4744. Loading.hide(), m.show(a)
  4745. }).fail(function (a) {
  4746. Loading.hide(), log("Fehler: "), log(a)
  4747. }).always(function () {
  4748. })
  4749. }
  4750.  
  4751. var i, j, k, l, m;
  4752. return {
  4753. init: function (c) {
  4754. a(c).length > 0 && b(c)
  4755. }
  4756. }
  4757. }(jQuery), AuszeitzoneBeissdichdurch = function (a) {
  4758. function b() {
  4759. a("#beissdichdurch").length > 0 && a("#beissdichdurch").waypoint(function () {
  4760. a("#beissdichdurchImage").animate({left: "50%"}, 2e3, "easeOutElastic", function () {
  4761. a("#beissdichdurchImage").one("click", function (b) {
  4762. v = a(this), w = a("#beissdichdurchContent"), v.off("click"), c(), b.preventDefault()
  4763. })
  4764. })
  4765. }, {offset: "50%", triggerOnce: !0})
  4766. }
  4767.  
  4768. function c() {
  4769. if (Loading.show(), y = a("#beissdichdurch").height(), t = a("#beissdichdurch h2").html(), a("#beissdichdurch").css("min-height", y + "px"), "undefined" == typeof B && (B = PickupSounds.getSupportedAudioFormat()), a("#debug").append("<br>beissdichdurch, supportedAudioFormat: " + B), "undefined" == typeof u) {
  4770. var b = window.location.protocol, c = "https" === b ? {createjs: ["libs/createjs/soundjs-NEXT.min"]} : {createjs: ["libs/createjs/soundjs-NEXT.min"]};
  4771. requirejs.config({
  4772. baseUrl: pickup_vars.template + "/assets/js",
  4773. paths: c
  4774. }), requirejs(["createjs", "libs/require/plugins/text!pickup/templates/TemplateAuszeitzoneBeissdichdurchCounter.html"], function (b, c) {
  4775. u = _.template(c), D = a("html").hasClass("no-flexbox") ? [{
  4776. src: "beissdichdurch_crunch01.mp3|beissdichdurch_crunch01.ogg",
  4777. id: 0
  4778. }, {
  4779. src: "beissdichdurch_crunch02.mp3|beissdichdurch_crunch02.ogg",
  4780. id: 1
  4781. }, {
  4782. src: "beissdichdurch_crunch03.mp3|beissdichdurch_crunch03.ogg",
  4783. id: 2
  4784. }] : [{
  4785. src: "beissdichdurch_crunch01.m4a|beissdichdurch_crunch01.ogg",
  4786. id: 0
  4787. }, {
  4788. src: "beissdichdurch_crunch02.m4a|beissdichdurch_crunch02.ogg",
  4789. id: 1
  4790. }, {
  4791. src: "beissdichdurch_crunch03.m4a|beissdichdurch_crunch03.ogg",
  4792. id: 2
  4793. }], createjs.Sound.addEventListener("fileload", createjs.proxy(d, this)), createjs.Sound.registerManifest(D, Z), C = setTimeout(function () {
  4794. f()
  4795. }, 7e3)
  4796. })
  4797. }
  4798. }
  4799.  
  4800. function d() {
  4801. a("#debug").append("<br>beissdichdurch, loadHandler, soundCrunchLoaded: " + $), $++, $ === D.length && (clearTimeout(C), g())
  4802. }
  4803.  
  4804. function e() {
  4805. clearTimeout(C), $++, $ === W.length && g()
  4806. }
  4807.  
  4808. function f() {
  4809. a("#debug").append("<br>beissdichdurch, onSoundTimeout"), clearTimeout(C), K = !1, g()
  4810. }
  4811.  
  4812. function g() {
  4813. var b = new Image;
  4814. a(b).load(function () {
  4815. v.css("background-image", "url(" + M + ")"), h()
  4816. }).error(function () {
  4817. w.html(G.fail_loading)
  4818. }).attr("src", M)
  4819. }
  4820.  
  4821. function h() {
  4822. var b = v.attr("data-nonce"), c = {
  4823. url: pickup_vars.ajaxurl,
  4824. data: {action: "getAuszeitzoneBeissdichdurchInteraktionKlicks", nonce: b}
  4825. };
  4826. a.ajax(a.extend({}, F, c)).done(function (b) {
  4827. a.each(b, function (a, b) {
  4828. P.push({titel: b.titel, post_id: b.post_id})
  4829. }), j(), K && i(), v.trigger("click"), Tracking.track("click", "AuszeitzoneBeissdichdurch", "Auszeitzone Beiss dich durch geladen", !1)
  4830. }).fail(function () {
  4831. w.html(G.fail_loading)
  4832. }).always(function () {
  4833. Loading.hide()
  4834. })
  4835. }
  4836.  
  4837. function i() {
  4838. a("section#beissdichdurch").prepend('<div id="beissdichdurchSoundToggle" class="on"></div>'), A = a("#beissdichdurchSoundToggle"), A.on("click", function () {
  4839. a(this).hasClass("on") ? (a(this).removeClass("on"), a(this).addClass("off"), K = !K) : (a(this).removeClass("off"), a(this).addClass("on"), K = !K)
  4840. })
  4841. }
  4842.  
  4843. function j() {
  4844. v.on("click", function () {
  4845. if (O++, H && (H = !1, a("#beissdichdurch h2").css("font-size", "3.2em").html(t)), K) {
  4846. var b = Math.floor(Math.random() * D.length);
  4847. createjs.Sound.play(b.toString(), createjs.Sound.INTERRUPT_NONE, 0, 0, !1, 1)
  4848. }
  4849. N >= U * (T - 1) && (E++, s());
  4850. var c = findInArray(P, "titel", O.toString());
  4851. c ? (Q++, k(c), v.off("click")) : (w.html(""), r())
  4852. })
  4853. }
  4854.  
  4855. function k(b) {
  4856. Loading.show();
  4857. var c = {
  4858. url: pickup_vars.ajaxurl,
  4859. data: {action: "getAuszeitzoneBeissdichdurchContent", issmich_id: b, audio: B}
  4860. };
  4861. a.ajax(a.extend({}, F, c)).done(function (b) {
  4862. if (b.issmich_bild) {
  4863. var c = new Image;
  4864. a(c).load(function () {
  4865. x = a(this)[0].height, l(b)
  4866. }).error(function () {
  4867. w.html(G.fail_loading)
  4868. }).attr("src", b.issmich_bild)
  4869. } else l(b)
  4870. }).fail(function () {
  4871. }).always(function () {
  4872. Loading.hide()
  4873. })
  4874. }
  4875.  
  4876. function l(b) {
  4877. Tracking.track("click", "BeissdichdurchEreignis", "Auszeitzone Beiss dich durch Ereignis bei Riegel " + E, !1);
  4878. var c = '<div class="additionalContent container">';
  4879. b.issmich_content && 23 === E ? c = '<div class="content">' + b.issmich_content + "</div>" : b.issmich_content && (c = '<div class="col-md-10 col-md-offset-1 content">' + b.issmich_content + "</div>"), b.issmich_text && (c = c + '<div class="col-md-10 col-md-offset-1 text">' + b.issmich_text + "</div>"), b.issmich_bild && (c = c + '<div class="col-md-10 col-md-offset-1 image"><img src="' + b.issmich_bild + '" /></div<div<>'), c += "</div>", a("#beissdichdurchImageWrapper").hide();
  4880. var d = !1;
  4881. b.issmich_sound && (d = createjs.Sound.play(b.issmich_sound), d.volume = .8), w.append(c).hide(), a("#beissdichdurchWrapper h2:first").fadeOut("fast", function () {
  4882. if (b.issmich_mehrfach_klick) {
  4883. var c = a(".additionalContent .image");
  4884. c.css({overflow: "hidden", height: .25 * x})
  4885. }
  4886. w.fadeIn("fast", function () {
  4887. }), w.find("#beissdichdurch_teilen").length > 0 ? m() : Q < P.length ? setTimeout(function () {
  4888. w.on("click.AuszeitzoneBeissdichdurch", function () {
  4889. p(d, b.issmich_mehrfach_klick)
  4890. })
  4891. }, R) : w.css("cursor", "normal")
  4892. })
  4893. }
  4894.  
  4895. function m() {
  4896. H = !0, w.off("click.AuszeitzoneBeissdichdurch");
  4897. var b = a("#beissdichdurch_teilen");
  4898. b.attr("data-name", I.fbname), b.attr("data-caption", ""), b.attr("data-description", I.fbdescription), b.attr("data-url", I.fblink), b.attr("data-picture", I.fbpicture), b.attr("data-callback", "AuszeitzoneBeissdichdurch.facebookCallback"), b.twoClickSocial({
  4899. facebook: {share: !0},
  4900. tooltip: {url: a("head base").attr("href").length > 0 ? a("head base").attr("href") + "/datenschutz#social-plugins" : document.location.protocol + "//" + document.location.host + "/datenschutz#social-plugins"}
  4901. }), a("#beissdichdurchFacebookShareNein a").on("click", function (a) {
  4902. a.preventDefault(), o()
  4903. })
  4904. }
  4905.  
  4906. function n() {
  4907. Tracking.track("click", "BeissdichdurchFacebookShare", "Auszeitzone Beiss dich durch Facebook Share", !0), p()
  4908. }
  4909.  
  4910. function o() {
  4911. a("#beissdichdurch h2").html("Gut, du klickst also doch noch öfter <br>auf dem Profil von deinem Ex-Partner rum.").css("font-size", "2.4em").hide(), p()
  4912. }
  4913.  
  4914. function p(b, c) {
  4915. if (b && K && b.play(), c) {
  4916. J++;
  4917. var d = a(".additionalContent .image"), e = d.find("img").css("margin-top");
  4918. if (e === .25 * -x * 3 + "px")J = 0, q(); else {
  4919. var f = .25 * x * J;
  4920. d.find("img").css("margin-top", "-" + f + "px")
  4921. }
  4922. } else q()
  4923. }
  4924.  
  4925. function q() {
  4926. w.off("click.AuszeitzoneBeissdichdurch").fadeOut(400, function () {
  4927. a("#beissdichdurch h2").fadeIn("slow", function () {
  4928. }), a("#beissdichdurchImageWrapper").show(), r(), j()
  4929. })
  4930. }
  4931.  
  4932. function r() {
  4933. switch (E) {
  4934. case 17:
  4935. S = 0;
  4936. break;
  4937. case 30:
  4938. S = 2;
  4939. break;
  4940. case 62:
  4941. S = 1;
  4942. break;
  4943. case 85:
  4944. S = 2
  4945. }
  4946. N >= U * (T - 1) && (N = -U, v.hide());
  4947. var a = 0;
  4948. switch (S) {
  4949. case 1:
  4950. a = -535;
  4951. break;
  4952. case 2:
  4953. a = -1073;
  4954. break;
  4955. case 3:
  4956. a = -1626;
  4957. break;
  4958. default:
  4959. a = 0
  4960. }
  4961. if (N += U, v.css("background-position", a + "px -" + N + "px"), 0 === N) {
  4962. var b = Math.round(Math.random());
  4963. b ? v.css("left", 0).show().animate({left: "50%"}, V, function () {
  4964. }) : v.css("left", "100%").show().animate({left: "50%"}, V, function () {
  4965. })
  4966. }
  4967. }
  4968.  
  4969. function s() {
  4970. if (E === L) {
  4971. "undefined" !== z && (a("section#beissdichdurch").prepend('<div id="beissdichdurchCount"></div>'), z = a("#beissdichdurchCount"));
  4972. var b = u({number: E, text: G.riegelCountMultiple});
  4973. z.html(b), z.delay(1200).fadeIn(200, function () {
  4974. a(this).delay(100).fadeOut(200, function () {
  4975. a(this).delay(100).fadeIn(200)
  4976. })
  4977. })
  4978. } else if (E > L) {
  4979. var c = u({number: E, text: G.riegelCountMultiple});
  4980. z.find(".number").fadeTo(300, 0, function () {
  4981. z.html(b), a(this).hide().fadeTo(300, 1)
  4982. }), z.html(c)
  4983. }
  4984. }
  4985.  
  4986. var t, u, v, w, x, y, z, A, B, C, D, E = 0, F = {
  4987. type: "post",
  4988. dataType: "json"
  4989. }, G = {
  4990. fail_loading: '<p class="fail">Leider konnten wir die Spieldaten nicht laden :(</p>',
  4991. riegelCountOne: "PiCK UP!",
  4992. riegelCountMultiple: "PiCK UP!s"
  4993. }, H = !1, I = {
  4994. fbname: "PiCK UP!",
  4995. fbdescription: 'Ich habe gerade "Beiß dich durch“ auf der PiCK UP!-Website ausprobiert und muss sagen:"Es lohnt sich!" Probiert es aus: <a href="https://' + window.location.hostname + '/#beissdichdurch+">Beiss dich durch</a>',
  4996. fblink: "https://" + window.location.hostname + "/#beissdichdurch",
  4997. fbpicture: "https://" + window.location.hostname + pickup_vars.template + "/assets/img/auszeitzone_katschong/fbKatschong.png"
  4998. }, J = 0, K = !0, L = 50, M = pickup_vars.template + "/assets/img/auszeitzone_beissdichdurch/riegel.png", N = 0, O = 0, P = [], Q = 0, R = 1400, S = 2, T = 6, U = 350, V = 600, W = ["/assets/beissdichdurch_crunch01", "/assets/beissdichdurch_crunch02"], X = window.location.pathname, Y = X.substring(0, X.lastIndexOf("/")), Z = Y + "/assets/", $ = 0;
  4999. return {
  5000. init: b, soundFileLoaded: function () {
  5001. e()
  5002. }, facebookCallback: function () {
  5003. n()
  5004. }
  5005. }
  5006. }(jQuery), AuszeitzoneKatschong = function (a) {
  5007. function b() {
  5008. a("#katschong").length > 0 && a("#katschong").waypoint(function () {
  5009. a("#katschongHeadlineIntro").fadeIn("slow", function () {
  5010. c()
  5011. })
  5012. }, {offset: "50%", triggerOnce: !0})
  5013. }
  5014.  
  5015. function c() {
  5016. a("#katschong img.unveil").unveil(0, refreshWaypoints), e() ? (v = !0, g("tag")) : o()
  5017. }
  5018.  
  5019. function d() {
  5020. var b = new Date, c = b.getMinutes(), d = b.getHours(), e = 60 - c, f = 23 - d;
  5021. b.setTime(b.getTime() + 60 * f * 60 * 1e3 + 60 * e * 1e3), a.cookie(u, w, {expires: b})
  5022. }
  5023.  
  5024. function e() {
  5025. return a.cookie(u) ? !0 : !1
  5026. }
  5027.  
  5028. function f() {
  5029. Loading.show();
  5030. var b = {url: pickup_vars.ajaxurl, data: {action: "saveAuszeitzoneKatschongDbEntry", auswahl: w}};
  5031. a.ajax(a.extend({}, x, b)).done(function () {
  5032. }).fail(function () {
  5033. log(" Katschong: Abspeichern fehlgeschlagen.")
  5034. }).always(function () {
  5035. g("tag")
  5036. })
  5037. }
  5038.  
  5039. function g(b) {
  5040. Loading.show();
  5041. var c = {url: pickup_vars.ajaxurl, data: {action: "getAuszeitzoneKatschongErgebnisse", zeitraum: b}};
  5042. a.ajax(a.extend({}, x, c)).done(function (b) {
  5043. b ? (a.each(b, function (a, b) {
  5044. z = Math.round(void 0 === b["0"] ? 0 : Math.round(b["0"] / b.gesamtstimmen * 1e4) / 100), A = Math.round(void 0 === b["1"] ? 0 : Math.round(b["1"] / b.gesamtstimmen * 1e4) / 100), B = Math.round(void 0 === b["2"] ? 0 : Math.round(b["2"] / b.gesamtstimmen * 1e4) / 100)
  5045. }), "undefined" == typeof s ? (requirejs.config({baseUrl: pickup_vars.template + "/assets/js"}), requirejs(["libs/require/plugins/text!pickup/templates/TemplateAuszeitzoneKatschong.html"], function (a) {
  5046. s = _.template(a), i()
  5047. })) : i()) : h()
  5048. }).fail(function () {
  5049. h()
  5050. }).always(function () {
  5051. Loading.hide()
  5052. })
  5053. }
  5054.  
  5055. function h() {
  5056. a("#katschong_abstimmung").append(C.fail_loading)
  5057. }
  5058.  
  5059. function i() {
  5060. var b = s({id: "ergebnis_katschong", prozent: z}), c = s({
  5061. id: "ergebnis_oder",
  5062. prozent: B
  5063. }), d = s({id: "ergebnis_schubidu", prozent: A});
  5064. a("#katschong_ergebnis").html("").append(b + c + d), j()
  5065. }
  5066.  
  5067. function j() {
  5068. r = a("#katschong").height(), a("#katschong").css("min-height", r + "px"), D ? (v ? (a("#katschongIntroHeadlineWrapper").hide(), a("#katschongHeadlineErgebnis").show()) : (a("#katschongIntroHeadlineWrapper").slideUp(), a("#katschongHeadlineErgebnis").slideDown(function () {
  5069. a(this).css({overflow: "visible", height: "auto"})
  5070. })), a("#katschong_select").selectbox({
  5071. onOpen: function () {
  5072. }, onChange: function () {
  5073. D = !1, g(a(this).val())
  5074. }
  5075. }), k()) : l()
  5076. }
  5077.  
  5078. function k() {
  5079. v ? (y = 0, a(".katschongAbstimmButton").hide().next(".btnShadow").hide()) : a(".katschongAbstimmButton").slideUp().next(".btnShadow").hide(), a("#btnOder").addClass("deactivated").animate({
  5080. fontSize: "1em",
  5081. paddingTop: "80px"
  5082. }, y, function () {
  5083. a("#btnOder a").on("click", function (a) {
  5084. a.preventDefault()
  5085. }), l()
  5086. });
  5087. .5 * a("#btnKatschong img").width();
  5088. a("#btnKatschong img").css("cursor", "default").animate({width: "210px", marginRight: "20%"}, y, function () {
  5089. }), a("#btnSchubidu img").css("cursor", "default").animate({width: "210px", marginLeft: "20%"}, y, function () {
  5090. })
  5091. }
  5092.  
  5093. function l() {
  5094. var b = v ? 800 : 1600;
  5095. a("#katschong_ergebnis").slideDown(b, function () {
  5096. var b = Math.round(1.5 * parseInt(z, 10)), c = Math.round(1.5 * parseInt(B, 10)), d = Math.round(1.5 * parseInt(A, 10));
  5097. 20 > b && (b = 20), 20 > c && (c = 20), 20 > d && (d = 20), v && n();
  5098. var e = v ? 6 : 12;
  5099. a("#ergebnis_katschong .chart_top").animate({height: b}, b * e, function () {
  5100. a("#ergebnis_katschong .prozent").css("margin-top", "-" + m(b) + "px").fadeIn(), a("#ergebnis_oder .chart_top").animate({height: c}, c * e, function () {
  5101. a("#ergebnis_oder .prozent").css("margin-top", "-" + m(c) + "px").fadeIn(), a("#ergebnis_schubidu .chart_top").animate({height: d}, d * e, function () {
  5102. a("#ergebnis_schubidu .prozent").css("margin-top", "-" + m(d) + "px").fadeIn(), v || n()
  5103. })
  5104. })
  5105. })
  5106. })
  5107. }
  5108.  
  5109. function m(a) {
  5110. return a + 70
  5111. }
  5112.  
  5113. function n() {
  5114. a("#katschong_teilen").twoClickSocial({
  5115. facebook: {share: !0},
  5116. tooltip: {
  5117. direction: "top",
  5118. url: a("head base").attr("href").length > 0 ? a("head base").attr("href") + "/datenschutz#social-plugins" : document.location.protocol + "//" + document.location.host + "/datenschutz#social-plugins"
  5119. }
  5120. }), v ? a("#katschong_teilen").slideDown(10, function () {
  5121. a(this).css("overflow", "visible")
  5122. }) : a("#katschong_teilen").delay(2e3).slideDown(10, function () {
  5123. a(this).css("overflow", "visible")
  5124. });
  5125. var b, c, d = a("#katschong_teilen");
  5126. -1 === w && (w = a.cookie(u)), 0 === parseInt(w, 10) ? (b = t.fbdescriptionKatschong, c = t.fbpictureKatschong) : 1 === parseInt(w, 10) ? (b = t.fbdescriptionSchubidu, c = t.fbpictureSchubidu) : (b = t.fbdescriptionOder, c = t.fbpictureOder), d.attr("data-name", t.fbname), d.attr("data-description", b), d.attr("data-url", t.fblink), d.attr("data-picture", c), d.attr("data-callback", "AuszeitzoneKatschong.facebookCallback")
  5127. }
  5128.  
  5129. function o() {
  5130. a(".katschongAbstimmButton").slideDown(), a("#btnKatschong").on("click", function (a) {
  5131. a.preventDefault(), w = 0, p()
  5132. }), a("#btnSchubidu").on("click", function (a) {
  5133. a.preventDefault(), w = 1, p()
  5134. }), a("#btnOder a").on("click", function (a) {
  5135. a.preventDefault(), w = 2, p()
  5136. })
  5137. }
  5138.  
  5139. function p() {
  5140. Tracking.track("click", "KatschongAbstimmung", "Katschong Abstimmung " + w, !0), d(), f(), q()
  5141. }
  5142.  
  5143. function q() {
  5144. a("#btnKatschong").off("click").find(".abstimm_button").hide(), a("#btnSchubidu").off("click").find(".abstimm_button").hide(), a("#btnOder a").off("click"), a("#btnOder a").on("click", function (a) {
  5145. a.preventDefault()
  5146. })
  5147. }
  5148.  
  5149. var r, s, t = {
  5150. fbname: "PiCK UP!",
  5151. fbdescriptionKatschong: "Mein Tag war heute so richtig Katschong und deiner? Gib dein Tagesvoting hier ab!",
  5152. fbdescriptionSchubidu: "Mein Tag war heute total Schubidu und deiner? Gib dein Tagesvoting hier ab!",
  5153. fbdescriptionOder: "Ich bin heute total unentschlossen. Alles fühlt sich so ODER an. Wie geht’s dir? Gib dein Tagesvoting hier ab!",
  5154. fblink: "http://" + window.location.hostname + "/#katschong",
  5155. fbpictureKatschong: "http://" + window.location.hostname + pickup_vars.template + "/assets/img/auszeitzone_katschong/fbKatschong.jpg",
  5156. fbpictureSchubidu: "http://" + window.location.hostname + pickup_vars.template + "/assets/img/auszeitzone_katschong/fbSchubidu.jpg",
  5157. fbpictureOder: "http://" + window.location.hostname + pickup_vars.template + "/assets/img/auszeitzone_katschong/fbOder.jpg"
  5158. }, u = "pickup_katschong", v = !1, w = -1, x = {
  5159. type: "post",
  5160. dataType: "json"
  5161. }, y = 1200, z = 0, A = 0, B = 0, C = {fail_loading: '<p class="fail">Leider konnten wir die Ergebnisse nicht laden. Wir haben unseren Technikern Bescheid gegeben.</p>'}, D = !0;
  5162. return {
  5163. init: b, facebookCallback: function () {
  5164. Tracking.track("click", "KatschongFacebookShare", "Katschong Facebook Share", !0), Tracking.trackTarget("Katschong", "AuszeitzoneKatschong", "KatschongFacebookShare")
  5165. }
  5166. }
  5167. }(jQuery), ContentSlider = function (a) {
  5168. function b(b, d) {
  5169. var e = {};
  5170. return d || (d = {}), a.extend(e, c, d), a(b).flexslider(e)
  5171. }
  5172.  
  5173. var c = {slideshow: !1, animation: "slide"};
  5174. return {
  5175. addSlider: function (a, c) {
  5176. return b(a, c)
  5177. }
  5178. }
  5179. }(jQuery), Formulare = function (a) {
  5180. function b() {
  5181. a(document).bind("gform_post_render", function () {
  5182. Formulare.initForm()
  5183. }), e(), c(), d()
  5184. }
  5185.  
  5186. function c() {
  5187. a(".gfield_date_dropdown_day select, .gfield_date_dropdown_month select, .gfield_date_dropdown_year select, .selectbox select").selectbox({
  5188. onOpen: function () {
  5189. }, onChange: function () {
  5190. }
  5191. }), a('input[type="submit"]').addClass("pickup-button btn btn-lg btn-primary"), a('li.geburtsdatum input[type="text"]').attr("pattern", "[0-9]*")
  5192. }
  5193.  
  5194. function d() {
  5195. if (a(".formFail").length > 0) {
  5196. var b = a(".formFail").parent().parent().nextAll(".pflichtfelder");
  5197. b.empty().html(a(".formFail").first())
  5198. }
  5199. a(".validation_message").has(".formFailInline").css("display", "block")
  5200. }
  5201.  
  5202. function e() {
  5203. a(document).bind("gform_confirmation_loaded", function (b, c) {
  5204. a(".gform_confirmation_message_" + c).nextAll(".pflichtfelder").hide();
  5205. var d = "", e = "";
  5206. switch (c) {
  5207. case f:
  5208. d = "Kontakt", e = "Kontaktanfrage";
  5209. break;
  5210. case g:
  5211. d = "NewsletterFooter", e = "Newsletter";
  5212. break;
  5213. case h:
  5214. d = "NewsletterHeader", e = "Newsletter";
  5215. break;
  5216. case i:
  5217. d = "NewsletterMobile", e = "Newsletter";
  5218. break;
  5219. default:
  5220. d = "Formular " + c, e = "Formular-Eingabe"
  5221. }
  5222. Tracking.trackTarget(d, d, e);
  5223. a.post("https://www.etracker.com/form.php", {
  5224. et: pickup_vars.etracker,
  5225. name: d,
  5226. strF0: e
  5227. }).done(function () {
  5228. log("post success")
  5229. }).fail(function () {
  5230. log("post error")
  5231. }).always(function () {
  5232. log("post always")
  5233. })
  5234. })
  5235. }
  5236.  
  5237. var f = 1, g = 3, h = 9, i = 5;
  5238. return {
  5239. init: b, initForm: function () {
  5240. c(), d()
  5241. }
  5242. }
  5243. }(jQuery), Gewinnspiele = function (a) {
  5244. function b() {
  5245. a("body").hasClass("mobile") && (s = !0), k(), l(), a(document).bind("gform_post_render", function (a, b) {
  5246. b !== o && b !== p && b !== q && b !== r && Gewinnspiele.initGewinnspielFormulare()
  5247. })
  5248. }
  5249.  
  5250. function c() {
  5251. a(".gewinnspielTeilnahmebedingungenLink").on("click", function (b) {
  5252. b.preventDefault(), m = a(this).closest("label");
  5253. var c = a(this).closest(".flexsliderGewinnspiel").next(".gewinnspielTeilnahmebedingungen").html();
  5254. a.magnificPopup.open({
  5255. items: {src: c},
  5256. type: "inline",
  5257. tClose: "Schliessen (Esc)",
  5258. callbacks: {
  5259. open: function () {
  5260. d()
  5261. }
  5262. }
  5263. })
  5264. })
  5265. }
  5266.  
  5267. function d() {
  5268. a(".gewinnspielDatenschutzbestimmungenLinkLightbox").on("click", function (b) {
  5269. b.preventDefault(), a.magnificPopup.close(), m.find("a.gewinnspielDatenschutzbestimmungenLink").trigger("click")
  5270. })
  5271. }
  5272.  
  5273. function e() {
  5274. a(".gewinnspielDatenschutzbestimmungenLink").on("click", function (b) {
  5275. b.preventDefault(), m = a(this).closest("label");
  5276. var c = a(this).closest(".flexsliderGewinnspiel").next().next(".gewinnspielDatenschutzbestimmungen").html();
  5277. a.magnificPopup.open({
  5278. items: {src: c},
  5279. type: "inline",
  5280. tClose: "Schliessen (Esc)",
  5281. callbacks: {
  5282. open: function () {
  5283. f()
  5284. }
  5285. }
  5286. })
  5287. })
  5288. }
  5289.  
  5290. function f() {
  5291. a(".gewinnspielTeilnahmebedingungenLinkLightbox").on("click", function (b) {
  5292. b.preventDefault(), a.magnificPopup.close(), m.find("a.gewinnspielTeilnahmebedingungenLink").trigger("click")
  5293. })
  5294. }
  5295.  
  5296. function g(b, c) {
  5297. n = a("#gewinnspielFeedback" + c).html(), a("#" + b + " input.gewinnspielAntwort").change(function () {
  5298. var d = parseInt(a("#" + b + " input[type=radio]:checked").val(), 10);
  5299. a("#" + b + " .antwortoption").removeClass("selected").removeClass("false"), a("#" + b + " .antwortoption.selected").removeClass("selected"), a("#" + b + " #gewinnspielAntwort_" + c + "_" + d).addClass("selected"), a("#gewinnspielAlert" + c + ":visible").hide(), a("#gewinnspielFeedback" + c + ":visible").fadeOut()
  5300. })
  5301. }
  5302.  
  5303. function h(b, c) {
  5304. a("#" + b).submit(function () {
  5305. var d = parseInt(a("#" + b + " input[type=radio]:checked").val(), 10);
  5306. return isNaN(d) ? a("#gewinnspielAlert" + c).show() : (a("#gewinnspielAlert" + c + ":visible").hide(), 1 === a("#" + b).data("retry") ? d === parseInt(a("#" + b).data("id"), 10) ? (a("#" + b + " .antwortoption.selected").addClass("true"), i(c, a(this), d)) : (a("#" + b + " .antwortoption.selected").data("wrong").length > 0 ? a("#gewinnspielFeedback" + c).html(a("#" + b + " .antwortoption.selected").data("wrong")) : a("#gewinnspielFeedback" + c).html(n), a("#gewinnspielFeedback" + c).fadeIn(), a("#" + b + " .antwortoption.selected").addClass("false")) : i(c, a(this), d)), !1
  5307. })
  5308. }
  5309.  
  5310. function i(b, c, d) {
  5311. a("#gewinnspielSubmit" + b).attr("disabled", "disabled"), c.closest(".gewinnspielContent").nextAll(".gewinnspielFormular").find(".gewinnspielantwort").find("input").val(d), setTimeout(function () {
  5312. c.closest(".flexsliderGewinnspiel").flexslider("next")
  5313. }, 1e3)
  5314. }
  5315.  
  5316. function j() {
  5317. var b = a(".flexsliderGewinnspiel").data("id"), c = "gewinnspielFrageForm" + b;
  5318. Gewinnspiele.setupChangeListener(c, b), Gewinnspiele.setupSubmitListener(c, b)
  5319. }
  5320.  
  5321. function k() {
  5322. var b = 2;
  5323. if (s) {
  5324. b = 1;
  5325. var c = a(".gewinnspielImage");
  5326. c.prev().prepend(c.html()), c.next().prepend(c.html()), c.remove()
  5327. }
  5328. var d = {
  5329. animationLoop: !1,
  5330. touch: !1,
  5331. controlNav: !1,
  5332. directionNav: !1,
  5333. keyboard: !1,
  5334. itemWidth: 585,
  5335. minItems: b,
  5336. maxItems: b,
  5337. useCSS: !1,
  5338. after: function (b) {
  5339. if (Tracking.track("click", "GewinnspielFormular", "Gewinnspiel-Formular Anzeige", !1), s) {
  5340. var c = a(b.slides.eq(b.currentSlide)).find("form"), d = {easing: "swing"};
  5341. a.scrollTo(c, 800, d)
  5342. }
  5343. }
  5344. };
  5345. ContentSlider.addSlider(".flexsliderGewinnspiel", d)
  5346. }
  5347.  
  5348. function l() {
  5349. c(), e()
  5350. }
  5351.  
  5352. var m, n, o = 3, p = 9, q = 5, r = 1, s = !1;
  5353. return {
  5354. init: b, initGewinnspielFormulare: function () {
  5355. l()
  5356. }, setupChangeListener: function (a, b) {
  5357. g(a, b)
  5358. }, setupSubmitListener: function (a, b) {
  5359. h(a, b)
  5360. }, setupGenericGewinnspiel: function () {
  5361. j()
  5362. }
  5363. }
  5364. }(jQuery), Intro = function (a) {
  5365. function b() {
  5366. a("#intro").length > 0 && c()
  5367. }
  5368.  
  5369. function c() {
  5370. ContentSlider.addSlider("#intro .flexslider", {
  5371. animationLoop: !1, video: !0, start: function () {
  5372. }, before: function (b) {
  5373. var c = a(b.slides.eq(b.animatingTo)).find("img");
  5374. c.addClass("unveiled"), d && (d[0].paused || d[0].pause())
  5375. }, after: function (a) {
  5376. Tracking.track("click", "IntroSlide", "Intro Slide " + a.currentSlide, !1)
  5377. }
  5378. })
  5379. }
  5380.  
  5381. {
  5382. var d;
  5383. pickup_vars.template + "/assets/video/", a('<a href="#" class="scrolling videoLinkBox">'), a('<a href="#" class="videoReplay"></a>')
  5384. }
  5385. return {init: b}
  5386. }(jQuery), Loading = function (a) {
  5387. function b() {
  5388. e && !e.is(":visible") && e.modal("show")
  5389. }
  5390.  
  5391. function c() {
  5392. e && e.is(":visible") && e.modal("hide")
  5393. }
  5394.  
  5395. function d() {
  5396. requirejs.config({baseUrl: pickup_vars.template + "/assets/js"}), requirejs(["libs/require/plugins/text!pickup/templates/TemplateLoading.html"], function (b) {
  5397. var c = _.template(b);
  5398. a("body").append(c), e = a("#modalLoading"), e.modal({keyboard: !1, backdrop: "static", show: !1})
  5399. })
  5400. }
  5401.  
  5402. var e;
  5403. return {init: d, show: b, hide: c}
  5404. }(jQuery), Newsletter = function (a) {
  5405. "use strict";
  5406. function b() {
  5407. a(".newsletter-toggle").on("click", function (b) {
  5408. b.preventDefault();
  5409. var c = a(".newsletter-content-wrapper"), d = a(".newsletter-btn-clickarea");
  5410. c.is(":visible") ? (a(".newsletter-btn-close").fadeOut("fast"), c.hide(), d.show()) : (d.hide(), c.show(), a(".newsletter-btn-close").fadeIn("fast"), Tracking.track("click", "NewsletterDropdown", "Header Newsletter-Dropdown", !0))
  5411. })
  5412. }
  5413.  
  5414. var c = 3, d = 9, e = 5;
  5415. return {
  5416. init: function () {
  5417. b(), a("#newsletterFormularFooter #input_3_5 input").attr("id", "choice_3_5_1"), a("#newsletterFormularFooter #input_3_5 input").attr("name", "input_3_5.1"), a("#newsletterFormularFooter #input_3_5 label").attr("for", "input_3_5.1"), a(document).bind("gform_confirmation_loaded", function (b, f) {
  5418. switch (f) {
  5419. case c:
  5420. Tracking.trackTarget("Newsletter", "Newsletter", "Newsletteranmeldung Footer"), a("#footerNewsletterText").hide();
  5421. break;
  5422. case d:
  5423. Tracking.trackTarget("Newsletter", "Newsletter", "Newsletteranmeldung Header"), a("#headerNewsletterText").hide();
  5424. break;
  5425. case e:
  5426. Tracking.trackTarget("Newsletter", "Newsletter", "Newsletteranmeldung Mobile")
  5427. }
  5428. })
  5429. }
  5430. }
  5431. }(jQuery), PageSettings = function (a) {
  5432. function b() {
  5433. a("body").hasClass("homepage") && a("a.navbar-brand, a.brandFlip").on("click", function (b) {
  5434. var c = {easing: "swing"};
  5435. a.scrollTo("0px", 800, c), b.preventDefault()
  5436. })
  5437. }
  5438.  
  5439. function c() {
  5440. /*a("canvas.nav-canvas").lines({
  5441. direction: "up",
  5442. color: {top: "#ffcc00", bottom: "transparent"},
  5443. shadow: {type: "inner", opacity: .3, color: {R: 80, G: 80, B: 80}, height: 10}
  5444. }), a("canvas.up.inner").lines({
  5445. direction: "up",
  5446. shadow: {type: "inner", opacity: .3, color: {R: 80, G: 80, B: 80}, height: 10}
  5447. }), a("canvas.up.outer").lines({
  5448. direction: "up",
  5449. shadow: {type: "outer", opacity: .3, color: {R: 80, G: 80, B: 80}, height: 10}
  5450. }), a("canvas.down.outer").lines({
  5451. direction: "down",
  5452. shadow: {type: "outer", opacity: .3, color: {R: 80, G: 80, B: 80}, height: 10}
  5453. }), a("canvas.down.inner").lines({
  5454. direction: "down",
  5455. shadow: {type: "inner", opacity: .3, color: {R: 80, G: 80, B: 80}, height: 10}
  5456. })*/
  5457. }
  5458.  
  5459. function d(b) {
  5460. if (0 !== a(b).length) {
  5461. var c = !1, d = !1, e = !1, f = "image", g = {};
  5462. a(b).hasClass("recipe") ? (e = !0, c = !0, f = "ajax") : a(b).hasClass("html") ? (e = !0, f = "ajax") : a(b).hasClass("iframe") ? f = "iframe" : (d = !0, g = {closeOnContentClick: !0});
  5463. var h = {
  5464. callbacks: {
  5465. elementParse: function (a) {
  5466. if (e) {
  5467. var b = a.el.attr("href");
  5468. a.src = -1 !== b.indexOf("?") ? b + "&display=inline" : b + "?display=inline"
  5469. }
  5470. }, updateStatus: function (a) {
  5471. "ready" === a.status && c && Rezepte.initFlexslider()
  5472. }
  5473. }, type: f, tLoading: "", closeBtnInside: !0, tClose: "Schliessen (Esc)"
  5474. };
  5475. a.extend(h, g), a(b).magnificPopup(h)
  5476. }
  5477. }
  5478.  
  5479. function e(b, c, d) {
  5480. a(b).on("click", function (b) {
  5481. if (a(this.hash).length > 0) {
  5482. "function" == typeof c && c();
  5483. var e = a(this).attr("href"), f = 0;
  5484. a.each(i, function (a, b) {
  5485. return e === b.target ? (f = b.offset, !1) : void 0
  5486. });
  5487. var g = {easing: "swing", offset: f};
  5488. "function" == typeof d && a.extend({}, g, {onAfter: d()}), a.scrollTo(this.hash, 800, g), b.preventDefault()
  5489. }
  5490. })
  5491. }
  5492.  
  5493. function f() {
  5494. a(".querverlinkung a").on("click", function () {
  5495. var b = a(this).attr("data-product-id"), c = a(this).attr("href");
  5496. if ("#alleRezepte" === c) {
  5497. var d = a(this).attr("data-product-name");
  5498. a("#rezeptFilterSorte").selectbox("change", b, d)
  5499. } else {
  5500. var e = a(c + " .slides > li." + b).not(".clone"), f = a(c + " .slides > li").not(".clone"), g = f.index(e);
  5501. g > -1 && a(c + " .flexslider").flexslider(g)
  5502. }
  5503. })
  5504. }
  5505.  
  5506. function g() {
  5507. a("#main-navigation").waypoint("sticky", {wrapper: '<div class="sticky-wrapper" />', stuckClass: "stuck"})
  5508. }
  5509.  
  5510. function h() {
  5511. a("body").hasClass("homepage") && a("#menu-hauptnavigation").onePageNav({
  5512. currentClass: "active",
  5513. changeHash: !0,
  5514. scrollSpeed: 1e3,
  5515. scrollOffset: 0
  5516. })
  5517. }
  5518.  
  5519. var i = [{target: "#produkte", offset: 60}, {target: "#videos", offset: 50}, {
  5520. target: "#rezepte",
  5521. offset: 120
  5522. }, {target: "#alleRezepte", offset: -100}, {target: "#aktionen0", offset: -80}];
  5523. return {
  5524. init: function () {
  5525. a("body").hasClass("daten-aendern") && a("#gform_submit_button_3").attr("value", "Daten ändern"), g(), b(), d(".content a.lightbox.img"), d(".content a.lightbox.recipe"), d(".content a.lightbox.html"), d(".content a.lightbox.iframe"), d(".content area.lightbox.iframe"), e("a.scrolling, .scrolling a"), f(), c(), h(), a("#facebookLike").twoClickSocial({
  5526. url: "http://www.pickup.de/",
  5527. facebook: {like: !0},
  5528. tooltip: {url: a("head base").attr("href").length > 0 ? a("head base").attr("href") + "/datenschutz#social-plugins" : document.location.protocol + "//" + document.location.host + "/datenschutz#social-plugins"}
  5529. })
  5530. }, initLightboxLinks: function (a) {
  5531. d(a)
  5532. }, initScrollLinks: function (a, b, c) {
  5533. e(a, b, c)
  5534. }
  5535. }
  5536. }(jQuery), Produkte = function (a) {
  5537. function b() {
  5538. var b = 1400;
  5539. m && (b = 600);
  5540. var d = {
  5541. animationSpeed: b, easing: "easeOutCirc", touch: n, useCSS: !1, start: function (b) {
  5542. var c = a(b.slides.eq(b.currentSlide)).find(".produktName");
  5543. c.show().css("marginTop", "20px")
  5544. }, before: function (b) {
  5545. if (m)f(), console.log("slide"), window.addEventListener("orientationchange", function () {
  5546. f(), console.log("slideWindowSize")
  5547. }, !1), a(".product-details").length > 0 && (a(".product-details").hide().css("float", "none"), a(".close-details-btn").hide()); else {
  5548. var c = a(b.slides.eq(b.animatingTo)).find(".produktName");
  5549. c.css("marginTop", "-280px"), a(b.slides.eq(b.animatingTo)).find(".produktDetails").hide()
  5550. }
  5551. {
  5552. var d = a(b.slides.eq(b.animatingTo)).attr("class");
  5553. a(b).find("." + d + " img.unveil").unveil()
  5554. }
  5555. }, after: function (b) {
  5556. if (Tracking.track("click", "ProduktSlide", "Produkte Anzeige Slide " + b.currentSlide, !1), !m) {
  5557. c(b), a("#produkte .flexslider ul.slides li").find(".produktDetails").hide();
  5558. {
  5559. a(b.slides.eq(b.animatingTo)).find(".produktDetails").fadeIn()
  5560. }
  5561. }
  5562. }
  5563. };
  5564. ContentSlider.addSlider("#produkte .flexslider", d)
  5565. }
  5566.  
  5567. function c(b) {
  5568. var c = a(b.slides.eq(b.animatingTo)).find(".produktName");
  5569. c.show().animate({marginTop: "20px"}, 600, "easeOutElastic")
  5570. }
  5571.  
  5572. function d() {
  5573. a(".product-details-btn").on("click", function (b) {
  5574. b.preventDefault();
  5575. var c = a(this).attr("data-productId");
  5576. return "loading" === o[c] ? (console.log("loading"), void 0) : ("undefined" == typeof o[c] ? (o[c] = "loading", e(c)) : a("#product-details-" + c).is(":visible") ? h(c) : g(c), void 0)
  5577. })
  5578. }
  5579.  
  5580. function e(b) {
  5581. i = a("#produkte .flex-active-slide").find(".product-details-btn"), j = a("#produkte .flexslider");
  5582. var c = i.attr("data-nonce"), d = i.attr("data-productId"), e = {
  5583. url: pickup_vars.ajaxurl,
  5584. data: {action: "product_details", productId: d, nonce: c}
  5585. };
  5586. a.ajax(a.extend({}, k, e)).done(function (a) {
  5587. j.after(a.html), g(d)
  5588. }).fail(function () {
  5589. j.append(l.fail_loading)
  5590. }).always(function () {
  5591. log("done"), o[b] = "done"
  5592. })
  5593. }
  5594.  
  5595. function f() {
  5596. var b = a(".flex-active-slide .produktcontent img").height();
  5597. a("#produkte .flexslider ul.slides li .product-img").css("height", b)
  5598. }
  5599.  
  5600. function g(b) {
  5601. a("#product-details-" + b).slideDown(), a(".close-details-btn").show()
  5602. }
  5603.  
  5604. function h(b) {
  5605. a("#product-details-" + b).slideUp(), a(".close-details-btn").hide()
  5606. }
  5607.  
  5608. var i, j, k = {
  5609. type: "post",
  5610. dataType: "json"
  5611. }, l = {
  5612. fail_loading: '<p class="fail">Leider konnten wir die Zutaten und Nährwerte für dieses Produkt nicht laden.</p>',
  5613. no_results: '<p class="fail">Für dieses Produkt gibt es keine genauen Informationen</p>'
  5614. }, m = !1, n = !0, o = {};
  5615. return {
  5616. init: function () {
  5617. a("body").hasClass("mobile") && (m = !0, a("body").hasClass("windowsphone") && (n = !1), d()), b()
  5618. }
  5619. }
  5620. }(jQuery), Rezepte = function (a) {
  5621. function b(b) {
  5622. a(b).selectbox(t)
  5623. }
  5624.  
  5625. function c(a) {
  5626. a.selectbox("detach"), a.selectbox("attach", t)
  5627. }
  5628.  
  5629. function d(b, c) {
  5630. c ? a(b).removeAttr("disabled") : a(b).attr("disabled", "disabled")
  5631. }
  5632.  
  5633. function e() {
  5634. var c = {url: pickup_vars.ajaxurl, data: {action: "get_recipes"}};
  5635. a.ajax(a.extend({}, q, c)).done(function (c) {
  5636. a("#recipesAdditional").html(c.html), m = a("#rezeptListe"), n = a("#more_recipes"), o = a("#rezeptFilterKategorie"), p = a("#rezeptFilterSorte"), b(".rezeptSelect"), a("#more_recipes").on("click", function (a) {
  5637. a.preventDefault(), f()
  5638. }), a.waypoints("refresh")
  5639. }).fail(function () {
  5640. m = a("#recipesAdditional"), m.html(r.fail_loading)
  5641. }).always(function () {
  5642. l()
  5643. })
  5644. }
  5645.  
  5646. function f() {
  5647. var b = n.attr("data-nonce"), c = n.attr("data-offset"), d = n.attr("data-limit"), e = o.val(), f = p.val();
  5648. Loading.show();
  5649. var g = {
  5650. url: pickup_vars.ajaxurl,
  5651. data: {action: "more_recipes", nonce: b, offset: c, limit: d, category: e, product: f}
  5652. };
  5653. a.ajax(a.extend({}, q, g)).done(function (b) {
  5654. m.append('<div class="moreRecipes">' + b.html + "</div>");
  5655. var e = a("#rezeptListe .moreRecipes .rezept").hide();
  5656. e.each(function (b) {
  5657. a(this).delay(200 * b).fadeIn()
  5658. }), a("#rezeptListe").find(".moreRecipes").removeClass("moreRecipes"), b.more ? n.attr("data-offset", +parseInt(c, 10) + parseInt(d, 10)) : n.hide().next(".btnShadow").hide(), a.waypoints("refresh")
  5659. }).fail(function () {
  5660. m.html(r.fail_loading)
  5661. }).always(function () {
  5662. Loading.hide(), l()
  5663. })
  5664. }
  5665.  
  5666. function g() {
  5667. $containerMobile = a("#rezepte .flexslider"), $moreButtonMobile = a("#more_recipes_mobile"), a("#more_recipes_mobile").on("click", function (a) {
  5668. a.preventDefault(), h()
  5669. })
  5670. }
  5671.  
  5672. function h() {
  5673. var b = $moreButtonMobile.attr("data-nonce"), c = $moreButtonMobile.attr("data-offset"), d = $moreButtonMobile.attr("data-limit");
  5674. Loading.show();
  5675. var e = {url: pickup_vars.ajaxurl, data: {action: "more_recipes_mobile", nonce: b, offset: c, limit: d}};
  5676. a.ajax(a.extend({}, q, e)).done(function (b) {
  5677. "4" === c ? $containerMobile.after('<div class="center" id="mobileMoreRecipes"><h3>NOCH MEHR KNACKIGE REZEPTE:</h3>' + b.html + "</div>") : a("#mobileMoreRecipes").append(b.html), b.more ? $moreButtonMobile.attr("data-offset", +parseInt(c, 10) + parseInt(d, 10)) : $moreButtonMobile.hide()
  5678. }).fail(function () {
  5679. $containerMobile.html(r.fail_loading)
  5680. }).always(function () {
  5681. Loading.hide()
  5682. })
  5683. }
  5684.  
  5685. function i(b) {
  5686. var c = b.input.attr("data-nonce"), d = o.val(), e = p.val(), f = n.attr("data-limit");
  5687. Loading.show();
  5688. var g = {url: pickup_vars.ajaxurl, data: {action: "filter_recipes", nonce: c, category: d, product: e}};
  5689. a.ajax(a.extend({}, q, g)).done(function (a) {
  5690. var b = a.html ? a.html : r.no_results;
  5691. m.html(b), a.more ? (n.attr("data-offset", f), n.show().next().show()) : n.hide().next().hide()
  5692. }).fail(function () {
  5693. m.html(r.fail_loading)
  5694. }).always(function () {
  5695. Loading.hide(), l()
  5696. })
  5697. }
  5698.  
  5699. function j(b, e) {
  5700. var f;
  5701. if (b.id === o.attr("id"))f = p; else {
  5702. if (b.id !== p.attr("id"))return;
  5703. f = o
  5704. }
  5705. f.find("option").each(function () {
  5706. if ("" === e)return d(this, !0), !0;
  5707. var b = a(this).attr("data-refs");
  5708. if (b) {
  5709. var c = !1;
  5710. a.each(b.split(","), function (a, b) {
  5711. return b === e ? (c = !0, void 0) : void 0
  5712. }), d(this, c)
  5713. }
  5714. }), c(f)
  5715. }
  5716.  
  5717. function k(b, c) {
  5718. var d = a("#" + b.id).next(".sbHolder").find("ul li a");
  5719. d.removeClass("highlightTextColor"), a("#" + b.id).next(".sbHolder").find('ul li a[rel="' + c + '"]').toggleClass("highlightTextColor")
  5720. }
  5721.  
  5722. function l() {
  5723. "undefined" != typeof PageSettings && PageSettings.initLightboxLinks(".rezept a.lightbox"), a.isFunction(jQuery().hoverIntent) ? a(".rezept").hoverIntent(function () {
  5724. a(this).animate({boxShadow: "0 0 12px rgba(0,0,0,0.4)"}, 500)
  5725. }, function () {
  5726. a(this).animate({boxShadow: "0 0 0 rgba(0,0,0,0)"}, 900)
  5727. }) : a(".rezept").on("mouseenter", this.mouseEnterHandler).on("mouseleave", this.mouseLeaveHandler)
  5728. }
  5729.  
  5730. var m, n, o, p, q = {
  5731. type: "post",
  5732. dataType: "json"
  5733. }, r = {
  5734. fail_loading: '<p class="fail">Oh nein! Leider konnten wir keine weiteren Rezepte laden.</p>',
  5735. no_results: '<p class="fail">F&uuml;r diese Auswahl gibt es leider keine Rezepte.</p>',
  5736. slider_left_overview: "Zur Schritt-f&uuml;r-Schritt Anleitung<span></span>",
  5737. slider_left_step: "Zum n&auml;chsten Schritt<span></span>"
  5738. }, s = !0, t = {
  5739. onChange: function (a, b) {
  5740. i(b), j(b, a), k(b, a)
  5741. }
  5742. };
  5743. return {
  5744. initFlexslider: function () {
  5745. a("#rezept-slider").length > 0 && (a("body").hasClass("mobile") || a("#recipe-social-media").twoClickSocial({
  5746. url: a("#permalinkRecipe").html().length > 0 ? a("#permalinkRecipe").html() : "http://www.pickup.de",
  5747. facebook: {like: !0, share: !0},
  5748. pinterest: {pinterest: !0},
  5749. tooltip: {
  5750. direction: "top",
  5751. url: a("head base").attr("href").length > 0 ? a("head base").attr("href") + "/datenschutz#social-plugins" : document.location.protocol + "//" + document.location.host + "/datenschutz#social-plugins"
  5752. }
  5753. }), a(".next-slide").html(r.slider_left_overview), a("#rezept-slider").flexslider({
  5754. slideshow: !1,
  5755. directionNav: !1,
  5756. animation: "slide",
  5757. easing: "easeInOutCirc",
  5758. animationSpeed: 1400,
  5759. animationLoop: !1,
  5760. selector: ".rezept-slides > .rezept-slide",
  5761. manualControls: ".rezept-slider-nav > li > a",
  5762. touch: s,
  5763. start: function (b) {
  5764. a(b.slides.eq(b.currentSlide)).find(".zubereitungsschrittZutaten").show()
  5765. },
  5766. before: function (b) {
  5767. 0 === b.animatingTo ? (a(".prev-slide").fadeOut(300), a(".recipe-thumb").fadeOut(300), a(".next-slide").html(r.slider_left_overview)) : (a(".prev-slide").fadeIn(300), a(".recipe-thumb").delay(300).fadeIn(300), a(".next-slide").html(r.slider_left_step));
  5768. a(b.slides.eq(b.animatingTo)).find(".zubereitungsschrittZutaten").show();
  5769. b.animatingTo === b.count - 1 ? a(".next-slide").fadeOut(300) : a(".next-slide").fadeIn(300)
  5770. }
  5771. }), a(".next-slide").on("click", function (b) {
  5772. a("#rezept-slider").flexslider("next"), b.preventDefault()
  5773. }), a(".prev-slide").on("click", function (b) {
  5774. a("#rezept-slider").flexslider("prev"), b.preventDefault()
  5775. }))
  5776. }, init: function () {
  5777. a("body").hasClass("windowsphone") && (s = !1), a("body").hasClass("mobile") ? (ContentSlider.addSlider("#rezepte .flexslider"), a(".next-slide").html("Vor<span></span>"), a(".prev-slide").html("Zur&uuml;ck<span></span>"), g()) : a("#rezepte").waypoint(function () {
  5778. e()
  5779. }, {triggerOnce: !0, offset: "100%"}), Rezepte.initFlexslider()
  5780. }
  5781. }
  5782. }(jQuery), PickupSounds = function (a) {
  5783. function b() {
  5784. try {
  5785. var a = new Audio, b = !!a.canPlayType, c = !!(b ? !1 : a.play);
  5786. b || c ? "" !== Modernizr.audio.m4a && "no" !== Modernizr.audio.m4a ? supportedAudioFormat = "m4a" : "" !== Modernizr.audio.ogg && "no" !== Modernizr.audio.ogg && (supportedAudioFormat = "ogg") : supportedAudioFormat = !1
  5787. } catch (d) {
  5788. supportedAudioFormat = !1
  5789. }
  5790. return supportedAudioFormat
  5791. }
  5792.  
  5793. function c(b, c) {
  5794. a("#debug").empty().html("_loadAudio: " + b);
  5795. var d = b, e = new Audio(d);
  5796. return e.addEventListener("canplaythrough", function () {
  5797. a("#debug").empty().html("_loadAudio: canplaythrough"), "function" == typeof c && c()
  5798. }, !1), e.addEventListener("error", function () {
  5799. a("#debug").empty().html("_loadAudio: error"), "function" == typeof c && c()
  5800. }, !1), e.addEventListener("abort", function () {
  5801. a("#debug").empty().html("_loadAudio: abort"), "function" == typeof c && c()
  5802. }, !1), e.load(), e
  5803. }
  5804.  
  5805. return {
  5806. getSupportedAudioFormat: function () {
  5807. return b()
  5808. }, loadAudio: function (a, b) {
  5809. return c(a, b)
  5810. }
  5811. }
  5812. }(jQuery), Videos = function (a) {
  5813. function b() {
  5814. i = ContentSlider.addSlider("#videos .flexslider", {
  5815. animationLoop: !1,
  5816. animationSpeed: 1e3,
  5817. useCSS: !1,
  5818. start: function () {
  5819. g(a("#videos .flexslider li:eq(0)")), c(".videolink"), e()
  5820. },
  5821. before: function (b) {
  5822. d(b);
  5823. var c = b.slides.eq(b.animatingTo);
  5824. if (a(c).find("div.btnWrap").hide(), b.animatingTo > b.currentSlide) {
  5825. g(c, b.animatingTo);
  5826. var e = a(c).find("img.unveil");
  5827. e.unveil()
  5828. } else h(b.animatingTo)
  5829. },
  5830. after: function (b) {
  5831. Tracking.track("click", "SpotSlide", "Spots Anzeige Slide " + b.currentSlide, !1);
  5832. var c = a(b.slides.eq(b.currentSlide)).find("div.btnWrap");
  5833. c.delay(1e3).fadeIn(400)
  5834. }
  5835. })
  5836. }
  5837.  
  5838. function c(b) {
  5839. a(b).on("click", function (b) {
  5840. if (b.preventDefault(), !a(this).parent().hasClass("active")) {
  5841. var c = a(this).data("video"), d = (a(this).data("target"), "http://www.youtube.com/watch?v=" + c), e = j, f = a(this).attr("title"), g = a(this).data("beschreibung");
  5842. Loading.show(), e.setSrc(d), e.load(), e.play(), Loading.hide();
  5843. var h = a("#videos li.flex-active-slide");
  5844. h.find("h1.videotitle").html(f), h.find(".videobeschreibung").html(g), h.find(".videoPlaylist li.active").removeClass("active"), a(this).parent().addClass("active")
  5845. }
  5846. })
  5847. }
  5848.  
  5849. function d(b) {
  5850. a("#videos .flexslider li.video:eq(" + b.currentSlide + ") video").each(function () {
  5851. f()
  5852. })
  5853. }
  5854.  
  5855. function e() {
  5856. a("#videos li.video").waypoint(function (a) {
  5857. "up" === a && f()
  5858. }, {
  5859. offset: function () {
  5860. return a(this).height()
  5861. }
  5862. }).waypoint(function (a) {
  5863. "down" === a && f()
  5864. }, {
  5865. offset: function () {
  5866. return -1 * a(this).height()
  5867. }
  5868. })
  5869. }
  5870.  
  5871. function f() {
  5872. j && !j.paused && j.pause()
  5873. }
  5874.  
  5875. function g(b, c) {
  5876. var d = pickup_vars.template + "/assets/js/vendor/";
  5877. b.hasClass("videoInitialised") ? h(c) : (j = b.addClass("videoInitialised").find("video:eq(0)").mediaelementplayer({
  5878. pluginPath: d,
  5879. features: ["playpause", "progress", "current", "duration", "volume", "fullscreen"],
  5880. flashName: "flashmediaelement.swf",
  5881. success: function (b) {
  5882. a(b).bind("play", function () {
  5883. Tracking.track("videostart", "SpotPlay", "Spot play", !0)
  5884. })
  5885. }
  5886. }), j = j[0].player, k.push(j))
  5887. }
  5888.  
  5889. function h(a) {
  5890. j = k[a]
  5891. }
  5892.  
  5893. var i, j, k = [];
  5894. return {
  5895. init: function () {
  5896. a("#videos").length > 0 && (b(), a("#videos .flexslider li.flex-active-slide .videoPlaylist img.unveil").unveil())
  5897. }
  5898. }
  5899. }(jQuery);
  5900. window.log = function () {
  5901. log.history = log.history || [], log.history.push(arguments), this.console && console.log(Array.prototype.slice.call(arguments))
  5902. }, window.timelog = function () {
  5903. if (log.history = log.history || [], log.history.push(arguments), this.console) {
  5904. var a = new Date, b = a.getHours() + ":" + a.getMinutes() + ":" + a.getSeconds() + ":" + a.getMilliseconds();
  5905. console.log(b + ": " + Array.prototype.slice.call(arguments))
  5906. }
  5907. }, $.urlParam = function (a) {
  5908. var b = new RegExp("[\\?&]" + a + "=([^&#]*)").exec(window.location.href);
  5909. return null == b ? null : b[1] || 0
  5910. };
  5911. var Tracking = function (a) {
  5912. function b() {
  5913. a("#menu-meta-company-navigation li.menu-leibniz-de a").bind("click", function () {
  5914. c("link", "HeaderLeibniz", "Link auf www.leibniz.de", !0)
  5915. }), a("#menu-meta-company-navigation li.menu-unternehmen a").bind("click", function () {
  5916. c("link", "HeaderUnternehmen", "Link auf www.bahlsen.com", !0)
  5917. }), a("#main-navigation .socialfacebook a").bind("click", function () {
  5918. c("link", "HeaderSocialMediaFacebook", "Header Link auf Facebook", !0)
  5919. }), a("#main-navigation .socialyoutube a").bind("click", function () {
  5920. c("link", "HeaderSocialMediaFacebook", "Header Link auf YouTube", !0)
  5921. }), a("#main-navigation .socialpinterest a").bind("click", function () {
  5922. c("link", "HeaderSocialMediaFacebook", "Header Link auf Pinterest", !0)
  5923. }), a("#menu-hauptnavigation li.menu-produkte a").bind("click", function () {
  5924. c("link", "HauptnavigationProdukte", "Hauptnavigation Produkte", !1)
  5925. }), a("#menu-hauptnavigation li.menu-rezepte a").bind("click", function () {
  5926. c("link", "HauptnavigationRezepte", "Hauptnavigation Rezepte", !1)
  5927. }), a("#menu-hauptnavigation li.menu-spots a").bind("click", function () {
  5928. c("link", "HauptnavigationSpots", "Hauptnavigation Spots", !1)
  5929. }), a("#menu-hauptnavigation li.menu-aktionen a").bind("click", function () {
  5930. c("link", "HauptnavigationAktionen", "Hauptnavigation Aktionen", !1)
  5931. }), a("#facebook .rfb-link").bind("click", function () {
  5932. c("link", "FacebookPostLink", "Facebook Klick auf Post-Link", !1)
  5933. }), a("a.track").bind("click", function () {
  5934. var b = a(this).data("track");
  5935. b || (b = "Beschreibung ist leer"), c("click", "TrackingLink", b, !1)
  5936. }), a("footer.content-info .nav li.socialfacebook a").bind("click", function () {
  5937. c("link", "FooterSocialMediaFacebook", "Footer Facebook", !0)
  5938. }), a("footer.content-info .nav li.socialyoutube a").bind("click", function () {
  5939. c("link", "FooterSocialMediaYoutube", "Footer YouTube", !0)
  5940. }), a("footer.content-info .nav li.socialpinterest a").bind("click", function () {
  5941. c("link", "FooterSocialMediaPinterest", "Footer Pinterest", !0)
  5942. }), a("#rezepte").waypoint(function () {
  5943. c("page", "SectionRezepte", "Section Rezepte", !0)
  5944. }, {triggerOnce: !0, offset: 200}), a("#beissdichdurch").waypoint(function () {
  5945. c("page", "SectionBeissdichdurch", "Section Beiss dich durch", !0)
  5946. }, {triggerOnce: !0, offset: 200}), a("#videos").waypoint(function () {
  5947. c("page", "SectionSpots", "Section Spots", !0)
  5948. }, {triggerOnce: !0, offset: 200}), a("#bergaufundup").waypoint(function () {
  5949. c("page", "SectionBergaufundup", "Section Berg Auf und Up", !0)
  5950. }, {triggerOnce: !0, offset: 200}), a("#aktionen0").waypoint(function () {
  5951. c("page", "SectionAktionen", "Section Aktion", !0)
  5952. }, {triggerOnce: !0, offset: 200}), a("#aktionen1").waypoint(function () {
  5953. c("page", "SectionAktionen", "Section Aktion 2", !0)
  5954. }, {triggerOnce: !0, offset: 200}), a("#newsletter").waypoint(function () {
  5955. c("page", "SectionNewsletter", "Section Newsletter", !0)
  5956. }, {triggerOnce: !0, offset: 200})
  5957. }
  5958.  
  5959. function c(b, c, d, g) {
  5960. if ("function" == typeof et_eC_Wrapper && "object" == typeof ET_Event) {
  5961. b = b ? b : "click", c = c ? encodeURIComponent(c) : "";
  5962. var h = d ? encodeURIComponent(d) : "";
  5963. if (g) {
  5964. if (-1 !== a.inArray(c, f))return;
  5965. f.push(c)
  5966. }
  5967. switch (b) {
  5968. case"link":
  5969. ET_Event.link(h, c);
  5970. break;
  5971. case"download":
  5972. ET_Event.download(h, c);
  5973. break;
  5974. case"videostart":
  5975. ET_Event.videoStart(h);
  5976. break;
  5977. case"videostop":
  5978. ET_Event.videoStop(h);
  5979. break;
  5980. case"page":
  5981. et_eC_Wrapper(e, d, "", "", "", "", "", "", "", "", "", "", "");
  5982. break;
  5983. default:
  5984. ET_Event.click(h, c)
  5985. }
  5986. }
  5987. }
  5988.  
  5989. function d(a, b, c) {
  5990. "function" == typeof et_eC_Wrapper && "object" == typeof ET_Event && et_eC_Wrapper(e, a, b, "", "", c, "", "", "", "", "", "", "")
  5991. }
  5992.  
  5993. var e, f = [];
  5994. return {
  5995. init: function () {
  5996. pickup_vars.etracker.length > 0 && (e = pickup_vars.etracker, b())
  5997. }, track: function (a, b, d, e) {
  5998. c(a, b, d, e)
  5999. }, trackTarget: function (a, b, c) {
  6000. d(a, b, c)
  6001. }
  6002. }
  6003. }(jQuery), Main = function () {
  6004. "use strict";
  6005. return {
  6006. init: function () {
  6007. PageSettings.init(), Loading.init(), Intro.init(), Produkte.init(), Rezepte.init(), Videos.init(), Formulare.init(), Gewinnspiele.init(), Newsletter.init(), Tracking.init(), AuszeitzoneBeissdichdurch.init(), CarGame.init("#car-game"), AuszeitzoneKatschong.init()
  6008. }
  6009. }
  6010. }(jQuery);
  6011. $(document).ready(function () {
  6012. Main.init()
  6013. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement