PageSourceSearch

http://www.niquesatravel.com/sites/default/files/js/js_4Y9g_jFwLG3rq228T1ukna5vMIumg1U4fm5Vk32sdVM.js

js niquesatravel.com collected 2026-10-08 05:48:47 UTC 588,544 bytes, 7,165 lines download raw bytes

vendor: 3,217 bytes, lines 1-6
1/*!
2  * domready (c) Dustin Diaz 2014 - License MIT
3  */
4!function(e,t){typeof module!="undefined"?module.exports=t():typeof define=="function"&&typeof define.amd=="object"?define(t):this[e]=t()}("domready",function(){var e=[],t,n=document,r=n.documentElement.doScroll,i="DOMContentLoaded",s=(r?/^loaded|^c/:/^loaded|^i|^c/).test(n.readyState);return s||n.addEventListener(i,t=function(){n.removeEventListener(i,t),s=1;while(t=e.shift())t()}),function(t){s?setTimeout(t,0):e.push(t)}});
5/*! jQuery v3.2.1 | (c) JS Foundation and other contributors | jquery.org/license */
6!function(a,b){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){"use strict";var c=[],d=a.document,e=Object.getPrototypeOf,f=c.slice,g=c.concat,h=c.push,i=c.indexOf,j={},k=j.toString,l=j.hasOwnProperty,m=l.toString,n=m.call(Object),o={};function p(a,b){b=b||d;var c=b.createElement("script");c.text=a,b.head.appendChild(c).parentNode.removeChild(c)}var q="3.2.1",r=function(a,b){return new r.fn.init(a,b)},s=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,t=/^-ms-/,u=/-([a-z])/g,v=function(a,b){return b.toUpperCase()};r.fn=r.prototype={jquery:q,constructor:r,length:0,toArray:function(){return f.call(this)},get:function(a){return null==a?f.call(this):a<0?this[a+this.length]:this[a]},pushStack:function(a){var b=r.merge(this.constructor(),a);return b.prevObject=this,b},each:function(a){return r.each(this,a)},map:function(a){return this.pushStack(r.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(f.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(a<0?b:0);return this.pushStack(c>=0&&c<b?[this[c]]:[])},end:function(){return this.prevObject||this.constructor()},push:h,sort:c.sort,splice:c.splice},r.extend=r.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||r.isFunction(g)||(g={}),h===i&&(g=this,h--);h<i;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(r.isPlainObject(d)||(e=Array.isArray(d)))?(e?(e=!1,f=c&&Array.isArray(c)?c:[]):f=c&&r.isPlainObject(c)?c:{},g[b]=r.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},r.extend({expando:"jQuery"+(q+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===r.type(a)},isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){var b=r.type(a);return("number"===b||"string"===b)&&!isNaN(a-parseFloat(a))},isPlainObject:function(a){var b,c;return!(!a||"[object Object]"!==k.call(a))&&(!(b=e(a))||(c=l.call(b,"constructor")&&b.constructor,"function"==typeof c&&m.call(c)===n))},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?j[k.call(a)]||"object":typeof a},globalEval:function(a){p(a)},camelCase:function(a){return a.replace(t,"ms-").replace(u,v
vendor: 19,680 bytes, line 6
6)},each:function(a,b){var c,d=0;if(w(a)){for(c=a.length;d<c;d++)if(b.call(a[d],d,a[d])===!1)break}else for(d in a)if(b.call(a[d],d,a[d])===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(s,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(w(Object(a))?r.merge(c,"string"==typeof a?[a]:a):h.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:i.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;d<c;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;f<g;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,e,f=0,h=[];if(w(a))for(d=a.length;f<d;f++)e=b(a[f],f,c),null!=e&&h.push(e);else for(f in a)e=b(a[f],f,c),null!=e&&h.push(e);return g.apply([],h)},guid:1,proxy:function(a,b){var c,d,e;if("string"==typeof b&&(c=a[b],b=a,a=c),r.isFunction(a))return d=f.call(arguments,2),e=function(){return a.apply(b||this,d.concat(f.call(arguments)))},e.guid=a.guid=a.guid||r.guid++,e},now:Date.now,support:o}),"function"==typeof Symbol&&(r.fn[Symbol.iterator]=c[Symbol.iterator]),r.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(a,b){j["[object "+b+"]"]=b.toLowerCase()});function w(a){var b=!!a&&"length"in a&&a.length,c=r.type(a);return"function"!==c&&!r.isWindow(a)&&("array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a)}var x=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ha(),z=ha(),A=ha(),B=function(a,b){return a===b&&(l=!0),0},C={}.hasOwnProperty,D=[],E=D.pop,F=D.push,G=D.push,H=D.slice,I=function(a,b){for(var c=0,d=a.length;c<d;c++)if(a[c]===b)return c;return-1},J="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",K="[\\x20\\t\\r\\n\\f]",L="(?:\\\\.|[\\w-]|[^\0-\\xa0])+",M="\\["+K+"*("+L+")(?:"+K+"*([*^$|!~]?=)"+K+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+L+"))|)"+K+"*\\]",N=":("+L+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+M+")*)|.*)\\)|)",O=new RegExp(K+"+","g"),P=new RegExp("^"+K+"+|((?:^|[^\\\\])(?:\\\\.)*)"+K+"+$","g"),Q=new RegExp("^"+K+"*,"+K+"*"),R=new RegExp("^"+K+"*([>+~]|"+K+")"+K+"*"),S=new RegExp("="+K+"*([^\\]'\"]*?)"+K+"*\\]","g"),T=new RegExp(N),U=new RegExp("^"+L+"$"),V={ID:new RegExp("^#("+L+")"),CLASS:new RegExp("^\\.("+L+")"),TAG:new RegExp("^("+L+"|[*])"),ATTR:new RegExp("^"+M),PSEUDO:new RegExp("^"+N),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+K+"*(even|odd|(([+-]|)(\\d*)n|)"+K+"*(?:([+-]|)"+K+"*(\\d+)|))"+K+"*\\)|)","i"),bool:new RegExp("^(?:"+J+")$","i"),needsContext:new RegExp("^"+K+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+K+"*((?:-\\d)?\\d*)"+K+"*\\)|)(?=[^-]|$)","i")},W=/^(?:input|select|textarea|button)$/i,X=/^h\d$/i,Y=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,$=/[+~]/,_=new RegExp("\\\\([\\da-f]{1,6}"+K+"?|("+K+")|.)","ig"),aa=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:d<0?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},ba=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ca=function(a,b){return b?"\0"===a?"\ufffd":a.slice(0,-1)+"\\"+a.charCodeAt(a.length-1).toString(16)+" ":"\\"+a},da=function(){m()},ea=ta(function(a){return a.disabled===!0&&("form"in a||"label"in a)},{dir:"parentNode",next:"legend"});try{G.apply(D=H.call(v.childNodes),v.childNodes),D[v.childNodes.length].nodeType}catch(fa){G={apply:D.length?function(a,b){F.apply(a,H.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function ga(a,b,d,e){var f,h,j,k,l,o,r,s=b&&b.ownerDocument,w=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==w&&9!==w&&11!==w)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==w&&(l=Z.exec(a)))if(f=l[1]){if(9===w){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(s&&(j=s.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(l[2])return G.apply(d,b.getElementsByTagName(a)),d;if((f=l[3])&&c.getElementsByClassName&&b.getElementsByClassName)return G.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==w)s=b,r=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(ba,ca):b.setAttribute("id",k=u),o=g(a),h=o.length;while(h--)o[h]="#"+k+" "+sa(o[h]);r=o.join(","),s=$.test(a)&&qa(b.parentNode)||b}if(r)try{return G.apply(d,s.querySelectorAll(r)),d}catch(x){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(P,"$1"),b,d,e)}function ha(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ia(a){return a[u]=!0,a}function ja(a){var b=n.createElement("fieldset");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ka(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function la(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&a.sourceIndex-b.sourceIndex;if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function na(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function oa(a){return function(b){return"form"in b?b.parentNode&&b.disabled===!1?"label"in b?"label"in b.parentNode?b.parentNode.disabled===a:b.disabled===a:b.isDisabled===a||b.isDisabled!==!a&&ea(b)===a:b.disabled===a:"label"in b&&b.disabled===a}}function pa(a){return ia(function(b){return b=+b,ia(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function qa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=ga.support={},f=ga.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return!!b&&"HTML"!==b.nodeName},m=ga.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),v!==n&&(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ja(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ja(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Y.test(n.getElementsByClassName),c.getById=ja(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.filter.ID=function(a){var b=a.replace(_,aa);return function(a){return a.getAttribute("id")===b}},d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}}):(d.filter.ID=function(a){var b=a.replace(_,aa);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}},d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c,d,e,f=b.getElementById(a);if(f){if(c=f.getAttributeNode("id"),c&&c.value===a)return[f];e=b.getElementsByName(a),d=0;while(f=e[d++])if(c=f.getAttributeNode("id"),c&&c.value===a)return[f]}return[]}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){if("undefined"!=typeof b.getElementsByClassName&&p)return b.getElementsByClassName(a)},r=[],q=[],(c.qsa=Y.test(n.querySelectorAll))&&(ja(function(a){o.appendChild(a).innerHTML="<a id='"+u+"'></a><select id='"+u+"-\r\\' msallowcapture=''><option selected=''></option></select>",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+K+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+K+"*(?:value|"+J+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ja(function(a){a.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+K+"*[*^$|!~]?="),2!==a.querySelectorAll(":enabled").length&&q.push(":enabled",":disabled"),o.appendChild(a).disabled=!0,2!==a.querySelectorAll(":disabled").length&&q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Y.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ja(function(a){c.disconnectedMatch=s.call(a,"*"),s.call(a,"[s!='']:x"),r.push("!=",N)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Y.test(o.compareDocumentPosition),t=b||Y.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?I(k,a)-I(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?I(k,a)-I(k,b):0;if(e===f)return la(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?la(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},ga.matches=function(a,b){return ga(a,null,null,b)},ga.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(S,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return ga(b,n,null,[a]).length>0},ga.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},ga.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&C.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},ga.escape=function(a){return(a+"").replace(ba,ca)},ga.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},ga.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=ga.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=ga.selectors={cacheLength:50,createPseudo:ia,match:V,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(_,aa),a[3]=(a[3]||a[4]||a[5]||"").replace(_,aa),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||ga.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&ga.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return V.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&T.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(_,aa).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+K+")"+a+"("+K+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=ga.attr(d,a);return null==e?"!="===b:!b||(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(O," ")+" ").indexOf(c)>-1:"|="===b&&(e===c||e.slice(0,c.length+1)===c+"-"))}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),t===!1)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return t-=e,t===d||t%d===0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||ga.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ia(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=I(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ia(function(a){var b=[],c=[],d=h(a.replace(P,"$1"));return d[u]?ia(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ia(function(a){return function(b){return ga(a,b).length>0}}),contains:ia(function(a){return a=a.replace(_,aa),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ia(function(a){return U.test(a||"")||ga.error("unsupported lang: "+a),a=a.replace(_,aa).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:oa(!1),disabled:oa(!0),checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return X.test(a.nodeName)},input:function(a){return W.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:pa(function(){return[0]}),last:pa(function(a,b){return[b-1]}),eq:pa(function(a,b,c){return[c<0?c+b:c]}),even:pa(function(a,b){for(var c=0;c<b;c+=2)a.push(c);return a}),odd:pa(function(a,b){for(var c=1;c<b;c+=2)a.push(c);return a}),lt:pa(function(a,b,c){for(var d=c<0?c+b:c;--d>=0;)a.push(d);return a}),gt:pa(function(a,b,c){for(var d=c<0?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=ma(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=na(b);function ra(){}ra.prototype=d.filters=d.pseudos,d.setFilters=new ra,g=ga.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){c&&!(e=Q.exec(h))||(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=R.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(P," ")}),h=h.slice(c.length));for(g in d.filter)!(e=V[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?ga.error(a):z(a,i).slice(0)};function sa(a){for(var b=0,c=a.length,d="";b<c;b++)d+=a[b].value;return d}function ta(a,b,c){var d=b.dir,e=b.next,f=e||d,g=c&&"parentNode"===f,h=x++;return b.first?function(b,c,e){while(b=b[d])if(1===b.nodeType||g)return a(b,c,e);return!1}:function(b,c,i){var j,k,l,m=[w,h];if(i){while(b=b[d])if((1===b.nodeType||g)&&a(b,c,i))return!0}else while(b=b[d])if(1===b.nodeType||g)if(l=b[u]||(b[u]={}),k=l[b.uniqueID]||(l[b.uniqueID]={}),e&&e===b.nodeName.toLowerCase())b=b[d]||b;else{if((j=k[f])&&j[0]===w&&j[1]===h)return m[2]=j[2];if(k[f]=m,m[2]=a(b,c,i))return!0}return!1}}function ua(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function va(a,b,c){for(var d=0,e=b.length;d<e;d++)ga(a,b[d],c);return c}function wa(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;h<i;h++)(f=a[h])&&(c&&!c(f,d,e)||(g.push(f),j&&b.push(h)));return g}function xa(a,b,c,d,e,f){return d&&!d[u]&&(d=xa(d)),e&&!e[u]&&(e=xa(e,f)),ia(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||va(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:wa(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=wa(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?I(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=wa(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):G.apply(g,r)})}function ya(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=ta(function(a){return a===b},h,!0),l=ta(function(a){return I(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];i<f;i++)if(c=d.relative[a[i].type])m=[ta(ua(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;e<f;e++)if(d.relative[a[e].type])break;return xa(i>1&&ua(m),i>1&&sa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(P,"$1"),c,i<e&&ya(a.slice(i,e)),e<f&&ya(a=a.slice(e)),e<f&&sa(a))}m.push(c)}return ua(m)}function za(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=E.call(i));u=wa(u)}G.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&ga.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ia(f):f}return h=ga.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=ya(b[c]),f[u]?d.push(f):e.push(f);f=A(a,za(e,d)),f.selector=a}return f},i=ga.select=function(a,b,c,e){var f,i,j,k,l,m="function"==typeof a&&a,n=!e&&g(a=m.selector||a);if(c=c||[],1===n.length){if(i=n[0]=n[0].slice(0),i.length>
vendor: 64,249 bytes, lines 6-8
62&&"ID"===(j=i[0]).type&&9===b.nodeType&&p&&d.relative[i[1].type]){if(b=(d.find.ID(j.matches[0].replace(_,aa),b)||[])[0],!b)return c;m&&(b=b.parentNode),a=a.slice(i.shift().value.length)}f=V.needsContext.test(a)?0:i.length;while(f--){if(j=i[f],d.relative[k=j.type])break;if((l=d.find[k])&&(e=l(j.matches[0].replace(_,aa),$.test(i[0].type)&&qa(b.parentNode)||b))){if(i.splice(f,1),a=e.length&&sa(i),!a)return G.apply(c,e),c;break}}}return(m||h(a,n))(e,b,!p,c,!b||$.test(a)&&qa(b.parentNode)||b),c},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ja(function(a){return 1&a.compareDocumentPosition(n.createElement("fieldset"))}),ja(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||ka("type|href|height|width",function(a,b,c){if(!c)return a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ja(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ka("value",function(a,b,c){if(!c&&"input"===a.nodeName.toLowerCase())return a.defaultValue}),ja(function(a){return null==a.getAttribute("disabled")})||ka(J,function(a,b,c){var d;if(!c)return a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),ga}(a);r.find=x,r.expr=x.selectors,r.expr[":"]=r.expr.pseudos,r.uniqueSort=r.unique=x.uniqueSort,r.text=x.getText,r.isXMLDoc=x.isXML,r.contains=x.contains,r.escapeSelector=x.escape;var y=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&r(a).is(c))break;d.push(a)}return d},z=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},A=r.expr.match.needsContext;function B(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()}var C=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i,D=/^.[^:#\[\.,]*$/;function E(a,b,c){return r.isFunction(b)?r.grep(a,function(a,d){return!!b.call(a,d,a)!==c}):b.nodeType?r.grep(a,function(a){return a===b!==c}):"string"!=typeof b?r.grep(a,function(a){return i.call(b,a)>-1!==c}):D.test(b)?r.filter(b,a,c):(b=r.filter(b,a),r.grep(a,function(a){return i.call(b,a)>-1!==c&&1===a.nodeType}))}r.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?r.find.matchesSelector(d,a)?[d]:[]:r.find.matches(a,r.grep(b,function(a){return 1===a.nodeType}))},r.fn.extend({find:function(a){var b,c,d=this.length,e=this;if("string"!=typeof a)return this.pushStack(r(a).filter(function(){for(b=0;b<d;b++)if(r.contains(e[b],this))return!0}));for(c=this.pushStack([]),b=0;b<d;b++)r.find(a,e[b],c);return d>1?r.uniqueSort(c):c},filter:function(a){return this.pushStack(E(this,a||[],!1))},not:function(a){return this.pushStack(E(this,a||[],!0))},is:function(a){return!!E(this,"string"==typeof a&&A.test(a)?r(a):a||[],!1).length}});var F,G=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,H=r.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||F,"string"==typeof a){if(e="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:G.exec(a),!e||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof r?b[0]:b,r.merge(this,r.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),C.test(e[1])&&r.isPlainObject(b))for(e in b)r.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}return f=d.getElementById(e[2]),f&&(this[0]=f,this.length=1),this}return a.nodeType?(this[0]=a,this.length=1,this):r.isFunction(a)?void 0!==c.ready?c.ready(a):a(r):r.makeArray(a,this)};H.prototype=r.fn,F=r(d);var I=/^(?:parents|prev(?:Until|All))/,J={children:!0,contents:!0,next:!0,prev:!0};r.fn.extend({has:function(a){var b=r(a,this),c=b.length;return this.filter(function(){for(var a=0;a<c;a++)if(r.contains(this,b[a]))return!0})},closest:function(a,b){var c,d=0,e=this.length,f=[],g="string"!=typeof a&&r(a);if(!A.test(a))for(;d<e;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&r.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?r.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?i.call(r(a),this[0]):i.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(r.uniqueSort(r.merge(this.get(),r(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function K(a,b){while((a=a[b])&&1!==a.nodeType);return a}r.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return y(a,"parentNode")},parentsUntil:function(a,b,c){return y(a,"parentNode",c)},next:function(a){return K(a,"nextSibling")},prev:function(a){return K(a,"previousSibling")},nextAll:function(a){return y(a,"nextSibling")},prevAll:function(a){return y(a,"previousSibling")},nextUntil:function(a,b,c){return y(a,"nextSibling",c)},prevUntil:function(a,b,c){return y(a,"previousSibling",c)},siblings:function(a){return z((a.parentNode||{}).firstChild,a)},children:function(a){return z(a.firstChild)},contents:function(a){return B(a,"iframe")?a.contentDocument:(B(a,"template")&&(a=a.content||a),r.merge([],a.childNodes))}},function(a,b){r.fn[a]=function(c,d){var e=r.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=r.filter(d,e)),this.length>1&&(J[a]||r.uniqueSort(e),I.test(a)&&e.reverse()),this.pushStack(e)}});var L=/[^\x20\t\r\n\f]+/g;function M(a){var b={};return r.each(a.match(L)||[],function(a,c){b[c]=!0}),b}r.Callbacks=function(a){a="string"==typeof a?M(a):r.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=e||a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h<f.length)f[h].apply(c[0],c[1])===!1&&a.stopOnFalse&&(h=f.length,c=!1)}a.memory||(c=!1),b=!1,e&&(f=c?[]:"")},j={add:function(){return f&&(c&&!b&&(h=f.length-1,g.push(c)),function d(b){r.each(b,function(b,c){r.isFunction(c)?a.unique&&j.has(c)||f.push(c):c&&c.length&&"string"!==r.type(c)&&d(c)})}(arguments),c&&!b&&i()),this},remove:function(){return r.each(arguments,function(a,b){var c;while((c=r.inArray(b,f,c))>-1)f.splice(c,1),c<=h&&h--}),this},has:function(a){return a?r.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=g=[],c||b||(f=c=""),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j};function N(a){return a}function O(a){throw a}function P(a,b,c,d){var e;try{a&&r.isFunction(e=a.promise)?e.call(a).done(b).fail(c):a&&r.isFunction(e=a.then)?e.call(a,b,c):b.apply(void 0,[a].slice(d))}catch(a){c.apply(void 0,[a])}}r.extend({Deferred:function(b){var c=[["notify","progress",r.Callbacks("memory"),r.Callbacks("memory"),2],["resolve","done",r.Callbacks("once memory"),r.Callbacks("once memory"),0,"resolved"],["reject","fail",r.Callbacks("once memory"),r.Callbacks("once memory"),1,"rejected"]],d="pending",e={state:function(){return d},always:function(){return f.done(arguments).fail(arguments),this},"catch":function(a){return e.then(null,a)},pipe:function(){var a=arguments;return r.Deferred(function(b){r.each(c,function(c,d){var e=r.isFunction(a[d[4]])&&a[d[4]];f[d[1]](function(){var a=e&&e.apply(this,arguments);a&&r.isFunction(a.promise)?a.promise().progress(b.notify).done(b.resolve).fail(b.reject):b[d[0]+"With"](this,e?[a]:arguments)})}),a=null}).promise()},then:function(b,d,e){var f=0;function g(b,c,d,e){return function(){var h=this,i=arguments,j=function(){var a,j;if(!(b<f)){if(a=d.apply(h,i),a===c.promise())throw new TypeError("Thenable self-resolution");j=a&&("object"==typeof a||"function"==typeof a)&&a.then,r.isFunction(j)?e?j.call(a,g(f,c,N,e),g(f,c,O,e)):(f++,j.call(a,g(f,c,N,e),g(f,c,O,e),g(f,c,N,c.notifyWith))):(d!==N&&(h=void 0,i=[a]),(e||c.resolveWith)(h,i))}},k=e?j:function(){try{j()}catch(a){r.Deferred.exceptionHook&&r.Deferred.exceptionHook(a,k.stackTrace),b+1>=f&&(d!==O&&(h=void 0,i=[a]),c.rejectWith(h,i))}};b?k():(r.Deferred.getStackHook&&(k.stackTrace=r.Deferred.getStackHook()),a.setTimeout(k))}}return r.Deferred(function(a){c[0][3].add(g(0,a,r.isFunction(e)?e:N,a.notifyWith)),c[1][3].add(g(0,a,r.isFunction(b)?b:N)),c[2][3].add(g(0,a,r.isFunction(d)?d:O))}).promise()},promise:function(a){return null!=a?r.extend(a,e):e}},f={};return r.each(c,function(a,b){var g=b[2],h=b[5];e[b[1]]=g.add,h&&g.add(function(){d=h},c[3-a][2].disable,c[0][2].lock),g.add(b[3].fire),f[b[0]]=function(){return f[b[0]+"With"](this===f?void 0:this,arguments),this},f[b[0]+"With"]=g.fireWith}),e.promise(f),b&&b.call(f,f),f},when:function(a){var b=arguments.length,c=b,d=Array(c),e=f.call(arguments),g=r.Deferred(),h=function(a){return function(c){d[a]=this,e[a]=arguments.length>1?f.call(arguments):c,--b||g.resolveWith(d,e)}};if(b<=1&&(P(a,g.done(h(c)).resolve,g.reject,!b),"pending"===g.state()||r.isFunction(e[c]&&e[c].then)))return g.then();while(c--)P(e[c],h(c),g.reject);return g.promise()}});var Q=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;r.Deferred.exceptionHook=function(b,c){a.console&&a.console.warn&&b&&Q.test(b.name)&&a.console.warn("jQuery.Deferred exception: "+b.message,b.stack,c)},r.readyException=function(b){a.setTimeout(function(){throw b})};var R=r.Deferred();r.fn.ready=function(a){return R.then(a)["catch"](function(a){r.readyException(a)}),this},r.extend({isReady:!1,readyWait:1,ready:function(a){(a===!0?--r.readyWait:r.isReady)||(r.isReady=!0,a!==!0&&--r.readyWait>0||R.resolveWith(d,[r]))}}),r.ready.then=R.then;function S(){d.removeEventListener("DOMContentLoaded",S),
7a.removeEventListener("load",S),r.ready()}"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll?a.setTimeout(r.ready):(d.addEventListener("DOMContentLoaded",S),a.addEventListener("load",S));var T=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===r.type(c)){e=!0;for(h in c)T(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,r.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(r(a),c)})),b))for(;h<i;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},U=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function V(){this.expando=r.expando+V.uid++}V.uid=1,V.prototype={cache:function(a){var b=a[this.expando];return b||(b={},U(a)&&(a.nodeType?a[this.expando]=b:Object.defineProperty(a,this.expando,{value:b,configurable:!0}))),b},set:function(a,b,c){var d,e=this.cache(a);if("string"==typeof b)e[r.camelCase(b)]=c;else for(d in b)e[r.camelCase(d)]=b[d];return e},get:function(a,b){return void 0===b?this.cache(a):a[this.expando]&&a[this.expando][r.camelCase(b)]},access:function(a,b,c){return void 0===b||b&&"string"==typeof b&&void 0===c?this.get(a,b):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d=a[this.expando];if(void 0!==d){if(void 0!==b){Array.isArray(b)?b=b.map(r.camelCase):(b=r.camelCase(b),b=b in d?[b]:b.match(L)||[]),c=b.length;while(c--)delete d[b[c]]}(void 0===b||r.isEmptyObject(d))&&(a.nodeType?a[this.expando]=void 0:delete a[this.expando])}},hasData:function(a){var b=a[this.expando];return void 0!==b&&!r.isEmptyObject(b)}};var W=new V,X=new V,Y=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Z=/[A-Z]/g;function $(a){return"true"===a||"false"!==a&&("null"===a?null:a===+a+""?+a:Y.test(a)?JSON.parse(a):a)}function _(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(Z,"-$&").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c=$(c)}catch(e){}X.set(a,b,c)}else c=void 0;return c}r.extend({hasData:function(a){return X.hasData(a)||W.hasData(a)},data:function(a,b,c){return X.access(a,b,c)},removeData:function(a,b){X.remove(a,b)},_data:function(a,b,c){return W.access(a,b,c)},_removeData:function(a,b){W.remove(a,b)}}),r.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=X.get(f),1===f.nodeType&&!W.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=r.camelCase(d.slice(5)),_(f,d,e[d])));W.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){X.set(this,a)}):T(this,function(b){var c;if(f&&void 0===b){if(c=X.get(f,a),void 0!==c)return c;if(c=_(f,a),void 0!==c)return c}else this.each(function(){X.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){X.remove(this,a)})}}),r.extend({queue:function(a,b,c){var d;if(a)return b=(b||"fx")+"queue",d=W.get(a,b),c&&(!d||Array.isArray(c)?d=W.access(a,b,r.makeArray(c)):d.push(c)),d||[]},dequeue:function(a,b){b=b||"fx";var c=r.queue(a,b),d=c.length,e=c.shift(),f=r._queueHooks(a,b),g=function(){r.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return W.get(a,c)||W.access(a,c,{empty:r.Callbacks("once memory").add(function(){W.remove(a,[b+"queue",c])})})}}),r.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?r.queue(this[0],a):void 0===b?this:this.each(function(){var c=r.queue(this,a,b);r._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&r.dequeue(this,a)})},dequeue:function(a){return this.each(function(){r.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=r.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=W.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var aa=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,ba=new RegExp("^(?:([+-])=|)("+aa+")([a-z%]*)$","i"),ca=["Top","Right","Bottom","Left"],da=function(a,b){return a=b||a,"none"===a.style.display||""===a.style.display&&r.contains(a.ownerDocument,a)&&"none"===r.css(a,"display")},ea=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e};function fa(a,b,c,d){var e,f=1,g=20,h=d?function(){return d.cur()}:function(){return r.css(a,b,"")},i=h(),j=c&&c[3]||(r.cssNumber[b]?"":"px"),k=(r.cssNumber[b]||"px"!==j&&+i)&&ba.exec(r.css(a,b));if(k&&k[3]!==j){j=j||k[3],c=c||[],k=+i||1;do f=f||".5",k/=f,r.style(a,b,k+j);while(f!==(f=h()/i)&&1!==f&&--g)}return c&&(k=+k||+i||0,e=c[1]?k+(c[1]+1)*c[2]:+c[2],d&&(d.unit=j,d.start=k,d.end=e)),e}var ga={};function ha(a){var b,c=a.ownerDocument,d=a.nodeName,e=ga[d];return e?e:(b=c.body.appendChild(c.createElement(d)),e=r.css(b,"display"),b.parentNode.removeChild(b),"none"===e&&(e="block"),ga[d]=e,e)}function ia(a,b){for(var c,d,e=[],f=0,g=a.length;f<g;f++)d=a[f],d.style&&(c=d.style.display,b?("none"===c&&(e[f]=W.get(d,"display")||null,e[f]||(d.style.display="")),""===d.style.display&&da(d)&&(e[f]=ha(d))):"none"!==c&&(e[f]="none",W.set(d,"display",c)));for(f=0;f<g;f++)null!=e[f]&&(a[f].style.display=e[f]);return a}r.fn.extend({show:function(){return ia(this,!0)},hide:function(){return ia(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){da(this)?r(this).show():r(this).hide()})}});var ja=/^(?:checkbox|radio)$/i,ka=/<([a-z][^\/\0>\x20\t\r\n\f]+)/i,la=/^$|\/(?:java|ecma)script/i,ma={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};ma.optgroup=ma.option,ma.tbody=ma.tfoot=ma.colgroup=ma.caption=ma.thead,ma.th=ma.td;function na(a,b){var c;return c="undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName(b||"*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll(b||"*"):[],void 0===b||b&&B(a,b)?r.merge([a],c):c}function oa(a,b){for(var c=0,d=a.length;c<d;c++)W.set(a[c],"globalEval",!b||W.get(b[c],"globalEval"))}var pa=/<|&#?\w+;/;function qa(a,b,c,d,e){for(var f,g,h,i,j,k,l=b.createDocumentFragment(),m=[],n=0,o=a.length;n<o;n++)if(f=a[n],f||0===f)if("object"===r.type(f))r.merge(m,f.nodeType?[f]:f);else if(pa.test(f)){g=g||l.appendChild(b.createElement("div")),h=(ka.exec(f)||["",""])[1].toLowerCase(),i=ma[h]||ma._default,g.innerHTML=i[1]+r.htmlPrefilter(f)+i[2],k=i[0];while(k--)g=g.lastChild;r.merge(m,g.childNodes),g=l.firstChild,g.textContent=""}else m.push(b.createTextNode(f));l.textContent="",n=0;while(f=m[n++])if(d&&r.inArray(f,d)>-1)e&&e.push(f);else if(j=r.contains(f.ownerDocument,f),g=na(l.appendChild(f),"script"),j&&oa(g),c){k=0;while(f=g[k++])la.test(f.type||"")&&c.push(f)}return l}!function(){var a=d.createDocumentFragment(),b=a.appendChild(d.createElement("div")),c=d.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),o.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",o.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var ra=d.documentElement,sa=/^key/,ta=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,ua=/^([^.]*)(?:\.(.+)|)/;function va(){return!0}function wa(){return!1}function xa(){try{return d.activeElement}catch(a){}}function ya(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)ya(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),e===!1)e=wa;else if(!e)return a;return 1===f&&(g=e,e=function(a){return r().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=r.guid++)),a.each(function(){r.event.add(this,b,e,d,c)})}r.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,n,o,p,q=W.get(a);if(q){c.handler&&(f=c,c=f.handler,e=f.selector),e&&r.find.matchesSelector(ra,e),c.guid||(c.guid=r.guid++),(i=q.events)||(i=q.events={}),(g=q.handle)||(g=q.handle=function(b){return"undefined"!=typeof r&&r.event.triggered!==b.type?r.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(L)||[""],j=b.length;while(j--)h=ua.exec(b[j])||[],n=p=h[1],o=(h[2]||"").split(".").sort(),n&&(l=r.event.special[n]||{},n=(e?l.delegateType:l.bindType)||n,l=r.event.special[n]||{},k=r.extend({type:n,origType:p,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&r.expr.match.needsContext.test(e),namespace:o.join(".")},f),(m=i[n])||(m=i[n]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,o,g)!==!1||a.addEventListener&&a.addEventListener(n,g)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),r.event.global[n]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,n,o,p,q=W.hasData(a)&&W.get(a);if(q&&(i=q.events)){b=(b||"").match(L)||[""],j=b.length;while(j--)if(h=ua.exec(b[j])||[],n=p=h[1],o=(h[2]||"").split(".").sort(),n){l=r.event.special[n]||{},n=(d?l.delegateType:l.bindType)||n,m=i[n]||[],h=h[2]&&new RegExp("(^|\\.)"+o.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&p!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,o,q.handle)!==!1||r.removeEvent(a,n,q.handle),delete i[n])}else for(n in i)r.event.remove(a,n+b[j],c,d,!0);r.isEmptyObject(i)&&W.remove(a,"handle events")}},dispatch:function(a){var b=r.event.fix(a),c,d,e,f,g,h,i=new Array(arguments.length),j=(W.get(this,"events")||{})[b.type]||[],k=r.event.special[b.type]||{};for(i[0]=b,c=1;c<arguments.length;c++)i[c]=arguments[c];if(b.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,b)!==!1){h=r.event.handlers.call(this,b,j),c=0;while((f=h[c++])&&!b.isPropagationStopped()){b.currentTarget=f.elem,d=0;while((g=f.handlers[d++])&&!b.isImmediatePropagationStopped())b.rnamespace&&!b.rnamespace.test(g.namespace)||(b.handleObj=g,b.data=g.data,e=((r.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==e&&(b.result=e)===!1&&(b.preventDefault(),b.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,b),b.result}},handlers:function(a,b){var c,d,e,f,g,h=[],i=b.delegateCount,j=a.target;if(i&&j.nodeType&&!("click"===a.type&&a.button>=1))for(;j!==this;j=j.parentNode||this)if(1===j.nodeType&&("click"!==a.type||j.disabled!==!0)){for(f=[],g={},c=0;c<i;c++)d=b[c],e=d.selector+" ",void 0===g[e]&&(g[e]=d.needsContext?r(e,this).index(j)>-1:r.find(e,this,null,[j]).length),g[e]&&f.push(d);f.length&&h.push({elem:j,handlers:f})}return j=this,i<b.length&&h.push({elem:j,handlers:b.slice(i)}),h},addProp:function(a,b){Object.defineProperty(r.Event.prototype,a,{enumerable:!0,configurable:!0,get:r.isFunction(b)?function(){if(this.originalEvent)return b(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[a]},set:function(b){Object.defineProperty(this,a,{enumerable:!0,configurable:!0,writable:!0,value:b})}})},fix:function(a){return a[r.expando]?a:new r.Event(a)},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==xa()&&this.focus)return this.focus(),!1},delegateType:"focusin"},blur:{trigger:function(){if(this===xa()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if("checkbox"===this.type&&this.click&&B(this,"input"))return this.click(),!1},_default:function(a){return B(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}}},r.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c)},r.Event=function(a,b){return this instanceof r.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?va:wa,this.target=a.target&&3===a.target.nodeType?a.target.parentNode:a.target,this.currentTarget=a.currentTarget,this.relatedTarget=a.relatedTarget):this.type=a,b&&r.extend(this,b),this.timeStamp=a&&a.timeStamp||r.now(),void(this[r.expando]=!0)):new r.Event(a,b)},r.Event.prototype={constructor:r.Event,isDefaultPrevented:wa,isPropagationStopped:wa,isImmediatePropagationStopped:wa,isSimulated:!1,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=va,a&&!this.isSimulated&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=va,a&&!this.isSimulated&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=va,a&&!this.isSimulated&&a.stopImmediatePropagation(),this.stopPropagation()}},r.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(a){var b=a.button;return null==a.which&&sa.test(a.type)?null!=a.charCode?a.charCode:a.keyCode:!a.which&&void 0!==b&&ta.test(a.type)?1&b?1:2&b?3:4&b?2:0:a.which}},r.event.addProp),r.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){r.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return e&&(e===d||r.contains(d,e))||(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),r.fn.extend({on:function(a,b,c,d){return ya(this,a,b,c,d)},one:function(a,b,c,d){return ya(this,a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,r(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return b!==!1&&"function"!=typeof b||(c=b,b=void 0),c===!1&&(c=wa),this.each(function(){r.event.remove(this,a,c,b)})}});var za=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,Aa=/<script|<style|<link/i,Ba=/checked\s*(?:[^=]|=\s*.checked.)/i,Ca=/^true\/(.*)/,Da=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function Ea(a,b){return B(a,"table")&&B(11!==b.nodeType?b:b.firstChild,"tr")?r(">tbody",a)[0]||a:a}function Fa(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function Ga(a){var b=Ca.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Ha(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(W.hasData(a)&&(f=W.access(a),g=W.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;c<d;c++)r.event.add(b,e,j[e][c])}X.hasData(a)&&(h=X.access(a),i=r.extend({},h),X.set(b,i))}}function Ia(a,b){var c=b.nodeName.toLowerCase();"input"===c&&ja.test(a.type)?b.checked=a.checked:"input"!==c&&"textarea"!==c||(b.defaultValue=a.defaultValue)}function Ja(a,b,c,d){b=g.apply([],b);var e,f,h,i,j,k,l=0,m=a.length,n=m-1,q=b[0],s=r.isFunction(q);if(s||m>1&&"string"==typeof q&&!o.checkClone&&Ba.test(q))return a.each(function(e){var f=a.eq(e);s&&(b[0]=q.call(this,e,f.html())),Ja(f,b,c,d)});if(m&&(e=qa(b,a[0].ownerDocument,!1,a,d),f=e.firstChild,1===e.childNodes.length&&(e=f),f||d)){for(h=r.map(na(e,"script"),Fa),i=h.length;l<m;l++)j=e,l!==n&&(j=r.clone(j,!0,!0),i&&r.merge(h,na(j,"script"))),c.call(a[l],j,l);if(i)for(k=h[h.length-1].ownerDocument,r.map(h,Ga),l=0;l<i;l++)j=h[l],la.test(j.type||"")&&!W.access(j,"globalEval")&&r.contains(k,j)&&(j.src?r._evalUrl&&r._evalUrl(j.src):p(j.textContent.replace(Da,""),k))}return a}function Ka(a,b,c){for(var d,e=b?r.filter(b,a):a,f=0;null!=(d=e[f]);f++)c||1!==d.nodeType||r.cleanData(na(d)),d.parentNode&&(c&&r.contains(d.ownerDocument,d)&&oa(na(d,"script")),d.parentNode.removeChild(d));return a}r.extend({htmlPrefilter:function(a){return a.replace(za,"<$1></$2>")},clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=r.contains(a.ownerDocument,a);if(!(o.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||r.isXMLDoc(a)))for(g=na(h),f=na(a),d=0,e=f.length;d<e;d++)Ia(f[d],g[d]);if(b)if(c)for(f=f||na(a),g=g||na(h),d=0,e=f.length;d<e;d++)Ha(f[d],g[d]);else Ha(a,h);return g=na(h,"script"),g.length>0&&oa(g,!i&&na(a,"script")),h},cleanData:function(a){for(var b,c,d,e=r.event.special,f=0;void 0!==(c=a[f]);f++)if(U(c)){if(b=c[W.expando]){if(b.events)for(d in b.events)e[d]?r.event.remove(c,d):r.removeEvent(c,d,b.handle);c[W.expando]=void 0}c[X.expando]&&(c[X.expando]=void 0)}}}),r.fn.extend({detach:function(a){return Ka(this,a,!0)},remove:function(a){return Ka(this,a)},text:function(a){return T(this,function(a){return void 0===a?r.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=a)})},null,a,arguments.length)},append:function(){return Ja(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ea(this,a);b.appendChild(a)}})},prepend:function(){return Ja(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ea(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return Ja(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return Ja(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(r.cleanData(na(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null!=a&&a,b=null==b?a:b,this.map(function(){return r.clone(this,a,b)})},html:function(a){return T(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!Aa.test(a)&&!ma[(ka.exec(a)||["",""])[1].toLowerCase()]){a=r.htmlPrefilter(a);try{for(;c<d;c++)b=this[c]||{},1===b.nodeType&&(r.cleanData(na(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=[];return Ja(this,arguments,function(b){var c=this.parentNode;r.inArray(this,a)<0&&(r.cleanData(na(this)),c&&c.replaceChild(b,this))},a)}}),r.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){r.fn[a]=function(a){for(var c,d=[],e=r(a),f=e.length-1,g=0;g<=f;g++)c=g===f?this:this.clone(!0),r(e[g])[b](c),h.apply(d,c.get());return this.pushStack(d)}});var La=/^margin/,Ma=new RegExp("^("+aa+")(?!px)[a-z%]+$","i"),Na=function(b){var c=b.ownerDocument.defaultView;return c&&c.opener||(c=a),c.getComputedStyle(b)};!function(){function b(){if(i){i.style.cssText="box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",i.innerHTML="",ra.appendChild(h);var b=a.getComputedStyle(i);c="1%"!==b.top,g="2px"===b.marginLeft,e="4px"===b.width,i.style.marginRight="50%",f="4px"===b.marginRight,ra.removeChild(h),i=null}}var c,e,f,g,h=d.createElement("div"),i=d.createElement("div");i.style&&(i.style.backgroundClip="content-box",i.cloneNode(!0).style.backgroundClip="",o.clearCloneStyle="content-box"===i.style.backgroundClip,h.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",h.appendChild(i),r.extend(o,{pixelPosition:function(){return b(),c},boxSizingReliable:function(){return b(),e},pixelMarginRight:function(){return b(),f},reliableMarginLeft:function(){return b(),g}}))}();function Oa(a,b,c){var d,e,f,g,h=a.style;return c=c||Na(a),c&&(g=c.getPropertyValue(b)||c[b],""!==g||r.contains(a.ownerDocument,a)||(g=r.style(a,b)),!o.pixelMarginRight()&&Ma.test(g)&&La.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f)),void 0!==g?g+"":g}function Pa(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}var Qa=/^(none|table(?!-c[ea]).+)/,Ra=/^--/,Sa={position:"absolute",visibility:"hidden",display:"block"},Ta={letterSpacing:"0",fontWeight:"400"},Ua=["Webkit","Moz","ms"],Va=d.createElement("div").style;function Wa(a){if(a in Va)return a;var b=a[0].toUpperCase()+a.slice(1),c=Ua.length;while(c--)if(a=Ua[c]+b,a in Va)return a}function Xa(a){var b=r.cssProps[a];return b||(b=r.cssProps[a]=Wa(a)||a),b}function Ya(a,b,c){var d=ba.exec(b);return d?Math.max(0,d[2]-(c||0))+(d[3]||"px"):b}function Za(a,b,c,d,e){var f,g=0;for(f=c===(d?"border":"content")?4:"width"===b?1:0;f<4;f+=2)"margin"===c&&(g+=r.css(a,c+ca[f],!0,e)),d?("content"===c&&(g-=r.css(a,"padding"+ca[f],!0,e)),"margin"!==c&&(g-=r.css(a,"border"+ca[f]+"Width",!0,e))):(g+=r.css(a,"padding"+ca[f],!0,e),"padding"!==c&&(g+=r.css(a,"border"+ca[f]+"Width",!0,e)));return g}function $a(a,b,c){var d,e=Na(a),f=Oa(a,b,e),g="border-box"===r.css(a,"boxSizing",!1,e);return Ma.test(f)?f:(d=g&&(o.boxSizingReliable()||f===a.style[b]),"auto"===f&&(f=a["offset"+b[0].toUpperCase()+b.slice(1)]),f=parseFloat(f)||0,f+Za(a,b,c||(g?"border":"content"),d,e)+"px")}r.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=Oa(a,"opacity");return""===c?"1":c}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=r.camelCase(b),i=Ra.test(b),j=a.style;return i||(b=Xa(h)),g=r.cssHooks[b]||r.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:j[b]:(f=typeof c,"string"===f&&(e=ba.exec(c))&&e[1]&&(c=fa(a,b,e),f="number"),null!=c&&c===c&&("number"===f&&(c+=e&&e[3]||(r.cssNumber[h]?"":"px")),o.clearCloneStyle||""!==c||0!==b.indexOf("background")||(j[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i?j.setProperty(b,c):j[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=r.camelCase(b),i=Ra.test(b);return i||(b=Xa(h)),g=r.cssHooks[b]||r.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=Oa(a,b,d)),"normal"===e&&b in Ta&&(e=Ta[b]),""===c||c?(f=parseFloat(e),c===!0||isFinite(f)?f||0:e):e}}),r.each(["height","width"],function(a,b){r.cssHooks[b]={get:function(a,c,d){if(c)return!Qa.test(r.css(a,"display"))||a.getClientRects().length&&a.getBoundingClientRect().width?$a(a,b,d):ea(a,Sa,function(){return $a(a,b,d)})},set:function(a,c,d){var e,f=d&&Na(a),g=d&&Za(a,b,d,"border-box"===r.css(a,"boxSizing",!1,f),f);return g&&(e=ba.exec(c))&&"px"!==(e[3]||"px")&&(a.style[b]=c,c=r.css(a,b)),Ya(a,c,g)}}}),r.cssHooks.marginLeft=Pa(o.reliableMarginLeft,function(a,b){if(b)return(parseFloat(Oa(a,"marginLeft"))||a.getBoundingClientRect().left-ea(a,{marginLeft:0},function(){return a.getBoundingClientRect().left}))+"px"}),r.each({margin:"",padding:"",border:"Width"},function(a,b){r.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];d<4;d++)e[a+ca[d]+b]=f[d]||f[d-2]||f[0];return e}},La.test(a)||(r.cssHooks[a+b].set=Ya)}),r.fn.extend({css:function(a,b){return T(this,function(a,b,c){var d,e,f={},g=0;if(Array.isArray(b)){for(d=Na(a),e=b.length;g<e;g++)f[b[g]]=r.css(a,b[g],!1,d);return f}return void 0!==c?r.style(a,b,c):r.css(a,b)},a,b,arguments.length>1)}});function _a(a,b,c,d,e){return new _a.prototype.init(a,b,c,d,e)}r.Tween=_a,_a.prototype={constructor:_a,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||r.easing._default,this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(r.cssNumber[c]?"":"px")},cur:function(){var a=_a.propHooks[this.prop];return a&&a.get?a.get(this):_a.propHooks._default.get(this)},run:function(a){var b,c=_a.propHooks[this.prop];return this.options.duration?this.pos=b=r.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):_a.propHooks._default.set(this),this}},_a.prototype.init.prototype=_a.prototype,_a.propHooks={_default:{get:function(a){var b;return 1!==a.elem.nodeType||null!=a.elem[a.prop]&&null==a.elem.style[a.prop]?a.elem[a.prop]:(b=r.css(a.elem,a.prop,""),b&&"auto"!==b?b:0)},set:function(a){r.fx.step[a.prop]?r.fx.step[a.prop](a):1!==a.elem.nodeType||null==a.elem.style[r.cssProps[a.prop]]&&!r.cssHooks[a.prop]?a.elem[a.prop]=a.now:r.style(a.elem,a.prop,a.now+a.unit)}}},_a.propHooks.scrollTop=_a.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},r.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2},_default:"swing"},r.fx=_a.prototype.init,r.fx.step={};var ab,bb,cb=/^(?:toggle|show|hide)$/,db=/queueHooks$/;function eb(){bb&&(d.hidden===!1&&a.requestAnimationFrame?a.requestAnimationFrame(eb):a.setTimeout(eb,r.fx.interval),r.fx.tick())}function fb(){return a.setTimeout(function(){ab=void 0}),ab=r.now()}function gb(a,b){var c,d=0,e={height:a};for(b=b?1:0;d<4;d+=2-b)c=ca[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function hb(a,b,c){for(var d,e=(kb.tweeners[b]||[]).concat(kb.tweeners["*"]),f=0,g=e.length;f<g;f++)if(d=e[f].call(c,b,a))return d}function ib(a,b,c){var d,e,f,g,h,i,j,k,l="width"in b||"height"in b,m=this,n={},o=a.style,p=a.nodeType&&da(a),q=W.get(a,"fxshow");c.queue||(g=r._queueHooks(a,"fx"),null==g.unqueued&&(g.unqueued=0,h=g.empty.fire,g.empty.fire=function(){g.unqueued||h()}),g.unqueued++,m.always(function(){m.always(function(){g.unqueued--,r.queue(a,"fx").length||g.empty.fire()})}));for(d in b)if(e=b[d],cb.test(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}n[d]=q&&q[d]||r.style(a,d)}if(i=!r.isEmptyObject(b),i||!r.isEmptyObject(n)){l&&1===a.nodeType&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=q&&q.display,null==j&&(j=W.get(a,"display")),k=r.css(a,"display"),"none"===k&&(j?k=j:(ia([a],!0),j=a.style.display||j,k=r.css(a,"display"),ia([a]))),("inline"===k||"inline-block"===k&&null!=j)&&"none"===r.css(a,"float")&&(i||(m.done(function(){o.display=j}),null==j&&(k=o.display,j="none"===k?"":k)),o.display="inline-block")),c.overflow&&(o.overflow="hidden",m.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]})),i=!1;for(d in n)i||(q?"hidden"in q&&(p=q.hidden):q=W.access(a,"fxshow",{display:j}),f&&(q.hidden=!p),p&&ia([a],!0),m.done(function(){p||ia([a]),W.remove(a,"fxshow");for(d in n)r.style(a,d,n[d])})),i=hb(p?q[d]:0,d,m),d in q||(q[d]=i.start,p&&(i.end=i.start,i.start=0))}}function jb(a,b){var c,d,e,f,g;for(c in a)if(d=r.camelCase(c),e=b[d],f=a[c],Array.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=r.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function kb(a,b,c){var d,e,f=0,g=kb.prefilters.length,h=r.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=ab||fb(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;g<i;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),f<1&&i?c:(i||h.notifyWith(a,[j,1,0]),h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:r.extend({},b),opts:r.extend(!0,{specialEasing:{},easing:r.easing._default},c),originalProperties:b,originalOptions:c,startTime:ab||fb(),duration:c.duration,tweens:[],createTween:function(b,c){var d=r.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;c<d;c++)j.tweens[c].run(1);return b?(h.notifyWith(a,[j,1,0]),h.resolveWith(a,[j,b])):h.rejectWith(a,[j,b]),this}}),k=j.props;for(jb(k,j.opts.specialEasing);f<g;f++)if(d=kb.prefilters[f].call(j,a,k,j.opts))return r.isFunction(d.stop)&&(r._queueHooks(j.elem,j.opts.queue).stop=r.proxy(d.stop,d)),d;return r.map(k,hb,j),r.isFunction(j.opts.start)&&j.opts.start.call(a,j),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always),r.fx.timer(r.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j}r.Animation=r.extend(kb,{tweeners:{"*":[function(a,b){var c=this.createTween(a,b);return fa(c.elem,a,ba.exec(b),c),c}]},tweener:function(a,b){r.isFunction(a)?(b=a,a=["*"]):a=a.match(L);for(var c,d=0,e=a.length;d<e;d++)c=a[d],kb.tweeners[c]=kb.tweeners[c]||[],kb.tweeners[c].unshift(b)},prefilters:[ib],prefilter:function(a,b){b?kb.prefilters.unshift(a):kb.prefilters.push(a)}}),r.speed=function(a,b,c){var d=a&&"object"==typeof a?r.extend({},a):{complete:c||!c&&b||r.isFunction(a)&&a,duration:a,easing:c&&b||b&&!r.isFunction(b)&&b};return r.fx.off?d.duration=0:"number"!=typeof d.duration&&(d.duration in r.fx.speeds?d.duration=r.fx.speeds[d.duration]:d.duration=r.fx.speeds._default),null!=d.queue&&d.queue!==!0||(d.queue="fx"),d.old=d.complete,d.complete=function(){r.isFunction(d.old)&&d.old.call(this),d.queue&&r.dequeue(this,d.queue)},d},r.fn.extend({fadeTo:function(a,b,c,d){return this.filter(da).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=r.isEmptyObject(a),f=r.speed(b,c,d),g=function(){var b=kb(this,r.extend({},a),f);(e||W.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=r.timers,g=W.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&db.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));!b&&c||r.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=W.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=r.timers,g=d?d.length:0;for(c.finish=!0,r.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;b<g;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),r.each(["toggle","show","hide"],function(a,b){var c=r.fn[b];r.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(gb(b,!0),a,d,e)}}),r.each({slideDown:gb("show"),slideUp:gb("hide"),slideToggle:gb("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){r.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),r.timers=[],r.fx.tick=function(){var a,b=0,c=r.timers;for(ab=r.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||r.fx.stop(),ab=void 0},r.fx.timer=function(a){r.timers.push(a),r.fx.start()},r.fx.interval=13,r.fx.start=function(){bb||(bb=!0,eb())},r.fx.stop=function(){bb=null},r.fx.speeds={slow:600,fast:200,_default:400},r.fn.delay=function(b,c){return b=r.fx?r.fx.speeds[b]||b:b,c=c||"fx",this.queue(c,function(c,d){var e=a.setTimeout(c,b);d.stop=function(){a.clearTimeout(e)}})},function(){var a=d.createElement("input"),b=d.createElement("select"),c=b.appendChild(d.createElement("option"));a.type="checkbox",o.checkOn=""!==a.value,o.optSelected=c.selected,a=d.createElement("input"),a.value="t",a.type="radio",o.radioValue="t"===a.value}();var lb,mb=r.expr.attrHandle;r.fn.extend({attr:function(a,b){return T(this,r.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){r.removeAttr(this,a)})}}),r.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return"undefined"==typeof a.getAttribute?r.prop(a,b,c):(1===f&&r.isXMLDoc(a)||(e=r.attrHooks[b.toLowerCase()]||(r.expr.match.bool.test(b)?lb:void 0)),void 0!==c?null===c?void r.removeAttr(a,b):e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:(a.setAttribute(b,c+""),c):e&&"get"in e&&null!==(d=e.get(a,b))?d:(d=r.find.attr(a,b),
8null==d?void 0:d))},attrHooks:{type:{set:function(a,b){if(!o.radioValue&&"radio"===b&&B(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}},removeAttr:function(a,b){var c,d=0,e=b&&b.match(L);if(e&&1===a.nodeType)while(c=e[d++])a.removeAttribute(c)}}),lb={set:function(a,b,c){return b===!1?r.removeAttr(a,c):a.setAttribute(c,c),c}},r.each(r.expr.match.bool.source.match(/\w+/g),function(a,b){var c=mb[b]||r.find.attr;mb[b]=function(a,b,d){var e,f,g=b.toLowerCase();return d||(f=mb[g],mb[g]=e,e=null!=c(a,b,d)?g:null,mb[g]=f),e}});var nb=/^(?:input|select|textarea|button)$/i,ob=/^(?:a|area)$/i;r.fn.extend({prop:function(a,b){return T(this,r.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[r.propFix[a]||a]})}}),r.extend({prop:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return 1===f&&r.isXMLDoc(a)||(b=r.propFix[b]||b,e=r.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=r.find.attr(a,"tabindex");return b?parseInt(b,10):nb.test(a.nodeName)||ob.test(a.nodeName)&&a.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),o.optSelected||(r.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null},set:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}}),r.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){r.propFix[this.toLowerCase()]=this});function pb(a){var b=a.match(L)||[];return b.join(" ")}function qb(a){return a.getAttribute&&a.getAttribute("class")||""}r.fn.extend({addClass:function(a){var b,c,d,e,f,g,h,i=0;if(r.isFunction(a))return this.each(function(b){r(this).addClass(a.call(this,b,qb(this)))});if("string"==typeof a&&a){b=a.match(L)||[];while(c=this[i++])if(e=qb(c),d=1===c.nodeType&&" "+pb(e)+" "){g=0;while(f=b[g++])d.indexOf(" "+f+" ")<0&&(d+=f+" ");h=pb(d),e!==h&&c.setAttribute("class",h)}}return this},removeClass:function(a){var b,c,d,e,f,g,h,i=0;if(r.isFunction(a))return this.each(function(b){r(this).removeClass(a.call(this,b,qb(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof a&&a){b=a.match(L)||[];while(c=this[i++])if(e=qb(c),d=1===c.nodeType&&" "+pb(e)+" "){g=0;while(f=b[g++])while(d.indexOf(" "+f+" ")>-1)d=d.replace(" "+f+" "," ");h=pb(d),e!==h&&c.setAttribute("class",h)}}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):r.isFunction(a)?this.each(function(c){r(this).toggleClass(a.call(this,c,qb(this),b),b)}):this.each(function(){var b,d,e,f;if("string"===c){d=0,e=r(this),f=a.match(L)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else void 0!==a&&"boolean"!==c||(b=qb(this),b&&W.set(this,"__className__",b),this.setAttribute&&this.setAttribute("class",b||a===!1?"":W.get(this,"__className__")||""))})},hasClass:function(a){var b,c,d=0;b=" "+a+" ";while(c=this[d++])if(1===c.nodeType&&(" "+pb(qb(c))+" ").indexOf(b)>-1)return!0;return!1}});var rb=/\r/g;r.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=r.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,r(this).val()):a,null==e?e="":"number"==typeof e?e+="":Array.isArray(e)&&(e=r.map(e,function(a){return null==a?"":a+""})),b=r.valHooks[this.type]||r.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=r.valHooks[e.type]||r.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(rb,""):null==c?"":c)}}}),r.extend({valHooks:{option:{get:function(a){var b=r.find.attr(a,"value");return null!=b?b:pb(r.text(a))}},select:{get:function(a){var b,c,d,e=a.options,f=a.selectedIndex,g="select-one"===a.type,h=g?null:[],i=g?f+1:e.length;for(d=f<0?i:g?f:0;d<i;d++)if(c=e[d],(c.selected||d===f)&&!c.disabled&&(!c.parentNode.disabled||!B(c.parentNode,"optgroup"))){if(b=r(c).val(),g)return b;h.push(b)}return h},set:function(a,b){var c,d,e=a.options,f=r.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=r.inArray(r.valHooks.option.get(d),f)>-1)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),r.each(["radio","checkbox"],function(){r.valHooks[this]={set:function(a,b){if(Array.isArray(b))return a.checked=r.inArray(r(a).val(),b)>-1}},o.checkOn||(r.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var sb=/^(?:focusinfocus|focusoutblur)$/;r.extend(r.event,{trigger:function(b,c,e,f){var g,h,i,j,k,m,n,o=[e||d],p=l.call(b,"type")?b.type:b,q=l.call(b,"namespace")?b.namespace.split("."):[];if(h=i=e=e||d,3!==e.nodeType&&8!==e.nodeType&&!sb.test(p+r.event.triggered)&&(p.indexOf(".")>-1&&(q=p.split("."),p=q.shift(),q.sort()),k=p.indexOf(":")<0&&"on"+p,b=b[r.expando]?b:new r.Event(p,"object"==typeof b&&b),b.isTrigger=f?2:3,b.namespace=q.join("."),b.rnamespace=b.namespace?new RegExp("(^|\\.)"+q.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=e),c=null==c?[b]:r.makeArray(c,[b]),n=r.event.special[p]||{},f||!n.trigger||n.trigger.apply(e,c)!==!1)){if(!f&&!n.noBubble&&!r.isWindow(e)){for(j=n.delegateType||p,sb.test(j+p)||(h=h.parentNode);h;h=h.parentNode)o.push(h),i=h;i===(e.ownerDocument||d)&&o.push(i.defaultView||i.parentWindow||a)}g=0;while((h=o[g++])&&!b.isPropagationStopped())b.type=g>1?j:n.bindType||p,m=(W.get(h,"events")||{})[b.type]&&W.get(h,"handle"),m&&m.apply(h,c),m=k&&h[k],m&&m.apply&&U(h)&&(b.result=m.apply(h,c),b.result===!1&&b.preventDefault());return b.type=p,f||b.isDefaultPrevented()||n._default&&n._default.apply(o.pop(),c)!==!1||!U(e)||k&&r.isFunction(e[p])&&!r.isWindow(e)&&(i=e[k],i&&(e[k]=null),r.event.triggered=p,e[p](),r.event.triggered=void 0,i&&(e[k]=i)),b.result}},simulate:function(a,b,c){var d=r.extend(new r.Event,c,{type:a,isSimulated:!0});r.event.trigger(d,null,b)}}),r.fn.extend({trigger:function(a,b){return this.each(function(){r.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];if(c)return r.event.trigger(a,b,c,!0)}}),r.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(a,b){r.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),r.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}}),o.focusin="onfocusin"in a,o.focusin||r.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){r.event.simulate(b,a.target,r.event.fix(a))};r.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=W.access(d,b);e||d.addEventListener(a,c,!0),W.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=W.access(d,b)-1;e?W.access(d,b,e):(d.removeEventListener(a,c,!0),W.remove(d,b))}}});var tb=a.location,ub=r.now(),vb=/\?/;r.parseXML=function(b){var c;if(!b||"string"!=typeof b)return null;try{c=(new a.DOMParser).parseFromString(b,"text/xml")}catch(d){c=void 0}return c&&!c.getElementsByTagName("parsererror").length||r.error("Invalid XML: "+b),c};var wb=/\[\]$/,xb=/\r?\n/g,yb=/^(?:submit|button|image|reset|file)$/i,zb=/^(?:input|select|textarea|keygen)/i;function Ab(a,b,c,d){var e;if(Array.isArray(b))r.each(b,function(b,e){c||wb.test(a)?d(a,e):Ab(a+"["+("object"==typeof e&&null!=e?b:"")+"]",e,c,d)});else if(c||"object"!==r.type(b))d(a,b);else for(e in b)Ab(a+"["+e+"]",b[e],c,d)}r.param=function(a,b){var c,d=[],e=function(a,b){var c=r.isFunction(b)?b():b;d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(null==c?"":c)};if(Array.isArray(a)||a.jquery&&!r.isPlainObject(a))r.each(a,function(){e(this.name,this.value)});else for(c in a)Ab(c,a[c],b,e);return d.join("&")},r.fn.extend({serialize:function(){return r.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=r.prop(this,"elements");return a?r.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!r(this).is(":disabled")&&zb.test(this.nodeName)&&!yb.test(a)&&(this.checked||!ja.test(a))}).map(function(a,b){var c=r(this).val();return null==c?null:Array.isArray(c)?r.map(c,function(a){return{name:b.name,value:a.replace(xb,"\r\n")}}):{name:b.name,value:c.replace(xb,"\r\n")}}).get()}});var Bb=/%20/g,Cb=/#.*$/,Db=/([?&])_=[^&]*/,Eb=/^(.*?):[ \t]*([^\r\n]*)$/gm,Fb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Gb=/^(?:GET|HEAD)$/,Hb=/^\/\//,Ib={},Jb={},Kb="*/".concat("*"),Lb=d.createElement("a");Lb.href=tb.href;function Mb(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(L)||[];if(r.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function Nb(a,b,c,d){var e={},f=a===Jb;function g(h){var i;return e[h]=!0,r.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function Ob(a,b){var c,d,e=r.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&r.extend(!0,a,d),a}function Pb(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}if(f)return f!==i[0]&&i.unshift(f),c[f]}function Qb(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}r.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:tb.href,type:"GET",isLocal:Fb.test(tb.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Kb,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":r.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?Ob(Ob(a,r.ajaxSettings),b):Ob(r.ajaxSettings,a)},ajaxPrefilter:Mb(Ib),ajaxTransport:Mb(Jb),ajax:function(b,c){"object"==typeof b&&(c=b,b=void 0),c=c||{};var e,f,g,h,i,j,k,l,m,n,o=r.ajaxSetup({},c),p=o.context||o,q=o.context&&(p.nodeType||p.jquery)?r(p):r.event,s=r.Deferred(),t=r.Callbacks("once memory"),u=o.statusCode||{},v={},w={},x="canceled",y={readyState:0,getResponseHeader:function(a){var b;if(k){if(!h){h={};while(b=Eb.exec(g))h[b[1].toLowerCase()]=b[2]}b=h[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return k?g:null},setRequestHeader:function(a,b){return null==k&&(a=w[a.toLowerCase()]=w[a.toLowerCase()]||a,v[a]=b),this},overrideMimeType:function(a){return null==k&&(o.mimeType=a),this},statusCode:function(a){var b;if(a)if(k)y.always(a[y.status]);else for(b in a)u[b]=[u[b],a[b]];return this},abort:function(a){var b=a||x;return e&&e.abort(b),A(0,b),this}};if(s.promise(y),o.url=((b||o.url||tb.href)+"").replace(Hb,tb.protocol+"//"),o.type=c.method||c.type||o.method||o.type,o.dataTypes=(o.dataType||"*").toLowerCase().match(L)||[""],null==o.crossDomain){j=d.createElement("a");try{j.href=o.url,j.href=j.href,o.crossDomain=Lb.protocol+"//"+Lb.host!=j.protocol+"//"+j.host}catch(z){o.crossDomain=!0}}if(o.data&&o.processData&&"string"!=typeof o.data&&(o.data=r.param(o.data,o.traditional)),Nb(Ib,o,c,y),k)return y;l=r.event&&o.global,l&&0===r.active++&&r.event.trigger("ajaxStart"),o.type=o.type.toUpperCase(),o.hasContent=!Gb.test(o.type),f=o.url.replace(Cb,""),o.hasContent?o.data&&o.processData&&0===(o.contentType||"").indexOf("application/x-www-form-urlencoded")&&(o.data=o.data.replace(Bb,"+")):(n=o.url.slice(f.length),o.data&&(f+=(vb.test(f)?"&":"?")+o.data,delete o.data),o.cache===!1&&(f=f.replace(Db,"$1"),n=(vb.test(f)?"&":"?")+"_="+ub++ +n),o.url=f+n),o.ifModified&&(r.lastModified[f]&&y.setRequestHeader("If-Modified-Since",r.lastModified[f]),r.etag[f]&&y.setRequestHeader("If-None-Match",r.etag[f])),(o.data&&o.hasContent&&o.contentType!==!1||c.contentType)&&y.setRequestHeader("Content-Type",o.contentType),y.setRequestHeader("Accept",o.dataTypes[0]&&o.accepts[o.dataTypes[0]]?o.accepts[o.dataTypes[0]]+("*"!==o.dataTypes[0]?", "+Kb+"; q=0.01":""):o.accepts["*"]);for(m in o.headers)y.setRequestHeader(m,o.headers[m]);if(o.beforeSend&&(o.beforeSend.call(p,y,o)===!1||k))return y.abort();if(x="abort",t.add(o.complete),y.done(o.success),y.fail(o.error),e=Nb(Jb,o,c,y)){if(y.readyState=1,l&&q.trigger("ajaxSend",[y,o]),k)return y;o.async&&o.timeout>0&&(i=a.setTimeout(function(){y.abort("timeout")},o.timeout));try{k=!1,e.send(v,A)}catch(z){if(k)throw z;A(-1,z)}}else A(-1,"No Transport");function A(b,c,d,h){var j,m,n,v,w,x=c;k||(k=!0,i&&a.clearTimeout(i),e=void 0,g=h||"",y.readyState=b>0?4:0,j=b>=200&&b<300||304===b,d&&(v=Pb(o,y,d)),v=Qb(o,v,y,j),j?(o.ifModified&&(w=y.getResponseHeader("Last-Modified"),w&&(r.lastModified[f]=w),w=y.getResponseHeader("etag"),w&&(r.etag[f]=w)),204===b||"HEAD"===o.type?x="nocontent":304===b?x="notmodified":(x=v.state,m=v.data,n=v.error,j=!n)):(n=x,!b&&x||(x="error",b<0&&(b=0))),y.status=b,y.statusText=(c||x)+"",j?s.resolveWith(p,[m,x,y]):s.rejectWith(p,[y,x,n]),y.statusCode(u),u=void 0,l&&q.trigger(j?"ajaxSuccess":"ajaxError",[y,o,j?m:n]),t.fireWith(p,[y,x]),l&&(q.trigger("ajaxComplete",[y,o]),--r.active||r.event.trigger("ajaxStop")))}return y},getJSON:function(a,b,c){return r.get(a,b,c,"json")},getScript:function(a,b){return r.get(a,void 0,b,"script")}}),r.each(["get","post"],function(a,b){r[b]=function(a,c,d,e){return r.isFunction(c)&&(e=e||d,d=c,c=void 0),r.ajax(r.extend({url:a,type:b,dataType:e,data:c,success:d},r.isPlainObject(a)&&a))}}),r._evalUrl=function(a){return r.ajax({url:a,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,"throws":!0})},r.fn.extend({wrapAll:function(a){var b;return this[0]&&(r.isFunction(a)&&(a=a.call(this[0])),b=r(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this},wrapInner:function(a){return r.isFunction(a)?this.each(function(b){r(this).wrapInner(a.call(this,b))}):this.each(function(){var b=r(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=r.isFunction(a);return this.each(function(c){r(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(a){return this.parent(a).not("body").each(function(){r(this).replaceWith(this.childNodes)}),this}}),r.expr.pseudos.hidden=function(a){return!r.expr.pseudos.visible(a)},r.expr.pseudos.visible=function(a){return!!(a.offsetWidth||a.offsetHeight||a.getClientRects().length)},r.ajaxSettings.xhr=function(){try{return new a.XMLHttpRequest}catch(b){}};var Rb={0:200,1223:204},Sb=r.ajaxSettings.xhr();o.cors=!!Sb&&"withCredentials"in Sb,o.ajax=Sb=!!Sb,r.ajaxTransport(function(b){var c,d;if(o.cors||Sb&&!b.crossDomain)return{send:function(e,f){var g,h=b.xhr();if(h.open(b.type,b.url,b.async,b.username,b.password),b.xhrFields)for(g in b.xhrFields)h[g]=b.xhrFields[g];b.mimeType&&h.overrideMimeType&&h.overrideMimeType(b.mimeType),b.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest");for(g in e)h.setRequestHeader(g,e[g]);c=function(a){return function(){c&&(c=d=h.onload=h.onerror=h.onabort=h.onreadystatechange=null,"abort"===a?h.abort():"error"===a?"number"!=typeof h.status?f(0,"error"):f(h.status,h.statusText):f(Rb[h.status]||h.status,h.statusText,"text"!==(h.responseType||"text")||"string"!=typeof h.responseText?{binary:h.response}:{text:h.responseText},h.getAllResponseHeaders()))}},h.onload=c(),d=h.onerror=c("error"),void 0!==h.onabort?h.onabort=d:h.onreadystatechange=function(){4===h.readyState&&a.setTimeout(function(){c&&d()})},c=c("abort");try{h.send(b.hasContent&&b.data||null)}catch(i){if(c)throw i}},abort:function(){c&&c()}}}),r.ajaxPrefilter(function(a){a.crossDomain&&(a.contents.script=!1)}),r.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(a){return r.globalEval(a),a}}}),r.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),r.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(e,f){b=r("<script>").prop({charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&f("error"===a.type?404:200,a.type)}),d.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Tb=[],Ub=/(=)\?(?=&|$)|\?\?/;r.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Tb.pop()||r.expando+"_"+ub++;return this[a]=!0,a}}),r.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Ub.test(b.url)?"url":"string"==typeof b.data&&0===(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ub.test(b.data)&&"data");if(h||"jsonp"===b.dataTypes[0])return e=b.jsonpCallback=r.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Ub,"$1"+e):b.jsonp!==!1&&(b.url+=(vb.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||r.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){void 0===f?r(a).removeProp(e):a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Tb.push(e)),g&&r.isFunction(f)&&f(g[0]),g=f=void 0}),"script"}),o.createHTMLDocument=function(){var a=d.implementation.createHTMLDocument("").body;return a.innerHTML="<form></form><form></form>",2===a.childNodes.length}(),r.parseHTML=function(a,b,c){if("string"!=typeof a)return[];"boolean"==typeof b&&(c=b,b=!1);var e,f,g;return b||(o.createHTMLDocument?(b=d.implementation.createHTMLDocument(""),e=b.createElement("base"),e.href=d.location.href,b.head.appendChild(e)):b=d),f=C.exec(a),g=!c&&[],f?[b.createElement(f[1])]:(f=qa([a],b,g),g&&g.length&&r(g).remove(),r.merge([],f.childNodes))},r.fn.load=function(a,b,c){var d,e,f,g=this,h=a.indexOf(" ");return h>-1&&(d=pb(a.slice(h)),a=a.slice(0,h)),r.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&r.ajax({url:a,type:e||"GET",dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?r("<div>").append(r.parseHTML(a)).find(d):a)}).always(c&&function(a,b){g.each(function(){c.apply(this,f||[a.responseText,b,a])})}),this},r.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){r.fn[b]=function(a){return this.on(b,a)}}),r.expr.pseudos.animated=function(a){return r.grep(r.timers,function(b){return a===b.elem}).length},r.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=r.css(a,"position"),l=r(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=r.css(a,"top"),i=r.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),r.isFunction(b)&&(b=b.call(a,c,r.extend({},h))),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},r.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){r.offset.setOffset(this,a,b)});var b,c,d,e,f=this[0];if(f)return f.getClientRects().length?(d=f.getBoundingClientRect(),b=f.ownerDocument,c=b.documentElement,e=b.defaultView,{top:d.top+e.pageYOffset-c.clientTop,left:d.left+e.pageXOffset-c.clientLeft}):{top:0,left:0}},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===r.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),B(a[0],"html")||(d=a.offset()),d={top:d.top+r.css(a[0],"borderTopWidth",!0),left:d.left+r.css(a[0],"borderLeftWidth",!0)}),{top:b.top-d.top-r.css(c,"marginTop",!0),left:b.left-d.left-r.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent;while(a&&"static"===r.css(a,"position"))a=a.offsetParent;return a||ra})}}),r.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c="pageYOffset"===b;r.fn[a]=function(d){return T(this,function(a,d,e){var f;return r.isWindow(a)?f=a:9===a.nodeType&&(f=a.defaultView),void 0===e?f?f[b]:a[d]:void(f?f.scrollTo(c?f.pageXOffset:e,c?e:f.pageYOffset):a[d]=e)},a,d,arguments.length)}}),r.each(["top","left"],function(a,b){r.cssHooks[b]=Pa(o.pixelPosition,function(a,c){if(c)return c=Oa(a,b),Ma.test(c)?r(a).position()[b]+"px":c})}),r.each({Height:"height",Width:"width"},function(a,b){r.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){r.fn[d]=function(e,f){var g=arguments.length&&(c||"boolean"!=typeof e),h=c||(e===!0||f===!0?"margin":"border");return T(this,function(b,c,e){var f;return r.isWindow(b)?0===d.indexOf("outer")?b["inner"+a]:b.document.documentElement["client"+a]:9===b.nodeType?(f=b.documentElement,Math.max(b.body["scroll"+a],f["scroll"+a],b.body["offset"+a],f["offset"+a],f["client"+a])):void 0===e?r.css(b,c,h):r.style(b,c,e,h)},b,g?e:void 0,g)}})}),r.fn.extend({bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)}}),r.holdReady=function(a){a?r.readyWait++:r.ready(!0)},r.isArray=Array.isArray,r.parseJSON=JSON.parse,r.nodeName=B,"function"==typeof define&&define.amd&&define("jquery",[],function(){return r});var Vb=a.jQuery,Wb=a.$;return r.noConflict=function(b){return a.$===r&&(a.$=Wb),b&&a.jQuery===r&&(a.jQuery=Vb),r},b||(a.jQuery=a.$=r),r});
9;
10//     Underscore.js 1.8.3
11//     http://underscorejs.org
12//     (c) 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
13//     Underscore may be freely distributed under the MIT license.
14(function(){function n(n){function t(t,r,e,u,i,o){for(;i>=0&&o>i;i+=n){var a=u?u[i]:i;e=r(e,t[a],a,t)}return e}return function(r,e,u,i){e=b(e,i,4);var o=!k(r)&&m.keys(r),a=(o||r).length,c=n>0?0:a-1;return arguments.length<3&&(u=r[o?o[c]:c],c+=n),t(r,e,u,o,c,a)}}function t(n){return function(t,r,e){r=x(r,e);for(var u=O(t),i=n>0?0:u-1;i>=0&&u>i;i+=n)if(r(t[i],i,t))return i;return-1}}function r(n,t,r){return function(e,u,i){var o=0,a=O(e);if("number"==typeof i)n>0?o=i>=0?i:Math.max(i+a,o):a=i>=0?Math.min(i+1,a):i+a+1;else if(r&&i&&a)return i=r(e,u),e[i]===u?i:-1;if(u!==u)return i=t(l.call(e,o,a),m.isNaN),i>=0?i+o:-1;for(i=n>0?o:a-1;i>=0&&a>i;i+=n)if(e[i]===u)return i;return-1}}function e(n,t){var r=I.length,e=n.constructor,u=m.isFunction(e)&&e.prototype||a,i="constructor";for(m.has(n,i)&&!m.contains(t,i)&&t.push(i);r--;)i=I[r],i in n&&n[i]!==u[i]&&!m.contains(t,i)&&t.push(i)}var u=this,i=u._,o=Array.prototype,a=Object.prototype,c=Function.prototype,f=o.push,l=o.slice,s=a.toString,p=a.hasOwnProperty,h=Array.isArray,v=Object.keys,g=c.bind,y=Object.create,d=function(){},m=function(n){return n instanceof m?n:this instanceof m?void(this._wrapped=n):new m(n)};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=m),exports._=m):u._=m,m.VERSION="1.8.3";var b=function(n,t,r){if(t===void 0)return n;switch(null==r?3:r){case 1:return function(r){return n.call(t,r)};case 2:return function(r,e){return n.call(t,r,e)};case 3:return function(r,e,u){return n.call(t,r,e,u)};case 4:return function(r,e,u,i){return n.call(t,r,e,u,i)}}return function(){return n.apply(t,arguments)}},x=function(n,t,r){return null==n?m.identity:m.isFunction(n)?b(n,t,r):m.isObject(n)?m.matcher(n):m.property(n)};m.iteratee=function(n,t){return x(n,t,1/0)};var _=function(n,t){return function(r){var e=arguments.length;if(2>e||null==r)return r;for(var u=1;e>u;u++)for(var i=arguments[u],o=n(i),a=o.length,c=0;a>c;c++){var f=o[c];t&&r[f]!==void 0||(r[f]=i[f])}return r}},j=function(n){if(!m.isObject(n))return{};if(y)return y(n);d.prototype=n;var t=new d;return d.prototype=null,t},w=function(n){return function(t){return null==t?void 0:t[n]}},A=Math.pow(2,53)-1,O=w("length"),k=function(n){var t=O(n);return"number"==typeof t&&t>=0&&A>=t};m.each=m.forEach=function(n,t,r){t=b(t,r);var e,u;if(k(n))for(e=0,u=n.length;u>e;e++)t(n[e],e,n);else{var i=m.keys(n);for(e=0,u=i.length;u>e;e++)t(n[i[e]],i[e],n)}return n},m.map=m.collect=function(n,t,r){t=x(t,r);for(var e=!k(n)&&m.keys(n),u=(e||n).length,i=Array(u),o=0;u>o;o++){var a=e?e[o]:o;i[o]=t(n[a],a,n)}return i},m.reduce=m.foldl=m.inject=n(1),m.reduceRight=m.foldr=n(-1),m.find=m.detect=function(n,t,r){var e;return e=k(n)?m.findIndex(n,t,r):m.findKey(n,t,r),e!==void 0&&e!==-1?n[e]:void 0},m.filter=m.select=function(n,t,r){var e=[];return t=x(t,r),m.each(n,function(n,r,u){t(n,r,u)&&e.push(n)}),e},m.reject=function(n,t,r){return m.filter(n,m.negate(x(t)),r)},m.every=m.all=function(n,t,r){t=x(t,r);for(var e=!k(n)&&m.keys(n),u=(e||n).length,i=0;u>i;i++){var o=e?e[i]:i;if(!t(n[o],o,n))return!1}return!0},m.some=m.any=function(n,t,r){t=x(t,r);for(var e=!k(n)&&m.keys(n),u=(e||n).length,i=0;u>i;i++){var o=e?e[i]:i;if(t(n[o],o,n))return!0}return!1},m.contains=m.includes=m.include=function(n,t,r,e){return k(n)||(n=m.values(n)),("number"!=typeof r||e)&&(r=0),m.indexOf(n,t,r)>=0},m.invoke=function(n,t){var r=l.call(arguments,2),e=m.isFunction(t);return m.map(n,function(n){var u=e?t:n[t];return null==u?u:u.apply(n,r)})},m.pluck=function(n,t){return m.map(n,m.property(t))},m.where=function(n,t){return m.filter(n,m.matcher(t))},m.findWhere=function(n,t){return m.find(n,m.matcher(t))},m.max=function(n,t,r){var e,u,i=-1/0,o=-1/0;if(null==t&&null!=n){n=k(n)?n:m.values(n);for(var a=0,c=n.length;c>a;a++)e=n[a],e>i&&(i=e)}else t=x(t,r),m.each(n,function(n,r,e){u=t(n,r,e),(u>o||u===-1/0&&i===-1/0)&&(i=n,o=u)});return i},m.min=function(n,t,r){var e,u,i=1/0,o=1/0;
14if(null==t&&null!=n){n=k(n)?n:m.values(n);for(var a=0,c=n.length;c>a;a++)e=n[a],i>e&&(i=e)}else t=x(t,r),m.each(n,function(n,r,e){u=t(n,r,e),(o>u||1/0===u&&1/0===i)&&(i=n,o=u)});return i},m.shuffle=function(n){for(var t,r=k(n)?n:m.values(n),e=r.length,u=Array(e),i=0;e>i;i++)t=m.random(0,i),t!==i&&(u[i]=u[t]),u[t]=r[i];return u},m.sample=function(n,t,r){return null==t||r?(k(n)||(n=m.values(n)),n[m.random(n.length-1)]):m.shuffle(n).slice(0,Math.max(0,t))},m.sortBy=function(n,t,r){return t=x(t,r),m.pluck(m.map(n,function(n,r,e){return{value:n,index:r,criteria:t(n,r,e)}}).sort(function(n,t){var r=n.criteria,e=t.criteria;if(r!==e){if(r>e||r===void 0)return 1;if(e>r||e===void 0)return-1}return n.index-t.index}),"value")};var F=function(n){return function(t,r,e){var u={};return r=x(r,e),m.each(t,function(e,i){var o=r(e,i,t);n(u,e,o)}),u}};m.groupBy=F(function(n,t,r){m.has(n,r)?n[r].push(t):n[r]=[t]}),m.indexBy=F(function(n,t,r){n[r]=t}),m.countBy=F(function(n,t,r){m.has(n,r)?n[r]++:n[r]=1}),m.toArray=function(n){return n?m.isArray(n)?l.call(n):k(n)?m.map(n,m.identity):m.values(n):[]},m.size=function(n){return null==n?0:k(n)?n.length:m.keys(n).length},m.partition=function(n,t,r){t=x(t,r);var e=[],u=[];return m.each(n,function(n,r,i){(t(n,r,i)?e:u).push(n)}),[e,u]},m.first=m.head=m.take=function(n,t,r){return null==n?void 0:null==t||r?n[0]:m.initial(n,n.length-t)},m.initial=function(n,t,r){return l.call(n,0,Math.max(0,n.length-(null==t||r?1:t)))},m.last=function(n,t,r){return null==n?void 0:null==t||r?n[n.length-1]:m.rest(n,Math.max(0,n.length-t))},m.rest=m.tail=m.drop=function(n,t,r){return l.call(n,null==t||r?1:t)},m.compact=function(n){return m.filter(n,m.identity)};var S=function(n,t,r,e){for(var u=[],i=0,o=e||0,a=O(n);a>o;o++){var c=n[o];if(k(c)&&(m.isArray(c)||m.isArguments(c))){t||(c=S(c,t,r));var f=0,l=c.length;for(u.length+=l;l>f;)u[i++]=c[f++]}else r||(u[i++]=c)}return u};m.flatten=function(n,t){return S(n,t,!1)},m.without=function(n){return m.difference(n,l.call(arguments,1))},m.uniq=m.unique=function(n,t,r,e){m.isBoolean(t)||(e=r,r=t,t=!1),null!=r&&(r=x(r,e));for(var u=[],i=[],o=0,a=O(n);a>o;o++){var c=n[o],f=r?r(c,o,n):c;t?(o&&i===f||u.push(c),i=f):r?m.contains(i,f)||(i.push(f),u.push(c)):m.contains(u,c)||u.push(c)}return u},m.union=function(){return m.uniq(S(arguments,!0,!0))},m.intersection=function(n){for(var t=[],r=arguments.length,e=0,u=O(n);u>e;e++){var i=n[e];if(!m.contains(t,i)){for(var o=1;r>o&&m.contains(arguments[o],i);o++);o===r&&t.push(i)}}return t},m.difference=function(n){var t=S(arguments,!0,!0,1);return m.filter(n,function(n){return!m.contains(t,n)})},m.zip=function(){return m.unzip(arguments)},m.unzip=function(n){for(var t=n&&m.max(n,O).length||0,r=Array(t),e=0;t>e;e++)r[e]=m.pluck(n,e);return r},m.object=function(n,t){for(var r={},e=0,u=O(n);u>e;e++)t?r[n[e]]=t[e]:r[n[e][0]]=n[e][1];return r},m.findIndex=t(1),m.findLastIndex=t(-1),m.sortedIndex=function(n,t,r,e){r=x(r,e,1);for(var u=r(t),i=0,o=O(n);o>i;){var a=Math.floor((i+o)/2);r(n[a])<u?i=a+1:o=a}return i},m.indexOf=r(1,m.findIndex,m.sortedIndex),m.lastIndexOf=r(-1,m.findLastIndex),m.range=function(n,t,r){null==t&&(t=n||0,n=0),r=r||1;for(var e=Math.max(Math.ceil((t-n)/r),0),u=Array(e),i=0;e>i;i++,n+=r)u[i]=n;return u};var E=function(n,t,r,e,u){if(!(e instanceof t))return n.apply(r,u);var i=j(n.prototype),o=n.apply(i,u);return m.isObject(o)?o:i};m.bind=function(n,t){if(g&&n.bind===g)return g.apply(n,l.call(arguments,1));if(!m.isFunction(n))throw new TypeError("Bind must be called on a function");var r=l.call(arguments,2),e=function(){return E(n,e,t,this,r.concat(l.call(arguments)))};return e},m.partial=function(n){var t=l.call(arguments,1),r=function(){for(var e=0,u=t.length,i=Array(u),o=0;u>o;o++)i[o]=t[o]===m?arguments[e++]:t[o];for(;e<arguments.length;)i.push(arguments[e++]);return E(n,r,this,this,i)};return r},m.bindAll=function(n){var t,r,e=arguments.length;if(1>=e)throw new Error("bindAll must be passed function names");for(t=1;e>t;t++)r=arguments[t],n[r]=m.bind(n[r],n);return n},m.memoize=function(n,t){var r=function(e){var u=r.cache,i=""+(t?t.apply(this,arguments):e);return m.has(u,i)||(u[i]=n.apply(this,arguments)),u[i]};return r.cache={},r},m.delay=function(n,t){var r=l.call(arguments,2);return setTimeout(function(){return n.apply(null,r)},t)},m.defer=m.partial(m.delay,m,1),m.throttle=function(n,t,r){var e,u,i,o=null,a=0;r||(r={});var c=function(){a=r.leading===!1?0:m.now(),o=null,i=n.apply(e,u),o||(e=u=null)};return function(){var f=m.now();a||r.leading!==!1||(a=f);var l=t-(f-a);return e=this,u=arguments,0>=l||l>t?(o&&(clearTimeout(o),o=null),a=f,i=n.apply(e,u),o||(e=u=null)):o||r.trailing===!1||(o=setTimeout(c,l)),i}},m.debounce=function(n,t,r){var e,u,i,o,a,c=function(){var f=m.now()-o;t>f&&f>=0?e=setTimeout(c,t-f):(e=null,r||(a=n.apply(i,u),e||(i=u=null)))};return function(){i=this,u=arguments,o=m.now();var f=r&&!e;return e||(e=setTimeout(c,t)),f&&(a=n.apply(i,u),i=u=null),a}},m.wrap=function(n,t){return m.partial(t,n)},m.negate=function(n){return function(){return!n.apply(this,arguments)}},m.compose=function(){var n=arguments,t=n.length-1;return function(){for(var r=t,e=n[t].apply(this,arguments);r--;)e=n[r].call(this,e);return e}},m.after=function(n,t){return function(){return--n<1?t.apply(this,arguments):void 0}},m.before=function(n,t){var r;return function(){return--n>0&&(r=t.apply(this,arguments)),1>=n&&(t=null),r}},m.once=m.partial(m.before,2);var M=!{toString:null}.propertyIsEnumerable("toString"),I=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleStr
14ing"];m.keys=function(n){if(!m.isObject(n))return[];if(v)return v(n);var t=[];for(var r in n)m.has(n,r)&&t.push(r);return M&&e(n,t),t},m.allKeys=function(n){if(!m.isObject(n))return[];var t=[];for(var r in n)t.push(r);return M&&e(n,t),t},m.values=function(n){for(var t=m.keys(n),r=t.length,e=Array(r),u=0;r>u;u++)e[u]=n[t[u]];return e},m.mapObject=function(n,t,r){t=x(t,r);for(var e,u=m.keys(n),i=u.length,o={},a=0;i>a;a++)e=u[a],o[e]=t(n[e],e,n);return o},m.pairs=function(n){for(var t=m.keys(n),r=t.length,e=Array(r),u=0;r>u;u++)e[u]=[t[u],n[t[u]]];return e},m.invert=function(n){for(var t={},r=m.keys(n),e=0,u=r.length;u>e;e++)t[n[r[e]]]=r[e];return t},m.functions=m.methods=function(n){var t=[];for(var r in n)m.isFunction(n[r])&&t.push(r);return t.sort()},m.extend=_(m.allKeys),m.extendOwn=m.assign=_(m.keys),m.findKey=function(n,t,r){t=x(t,r);for(var e,u=m.keys(n),i=0,o=u.length;o>i;i++)if(e=u[i],t(n[e],e,n))return e},m.pick=function(n,t,r){var e,u,i={},o=n;if(null==o)return i;m.isFunction(t)?(u=m.allKeys(o),e=b(t,r)):(u=S(arguments,!1,!1,1),e=function(n,t,r){return t in r},o=Object(o));for(var a=0,c=u.length;c>a;a++){var f=u[a],l=o[f];e(l,f,o)&&(i[f]=l)}return i},m.omit=function(n,t,r){if(m.isFunction(t))t=m.negate(t);else{var e=m.map(S(arguments,!1,!1,1),String);t=function(n,t){return!m.contains(e,t)}}return m.pick(n,t,r)},m.defaults=_(m.allKeys,!0),m.create=function(n,t){var r=j(n);return t&&m.extendOwn(r,t),r},m.clone=function(n){return m.isObject(n)?m.isArray(n)?n.slice():m.extend({},n):n},m.tap=function(n,t){return t(n),n},m.isMatch=function(n,t){var r=m.keys(t),e=r.length;if(null==n)return!e;for(var u=Object(n),i=0;e>i;i++){var o=r[i];if(t[o]!==u[o]||!(o in u))return!1}return!0};var N=function(n,t,r,e){if(n===t)return 0!==n||1/n===1/t;if(null==n||null==t)return n===t;n instanceof m&&(n=n._wrapped),t instanceof m&&(t=t._wrapped);var u=s.call(n);if(u!==s.call(t))return!1;switch(u){case"[object RegExp]":case"[object String]":return""+n==""+t;case"[object Number]":return+n!==+n?+t!==+t:0===+n?1/+n===1/t:+n===+t;case"[object Date]":case"[object Boolean]":return+n===+t}var i="[object Array]"===u;if(!i){if("object"!=typeof n||"object"!=typeof t)return!1;var o=n.constructor,a=t.constructor;if(o!==a&&!(m.isFunction(o)&&o instanceof o&&m.isFunction(a)&&a instanceof a)&&"constructor"in n&&"constructor"in t)return!1}r=r||[],e=e||[];for(var c=r.length;c--;)if(r[c]===n)return e[c]===t;if(r.push(n),e.push(t),i){if(c=n.length,c!==t.length)return!1;for(;c--;)if(!N(n[c],t[c],r,e))return!1}else{var f,l=m.keys(n);if(c=l.length,m.keys(t).length!==c)return!1;for(;c--;)if(f=l[c],!m.has(t,f)||!N(n[f],t[f],r,e))return!1}return r.pop(),e.pop(),!0};m.isEqual=function(n,t){return N(n,t)},m.isEmpty=function(n){return null==n?!0:k(n)&&(m.isArray(n)||m.isString(n)||m.isArguments(n))?0===n.length:0===m.keys(n).length},m.isElement=function(n){return!(!n||1!==n.nodeType)},m.isArray=h||function(n){return"[object Array]"===s.call(n)},m.isObject=function(n){var t=typeof n;return"function"===t||"object"===t&&!!n},m.each(["Arguments","Function","String","Number","Date","RegExp","Error"],function(n){m["is"+n]=function(t){return s.call(t)==="[object "+n+"]"}}),m.isArguments(arguments)||(m.isArguments=function(n){return m.has(n,"callee")}),"function"!=typeof/./&&"object"!=typeof Int8Array&&(m.isFunction=function(n){return"function"==typeof n||!1}),m.isFinite=function(n){return isFinite(n)&&!isNaN(parseFloat(n))},m.isNaN=function(n){return m.isNumber(n)&&n!==+n},m.isBoolean=function(n){return n===!0||n===!1||"[object Boolean]"===s.call(n)},m.isNull=function(n){return null===n},m.isUndefined=function(n){return n===void 0},m.has=function(n,t){return null!=n&&p.call(n,t)},m.noConflict=function(){return u._=i,this},m.identity=function(n){return n},m.constant=function(n){return function(){return n}},m.noop=function(){},m.property=w,m.propertyOf=function(n){return null==n?function(){}:function(t){return n[t]}},m.matcher=m.matches=function(n){return n=m.extendOwn({},n),function(t){return m.isMatch(t,n)}},m.times=function(n,t,r){var e=Array(Math.max(0,n));t=b(t,r,1);for(var u=0;n>u;u++)e[u]=t(u);return e},m.random=function(n,t){return null==t&&(t=n,n=0),n+Math.floor(Math.random()*(t-n+1))},m.now=Date.now||function(){return(new Date).getTime()};var B={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},T=m.invert(B),R=function(n){var t=function(t){return n[t]},r="(?:"+m.keys(n).join("|")+")",e=RegExp(r),u=RegExp(r,"g");return function(n){return n=null==n?"":""+n,e.test(n)?n.replace(u,t):n}};m.escape=R(B),m.unescape=R(T),m.result=function(n,t,r){var e=null==n?void 0:n[t];return e===void 0&&(e=r),m.isFunction(e)?e.call(n):e};var q=0;m.uniqueId=function(n){var t=++q+"";return n?n+t:t},m.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var K=/(.)^/,z={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},D=/\\|'|\r|\n|\u2028|\u2029/g,L=function(n){return"\\"+z[n]};m.template=function(n,t,r){!t&&r&&(t=r),t=m.defaults({},t,m.templateSettings);var e=RegExp([(t.escape||K).source,(t.interpolate||K).source,(t.evaluate||K).source].join("|")+"|$","g"),u=0,i="__p+='";n.replace(e,function(t,r,e,o,a){return i+=n.slice(u,a).replace(D,L),u=a+t.length,r?i+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'":e?i+="'+\n((__t=("+e+"))==null?'':__t)+\n'":o&&(i+="';\n"+o+"\n__p+='"),t}),i+="';\n",t.variable||(i="with(obj||{}){\n"+i+"}\n"),i="var __t,__p='',__j=Array.prototype.join,"+"print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{var o=new Function(t.variable||"obj","_",i)}catch(a){throw a.source=i,a}var c=function(n){return o.call(this,n,m)},f=t.variable||"obj";return c.source="function("+f+"){\n"+i+"}",c},m.chain=function(n){var t=m(n);return t._chain=!0,t};var P=function(n,t){return n._chain?m(t).chain():t};m.mixin=function(n){m.each(m.functions(n),function(t){var r=m[t]=n[t];m.prototype[t]=function(){var n=[this._wrapped];return f.apply(n,arguments),P(this,r.apply(m,n))}})},m.mixin(m),m.each(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var t=o[n];m.prototype[n]=function(){var r=this._wrapped;return t.apply(r,arguments),"shift"!==n&&"splice"!==n||0!==r.length||delete r[0],P(this,r)}}),m.each(["concat","join","slice"],function(n){var t=o[n];m.prototype[n]=function(){return P(this,t.apply(this._wrapped,arguments))}}),m.prototype.value=function(){return this._wrapped},m.prototype.valueOf=m.prototype.toJSON=m.prototype.value,m.prototype.toString=function(){return""+this._wrapped},"function"==typeof define&&define.amd&&define("underscore",[],function(){return m})}).call(this);
15
16/*!
17 * jQuery Once v2.2.0 - http://github.com/robloach/jquery-once
18 * @license MIT, GPL-2.0
19 *   http://opensource.org/licenses/MIT
20 *   http://opensource.org/licenses/GPL-2.0
21 */
22(function(e){"use strict";if(typeof exports==="object"){e(require("jquery"))}else if(typeof define==="function"&&define.amd){define(["jquery"],e)}else{e(jQuery)}})(function(e){"use strict";var n=function(e){e=e||"once";if(typeof e!=="string"){throw new TypeError("The jQuery Once id parameter must be a string")}return e};e.fn.once=function(t){var r="jquery-once-"+n(t);return this.filter(function(){return e(this).data(r)!==true}).data(r,true)};e.fn.removeOnce=function(e){return this.findOnce(e).removeData("jquery-once-"+n(e))};e.fn.findOnce=function(t){var r="jquery-once-"+n(t);return this.filter(function(){return e(this).data(r)===true})}});
23
24(function(t){var e=typeof self=="object"&&self.self==self&&self||typeof global=="object"&&global.global==global&&global;if(typeof define==="function"&&define.amd){define(["underscore","jquery","exports"],function(i,r,n){e.Backbone=t(e,n,i,r)})}else if(typeof exports!=="undefined"){var i=require("underscore"),r;try{r=require("jquery")}catch(n){}t(e,exports,i,r)}else{e.Backbone=t(e,{},e._,e.jQuery||e.Zepto||e.ender||e.$)}}
vendor: 11,864 bytes, line 24
24)(function(t,e,i,r){var n=t.Backbone;var s=Array.prototype.slice;e.VERSION="1.2.3";e.$=r;e.noConflict=function(){t.Backbone=n;return this};e.emulateHTTP=false;e.emulateJSON=false;var a=function(t,e,r){switch(t){case 1:return function(){return i[e](this[r])};case 2:return function(t){return i[e](this[r],t)};case 3:return function(t,n){return i[e](this[r],h(t,this),n)};case 4:return function(t,n,s){return i[e](this[r],h(t,this),n,s)};default:return function(){var t=s.call(arguments);t.unshift(this[r]);return i[e].apply(i,t)}}};var o=function(t,e,r){i.each(e,function(e,n){if(i[n])t.prototype[n]=a(e,n,r)})};var h=function(t,e){if(i.isFunction(t))return t;if(i.isObject(t)&&!e._isModel(t))return u(t);if(i.isString(t))return function(e){return e.get(t)};return t};var u=function(t){var e=i.matches(t);return function(t){return e(t.attributes)}};var l=e.Events={};var c=/\s+/;var f=function(t,e,r,n,s){var a=0,o;if(r&&typeof r==="object"){if(n!==void 0&&"context"in s&&s.context===void 0)s.context=n;for(o=i.keys(r);a<o.length;a++){e=f(t,e,o[a],r[o[a]],s)}}else if(r&&c.test(r)){for(o=r.split(c);a<o.length;a++){e=t(e,o[a],n,s)}}else{e=t(e,r,n,s)}return e};l.on=function(t,e,i){return d(this,t,e,i)};var d=function(t,e,i,r,n){t._events=f(v,t._events||{},e,i,{context:r,ctx:t,listening:n});if(n){var s=t._listeners||(t._listeners={});s[n.id]=n}return t};l.listenTo=function(t,e,r){if(!t)return this;var n=t._listenId||(t._listenId=i.uniqueId("l"));var s=this._listeningTo||(this._listeningTo={});var a=s[n];if(!a){var o=this._listenId||(this._listenId=i.uniqueId("l"));a=s[n]={obj:t,objId:n,id:o,listeningTo:s,count:0}}d(t,e,r,this,a);return this};var v=function(t,e,i,r){if(i){var n=t[e]||(t[e]=[]);var s=r.context,a=r.ctx,o=r.listening;if(o)o.count++;n.push({callback:i,context:s,ctx:s||a,listening:o})}return t};l.off=function(t,e,i){if(!this._events)return this;this._events=f(g,this._events,t,e,{context:i,listeners:this._listeners});return this};l.stopListening=function(t,e,r){var n=this._listeningTo;if(!n)return this;var s=t?[t._listenId]:i.keys(n);for(var a=0;a<s.length;a++){var o=n[s[a]];if(!o)break;o.obj.off(e,r,this)}if(i.isEmpty(n))this._listeningTo=void 0;return this};var g=function(t,e,r,n){if(!t)return;var s=0,a;var o=n.context,h=n.listeners;if(!e&&!r&&!o){var u=i.keys(h);for(;s<u.length;s++){a=h[u[s]];delete h[a.id];delete a.listeningTo[a.objId]}return}var l=e?[e]:i.keys(t);for(;s<l.length;s++){e=l[s];var c=t[e];if(!c)break;var f=[];for(var d=0;d<c.length;d++){var v=c[d];if(r&&r!==v.callback&&r!==v.callback._callback||o&&o!==v.context){f.push(v)}else{a=v.listening;if(a&&--a.count===0){delete h[a.id];delete a.listeningTo[a.objId]}}}if(f.length){t[e]=f}else{delete t[e]}}if(i.size(t))return t};l.once=function(t,e,r){var n=f(p,{},t,e,i.bind(this.off,this));return this.on(n,void 0,r)};l.listenToOnce=function(t,e,r){var n=f(p,{},e,r,i.bind(this.stopListening,this,t));return this.listenTo(t,n)};var p=function(t,e,r,n){if(r){var s=t[e]=i.once(function(){n(e,s);r.apply(this,arguments)});s._callback=r}return t};l.trigger=function(t){if(!this._events)return this;var e=Math.max(0,arguments.length-1);var i=Array(e);for(var r=0;r<e;r++)i[r]=arguments[r+1];f(m,this._events,t,void 0,i);return this};var m=function(t,e,i,r){if(t){var n=t[e];var s=t.all;if(n&&s)s=s.slice();if(n)_(n,r);if(s)_(s,[e].concat(r))}return t};var _=function(t,e){var i,r=-1,n=t.length,s=e[0],a=e[1],o=e[2];switch(e.length){case 0:while(++r<n)(i=t[r]).callback.call(i.ctx);return;case 1:while(++r<n)(i=t[r]).callback.call(i.ctx,s);return;case 2:while(++r<n)(i=t[r]).callback.call(i.ctx,s,a);return;case 3:while(++r<n)(i=t[r]).callback.call(i.ctx,s,a,o);return;default:while(++r<n)(i=t[r]).callback.apply(i.ctx,e);return}};l.bind=l.on;l.unbind=l.off;i.extend(e,l);var y=e.Model=function(t,e){var r=t||{};e||(e={});this.cid=i.uniqueId(this.cidPrefix);this.attributes={};if(e.collection)this.collection=e.collection;if(e.parse)r=this.parse(r,e)||{};r=i.defaults({},r,i.result(this,"defaults"));this.set(r,e);this.changed={};this.initialize.apply(this,arguments)};i.extend(y.prototype,l,{changed:null,validationError:null,idAttribute:"id",cidPrefix:"c",initialize:function(){},toJSON:function(t){return i.clone(this.attributes)},sync:function(){return e.sync.apply(this,arguments)},get:function(t){return this.attributes[t]},escape:function(t){return i.escape(this.get(t))},has:function(t){return this.get(t)!=null},matches:function(t){return!!i.iteratee(t,this)(this.attributes)},set:function(t,e,r){if(t==null)return this;var n;if(typeof t==="object"){n=t;r=e}else{(n={})[t]=e}r||(r={});if(!this._validate(n,r))return false;var s=r.unset;var a=r.silent;var o=[];var h=this._changing;this._changing=true;if(!h){this._previousAttributes=i.clone(this.attributes);this.changed={}}var u=this.attributes;var l=this.changed;var c=this._previousAttributes;for(var f in n){e=n[f];if(!i.isEqual(u[f],e))o.push(f);if(!i.isEqual(c[f],e)){l[f]=e}else{delete l[f]}s?delete u[f]:u[f]=e}this.id=this.get(this.idAttribute);if(!a){if(o.length)this._pending=r;for(var d=0;d<o.length;d++){this.trigger("change:"+o[d],this,u[o[d]],r)}}if(h)return this;if(!a){while(this._pending){r=this._pending;this._pending=false;this.trigger("change",this,r)}}this._pending=false;this._changing=false;return this},unset:function(t,e){return this.set(t,void 0,i.extend({},e,{unset:true}))},clear:function(t){var e={};for(var r in this.attributes)e[r]=void 0;return this.set(e,i.extend({},t,{unset:true}))},hasChanged:function(t){if(t==null)return!i.isEmpty(this.changed);return i.has(this.changed,t)},changedAttributes:function(t){if(!t)return this.hasChanged()?i.clone(this.changed):false;var e=this._changing?this._previousAttributes:this.attributes;var r={};for(var n in t){var s=t[n];if(i.isEqual(e[n],s))continue;r[n]=s}return i.size(r)?r:false},previous:function(t){if(t==null||!this._previousAttributes)return null;return this._previousAttributes[t]},previousAttributes:function(){return i.clone(this._previousAttributes)},fetch:function(t){t=i.extend({parse:true},t);var e=this;var r=t.success;t.success=function(i){var n=t.parse?e.parse(i,t):i;if(!e.set(n,t))return false;if(r)r.call(t.context,e,i,t);e.trigger("sync",e,i,t)};z(this,t);return this.sync("read",this,t)},save:function(t,e,r){var n;if(t==null||typeof t==="object"){n=t;r=e}else{(n={})[t]=e}r=i.extend({validate:true,parse:true},r);var s=r.wait;if(n&&!s){if(!this.set(n,r))return false}else{if(!this._validate(n,r))return false}var a=this;var o=r.success;var h=this.attributes;r.success=function(t){a.attributes=h;var e=r.parse?a.parse(t,r):t;if(s)e=i.extend({},n,e);if(e&&!a.set(e,r))return false;if(o)o.call(r.context,a,t,r);a.trigger("sync",a,t,r)};z(this,r);if(n&&s)this.attributes=i.extend({},h,n);var u=this.isNew()?"create":r.patch?"patch":"update";if(u==="patch"&&!r.attrs)r.attrs=n;var l=this.sync(u,this,r);this.attributes=h;return l},destroy:function(t){t=t?i.clone(t):{};var e=this;var r=t.success;var n=t.wait;var s=function(){e.stopListening();e.trigger("destroy",e,e.collection,t)};t.success=function(i){if(n)s();if(r)r.call(t.context,e,i,t);if(!e.isNew())e.trigger("sync",e,i,t)};var a=false;if(this.isNew()){i.defer(t.success)}else{z(this,t);a=this.sync("delete",this,t)}if(!n)s();return a},url:function(){var t=i.result(this,"urlRoot")||i.result(this.collection,"url")||F();if(this.isNew())return t;var e=this.get(this.idAttribute);return t.replace(/[^\/]$/,"$&/")+encodeURIComponent(e)},parse:function(t,e){return t},clone:function(){return new this.constructor(this.attributes)},isNew:function(){return!this.has(this.idAttribute)},isValid:function(t){return this._validate({},i.defaults({validate:true},t))},_validate:function(t,e){if(!e.validate||!this.validate)return true;t=i.extend({},this.attributes,t);var r=this.validationError=this.validate(t,e)||null;if(!r)return true;this.trigger("invalid",this,r,i.extend(e,{validationError:r}));return false}});var b={keys:1,values:1,pairs:1,invert:1,pick:0,omit:0,chain:1,isEmpty:1};o(y,b,"attributes");var x=e.Collection=function(t,e){e||(e={});if(e.model)this.model=e.model;if(e.comparator!==void 0)this.comparator=e.comparator;this._reset();this.initialize.apply(this,arguments);if(t)this.reset(t,i.extend({silent:true},e))};var w={add:true,remove:true,merge:true};var E={add:true,remove:false};var k=function(t,e,i){i=Math.min(Math.max(i,0),t.length);var r=Array(t.length-i);var n=e.length;for(var s=0;s<r.length;s++)r[s]=t[s+i];for(s=0;s<n;s++)t[s+i]=e[s];for(s=0;s<r.length;s++)t[s+n+i]=r[s]};i.extend(x.prototype,l,{model:y,initialize:function(){},toJSON:function(t){return this.map(function(e){return e.toJSON(t)})},sync:function(){return e.sync.apply(this,arguments)},add:function(t,e){return this.set(t,i.extend({merge:false},e,E))},remove:function(t,e){e=i.extend({},e);var r=!i.isArray(t);t=r?[t]:i.clone(t);var n=this._removeModels(t,e);if(!e.silent&&n)this.trigger("update",this,e);return r?n[0]:n},set:function(t,e){if(t==null)return;e=i.defaults({},e,w);if(e.parse&&!this._isModel(t))t=this.parse(t,e);var r=!i.isArray(t);t=r?[t]:t.slice();var n=e.at;if(n!=null)n=+n;if(n<0)n+=this.length+1;var s=[];var a=[];var o=[];var h={};var u=e.add;var l=e.merge;var c=e.remove;var f=false;var d=this.comparator&&n==null&&e.sort!==false;var v=i.isString(this.comparator)?this.comparator:null;var g;for(var p=0;p<t.length;p++){g=t[p];var m=this.get(g);if(m){if(l&&g!==m){var _=this._isModel(g)?g.attributes:g;if(e.parse)_=m.parse(_,e);m.set(_,e);if(d&&!f)f=m.hasChanged(v)}if(!h[m.cid]){h[m.cid]=true;s.push(m)}t[p]=m}else if(u){g=t[p]=this._prepareModel(g,e);if(g){a.push(g);this._addReference(g,e);h[g.cid]=true;s.push(g)}}}if(c){for(p=0;p<this.length;p++){g=this.models[p];if(!h[g.cid])o.push(g)}if(o.length)this._removeModels(o,e)}var y=false;var b=!d&&u&&c;if(s.length&&b){y=this.length!=s.length||i.some(this.models,function(t,e){return t!==s[e]});this.models.length=0;k(this.models,s,0);this.length=this.models.length}else if(a.length){if(d)f=true;k(this.models,a,n==null?this.length:n);this.length=this.models.length}if(f)this.sort({silent:true});if(!e.silent){for(p=0;p<a.length;p++){if(n!=null)e.index=n+p;g=a[p];g.trigger("add",g,this,e)}if(f||y)this.trigger("sort",this,e);if(a.length||o.length)this.trigger("update",this,e)}return r?t[0]:t},reset:function(t,e){e=e?i.clone(e):{};for(var r=0;r<this.models.length;r++){this._removeReference(this.models[r],e)}e.previousModels=this.models;this._reset();t=this.add(t,i.extend({silent:true},e));if(!e.silent)this.trigger("reset",this,e);return t},push:function(t,e){return this.add(t,i.extend({at:this.length},e))},pop:function(t){var e=this.at(this.length-1);return this.remove(e,t)},unshift:function(t,e){return this.add(t,i.extend({at:0},e))},shift:function(t){var e=this.at(0);return this.remove(e,t)},slice:function(){return s.apply(this.models,arguments)},get:function(t){if(t==null)return void 0;var e=this.modelId(this._isModel(t)?t.attributes:t);return this._byId[t]||this._byId[e]||this._byId[t.cid]},at:function(t){if(t<0)t+=this.length;return this.models[t]},where:function(t,e){return this[e?"find":"filter"](t)},findWhere:function(t){return this.where(t,true)},sort:function(t){var e=this.comparator;if(!e)throw new Error("Cannot sort a set without a comparator");t||(t={});var r=e.length;if(i.isFunction(e))e=i.bind(e,this);if(r===1||i.isString(e)){this.models=this.sortBy(e)}else{this.models.sort(e)}if(!t.silent)this.trigger("sort",this,t);return this},pluck:function(t){return i.invoke(this.models,"get",t)},fetch:function(t){t=i.extend({parse:true},t);var e=t.success;var r=this;t.success=function(i){var n=t.reset?"reset":"set";r[n](i,t);if(e)e.call(t.context,r,i,t);r.trigger("sync",r,i,t)};z(this,t);return this.sync("read",this,t)},create:function(t,e){e=e?i.clone(e):{};var r=e.wait;t=this._prepareModel(t,e);if(!t)return false;if(!r)this.add(t,e);var n=this;var s=e.success;
24e.success=function(t,e,i){if(r)n.add(t,i);if(s)s.call(i.context,t,e,i)};t.save(null,e);return t},parse:function(t,e){return t},clone:function(){return new this.constructor(this.models,{model:this.model,comparator:this.comparator})},modelId:function(t){return t[this.model.prototype.idAttribute||"id"]},_reset:function(){this.length=0;this.models=[];this._byId={}},_prepareModel:function(t,e){if(this._isModel(t)){if(!t.collection)t.collection=this;return t}e=e?i.clone(e):{};e.collection=this;var r=new this.model(t,e);if(!r.validationError)return r;this.trigger("invalid",this,r.validationError,e);return false},_removeModels:function(t,e){var i=[];for(var r=0;r<t.length;r++){var n=this.get(t[r]);if(!n)continue;var s=this.indexOf(n);this.models.splice(s,1);this.length--;if(!e.silent){e.index=s;n.trigger("remove",n,this,e)}i.push(n);this._removeReference(n,e)}return i.length?i:false},_isModel:function(t){return t instanceof y},_addReference:function(t,e){this._byId[t.cid]=t;var i=this.modelId(t.attributes);if(i!=null)this._byId[i]=t;t.on("all",this._onModelEvent,this)},_removeReference:function(t,e){delete this._byId[t.cid];var i=this.modelId(t.attributes);if(i!=null)delete this._byId[i];if(this===t.collection)delete t.collection;t.off("all",this._onModelEvent,this)},_onModelEvent:function(t,e,i,r){if((t==="add"||t==="remove")&&i!==this)return;if(t==="destroy")this.remove(e,r);if(t==="change"){var n=this.modelId(e.previousAttributes());var s=this.modelId(e.attributes);if(n!==s){if(n!=null)delete this._byId[n];if(s!=null)this._byId[s]=e}}this.trigger.apply(this,arguments)}});var S={forEach:3,each:3,map:3,collect:3,reduce:4,foldl:4,inject:4,reduceRight:4,foldr:4,find:3,detect:3,filter:3,select:3,reject:3,every:3,all:3,some:3,any:3,include:3,includes:3,contains:3,invoke:0,max:3,min:3,toArray:1,size:1,first:3,head:3,take:3,initial:3,rest:3,tail:3,drop:3,last:3,without:0,difference:0,indexOf:3,shuffle:1,lastIndexOf:3,isEmpty:1,chain:1,sample:3,partition:3,groupBy:3,countBy:3,sortBy:3,indexBy:3};o(x,S,"models");var I=e.View=function(t){this.cid=i.uniqueId("view");i.extend(this,i.pick(t,P));this._ensureElement();this.initialize.apply(this,arguments)};var T=/^(\S+)\s*(.*)$/;var P=["model","collection","el","id","attributes","className","tagName","events"];i.extend(I.prototype,l,{tagName:"div",$:function(t){return this.$el.find(t)},initialize:function(){},render:function(){return this},remove:function(){this._removeElement();this.stopListening();return this},_removeElement:function(){this.$el.remove()},setElement:function(t){this.undelegateEvents();this._setElement(t);this.delegateEvents();return this},_setElement:function(t){this.$el=t instanceof e.$?t:e.$(t);this.el=this.$el[0]},delegateEvents:function(t){t||(t=i.result(this,"events"));if(!t)return this;this.undelegateEvents();for(var e in t){var r=t[e];if(!i.isFunction(r))r=this[r];if(!r)continue;var n=e.match(T);this.delegate(n[1],n[2],i.bind(r,this))}return this},delegate:function(t,e,i){this.$el.on(t+".delegateEvents"+this.cid,e,i);return this},undelegateEvents:function(){if(this.$el)this.$el.off(".delegateEvents"+this.cid);return this},undelegate:function(t,e,i){this.$el.off(t+".delegateEvents"+this.cid,e,i);return this},_createElement:function(t){return document.createElement(t)},_ensureElement:function(){if(!this.el){var t=i.extend({},i.result(this,"attributes"));if(this.id)t.id=i.result(this,"id");if(this.className)t["class"]=i.result(this,"className");this.setElement(this._createElement(i.result(this,"tagName")));this._setAttributes(t)}else{this.setElement(i.result(this,"el"))}},_setAttributes:function(t){this.$el.attr(t)}});e.sync=function(t,r,n){var s=H[t];i.defaults(n||(n={}),{emulateHTTP:e.emulateHTTP,emulateJSON:e.emulateJSON});var a={type:s,dataType:"json"};if(!n.url){a.url=i.result(r,"url")||F()}if(n.data==null&&r&&(t==="create"||t==="update"||t==="patch")){a.contentType="application/json";a.data=JSON.stringify(n.attrs||r.toJSON(n))}if(n.emulateJSON){a.contentType="application/x-www-form-urlencoded";a.data=a.data?{model:a.data}:{}}if(n.emulateHTTP&&(s==="PUT"||s==="DELETE"||s==="PATCH")){a.type="POST";if(n.emulateJSON)a.data._method=s;var o=n.beforeSend;n.beforeSend=function(t){t.setRequestHeader("X-HTTP-Method-Override",s);if(o)return o.apply(this,arguments)}}
vendor: 5,799 bytes, line 24
24if(a.type!=="GET"&&!n.emulateJSON){a.processData=false}var h=n.error;n.error=function(t,e,i){n.textStatus=e;n.errorThrown=i;if(h)h.call(n.context,t,e,i)};var u=n.xhr=e.ajax(i.extend(a,n));r.trigger("request",r,u,n);return u};var H={create:"POST",update:"PUT",patch:"PATCH","delete":"DELETE",read:"GET"};e.ajax=function(){return e.$.ajax.apply(e.$,arguments)};var $=e.Router=function(t){t||(t={});if(t.routes)this.routes=t.routes;this._bindRoutes();this.initialize.apply(this,arguments)};var A=/\((.*?)\)/g;var C=/(\(\?)?:\w+/g;var R=/\*\w+/g;var j=/[\-{}\[\]+?.,\\\^$|#\s]/g;i.extend($.prototype,l,{initialize:function(){},route:function(t,r,n){if(!i.isRegExp(t))t=this._routeToRegExp(t);if(i.isFunction(r)){n=r;r=""}if(!n)n=this[r];var s=this;e.history.route(t,function(i){var a=s._extractParameters(t,i);if(s.execute(n,a,r)!==false){s.trigger.apply(s,["route:"+r].concat(a));s.trigger("route",r,a);e.history.trigger("route",s,r,a)}});return this},execute:function(t,e,i){if(t)t.apply(this,e)},navigate:function(t,i){e.history.navigate(t,i);return this},_bindRoutes:function(){if(!this.routes)return;this.routes=i.result(this,"routes");var t,e=i.keys(this.routes);while((t=e.pop())!=null){this.route(t,this.routes[t])}},_routeToRegExp:function(t){t=t.replace(j,"\\$&").replace(A,"(?:$1)?").replace(C,function(t,e){return e?t:"([^/?]+)"}).replace(R,"([^?]*?)");return new RegExp("^"+t+"(?:\\?([\\s\\S]*))?$")},_extractParameters:function(t,e){var r=t.exec(e).slice(1);return i.map(r,function(t,e){if(e===r.length-1)return t||null;return t?decodeURIComponent(t):null})}});var M=e.History=function(){this.handlers=[];this.checkUrl=i.bind(this.checkUrl,this);if(typeof window!=="undefined"){this.location=window.location;this.history=window.history}};var N=/^[#\/]|\s+$/g;var O=/^\/+|\/+$/g;var U=/#.*$/;M.started=false;i.extend(M.prototype,l,{interval:50,atRoot:function(){var t=this.location.pathname.replace(/[^\/]$/,"$&/");return t===this.root&&!this.getSearch()},matchRoot:function(){var t=this.decodeFragment(this.location.pathname);var e=t.slice(0,this.root.length-1)+"/";return e===this.root},decodeFragment:function(t){return decodeURI(t.replace(/%25/g,"%2525"))},getSearch:function(){var t=this.location.href.replace(/#.*/,"").match(/\?.+/);return t?t[0]:""},getHash:function(t){var e=(t||this).location.href.match(/#(.*)$/);return e?e[1]:""},getPath:function(){var t=this.decodeFragment(this.location.pathname+this.getSearch()).slice(this.root.length-1);return t.charAt(0)==="/"?t.slice(1):t},getFragment:function(t){if(t==null){if(this._usePushState||!this._wantsHashChange){t=this.getPath()}else{t=this.getHash()}}return t.replace(N,"")},start:function(t){if(M.started)throw new Error("Backbone.history has already been started");M.started=true;this.options=i.extend({root:"/"},this.options,t);this.root=this.options.root;this._wantsHashChange=this.options.hashChange!==false;this._hasHashChange="onhashchange"in window&&(document.documentMode===void 0||document.documentMode>7);this._useHashChange=this._wantsHashChange&&this._hasHashChange;this._wantsPushState=!!this.options.pushState;this._hasPushState=!!(this.history&&this.history.pushState);this._usePushState=this._wantsPushState&&this._hasPushState;this.fragment=this.getFragment();this.root=("/"+this.root+"/").replace(O,"/");if(this._wantsHashChange&&this._wantsPushState){if(!this._hasPushState&&!this.atRoot()){var e=this.root.slice(0,-1)||"/";this.location.replace(e+"#"+this.getPath());return true}else if(this._hasPushState&&this.atRoot()){this.navigate(this.getHash(),{replace:true})}}if(!this._hasHashChange&&this._wantsHashChange&&!this._usePushState){this.iframe=document.createElement("iframe");this.iframe.src="javascript:0";this.iframe.style.display="none";this.iframe.tabIndex=-1;var r=document.body;var n=r.insertBefore(this.iframe,r.firstChild).contentWindow;n.document.open();n.document.close();n.location.hash="#"+this.fragment}var s=window.addEventListener||function(t,e){return attachEvent("on"+t,e)};if(this._usePushState){s("popstate",this.checkUrl,false)}else if(this._useHashChange&&!this.iframe){s("hashchange",this.checkUrl,false)}else if(this._wantsHashChange){this._checkUrlInterval=setInterval(this.checkUrl,this.interval)}if(!this.options.silent)return this.loadUrl()},stop:function(){var t=window.removeEventListener||function(t,e){return detachEvent("on"+t,e)};if(this._usePushState){t("popstate",this.checkUrl,false)}else if(this._useHashChange&&!this.iframe){t("hashchange",this.checkUrl,false)}if(this.iframe){document.body.removeChild(this.iframe);this.iframe=null}if(this._checkUrlInterval)clearInterval(this._checkUrlInterval);M.started=false},route:function(t,e){this.handlers.unshift({route:t,callback:e})},checkUrl:function(t){var e=this.getFragment();if(e===this.fragment&&this.iframe){e=this.getHash(this.iframe.contentWindow)}if(e===this.fragment)return false;if(this.iframe)this.navigate(e);this.loadUrl()},loadUrl:function(t){if(!this.matchRoot())return false;t=this.fragment=this.getFragment(t);return i.some(this.handlers,function(e){if(e.route.test(t)){e.callback(t);return true}})},navigate:function(t,e){if(!M.started)return false;if(!e||e===true)e={trigger:!!e};t=this.getFragment(t||"");var i=this.root;if(t===""||t.charAt(0)==="?"){i=i.slice(0,-1)||"/"}var r=i+t;t=this.decodeFragment(t.replace(U,""));if(this.fragment===t)return;this.fragment=t;if(this._usePushState){this.history[e.replace?"replaceState":"pushState"]({},document.title,r)}else if(this._wantsHashChange){this._updateHash(this.location,t,e.replace);if(this.iframe&&t!==this.getHash(this.iframe.contentWindow)){var n=this.iframe.contentWindow;if(!e.replace){n.document.open();n.document.close()}this._updateHash(n.location,t,e.replace)}}else{return this.location.assign(r)}if(e.trigger)return this.loadUrl(t)}
24,_updateHash:function(t,e,i){if(i){var r=t.href.replace(/(javascript:|#).*$/,"");t.replace(r+"#"+e)}else{t.hash="#"+e}}});e.history=new M;var q=function(t,e){var r=this;var n;if(t&&i.has(t,"constructor")){n=t.constructor}else{n=function(){return r.apply(this,arguments)}}i.extend(n,r,e);var s=function(){this.constructor=n};s.prototype=r.prototype;n.prototype=new s;if(t)i.extend(n.prototype,t);n.__super__=r.prototype;return n};y.extend=x.extend=$.extend=I.extend=M.extend=q;var F=function(){throw new Error('A "url" property or function must be specified')};var z=function(t,e){var i=e.error;e.error=function(r){if(i)i.call(e.context,t,r,e);t.trigger("error",t,r,e)}};return e});
25
26/**
27* DO NOT EDIT THIS FILE.
28* See the following change record for more information,
29* https://www.drupal.org/node/2815083
30* @preserve
31**/
32
33(function () {
34  var settingsElement = document.querySelector('head > script[type="application/json"][data-drupal-selector="drupal-settings-json"], body > script[type="application/json"][data-drupal-selector="drupal-settings-json"]');
35
36  window.drupalSettings = {};
37
38  if (settingsElement !== null) {
39    window.drupalSettings = JSON.parse(settingsElement.textContent);
40  }
41})();;
42/**
43* DO NOT EDIT THIS FILE.
44* See the following change record for more information,
45* https://www.drupal.org/node/2815083
46* @preserve
47**/
48
49window.Drupal = { behaviors: {}, locale: {} };
50
51(function (Drupal, drupalSettings, drupalTranslations) {
52  Drupal.throwError = function (error) {
53    setTimeout(function () {
54      throw error;
55    }, 0);
56  };
57
58  Drupal.attachBehaviors = function (context, settings) {
59    context = context || document;
60    settings = settings || drupalSettings;
61    var behaviors = Drupal.behaviors;
62
63    for (var i in behaviors) {
64      if (behaviors.hasOwnProperty(i) && typeof behaviors[i].attach === 'function') {
65        try {
66          behaviors[i].attach(context, settings);
67        } catch (e) {
68          Drupal.throwError(e);
69        }
70      }
71    }
72  };
73
74  Drupal.detachBehaviors = function (context, settings, trigger) {
75    context = context || document;
76    settings = settings || drupalSettings;
77    trigger = trigger || 'unload';
78    var behaviors = Drupal.behaviors;
79
80    for (var i in behaviors) {
81      if (behaviors.hasOwnProperty(i) && typeof behaviors[i].detach === 'function') {
82        try {
83          behaviors[i].detach(context, settings, trigger);
84        } catch (e) {
85          Drupal.throwError(e);
86        }
87      }
88    }
89  };
90
91  Drupal.checkPlain = function (str) {
92    str = str.toString().replace(/&/g, '&amp;').replace(/"/g, '&quot;').replace(/</g, '&lt;').replace(/>/g, '&gt;');
93    return str;
94  };
95
96  Drupal.formatString = function (str, args) {
97    var processedArgs = {};
98
99    for (var key in args) {
100      if (args.hasOwnProperty(key)) {
101        switch (key.charAt(0)) {
102          case '@':
103            processedArgs[key] = Drupal.checkPlain(args[key]);
104            break;
105
106          case '!':
107            processedArgs[key] = args[key];
108            break;
109
110          default:
111            processedArgs[key] = Drupal.theme('placeholder', args[key]);
112            break;
113        }
114      }
115    }
116
117    return Drupal.stringReplace(str, processedArgs, null);
118  };
119
120  Drupal.stringReplace = function (str, args, keys) {
121    if (str.length === 0) {
122      return str;
123    }
124
125    if (!Array.isArray(keys)) {
126      keys = [];
127      for (var k in args) {
128        if (args.hasOwnProperty(k)) {
129          keys.push(k);
130        }
131      }
132
133      keys.sort(function (a, b) {
134        return a.length - b.length;
135      });
136    }
137
138    if (keys.length === 0) {
139      return str;
140    }
141
142    var key = keys.pop();
143    var fragments = str.split(key);
144
145    if (keys.length) {
146      for (var i = 0; i < fragments.length; i++) {
147        fragments[i] = Drupal.stringReplace(fragments[i], args, keys.slice(0));
148      }
149    }
150
151    return fragments.join(args[key]);
152  };
153
154  Drupal.t = function (str, args, options) {
155    options = options || {};
156    options.context = options.context || '';
157
158    if (typeof drupalTranslations !== 'undefined' && drupalTranslations.strings && drupalTranslations.strings[options.context] && drupalTranslations.strings[options.context][str]) {
159      str = drupalTranslations.strings[options.context][str];
160    }
161
162    if (args) {
163      str = Drupal.formatString(str, args);
164    }
165    return str;
166  };
167
168  Drupal.url = function (path) {
169    return drupalSettings.path.baseUrl + drupalSettings.path.pathPrefix + path;
170  };
171
172  Drupal.url.toAbsolute = function (url) {
173    var urlParsingNode = document.createElement('a');
174
175    try {
176      url = decodeURIComponent(url);
177    } catch (e) {}
178
179    urlParsingNode.setAttribute('href', url);
180
181    return urlParsingNode.cloneNode(false).href;
182  };
183
184  Drupal.url.isLocal = function (url) {
185    var absoluteUrl = Drupal.url.toAbsolute(url);
186    var protocol = location.protocol;
187
188    if (protocol === 'http:' && absoluteUrl.indexOf('https:') === 0) {
189      protocol = 'https:';
190    }
191    var baseUrl = protocol + '//' + location.host + drupalSettings.path.baseUrl.slice(0, -1);
192
193    try {
194      absoluteUrl = decodeURIComponent(absoluteUrl);
195    } catch (e) {}
196    try {
197      baseUrl = decodeURIComponent(baseUrl);
198    } catch (e) {}
199
200    return absoluteUrl === baseUrl || absoluteUrl.indexOf(baseUrl + '/') === 0;
201  };
202
203  Drupal.formatPlural = function (count, singular, plural, args, options) {
204    args = args || {};
205    args['@count'] = count;
206
207    var pluralDelimiter = drupalSettings.pluralDelimiter;
208    var translations = Drupal.t(singular + pluralDelimiter + plural, args, options).split(pluralDelimiter);
209    var index = 0;
210
211    if (typeof drupalTranslations !== 'undefined' && drupalTranslations.pluralFormula) {
212      index = count in drupalTranslations.pluralFormula ? drupalTranslations.pluralFormula[count] : drupalTranslations.pluralFormula.default;
213    } else if (args['@count'] !== 1) {
214      index = 1;
215    }
216
217    return translations[index];
218  };
219
220  Drupal.encodePath = function (item) {
221    return window.encodeURIComponent(item).replace(/%2F/g, '/');
222  };
223
224  Drupal.theme = function (func) {
225    var args = Array.prototype.slice.apply(arguments, [1]);
226    if (func in Drupal.theme) {
227      return Drupal.theme[func].apply(this, args);
228    }
229  };
230
231  Drupal.theme.placeholder = function (str) {
232    return '<em class="placeholder">' + Drupal.checkPlain(str) + '</em>';
233  };
234})(Drupal, window.drupalSettings, window.drupalTranslations);;
235/**
236* DO NOT EDIT THIS FILE.
237* See the following change record for more information,
238* https://www.drupal.org/node/2815083
239* @preserve
240**/
241
242if (window.jQuery) {
243  jQuery.noConflict();
244}
245
246document.documentElement.className += ' js';
247
248(function (domready, Drupal, drupalSettings) {
249  domready(function () {
250    Drupal.attachBehaviors(document, drupalSettings);
251  });
252})(domready, Drupal, window.drupalSettings);;
vendor: 4,348 bytes, lines 253-284
253/*! jQuery UI - v1.12.1 - 2017-03-31
254* http://jqueryui.com
255* Copyright jQuery Foundation and other contributors; Licensed  */
256!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.extend(a.expr[":"],{data:a.expr.createPseudo?a.expr.createPseudo(function(b){return function(c){return!!a.data(c,b)}}):function(b,c,d){return!!a.data(b,d[3])}})});;
257/*! jQuery UI - v1.12.1 - 2017-03-31
258* http://jqueryui.com
259* Copyright jQuery Foundation and other contributors; Licensed  */
260!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.fn.extend({disableSelection:function(){var a="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(a+".ui-disableSelection",function(a){a.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}})});;
261/*! jQuery UI - v1.12.1 - 2017-03-31
262* http://jqueryui.com
263* Copyright jQuery Foundation and other contributors; Licensed  */
264!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):a(this[0].form)}});;
265/*! jQuery UI - v1.12.1 - 2017-03-31
266* http://jqueryui.com
267* Copyright jQuery Foundation and other contributors; Licensed  */
268!function(a){"function"==typeof define&&define.amd?define(["jquery","./version","./escape-selector"],a):a(jQuery)}(function(a){return a.fn.labels=function(){var b,c,d,e,f;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(e=this.eq(0).parents("label"),d=this.attr("id"),d&&(b=this.eq(0).parents().last(),f=b.add(b.length?b.siblings():this.siblings()),c="label[for='"+a.ui.escapeSelector(d)+"']",e=e.add(f.find(c).addBack(c))),this.pushStack(e))}});;
269/*! jQuery UI - v1.12.1 - 2017-03-31
270* http://jqueryui.com
271* Copyright jQuery Foundation and other contributors; Licensed  */
272!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){"1.7"===a.fn.jquery.substring(0,3)&&(a.each(["Width","Height"],function(b,c){function d(b,c,d,f){return a.each(e,function(){c-=parseFloat(a.css(b,"padding"+this))||0,d&&(c-=parseFloat(a.css(b,"border"+this+"Width"))||0),f&&(c-=parseFloat(a.css(b,"margin"+this))||0)}),c}var e="Width"===c?["Left","Right"]:["Top","Bottom"],f=c.toLowerCase(),g={innerWidth:a.fn.innerWidth,innerHeight:a.fn.innerHeight,outerWidth:a.fn.outerWidth,outerHeight:a.fn.outerHeight};a.fn["inner"+c]=function(b){return void 0===b?g["inner"+c].call(this):this.each(function(){a(this).css(f,d(this,b)+"px")})},a.fn["outer"+c]=function(b,e){return"number"!=typeof b?g["outer"+c].call(this,b):this.each(function(){a(this).css(f,d(this,b,!0,e)+"px")})}}),a.fn.addBack=function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))})});;
273/*! jQuery UI - v1.12.1 - 2017-03-31
274* http://jqueryui.com
275* Copyright jQuery Foundation and other contributors; Licensed  */
276!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.fn.scrollParent=function(b){var c=this.css("position"),d="absolute"===c,e=b?/(auto|scroll|hidden)/:/(auto|scroll)/,f=this.parents().filter(function(){var b=a(this);return(!d||"static"!==b.css("position"))&&e.test(b.css("overflow")+b.css("overflow-y")+b.css("overflow-x"))}).eq(0);return"fixed"!==c&&f.length?f:a(this[0].ownerDocument||document)}});;
277/*! jQuery UI - v1.12.1 - 2017-03-31
278* http://jqueryui.com
279* Copyright jQuery Foundation and other contributors; Licensed  */
280!function(a){"function"==typeof define&&define.amd?define(["jquery","./version","./focusable"],a):a(jQuery)}(function(a){return a.extend(a.expr[":"],{tabbable:function(b){var c=a.attr(b,"tabindex"),d=null!=c;return(!d||c>=0)&&a.ui.focusable(b,d)}})});;
281/*! jQuery UI - v1.12.1 - 2017-03-31
282* http://jqueryui.com
283* Copyright jQuery Foundation and other contributors; Licensed  */
284!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.fn.extend({uniqueId:function(){var a=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++a)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id
284)&&a(this).removeAttr("id")})}})});;
285/*! jQuery UI - v1.12.1 - 2017-03-31
286* http://jqueryui.com
287* Copyright jQuery Foundation and other contributors; Licensed  */
288!function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a(jQuery)}(function(a){return a.ui=a.ui||{},a.ui.version="1.12.1"});;
289/*! jQuery UI - v1.12.1 - 2017-03-31
290* http://jqueryui.com
291* Copyright jQuery Foundation and other contributors; Licensed  */
292!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){function b(a){for(var b=a.css("visibility");"inherit"===b;)a=a.parent(),b=a.css("visibility");return"hidden"!==b}return a.ui.focusable=function(c,d){var e,f,g,h,i,j=c.nodeName.toLowerCase();return"area"===j?(e=c.parentNode,f=e.name,!(!c.href||!f||"map"!==e.nodeName.toLowerCase())&&(g=a("img[usemap='#"+f+"']"),g.length>0&&g.is(":visible"))):(/^(input|select|textarea|button|object)$/.test(j)?(h=!c.disabled,h&&(i=a(c).closest("fieldset")[0],i&&(h=!i.disabled))):h="a"===j?c.href||d:d,h&&a(c).is(":visible")&&b(a(c)))},a.extend(a.expr[":"],{focusable:function(b){return a.ui.focusable(b,null!=a.attr(b,"tabindex"))}}),a.ui.focusable});;
293/*! jQuery UI - v1.12.1 - 2017-03-31
294* http://jqueryui.com
295* Copyright jQuery Foundation and other contributors; Licensed  */
296!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase())});;
297/*! jQuery UI - v1.12.1 - 2017-03-31
298* http://jqueryui.com
299* Copyright jQuery Foundation and other contributors; Licensed  */
300!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}});;
301/*! jQuery UI - v1.12.1 - 2017-03-31
302* http://jqueryui.com
303* Copyright jQuery Foundation and other contributors; Licensed  */
304!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.ui.plugin={add:function(b,c,d){var e,f=a.ui[b].prototype;for(e in d)f.plugins[e]=f.plugins[e]||[],f.plugins[e].push([c,d[e]])},call:function(a,b,c,d){var e,f=a.plugins[b];if(f&&(d||a.element[0].parentNode&&11!==a.element[0].parentNode.nodeType))for(e=0;e<f.length;e++)a.options[f[e][0]]&&f[e][1].apply(a.element,c)}}});;
305/*! jQuery UI - v1.12.1 - 2017-03-31
306* http://jqueryui.com
307* Copyright jQuery Foundation and other contributors; Licensed  */
308!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.ui.safeActiveElement=function(a){var b;try{b=a.activeElement}catch(c){b=a.body}return b||(b=a.body),b.nodeName||(b=a.body),b}});;
309/*! jQuery UI - v1.12.1 - 2017-03-31
310* http://jqueryui.com
311* Copyright jQuery Foundation and other contributors; Licensed  */
312!function(a){"function"==typeof define&&define.amd?define(["jquery","./version"],a):a(jQuery)}(function(a){return a.ui.safeBlur=function(b){b&&"body"!==b.nodeName.toLowerCase()&&a(b).trigger("blur")}});;
313/**
314 * @file
315 * Attaches several event listener to a web page.
316 */
317
318(function ($, Drupal, drupalSettings) {
319
320  "use strict";
321
322  Drupal.google_analytics = {};
323
324  $(document).ready(function () {
325
326    // Attach mousedown, keyup, touchstart events to document only and catch
327    // clicks on all elements.
328    $(document.body).on("mousedown keyup touchstart", function (event) {
329
330      // Catch the closest surrounding link of a clicked element.
331      $(event.target).closest("a,area").each(function () {
332
333        // Is the clicked URL internal?
334        if (Drupal.google_analytics.isInternal(this.href)) {
335          // Skip 'click' tracking, if custom tracking events are bound.
336          if ($(this).is('.colorbox') && (drupalSettings.google_analytics.trackColorbox)) {
337            // Do nothing here. The custom event will handle all tracking.
338            // console.info("Click on .colorbox item has been detected.");
339          }
340          // Is download tracking activated and the file extension configured
341          // for download tracking?
342          else if (drupalSettings.google_analytics.trackDownload && Drupal.google_analytics.isDownload(this.href)) {
343            // Download link clicked.
344            ga("send", {
345              "hitType": "event",
346              "eventCategory": "Downloads",
347              "eventAction": Drupal.google_analytics.getDownloadExtension(this.href).toUpperCase(),
348              "eventLabel": Drupal.google_analytics.getPageUrl(this.href),
349              "transport": "beacon"
350            });
351          }
352          else if (Drupal.google_analytics.isInternalSpecial(this.href)) {
353            // Keep the internal URL for Google Analytics website overlay intact.
354            ga("send", {
355              "hitType": "pageview",
356              "page": Drupal.google_analytics.getPageUrl(this.href),
357              "transport": "beacon"
358            });
359          }
360        }
361        else {
362          if (drupalSettings.google_analytics.trackMailto && $(this).is("a[href^='mailto:'],area[href^='mailto:']")) {
363            // Mailto link clicked.
364            ga("send", {
365              "hitType": "event",
366              "eventCategory": "Mails",
367              "eventAction": "Click",
368              "eventLabel": this.href.substring(7),
369              "transport": "beacon"
370            });
371          }
372          else if (drupalSettings.google_analytics.trackOutbound && this.href.match(/^\w+:\/\//i)) {
373            if (drupalSettings.google_analytics.trackDomainMode !== 2 || (drupalSettings.google_analytics.trackDomainMode === 2 && !Drupal.google_analytics.isCrossDomain(this.hostname, drupalSettings.google_analytics.trackCrossDomains))) {
374              // External link clicked / No top-level cross domain clicked.
375              ga("send", {
376                "hitType": "event",
377                "eventCategory": "Outbound links",
378                "eventAction": "Click",
379                "eventLabel": this.href,
380                "transport": "beacon"
381              });
382            }
383          }
384        }
385      });
386    });
387
388    // Track hash changes as unique pageviews, if this option has been enabled.
389    if (drupalSettings.google_analytics.trackUrlFragments) {
390      window.onhashchange = function () {
391        ga("send", {
392          "hitType": "pageview",
393          "page": location.pathname + location.search + location.hash
394        });
395      };
396    }
397
398    // Colorbox: This event triggers when the transition has completed and the
399    // newly loaded content has been revealed.
400    if (drupalSettings.google_analytics.trackColorbox) {
401      $(document).on("cbox_complete", function () {
402        var href = $.colorbox.element().attr("href");
403        if (href) {
404          ga("send", {
405            "hitType": "pageview",
406            "page": Drupal.google_analytics.getPageUrl(href)
407          });
408        }
409      });
410    }
411
412  });
413
414  /**
415   * Check whether the hostname is part of the cross domains or not.
416   *
417   * @param {string} hostname
418   *   The hostname of the clicked URL.
419   * @param {array} crossDomains
420   *   All cross domain hostnames as JS array.
421   *
422   * @return {boolean} isCrossDomain
423   */
424  Drupal.google_analytics.isCrossDomain = function (hostname, crossDomains) {
425    return $.inArray(hostname, crossDomains) > -1 ? true : false;
426  };
427
428  /**
429   * Check whether this is a download URL or not.
430   *
431   * @param {string} url
432   *   The web url to check.
433   *
434   * @return {boolean} isDownload
435   */
436  Drupal.google_analytics.isDownload = function (url) {
437    var isDownload = new RegExp("\\.(" + drupalSettings.google_analytics.trackDownloadExtensions + ")([\?#].*)?$", "i");
438    return isDownload.test(url);
439  };
440
441  /**
442   * Check whether this is an absolute internal URL or not.
443   *
444   * @param {string} url
445   *   The web url to check.
446   *
447   * @return {boolean} isInternal
448   */
449  Drupal.google_analytics.isInternal = function (url) {
450    var isInternal = new RegExp("^(https?):\/\/" + window.location.host, "i");
451    return isInternal.test(url);
452  };
453
454  /**
455   * Check whether this is a special URL or not.
456   *
457   * URL types:
458   *  - gotwo.module /go/* links.
459   *
460   * @param {string} url
461   *   The web url to check.
462   *
463   * @return {boolean} isInternalSpecial
464   */
465  Drupal.google_analytics.isInternalSpecial = function (url) {
466    var isInternalSpecial = new RegExp("(\/go\/.*)$", "i");
467    return isInternalSpecial.test(url);
468  };
469
470  /**
471   * Extract the relative internal URL from an absolute internal URL.
472   *
473   * Examples:
474   * - http://mydomain.com/node/1 -> /node/1
475   * - http://example.com/foo/bar -> http://example.com/foo/bar
476   *
477   * @param {string} url
478   *   The web url to check.
479   *
480   * @return {string} getPageUrl
481   *   Internal website URL.
482   */
483  Drupal.google_analytics.getPageUrl = function (url) {
484    var extractInternalUrl = new RegExp("^(https?):\/\/" + window.location.host, "i");
485    return url.replace(extractInternalUrl, '');
486  };
487
488  /**
489   * Extract the download file extension from the URL.
490   *
491   * @param {string} url
492   *   The web url to check.
493   *
494   * @return {string} getDownloadExtension
495   *   The file extension of the passed url. e.g. "zip", "txt"
496   */
497  Drupal.google_analytics.getDownloadExtension = function (url) {
498    var extractDownloadextension = new RegExp("\\.(" + drupalSettings.google_analytics.trackDownloadExtensions + ")([\?#].*)?$", "i");
499    var extension = extractDownloadextension.exec(url);
500    return (extension === null) ? '' : extension[1];
501  };
502
503})(jQuery, Drupal, drupalSettings);
504;
505function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}!function(t){"use strict";function e(t){if(void 0===Function.prototype.name){var e=/function\s([^(]{1,})\(/,i=e.exec(t.toString());return i&&i.length>1?i[1].trim():""}return void 0===t.prototype?t.constructor.name:t.prototype.constructor.name}function i(t){return"true"===t||"false"!==t&&(isNaN(1*t)?t:parseFloat(t))}function n(t){return t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}var s="6.3.1",o={version:s,_plugins:{},_uuids:[],rtl:function(){return"rtl"===t("html").attr("dir")},plugin:function(t,i){var s=i||e(t),o=n(s);this._plugins[o]=this[s]=t},registerPlugin:function(t,i){var s=i?n(i):e(t.constructor).toLowerCase();t.uuid=this.GetYoDigits(6,s),t.$element.attr("data-"+s)||t.$element.attr("data-"+s,t.uuid),t.$element.data("zfPlugin")||t.$element.data("zfPlugin",t),t.$element.trigger("init.zf."+s),this._uuids.push(t.uuid)},unregisterPlugin:function(t){var i=n(e(t.$element.data("zfPlugin").constructor));this._uuids.splice(this._uuids.indexOf(t.uuid),1),t.$element.removeAttr("data-"+i).removeData("zfPlugin").trigger("destroyed.zf."+i);for(var s in t)t[s]=null},reInit:function(e){var i=e instanceof t;try{if(i)e.each(function(){t(this).data("zfPlugin")._init()});else{var s=typeof e,o=this,a={object:function(e){e.forEach(function(e){e=n(e),t("[data-"+e+"]").foundation("_init")})},string:function(){e=n(e),t("[data-"+e+"]").foundation("_init")},undefined:function(){this.object(Object.keys(o._plugins))}};a[s](e)}}catch(t){console.error(t)}finally{return e}},GetYoDigits:function(t,e){return t=t||6,Math.round(Math.pow(36,t+1)-Math.random()*Math.pow(36,t)).toString(36).slice(1)+(e?"-"+e:"")},reflow:function(e,n){"undefined"==typeof n?n=Object.keys(this._plugins):"string"==typeof n&&(n=[n]);var s=this;t.each(n,function(n,o){var a=s._plugins[o],r=t(e).find("[data-"+o+"]").addBack("[data-"+o+"]");r.each(function(){var e=t(this),n={};if(e.data("zfPlugin"))return void console.warn("Tried to initialize "+o+" on an element that already has a Foundation plugin.");
505if(e.attr("data-options")){e.attr("data-options").split(";").forEach(function(t,e){var s=t.split(":").map(function(t){return t.trim()});s[0]&&(n[s[0]]=i(s[1]))})}try{e.data("zfPlugin",new a(t(this),n))}catch(t){console.error(t)}finally{return}})})},getFnName:e,transitionend:function(t){var e,i={transition:"transitionend",WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"otransitionend"},n=document.createElement("div");for(var s in i)"undefined"!=typeof n.style[s]&&(e=i[s]);return e?e:(e=setTimeout(function(){t.triggerHandler("transitionend",[t])},1),"transitionend")}};o.util={throttle:function(t,e){var i=null;return function(){var n=this,s=arguments;null===i&&(i=setTimeout(function(){t.apply(n,s),i=null},e))}}};var a=function(i){var n=typeof i,s=t("meta.foundation-mq"),a=t(".no-js");if(s.length||t('<meta class="foundation-mq">').appendTo(document.head),a.length&&a.removeClass("no-js"),"undefined"===n)o.MediaQuery._init(),o.reflow(this);else{if("string"!==n)throw new TypeError("We're sorry, "+n+" is not a valid parameter. You must use a string representing the method you wish to invoke.");var r=Array.prototype.slice.call(arguments,1),l=this.data("zfPlugin");if(void 0===l||void 0===l[i])throw new ReferenceError("We're sorry, '"+i+"' is not an available method for "+(l?e(l):"this element")+".");1===this.length?l[i].apply(l,r):this.each(function(e,n){l[i].apply(t(n).data("zfPlugin"),r)})}return this};window.Foundation=o,t.fn.foundation=a,function(){Date.now&&window.Date.now||(window.Date.now=Date.now=function(){return(new Date).getTime()});for(var t=["webkit","moz"],e=0;e<t.length&&!window.requestAnimationFrame;++e){var i=t[e];window.requestAnimationFrame=window[i+"RequestAnimationFrame"],window.cancelAnimationFrame=window[i+"CancelAnimationFrame"]||window[i+"CancelRequestAnimationFrame"]}if(/iP(ad|hone|od).*OS 6/.test(window.navigator.userAgent)||!window.requestAnimationFrame||!window.cancelAnimationFrame){var n=0;window.requestAnimationFrame=function(t){var e=Date.now(),i=Math.max(n+16,e);return setTimeout(function(){t(n=i)},i-e)},window.cancelAnimationFrame=clearTimeout}window.performance&&window.performance.now||(window.performance={start:Date.now(),now:function(){return Date.now()-this.start}})}(),Function.prototype.bind||(Function.prototype.bind=function(t){if("function"!=typeof this)throw new TypeError("Function.prototype.bind - what is trying to be bound is not callable");var e=Array.prototype.slice.call(arguments,1),i=this,n=function(){},s=function(){return i.apply(this instanceof n?this:t,e.concat(Array.prototype.slice.call(arguments)))};return this.prototype&&(n.prototype=this.prototype),s.prototype=new n,s})}(jQuery),!function(t){function e(t,e,n,s){var o,a,r,l,h=i(t);if(e){var u=i(e);a=h.offset.top+h.height<=u.height+u.offset.top,o=h.offset.top>=u.offset.top,r=h.offset.left>=u.offset.left,l=h.offset.left+h.width<=u.width+u.offset.left}else a=h.offset.top+h.height<=h.windowDims.height+h.windowDims.offset.top,o=h.offset.top>=h.windowDims.offset.top,r=h.offset.left>=h.windowDims.offset.left,l=h.offset.left+h.width<=h.windowDims.width;var d=[a,o,r,l];return n?r===l==!0:s?o===a==!0:d.indexOf(!1)===-1}function i(t,e){if(t=t.length?t[0]:t,t===window||t===document)throw new Error("I'm sorry, Dave. I'm afraid I can't do that.");var i=t.getBoundingClientRect(),n=t.parentNode.getBoundingClientRect(),s=document.body.getBoundingClientRect(),o=window.pageYOffset,a=window.pageXOffset;return{width:i.width,height:i.height,offset:{top:i.top+o,left:i.left+a},parentDims:{width:n.width,height:n.height,offset:{top:n.top+o,left:n.left+a}},windowDims:{width:s.width,height:s.height,offset:{top:o,left:a}}}}function n(t,e,n,s,o,a){var r=i(t),l=e?i(e):null;switch(n){case"top":return{left:Foundation.rtl()?l.offset.left-r.width+l.width:l.offset.left,top:l.offset.top-(r.height+s)};case"left":return{left:l.offset.left-(r.width+o),top:l.offset.top};case"right":return{left:l.offset.left+l.width+o,top:l.offset.top};case"center top":return{left:l.offset.left+l.width/2-r.width/2,top:l.offset.top-(r.height+s)};case"center bottom":return{left:a?o:l.offset.left+l.width/2-r.width/2,top:l.offset.top+l.height+s};case"center left":return{left:l.offset.left-(r.width+o),top:l.offset.top+l.height/2-r.height/2};case"center right":return{left:l.offset.left+l.width+o+1,top:l.offset.top+l.height/2-r.height/2};
505case"center":return{left:r.windowDims.offset.left+r.windowDims.width/2-r.width/2,top:r.windowDims.offset.top+r.windowDims.height/2-r.height/2};case"reveal":return{left:(r.windowDims.width-r.width)/2,top:r.windowDims.offset.top+s};case"reveal full":return{left:r.windowDims.offset.left,top:r.windowDims.offset.top};case"left bottom":return{left:l.offset.left,top:l.offset.top+l.height+s};case"right bottom":return{left:l.offset.left+l.width+o-r.width,top:l.offset.top+l.height+s};default:return{left:Foundation.rtl()?l.offset.left-r.width+l.width:l.offset.left+o,top:l.offset.top+l.height+s}}}Foundation.Box={ImNotTouchingYou:e,GetDimensions:i,GetOffsets:n}}(jQuery),!function(t){function e(t){var e={};for(var i in t)e[t[i]]=t[i];return e}var i={9:"TAB",13:"ENTER",27:"ESCAPE",32:"SPACE",37:"ARROW_LEFT",38:"ARROW_UP",39:"ARROW_RIGHT",40:"ARROW_DOWN"},n={},s={keys:e(i),parseKey:function(t){var e=i[t.which||t.keyCode]||String.fromCharCode(t.which).toUpperCase();return e=e.replace(/\W+/,""),t.shiftKey&&(e="SHIFT_"+e),t.ctrlKey&&(e="CTRL_"+e),t.altKey&&(e="ALT_"+e),e=e.replace(/_$/,"")},handleKey:function(e,i,s){var o,a,r,l=n[i],h=this.parseKey(e);if(!l)return console.warn("Component not defined!");if(o="undefined"==typeof l.ltr?l:Foundation.rtl()?t.extend({},l.ltr,l.rtl):t.extend({},l.rtl,l.ltr),a=o[h],r=s[a],r&&"function"==typeof r){var u=r.apply();(s.handled||"function"==typeof s.handled)&&s.handled(u)}else(s.unhandled||"function"==typeof s.unhandled)&&s.unhandled()},findFocusable:function(e){return!!e&&e.find("a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, embed, *[tabindex], *[contenteditable]").filter(function(){return!(!t(this).is(":visible")||t(this).attr("tabindex")<0)})},register:function(t,e){n[t]=e},trapFocus:function(t){var e=Foundation.Keyboard.findFocusable(t),i=e.eq(0),n=e.eq(-1);t.on("keydown.zf.trapfocus",function(t){t.target===n[0]&&"TAB"===Foundation.Keyboard.parseKey(t)?(t.preventDefault(),i.focus()):t.target===i[0]&&"SHIFT_TAB"===Foundation.Keyboard.parseKey(t)&&(t.preventDefault(),n.focus())})},releaseFocus:function(t){t.off("keydown.zf.trapfocus")}};Foundation.Keyboard=s}(jQuery),!function(t){function e(t){var e={};return"string"!=typeof t?e:(t=t.trim().slice(1,-1))?e=t.split("&").reduce(function(t,e){var i=e.replace(/\+/g," ").split("="),n=i[0],s=i[1];return n=decodeURIComponent(n),s=void 0===s?null:decodeURIComponent(s),t.hasOwnProperty(n)?Array.isArray(t[n])?t[n].push(s):t[n]=[t[n],s]:t[n]=s,t},{}):e}var i={queries:[],current:"",_init:function(){var i,n=this,s=t(".foundation-mq").css("font-family");i=e(s);for(var o in i)i.hasOwnProperty(o)&&n.queries.push({name:o,value:"only screen and (min-width: "+i[o]+")"});this.current=this._getCurrentSize(),this._watcher()},atLeast:function(t){var e=this.get(t);return!!e&&window.matchMedia(e).matches},is:function(t){return t=t.trim().split(" "),t.length>1&&"only"===t[1]?t[0]===this._getCurrentSize():this.atLeast(t[0])},get:function(t){for(var e in this.queries)if(this.queries.hasOwnProperty(e)){var i=this.queries[e];if(t===i.name)return i.value}return null},_getCurrentSize:function(){for(var t,e=0;e<this.queries.length;e++){var i=this.queries[e];window.matchMedia(i.value).matches&&(t=i)}return"object"==typeof t?t.name:t},_watcher:function(){var e=this;t(window).on("resize.zf.mediaquery",function(){var i=e._getCurrentSize(),n=e.current;i!==n&&(e.current=i,t(window).trigger("changed.zf.mediaquery",[i,n]))})}};Foundation.MediaQuery=i,window.matchMedia||(window.matchMedia=function(){"use strict";var t=window.styleMedia||window.media;if(!t){var e=document.createElement("style"),i=document.getElementsByTagName("script")[0],n=null;e.type="text/css",e.id="matchmediajs-test",i&&i.parentNode&&i.parentNode.insertBefore(e,i),n="getComputedStyle"in window&&window.getComputedStyle(e,null)||e.currentStyle,t={matchMedium:function(t){var i="@media "+t+"{ #matchmediajs-test { width: 1px; } }";return e.styleSheet?e.styleSheet.cssText=i:e.textContent=i,"1px"===n.width}}}return function(e){return{matches:t.matchMedium(e||"all"),media:e||"all"}}}()),Foundation.MediaQuery=i}(jQuery),!function(t){function e(t,e,i){function n(r){a||(a=r),o=r-a,i.apply(e),o<t?s=window.requestAnimationFrame(n,e):(window.cancelAnimationFrame(s),e.trigger("finished.zf.animate",[e]).triggerHandler("finished.zf.animate",[e]))}var s,o,a=null;return 0===t?(i.apply(e),void e.trigger("finished.zf.animate",[e]).triggerHandler("finished.zf.animate",[e])):void(s=window.requestAnimationFrame(n))}function i(e,i,o,a){function r(){e||i.hide(),l(),a&&a.apply(i)}function l(){i[0].style.transitionDuration=0,i.removeClass(h+" "+u+" "+o)}if(i=t(i).eq(0),i.length){var h=e?n[0]:n[1],u=e?s[0]:s[1];l(),i.addClass(o).css("transition","none"),requestAnimationFrame(function(){i.addClass(h),e&&i.show()}),requestAnimationFrame(function(){i[0].offsetWidth,i.css("transition","").addClass(u)}),i.one(Foundation.transitionend(i),r)}}var n=["mui-enter","mui-leave"],s=["mui-enter-active","mui-leave-active"],o={animateIn:function(t,e,n){i(!0,t,e,n)},animateOut:function(t,e,n){i(!1,t,e,n)}};Foundation.Move=e,Foundation.Motion=o}(jQuery),!function(t){var e={Feather:function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"zf";e.attr("role","menubar");var n=e.find("li").attr({role:"menuitem"}),s="is-"+i+"-submenu",o=s+"-item",a="is-"+i+"-submenu-parent";n.each(function(){var e=t(this),n=e.children("ul");n.length&&(e.addClass(a).attr({"aria-haspopup":!0,"aria-label":e.children("a:first").text()}),"drilldown"===i&&e.attr({"aria-expanded":!1}),n.addClass("submenu "+s).attr({"data-submenu":"",role:"menu"}),"drilldown"===i&&n.attr({"aria-hidden":!0})),e.parent("[data-submenu]").length&&e.addClass("is-submenu-item "+o)})},Burn:function(t,e){var i="is-"+e+"-submenu",n=i+"-item",s="is-"+e+"-submenu-parent";t.find(">li, .menu, .menu > li").removeClass(i+" "+n+" "+s+" is-submenu-item submenu is-active").removeAttr("data-submenu").css("display","")}};Foundation.Nest=e}(jQuery),!function(t){function e(t,e,i){var n,s,o=this,a=e.duration,r=Object.keys(t.data())[0]||"timer",l=-1;this.isPaused=!1,this.restart=function(){l=-1,clearTimeout(s),this.start()},this.start=function(){this.isPaused=!1,clearTimeout(s),l=l<=0?a:l,t.data("paused",!1),n=Date.now(),s=setTimeout(function(){e.infinite&&o.restart(),i&&"function"==typeof i&&i()},l),t.trigger("timerstart.zf."+r)},this.pause=function(){this.isPaused=!0,clearTimeout(s),t.data("paused",!0);var e=Date.now();l-=e-n,t.trigger("timerpaused.zf."+r)}}function i(e,i){function n(){s--,0===s&&i()}var s=e.length;0===s&&i(),e.each(function(){if(this.complete||4===this.readyState||"complete"===this.readyState)n();else{var e=t(this).attr("src");t(this).attr("src",e+(e.indexOf("?")>=0?"&":"?")+(new Date).getTime()),t(this).one("load",function(){n()})}})}Foundation.Timer=e,Foundation.onImagesLoaded=i}(jQuery),function(t){function e(){this.removeEventListener("touchmove",i),this.removeEventListener("touchend",e),h=!1}function i(i){if(t.spotSwipe.preventDefault&&i.preventDefault(),h){var n,s=i.touches[0].pageX,a=(i.touches[0].pageY,o-s);l=(new Date).getTime()-r,Math.abs(a)>=t.spotSwipe.moveThreshold&&l<=t.spotSwipe.timeThreshold&&(n=a>0?"left":"right"),n&&(i.preventDefault(),e.call(this),t(this).trigger("swipe",n).trigger("swipe"+n))}}function n(t){1==t.touches.length&&(o=t.touches[0].pageX,a=t.touches[0].pageY,h=!0,r=(new Date).getTime(),this.addEventListener("touchmove",i,!1),this.addEventListener("touchend",e,!1))}function s(){this.addEventListener&&this.addEventListener("touchstart",n,!1)}t.spotSwipe={version:"1.0.0",enabled:"ontouchstart"in document.documentElement,preventDefault:!1,moveThreshold:75,timeThreshold:200};var o,a,r,l,h=!1;t.event.special.swipe={setup:s},t.each(["left","up","down","right"],function(){t.event.special["swipe"+this]={setup:function(){t(this).on("swipe",t.noop)}}})}(jQuery),!function(t){t.fn.addTouch=function(){this.each(function(i,n){t(n).bind("touchstart touchmove touchend touchcancel",function(){e(event)})});var e=function(t){var e,i=t.changedTouches,n=i[0],s={touchstart:"mousedown",touchmove:"mou
505semove",touchend:"mouseup"},o=s[t.type];"MouseEvent"in window&&"function"==typeof window.MouseEvent?e=new window.MouseEvent(o,{bubbles:!0,cancelable:!0,screenX:n.screenX,screenY:n.screenY,clientX:n.clientX,clientY:n.clientY}):(e=document.createEvent("MouseEvent"),e.initMouseEvent(o,!0,!0,window,1,n.screenX,n.screenY,n.clientX,n.clientY,!1,!1,!1,!1,0,null)),n.target.dispatchEvent(e)}}}(jQuery),!function(t){function e(){a(),n(),s(),o(),i()}function i(e){var i=t("[data-yeti-box]"),n=["dropdown","tooltip","reveal"];if(e&&("string"==typeof e?n.push(e):"object"==typeof e&&"string"==typeof e[0]?n.concat(e):console.error("Plugin names must be strings")),i.length){var s=n.map(function(t){return"closeme.zf."+t}).join(" ");t(window).off(s).on(s,function(e,i){var n=e.namespace.split(".")[0],s=t("[data-"+n+"]").not('[data-yeti-box="'+i+'"]');s.each(function(){var e=t(this);e.triggerHandler("close.zf.trigger",[e])})})}}function n(e){var i=void 0,n=t("[data-resize]");n.length&&t(window).off("resize.zf.trigger").on("resize.zf.trigger",function(s){i&&clearTimeout(i),i=setTimeout(function(){r||n.each(function(){t(this).triggerHandler("resizeme.zf.trigger")}),n.attr("data-events","resize")},e||10)})}function s(e){var i=void 0,n=t("[data-scroll]");n.length&&t(window).off("scroll.zf.trigger").on("scroll.zf.trigger",function(s){i&&clearTimeout(i),i=setTimeout(function(){r||n.each(function(){t(this).triggerHandler("scrollme.zf.trigger")}),n.attr("data-events","scroll")},e||10)})}function o(e){var i=t("[data-mutate]");i.length&&r&&i.each(function(){t(this).triggerHandler("mutateme.zf.trigger")})}function a(){if(!r)return!1;var e=document.querySelectorAll("[data-resize], [data-scroll], [data-mutate]"),i=function(e){var i=t(e[0].target);switch(e[0].type){case"attributes":"scroll"===i.attr("data-events")&&"data-events"===e[0].attributeName&&i.triggerHandler("scrollme.zf.trigger",[i,window.pageYOffset]),"resize"===i.attr("data-events")&&"data-events"===e[0].attributeName&&i.triggerHandler("resizeme.zf.trigger",[i]),"style"===e[0].attributeName&&(i.closest("[data-mutate]").attr("data-events","mutate"),i.closest("[data-mutate]").triggerHandler("mutateme.zf.trigger",[i.closest("[data-mutate]")]));break;case"childList":i.closest("[data-mutate]").attr("data-events","mutate"),i.closest("[data-mutate]").triggerHandler("mutateme.zf.trigger",[i.closest("[data-mutate]")]);break;default:return!1}};if(e.length)for(var n=0;n<=e.length-1;n++){var s=new r(i);s.observe(e[n],{attributes:!0,childList:!0,characterData:!1,subtree:!0,attributeFilter:["data-events","style"]})}}var r=function(){for(var t=["WebKit","Moz","O","Ms",""],e=0;e<t.length;e++)if(t[e]+"MutationObserver"in window)return window[t[e]+"MutationObserver"];return!1}(),l=function(e,i){e.data(i).split(" ").forEach(function(n){t("#"+n)["close"===i?"trigger":"triggerHandler"](i+".zf.trigger",[e])})};t(document).on("click.zf.trigger","[data-open]",function(){l(t(this),"open")}),t(document).on("click.zf.trigger","[data-close]",function(){var e=t(this).data("close");e?l(t(this),"close"):t(this).trigger("close.zf.trigger")}),t(document).on("click.zf.trigger","[data-toggle]",function(){var e=t(this).data("toggle");e?l(t(this),"toggle"):t(this).trigger("toggle.zf.trigger")}),t(document).on("close.zf.trigger","[data-closable]",function(e){e.stopPropagation();var i=t(this).data("closable");""!==i?Foundation.Motion.animateOut(t(this),i,function(){t(this).trigger("closed.zf")}):t(this).fadeOut().trigger("closed.zf")}),t(document).on("focus.zf.trigger blur.zf.trigger","[data-toggle-focus]",function(){var e=t(this).data("toggle-focus");t("#"+e).triggerHandler("toggle.zf.trigger",[t(this)])}),t(window).on("load",function(){e()}),Foundation.IHearYou=e}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Abide")}return _createClass(e,[{key:"_init",value:function(){this.$inputs=this.$element.find("input, textarea, select"),this._events()}},{key:"_events",value:function(){var e=this;this.$element.off(".abide").on("reset.zf.abide",function(){e.resetForm()}).on("submit.zf.abide",function(){return e.validateForm()}),"fieldChange"===this.options.validateOn&&this.$inputs.off("change.zf.abide").on("change.zf.abide",function(i){e.validateInput(t(i.target))}),this.options.liveValidate&&this.$inputs.off("input.zf.abide").on("input.zf.abide",function(i){e.validateInput(t(i.target))}),this.options.validateOnBlur&&this.$inputs.off("blur.zf.abide").on("blur.zf.abide",function(i){e.validateInput(t(i.target))})}},{key:"_reflow",value:function(){this._init()}},{key:"requiredCheck",value:function(t){if(!t.attr("required"))return!0;var e=!0;switch(t[0].type){case"checkbox":e=t[0].checked;break;case"select":case"select-one":case"select-multiple":var i=t.find("option:selected");i.length&&i.val()||(e=!1);break;default:t.val()&&t.val().length||(e=!1)}return e}},{key:"findFormError",value:function(t){var e=t.siblings(this.options.formErrorSelector);return e.length||(e=t.parent().find(this.options.formErrorSelector)),e}},{key:"findLabel",value:function(t){var e=t[0].id,i=this.$element.find('label[for="'+e+'"]');return i.length?i:t.closest("label")}},{key:"findRadioLabels",value:function(e){var i=this,n=e.map(function(e,n){var s=n.id,o=i.$element.find('label[for="'+s+'"]');return o.length||(o=t(n).closest("label")),o[0]});return t(n)}},{key:"addErrorClasses",value:function(t){var e=this.findLabel(t),i=this.findFormError(t);e.length&&e.addClass(this.options.labelErrorClass),i.length&&i.addClass(this.options.formErrorClass),t.addClass(this.options.inputErrorClass).attr("data-invalid","")}},{key:"removeRadioErrorClasses",value:function(t){var e=this.$element.find(':radio[name="'+t+'"]'),i=this.findRadioLabels(e),n=this.findFormError(e);i.length&&i.removeClass(this.options.labelErrorClass),n.length&&n.removeClass(this.options.formErrorClass),e.removeClass(this.options.inputErrorClass).removeAttr("data-invalid")}},{key:"removeErrorClasses",value:function(t){if("radio"==t[0].type)return this.removeRadioErrorClasses(t.attr("name"));var e=this.findLabel(t),i=this.findFormError(t);e.length&&e.removeClass(this.options.labelErrorClass),i.length&&i.removeClass(this.options.formErrorClass),t.removeClass(this.options.inputErrorClass).removeAttr("data-invalid")}},{key:"validateInput",value:function(e){var i=this,n=this.requiredCheck(e),s=!1,o=!0,a=e.attr("data-validator"),r=!0;
505if(e.is("[data-abide-ignore]")||e.is('[type="hidden"]')||e.is("[disabled]"))return!0;switch(e[0].type){case"radio":s=this.validateRadio(e.attr("name"));break;case"checkbox":s=n;break;case"select":case"select-one":case"select-multiple":s=n;break;default:s=this.validateText(e)}a&&(o=this.matchValidation(e,a,e.attr("required"))),e.attr("data-equalto")&&(r=this.options.validators.equalTo(e));var l=[n,s,o,r].indexOf(!1)===-1,h=(l?"valid":"invalid")+".zf.abide";if(l){var u=this.$element.find('[data-equalto="'+e.attr("id")+'"]');u.length&&!function(){var e=i;u.each(function(){t(this).val()&&e.validateInput(t(this))})}()}return this[l?"removeErrorClasses":"addErrorClasses"](e),e.trigger(h,[e]),l}},{key:"validateForm",value:function(){var e=[],i=this;this.$inputs.each(function(){e.push(i.validateInput(t(this)))});var n=e.indexOf(!1)===-1;return this.$element.find("[data-abide-error]").css("display",n?"none":"block"),this.$element.trigger((n?"formvalid":"forminvalid")+".zf.abide",[this.$element]),n}},{key:"validateText",value:function(t,e){e=e||t.attr("pattern")||t.attr("type");var i=t.val(),n=!1;return i.length?n=this.options.patterns.hasOwnProperty(e)?this.options.patterns[e].test(i):e===t.attr("type")||new RegExp(e).test(i):t.prop("required")||(n=!0),n}},{key:"validateRadio",value:function(e){var i=this.$element.find(':radio[name="'+e+'"]'),n=!1,s=!1;return i.each(function(e,i){t(i).attr("required")&&(s=!0)}),s||(n=!0),n||i.each(function(e,i){t(i).prop("checked")&&(n=!0)}),n}},{key:"matchValidation",value:function(t,e,i){var n=this;i=!!i;var s=e.split(" ").map(function(e){return n.options.validators[e](t,i,t.parent())});return s.indexOf(!1)===-1}},{key:"resetForm",value:function(){var e=this.$element,i=this.options;t("."+i.labelErrorClass,e).not("small").removeClass(i.labelErrorClass),t("."+i.inputErrorClass,e).not("small").removeClass(i.inputErrorClass),t(i.formErrorSelector+"."+i.formErrorClass).removeClass(i.formErrorClass),e.find("[data-abide-error]").css("display","none"),t(":input",e).not(":button, :submit, :reset, :hidden, :radio, :checkbox, [data-abide-ignore]").val("").removeAttr("data-invalid"),t(":input:radio",e).not("[data-abide-ignore]").prop("checked",!1).removeAttr("data-invalid"),t(":input:checkbox",e).not("[data-abide-ignore]").prop("checked",!1).removeAttr("data-invalid"),e.trigger("formreset.zf.abide",[e])}},{key:"destroy",value:function(){var e=this;this.$element.off(".abide").find("[data-abide-error]").css("display","none"),this.$inputs.off(".abide").each(function(){e.removeErrorClasses(t(this))}),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={validateOn:"fieldChange",labelErrorClass:"is-invalid-label",inputErrorClass:"is-invalid-input",formErrorSelector:".form-error",formErrorClass:"is-visible",liveValidate:!1,validateOnBlur:!1,patterns:{alpha:/^[a-zA-Z]+$/,alpha_numeric:/^[a-zA-Z0-9]+$/,integer:/^[-+]?\d+$/,number:/^[-+]?\d*(?:[\.\,]\d+)?$/,card:/^(?:4[0-9]{12}(?:[0-9]{3})?|5[1-5][0-9]{14}|6(?:011|5[0-9][0-9])[0-9]{12}|3[47][0-9]{13}|3(?:0[0-5]|[68][0-9])[0-9]{11}|(?:2131|1800|35\d{3})\d{11})$/,cvv:/^([0-9]){3,4}$/,email:/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+$/,url:/^(https?|ftp|file|ssh):\/\/(((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-zA-Z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-zA-Z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/,domain:/^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,8}$/,datetime:/^([0-2][0-9]{3})\-([0-1][0-9])\-([0-3][0-9])T([0-5][0-9])\:([0-5][0-9])\:([0-5][0-9])(Z|([\-\+]([0-1][0-9])\:00))$/,date:/(?:19|20)[0-9]{2}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1[0-9]|2[0-9])|(?:(?!02)(?:0[1-9]|1[0-2])-(?:30))|(?:(?:0[13578]|1[02])-31))$/,time:/^(0[0-9]|1[0-9]|2[0-3])(:[0-5][0-9]){2}$/,dateISO:/^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}$/,month_day_year:/^(0[1-9]|1[012])[- \/.](0[1-9]|[12][0-9]|3[01])[- \/.]\d{4}$/,day_month_year:/^(0[1-9]|[12][0-9]|3[01])[- \/.](0[1-9]|1[012])[- \/.]\d{4}$/,color:/^#?([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/}
505,validators:{equalTo:function(e,i,n){return t("#"+e.attr("data-equalto")).val()===e.val()}}},Foundation.plugin(e,"Abide")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Accordion"),Foundation.Keyboard.register("Accordion",{ENTER:"toggle",SPACE:"toggle",ARROW_DOWN:"next",ARROW_UP:"previous"})}return _createClass(e,[{key:"_init",value:function(){this.$element.attr("role","tablist"),this.$tabs=this.$element.children("[data-accordion-item]"),this.$tabs.each(function(e,i){var n=t(i),s=n.children("[data-tab-content]"),o=s[0].id||Foundation.GetYoDigits(6,"accordion"),a=i.id||o+"-label";n.find("a:first").attr({"aria-controls":o,role:"tab",id:a,"aria-expanded":!1,"aria-selected":!1}),s.attr({role:"tabpanel","aria-labelledby":a,"aria-hidden":!0,id:o})});var e=this.$element.find(".is-active").children("[data-tab-content]");e.length&&this.down(e,!0),this._events()}},{key:"_events",value:function(){var e=this;this.$tabs.each(function(){var i=t(this),n=i.children("[data-tab-content]");n.length&&i.children("a").off("click.zf.accordion keydown.zf.accordion").on("click.zf.accordion",function(t){t.preventDefault(),e.toggle(n)}).on("keydown.zf.accordion",function(t){Foundation.Keyboard.handleKey(t,"Accordion",{toggle:function(){e.toggle(n)},next:function(){var t=i.next().find("a").focus();e.options.multiExpand||t.trigger("click.zf.accordion")},previous:function(){var t=i.prev().find("a").focus();e.options.multiExpand||t.trigger("click.zf.accordion")},handled:function(){t.preventDefault(),t.stopPropagation()}})})})}},{key:"toggle",value:function(t){t.parent().hasClass("is-active")?this.up(t):this.down(t)}},{key:"down",value:function(e,i){var n=this;if(e.attr("aria-hidden",!1).parent("[data-tab-content]").addBack().parent().addClass("is-active"),!this.options.multiExpand&&!i){var s=this.$element.children(".is-active").children("[data-tab-content]");s.length&&this.up(s.not(e))}e.slideDown(this.options.slideSpeed,function(){n.$element.trigger("down.zf.accordion",[e])}),t("#"+e.attr("aria-labelledby")).attr({"aria-expanded":!0,"aria-selected":!0})}},{key:"up",value:function(e){var i=e.parent().siblings(),n=this;(this.options.allowAllClosed||i.hasClass("is-active"))&&e.parent().hasClass("is-active")&&(e.slideUp(n.options.slideSpeed,function(){n.$element.trigger("up.zf.accordion",[e])}),e.attr("aria-hidden",!0).parent().removeClass("is-active"),t("#"+e.attr("aria-labelledby")).attr({"aria-expanded":!1,"aria-selected":!1}))}},{key:"destroy",value:function(){this.$element.find("[data-tab-content]").stop(!0).slideUp(0).css("display",""),this.$element.find("a").off(".zf.accordion"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={slideSpeed:250,multiExpand:!1,allowAllClosed:!1},Foundation.plugin(e,"Accordion")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),
506n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),Foundation.Nest.Feather(this.$element,"accordion"),this._init(),Foundation.registerPlugin(this,"AccordionMenu"),Foundation.Keyboard.register("AccordionMenu",{ENTER:"toggle",SPACE:"toggle",ARROW_RIGHT:"open",ARROW_UP:"up",ARROW_DOWN:"down",ARROW_LEFT:"close",ESCAPE:"closeAll"})}return _createClass(e,[{key:"_init",value:function(){this.$element.find("[data-submenu]").not(".is-active").slideUp(0),this.$element.attr({role:"menu","aria-multiselectable":this.options.multiOpen}),this.$menuLinks=this.$element.find(".is-accordion-submenu-parent"),this.$menuLinks.each(function(){var e=this.id||Foundation.GetYoDigits(6,"acc-menu-link"),i=t(this),n=i.
506children("[data-submenu]"),s=n[0].id||Foundation.GetYoDigits(6,"acc-menu"),o=n.hasClass("is-active");i.attr({"aria-controls":s,"aria-expanded":o,role:"menuitem",id:e}),n.attr({"aria-labelledby":e,"aria-hidden":!o,role:"menu",id:s})});var e=this.$element.find(".is-active");if(e.length){var i=this;e.each(function(){i.down(t(this))})}this._events()}},{key:"_events",value:function(){var e=this;this.$element.find("li").each(function(){var i=t(this).children("[data-submenu]");i.length&&t(this).children("a").off("click.zf.accordionMenu").on("click.zf.accordionMenu",function(t){t.preventDefault(),e.toggle(i)})}).on("keydown.zf.accordionmenu",function(i){var n,s,o=t(this),a=o.parent("ul").children("li"),r=o.children("[data-submenu]");a.each(function(e){if(t(this).is(o))return n=a.eq(Math.max(0,e-1)).find("a").first(),s=a.eq(Math.min(e+1,a.length-1)).find("a").first(),t(this).children("[data-submenu]:visible").length&&(s=o.find("li:first-child").find("a").first()),t(this).is(":first-child")?n=o.parents("li").first().find("a").first():n.parents("li").first().children("[data-submenu]:visible").length&&(n=n.parents("li").find("li:last-child").find("a").first()),void(t(this).is(":last-child")&&(s=o.parents("li").first().next("li").find("a").first()))}),Foundation.Keyboard.handleKey(i,"AccordionMenu",{open:function(){r.is(":hidden")&&(e.down(r),r.find("li").first().find("a").first().focus())},close:function(){r.length&&!r.is(":hidden")?e.up(r):o.parent("[data-submenu]").length&&(e.up(o.parent("[data-submenu]")),o.parents("li").first().find("a").first().focus())},up:function(){return n.focus(),!0},down:function(){return s.focus(),!0},toggle:function(){o.children("[data-submenu]").length&&e.toggle(o.children("[data-submenu]"))},closeAll:function(){e.hideAll()},handled:function(t){t&&i.preventDefault(),i.stopImmediatePropagation()}})})}},{key:"hideAll",value:function(){this.up(this.$element.find("[data-submenu]"))}},{key:"showAll",value:function(){this.down(this.$element.find("[data-submenu]"))}},{key:"toggle",value:function(t){t.is(":animated")||(t.is(":hidden")?this.down(t):this.up(t))}},{key:"down",value:function(t){var e=this;this.options.multiOpen||this.up(this.$element.find(".is-active").not(t.parentsUntil(this.$element).add(t))),t.addClass("is-active").attr({"aria-hidden":!1}).parent(".is-accordion-submenu-parent").attr({"aria-expanded":!0}),t.slideDown(e.options.slideSpeed,function(){e.$element.trigger("down.zf.accordionMenu",[t])})}},{key:"up",value:function(t){var e=this;t.slideUp(e.options.slideSpeed,function(){e.$element.trigger("up.zf.accordionMenu",[t])});var i=t.find("[data-submenu]").slideUp(0).addBack().attr("aria-hidden",!0);i.parent(".is-accordion-submenu-parent").attr("aria-expanded",!1)}},{key:"destroy",value:function(){this.$element.find("[data-submenu]").slideDown(0).css("display",""),this.$element.find("a").off("click.zf.accordionMenu"),Foundation.Nest.Burn(this.$element,"accordion"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={slideSpeed:250,multiOpen:!0},Foundation.plugin(e,"AccordionMenu")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),Foundation.Nest.Feather(this.$element,"drilldown"),this._init(),Foundation.registerPlugin(this,"Drilldown"),Foundation.Keyboard.register("Drilldown",{ENTER:"open",SPACE:"open",ARROW_RIGHT:"next",ARROW_UP:"up",ARROW_DOWN:"down",ARROW_LEFT:"previous",ESCAPE:"close",TAB:"down",SHIFT_TAB:"up"})}return _createClass(e,[{key:"_init",value:function(){this.$submenuAnchors=this.$element.find("li.is-drilldown-submenu-parent").children("a"),this.$submenus=this.$submenuAnchors.parent("li").children("[data-submenu]"),this.$menuItems=this.$element.find("li").not(".js-drilldown-back").attr("role","menuitem").find("a"),this.$element.attr("data-mutate",this.$element.attr("data-drilldown")||Foundation.GetYoDigits(6,"drilldown")),this._prepareMenu(),this._registerEvents(),this._keyboardEvents()}},{key:"_prepareMenu",value:function(){var e=this;this.$submenuAnchors.each(function(){var i=t(this),n=i.parent();e.options.parentLink&&i.clone().prependTo(n.children("[data-submenu]")).wrap('<li class="is-submenu-parent-item is-submenu-item is-drilldown-submenu-item" role="menu-item"></li>'),i.data("savedHref",i.attr("href")).removeAttr("href").attr("tabindex",0),i.children("[data-submenu]").attr({"aria-hidden":!0,tabindex:0,role:"menu"}),e._events(i)}),this.$submenus.each(function(){var i=t(this),n=i.find(".js-drilldown-back");if(!n.length)switch(e.options.backButtonPosition){case"bottom":i.append(e.options.backButton);break;case"top":i.prepend(e.options.backButton);break;default:console.error("Unsupported backButtonPosition value '"+e.options.backButtonPosition+"'")}e._back(i)}),this.$submenus.addClass("invisible"),this.options.autoHeight||this.$submenus.addClass("drilldown-submenu-cover-previous"),this.$element.parent().hasClass("is-drilldown")||(this.$wrapper=t(this.options.wrapper).addClass("is-drilldown"),this.options.animateHeight&&this.$wrapper.addClass("animate-height"),this.$element.wrap(this.$wrapper)),this.$wrapper=this.$element.parent(),this.$wrapper.css(this._getMaxDims())}},{key:"_resize",value:function(){this.$wrapper.css({"max-width":"none","min-height":"none"}),this.$wrapper.css(this._getMaxDims())}},{key:"_events",value:function(e){var i=this;e.off("click.zf.drilldown").on("click.zf.drilldown",function(n){if(t(n.target).parentsUntil("ul","li").hasClass("is-drilldown-submenu-parent")&&(n.stopImmediatePropagation(),n.preventDefault()),i._show(e.parent("li")),i.options.closeOnClick){var s=t("body");s.off(".zf.drilldown").on("click.zf.drilldown",function(e){e.target===i.$element[0]||t.contains(i.$element[0],e.target)||(e.preventDefault(),i._hideAll(),s.off(".zf.drilldown"))})}}),this.$element.on("mutateme.zf.trigger",this._resize.bind(this))}},{key:"_registerEvents",value:function(){this.options.scrollTop&&(this._bindHandler=this._scrollTop.bind(this),this.$element.on("open.zf.drilldown hide.zf.drilldown closed.zf.drilldown",this._bindHandler))}},{key:"_scrollTop",value:function(){var e=this,i=""!=e.options.scrollTopElement?t(e.options.scrollTopElement):e.$element,n=parseInt(i.offset().top+e.options.scrollTopOffset);t("html, body").stop(!0).animate({scrollTop:n},e.options.animationDuration,e.options.animationEasing,function(){this===t("html")[0]&&e.$element.trigger("scrollme.zf.drilldown")})}},{key:"_keyboardEvents",value:function(){var e=this;this.$menuItems.add(this.$element.find(".js-drilldown-back > a, .is-submenu-parent-item > a")).on("keydown.zf.drilldown",function(i){var n,s,o=t(this),a=o.parent("li").parent("ul").children("li").children("a");a.each(function(e){if(t(this).is(o))return n=a.eq(Math.max(0,e-1)),void(s=a.eq(Math.min(e+1,a.length-1)))}),Foundation.Keyboard.handleKey(i,"Drilldown",{next:function(){if(o.is(e.$submenuAnchors))return e._show(o.parent("li")),o.parent("li").one(Foundation.transitionend(o),function(){o.parent("li").find("ul li a").filter(e.$menuItems).first().focus()}),!0},previous:function(){return e._hide(o.parent("li").parent("ul")),o.parent("li").parent("ul").one(Foundation.transitionend(o),function(){setTimeout(function(){o.parent("li").parent("ul").parent("li").children("a").first().focus()},1)}),!0},up:function(){return n.focus(),!o.is(e.$element.find("> li:first-child > a"))},down:function(){return s.focus(),!o.is(e.$element.find("> li:last-child > a"))},close:function(){o.is(e.$element.find("> li > a"))||(e._hide(o.parent().parent()),o.parent().parent().siblings("a").focus())},open:function(){return o.is(e.$menuItems)?o.is(e.$submenuAnchors)?(e._show(o.parent("li")),o.parent("li").one(Foundation.transitionend(o),function(){o.parent("li").find("ul li a").filter(e.$menuItems).first().focus()}),!0):void 0:(e._hide(o.parent("li").parent("ul")),o.parent("li").parent("ul").one(Foundation.transitionend(o),function(){setTimeout(function(){o.parent("li").parent("ul").parent("li").children("a").first().focus()},1)}),!0)},handled:function(t){t&&i.preventDefault(),i.stopImmediatePropagation()}})})}}
506,{key:"_hideAll",value:function(){var t=this.$element.find(".is-drilldown-submenu.is-active").addClass("is-closing");this.options.autoHeight&&this.$wrapper.css({height:t.parent().closest("ul").data("calcHeight")}),t.one(Foundation.transitionend(t),function(e){t.removeClass("is-active is-closing")}),this.$element.trigger("closed.zf.drilldown")}},{key:"_back",value:function(t){var e=this;t.off("click.zf.drilldown"),t.children(".js-drilldown-back").on("click.zf.drilldown",function(i){i.stopImmediatePropagation(),e._hide(t);var n=t.parent("li").parent("ul").parent("li");n.length&&e._show(n)})}},{key:"_menuLinkEvents",value:function(){var t=this;this.$menuItems.not(".is-drilldown-submenu-parent").off("click.zf.drilldown").on("click.zf.drilldown",function(e){setTimeout(function(){t._hideAll()},0)})}},{key:"_show",value:function(t){this.options.autoHeight&&this.$wrapper.css({height:t.children("[data-submenu]").data("calcHeight")}),t.attr("aria-expanded",!0),t.children("[data-submenu]").addClass("is-active").removeClass("invisible").attr("aria-hidden",!1),this.$element.trigger("open.zf.drilldown",[t])}},{key:"_hide",value:function(t){this.options.autoHeight&&this.$wrapper.css({height:t.parent().closest("ul").data("calcHeight")});t.parent("li").attr("aria-expanded",!1),t.attr("aria-hidden",!0).addClass("is-closing"),t.addClass("is-closing").one(Foundation.transitionend(t),function(){t.removeClass("is-active is-closing"),t.blur().addClass("invisible")}),t.trigger("hide.zf.drilldown",[t])}},{key:"_getMaxDims",value:function(){var e=0,i={},n=this;return this.$submenus.add(this.$element).each(function(){var s=(t(this).children("li").length,Foundation.Box.GetDimensions(this).height);e=s>e?s:e,n.options.autoHeight&&(t(this).data("calcHeight",s),t(this).hasClass("is-drilldown-submenu")||(i.height=s))}),this.options.autoHeight||(i["min-height"]=e+"px"),i["max-width"]=this.$element[0].getBoundingClientRect().width+"px",i}},{key:"destroy",value:function(){this.options.scrollTop&&this.$element.off(".zf.drilldown",this._bindHandler),this._hideAll(),this.$element.off("mutateme.zf.trigger"),Foundation.Nest.Burn(this.$element,"drilldown"),this.$element.unwrap().find(".js-drilldown-back, .is-submenu-parent-item").remove().end().find(".is-active, .is-closing, .is-drilldown-submenu").removeClass("is-active is-closing is-drilldown-submenu").end().find("[data-submenu]").removeAttr("aria-hidden tabindex role"),this.$submenuAnchors.each(function(){t(this).off(".zf.drilldown")}),this.$submenus.removeClass("drilldown-submenu-cover-previous"),this.$element.find("a").each(function(){var e=t(this);e.removeAttr("tabindex"),e.data("savedHref")&&e.attr("href",e.data("savedHref")).removeData("savedHref")}),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={backButton:'<li class="js-drilldown-back"><a tabindex="0">Back</a></li>',backButtonPosition:"top",wrapper:"<div></div>",parentLink:!1,closeOnClick:!1,autoHeight:!1,animateHeight:!1,scrollTop:!1,scrollTopElement:"",scrollTopOffset:0,animationDuration:500,animationEasing:"swing"},Foundation.plugin(e,"Drilldown")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Dropdown"),Foundation.Keyboard.register("Dropdown",{ENTER:"open",SPACE:"open",ESCAPE:"close"})}return _createClass(e,[{key:"_init",value:function(){var e=this.$element.attr("id");this.$anchor=t(t('[data-toggle="'+e+'"]').length?'[data-toggle="'+e+'"]':'[data-open="'+e+'"]'),this.$anchor.attr({"aria-controls":e,"data-is-focus":!1,"data-yeti-box":e,"aria-haspopup":!0,"aria-expanded":!1}),this.options.parentClass?this.$parent=this.$element.parents("."+this.options.parentClass):this.$parent=null,this.options.positionClass=this.getPositionClass(),this.counter=4,this.usedPositions=[],this.$element.attr({"aria-hidden":"true","data-yeti-box":e,"data-resize":e,"aria-labelledby":this.$anchor[0].id||Foundation.GetYoDigits(6,"dd-anchor")}),this._events()}},{key:"getPositionClass",value:function(){var t=this.$element[0].className.match(/(top|left|right|bottom)/g);t=t?t[0]:"";var e=/float-(\S+)/.exec(this.$anchor[0].className);e=e?e[1]:"";var i=e?e+" "+t:t;return i}},{key:"_reposition",value:function(t){this.usedPositions.push(t?t:"bottom"),!t&&this.usedPositions.indexOf("top")<0?this.$element.addClass("top"):"top"===t&&this.usedPositions.indexOf("bottom")<0?this.$element.removeClass(t):"left"===t&&this.usedPositions.indexOf("right")<0?this.$element.removeClass(t).addClass("right"):"right"===t&&this.usedPositions.indexOf("left")<0?this.$element.removeClass(t).addClass("left"):!t&&this.usedPositions.indexOf("top")>-1&&this.usedPositions.indexOf("left")<0?this.$element.addClass("left"):"top"===t&&this.usedPositions.indexOf("bottom")>-1&&this.usedPositions.indexOf("left")<0?this.$element.removeClass(t).addClass("left"):"left"===t&&this.usedPositions.indexOf("right")>-1&&this.usedPositions.indexOf("bottom")<0?this.$element.removeClass(t):"right"===t&&this.usedPositions.indexOf("left")>-1&&this.usedPositions.indexOf("bottom")<0?this.$element.removeClass(t):this.$element.removeClass(t),this.classChanged=!0,this.counter--}},{key:"_setPosition",value:function(){if("false"===this.$anchor.attr("aria-expanded"))return!1;var t=this.getPositionClass(),e=Foundation.Box.GetDimensions(this.$element),i=(Foundation.Box.GetDimensions(this.$anchor),"left"===t?"left":"right"===t?"left":"top"),n="top"===i?"height":"width";"height"===n?this.options.vOffset:this.options.hOffset;if(e.width>=e.windowDims.width||!this.counter&&!Foundation.Box.ImNotTouchingYou(this.$element,this.$parent)){var s=e.windowDims.width,o=0;if(this.$parent){var a=Foundation.Box.GetDimensions(this.$parent),o=a.offset.left;a.width<s&&(s=a.width)}return this.$element.offset(Foundation.Box.GetOffsets(this.$element,this.$anchor,"center bottom",this.options.vOffset,this.options.hOffset+o,!0)).css({width:s-2*this.options.hOffset,height:"auto"}),this.classChanged=!0,!1}for(this.$element.offset(Foundation.Box.GetOffsets(this.$element,this.$anchor,t,this.options.vOffset,this.options.hOffset));!Foundation.Box.ImNotTouchingYou(this.$element,this.$parent,!0)&&this.counter;)this._reposition(t),this._setPosition()}},{key:"_events",value:function(){var e=this;this.$element.on({"open.zf.trigger":this.open.bind(this),"close.zf.trigger":this.close.bind(this),"toggle.zf.trigger":this.toggle.bind(this),"resizeme.zf.trigger":this._setPosition.bind(this)}),this.options.hover&&(this.$anchor.off("mouseenter.zf.dropdown mouseleave.zf.dropdown").on("mouseenter.zf.dropdown",function(){var i=t("body").data();"undefined"!=typeof i.whatinput&&"mouse"!==i.whatinput||(clearTimeout(e.timeout),e.timeout=setTimeout(function(){e.open(),e.$anchor.data("hover",!0)},e.options.hoverDelay))}).on("mouseleave.zf.dropdown",function(){clearTimeout(e.timeout),e.timeout=setTimeout(function(){e.close(),e.$anchor.data("hover",!1)},e.options.hoverDelay)}),this.options.hoverPane&&this.$element.off("mouseenter.zf.dropdown mouseleave.zf.dropdown").on("mouseenter.zf.dropdown",function(){clearTimeout(e.timeout)}).on("mouseleave.zf.dropdown",function(){clearTimeout(e.timeout),e.timeout=setTimeout(function(){e.close(),e.$anchor.data("hover",!1)},e.options.hoverDelay)})),this.$anchor.add(this.$element).on("keydown.zf.dropdown",function(i){var n=t(this);Foundation.Keyboard.findFocusable(e.$element);Foundation.Keyboard.handleKey(i,"Dropdown",{open:function(){n.is(e.$anchor)&&(e.open(),e.$element.attr("tabindex",-1).focus(),i.preventDefault())},close:function(){e.close(),e.$anchor.focus()}})})}},{key:"_addBodyHandler",value:function(){var e=t(document.body).not(this.$element),i=this;e.off("click.zf.dropdown").on("click.zf.dropdown",function(t){i.$anchor.is(t.target)||i.$anchor.find(t.target).length||i.$element.find(t.target).length||(i.close(),e.off("click.zf.dropdown"))})}},{key:"open",value:function(){if(this.$element.trigger("closeme.zf.dropdown",this.$element.attr("id")),this.$anchor.addClass("hover").attr({"aria-expanded":!0}),this._setPosition(),this.$element.addClass("is-open").attr({"aria-hidden":!1}),this.options.autoFocus){var t=Foundation.Keyboard.findFocusable(this.$element);t.length&&t.eq(0).focus()}this.options.closeOnClick&&this._addBodyHandler(),this.options.trapFocus&&Foundation.Keyboard.trapFocus(this.$element),this.$element.trigger("show.zf.dropdown",[this.$element])}},{key:"close",value:function(){if(!this.$element.hasClass("is-open"))return!1;if(this.$element.removeClass("is-open").attr({"aria-hidden":!0}),this.$anchor.removeClass("hover").attr("aria-expanded",!1),this.classChanged){var t=this.getPositionClass();t&&this.$element.removeClass(t),this.$element.addClass(this.options.positionClass).css({height:"",width:""}),this.classChanged=!1,this.counter=4,this.usedPositions.length=0}this.$element.trigger("hide.zf.dropdown",[this.$element]),this.options.trapFocus&&Foundation.Keyboard.releaseFocus(this.$element)}},{key:"toggle",value:function(){if(this.$element.hasClass("is-open")){if(this.$anchor.data("hover"))return;this.close()}else this.open()}},{key:"destroy",value:function(){this.$element.off(".zf.trigger").hide(),this.$anchor.off(".zf.dropdown"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={parentClass:null,hoverDelay:250,hover:!1,hoverPane:!1,vOffset:1,hOffset:1,positionClass:"",trapFocus:!1,autoFocus:!1,closeOnClick:!1},Foundation.plugin(e,"Dropdown")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}
506return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),Foundation.Nest.Feather(this.$element,"dropdown"),this._init(),Foundation.registerPlugin(this,"DropdownMenu"),Foundation.Keyboard.register("DropdownMenu",{ENTER:"open",SPACE:"open",ARROW_RIGHT:"next",ARROW_UP:"up",ARROW_DOWN:"down",ARROW_LEFT:"previous",ESCAPE:"close"})}return _createClass(e,[{key:"_init",value:function(){var t=this.$element.find("li.is-dropdown-submenu-parent");this.$element.children(".is-dropdown-submenu-parent").children(".is-dropdown-submenu").addClass("first-sub"),this.$menuItems=this.$element.find('[role="menuitem"]'),this.$tabs=this.$element.children('[role="menuitem"]'),this.$tabs.find("ul.is-dropdown-submenu").addClass(this.options.verticalClass),this.$element.hasClass(this.options.rightClass)||"right"===this.options.alignment||Foundation.rtl()||this.$element.parents(".top-bar-right").is("*")?(this.options.alignment="right",t.addClass("opens-left")):t.addClass("opens-right"),this.changed=!1,this._events()}},{key:"_isVertical",value:function(){return"block"===this.$tabs.css("display")}},{key:"_events",value:function(){var e=this,i="ontouchstart"in window||"undefined"!=typeof window.ontouchstart,n="is-dropdown-submenu-parent",s=function(s){var o=t(s.target).parentsUntil("ul","."+n),a=o.hasClass(n),r="true"===o.attr("data-is-click"),l=o.children(".is-dropdown-submenu");if(a)if(r){if(!e.options.closeOnClick||!e.options.clickOpen&&!i||e.options.forceFollow&&i)return;s.stopImmediatePropagation(),s.preventDefault(),e._hide(o)}else s.preventDefault(),s.stopImmediatePropagation(),e._show(l),o.add(o.parentsUntil(e.$element,"."+n)).attr("data-is-click",!0)};(this.options.clickOpen||i)&&this.$menuItems.on("click.zf.dropdownmenu touchstart.zf.dropdownmenu",s),e.options.closeOnClickInside&&this.$menuItems.on("click.zf.dropdownmenu",function(i){var s=t(this),o=s.hasClass(n);o||e._hide()}),this.options.disableHover||this.$menuItems.on("mouseenter.zf.dropdownmenu",function(i){var s=t(this),o=s.hasClass(n);o&&(clearTimeout(s.data("_delay")),s.data("_delay",setTimeout(function(){e._show(s.children(".is-dropdown-submenu"))},e.options.hoverDelay)))}).on("mouseleave.zf.dropdownmenu",function(i){var s=t(this),o=s.hasClass(n);if(o&&e.options.autoclose){if("true"===s.attr("data-is-click")&&e.options.clickOpen)return!1;clearTimeout(s.data("_delay")),s.data("_delay",setTimeout(function(){e._hide(s)},e.options.closingTime))}}),this.$menuItems.on("keydown.zf.dropdownmenu",function(i){var n,s,o=t(i.target).parentsUntil("ul",'[role="menuitem"]'),a=e.$tabs.index(o)>-1,r=a?e.$tabs:o.siblings("li").add(o);r.each(function(e){if(t(this).is(o))return n=r.eq(e-1),void(s=r.eq(e+1))});var l=function(){o.is(":last-child")||(s.children("a:first").focus(),i.preventDefault())},h=function(){n.children("a:first").focus(),i.preventDefault()},u=function(){var t=o.children("ul.is-dropdown-submenu");t.length&&(e._show(t),o.find("li > a:first").focus(),i.preventDefault())},d=function(){var t=o.parent("ul").parent("li");t.children("a:first").focus(),e._hide(t),i.preventDefault()},c={open:u,close:function(){e._hide(e.$element),e.$menuItems.find("a:first").focus(),i.preventDefault()},handled:function(){i.stopImmediatePropagation()}};a?e._isVertical()?Foundation.rtl()?t.extend(c,{down:l,up:h,next:d,previous:u}):t.extend(c,{down:l,up:h,next:u,previous:d}):Foundation.rtl()?t.extend(c,{next:h,previous:l,down:u,up:d}):t.extend(c,{next:l,previous:h,down:u,up:d}):Foundation.rtl()?t.extend(c,{next:d,previous:u,down:l,up:h}):t.extend(c,{next:u,previous:d,down:l,up:h}),Foundation.Keyboard.handleKey(i,"DropdownMenu",c)})}},{key:"_addBodyHandler",value:function(){var e=t(document.body),i=this;e.off("mouseup.zf.dropdownmenu touchend.zf.dropdownmenu").on("mouseup.zf.dropdownmenu touchend.zf.dropdownmenu",function(t){var n=i.$element.find(t.target);n.length||(i._hide(),e.off("mouseup.zf.dropdownmenu touchend.zf.dropdownmenu"))})}},{key:"_show",value:function(e){var i=this.$tabs.index(this.$tabs.filter(function(i,n){return t(n).find(e).length>0})),n=e.parent("li.is-dropdown-submenu-parent").siblings("li.is-dropdown-submenu-parent");this._hide(n,i),e.css("visibility","hidden").addClass("js-dropdown-active").parent("li.is-dropdown-submenu-parent").addClass("is-active");var s=Foundation.Box.ImNotTouchingYou(e,null,!0);if(!s){var o="left"===this.options.alignment?"-right":"-left",a=e.parent(".is-dropdown-submenu-parent");a.removeClass("opens"+o).addClass("opens-"+this.options.alignment),s=Foundation.Box.ImNotTouchingYou(e,null,!0),s||a.removeClass("opens-"+this.options.alignment).addClass("opens-inner"),this.changed=!0}e.css("visibility",""),this.options.closeOnClick&&this._addBodyHandler(),this.$element.trigger("show.zf.dropdownmenu",[e])}},{key:"_hide",value:function(t,e){var i;i=t&&t.length?t:void 0!==e?this.$tabs.not(function(t,i){return t===e}):this.$element;var n=i.hasClass("is-active")||i.find(".is-active").length>0;if(n){if(i.find("li.is-active").add(i).attr({"data-is-click":!1}).removeClass("is-active"),i.find("ul.js-dropdown-active").removeClass("js-dropdown-active"),this.changed||i.find("opens-inner").length){var s="left"===this.options.alignment?"right":"left";i.find("li.is-dropdown-submenu-parent").add(i).removeClass("opens-inner opens-"+this.options.alignment).addClass("opens-"+s),this.changed=!1}this.$element.trigger("hide.zf.dropdownmenu",[i])}}},{key:"destroy",value:function(){this.$menuItems.off(".zf.dropdownmenu").removeAttr("data-is-click").removeClass("is-right-arrow is-left-arrow is-down-arrow opens-right opens-left opens-inner"),t(document.body).off(".zf.dropdownmenu"),Foundation.Nest.Burn(this.$element,"dropdown"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={disableHover:!1,autoclose:!0,hoverDelay:50,clickOpen:!1,closingTime:500,alignment:"left",closeOnClick:!0,closeOnClickInside:!0,verticalClass:"vertical",rightClass:"align-right",forceFollow:!0},Foundation.plugin(e,"DropdownMenu")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}
506return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Equalizer")}return _createClass(e,[{key:"_init",value:function(){var e=this.$element.attr("data-equalizer")||"",i=this.$element.find('[data-equalizer-watch="'+e+'"]');this.$watched=i.length?i:this.$element.find("[data-equalizer-watch]"),this.$element.attr("data-resize",e||Foundation.GetYoDigits(6,"eq")),this.$element.attr("data-mutate",e||Foundation.GetYoDigits(6,"eq")),this.hasNested=this.$element.find("[data-equalizer]").length>0,this.isNested=this.$element.parentsUntil(document.body,"[data-equalizer]").length>0,this.isOn=!1,this._bindHandler={onResizeMeBound:this._onResizeMe.bind(this),onPostEqualizedBound:this._onPostEqualized.bind(this)};var n,s=this.$element.find("img");this.options.equalizeOn?(n=this._checkMQ(),t(window).on("changed.zf.mediaquery",this._checkMQ.bind(this))):this._events(),(void 0!==n&&n===!1||void 0===n)&&(s.length?Foundation.onImagesLoaded(s,this._reflow.bind(this)):this._reflow())}},{key:"_pauseEvents",value:function(){this.isOn=!1,this.$element.off({".zf.equalizer":this._bindHandler.onPostEqualizedBound,"resizeme.zf.trigger":this._bindHandler.onResizeMeBound,"mutateme.zf.trigger":this._bindHandler.onResizeMeBound})}},{key:"_onResizeMe",value:function(t){this._reflow()}},{key:"_onPostEqualized",value:function(t){t.target!==this.$element[0]&&this._reflow()}},{key:"_events",value:function(){this._pauseEvents(),this.hasNested?this.$element.on("postequalized.zf.equalizer",this._bindHandler.onPostEqualizedBound):(this.$element.on("resizeme.zf.trigger",this._bindHandler.onResizeMeBound),this.$element.on("mutateme.zf.trigger",this._bindHandler.onResizeMeBound)),this.isOn=!0}},{key:"_checkMQ",value:function(){var t=!Foundation.MediaQuery.is(this.options.equalizeOn);return t?this.isOn&&(this._pauseEvents(),this.$watched.css("height","auto")):this.isOn||this._events(),t}},{key:"_killswitch",value:function(){}},{key:"_reflow",value:function(){return!this.options.equalizeOnStack&&this._isStacked()?(this.$watched.css("height","auto"),!1):void(this.options.equalizeByRow?this.getHeightsByRow(this.applyHeightByRow.bind(this)):this.getHeights(this.applyHeight.bind(this)))}},{key:"_isStacked",value:function(){return!this.$watched[0]||!this.$watched[1]||this.$watched[0].getBoundingClientRect().top!==this.$watched[1].getBoundingClientRect().top}},{key:"getHeights",value:function(t){for(var e=[],i=0,n=this.$watched.length;i<n;i++)this.$watched[i].style.height="auto",e.push(this.$watched[i].offsetHeight);t(e)}},{key:"getHeightsByRow",value:function(e){var i=this.$watched.length?this.$watched.first().offset().top:0,n=[],s=0;n[s]=[];for(var o=0,a=this.$watched.length;o<a;o++){this.$watched[o].style.height="auto";var r=t(this.$watched[o]).offset().top;r!=i&&(s++,n[s]=[],i=r),n[s].push([this.$watched[o],this.$watched[o].offsetHeight])}for(var l=0,h=n.length;l<h;l++){var u=t(n[l]).map(function(){return this[1]}).get(),d=Math.max.apply(null,u);n[l].push(d)}e(n)}},{key:"applyHeight",value:function(t){var e=Math.max.apply(null,t);this.$element.trigger("preequalized.zf.equalizer"),this.$watched.css("height",e),this.$element.trigger("postequalized.zf.equalizer")}},{key:"applyHeightByRow",value:function(e){this.$element.trigger("preequalized.zf.equalizer");for(var i=0,n=e.length;i<n;i++){var s=e[i].length,o=e[i][s-1];if(s<=2)t(e[i][0][0]).css({height:"auto"});else{this.$element.trigger("preequalizedrow.zf.equalizer");for(var a=0,r=s-1;a<r;a++)t(e[i][a][0]).css({height:o});this.$element.trigger("postequalizedrow.zf.equalizer")}}this.$element.trigger("postequalized.zf.equalizer")}},{key:"destroy",value:function(){this._pauseEvents(),this.$watched.css("height","auto"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={equalizeOnStack:!1,equalizeByRow:!1,equalizeOn:""},Foundation.plugin(e,"Equalizer")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}
506return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,n),this.rules=[],this.currentPath="",this._init(),this._events(),Foundation.registerPlugin(this,"Interchange")}return _createClass(e,[{key:"_init",value:function(){this._addBreakpoints(),this._generateRules(),this._reflow()}},{key:"_events",value:function(){var e=this;t(window).on("resize.zf.interchange",Foundation.util.throttle(function(){e._reflow()},50))}},{key:"_reflow",value:function(){var t;for(var e in this.rules)if(this.rules.hasOwnProperty(e)){var i=this.rules[e];window.matchMedia(i.query).matches&&(t=i)}t&&this.replace(t.path)}},{key:"_addBreakpoints",value:function(){for(var t in Foundation.MediaQuery.queries)if(Foundation.MediaQuery.queries.hasOwnProperty(t)){var i=Foundation.MediaQuery.queries[t];e.SPECIAL_QUERIES[i.name]=i.value}}},{key:"_generateRules",value:function(t){var i,n=[];i=this.options.rules?this.options.rules:this.$element.data("interchange"),i="string"==typeof i?i.match(/\[.*?\]/g):i;for(var s in i)if(i.hasOwnProperty(s)){var o=i[s].slice(1,-1).split(", "),a=o.slice(0,-1).join(""),r=o[o.length-1];e.SPECIAL_QUERIES[r]&&(r=e.SPECIAL_QUERIES[r]),n.push({path:a,query:r})}this.rules=n}},{key:"replace",value:function(e){if(this.currentPath!==e){var i=this,n="replaced.zf.interchange";"IMG"===this.$element[0].nodeName?this.$element.attr("src",e).on("load",function(){i.currentPath=e}).trigger(n):e.match(/\.(gif|jpg|jpeg|png|svg|tiff)([?#].*)?/i)?this.$element.css({"background-image":"url("+e+")"}).trigger(n):t.get(e,function(s){i.$element.html(s).trigger(n),t(s).foundation(),i.currentPath=e})}}},{key:"destroy",value:function(){}}]),e}();e.defaults={rules:null},e.SPECIAL_QUERIES={landscape:"screen and (orientation: landscape)",portrait:"screen and (orientation: portrait)",retina:"only screen and (-webkit-min-device-pixel-ratio: 2), only screen and (min--moz-device-pixel-ratio: 2), only screen and (-o-min-device-pixel-ratio: 2/1), only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx)"},Foundation.plugin(e,"Interchange")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,
507"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),this.calcPoints(),Foundation.registerPlugin(this,"Magellan")}return _createClass(e,[{key:"_init",value:function(){var e=this.$element[0].id||Foundation.GetYoDigits(6,"magellan");this.$targets=t("[data-magellan-target]"),this.$links=this.$element.find("a"),this.$element.attr({"data-resize":e,"data-scroll":e,id:e}),this.$active=t(),this.scrollPos=parseInt(window.pageYOffset,10),this._events()}},{key:"calcPoints",value:function(){var e=this,i=document.body,n=document.documentElement;this.points=[],this.winHeight=Math.round(Math.max(window.innerHeight,n.clientHeight)),this.docHeight=Math.round(Math.max(i.scrollHeight,i.offsetHeight,n.clientHeight,n.scrollHeight,n.offsetHeight)),this.$targets.each(function(){var i=t(this),n=Math.round(i.offset().top-e.options.threshold);i.targetPoint=n,e.points.push(n)})}},{key:"_events",value:function(){var e=this;t("html, body"),{duration:e.options.animationDuration,easing:e.options.animationEasing};t(window).one("load",function(){e.options.deepLinking&&location.hash&&e.scrollToLoc(location.hash),e.calcPoints(),e._updateActive()}),this.$element.on({"resizeme.zf.trigger":this.reflow.bind(this),"scrollme.zf.trigger":this._updateActive.bind(this)}).on("click.zf.magellan",'a[href^="#"]',function(t){t.preventDefault();var i=this.getAttribute("href");e.scrollToLoc(i)}),t(window).on("popstate",function(t){e.options.deepLinking&&e.scrollToLoc(window.location.hash)})}},{key:"scrollToLoc",value:function(e){if(!t(e).length)return!1;this._inTransition=!0;var i=this,n=Math.round(t(e).offset().top-this.options.threshold/2-this.options.barOffset);t("html, body").stop(!0).animate({scrollTop:n},this.options.animationDuration,this.options.animationEasing,function(){i._inTransition=!1,i._updateActive()})}},{key:"reflow",value:function(){this.calcPoints(),this._updateActive()}},{key:"_updateActive",value:function(){if(!this._inTransition){var t,e=parseInt(window.pageYOffset,10);if(e+this.winHeight===this.docHeight)t=this.points.length-1;else if(e<this.points[0])t=void 0;else{var i=this.scrollPos<e,n=this,s=this.points.filter(function(t,s){return i?t-n.options.barOffset<=e:t-n.options.barOffset-n.options.threshold<=e});t=s.length?s.length-1:0}if(this.$active.removeClass(this.options.activeClass),this.$active=this.$links.filter('[href="#'+this.$targets.eq(t).data("magellan-target")+'"]').addClass(this.options.activeClass),this.options.deepLinking){var o="";void 0!=t&&(o=this.$active[0].getAttribute("href")),o!==window.location.hash&&(window.history.pushState?window.history.pushState(null,null,o):window.location.hash=o)}this.scrollPos=e,this.$element.trigger("update.zf.magellan",[this.$active])}}},{key:"destroy",value:function(){if(this.$element.off(".zf.trigger .zf.magellan").find("."+this.options.activeClass).removeClass(this.options.activeClass),this.options.deepLinking){var t=this.$active[0].getAttribute("href");window.location.hash.replace(t,"")}Foundation.unregisterPlugin(this)}}]),e}();e.defaults={animationDuration:500,animationEasing:"linear",threshold:50,activeClass:"active",deepLinking:!1,barOffset:0},Foundation.plugin(e,"Magellan")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}
507return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this.$lastTrigger=t(),this.$triggers=t(),this._init(),this._events(),Foundation.registerPlugin(this,"OffCanvas"),Foundation.Keyboard.register("OffCanvas",{ESCAPE:"close"})}return _createClass(e,[{key:"_init",value:function(){var e=this.$element.attr("id");if(this.$element.attr("aria-hidden","true"),this.$element.addClass("is-transition-"+this.options.transition),this.$triggers=t(document).find('[data-open="'+e+'"], [data-close="'+e+'"], [data-toggle="'+e+'"]').attr("aria-expanded","false").attr("aria-controls",e),this.options.contentOverlay===!0){var i=document.createElement("div"),n="fixed"===t(this.$element).css("position")?"is-overlay-fixed":"is-overlay-absolute";i.setAttribute("class","js-off-canvas-overlay "+n),this.$overlay=t(i),"is-overlay-fixed"===n?t("body").append(this.$overlay):this.$element.siblings("[data-off-canvas-content]").append(this.$overlay)}this.options.isRevealed=this.options.isRevealed||new RegExp(this.options.revealClass,"g").test(this.$element[0].className),this.options.isRevealed===!0&&(this.options.revealOn=this.options.revealOn||this.$element[0].className.match(/(reveal-for-medium|reveal-for-large)/g)[0].split("-")[2],this._setMQChecker()),!this.options.transitionTime==!0&&(this.options.transitionTime=1e3*parseFloat(window.getComputedStyle(t("[data-off-canvas]")[0]).transitionDuration))}},{key:"_events",value:function(){if(this.$element.off(".zf.trigger .zf.offcanvas").on({"open.zf.trigger":this.open.bind(this),"close.zf.trigger":this.close.bind(this),"toggle.zf.trigger":this.toggle.bind(this),"keydown.zf.offcanvas":this._handleKeyboard.bind(this)}),this.options.closeOnClick===!0){var e=this.options.contentOverlay?this.$overlay:t("[data-off-canvas-content]");e.on({"click.zf.offcanvas":this.close.bind(this)})}}},{key:"_setMQChecker",value:function(){var e=this;t(window).on("changed.zf.mediaquery",function(){Foundation.MediaQuery.atLeast(e.options.revealOn)?e.reveal(!0):e.reveal(!1)}).one("load.zf.offcanvas",function(){Foundation.MediaQuery.atLeast(e.options.revealOn)&&e.reveal(!0)})}},{key:"reveal",value:function(t){var e=this.$element.find("[data-close]");t?(this.close(),this.isRevealed=!0,this.$element.attr("aria-hidden","false"),this.$element.off("open.zf.trigger toggle.zf.trigger"),e.length&&e.hide()):(this.isRevealed=!1,this.$element.attr("aria-hidden","true"),this.$element.on({"open.zf.trigger":this.open.bind(this),"toggle.zf.trigger":this.toggle.bind(this)}),e.length&&e.show())}},{key:"_stopScrolling",value:function(t){return!1}},{key:"_recordScrollable",value:function(t){var e=this;e.scrollHeight!==e.clientHeight&&(0===e.scrollTop&&(e.scrollTop=1),e.scrollTop===e.scrollHeight-e.clientHeight&&(e.scrollTop=e.scrollHeight-e.clientHeight-1)),e.allowUp=e.scrollTop>0,e.allowDown=e.scrollTop<e.scrollHeight-e.clientHeight,e.lastY=t.originalEvent.pageY}},{key:"_stopScrollPropagation",value:function(t){var e=this,i=t.pageY<e.lastY,n=!i;e.lastY=t.pageY,i&&e.allowUp||n&&e.allowDown?t.stopPropagation():t.preventDefault()}},{key:"open",value:function(e,i){if(!this.$element.hasClass("is-open")&&!this.isRevealed){var n=this;i&&(this.$lastTrigger=i),"top"===this.options.forceTo?window.scrollTo(0,0):"bottom"===this.options.forceTo&&window.scrollTo(0,document.body.scrollHeight),n.$element.addClass("is-open"),this.$triggers.attr("aria-expanded","true"),this.$element.attr("aria-hidden","false").trigger("opened.zf.offcanvas"),this.options.contentScroll===!1&&(t("body").addClass("is-off-canvas-open").on("touchmove",this._stopScrolling),this.$element.on("touchstart",this._recordScrollable),this.$element.on("touchmove",this._stopScrollPropagation)),this.options.contentOverlay===!0&&this.$overlay.addClass("is-visible"),this.options.closeOnClick===!0&&this.options.contentOverlay===!0&&this.$overlay.addClass("is-closable"),this.options.autoFocus===!0&&this.$element.one(Foundation.transitionend(this.$element),function(){n.$element.find("a, button").eq(0).focus()}),this.options.trapFocus===!0&&(this.$element.siblings("[data-off-canvas-content]").attr("tabindex","-1"),Foundation.Keyboard.trapFocus(this.$element))}}},{key:"close",value:function(e){if(this.$element.hasClass("is-open")&&!this.isRevealed){var i=this;i.$element.removeClass("is-open"),this.$element.attr("aria-hidden","true").trigger("closed.zf.offcanvas"),this.options.contentScroll===!1&&(t("body").removeClass("is-off-canvas-open").off("touchmove",this._stopScrolling),this.$element.off("touchstart",this._recordScrollable),this.$element.off("touchmove",this._stopScrollPropagation)),this.options.contentOverlay===!0&&this.$overlay.removeClass("is-visible"),this.options.closeOnClick===!0&&this.options.contentOverlay===!0&&this.$overlay.removeClass("is-closable"),this.$triggers.attr("aria-expanded","fal
507se"),this.options.trapFocus===!0&&(this.$element.siblings("[data-off-canvas-content]").removeAttr("tabindex"),Foundation.Keyboard.releaseFocus(this.$element))}}},{key:"toggle",value:function(t,e){this.$element.hasClass("is-open")?this.close(t,e):this.open(t,e)}},{key:"_handleKeyboard",value:function(t){var e=this;Foundation.Keyboard.handleKey(t,"OffCanvas",{close:function(){return e.close(),e.$lastTrigger.focus(),!0},handled:function(){t.stopPropagation(),t.preventDefault()}})}},{key:"destroy",value:function(){this.close(),this.$element.off(".zf.trigger .zf.offcanvas"),this.$overlay.off(".zf.offcanvas"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={closeOnClick:!0,contentOverlay:!0,contentScroll:!0,transitionTime:0,transition:"push",forceTo:null,isRevealed:!1,revealOn:null,autoFocus:!0,revealClass:"reveal-for-",trapFocus:!1},Foundation.plugin(e,"OffCanvas")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Orbit"),Foundation.Keyboard.register("Orbit",{ltr:{ARROW_RIGHT:"next",ARROW_LEFT:"previous"},rtl:{ARROW_LEFT:"next",ARROW_RIGHT:"previous"}})}return _createClass(e,[{key:"_init",value:function(){this._reset(),this.$wrapper=this.$element.find("."+this.options.containerClass),this.$slides=this.$element.find("."+this.options.slideClass);var t=this.$element.find("img"),e=this.$slides.filter(".is-active"),i=this.$element[0].id||Foundation.GetYoDigits(6,"orbit");this.$element.attr({"data-resize":i,id:i}),e.length||this.$slides.eq(0).addClass("is-active"),this.options.useMUI||this.$slides.addClass("no-motionui"),t.length?Foundation.onImagesLoaded(t,this._prepareForOrbit.bind(this)):this._prepareForOrbit(),this.options.bullets&&this._loadBullets(),this._events(),this.options.autoPlay&&this.$slides.length>1&&this.geoSync(),this.options.accessible&&this.$wrapper.attr("tabindex",0)}},{key:"_loadBullets",value:function(){this.$bullets=this.$element.find("."+this.options.boxOfBullets).find("button")}},{key:"geoSync",value:function(){var t=this;this.timer=new Foundation.Timer(this.$element,{duration:this.options.timerDelay,infinite:!1},function(){t.changeSlide(!0)}),this.timer.start()}},{key:"_prepareForOrbit",value:function(){this._setWrapperHeight()}},{key:"_setWrapperHeight",value:function(e){var i,n=0,s=0,o=this;this.$slides.each(function(){i=this.getBoundingClientRect().height,t(this).attr("data-slide",s),o.$slides.filter(".is-active")[0]!==o.$slides.eq(s)[0]&&t(this).css({position:"relative",display:"none"}),n=i>n?i:n,s++}),s===this.$slides.length&&(this.$wrapper.css({height:n}),e&&e(n))}},{key:"_setSlideHeight",value:function(e){this.$slides.each(function(){t(this).css("max-height",e)})}},{key:"_events",value:function(){var e=this;if(this.$element.off(".resizeme.zf.trigger").on({"resizeme.zf.trigger":this._prepareForOrbit.bind(this)}),this.$slides.length>1){if(this.options.swipe&&this.$slides.off("swipeleft.zf.orbit swiperight.zf.orbit").on("swipeleft.zf.orbit",function(t){t.preventDefault(),e.changeSlide(!0)}).on("swiperight.zf.orbit",function(t){t.preventDefault(),e.changeSlide(!1)}),this.options.autoPlay&&(this.$slides.on("click.zf.orbit",function(){e.$element.data("clickedOn",!e.$element.data("clickedOn")),e.timer[e.$element.data("clickedOn")?"pause":"start"]()}),this.options.pauseOnHover&&this.$element.on("mouseenter.zf.orbit",function(){e.timer.pause()}).on("mouseleave.zf.orbit",function(){e.$element.data("clickedOn")||e.timer.start()})),this.options.navButtons){var i=this.$element.find("."+this.options.nextClass+", ."+this.options.prevClass);i.attr("tabindex",0).on("click.zf.orbit touchend.zf.orbit",function(i){i.preventDefault(),e.changeSlide(t(this).hasClass(e.options.nextClass))})}this.options.bullets&&this.$bullets.on("click.zf.orbit touchend.zf.orbit",function(){if(/is-active/g.test(this.className))return!1;var i=t(this).data("slide"),n=i>e.$slides.filter(".is-active").data("slide"),s=e.$slides.eq(i);e.changeSlide(n,s,i)}),this.options.accessible&&this.$wrapper.add(this.$bullets).on("keydown.zf.orbit",function(i){Foundation.Keyboard.handleKey(i,"Orb
507it",{next:function(){e.changeSlide(!0)},previous:function(){e.changeSlide(!1)},handled:function(){t(i.target).is(e.$bullets)&&e.$bullets.filter(".is-active").focus()}})})}}},{key:"_reset",value:function(){"undefined"!=typeof this.$slides&&this.$slides.length>1&&(this.$element.off(".zf.orbit").find("*").off(".zf.orbit"),this.options.autoPlay&&this.timer.restart(),this.$slides.each(function(e){t(e).removeClass("is-active is-active is-in").removeAttr("aria-live").hide()}),this.$slides.first().addClass("is-active").show(),this.$element.trigger("slidechange.zf.orbit",[this.$slides.first()]),this.options.bullets&&this._updateBullets(0))}},{key:"changeSlide",value:function(t,e,i){if(this.$slides){var n=this.$slides.filter(".is-active").eq(0);if(/mui/g.test(n[0].className))return!1;var s,o=this.$slides.first(),a=this.$slides.last(),r=t?"Right":"Left",l=t?"Left":"Right",h=this;s=e?e:t?this.options.infiniteWrap?n.next("."+this.options.slideClass).length?n.next("."+this.options.slideClass):o:n.next("."+this.options.slideClass):this.options.infiniteWrap?n.prev("."+this.options.slideClass).length?n.prev("."+this.options.slideClass):a:n.prev("."+this.options.slideClass),s.length&&(this.$element.trigger("beforeslidechange.zf.orbit",[n,s]),this.options.bullets&&(i=i||this.$slides.index(s),this._updateBullets(i)),this.options.useMUI&&!this.$element.is(":hidden")?(Foundation.Motion.animateIn(s.addClass("is-active").css({position:"absolute",top:0}),this.options["animInFrom"+r],function(){s.css({position:"relative",display:"block"}).attr("aria-live","polite")}),Foundation.Motion.animateOut(n.removeClass("is-active"),this.options["animOutTo"+l],function(){n.removeAttr("aria-live"),h.options.autoPlay&&!h.timer.isPaused&&h.timer.restart()})):(n.removeClass("is-active is-in").removeAttr("aria-live").hide(),s.addClass("is-active is-in").attr("aria-live","polite").show(),this.options.autoPlay&&!this.timer.isPaused&&this.timer.restart()),this.$element.trigger("slidechange.zf.orbit",[s]))}}},{key:"_updateBullets",value:function(t){var e=this.$element.find("."+this.options.boxOfBullets).find(".is-active").removeClass("is-active").blur(),i=e.find("span:last").detach();this.$bullets.eq(t).addClass("is-active").append(i)}},{key:"destroy",value:function(){this.$element.off(".zf.orbit").find("*").off(".zf.orbit").end().hide(),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={bullets:!0,navButtons:!0,animInFromRight:"slide-in-right",animOutToRight:"slide-out-right",animInFromLeft:"slide-in-left",animOutToLeft:"slide-out-left",autoPlay:!0,timerDelay:5e3,infiniteWrap:!0,swipe:!0,pauseOnHover:!0,accessible:!0,containerClass:"orbit-container",slideClass:"orbit-slide",boxOfBullets:"orbit-bullets",nextClass:"orbit-next",prevClass:"orbit-previous",useMUI:!0},Foundation.plugin(e,"Orbit")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=t(i),this.rules=this.$element.data("responsive-menu"),this.currentMq=null,this.currentPlugin=null,this._init(),this._events(),Foundation.registerPlugin(this,"ResponsiveMenu")}return _createClass(e,[{key:"_init",value:function(){if("string"==typeof this.rules){for(var e={},n=this.rules.split(" "),s=0;s<n.length;s++){var o=n[s].split("-"),a=o.length>1?o[0]:"small",r=o.length>1?o[1]:o[0];null!==i[r]&&(e[a]=i[r])}this.rules=e}t.isEmptyObject(this.rules)||this._checkMediaQueries(),this.$element.attr("data-mutate",this.$element.attr("data-mutate")||Foundation.GetYoDigits(6,"responsive-menu"))}},{key:"_events",value:function(){var e=this;t(window).on("changed.zf.mediaquery",function(){e._checkMediaQueries()})}},{key:"_checkMediaQueries",value:function(){var e,n=this;t.each(this.rules,function(t){Foundation.MediaQuery.atLeast(t)&&(e=t)}),e&&(this.currentPlugin instanceof this.rules[e].plugin||(t.each(i,function(t,e){n.$element.removeClass(e.cssClass)}),this.$element.addClass(this.rules[e].cssClass),this.currentPlugin&&this.currentPlugin.destroy(),this.currentPlugin=new this.rules[e].plugin(this.$element,{}
507)))}},{key:"destroy",value:function(){this.currentPlugin.destroy(),t(window).off(".zf.ResponsiveMenu"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={};var i={dropdown:{cssClass:"dropdown",plugin:Foundation._plugins["dropdown-menu"]||null},drilldown:{cssClass:"drilldown",plugin:Foundation._plugins.drilldown||null},accordion:{cssClass:"accordion-menu",plugin:Foundation._plugins["accordion-menu"]||null}};Foundation.plugin(e,"ResponsiveMenu")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=t(i),this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),this._events(),Foundation.registerPlugin(this,"ResponsiveToggle")}return _createClass(e,[{key:"_init",value:function(){var e=this.$element.data("responsive-toggle");if(e||console.error("Your tab bar needs an ID of a Menu as the value of data-tab-bar."),this.$targetMenu=t("#"+e),this.$toggler=this.$element.find("[data-toggle]").filter(function(){var i=t(this).data("toggle");return i===e||""===i}),this.options=t.extend({},this.options,this.$targetMenu.data()),this.options.animate){var i=this.options.animate.split(" ");this.animationIn=i[0],this.animationOut=i[1]||null}this._update()}},{key:"_events",value:function(){this._updateMqHandler=this._update.bind(this),t(window).on("changed.zf.mediaquery",this._updateMqHandler),this.$toggler.on("click.zf.responsiveToggle",this.toggleMenu.bind(this))}},{key:"_update",value:function(){Foundation.MediaQuery.atLeast(this.options.hideFor)?(this.$element.hide(),this.$targetMenu.show()):(this.$element.show(),this.$targetMenu.hide())}},{key:"toggleMenu",value:function(){var t=this;Foundation.MediaQuery.atLeast(this.options.hideFor)||(this.options.animate?this.$targetMenu.is(":hidden")?Foundation.Motion.animateIn(this.$targetMenu,this.animationIn,function(){t.$element.trigger("toggled.zf.responsiveToggle"),t.$targetMenu.find("[data-mutate]").triggerHandler("mutateme.zf.trigger")}):Foundation.Motion.animateOut(this.$targetMenu,this.animationOut,function(){t.$element.trigger("toggled.zf.responsiveToggle")}):(this.$targetMenu.toggle(0),this.$targetMenu.find("[data-mutate]").trigger("mutateme.zf.trigger"),this.$element.trigger("toggled.zf.responsiveToggle")))}},{key:"destroy",value:function(){this.$element.off(".zf.responsiveToggle"),this.$toggler.off(".zf.responsiveToggle"),t(window).off("changed.zf.mediaquery",this._updateMqHandler),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={hideFor:"medium",animate:!1},Foundation.plugin(e,"ResponsiveToggle")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){function e(){return/iP(ad|hone|od).*OS/.test(window.navigator.userAgent)}function i(){return/Android/.test(window.navigator.userAgent)}function n(){return e()||i()}var s=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Reveal"),Foundation.Keyboard.register("Reveal",{ENTER:"open",SPACE:"open",ESCAPE:"close"})}return _createClass(e,[{key:"_init",value:function(){this.id=this.$element.attr("id"),this.isActive=!1,this.cached={mq:Foundation.MediaQuery.current},this.isMobile=n(),this.$anchor=t(t('[data-open="'+this.id+'"]').length?'[data-open="'+this.id+'"]':'[data-toggle="'+this.id+'"]'),this.$anchor.attr({"aria-controls":this.id,"aria-haspopup":!0,tabindex:0}),(this.options.fullScreen||this.$element.hasClass("full"))&&(this.options.fullScreen=!0,this.options.overlay=!1),this.options.overlay&&!this.$overlay&&(this.$overlay=this._makeOverlay(this.id)),this.$element.attr({role:"dialog","aria-hidden":!0,"data-yeti-box":this.id,"data-resize":this.id}),this.$overlay?this.$element.detach().appendTo(this.$overlay):(this.$element.detach().appendTo(t(this.options.appendTo)),this.$element.addClass("without-overlay")),this._events(),this.options.deepLink&&window.location.hash==="#"+this.id&&t(window).one("load.zf.reveal",this.open.bind(this))}},{key:"_makeOverlay",value:function(){return t("<div></div>").addClass("reveal-overlay").appendTo(this.options.appendTo)}},{key:"_updatePosition",value:function(){var e,i,n=this.$element.outerWidth(),s=t(window).width(),o=this.$element.outerHeight(),a=t(window).height();e="auto"===this.options.hOffset?parseInt((s-n)/2,10):parseInt(this.options.hOffset,10),i="auto"===this.options.vOffset?o>a?parseInt(Math.min(100,a/10),10):parseInt((a-o)/4,10):parseInt(this.options.vOffset,10),this.$element.css({top:i+"px"}),this.$overlay&&"auto"===this.options.hOffset||(this.$element.css({left:e+"px"}),this.$element.css({margin:"0px"}))}},{key:"_events",value:function(){var e=this,i=this;this.$element.on({"open.zf.trigger":this.open.bind(this),"close.zf.trigger":function(n,s){if(n.target===i.$element[0]||t(n.target).parents("[data-closable]")[0]===s)return e.close.apply(e)},"toggle.zf.trigger":this.toggle.bind(this),"resizeme.zf.trigger":function(){i._updatePosition()}}
507),this.$anchor.length&&this.$anchor.on("keydown.zf.reveal",function(t){13!==t.which&&32!==t.which||(t.stopPropagation(),t.preventDefault(),i.open())}),this.options.closeOnClick&&this.options.overlay&&this.$overlay.off(".zf.reveal").on("click.zf.reveal",function(e){e.target!==i.$element[0]&&!t.contains(i.$element[0],e.target)&&t.contains(document,e.target)&&i.close()}),this.options.deepLink&&t(window).on("popstate.zf.reveal:"+this.id,this._handleState.bind(this))}},{key:"_handleState",value:function(t){window.location.hash!=="#"+this.id||this.isActive?this.close():this.open()}},{key:"open",value:function(){function e(){s.isMobile?(s.originalScrollPos||(s.originalScrollPos=window.pageYOffset),t("html, body").addClass("is-reveal-open")):t("body").addClass("is-reveal-open")}var i=this;if(this.options.deepLink){var n="#"+this.id;window.history.pushState?window.history.pushState(null,null,n):window.location.hash=n}this.isActive=!0,this.$element.css({visibility:"hidden"}).show().scrollTop(0),this.options.overlay&&this.$overlay.css({visibility:"hidden"}).show(),this._updatePosition(),this.$element.hide().css({visibility:""}),this.$overlay&&(this.$overlay.css({visibility:""}).hide(),this.$element.hasClass("fast")?this.$overlay.addClass("fast"):this.$element.hasClass("slow")&&this.$overlay.addClass("slow")),this.options.multipleOpened||this.$element.trigger("closeme.zf.reveal",this.id);var s=this;this.options.animationIn?!function(){var t=function(){s.$element.attr({"aria-hidden":!1,tabindex:-1}).focus(),e(),Foundation.Keyboard.trapFocus(s.$element)};i.options.overlay&&Foundation.Motion.animateIn(i.$overlay,"fade-in"),Foundation.Motion.animateIn(i.$element,i.options.animationIn,function(){i.$element&&(i.focusableElements=Foundation.Keyboard.findFocusable(i.$element),t())})}():(this.options.overlay&&this.$overlay.show(0),this.$element.show(this.options.showDelay)),this.$element.attr({"aria-hidden":!1,tabindex:-1}).focus(),Foundation.Keyboard.trapFocus(this.$element),this.$element.trigger("open.zf.reveal"),e(),setTimeout(function(){i._extraHandlers()},0)}},{key:"_extraHandlers",value:function(){var e=this;this.$element&&(this.focusableElements=Foundation.Keyboard.findFocusable(this.$element),this.options.overlay||!this.options.closeOnClick||this.options.fullScreen||t("body").on("click.zf.reveal",function(i){i.target!==e.$element[0]&&!t.contains(e.$element[0],i.target)&&t.contains(document,i.target)&&e.close()}),this.options.closeOnEsc&&t(window).on("keydown.zf.reveal",function(t){Foundation.Keyboard.handleKey(t,"Reveal",{close:function(){e.options.closeOnEsc&&(e.close(),e.$anchor.focus())}})}),this.$element.on("keydown.zf.reveal",function(i){var n=t(this);Foundation.Keyboard.handleKey(i,"Reveal",{open:function(){e.$element.find(":focus").is(e.$element.find("[data-close]"))?setTimeout(function(){e.$anchor.focus()},1):n.is(e.focusableElements)&&e.open()},close:function(){e.options.closeOnEsc&&(e.close(),e.$anchor.focus())},handled:function(t){t&&i.preventDefault()}})}))}},{key:"close",value:function(){function e(){i.isMobile?(t("html, body").removeClass("is-reveal-open"),i.originalScrollPos&&(t("body").scrollTop(i.originalScrollPos),i.originalScrollPos=null)):t("body").removeClass("is-reveal-open"),Foundation.Keyboard.releaseFocus(i.$element),i.$element.attr("aria-hidden",!0),i.$element.trigger("closed.zf.reveal")}if(!this.isActive||!this.$element.is(":visible"))return!1;var i=this;this.options.animationOut?(this.options.overlay?Foundation.Motion.animateOut(this.$overlay,"fade-out",e):e(),Foundation.Motion.animateOut(this.$element,this.options.animationOut)):(this.options.overlay?this.$overlay.hide(0,e):e(),this.$element.hide(this.options.hideDelay)),this.options.closeOnEsc&&t(window).off("keydown.zf.reveal"),!this.options.overlay&&this.options.closeOnClick&&t("body").off("click.zf.reveal"),this.$element.off("keydown.zf.reveal"),this.options.resetOnClose&&this.$element.html(this.$element.html()),this.isActive=!1,i.options.deepLink&&(window.history.replaceState?window.history.replaceState("",document.title,window.location.href.replace("#"+this.id,"")):window.location.hash="")}},{key:"toggle",value:function(){this.isActive?this.close():this.open()}},{key:"destroy",value:function(){this.options.overlay&&(this.$element.appendTo(t(this.options.appendTo)),this.$overlay.hide().off().remove()),this.$element.hide().off(),this.$anchor.off(".zf"),t(window).off(".zf.reveal:"+this.id
507),Foundation.unregisterPlugin(this)}}]),e}();s.defaults={animationIn:"",animationOut:"",showDelay:0,hideDelay:0,closeOnClick:!0,closeOnEsc:!0,multipleOpened:!1,vOffset:"auto",hOffset:"auto",fullScreen:!1,btmOffsetPct:10,overlay:!0,resetOnClose:!1,deepLink:!1,appendTo:"body"},Foundation.plugin(s,"Reveal")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){function e(t,e){return t/e}function i(t,e,i,n){return Math.abs(t.position()[e]+t[n]()/2-i)}function n(t,e){return Math.log(e)/Math.log(t)}var s=function(){function s(e,i){_classCallCheck(this,s),this.$element=e,this.options=t.extend({},s.defaults,this.$element.data(),i),this._init(),Foundation.registerPlugin(this,"Slider"),Foundation.Keyboard.register("Slider",{ltr:{ARROW_RIGHT:"increase",ARROW_UP:"increase",ARROW_DOWN:"decrease",ARROW_LEFT:"decrease",SHIFT_ARROW_RIGHT:"increase_fast",SHIFT_ARROW_UP:"increase_fast",SHIFT_ARROW_DOWN:"decrease_fast",SHIFT_ARROW_LEFT:"decrease_fast"},rtl:{ARROW_LEFT:"increase",ARROW_RIGHT:"decrease",SHIFT_ARROW_LEFT:"increase_fast",SHIFT_ARROW_RIGHT:"decrease_fast"}})}return _createClass(s,[{key:"_init",value:function(){this.inputs=this.$element.find("input"),this.handles=this.$element.find("[data-slider-handle]"),this.$handle=this.handles.eq(0),this.$input=this.inputs.length?this.inputs.eq(0):t("#"+this.$handle.attr("aria-controls")),this.$fill=this.$element.find("[data-slider-fill]").css(this.options.vertical?"height":"width",0);var e=!1;(this.options.disabled||this.$element.hasClass(this.options.disabledClass))&&(this.options.disabled=!0,this.$element.addClass(this.options.disabledClass)),this.inputs.length||(this.inputs=t().add(this.$input),this.options.binding=!0),this._setInitAttr(0),this.handles[1]&&(this.options.doubleSided=!0,this.$handle2=this.handles.eq(1),this.$input2=this.inputs.length>1?this.inputs.eq(1):t("#"+this.$handle2.attr("aria-controls")),this.inputs[1]||(this.inputs=this.inputs.add(this.$input2)),e=!0,this._setInitAttr(1)),this.setHandles(),this._events()}},{key:"setHandles",value:function(){var t=this;this.handles[1]?this._setHandlePos(this.$handle,this.inputs.eq(0).val(),!0,function(){t._setHandlePos(t.$handle2,t.inputs.eq(1).val(),!0)}):this._setHandlePos(this.$handle,this.inputs.eq(0).val(),!0)}},{key:"_reflow",value:function(){this.setHandles()}},{key:"_pctOfBar",value:function(t){var i=e(t-this.options.start,this.options.end-this.options.start);switch(this.options.positionValueFunction){case"pow":i=this._logTransform(i);break;case"log":i=this._powTransform(i)}return i.toFixed(2)}},{key:"_value",value:function(t){switch(this.options.positionValueFunction){case"pow":t=this._powTransform(t);break;case"log":t=this._logTransform(t)}var e=(this.options.end-this.options.start)*t+this.options.start;return e}},{key:"_logTransform",value:function(t){return n(this.options.nonLinearBase,t*(this.options.nonLinearBase-1)+1)}},{key:"_powTransform",value:function(t){return(Math.pow(this.options.nonLinearBase,t)-1)/(this.options.nonLinearBase-1)}},{key:"_setHandlePos",value:function(t,i,n,s){if(!this.$element.hasClass(this.options.disabledClass)){i=parseFloat(i),i<this.options.start?i=this.options.start:i>this.options.end&&(i=this.options.end);var o=this.options.doubleSided;if(o)if(0===this.handles.index(t)){var a=parseFloat(this.$handle2.attr("aria-valuenow"));i=i>=a?a-this.options.step:i}else{var r=parseFloat(this.$handle.attr("aria-valuenow"));i=i<=r?r+this.options.step:i}this.options.vertical&&!n&&(i=this.options.end-i);var l=this,h=this.options.vertical,u=h?"height":"width",d=h?"top":"left",c=t[0].getBoundingClientRect()[u],f=this.$element[0].getBoundingClientRect()[u],p=this._pctOfBar(i),m=(f-c)*p,g=(100*e(m,f)).toFixed(this.options.decimal);i=parseFloat(i.toFixed(this.options.decimal));var v={};if(this._setValues(t,i),o){var y,w=0===this.handles.index(t),b=~~(100*e(c,f));
507if(w)v[d]=g+"%",y=parseFloat(this.$handle2[0].style[d])-g+b,s&&"function"==typeof s&&s();else{var $=parseFloat(this.$handle[0].style[d]);y=g-(isNaN($)?(this.options.initialStart-this.options.start)/((this.options.end-this.options.start)/100):$)+b}v["min-"+u]=y+"%"}this.$element.one("finished.zf.animate",function(){l.$element.trigger("moved.zf.slider",[t])});var C=this.$element.data("dragging")?1e3/60:this.options.moveTime;Foundation.Move(C,t,function(){isNaN(g)?t.css(d,100*p+"%"):t.css(d,g+"%"),l.options.doubleSided?l.$fill.css(v):l.$fill.css(u,100*p+"%")}),clearTimeout(l.timeout),l.timeout=setTimeout(function(){l.$element.trigger("changed.zf.slider",[t])},l.options.changedDelay)}}},{key:"_setInitAttr",value:function(t){var e=0===t?this.options.initialStart:this.options.initialEnd,i=this.inputs.eq(t).attr("id")||Foundation.GetYoDigits(6,"slider");
508this.inputs.eq(t).attr({id:i,max:this.options.end,min:this.options.start,step:this.options.step}),this.inputs.eq(t).val(e),this.handles.eq(t).attr({role:"slider","aria-controls":i,"aria-valuemax":this.options.end,"aria-valuemin":this.options.start,"aria-valuenow":e,"aria-orientation":this.options.vertical?"vertical":"horizontal",tabindex:0})}},{key:"_setValues",value:function(t,e){var i=this.options.doubleSided?this.handles.index(t):0;this.inputs.eq(i).val(e),t.attr("aria-valuenow",e)}},{key:"_handleEvent",value:function(n,s,o){var a,r;if(o)a=this._adjustValue(null,o),r=!0;else{n.preventDefault();var l=this,h=this.options.vertical,u=h?"height":"width",d=h?"top":"left",c=h?n.pageY:n.pageX,f=(this.$handle[0].getBoundingClientRect()[u]/2,this.$element[0].getBoundingClientRect()[u]),p=h?t(window).scrollTop():t(window).scrollLeft(),m=this.$element.offset()[d];n.clientY===n.pageY&&(c+=p);var g,v=c-m;g=v<0?0:v>f?f:v;var y=e(g,f);if(a=this._value(y),Foundation.rtl()&&!this.options.vertical&&(a=this.options.end-a),a=l._adjustValue(null,a),r=!1,!s){var w=i(this.$handle,d,g,u),b=i(this.$handle2,d,g,u);s=w<=b?this.$handle:this.$handle2}}this._setHandlePos(s,a,r)}},{key:"_adjustValue",value:function(t,e){var i,n,s,o,a=this.options.step,r=parseFloat(a/2);return i=t?parseFloat(t.attr("aria-valuenow")):e,n=i%a,s=i-n,o=s+a,0===n?i:i=i>=s+r?o:s}},{key:"_events",value:function(){this._eventsForHandle(this.$handle),this.handles[1]&&this._eventsForHandle(this.$handle2)}},{key:"_eventsForHandle",value:function(e){var i,n=this;if(this.inputs.off("change.zf.slider").on("change.zf.slider",function(e){var i=n.inputs.index(t(this));n._handleEvent(e,n.handles.eq(i),t(this).val())}),this.options.clickSelect&&this.$element.off("click.zf.slider").on("click.zf.slider",function(e){return!n.$element.data("dragging")&&void(t(e.target).is("[data-slider-handle]")||(n.options.doubleSided?n._handleEvent(e):n._handleEvent(e,n.$handle)))}),this.options.draggable){this.handles.addTouch();var s=t("body");e.off("mousedown.zf.slider").on("mousedown.zf.slider",function(o){e.addClass("is-dragging"),n.$fill.addClass("is-dragging"),n.$element.data("dragging",!0),i=t(o.currentTarget),s.on("mousemove.zf.slider",function(t){t.preventDefault(),n._handleEvent(t,i)}).on("mouseup.zf.slider",function(t){n._handleEvent(t,i),e.removeClass("is-dragging"),n.$fill.removeClass("is-dragging"),n.$element.data("dragging",!1),s.off("mousemove.zf.slider mouseup.zf.slider")})}).on("selectstart.zf.slider touchmove.zf.slider",function(t){t.preventDefault()})}e.off("keydown.zf.slider").on("keydown.zf.slider",function(e){var i,s=t(this),o=n.options.doubleSided?n.handles.index(s):0,a=parseFloat(n.inputs.eq(o).val());Foundation.Keyboard.handleKey(e,"Slider",{decrease:function(){i=a-n.options.step},increase:function(){i=a+n.options.step},decrease_fast:function(){i=a-10*n.options.step},increase_fast:function(){i=a+10*n.options.step},handled:function(){e.preventDefault(),n._setHandlePos(s,i,!0)}})})}},{key:"destroy",value:function(){this.handles.off(".zf.slider"),this.inputs.off(".zf.slider"),this.$element.off(".zf.slider"),clearTimeout(this.timeout),Foundation.unregisterPlugin(this)}}]),s}();s.defaults={start:0,end:100,step:1,initialStart:0,initialEnd:100,binding:!1,clickSelect:!0,vertical:!1,draggable:!0,disabled:!1,doubleSided:!1,decimal
508:2,moveTime:200,disabledClass:"disabled",invertVertical:!1,changedDelay:500,nonLinearBase:5,positionValueFunction:"linear"},Foundation.plugin(s,"Slider")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){function e(t){return parseInt(window.getComputedStyle(document.body,null).fontSize,10)*t}var i=function(){function i(e,n){_classCallCheck(this,i),this.$element=e,this.options=t.extend({},i.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Sticky")}return _createClass(i,[{key:"_init",value:function(){var e=this.$element.parent("[data-sticky-container]"),i=this.$element[0].id||Foundation.GetYoDigits(6,"sticky"),n=this;e.length||(this.wasWrapped=!0),this.$container=e.length?e:t(this.options.container).wrapInner(this.$element),this.$container.addClass(this.options.containerClass),this.$element.addClass(this.options.stickyClass).attr({"data-resize":i}),this.scrollCount=this.options.checkEvery,this.isStuck=!1,t(window).one("load.zf.sticky",function(){n.containerHeight="none"==n.$element.css("display")?0:n.$element[0].getBoundingClientRect().height,n.$container.css("height",n.containerHeight),n.elemHeight=n.containerHeight,""!==n.options.anchor?n.$anchor=t("#"+n.options.anchor):n._parsePoints(),n._setSizes(function(){var t=window.pageYOffset;n._calc(!1,t),n.isStuck||n._removeSticky(!(t>=n.topPoint))}),n._events(i.split("-").reverse().join("-"))})}},{key:"_parsePoints",value:function(){for(var e=""==this.options.topAnchor?1:this.options.topAnchor,i=""==this.options.btmAnchor?document.documentElement.scrollHeight:this.options.btmAnchor,n=[e,i],s={},o=0,a=n.length;o<a&&n[o];o++){var r;if("number"==typeof n[o])r=n[o];else{var l=n[o].split(":"),h=t("#"+l[0]);r=h.offset().top,l[1]&&"bottom"===l[1].toLowerCase()&&(r+=h[0].getBoundingClientRect().height)}s[o]=r}this.points=s}},{key:"_events",value:function(e){var i=this,n=this.scrollListener="scroll.zf."+e;this.isOn||(this.canStick&&(this.isOn=!0,t(window).off(n).on(n,function(t){0===i.scrollCount?(i.scrollCount=i.options.checkEvery,i._setSizes(function(){i._calc(!1,window.pageYOffset)})):(i.scrollCount--,i._calc(!1,window.pageYOffset))})),this.$element.off("resizeme.zf.trigger").on("resizeme.zf.trigger",function(t,s){i._setSizes(function(){i._calc(!1),i.canStick?i.isOn||i._events(e):i.isOn&&i._pauseListeners(n)})}))}},{key:"_pauseListeners",value:function(e){this.isOn=!1,t(window).off(e),this.$element.trigger("pause.zf.sticky")}},{key:"_calc",value:function(t,e){return t&&this._setSizes(),this.canStick?(e||(e=window.pageYOffset),void(e>=this.topPoint?e<=this.bottomPoint?this.isStuck||this._setSticky():this.isStuck&&this._removeSticky(!1):this.isStuck&&this._removeSticky(!0))):(this.isStuck&&this._removeSticky(!0),!1)}},{key:"_setSticky",value:function(){var t=this,e=this.options.stickTo,i="top"===e?"marginTop":"marginBottom",n="top"===e?"bottom":"top",s={};s[i]=this.options[i]+"em",s[e]=0,s[n]="auto",this.isStuck=!0,this.$element.removeClass("is-anchored is-at-"+n).addClass("is-stuck is-at-"+e).css(s).trigger("sticky.zf.stuckto:"+e),this.$element.on("transitionend webkitTransitionEnd oTransitionEnd otransitionend MSTransitionEnd",function(){t._setSizes()})}},{key:"_removeSticky",value:function(t){var e=this.options.stickTo,i="top"===e,n={},s=(this.points?this.points[1]-this.points[0]:this.anchorHeight)-this.elemHeight,o=i?"marginTop":"marginBottom",a=t?"top":"bottom";n[o]=0,n.bottom="auto",t?n.top=0:n.top=s,this.isStuck=!1,this.$element.removeClass("is-stuck is-at-"+e).addClass("is-anchored is-at-"+a).css(n).trigger("sticky.zf.unstuckfrom:"+a)}},{key:"_setSizes",value:function(t){this.canStick=Foundation.MediaQuery.is(this.options.stickyOn),this.canStick||t&&"function"==typeof t&&t();var e=this.$container[0].getBoundingClientRect().width,i=window.getComputedStyle(this.$container[0]),n=parseInt(i["padding-left"],10),s=parseInt(i["padding-right"],10);this.$anchor&&this.$anchor.length?this.anchorHeight=this.$anchor[0].getBoundingClientRect().height:this._parsePoints(),this.$element.css({"max-width":e-n-s+"px"});var o=this.$element[0].getBoundingClientRect().height||this.containerHeight;if("none"==this.$element.css("display")&&(o=0),this.containerHeight=o,this.$container.css({height:o}),this.elemHeight=o,!this.isStuck&&this.$element.hasClass("is-at-bottom")){var a=(this.points?this.points[1]-this.$container.offset().top:this.anchorHeight)-this.elemHeight;this.$element.css("top",a)}this._setBreakPoints(o,function(){t&&"function"==typeof t&&t()})}},{key:"_setBreakPoints",value:function(t,i){if(!this.canStick){if(!i||"function"!=typeof i)return!1;i()}var n=e(this.options.marginTop),s=e(this.options.marginBottom),o=this.points?this.points[0]:this.$anchor.offset().top,a=this.points?this.points[1]:o+this.anchorHeight,r=window.innerHeight;"top"===this.options.stickTo?(o-=n,a-=t+n):"bottom"===this.options.stickTo&&(o-=r-(t+s),a-=r-s),this.topPoint=o,this.bottomPoint=a,i&&"function"==typeof i&&i()}},{key:"destroy",value:function(){this._removeSticky(!0),this.$element.removeClass(this.options.stickyClass+" is-anchored is-at-top").css({height:"",top:"",bottom:"","max-width":""}).off("resizeme.zf.trigger"),this.$anchor&&this.$anchor.length&&this.$anchor.off("change.zf.sticky"),t(window).off(this.scrollListener),this.wasWrapped?this.$element.unwrap():this.$container.removeClass(this.options.containerClass).css({height:""}),Foundation.unregisterPlugin(this)}}]),i}();
508i.defaults={container:"<div data-sticky-container></div>",stickTo:"top",anchor:"",topAnchor:"",btmAnchor:"",marginTop:1,marginBottom:1,stickyOn:"medium",stickyClass:"sticky",containerClass:"sticky-container",checkEvery:-1},Foundation.plugin(i,"Sticky")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this._init(),Foundation.registerPlugin(this,"Tabs"),Foundation.Keyboard.register("Tabs",{ENTER:"open",SPACE:"open",ARROW_RIGHT:"next",ARROW_UP:"previous",ARROW_DOWN:"next",ARROW_LEFT:"previous"})}return _createClass(e,[{key:"_init",value:function(){var e=this,i=this;if(this.$element.attr({role:"tablist"}),this.$tabTitles=this.$element.find("."+this.options.linkClass),this.$tabContent=t('[data-tabs-content="'+this.$element[0].id+'"]'),this.$tabTitles.each(function(){var e=t(this),n=e.find("a"),s=e.hasClass(""+i.options.linkActiveClass),o=n[0].hash.slice(1),a=n[0].id?n[0].id:o+"-label",r=t("#"+o);e.attr({role:"presentation"}),n.attr({role:"tab","aria-controls":o,"aria-selected":s,id:a}),r.attr({role:"tabpanel","aria-hidden":!s,"aria-labelledby":a}),s&&i.options.autoFocus&&t(window).load(function(){t("html, body").animate({scrollTop:e.offset().top},i.options.deepLinkSmudgeDelay,function(){n.focus()})})}),this.options.matchHeight){var n=this.$tabContent.find("img");n.length?Foundation.onImagesLoaded(n,this._setHeight.bind(this)):this._setHeight()}this._checkDeepLink=function(){var i=window.location.hash;if(i.length){var n=e.$element.find('[href="'+i+'"]');if(n.length){if(e.selectTab(t(i),!0),e.options.deepLinkSmudge){var s=e.$element.offset();t("html, body").animate({scrollTop:s.top},e.options.deepLinkSmudgeDelay)}e.$element.trigger("deeplink.zf.tabs",[n,t(i)])}}},this.options.deepLink&&this._checkDeepLink(),this._events()}},{key:"_events",value:function(){this._addKeyHandler(),this._addClickHandler(),this._setHeightMqHandler=null,this.options.matchHeight&&(this._setHeightMqHandler=this._setHeight.bind(this),t(window).on("changed.zf.mediaquery",this._setHeightMqHandler)),this.options.deepLink&&t(window).on("popstate",this._checkDeepLink)}},{key:"_addClickHandler",value:function(){var e=this;this.$element.off("click.zf.tabs").on("click.zf.tabs","."+this.options.linkClass,function(i){i.preventDefault(),i.stopPropagation(),e._handleTabChange(t(this))})}},{key:"_addKeyHandler",value:function(){var e=this;this.$tabTitles.off("keydown.zf.tabs").on("keydown.zf.tabs",function(i){if(9!==i.which){var n,s,o=t(this),a=o.parent("ul").children("li");a.each(function(i){if(t(this).is(o))return void(e.options.wrapOnKeys?(n=0===i?a.last():a.eq(i-1),s=i===a.length-1?a.first():a.eq(i+1)):(n=a.eq(Math.max(0,i-1)),s=a.eq(Math.min(i+1,a.length-1))))}),Foundation.Keyboard.handleKey(i,"Tabs",{open:function(){o.find('[role="tab"]').focus(),e._handleTabChange(o)},previous:function(){n.find('[role="tab"]').focus(),e._handleTabChange(n)},next:function(){s.find('[role="tab"]').focus(),e._handleTabChange(s)},handled:function(){i.stopPropagation(),i.preventDefault()}})}})}},{key:"_handleTabChange",value:function(t,e){if(t.hasClass(""+this.options.linkActiveClass))return void(this.options.activeCollapse&&(this._collapseTab(t),this.$element.trigger("collapse.zf.tabs",[t])));var i=this.$element.find("."+this.options.linkClass+"."+this.options.linkActiveClass),n=t.find('[role="tab"]'),s=n[0].hash,o=this.$tabContent.find(s);if(this._collapseTab(i),this._openTab(t),this.options.deepLink&&!e){var a=t.find("a").attr("href");this.options.updateHistory?history.pushState({},"",a):history.replaceState({},"",a)}this.$element.trigger("change.zf.tabs",[t,o]),o.find("[data-mutate]").trigger("mutateme.zf.trigger")}},{key:"_openTab",value:function(t){var e=t.find('[role="tab"]'),i=e[0].hash,n=this.$tabContent.find(i);t.addClass(""+this.options.linkActiveClass),e.attr({"aria-selected":"true"}),n.addClass(""+this.options.panelActiveClass).attr({"aria-hidden":"false"})}},{key:"_collapseTab",value:function(e){var i=e.removeClass(""+this.options.linkActiveClass).find('[role="tab"]').attr({"aria-selected":"false"});t("#"+i.attr("aria-controls")).removeClass(""+this.options.panelActiveClass).attr({"aria-hidden":"true"})}},{key:"selectTab",value:function(t,e){var i;i="object"==typeof t?t[0].id:t,i.indexOf("#")<0&&(i="#"+i);var n=this.$tabTitles.find('[href="'+i+'"]').parent("."+this.options.linkClass);this._handleTabChange(n,e)}},{key:"_setHeight",value:function(){var e=0,i=this;this.$tabContent.find("."+this.options.panelClass).css("height","").each(function(){var n=t(this),s=n.hasClass(""+i.options.panelActiveClass);s||n.css({visibility:"hidden",display:"block"});var o=this.getBoundingClientRect().height;s||n.css({visibility:"",display:""}),e=o>e?o:e}).css("height",e+"px")}},{key:"destroy",value:function(){this.$element.find("."+this.options.linkClass).off(".zf.tabs").hide().end().find("."+this.options.panelClass).hide(),this.options.matchHeight&&null!=this._setHeightMqHandler&&t(window).off("changed.zf.mediaquery",this._setHeightMqHandler),this.options.deepLink&&t(window).off("popstate",this._checkDeepLink),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={deepLink:!1,deepLinkSmudge:!1,deepLinkSmudgeDelay:300,updateHistory:!1,autoFocus:!1,wrapOnKeys:!0,matchHeight:!1,activeCollapse:!1,linkClass:"tabs-title",linkActiveClass:"is-active",panelClass:"tabs-panel",panelActiveClass:"is-active"},Foundation.plugin(e,"Tabs")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}
508return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,i.data(),n),this.className="",this._init(),this._events(),Foundation.registerPlugin(this,"Toggler")}return _createClass(e,[{key:"_init",value:function(){var e;this.options.animate?(e=this.options.animate.split(" "),this.animationIn=e[0],this.animationOut=e[1]||null):(e=this.$element.data("toggler"),this.className="."===e[0]?e.slice(1):e);var i=this.$element[0].id;t('[data-open="'+i+'"], [data-close="'+i+'"], [data-toggle="'+i+'"]').attr("aria-controls",i),this.$element.attr("aria-expanded",!this.$element.is(":hidden"))}},{key:"_events",value:function(){this.$element.off("toggle.zf.trigger").on("toggle.zf.trigger",this.toggle.bind(this))}},{key:"toggle",value:function(){this[this.options.animate?"_toggleAnimate":"_toggleClass"]()}},{key:"_toggleClass",value:function(){this.$element.toggleClass(this.className);var t=this.$element.hasClass(this.className);t?this.$element.trigger("on.zf.toggler"):this.$element.trigger("off.zf.toggler"),this._updateARIA(t),this.$element.find("[data-mutate]").trigger("mutateme.zf.trigger")}},{key:"_toggleAnimate",value:function(){var t=this;this.$element.is(":hidden")?Foundation.Motion.animateIn(this.$element,this.animationIn,function(){t._updateARIA(!0),this.trigger("on.zf.toggler"),this.find("[data-mutate]").trigger("mutateme.zf.trigger")}):Foundation.Motion.animateOut(this.$element,this.animationOut,function(){t._updateARIA(!1),this.trigger("off.zf.toggler"),this.find("[data-mutate]").trigger("mutateme.zf.trigger")})}},{key:"_updateARIA",value:function(t){this.$element.attr("aria-expanded",!!t)}},{key:"destroy",value:function(){this.$element.off(".zf.toggler"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={animate:!1},Foundation.plugin(e,"Toggler")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=i,this.options=t.extend({},e.defaults,this.$element.data(),n),this.isActive=!1,this.isClick=!1,this._init(),Foundation.registerPlugin(this,"Tooltip")}return _createClass(e,[{key:"_init",value:function(){var e=this.$element.attr("aria-describedby")||Foundation.GetYoDigits(6,"tooltip");this.options.positionClass=this.options.positionClass||this._getPositionClass(this.$element),this.options.tipText=this.options.tipText||this.$element.attr("title"),this.template=this.options.template?t(this.options.template):this._buildTemplate(e),this.options.allowHtml?this.template.appendTo(document.body).html(this.options.tipText).hide():this.template.appendTo(document.body).text(this.options.tipText).hide(),this.$element.attr({title:"","aria-describedby":e,"data-yeti-box":e,"data-toggle":e,"data-resize":e}).addClass(this.options.triggerClass),this.usedPositions=[],this.counter=4,this.classChanged=!1,this._events()}},{key:"_getPositionClass",value:function(t){if(!t)return"";var e=t[0].className.match(/\b(top|left|right)\b/g);return e=e?e[0]:""}},{key:"_buildTemplate",value:function(e){var i=(this.options.tooltipClass+" "+this.options.positionClass+" "+this.options.templateClasses).trim(),n=t("<div></div>").addClass(i).attr({role:"tooltip","aria-hidden":!0,"data-is-active":!1,"data-is-focus":!1,id:e});return n}},{key:"_reposition",value:function(t){this.usedPositions.push(t?t:"bottom"),!t&&this.usedPositions.indexOf("top")<0?this.template.addClass("top"):"top"===t&&this.usedPositions.indexOf("bottom")<0?this.template.removeClass(t):"left"===t&&this.usedPositions.indexOf("right")<0?this.template.removeClass(t).addClass("right"):"right"===t&&this.usedPositions.indexOf("left")<0?this.template.removeClass(t).addClass("left"):!t&&this.usedPositions.indexOf("top")>-1&&this.usedPositions.indexOf("left")<0?this.template.addClass("left"):"top"===t&&this.usedPositions.indexOf("bottom")>-1&&this.usedPositions.indexOf("left")<0?this.template.removeClass(t).addClass("left"):"left"===t&&this.usedPositions.indexOf("right")>-1&&this.usedPositions.indexOf("bottom")<0?this.template.removeClass(t):"right"===t&&this.usedPositions.indexOf("left")>-1&&this.usedPositions.indexOf("bottom")<0?this.template.removeClass(t):this.template.removeClass(t),this.classChanged=!0,this.counter--}},{key:"_setPosition",value:function(){var t=this._getPositionClass(this.template),e=Foundation.Box.GetDimensions(this.template),i=Foundation.Box.GetDimensions(this.$element),n="left"===t?"left":"right"===t?"left":"top",s="top"===n?"height":"width";"height"===s?this.options.vOffset:this.options.hOffset;if(e.width>=e.windowDims.width||!this.counter&&!Foundation.Box.ImNotTouchingYou(this.template))return this.template.offset(Foundation.Box.GetOffsets(this.template,this.$element,"center bottom",this.options.vOffset,this.options.hOffset,!0)).css({width:i.windowDims.width-2*this.options.hOffset,height:"auto"}),!1;for(this.template.offset(Foundation.Box.GetOffsets(this.template,this.$element,"center "+(t||"bottom"),this.options.vOffset,this.options.hOffset));!Foundation.Box.ImNotTouchingYou(this.template)&&this.counter;)this._reposition(t),this._setPosition()}},{key:"show",value:function(){if("all"!==this.options.showOn&&!Foundation.MediaQuery.is(this.options.showOn))return!1;var t=this;this.template.css("visibility","hidden").show(),this._setPosition(),this.$element.trigger("closeme.zf.tooltip",this.template.attr("id")),this.template.attr({"data-is-active":!0,"aria-hidden":!1}),t.isActive=!0,this.template.stop().hide().css("visibility","").fadeIn(this.options.fadeInDuration,function(){}),this.$element.trigger("show.zf.tooltip")}},{key:"hide",value:function(){var t=this;this.template.stop().attr({"aria-hidden":!0,"data-is-active":!1}).fadeOut(this.options.fadeOutDuration,function(){t.isActive=!1,t.isClick=!1,t.classChanged&&(t.template.removeClass(t._getPositionClass(t.template)).addClass(t.o
508ptions.positionClass),t.usedPositions=[],t.counter=4,t.classChanged=!1)}),this.$element.trigger("hide.zf.tooltip")}},{key:"_events",value:function(){var t=this,e=(this.template,!1);this.options.disableHover||this.$element.on("mouseenter.zf.tooltip",function(e){t.isActive||(t.timeout=setTimeout(function(){t.show()},t.options.hoverDelay))}).on("mouseleave.zf.tooltip",function(i){clearTimeout(t.timeout),(!e||t.isClick&&!t.options.clickOpen)&&t.hide()}),this.options.clickOpen?this.$element.on("mousedown.zf.tooltip",function(e){e.stopImmediatePropagation(),t.isClick||(t.isClick=!0,!t.options.disableHover&&t.$element.attr("tabindex")||t.isActive||t.show())}):this.$element.on("mousedown.zf.tooltip",function(e){e.stopImmediatePropagation(),t.isClick=!0}),this.options.disableForTouch||this.$element.on("tap.zf.tooltip touchend.zf.tooltip",function(e){t.isActive?t.hide():t.show()}),this.$element.on({"close.zf.trigger":this.hide.bind(this)}),this.$element.on("focus.zf.tooltip",function(i){return e=!0,t.isClick?(t.options.clickOpen||(e=!1),!1):void t.show()}).on("focusout.zf.tooltip",function(i){e=!1,t.isClick=!1,t.hide()}).on("resizeme.zf.trigger",function(){t.isActive&&t._setPosition()})}},{key:"toggle",value:function(){this.isActive?this.hide():this.show()}},{key:"destroy",value:function(){this.$element.attr("title",this.template.text()).off(".zf.trigger .zf.tooltip").removeClass("has-tip top right left").removeAttr("aria-describedby aria-haspopup data-disable-hover data-resize data-toggle data-tooltip data-yeti-box"),this.template.remove(),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={disableForTouch:!1,hoverDelay:200,fadeInDuration:150,fadeOutDuration:150,disableHover:!1,templateClasses:"",tooltipClass:"tooltip",triggerClass:"has-tip",showOn:"small",template:"",tipText:"",touchCloseText:"Tap to close.",clickOpen:!0,positionClass:"",vOffset:10,hOffset:12,allowHtml:!1},Foundation.plugin(e,"Tooltip")}(jQuery);var _createClass=function(){function t(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,i,n){return i&&t(e.prototype,i),n&&t(e,n),e}}();!function(t){var e=function(){function e(i,n){_classCallCheck(this,e),this.$element=t(i),this.options=t.extend({},this.$element.data(),n),this.rules=this.$element.data("responsive-accordion-tabs"),this.currentMq=null,this.currentPlugin=null,this.$element.attr("id")||this.$element.attr("id",Foundation.GetYoDigits(6,"responsiveaccordiontabs")),this._init(),this._events(),Foundation.registerPlugin(this,"ResponsiveAccordionTabs")}return _createClass(e,[{key:"_init",value:function(){if("string"==typeof this.rules){for(var e={},n=this.rules.split(" "),s=0;s<n.length;s++){var o=n[s].split("-"),a=o.length>1?o[0]:"small",r=o.length>1?o[1]:o[0];null!==i[r]&&(e[a]=i[r])}this.rules=e}this._getAllOptions(),t.isEmptyObject(this.rules)||this._checkMediaQueries()}},{key:"_getAllOptions",value:function(){var e=this;e.allOptions={};for(var n in i)if(i.hasOwnProperty(n)){var s=i[n];try{var o=t("<ul></ul>"),a=new s.plugin(o,e.options);for(var r in a.options)if(a.options.hasOwnProperty(r)&&"zfPlugin"!==r){var l=a.options[r];e.allOptions[r]=l}a.destroy()}catch(t){}}}},{key:"_events",value:function(){var e=this;t(window).on("changed.zf.mediaquery",function(){e._checkMediaQueries()})}},{key:"_checkMediaQueries",value:function(){var e,n=this;t.each(this.rules,function(t){Foundation.MediaQuery.atLeast(t)&&(e=t)}),e&&(this.currentPlugin instanceof this.rules[e].plugin||(t.each(i,function(t,e){n.$element.removeClass(e.cssClass)}),this.$element.addClass(this.rules[e].cssClass),this.currentPlugin&&(!this.currentPlugin.$element.data("zfPlugin")&&this.storezfData&&this.currentPlugin.$element.data("zfPlugin",this.storezfData),this.currentPlugin.destroy()),this._handleMarkup(this.rules[e].cssClass),this.currentPlugin=new this.rules[e].plugin(this.$element,{}),this.storezfData=this.currentPlugin.$element.data("zfPlugin")))}},{key:"_handleMarkup",value:function(e){var i=this,n="accordion",s=t("[data-tabs-content="+this.$element.attr("id")+"]");if(s.length&&(n="tabs"),n!==e){var o=i.allOptions.linkClass?i.allOptions.linkClass:"tabs-title",a=i.allOptions.panelClass?i.allOptions.panelClass:"tabs-panel";this.$element.removeAttr("role");var r=this.$element.children("."+o+",[data-accordion-item]").removeClass(o).removeClass("accordion-item").removeAttr("data-accordion-item"),l=r.children("a").removeClass("accordion-title");if("tabs"===n?(s=s.children("."+a).removeClass(a).removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby"),s.children("a").removeAttr("role").removeAttr("aria-controls").removeAttr("aria-selected")):s=r.children("[data-tab-content]").removeClass("accordion-content"),s.css({display:"",visibility:""}),r.css({display:"",visibility:""}),"accordion"===e)s.each(function(e,n){t(n).appendTo(r.get(e)).addClass("accordion-content").attr("data-tab-content","").removeClass("is-active").css({height:""}),t("[data-tabs-content="+i.$element.attr("id")+"]").after('<div id="tabs-placeholder-'+i.$element.attr("id")+'"></div>').remove(),r.addClass("accordion-item").attr("data-accordion-item",""),l.addClass("accordion-title")});else if("tabs"===e){var h=t("[data-tabs-content="+i.$element.attr("id")+"]"),u=t("#tabs-placeholder-"+i.$element.attr("id"));u.length?(h=t('<div class="tabs-content"></div>').insertAfter(u).attr("data-tabs-content",i.$element.attr("id")),u.remove()):h=t('<div class="tabs-content"></div>').insertAfter(i.$element).attr("data-tabs-content",i.$element.attr("id")),s.each(function(e,i){var n=t(i).appendTo(h).addClass(a),s=l.get(e).hash.slice(1),o=t(i).attr("id")||Foundation.GetYoDigits(6,"accordion");s!==o&&(""!==s?t(i).attr("id",s):(s=o,t(i).attr("id",s),t(l.get(e)).attr("href",t(l.get(e)).attr("href").replace("#","")+"#"+s)));var u=t(r.get(e)).hasClass("is-active");u&&n.addClass("is-active")}),r.addClass(o)}}}},{key:"destroy",value:function(){this.currentPlugin&&this.currentPlugin.destroy(),t(window).off(".zf.ResponsiveAccordionTabs"),Foundation.unregisterPlugin(this)}}]),e}();e.defaults={};var i={tabs:{cssClass:"tabs",plugin:Foundation._plugins.tabs||null},accordion:{cssClass:"accordion",plugin:Foundation._plugins.accordion||null}};Foundation.plugin(e,"ResponsiveAccordionTabs")}(jQuery);;
509/*
510 * International Telephone Input v11.1.6
511 * https://github.com/jackocnr/intl-tel-input.git
512 * Licensed under the MIT license
513 */
514// wrap in UMD - see https://github.com/umdjs/umd/blob/master/jqueryPluginCommonjs.js
515(function(factory) {
516    if (typeof define === "function" && define.amd) {
517        define([ "jquery" ], function($) {
518            factory($, window, document);
519        });
520    } else if (typeof module === "object" && module.exports) {
521        module.exports = factory(require("jquery"), window, document);
522    } else {
523        factory(jQuery, window, document);
524    }
525})(function($, window, document, undefined) {
526    "use strict";
527    // these vars persist through all instances of the plugin
528    var pluginName = "intlTelInput", id = 1, // give each instance it's own i
528d for namespaced event handling
529    defaults = {
530        // whether or not to allow the dropdown
531        allowDropdown: true,
532        // if there is just a dial code in the input: remove it on blur, and re-add it on focus
533        autoHideDialCode: true,
534        // add a placeholder in the input with an example number for the selected country
535        autoPlaceholder: "polite",
536        // modify the auto placeholder
537        customPlaceholder: null,
538        // append menu to a specific element
539        dropdownContainer: "",
540        // don't display these countries
541        excludeCountries: [],
542        // format the input value during initialisation and on setNumber
543        formatOnDisplay: true,
544        // geoIp lookup function
545        geoIpLookup: null,
546        // initial country
547        initialCountry: "",
548        // don't insert international dial codes
549        nationalMode: true,
550        // display only these countries
551        onlyCountries: [],
552        // number type to use for placeholders
553        placeholderNumberType: "MOBILE",
554        // the countries at the top of the list. defaults to united states and united kingdom
555        preferredCountries: [ "us", "gb" ],
556        // display the country dial code next to the selected flag so it's not part of the typed number
557        separateDialCode: false,
558        // specify the path to the libphonenumber script to enable validation/formatting
559        utilsScript: ""
560    }, keys = {
561        UP: 38,
562        DOWN: 40,
563        ENTER: 13,
564        ESC: 27,
565        PLUS: 43,
566        A: 65,
567        Z: 90,
568        SPACE: 32,
569        TAB: 9
570    }, // https://en.wikipedia.org/wiki/List_of_North_American_Numbering_Plan_area_codes#Non-geographic_area_codes
571    regionlessNanpNumbers = [ "800", "822", "833", "844", "855", "866", "877", "880", "881", "882", "883", "884", "885", "886", "887", "888", "889" ];
572    // keep track of if the window.load event has fired as impossible to check after the fact
573    $(window).on("load", function() {
574        // UPDATE: use a public static field so we can fudge it in the tests
575        $.fn[pluginName].windowLoaded = true;
576    });
577    function Plugin(element, options) {
578        this.telInput = $(element);
579        this.options = $.extend({}, defaults, options);
580        // event namespace
581        this.ns = "." + pluginName + id++;
582        // Chrome, FF, Safari, IE9+
583        this.isGoodBrowser = Boolean(element.setSelectionRange);
584        this.hadInitialPlaceholder = Boolean($(element).attr("placeholder"));
585    }
586    Plugin.prototype = {
587        _init: function() {
588            // if in nationalMode, disable options relating to dial codes
589            if (this.options.nationalMode) {
590                this.options.autoHideDialCode = false;
591            }
592            // if separateDialCode then doesn't make sense to A) insert dial code into input (autoHideDialCode), and B) display national numbers (because we're displaying the country dial code next to them)
593            if (this.options.separateDialCode) {
594                this.options.autoHideDialCode = this.options.nationalMode = false;
595            }
596            // we cannot just test screen size as some smartphones/website meta tags will report desktop resolutions
597            // Note: for some reason jasmine breaks if you put this in the main Plugin function with the rest of these declarations
598            // Note: to target Android Mobiles (and not Tablets), we must find "Android" and "Mobile"
599            this.isMobile = /Android.+Mobile|webOS|iPhone|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
600            if (this.isMobile) {
601                // trigger the mobile dropdown css
602                $("body").addClass("iti-mobile");
603                // on mobile, we want a full screen dropdown, so we must append it to the body
604                if (!this.options.dropdownContainer) {
605                    this.options.dropdownContainer = "body";
606                }
607            }
608            // we return these deferred objects from the _init() call so they can be watched, and then we resolve them when each specific request returns
609            // Note: again, jasmine breaks when I put these in the Plugin function
610            this.autoCountryDeferred = new $.Deferred();
611            this.utilsScriptDeferred = new $.Deferred();
612            // in various situations there could be no country selected initially, but we need to be able to assume this variable exists
613            this.selectedCountryData = {};
614            // process all the data: onlyCountries, excludeCountries, preferredCountries etc
615            this._processCountryData();
616            // generate the markup
617            this._generateMarkup();
618            // set the initial state of the input value and the selected flag
619            this._setInitialState();
620            // start all of the event listeners: autoHideDialCode, input keydown, selectedFlag click
621            this._initListeners();
622            // utils script, and auto country
623            this._initRequests();
624            // return the deferreds
625            return [ this.autoCountryDeferred, this.utilsScriptDeferred ];
626        },
627        /********************
628   *  PRIVATE METHODS
629   ********************/
630        // prepare all of the country data, including onlyCountries, excludeCountries and preferredCountries options
631        _processCountryData: function() {
632            // process onlyCountries or excludeCountries array if present
633            this._processAllCountries();
634            // process the countryCodes map
635            this._processCountryCodes();
636            // process the preferredCountries
637            this._processPreferredCountries();
638        },
639        // add a country code to this.countryCodes
640        _addCountryCode: function(iso2, dialCode, priority) {
641            if (!(dialCode in this.countryCodes)) {
642                this.countryCodes[dialCode] = [];
643            }
644            var index = priority || 0;
645            this.countryCodes[dialCode][index] = iso2;
646        },
647        // process onlyCountries or excludeCountries array if present
648        _processAllCountries: function() {
649            if (this.options.onlyCountries.length) {
650                var lowerCaseOnlyCountries = this.options.onlyCountries.map(function(country) {
651                    return country.toLowerCase();
652                });
653                this.countries = allCountries.filter(function(country) {
654                    return lowerCaseOnlyCountries.indexOf(country.iso2) > -1;
655                });
656            } else if (this.options.excludeCountries.length) {
657                var lowerCaseExcludeCountries = this.options.excludeCountries.map(function(country) {
658                    return country.toLowerCase();
659                });
660                this.countries = allCountries.filter(function(country) {
661                    return lowerCaseExcludeCountries.indexOf(country.iso2) === -1;
662                });
663            } else {
664                this.countries = allCountries;
665            }
666        },
667        // process the countryCodes map
668        _processCountryCodes: function() {
669            this.countryCodes = {};
670            for (var i = 0; i < this.countries.length; i++) {
671                var c = this.countries[i];
672                this._addCountryCode(c.iso2, c.dialCode, c.priority);
673                // area codes
674                if (c.areaCodes) {
675                    for (var j = 0; j < c.areaCodes.length; j++) {
676                        // full dial code is country code + dial code
677                        this._addCountryCode(c.iso2, c.dialCode + c.areaCodes[j]);
678                    }
679                }
680            }
681        },
682        // process preferred countries - iterate through the preferences, fetching the country data for each one
683        _processPreferredCountries: function() {
684            this.preferredCountries = [];
685            for (var i = 0; i < this.options.preferredCountries.length; i++) {
686                var countryCode = this.options.preferredCountries[i].toLowerCase(), countryData = this._getCountryData(countryCode, false, true);
687                if (countryData) {
688                    this.preferredCountries.push(countryData);
689                }
690            }
691        },
692        // generate all of the markup for the plugin: the selected flag overlay, and the dropdown
693        _generateMarkup: function() {
694            // prevent autocomplete as there's no safe, cross-browser event we can react to, so it can easily put the plugin in an inconsistent state e.g. the wrong flag selected for the autocompleted number, which on submit c
694ould mean the wrong number is saved (esp in nationalMode)
695            this.telInput.attr("autocomplete", "off");
696            // containers (mostly for positioning)
697            var parentClass = "intl-tel-input";
698            if (this.options.allowDropdown) {
699                parentClass += " allow-dropdown";
700            }
701            if (this.options.separateDialCode) {
702                parentClass += " separate-dial-code";
703            }
704            this.telInput.wrap($("<div>", {
705                "class": parentClass
706            }));
707            this.flagsContainer = $("<div>", {
708                "class": "flag-container"
709            }).insertBefore(this.telInput);
710            // currently selected flag (displayed to left of input)
711            var selectedFlag = $("<div>", {
712                "class": "selected-flag"
713            });
714            selectedFlag.appendTo(this.flagsContainer);
715            this.selectedFlagInner = $("<div>", {
716                "class": "iti-flag"
717            }).appendTo(selectedFlag);
718            if (this.options.separateDialCode) {
719                this.selectedDialCode = $("<div>", {
720                    "class": "selected-dial-code"
721                }).appendTo(selectedFlag);
722            }
723            if (this.options.allowDropdown) {
724                // make element focusable and tab naviagable
725                selectedFlag.attr("tabindex", "0");
726                // CSS triangle
727                $("<div>", {
728                    "class": "iti-arrow"
729                }).appendTo(selectedFlag);
730                // country dropdown: preferred countries, then divider, then all countries
731                this.countryList = $("<ul>", {
732                    "class": "country-list hide"
733                });
734                if (this.preferredCountries.length) {
735                    this._appendListItems(this.preferredCountries, "preferred");
736                    $("<li>", {
737                        "class": "divider"
738                    }).appendTo(this.countryList);
739                }
740                this._appendListItems(this.countries, "");
741                // this is useful in lots of places
742                this.countryListItems = this.countryList.children(".country");
743                // create dropdownContainer markup
744                if (this.options.dropdownContainer) {
745                    this.dropdown = $("<div>", {
746                        "class": "intl-tel-input iti-container"
747                    }).append(this.countryList);
748                } else {
749                    this.countryList.appendTo(this.flagsContainer);
750                }
751            } else {
752                // a little hack so we don't break anything
753                this.countryListItems = $();
754            }
755        },
756        // add a country <li> to the countryList <ul> container
757        _appendListItems: function(countries, className) {
758            // we create so many DOM elements, it is faster to build a temp string
759            // and then add everything to the DOM in one go at the end
760            var tmp = "";
761            // for each country
762            for (var i = 0; i < countries.length; i++) {
763                var c = countries[i];
764                // open the list item
765                tmp += "<li class='country " + className + "' data-dial-code='" + c.dialCode + "' data-country-code='" + c.iso2 + "'>";
766                // add the flag
767                tmp += "<div class='flag-box'><div class='iti-flag " + c.iso2 + "'></div></div>";
768                // and the country name and dial code
769                tmp += "<span class='country-name'>" + c.name + "</span>";
770                tmp += "<span class='dial-code'>+" + c.dialCode + "</span>";
771                // close the list item
772                tmp += "</li>";
773            }
774            this.countryList.append(tmp);
775        },
776        // set the initial state of the input value and the selected flag by:
777        // 1. extracting a dial code from the given number
778        // 2. using explicit initialCountry
779        // 3. picking the first preferred country
780        // 4. picking the first country
781        _setInitialState: function() {
782            var val = this.telInput.val();
783            // if we already have a dial code, and it's not a regi
783onlessNanp, we can go ahead and set the flag, else fall back to the default country
784            // UPDATE: actually we do want to set the flag for a regionlessNanp in one situation: if we're in nationalMode and there's no initialCountry - otherwise we lose the +1 and we're left with an invalid number
785            if (this._getDialCode(val) && (!this._isRegionlessNanp(val) || this.options.nationalMode && !this.options.initialCountry)) {
786                this._updateFlagFromNumber(val);
787            } else if (this.options.initialCountry !== "auto") {
788                // see if we should select a flag
789                if (this.options.initialCountry) {
790                    this._setFlag(this.options.initialCountry.toLowerCase());
791                } else {
792                    // no dial code and no initialCountry, so default to first in list
793                    this.defaultCountry = this.preferredCountries.length ? this.preferredCountries[0].iso2 : this.countries[0].iso2;
794                    if (!val) {
795                        this._setFlag(this.defaultCountry);
796                    }
797                }
798                // if empty and no nationalMode and no autoHideDialCode then insert the default dial code
799                if (!val && !this.options.nationalMode && !this.options.autoHideDialCode && !this.options.separateDialCode) {
800                    this.telInput.val("+" + this.selectedCountryData.dialCode);
801                }
802            }
803            // NOTE: if initialCountry is set to auto, that will be handled separately
804            // format
805            if (val) {
806                // this wont be run after _updateDialCode as that's only called 
806if no val
807                this._updateValFromNumber(val);
808            }
809        },
810        // initialise the main event listeners: input keyup, and click selected flag
811        _initListeners: function() {
812            this._initKeyListeners();
813            if (this.options.autoHideDialCode) {
814                this._initFocusListeners();
815            }
816            if (this.options.allowDropdown) {
817                this._initDropdownListeners();
818            }
819        },
820        // initialise the dropdown listeners
821        _initDropdownListeners: function() {
822            var that = this;
823            // hack for input nested inside label: clicking the selected-flag to open the dropdown would then automatically trigger a 2nd click on the input which would close it again
824            var label = this.telInput.closest("label");
825            if (label.length) {
826                label.on("click" + this.ns, function(e) {
827                    // if the dropdown is closed, then focus the input, else ignore the click
828                    if (that.countryList.hasClass("hide")) {
829                        that.telInput.focus();
830                    } else {
831                        e.preventDefault();
832                    }
833                });
834            }
835            // toggle country dropdown on click
836            var selectedFlag = this.selectedFlagInner.parent();
837            selectedFlag.on("click" + this.ns, function(e) {
838                // only intercept this event if we're opening the dropdown
839                // else let it bubble up to the top ("click-off-to-close" listener)
840                // we cannot just stopPropagation as it may be needed to close another instance
841                if (that.countryList.hasClass("hide") && !that.telInput.prop("disabled") && !that.telInput.prop("readonly")) {
842                    that._showDropdown();
843                }
844            });
845            // open dropdown list if currently focused
846            this.flagsContainer.on("keydown" + that.ns, function(e) {
847                var isDropdownHidden = that.countryList.hasClass("hide");
848                if (isDropdownHidden && (e.which == keys.UP || e.which == keys.DOWN || e.which == keys.SPACE || e.which == keys.ENTER)) {
849                    // prevent form from being submitted if "ENTER" was pressed
850                    e.preventDefault();
851                    // prevent event from being handled again by document
852                    e.stopPropagation();
853                    that._showDropdown();
854                }
855                // allow navigation from dropdown to input on TAB
856                if (e.which == keys.TAB) {
857                    that._closeDropdown();
858                }
859            });
860        },
861        // init many requests: utils script / geo ip lookup
862        _initRequests: function() {
863            var that = this;
864            // if the user has specified the path to the utils script, fetch it on window.load, else resolve
865            if (this.options.utilsScript) {
866                // if the plugin is being initialised after the window.load event has already been fired
867                if ($.fn[pluginName].windowLoaded) {
868                    $.fn[pluginName].loadUtils(this.options.utilsScript, this.utilsScriptDeferred);
869                } else {
870                    // wait until the load event so we don't block any other requests e.g. the flags image
871                    $(window).on("load", function() {
872                        $.fn[pluginName].loadUtils(that.options.utilsScript, that.utilsScriptDeferred);
873                    });
874                }
875            } else {
876                this.utilsScriptDeferred.resolve();
877            }
878            if (this.options.initialCountry === "auto") {
879                this._loadAutoCountry();
880            } else {
881                this.autoCountryDeferred.resolve();
882            }
883        },
884        // perform the geo ip lookup
885        _loadAutoCountry: function() {
886            var that = this;
887            // 3 options:
888            // 1) already loaded (we're done)
889            // 2) not already started loading (start)
890            // 3) already started loading (do nothing - just wait for loading callback to fire)
891            if ($.fn[pluginName].autoCountry) {
892                this.handleAutoCountry();
893            } else if (!$.fn[pluginName].startedLoadingAutoCountry) {
894                // don't do this twice!
895                $.fn[pluginName].startedLoadingAutoCountry = true;
896                if (typeof this.options.geoIpLookup === "function") {
897                    this.options.geoIpLookup(function(countryCode) {
898                        $.fn[pluginName].autoCountry = countryCode.toLowerCase();
899                        // tell all instances the auto country is ready
900                        // TODO: this should just be the current instances
901                        // UPDATE: use setTimeout in case their geoIpLookup function calls this callback straight away (e.g. if they have already done the geo ip lookup somewhere else). Using setTimeout means that the current thread of execution will finish before executing this, which allows the plugin to finish initialising.
902                        setTimeout(function() {
903                            $(".intl-tel-input input").intlTelInput("handleAutoCountry");
904                        });
905                    });
906                }
907            }
908        },
909        // initialize any key listeners
910        _initKeyListeners: function() {
911            var that = this;
912            // update flag on keyup
913            // (keep this listener separate otherwise the setTimeout breaks all the tests)
914            this.telInput.on("keyup" + this.ns, function() {
915                if (that._updateFlagFromNumber(that.telInput.val())) {
916                    that._triggerCountryChange();
917                }
918            });
919            // update flag on cut/paste events (now supported in all major browsers)
920            this.telInput.on("cut" + this.ns + " paste" + this.ns, function() {
921                // hack because "paste" event is fired before input is updated
922                setTimeout(function() {
923                    if (that._updateFlagFromNumber(that.telInput.val())) {
924                        that._triggerCountryChange();
925                    }
926                });
927            });
928        },
929        // adhere to the input's maxlength attr
930        _cap: function(number) {
931            var max = this.telInput.attr("maxlength");
932            return max && number.length > max ? number.substr(0, max) : number;
933        },
934        // listen for mousedown, focus and blur
935        _initFocusListeners: function() {
936            var that = this;
937            // mousedown decides where the cursor goes, so if we're focusing we must preventDefault as we'll be inserting the dial code, and we want the cursor to be at the end no matter where they click
938            this.telInput.on("mousedown" + this.ns, function(e) {
939                if (!that.telInput.is(":focus") && !that.telInput.val()) {
940                    e.preventDefault();
941                    // but this also cancels the focus, so we must trigger that manually
942                    that.telInput.focus();
943                }
944            });
945            // on focus: if empty, insert the dial code for the currently selected flag
946            this.telInput.on("focus" + this.ns, function(e) {
947                if (!that.telInput.val() && !that.telInput.prop("readonly") && that.selectedCountryData.dialCode) {
948                    // insert the dial code
949                    that.telInput.val("+" + that.selectedCountryData.dialCode);
950                    // after auto-inserting a dial code, if the first key they hit is '+' then assume they are entering a new number, so remove the dial code. use keypress instead of keydown because keydown gets triggered for the shift key (required to hit the + key), and instead of keyup because that shows the new '+' before removing the old one
951                    that.telInput.one("keypress.plus" + that.ns, function(e) {
952                        if (e.which == keys.PLUS) {
953                            that.telInput.val("");
954                        }
955                    });
956                    // after tabbing in, make sure the cursor is at the end we must use setTimeout to get outside of the focus handler as it seems the selection happens after that
957                    setTimeout(function() {
958                        var input = that.telInput[0];
959                        if (that.isGoodBrowser) {
960                            var len = that.telInput.val().length;
961                            input.setSelectionRange(len, len);
962                        }
963                    });
964                }
965            });
966            // on blur or form submit: if just a dial code then remove it
967            var form = this.telInput.prop("form");
968            if (form) {
969                $(form).on("submit" + this.ns, function() {
970                    that._removeEmptyDialCode();
971                });
972            }
973            this.telInput.on("blur" + this.ns, function() {
974                that._removeEmptyDialCode();
975            });
976        },
977        _removeEmptyDialCode: function() {
978            var value = this.telInput.val(), startsPlus = value.charAt(0) == "+";
979            if (startsPlus) {
980                var numeric = this._getNumeric(value);
981                // if just a plus, or if just a dial code
982                if (!numeric || this.selectedCountryData.dialCode == numeric) {
983                    this.telInput.val("");
984                }
985            }
986            // remove the keypress listener we added on focus
987            this.telInput.off("keypress.plus" + this.ns);
988        },
989        // extract the numeric digits from the given string
990        _getNumeric: function(s) {
991            return s.replace(/\D/g, "");
992        },
993        // show the dropdown
994        _showDropdown: function() {
995            this._setDropdownPosition();
996            // update highlighting and scroll to active list item
997            var activeListItem = this.countryList.children(".active");
998            if (activeListItem.length) {
999                this._highlightListItem(activeListItem);
1000                this._scrollTo(activeListItem);
1001            }
1002            // bind all the dropdown-related listeners: mouseover, click, click-off, keydown
1003            this._bindDropdownListeners();
1004            // update the arrow
1005            this.selectedFlagInner.children(".iti-arrow").addClass("up");
1006            this.telInput.trigger("open:countrydropdown");
1007        },
1008        // decide where to position dropdown (depends on position within viewport, and scroll)
1009        _setDropdownPosition: function() {
1010            var that = this;
1011            if (this.options.dropdownContainer) {
1012                this.dropdown.appendTo(this.options.dropdownContainer);
1013            }
1014            // show the menu and grab the dropdown height
1015            this.dropdownHeight = this.countryList.removeClass("hide").outerHeight();
1016            if (!this.isMobile) {
1017                var pos = this.telInput.offset(), inputTop = pos.top, windowTop = $(window).scrollTop(), // dropdownFitsBelow = (dropdownBottom < windowBottom)
1018                dropdownFitsBelow = inputTop + this.telInput.outerHeight() + this.dropdownHeight < windowTop + $(window).height(), dropdownFitsAbove = inputTop - this.dropdownHeight > windowTop;
1019                // by default, the dropdown will be below the input. If we want to position it above the input, we add the dropup class.
1020                this.countryList.toggleClass("dropup", !dropdownFitsBelow && dropdownFitsAbove);
1021                // if dropdownContainer is enabled, calculate postion
1022                if (this.options.dropdownContainer) {
1023                    // by default the dropdown will be directly over the input because it's not in the flow. If we want to position it below, we need to add some extra top value.
1024                    var extraTop = !dropdownFitsBelow && dropdownFitsAbove ? 0 : this.telInput.innerHeight();
1025                    // calculate placement
1026                    this.dropdown.css({
1027                        top: inputTop + extraTop,
1028                        left: pos.left
1029                    });
1030                    // close menu on window scroll
1031                    $(window).on("scroll" + this.ns, function() {
1032                        that._closeDropdown();
1033                    });
1034                }
1035            }
1036        },
1037        // we only bind dropdown listeners when the dropdown is open
1038        _bindDropdownListeners: function() {
1039            var that = this;
1040            // when mouse over a list item, just highlight that one
1041            // we add the class "highlight", so if they hit "enter" we know which one to select
1042            this.countryList.on("mouseover" + this.ns, ".country", function(e) {
1043                that._highlightListItem($(this));
1044            });
1045            // listen for country selection
1046            this.countryList.on("click" + this.ns, ".country", function(e) {
1047                that._selectListItem($(this));
1048            });
1049            // click off to close
1050            // (except when this initial opening click is bubbling up)
1051            // we cannot just stopPropagation as it may be needed to close another instance
1052            var isOpening = true;
1053            $("html").on("click" + this.ns, function(e) {
1054                if (!isOpening) {
1055                    that._closeDropdown();
1056                }
1057                isOpening = false;
1058            });
1059            // listen for up/down scrolling, enter to select, or letters to jump to country name.
1060            // use keydown as keypress doesn't fire for non-char keys and we want to catch if they
1061            // just hit down and hold it to scroll down (no keyup event).
1062            // listen on the document because that's where key events are triggered if no input has focus
1063            var query = "", queryTimer = null;
1064            $(document).on("keydown" + this.ns, function(e) {
1065                // prevent down key from scrolling the whole page,
1066                // and enter key from submitting a form etc
1067                e.preventDefault();
1068                if (e.which == keys.UP || e.which == keys.DOWN) {
1069                    // up and down to navigate
1070                    that._handleUpDownKey(e.which);
1071                } else if (e.which == keys.ENTER) {
1072                    // enter to select
1073                    that._handleEnterKey();
1074                } else if (e.which == keys.ESC) {
1075                    // esc to close
1076                    that._closeDropdown();
1077                } else if (e.which >
1077= keys.A && e.which <= keys.Z || e.which == keys.SPACE) {
1078                    // upper case letters (note: keyup/keydown only return upper case letters)
1079                    // jump to countries that start with the query string
1080                    if (queryTimer) {
1081                        clearTimeout(queryTimer);
1082                    }
1083                    query += String.fromCharCode(e.which);
1084                    that._searchForCountry(query);
1085                    // if the timer hits 1 second, reset the query
1086                    queryTimer = setTimeout(function() {
1087                        query = "";
1088                    }, 1e3);
1089                }
1090            });
1091        },
1092        // highlight the next/prev item in the list (and ensure it is visible)
1093        _handleUpDownKey: function(key) {
1094            var current = this.countryList.children(".highlight").first();
1095            var next = key == keys.UP ? current.prev() : current.next();
1096            if (next.length) {
1097                // skip the divider
1098                if (next.hasClass("divider")) {
1099                    next = key == keys.UP ? next.prev() : next.next();
1100                }
1101                this._highlightListItem(next);
1102                this._scrollTo(next);
1103            }
1104        },
1105        // select the currently highlighted item
1106        _handleEnterKey: function() {
1107            var currentCountry = this.countryList.children(".highlight").first();
1108            if (currentCountry.length) {
1109                this._selectListItem(currentCountry);
1110            }
1111        },
1112        // find the first list item whose name starts with the query string
1113        _searchForCountry: function(query) {
1114            for (var i = 0; i < this.countries.length; i++) {
1115                if (this._startsWith(this.countries[i].name, query)) {
1116                    var listItem = this.countryList.children("[data-country-code=" + this.countries[i].iso2 + "]").not(".preferred");
1117                    // update highlighting and scroll
1118                    this._highlightListItem(listItem);
1119                    this._scrollTo(listItem, true);
1120                    break;
1121                }
1122            }
1123        },
1124        // check if (uppercase) string a starts with string b
1125        _startsWith: function(a, b) {
1126            return a.substr(0, b.length).toUpperCase() == b;
1127        },
1128        // update the input's value to the given val (format first if possible)
1129        // NOTE: this is called from _setInitialState, handleUtils and setNumber
1130        _updateValFromNumber: function(number) {
1131            if (this.options.formatOnDisplay && window.intlTelInputUtils && this.selectedCountryData) {
1132                var format = !this.options.separateDialCode && (this.options.nationalMode || number.charAt(0) != "+") ? intlTelInputUtils.numberFormat.NATIONAL : intlTelInputUtils.numberFormat.INTERNATIONAL;
1133                number = intlTelInputUtils.formatNumber(number, this.selectedCountryData.iso2, format);
1134            }
1135            number = this._beforeSetNumber(number);
1136            this.telInput.val(number);
1137        },
1138        // check if need to select a new flag based on the given number
1139        // Note: called from _setInitialState, keyup handler, setNumber
1140        _updateFlagFromNumber: function(number) {
1141            // if we're in nationalMode and we already have US/Canada selected, make sure the number starts with a +1 so _getDialCode will be able to extract the area code
1142            // update: if we dont yet have selectedCountryData, but we're here (trying to update the flag from the number), that means we're initialising the plugin with a number that already has a dial code, so fine to ignore this bit
1143            if (number && this.options.nationalMode && this.selectedCountryData.dialCode == "1" && number.charAt(0) != "+") {
1144                if (number.charAt(0) != "1") {
1145                    number = "1" + number;
1146                }
1147                number = "+" + number;
1148            }
1149            // try and extract valid dial code from input
1150            var dialCode = this._getDialCode(number), countryCode = null, numeric = this._getNumeric(number);
1151            if (dialCode) {
1152                // check if one of the matching countries is already selected
1153                var countryCodes = this.countryCodes[this._getNumeric(dialCode)], alreadySelected = $.inArray(this.selectedCountryData.iso2, countryCodes) > -1, // check if the given number contains a NANP area code i.e. the only dialCode that could be extracted was +1 (instead of say +1204) and the actual number's length is >=4
1154                isNanpAreaCode = dialCode == "+1" && numeric.length >= 4, nanpSelected = this.selectedCountryData.dialCode == "1";
1155                // only update the flag if:
1156                // A) NOT (we currently have a NANP flag selected, and the number is a regionlessNanp)
1157                // AND
1158                // B) either a matching country is not already selected OR the number contains a NANP area code (ensure the flag is set to the first matching country)
1159                if (!(nanpSelected && this._isRegionlessNanp(numeric)) && (!alreadySelected || isNanpAreaCode)) {
1160                    // if using onlyCountries option, countryCodes[0] may be empty, so we must find the first non-empty index
1161                    for (var j = 0; j < countryCodes.length; j++) {
1162                        if (countryCodes[j]) {
1163                            countryCode = countryCodes[j];
1164                            break;
1165                        }
1166                    }
1167                }
1168            } else if (number.charAt(0) == "+" && numeric.length) {
1169                // invalid dial code, so empty
1170                // Note: use getNumeric here because the number has not been formatted yet, so could contain bad chars
1171                countryCode = "";
1172            } else if (!number || number == "+") {
1173                // empty, or just a plus, so default
1174                countryCode = this.defaultCountry;
1175            }
1176            if (countryCode !== null) {
1177                return this._setFlag(countryCode);
1178            }
1179            return false;
1180        },
1181        // check if the given number is a regionless NANP number (expects the number to contain an international dial code)
1182        _isRegionlessNanp: function(number) {
1183            var numeric = this._getNumeric(number);
1184            if (numeric.charAt(0) == "1") {
1185                var areaCode = numeric.substr(1, 3);
1186                return $.inArray(areaCode, regionlessNanpNumbers) > -1;
1187            }
1188            return false;
1189        },
1190        // remove highlighting from other list items and highlight the given item
1191        _highlightListItem: function(listItem) {
1192            this.countryListItems.removeClass("highlight");
1193            listItem.addClass("highlight");
1194        },
1195        // find the country data for the given country code
1196        // the ignoreOnlyCountriesOption is only used during init() while parsing the onlyCountries array
1197        _getCountryData: function(countryCode, ignoreOnlyCountriesOption, allowFail) {
1198            var countryList = ignoreOnlyCountriesOption ? allCountries : this.countries;
1199            for (var i = 0; i < countryList.length; i++) {
1200                if (countryList[i].iso2 == countryCode) {
1201                    return countryList[i];
1202                }
1203            }
1204            if (allowFail) {
1205                return null;
1206            } else {
1207                throw new Error("No country data for '" + countryCode + "'");
1208            }
1209        },
1210        // select the given flag, update the placeholder and the active list item
1211        // Note: called from _setInitialState, _updateFlagFromNumber, _selectListItem, setCountry
1212        _setFlag: function(countryCode) {
1213            var prevCountry = this.selectedCountryData.iso2 ? this.selectedCountryData : {};
1214            // do this first as it will throw an error and stop if c
1214ountryCode is invalid
1215            this.selectedCountryData = countryCode ? this._getCountryData(countryCode, false, false) : {};
1216            // update the defaultCountry - we only need the iso2 from now on, so just store that
1217            if (this.selectedCountryData.iso2) {
1218                this.defaultCountry = this.selectedCountryData.iso2;
1219            }
1220            this.selectedFlagInner.attr("class", "iti-flag " + countryCode);
1221            // update the selected country's title attribute
1222            var title = countryCode ? this.selectedCountryData.name + ": +" + this.selectedCountryData.dialCode : "Unknown";
1223            this.selectedFlagInner.parent().attr("title", title);
1224            if (this.options.separateDialCode) {
1225                var dialCode = this.selectedCountryData.dialCode ? "+" + this.selectedCountryData.dialCode : "", parent = this.telInput.parent();
1226                if (prevCountry.dialCode) {
1227                    parent.removeClass("iti-sdc-" + (prevCountry.dialCode.length + 1));
1228                }
1229                if (dialCode) {
1230                    parent.addClass("iti-sdc-" + dialCode.length);
1231                }
1232                this.selectedDialCode.text(dialCode);
1233            }
1234            // and the input's placeholder
1235            this._updatePlaceholder();
1236            // update the active list item
1237            this.countryListItems.removeClass("active");
1238            if (countryCode) {
1239                this.countryListItems.find(".iti-flag." + countryCode).first().closest(".country").addClass("active");
1240            }
1241            // return if the flag has changed or not
1242            return prevCountry.iso2 !== countryCode;
1243        },
1244        // update the input placeholder to an example number from the currently selected country
1245        _updatePlaceholder: function() {
1246            var shouldSetPlaceholder = this.options.autoPlaceholder === "aggressive" || !this.hadInitialPlaceholder && (this.options.autoPlaceholder === true || this.options.autoPlaceholder === "polite");
1247            if (window.intlTelInputUtils && shouldSetPlaceholder) {
1248                var numberType = intlTelInputUtils.numberType[this.options.placeholderNumberType], placeholder = this.selectedCountryData.iso2 ? intlTelInputUtils.getExampleNumber(this.selectedCountryData.iso2, this.options.nationalMode, numberType) : "";
1249                placeholder = this._beforeSetNumber(placeholder);
1250                if (typeof this.options.customPlaceholder === "function") {
1251                    placeholder = this.options.customPlaceholder(placeholder, this.selectedCountryData);
1252                }
1253                this.telInput.attr("placeholder", placeholder);
1254            }
1255        },
1256        // called when the user selects a list item from the dropdown
1257        _selectListItem: function(listItem) {
1258            // update selected flag and active list item
1259            var flagChanged = this._setFlag(listItem.attr("data-country-code"));
1260            this._closeDropdown();
1261            this._updateDialCode(listItem.attr("data-dial-code"), true);
1262            // focus the input
1263            this.telInput.focus();
1264            // put cursor at end - this fix is required for FF and IE11 (with nationalMode=false i.e. auto inserting dial code), who try to put the cursor at the beginning the first time
1265            if (this.isGoodBrowser) {
1266                var len = this.telInput.val().length;
1267                this.telInput[0].setSelectionRange(len, len);
1268            }
1269            if (flagChanged) {
1270                this._triggerCountryChange();
1271            }
1272        },
1273        // close the dropdown and unbind any listeners
1274        _closeDropdown: function() {
1275            this.countryList.addClass("hide");
1276            // update the arrow
1277            this.selectedFlagInner.children(".iti-arrow").removeClass("up");
1278            // unbind key events
1279            $(document).off(this.ns);
1280            // unbind click-off-to-close
1281            $("html").off(this.ns);
1282            // unbind hover and click listeners
1283            this.countryList.off(this.ns);
1284            // remove menu from container
1285            if (this.options.dropdownContainer) {
1286                if (!this.isMobile) {
1287                    $(window).off("scroll" + this.ns);
1288                }
1289                this.dropdown.detach();
1290            }
1291            this.telInput.trigger("close:countrydropdown");
1292        },
1293        // check if an element is visible within it's container, else scroll until it is
1294        _scrollTo: function(element, middle) {
1295            var container = this.countryList, containerHeight = container.height(), containerTop = container.offset().top, containerBottom = containerTop + containerHeight, elementHeight = element.outerHeight(), elementTop = element.offset().top, elementBottom = elementTop + elementHeight, newScrollTop = elementTop - containerTop + container.scrollTop(), middleOffset = containerHeight / 2 - elementHeight / 2;
1296            if (elementTop < containerTop) {
1297                // scroll up
1298                if (middle) {
1299                    newScrollTop -= middleOffset;
1300                }
1301                container.scrollTop(newScrollTop);
1302            } else if (elementBottom > containerBottom) {
1303                // scroll down
1304                if (middle) {
1305                    newScrollTop += middleOffset;
1306                }
1307                var heightDifference = containerHeight - elementHeight;
1308                container.scrollTop(newScrollTop - heightDifference);
1309            }
1310        },
1311        // replace any existing dial code with the new one
1312        // Note: called from _selectListItem and setCountry
1313        _updateDialCode: function(newDialCode, hasSelectedListItem) {
1314            var inputVal = this.telInput.val(), newNumber;
1315            // save having to pass this every time
1316            newDialCode = "+" + newDialCode;
1317            if (inputVal.charAt(0) == "+") {
1318                // there's a plus so we're dealing with a replacement (doesn't matter if nationalMode or not)
1319                var prevDialCode = this._getDialCode(inputVal);
1320                if (prevDialCode) {
1321                    // current number contains a valid dial code, so replace it
1322                    newNumber = inputVal.replace(prevDialCode, newDialCode);
1323                } else {
1324                    // current number contains an invalid dial code, so ditch it
1325                    // (no way to determine where the invalid dial code ends and the rest of the number begins)
1326                    newNumber = newDialCode;
1327                }
1328            } else if (this.options.nationalMode || this.options.separateDialCode) {
1329                // don't do anything
1330                return;
1331            } else {
1332                // nationalMode is disabled
1333                if (inputVal) {
1334                    // there is an existing value with no dial code: prefix the new dial code
1335                    newNumber = newDialCode + inputVal;
1336                } else if (hasSelectedListItem || !this.options.autoHideDialCode) {
1337                    // no existing value and either they've just selected a list item, or autoHideDialCode is disabled: insert new dial code
1338                    newNumber = newDialCode;
1339                } else {
1340                    return;
1341                }
1342            }
1343            this.telInput.val(newNumber);
1344        },
1345        // try and extract a valid international dial code from a full telephone number
1346        // Note: returns the raw string inc plus character and any whitespace/dots etc
1347        _getDialCode: function(number) {
1348            var dialCode = "";
1349            // only interested in international numbers (starting with a plus)
1350            if (number.charAt(0) == "+") {
1351                var numericChars = "";
1352                // iterate over chars
1353                for (var i = 0; i < number.length; i++) {
1354                    var c = number.charAt(i);
1355                    // if char is number
1356                    if ($.isNumeric(c)) {
1357                        numericChars += c;
1358                        // if current numericChars make a valid dial code
1359                        if (this.countryCodes[numericChars]) {
1360                            // store the actual raw string (useful for matching later)
1361                            dialCode = number.substr(0, i + 1);
1362                        }
1363                        // longest dial code is 4 chars
1364                        if (numericChars.length == 4) {
1365                            break;
1366                        }
1367                    }
1368                }
1369            }
1370            return dialCode;
1371        },
1372        // get the input val, adding the dial code if separateDialCode is enabled
1373        _getFullNumber: function() {
1374            var val = $.trim(this.telInput.val()), dialCode = this.selectedCountryData.dialCode, prefix, numericVal = this._getNumeric(val), // normalized means ensure starts with a 1, so we can match against the full dial code
1375            normalizedVal = numericVal.charAt(0) == "1" ? numericVal : "1" + numericVal;
1376            if (this.options.separateDialCode) {
1377                prefix = "+" + dialCode;
1378            } else if (val.charAt(0) != "+" && val.charAt(0) != "1" && dialCode && dialCode.charAt(0) == "1" && dialCode.length == 4 && dialCode != normalizedVal.substr(0, 4)) {
1379                // if the user has entered a national NANP number, then ensure it includes the full dial code / area code
1380                prefix = dialCode.substr(1);
1381            } else {
1382                prefix = "";
1383            }
1384            return prefix + val;
1385        },
1386        // remove the dial code if separateDialCode is enabled
1387        _beforeSetNumber: function(number) {
1388            if (this.options.separateDialCode) {
1389                var dialCode = this._getDialCode(number);
1390                if (dialCode) {
1391                    // US dialCode is "+1", which is what we want
1392                    // CA dialCode is "+1 123", which is wrong - should be "+1" (as it has multiple area codes)
1393                    // AS dialCode is "+1 684", which is what we want
1394                    // Solution: if the country has area codes, then revert to just the dial code
1395                    if (this.selectedCountryData.areaCodes !== null) {
1396                        dialCode = "+" + this.selectedCountryData.dialCode;
1397                    }
1398                    // a lot of numbers will have a space separating the dial code and the main number, and some NANP numbers will have a hyphen e.g. +1 684-733-1234 - in both cases we want to get rid of it
1399                    // NOTE: don't just trim all non-numerics as may want to preserve an open parenthesis etc
1400                    var start = number[dialCode.length] === " " || number[dialCode.length] === "-" ? dialCode.length + 1 : dialCode.length;
1401                    number = number.substr(start);
1402                }
1403            }
1404            return this._cap(number);
1405        },
1406        // trigger the 'countrychange' event
1407        _triggerCountryChange: function() {
1408            this.telInput.trigger("countrychange", this.selectedCountryData);
1409        },
1410        /**************************
1411   *  SECRET PUBLIC METHODS
1412   **************************/
1413        // this is called when the geoip call returns
1414        handleAutoCountry: function() {
1415            if (this.options.initialCountry === "auto") {
1416                // we must set this even if there is an initial val in the input: in case the initial val is invali
1416d and they delete it - they should see their auto country
1417                this.defaultCountry = $.fn[pluginName].autoCountry;
1418                // if there's no initial value in the input, then update the flag
1419                if (!this.telInput.val()) {
1420                    this.setCountry(this.defaultCountry);
1421                }
1422                this.autoCountryDeferred.resolve();
1423            }
1424        },
1425        // this is called when the utils request completes
1426        handleUtils: function() {
1427            // if the request was successful
1428            if (window.intlTelInputUtils) {
1429                // if there's an initial value in the input, then format it
1430                if (this.telInput.val()) {
1431                    this._updateValFromNumber(this.telInput.val());
1432                }
1433                this._updatePlaceholder();
1434            }
1435            this.utilsScriptDeferred.resolve();
1436        },
1437        /********************
1438   *  PUBLIC METHODS
1439   ********************/
1440        // remove plugin
1441        destroy: function() {
1442            if (this.allowDropdown) {
1443                // make sure the dropdown is closed (and unbind listeners)
1444                this._closeDropdown();
1445                // click event to open dropdown
1446                this.selectedFlagInner.parent().off(this.ns);
1447                // label click hack
1448                this.telInput.closest("label").off(this.ns);
1449            }
1450            // unbind submit event handler on form
1451            if (this.options.autoHideDialCode) {
1452                var form = this.telInput.prop("form");
1453                if (form) {
1454                    $(form).off(this.ns);
1455                }
1456            }
1457            // unbind all events: key events, and focus/blur events if autoHideDialCode=true
1458            this.telInput.off(this.ns);
1459            // remove markup (but leave the original input)
1460            var container = this.telInput.parent();
1461            container.before(this.telInput).remove();
1462        },
1463        // get the extension from the current number
1464        getExtension: function() {
1465            if (window.intlTelInputUtils) {
1466                return intlTelInputUtils.getExtension(this._getFullNumber(), this.selectedCountryData.iso2);
1467            }
1468            return "";
1469        },
1470        // format the number to the given format
1471        getNumber: function(format) {
1472            if (window.intlTelInputUtils) {
1473                return intlTelInputUtils.formatNumber(this._getFullNumber(), this.selectedCountryData.iso2, format);
1474            }
1475            return "";
1476        },
1477        // get the type of the entered number e.g. landline/mobile
1478        getNumberType: function() {
1479            if (window.intlTelInputUtils) {
1480                return intlTelInputUtils.getNumberType(this._getFullNumber(), this.selectedCountryData.iso2);
1481            }
1482            return -99;
1483        },
1484        // get the country data for the currently selected flag
1485        getSelectedCountryData: function() {
1486            return this.selectedCountryData;
1487        },
1488        // get the validation error
1489        getValidationError: function() {
1490            if (window.intlTelInputUtils) {
1491                return intlTelInputUtils.getValidationError(this._getFullNumber(), this.selectedCountryData.iso2);
1492            }
1493            return -99;
1494        },
1495        // validate the input val - assumes the global function isValidNumber (from utilsScript)
1496        isValidNumber: function() {
1497            var val = $.trim(this._getFullNumber()), countryCode = this.options.nationalMode ? this.selectedCountryData.iso2 : "";
1498            return window.intlTelInputUtils ? intlTelInputUtils.isValidNumber(val, countryCode) : null;
1499        },
1500        // update the selected flag, and update the input val accordingly
1501        setCountry: function(countryCode) {
1502            countryCode = countryCode.toLowerCase();
1503            // check if already selected
1504            if (!this.selectedFlagInner.hasClass(countryCode)) {
1505                this._setFlag(countryCode);
1506                this._updateDialCode(this.selectedCountryData.dialCode, false);
1507                this._triggerCountryChange();
1508            }
1509        },
1510        // set the input value and update the flag
1511        setNumber: function(number) {
1512            // we must update the flag first, which updates this.selectedCountryData, which is used for formatting the number before displaying it
1513            var flagChanged = this._updateFlagFromNumber(number);
1514            this._updateValFromNumber(number);
1515            if (flagChanged) {
1516                this._triggerCountryChange();
1517            }
1518        }
1519    };
1520    // using https://github.com/jquery-boilerplate/jquery-boilerplate/wiki/Extending-jQuery-Boilerplate
1521    // (adapted to allow public functions)
1522    $.fn[pluginName] = function(options) {
1523        var args = arguments;
1524        // Is the first parameter an object (options), or was omitted,
1525        // instantiate a new instance of the plugin.
1526        if (options === undefined || typeof options === "object") {
1527            // collect all of the deferred objects for all instances created with this selector
1528            var deferreds = [];
1529            this.each(function() {
1530                if (!$.data(this, "plugin_" + pluginName)) {
1531                    var instance = new Plugin(this, options);
1532                    var instanceDeferreds = instance._init();
1533                    // we now have 2 deffereds: 1 for auto country, 1 for utils script
1534                    deferreds.push(instanceDeferreds[0]);
1535                    deferreds.push(instanceDeferreds[1]);
1536                    $.data(this, "plugin_" + pluginName, instance);
1537                }
1538            });
1539            // return the promise from the "master" deferred object that tracks all the others
1540            return $.when.apply(null, deferreds);
1541        } else if (typeof options === "string" && options[0] !== "_") {
1542            // If the first parameter is a string and it doesn't start
1543            // with an underscore or "contains" the `init`-function,
1544            // treat this as a call to a public method.
1545            // Cache the method call to make it possible to return a value
1546            var returns;
1547            this.each(function() {
1548                var instance = $.data(this, "plugin_" + pluginName);
1549                // Tests that there's already a plugin-instance
1550                // and checks that the requested public method exists
1551                if (instance instanceof Plugin && typeof instance[options] === "function") {
1552                    // Call the method of our plugin instance,
1553                    // and pass it the supplied arguments.
1554                    returns = instance[options].apply(instance, Array.prototype.slice.call(args, 1));
1555                }
1556                // Allow instances to be destroyed via the 'destroy' method
1557                if (options === "destroy") {
1558                    $.data(this, "plugin_" + pluginName, null);
1559                }
1560            });
1561            // If the earlier cached method gives a value back return the value,
1562            // otherwise return this to preserve chainability.
1563            return returns !== undefined ? returns : this;
1564        }
1565    };
1566    /********************
1567 *  STATIC METHODS
1568 ********************/
1569    // get the country data object
1570    $.fn[pluginName].getCountryData = function() {
1571        return allCountries;
1572    };
1573    // load the utils script
1574    $.fn[pluginName].loadUtils = function(path, utilsScriptDeferred) {
1575        if (!$.fn[pluginName].loadedUtilsScript) {
1576            // don't do this twice! (dont just check if window.intlTelInputUtils exists as if init plugin multiple times in quick succession, it may not have finished loading yet)
1577            $.fn[pluginName].loadedUtilsScript = true;
1578            // dont use $.getScript as it prevents caching
1579            $.ajax({
1580                type: "GET",
1581                url: path,
1582                complete: function() {
1583                    // tell all instances that the utils request is complete
1584                    $(".intl-tel-input input").intlTelInput("handleUtils");
1585                },
1586                dataType: "script",
1587                cache: true
1588            });
1589        } else if (utilsScriptDeferred) {
1590            utilsScriptDeferred.resolve();
1591        }
1592    };
1593    // default options
1594    $.fn[pluginName].defaults = defaults;
1595    // version
1596    $.fn[pluginName].version = "11.1.6";
1597    // Array of country objects for the flag dropdown.
1598    // Here is the criteria for the plugin to support a given country/territory
1599    // - It has an iso2 code: https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2
1600    // - It has it's own country calling code (it is not a sub-region of another country): https://en.wikipedia.org/wiki/List_of_country_calling_codes
1601    // - It has a flag in the region-flags project: https://github.com/behdad/region-flags/tree/gh-pages/png
1602    // - It is supported by libphonenumber (it must be listed on this page): https://github.com/googlei18n/libphonenumber/blob/master/resources/ShortNumberMetadata.xml
1603    // Each country array has the following information:
1604    // [
1605    //    Country name,
1606    //    iso2 code,
1607    //    International dial code,
1608    //    Order (if >1 country with same dial code),
1609    //    Area codes
1610    // ]
1611    var allCountries = [ [ "Afghanistan (‫افغانستان‬‎)", "af", "93" ], [ "Albania (Shqipëri)", "al", "355" ], [ "Algeria (‫الجزائر‬‎)", "dz", "213" ], [ "American Samoa", "as", "1684" ], [ "Andorra", "ad", "376" ], [ "Angola", "ao", "244" ], [ "Anguilla", "ai", "1264" ], [ "Antigua and Barbuda", "ag", "1268" ], [ "Argentina", "ar", "54" ], [ "Armenia (Հայաստան)", "am", "374" ], [ "Aruba", "aw", "297" ], [ "Australia", "au", "61", 0 ], [ "Austria (Österreich)", "at", "43" ], [ "Azerbaijan (Azərbaycan)", "az", "994" ], [ "Bahamas", "bs", "1242" ], [ "Bahrain (‫البحرين‬‎)", "bh", "973" ], [ "Bangladesh (বাংলাদেশ)", "bd", "880" ], [ "Barbados", "bb", "1246" ], [ "Belarus (Беларусь)", "by", "375" ], [ "Belgium (België)", "be", "32" ], [ "Belize", "bz", "501" ], [ "Benin (Bénin)", "bj", "229" ], [ "Bermuda", "bm", "1441" ], [ "Bhutan (འབྲུག)", "bt", "975" ], [ "Bolivia", "bo", "591" ], [ "Bosnia and Herzegovina (Босна и Херцеговина)", "ba", "387" ], [ "Botswana", "bw", "267" ], [ "Brazil (Brasil)", "br", "55" ], [ "British Indian Ocean Territory", "io", "246" ], [ "British Virgin Islands", "vg", "1284" ], [ "Brunei", "bn", "673" ], [ "Bulgaria (България)", "bg", "359" ], [ "Burkina Faso", "bf", "226" ], [ "Burundi (Uburundi)", "bi", "257" ], [ "Cambodia (កម្ពុជា)", "kh", "855" ], [ "Cameroon (Cameroun)", "cm", "237" ], [ "Canada", "ca", "1", 1, [ "204", "226", "236", "249", "250", "289", "306", "343", "365", "387", "403", "416", "418", "431", "437", "438", "450", "506", "514", "519", "548", "579", "581", "587", "604", "613", "639", "647", "672", "705", "709", "742", "778", "780", "782", "807", "819", "825", "867", "873", "902", "905" ] ], [ "Cape Verde (Kabu Verdi)", "cv", "238" ], [ "Caribbean Netherlands", "bq", "599", 1 ], [ "Cayman Islands", "ky", "1345" ], [ "Central African Republic (République centrafricaine)", "cf", "236" ], [ "Chad (Tchad)", "td", "235" ], [ "Chile", "cl", "56" ], [ "China (中国)", "cn", "86" ], [ "Christmas Island", "cx", "61", 2 ], [ "Cocos (Keeling) Islands", "cc", "61", 1 ], [ "Colombia", "co", "57" ], [ "Comoros (‫جزر القمر‬‎)", "km", "269" ], [ "Congo (DRC) (Jamhuri ya Kidemokrasia ya Kongo)", "cd", "243" ], [ "Congo (Republic) (Congo-Brazzaville)", "cg", "242" ], [ "Cook Islands", "ck", "682" ], [ "Costa Rica", "cr", "506" ], [ "Côte d’Ivoire", "ci", "225" ], [ "Croatia (Hrvatska)", "hr", "385" ], [ "Cuba", "cu", "53" ], [ "Curaçao", "cw", "599", 0 ], [ "Cyprus (Κύπρος)", "cy", "357" ], [ "Czech Republic (Česká republika)", "cz", "420" ], [ "Denmark (Danmark)", "dk", "45" ], [ "Djibouti", "dj", "253" ], [ "Dominica", "dm", "1767" ], [ "Dominican Republic (República Dominicana)", "do", "1", 2, [ "809", "829", "849" ] ], [ "Ecuador", "ec", "593" ], [ "Egypt (‫مصر‬‎)", "eg", "20" ], [ "El Salvador", "sv", "503" ], [ "Equatorial Guinea (Guinea Ecuatorial)", "gq", "240" ], [ "Eritrea", "er", "291" ], [ "Estonia (Eesti)", "ee", "372" ], [ "Ethiopia", "et", "251" ], [ "Falkland Islands (Islas Malvinas)", "fk", "500" ], [ "Faroe Islands (Føroyar)", "fo", "298" ], [ "Fiji", "fj", "679" ], [ "Finland (Suomi)", "fi", "358", 0 ], [ "France", "fr", "33" ], [ "French Guiana (Guyane française)", "gf", "594" ], [ "French Polynesia (Polynésie française)", "pf", "689" ], [ "Gabon", "ga", "241" ], [ "Gambia", "gm", "220" ], [ "Georgia (საქართველო)", "ge", "995" ], [ "Germany (Deutschland)", "de", "49" ], [ "Ghana (Gaana)", "gh", "233" ], [ "Gibraltar", "gi", "350" ], [ "Greece (Ελλάδα)", "gr", "30" ], [ "Greenland (Kalaallit Nun
1611aat)", "gl", "299" ], [ "Grenada", "gd", "1473" ], [ "Guadeloupe", "gp", "590", 0 ], [ "Guam", "gu", "1671" ], [ "Guatemala", "gt", "502" ], [ "Guernsey", "gg", "44", 1 ], [ "Guinea (Guinée)", "gn", "224" ], [ "Guinea-Bissau (Guiné Bissau)", "gw", "245" ], [ "Guyana", "gy", "592" ], [ "Haiti", "ht", "509" ], [ "Honduras", "hn", "504" ], [ "Hong Kong (香港)", "hk", "852" ], [ "Hungary (Magyarország)", "hu", "36" ], [ "Iceland (Ísland)", "is", "354" ], [ "India (भारत)", "in", "91" ], [ "Indonesia", "id", "62" ], [ "Iran (‫ایران‬‎)", "ir", "98" ], [ "Iraq (‫العراق‬‎)", "iq", "964" ], [ "Ireland", "ie", "353" ], [ "Isle of Man", "im", "44", 2 ], [ "Israel (‫ישראל‬‎)", "il", "972" ], [ "Italy (Italia)", "it", "39", 0 ], [ "Jamaica", "jm", "1876" ], [ "Japan (日本)", "jp", "81" ], [ "Jersey", "je", "44", 3 ], [ "Jordan (‫الأردن‬‎)", "jo", "962" ], [ "Kazakhstan (Казахстан)", "kz", "7", 1 ], [ "Kenya", "ke", "254" ], [ "Kiribati", "ki", "686" ], [ "Kosovo", "xk", "383" ], [ "Kuwait (‫الكويت‬‎)", "kw", "965" ], [ "Kyrgyzstan (Кыргызстан)", "kg", "996" ], [ "Laos (ລາວ)", "la", "856" ], [ "Latvia (Latvija)", "lv", "371" ], [ "Lebanon (‫لبنان‬‎)", "lb", "961" ], [ "Lesotho", "ls", "266" ], [ "Liberia", "lr", "231" ], [ "Libya (‫ليبيا‬‎)", "ly", "218" ], [ "Liechtenstein", "li", "423" ], [ "Lithuania (Lietuva)", "lt", "370" ], [ "Luxembourg", "lu", "352" ], [ "Macau (澳門)", "mo", "853" ], [ "Macedonia (FYROM) (Македонија)", "mk", "389" ], [ "Madagascar (Madagasikara)", "mg", "261" ], [ "Malawi", "mw", "265" ], [ "Malaysia", "my", "60" ], [ "Maldives", "mv", "960" ], [ "Mali", "ml", "223" ], [ "Malta", "mt", "356" ], [ "Marshall Islands", "mh", "692" ], [ "Martinique", "mq", "596" ], [ "Mauritania (‫موريتانيا‬‎)", "mr", "222" ], [ "Mauritius (Moris)", "mu", "230" ], [ "Mayotte", "yt", "262", 1 ], [ "Mexico (México)", "mx", "52" ], [ "Micronesia", "fm", "691" ], [ "Moldova (Republica Moldova)", "md", "373" ], [ "Monaco", "mc", "377" ], [ "Mongolia (Монгол)", "mn", "976" ], [ "Montenegro (Crna Gora)", "me", "382" ], [ "Montserrat", "ms", "1664" ], [ "Morocco (‫المغرب‬‎)", "ma", "212", 0 ], [ "Mozambique (Moçambique)", "mz", "258" ], [ "Myanmar (Burma) (မြန်မာ)", "mm", "95" ], [ "Namibia (Namibië)", "na", "264" ], [ "Nauru", "nr", "674" ], [ "Nepal (नेपाल)", "np", "977" ], [ "Netherlands (Nederland)", "nl", "31" ], [ "New Caledonia (Nouvelle-Calédonie)", "nc", "687" ], [ "New Zealand", "nz", "64" ], [ "Nicaragua", "ni", "505" ], [ "Niger (Nijar)", "ne", "227" ], [ "Nigeria", "ng", "234" ], [ "Niue", "nu", "683" ], [ "Norfolk Island", "nf", "672" ], [ "North Korea (조선 민주주의 인민 공화국)", "kp", "850" ], [ "Northern Mariana Islands", "mp", "1670" ], [ "Norway (Norge)", "no", "47", 0 ], [ "Oman (‫عُمان‬‎)", "om", "968" ], [ "Pakistan (‫پاکستان‬‎)", "pk", "92" ], [ "Palau", "pw", "680" ], [ "Palestine (‫فلسطين‬‎)", "ps", "970" ], [ "Panama (Panamá)", "pa", "507" ], [ "Papua New Guinea", "pg", "675" ], [ "Paraguay", "py", "595" ], [ "Peru (Perú)", "pe", "51" ], [ "Philippines", "ph", "63" ], [ "Poland (Polska)", "pl", "48" ], [ "Portugal", "pt", "351" ], [ "Puerto Rico", "pr", "1", 3, [ "787", "939" ] ], [ "Qatar (‫قطر‬‎)", "qa", "974" ], [ "Réunion (La Réunion)", "re", "262", 0 ], [ "Romania (România)", "ro", "40" ], [ "Russia (Россия)", "ru", "7", 0 ], [ "Rwanda", "rw", "250" ], [ "Saint Barthélemy", "bl", "590", 1 ], [ "Saint Helena", "sh", "290" ], [ "Saint Kitts and Nevis", "kn", "1869" ], [ "Saint Lucia", "lc", "1758" ], [ "Saint Martin (Saint-Martin (partie française))", "mf", "590", 2 ], [ "Saint Pierre and Miquelon (Saint-Pierre-et-Miquelon)", "pm", "508" ], [ "Saint Vincent and the Grenadines", "vc", "1784" ], [ "Samoa", "ws", "685" ], [ "San Marino", "sm", "378" ], [ "São Tomé and Príncipe (São Tomé e Príncipe)", "st", "239" ], [ "Saudi Arabia (‫المملكة العربية السعودية‬‎)", "sa", "966" ], [ "Senegal (Sénégal)", "sn", "221" ], [ "Serbia (Србија)", "rs", "381" ], [ "Seychelles", "sc", "248" ], [ "Sierra Leone", "sl", "232" ], [ "Singapore", "sg", "65" ], [ "Sint Maarten", "sx", "1721" ], [ "Slovakia (Slovensko)", "sk", "421" ], [ "Slovenia (Slovenija)", "si", "386" ], [ "Solomon Islands", "sb", "677" ], [ "Somalia (Soomaaliya)", "so", "252" ], [ "South Africa", "za", "27" ], [ "South Korea (대한민국)", "kr", "82" ], [ "South Sudan (‫جنوب السودان‬‎)", "ss", "211" ], [ "Spain (España)", "es", "34" ], [ "Sri Lanka (ශ්‍රී ලංකාව)", "lk", "94" ], [ "Sudan (‫السودان‬‎)", "sd", "249" ], [ "Suriname", "sr", "597" ], [ "Svalbard and Jan Mayen", "sj", "47", 1 ], [ "Swaziland", "sz", "268" ], [ "Sweden (Sverige)", "se", "46" ], [ "Switzerland (Schweiz)", "ch", "41" ], [ "Syria (‫سوريا‬‎)", "sy", "963" ], [ "Taiwan (台灣)", "tw", "886" ], [ "Tajikistan", "tj", "992" ], [ "Tanzania", "tz", "255" ], [ "Thailand (ไทย)", "th", "66" ], [ "Timor-Leste", "tl", "670" ], [ "Togo", "tg", "228" ], [ "Tokelau", "tk", "690" ], [ "Tonga", "to", "676" ], [ "Trinidad and Tobago", "tt", "1868" ], [ "Tunisia (‫تونس‬‎)", "tn", "216" ], [ "Turkey (Türkiye)", "tr", "90" ], [ "Turkmenistan", "tm", "993" ], [ "Turks and Caicos Islands", "tc", "1649" ], [ "Tuvalu", "tv", "688" ], [ "U.S. Virgin Islands", "vi", "1340" ], [ "Uganda", "ug", "256" ], [ "Ukraine (Україна)", "ua", "380" ], [ "United Arab Emirates (‫الإمارات العربية المتحدة‬‎)", "ae", "971" ], [ "United Kingdom", "gb", "44", 0 ], [ "United States", "us", "1", 0 ], [ "Uruguay", "uy", "598" ], [ "Uzbekistan (Oʻzbekiston)", "uz", "998" ], [ "Vanuatu", "vu", "678" ], [ "Vatican City (Città del Vaticano)", "va", "39", 1 ], [ "Venezuela", "ve", "58" ], [ "Vietnam (Việt Nam)", "vn", "84" ], [ "Wallis and Futuna (Wallis-et-Futuna)", "wf", "681" ], [ "Western Sahara (‫الصحراء الغربية‬‎)", "eh", "212", 1 ], [ "Yemen (‫اليمن‬‎)", "ye", "967" ], [ "Zambia", "zm", "260" ], [ "Zimbabwe", "zw", "263" ], [ "Åland Islands", "ax", "358", 1 ] ];
1612    // loop over all of the countries above
1613    for (var i = 0; i < allCountries.length; i++) {
1614        var c = allCountries[i];
1615        allCountries[i] = {
1616            name: c[0],
1617            iso2: c[1],
1618            dialCode: c[2],
1619            priority: c[3] || 0,
1620            areaCodes: c[4] || null
1621        };
1622    }
1623});;
1624/*
1625     _ _      _       _
1626 ___| (_) ___| | __  (_)___
1627/ __| | |/ __| |/ /  | / __|
1628\__ \ | | (__|   < _ | \__ \
1629|___/_|_|\___|_|\_(_)/ |___/
1630                   |__/
1631
1632 Version: 1.6.0
1633  Author: Ken Wheeler
1634 Website: http://kenwheeler.github.io
1635    Docs: http://kenwheeler.github.io/slick
1636    Repo: http://github.com/kenwheeler/slick
1637  Issues: http://github.com/kenwheeler/slick/issues
1638
1639 */
1640/* global window, document, define, jQuery, setInterval, clearInterval */
1641(function(factory) {
1642    'use strict';
1643    if (typeof define === 'function' && define.amd) {
1644        define(['jquery'], factory);
1645    } else if (typeof exports !== 'undefined') {
1646        module.exports = factory(require('jquery'));
1647    } else {
1648        factory(jQuery);
1649    }
1650
1651}(function($) {
1652    'use strict';
1653    var Slick = window.Slick || {};
1654
1655    Slick = (function() {
1656
1657        var instanceUid = 0;
1658
1659        function Slick(element, settings) {
1660
1661            var _ = this, dataSettings;
1662
1663            _.defaults = {
1664                accessibility: true,
1665                adaptiveHeight: false,
1666                appendArrows: $(element),
1667                appendDots: $(element),
1668                arrows: true,
1669                asNavFor: null,
1670                prevArrow: '<button type="button" data-role="none" class="slick-prev" aria-label="Previous" tabindex="0" role="button">Previous</button>',
1671                nextArrow: '<button type="button" data-role="none" class="slick-next" aria-label="Next" tabindex="0" role="button">Next</button>',
1672                autoplay: false,
1673                autoplaySpeed: 3000,
1674                centerMode: false,
1675                centerPadding: '50px',
1676                cssEase: 'ease',
1677                customPaging: function(slider, i) {
1678                    return $('<button type="button" data-role="none" role="button" tabindex="0" />').text(i + 1);
1679                },
1680                dots: false,
1681                dotsClass: 'slick-dots',
1682                draggable: true,
1683                easing: 'linear',
1684                edgeFriction: 0.35,
1685                fade: false,
1686                focusOnSelect: false,
1687                infinite: true,
1688                initialSlide: 0,
1689                lazyLoad: 'ondemand',
1690                mobileFirst: false,
1691                pauseOnHover: true,
1692                pauseOnFocus: true,
1693                pauseOnDotsHover: false,
1694                respondTo: 'window',
1695                responsive: null,
1696                rows: 1,
1697                rtl: false,
1698                slide: '',
1699                slidesPerRow: 1,
1700                slidesToShow: 1,
1701                slidesToScroll: 1,
1702                speed: 500,
1703                swipe: true,
1704                swipeToSlide: false,
1705                touchMove: true,
1706                touchThreshold: 5,
1707                useCSS: true,
1708                useTransform: true,
1709                variableWidth: false,
1710                vertical: false,
1711                verticalSwiping: false,
1712                waitForAnimate: true,
1713                zIndex: 1000
1714            };
1715
1716            _.initials = {
1717                animating: false,
1718                dragging: false,
1719                autoPlayTimer: null,
1720                currentDirection: 0,
1721                currentLeft: null,
1722                currentSlide: 0,
1723                direction: 1,
1724                $dots: null,
1725                listWidth: null,
1726                listHeight: null,
1727                loadIndex: 0,
1728                $nextArrow: null,
1729                $prevArrow: null,
1730                slideCount: null,
1731                slideWidth: null,
1732                $slideTrack: null,
1733                $slides: null,
1734                sliding: false,
1735                slideOffset: 0,
1736                swipeLeft: null
vendor: 11,177 bytes, lines 1736-2119
1736,
1737                $list: null,
1738                touchObject: {},
1739                transformsEnabled: false,
1740                unslicked: false
1741            };
1742
1743            $.extend(_, _.initials);
1744
1745            _.activeBreakpoint = null;
1746            _.animType = null;
1747            _.animProp = null;
1748            _.breakpoints = [];
1749            _.breakpointSettings = [];
1750            _.cssTransitions = false;
1751            _.focussed = false;
1752            _.interrupted = false;
1753            _.hidden = 'hidden';
1754            _.paused = true;
1755            _.positionProp = null;
1756            _.respondTo = null;
1757            _.rowCount = 1;
1758            _.shouldClick = true;
1759            _.$slider = $(element);
1760            _.$slidesCache = null;
1761            _.transformType = null;
1762            _.transitionType = null;
1763            _.visibilityChange = 'visibilitychange';
1764            _.windowWidth = 0;
1765            _.windowTimer = null;
1766
1767            dataSettings = $(element).data('slick') || {};
1768
1769            _.options = $.extend({}, _.defaults, settings, dataSettings);
1770
1771            _.currentSlide = _.options.initialSlide;
1772
1773            _.originalSettings = _.options;
1774
1775            if (typeof document.mozHidden !== 'undefined') {
1776                _.hidden = 'mozHidden';
1777                _.visibilityChange = 'mozvisibilitychange';
1778            } else if (typeof document.webkitHidden !== 'undefined') {
1779                _.hidden = 'webkitHidden';
1780                _.visibilityChange = 'webkitvisibilitychange';
1781            }
1782
1783            _.autoPlay = $.proxy(_.autoPlay, _);
1784            _.autoPlayClear = $.proxy(_.autoPlayClear, _);
1785            _.autoPlayIterator = $.proxy(_.autoPlayIterator, _);
1786            _.changeSlide = $.proxy(_.changeSlide, _);
1787            _.clickHandler = $.proxy(_.clickHandler, _);
1788            _.selectHandler = $.proxy(_.selectHandler, _);
1789            _.setPosition = $.proxy(_.setPosition, _);
1790            _.swipeHandler = $.proxy(_.swipeHandler, _);
1791            _.dragHandler = $.proxy(_.dragHandler, _);
1792            _.keyHandler = $.proxy(_.keyHandler, _);
1793
1794            _.instanceUid = instanceUid++;
1795
1796            // A simple way to check for HTML strings
1797            // Strict HTML recognition (must start with <)
1798            // Extracted from jQuery v1.11 source
1799            _.htmlExpr = /^(?:\s*(<[\w\W]+>)[^>]*)$/;
1800
1801
1802            _.registerBreakpoints();
1803            _.init(true);
1804
1805        }
1806
1807        return Slick;
1808
1809    }());
1810
1811    Slick.prototype.activateADA = function() {
1812        var _ = this;
1813
1814        _.$slideTrack.find('.slick-active').attr({
1815            'aria-hidden': 'false'
1816        }).find('a, input, button, select').attr({
1817            'tabindex': '0'
1818        });
1819
1820    };
1821
1822    Slick.prototype.addSlide = Slick.prototype.slickAdd = function(markup, index, addBefore) {
1823
1824        var _ = this;
1825
1826        if (typeof(index) === 'boolean') {
1827            addBefore = index;
1828            index = null;
1829        } else if (index < 0 || (index >= _.slideCount)) {
1830            return false;
1831        }
1832
1833        _.unload();
1834
1835        if (typeof(index) === 'number') {
1836            if (index === 0 && _.$slides.length === 0) {
1837                $(markup).appendTo(_.$slideTrack);
1838            } else if (addBefore) {
1839                $(markup).insertBefore(_.$slides.eq(index));
1840            } else {
1841                $(markup).insertAfter(_.$slides.eq(index));
1842            }
1843        } else {
1844            if (addBefore === true) {
1845                $(markup).prependTo(_.$slideTrack);
1846            } else {
1847                $(markup).appendTo(_.$slideTrack);
1848            }
1849        }
1850
1851        _.$slides = _.$slideTrack.children(this.options.slide);
1852
1853        _.$slideTrack.children(this.options.slide).detach();
1854
1855        _.$slideTrack.append(_.$slides);
1856
1857        _.$slides.each(function(index, element) {
1858            $(element).attr('data-slick-index', index);
1859        });
1860
1861        _.$slidesCache = _.$slides;
1862
1863        _.reinit();
1864
1865    };
1866
1867    Slick.prototype.animateHeight = function() {
1868        var _ = this;
1869        if (_.options.slidesToShow === 1 && _.options.adaptiveHeight === true && _.options.vertical === false) {
1870            var targetHeight = _.$slides.eq(_.currentSlide).outerHeight(true);
1871            _.$list.animate({
1872                height: targetHeight
1873            }, _.options.speed);
1874        }
1875    };
1876
1877    Slick.prototype.animateSlide = function(targetLeft, callback) {
1878
1879        var animProps = {},
1880            _ = this;
1881
1882        _.animateHeight();
1883
1884        if (_.options.rtl === true && _.options.vertical === false) {
1885            targetLeft = -targetLeft;
1886        }
1887        if (_.transformsEnabled === false) {
1888            if (_.options.vertical === false) {
1889                _.$slideTrack.animate({
1890                    left: targetLeft
1891                }, _.options.speed, _.options.easing, callback);
1892            } else {
1893                _.$slideTrack.animate({
1894                    top: targetLeft
1895                }, _.options.speed, _.options.easing, callback);
1896            }
1897
1898        } else {
1899
1900            if (_.cssTransitions === false) {
1901                if (_.options.rtl === true) {
1902                    _.currentLeft = -(_.currentLeft);
1903                }
1904                $({
1905                    animStart: _.currentLeft
1906                }).animate({
1907                    animStart: targetLeft
1908                }, {
1909                    duration: _.options.speed,
1910                    easing: _.options.easing,
1911                    step: function(now) {
1912                        now = Math.ceil(now);
1913                        if (_.options.vertical === false) {
1914                            animProps[_.animType] = 'translate(' +
1915                                now + 'px, 0px)';
1916                            _.$slideTrack.css(animProps);
1917                        } else {
1918                            animProps[_.animType] = 'translate(0px,' +
1919                                now + 'px)';
1920                            _.$slideTrack.css(animProps);
1921                        }
1922                    },
1923                    complete: function() {
1924                        if (callback) {
1925                            callback.call();
1926                        }
1927                    }
1928                });
1929
1930            } else {
1931
1932                _.applyTransition();
1933                targetLeft = Math.ceil(targetLeft);
1934
1935                if (_.options.vertical === false) {
1936                    animProps[_.animType] = 'translate3d(' + targetLeft + 'px, 0px, 0px)';
1937                } else {
1938                    animProps[_.animType] = 'translate3d(0px,' + targetLeft + 'px, 0px)';
1939                }
1940                _.$slideTrack.css(animProps);
1941
1942                if (callback) {
1943                    setTimeout(function() {
1944
1945                        _.disableTransition();
1946
1947                        callback.call();
1948                    }, _.options.speed);
1949                }
1950
1951            }
1952
1953        }
1954
1955    };
1956
1957    Slick.prototype.getNavTarget = function() {
1958
1959        var _ = this,
1960            asNavFor = _.options.asNavFor;
1961
1962        if ( asNavFor && asNavFor !== null ) {
1963            asNavFor = $(asNavFor).not(_.$slider);
1964        }
1965
1966        return asNavFor;
1967
1968    };
1969
1970    Slick.prototype.asNavFor = function(index) {
1971
1972        var _ = this,
1973            asNavFor = _.getNavTarget();
1974
1975        if ( asNavFor !== null && typeof asNavFor === 'object' ) {
1976            asNavFor.each(function() {
1977                var target = $(this).slick('getSlick');
1978                if(!target.unslicked) {
1979                    target.slideHandler(index, true);
1980                }
1981            });
1982        }
1983
1984    };
1985
1986    Slick.prototype.applyTransition = function(slide) {
1987
1988        var _ = this,
1989            transition = {};
1990
1991        if (_.options.fade === false) {
1992            transition[_.transitionType] = _.transformType + ' ' + _.options.speed + 'ms ' + _.options.cssEase;
1993        } else {
1994            transition[_.transitionType] = 'opacity ' + _.options.speed + 'ms ' + _.options.cssEase;
1995        }
1996
1997        if (_.options.fade === false) {
1998            _.$slideTrack.css(transition);
1999        } else {
2000            _.$slides.eq(slide).css(transition);
2001        }
2002
2003    };
2004
2005    Slick.prototype.autoPlay = function() {
2006
2007        var _ = this;
2008
2009        _.autoPlayClear();
2010
2011        if ( _.slideCount > _.options.slidesToShow ) {
2012            _.autoPlayTimer = setInterval( _.autoPlayIterator, _.options.autoplaySpeed );
2013        }
2014
2015    };
2016
2017    Slick.prototype.autoPlayClear = function() {
2018
2019        var _ = this;
2020
2021        if (_.autoPlayTimer) {
2022            clearInterval(_.autoPlayTimer);
2023        }
2024
2025    };
2026
2027    Slick.prototype.autoPlayIterator = function() {
2028
2029        var _ = this,
2030            slideTo = _.currentSlide + _.options.slidesToScroll;
2031
2032        if ( !_.paused && !_.interrupted && !_.focussed ) {
2033
2034            if ( _.options.infinite === false ) {
2035
2036                if ( _.direction === 1 && ( _.currentSlide + 1 ) === ( _.slideCount - 1 )) {
2037                    _.direction = 0;
2038                }
2039
2040                else if ( _.direction === 0 ) {
2041
2042                    slideTo = _.currentSlide - _.options.slidesToScroll;
2043
2044                    if ( _.currentSlide - 1 === 0 ) {
2045                        _.direction = 1;
2046                    }
2047
2048                }
2049
2050            }
2051
2052            _.slideHandler( slideTo );
2053
2054        }
2055
2056    };
2057
2058    Slick.prototype.buildArrows = function() {
2059
2060        var _ = this;
2061
2062        if (_.options.arrows === true ) {
2063
2064            _.$prevArrow = $(_.options.prevArrow).addClass('slick-arrow');
2065            _.$nextArrow = $(_.options.nextArrow).addClass('slick-arrow');
2066
2067            if( _.slideCount > _.options.slidesToShow ) {
2068
2069                _.$prevArrow.removeClass('slick-hidden').removeAttr('aria-hidden tabindex');
2070                _.$nextArrow.removeClass('slick-hidden').removeAttr('aria-hidden tabindex');
2071
2072                if (_.htmlExpr.test(_.options.prevArrow)) {
2073                    _.$prevArrow.prependTo(_.options.appendArrows);
2074                }
2075
2076                if (_.htmlExpr.test(_.options.nextArrow)) {
2077                    _.$nextArrow.appendTo(_.options.appendArrows);
2078                }
2079
2080                if (_.options.infinite !== true) {
2081                    _.$prevArrow
2082                        .addClass('slick-disabled')
2083                        .attr('aria-disabled', 'true');
2084                }
2085
2086            } else {
2087
2088                _.$prevArrow.add( _.$nextArrow )
2089
2090                    .addClass('slick-hidden')
2091                    .attr({
2092                        'aria-disabled': 'true',
2093                        'tabindex': '-1'
2094                    });
2095
2096            }
2097
2098        }
2099
2100    };
2101
2102    Slick.prototype.buildDots = function() {
2103
2104        var _ = this,
2105            i, dot;
2106
2107        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
2108
2109            _.$slider.addClass('slick-dotted');
2110
2111            dot = $('<ul />').addClass(_.options.dotsClass);
2112
2113            for (i = 0; i <= _.getDotCount(); i += 1) {
2114                dot.append($('<li />').append(_.options.customPaging.call(this, _, i)));
2115            }
2116
2117            _.$dots = dot.appendTo(_.options.appendDots);
2118
2119            _.$dots.find('li').first().addClass('slick-active')
vendor: 18,779 bytes, lines 2119-2728
2119.attr('aria-hidden', 'false');
2120
2121        }
2122
2123    };
2124
2125    Slick.prototype.buildOut = function() {
2126
2127        var _ = this;
2128
2129        _.$slides =
2130            _.$slider
2131                .children( _.options.slide + ':not(.slick-cloned)')
2132                .addClass('slick-slide');
2133
2134        _.slideCount = _.$slides.length;
2135
2136        _.$slides.each(function(index, element) {
2137            $(element)
2138                .attr('data-slick-index', index)
2139                .data('originalStyling', $(element).attr('style') || '');
2140        });
2141
2142        _.$slider.addClass('slick-slider');
2143
2144        _.$slideTrack = (_.slideCount === 0) ?
2145            $('<div class="slick-track"/>').appendTo(_.$slider) :
2146            _.$slides.wrapAll('<div class="slick-track"/>').parent();
2147
2148        _.$list = _.$slideTrack.wrap(
2149            '<div aria-live="polite" class="slick-list"/>').parent();
2150        _.$slideTrack.css('opacity', 0);
2151
2152        if (_.options.centerMode === true || _.options.swipeToSlide === true) {
2153            _.options.slidesToScroll = 1;
2154        }
2155
2156        $('img[data-lazy]', _.$slider).not('[src]').addClass('slick-loading');
2157
2158        _.setupInfinite();
2159
2160        _.buildArrows();
2161
2162        _.buildDots();
2163
2164        _.updateDots();
2165
2166
2167        _.setSlideClasses(typeof _.currentSlide === 'number' ? _.currentSlide : 0);
2168
2169        if (_.options.draggable === true) {
2170            _.$list.addClass('draggable');
2171        }
2172
2173    };
2174
2175    Slick.prototype.buildRows = function() {
2176
2177        var _ = this, a, b, c, newSlides, numOfSlides, originalSlides,slidesPerSection;
2178
2179        newSlides = document.createDocumentFragment();
2180        originalSlides = _.$slider.children();
2181
2182        if(_.options.rows > 1) {
2183
2184            slidesPerSection = _.options.slidesPerRow * _.options.rows;
2185            numOfSlides = Math.ceil(
2186                originalSlides.length / slidesPerSection
2187            );
2188
2189            for(a = 0; a < numOfSlides; a++){
2190                var slide = document.createElement('div');
2191                for(b = 0; b < _.options.rows; b++) {
2192                    var row = document.createElement('div');
2193                    for(c = 0; c < _.options.slidesPerRow; c++) {
2194                        var target = (a * slidesPerSection + ((b * _.options.slidesPerRow) + c));
2195                        if (originalSlides.get(target)) {
2196                            row.appendChild(originalSlides.get(target));
2197                        }
2198                    }
2199                    slide.appendChild(row);
2200                }
2201                newSlides.appendChild(slide);
2202            }
2203
2204            _.$slider.empty().append(newSlides);
2205            _.$slider.children().children().children()
2206                .css({
2207                    'width':(100 / _.options.slidesPerRow) + '%',
2208                    'display': 'inline-block'
2209                });
2210
2211        }
2212
2213    };
2214
2215    Slick.prototype.checkResponsive = function(initial, forceUpdate) {
2216
2217        var _ = this,
2218            breakpoint, targetBreakpoint, respondToWidth, triggerBreakpoint = false;
2219        var sliderWidth = _.$slider.width();
2220        var windowWidth = window.innerWidth || $(window).width();
2221
2222        if (_.respondTo === 'window') {
2223            respondToWidth = windowWidth;
2224        } else if (_.respondTo === 'slider') {
2225            respondToWidth = sliderWidth;
2226        } else if (_.respondTo === 'min') {
2227            respondToWidth = Math.min(windowWidth, sliderWidth);
2228        }
2229
2230        if ( _.options.responsive &&
2231            _.options.responsive.length &&
2232            _.options.responsive !== null) {
2233
2234            targetBreakpoint = null;
2235
2236            for (breakpoint in _.breakpoints) {
2237                if (_.breakpoints.hasOwnProperty(breakpoint)) {
2238                    if (_.originalSettings.mobileFirst === false) {
2239                        if (respondToWidth < _.breakpoints[breakpoint]) {
2240                            targetBreakpoint = _.breakpoints[breakpoint];
2241                        }
2242                    } else {
2243                        if (respondToWidth > _.breakpoints[breakpoint]) {
2244                            targetBreakpoint = _.breakpoints[breakpoint];
2245                        }
2246                    }
2247                }
2248            }
2249
2250            if (targetBreakpoint !== null) {
2251                if (_.activeBreakpoint !== null) {
2252                    if (targetBreakpoint !== _.activeBreakpoint || forceUpdate) {
2253                        _.activeBreakpoint =
2254                            targetBreakpoint;
2255                        if (_.breakpointSettings[targetBreakpoint] === 'unslick') {
2256                            _.unslick(targetBreakpoint);
2257                        } else {
2258                            _.options = $.extend({}, _.originalSettings,
2259                                _.breakpointSettings[
2260                                    targetBreakpoint]);
2261                            if (initial === true) {
2262                                _.currentSlide = _.options.initialSlide;
2263                            }
2264                            _.refresh(initial);
2265                        }
2266                        triggerBreakpoint = targetBreakpoint;
2267                    }
2268                } else {
2269                    _.activeBreakpoint = targetBreakpoint;
2270                    if (_.breakpointSettings[targetBreakpoint] === 'unslick') {
2271                        _.unslick(targetBreakpoint);
2272                    } else {
2273                        _.options = $.extend({}, _.originalSettings,
2274                            _.breakpointSettings[
2275                                targetBreakpoint]);
2276                        if (initial === true) {
2277                            _.currentSlide = _.options.initialSlide;
2278                        }
2279                        _.refresh(initial);
2280                    }
2281                    triggerBreakpoint = targetBreakpoint;
2282                }
2283            } else {
2284                if (_.activeBreakpoint !== null) {
2285                    _.activeBreakpoint = null;
2286                    _.options = _.originalSettings;
2287                    if (initial === true) {
2288                        _.currentSlide = _.options.initialSlide;
2289                    }
2290                    _.refresh(initial);
2291                    triggerBreakpoint = targetBreakpoint;
2292                }
2293            }
2294
2295            // only trigger breakpoints during an actual break. not on initialize.
2296            if( !initial && triggerBreakpoint !== false ) {
2297                _.$slider.trigger('breakpoint', [_, triggerBreakpoint]);
2298            }
2299        }
2300
2301    };
2302
2303    Slick.prototype.changeSlide = function(event, dontAnimate) {
2304
2305        var _ = this,
2306            $target = $(event.currentTarget),
2307            indexOffset, slideOffset, unevenOffset;
2308
2309        // If target is a link, prevent default action.
2310        if($target.is('a')) {
2311            event.preventDefault();
2312        }
2313
2314        // If target is not the <li> element (ie: a child), find the <li>.
2315        if(!$target.is('li')) {
2316            $target = $target.closest('li');
2317        }
2318
2319        unevenOffset = (_.slideCount % _.options.slidesToScroll !== 0);
2320        indexOffset = unevenOffset ? 0 : (_.slideCount - _.currentSlide) % _.options.slidesToScroll;
2321
2322        switch (event.data.message) {
2323
2324            case 'previous':
2325                slideOffset = indexOffset === 0 ? _.options.slidesToScroll : _.options.slidesToShow - indexOffset;
2326                if (_.slideCount > _.options.slidesToShow) {
2327                    _.slideHandler(_.currentSlide - slideOffset, false, dontAnimate);
2328                }
2329                break;
2330
2331            case 'next':
2332                slideOffset = indexOffset === 0 ? _.options.slidesToScroll : indexOffset;
2333                if (_.slideCount > _.options.slidesToShow) {
2334                    _.slideHandler(_.currentSlide + slideOffset, false, dontAnimate);
2335                }
2336                break;
2337
2338            case 'index':
2339                var index = event.data.index === 0 ? 0 :
2340                    event.data.index || $target.index() * _.options.slidesToScroll;
2341
2342                _.slideHandler(_.checkNavigable(index), false, dontAnimate);
2343                $target.children().trigger('focus');
2344                break;
2345
2346            default:
2347                return;
2348        }
2349
2350    };
2351
2352    Slick.prototype.checkNavigable = function(index) {
2353
2354        var _ = this,
2355            navigables, prevNavigable;
2356
2357        navigables = _.getNavigableIndexes();
2358        prevNavigable = 0;
2359        if (index > navigables[navigables.length - 1]) {
2360            index = navigables[navigables.length - 1];
2361        } else {
2362            for (var n in navigables) {
2363                if (index < navigables[n]) {
2364                    index = prevNavigable;
2365                    break;
2366                }
2367                prevNavigable = navigables[n];
2368            }
2369        }
2370
2371        return index;
2372    };
2373
2374    Slick.prototype.cleanUpEvents = function() {
2375
2376        var _ = this;
2377
2378        if (_.options.dots && _.$dots !== null) {
2379
2380            $('li', _.$dots)
2381                .off('click.slick', _.changeSlide)
2382                .off('mouseenter.slick', $.proxy(_.interrupt, _, true))
2383                .off('mouseleave.slick', $.proxy(_.interrupt, _, false));
2384
2385        }
2386
2387        _.$slider.off('focus.slick blur.slick');
2388
2389        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
2390            _.$prevArrow && _.$prevArrow.off('click.slick', _.changeSlide);
2391            _.$nextArrow && _.$nextArrow.off('click.slick', _.changeSlide);
2392        }
2393
2394        _.$list.off('touchstart.slick mousedown.slick', _.swipeHandler);
2395        _.$list.off('touchmove.slick mousemove.slick', _.swipeHandler);
2396        _.$list.off('touchend.slick mouseup.slick', _.swipeHandler);
2397        _.$list.off('touchcancel.slick mouseleave.slick', _.swipeHandler);
2398
2399        _.$list.off('click.slick', _.clickHandler);
2400
2401        $(document).off(_.visibilityChange, _.visibility);
2402
2403        _.cleanUpSlideEvents();
2404
2405        if (_.options.accessibility === true) {
2406            _.$list.off('keydown.slick', _.keyHandler);
2407        }
2408
2409        if (_.options.focusOnSelect === true) {
2410            $(_.$slideTrack).children().off('click.slick', _.selectHandler);
2411        }
2412
2413        $(window).off('orientationchange.slick.slick-' + _.instanceUid, _.orientationChange);
2414
2415        $(window).off('resize.slick.slick-' + _.instanceUid, _.resize);
2416
2417        $('[draggable!=true]', _.$slideTrack).off('dragstart', _.preventDefault);
2418
2419        $(window).off('load.slick.slick-' + _.instanceUid, _.setPosition);
2420        $(document).off('ready.slick.slick-' + _.instanceUid, _.setPosition);
2421
2422    };
2423
2424    Slick.prototype.cleanUpSlideEvents = function() {
2425
2426        var _ = this;
2427
2428        _.$list.off('mouseenter.slick', $.proxy(_.interrupt, _, true));
2429        _.$list.off('mouseleave.slick', $.proxy(_.interrupt, _, false));
2430
2431    };
2432
2433    Slick.prototype.cleanUpRows = function() {
2434
2435        var _ = this, originalSlides;
2436
2437        if(_.options.rows > 1) {
2438            originalSlides = _.$slides.children().children();
2439            originalSlides.removeAttr('style');
2440            _.$slider.empty().append(originalSlides);
2441        }
2442
2443    };
2444
2445    Slick.prototype.clickHandler = function(event) {
2446
2447        var _ = this;
2448
2449        if (_.shouldClick === false) {
2450            event.stopImmediatePropagation();
2451            event.stopPropagation();
2452            event.preventDefault();
2453        }
2454
2455    };
2456
2457    Slick.prototype.destroy = function(refresh) {
2458
2459        var _ = this;
2460
2461        _.autoPlayClear();
2462
2463        _.touchObject = {};
2464
2465        _.cleanUpEvents();
2466
2467        $('.slick-cloned', _.$slider).detach();
2468
2469        if (_.$dots) {
2470            _.$dots.remove();
2471        }
2472
2473
2474        if ( _.$prevArrow && _.$prevArrow.length ) {
2475
2476            _.$prevArrow
2477                .removeClass('slick-disabled slick-arrow slick-hidden')
2478                .removeAttr('aria-hidden aria-disabled tabindex')
2479                .css('display','');
2480
2481            if ( _.htmlExpr.test( _.options.prevArrow )) {
2482                _.$prevArrow.remove();
2483            }
2484        }
2485
2486        if ( _.$nextArrow && _.$nextArrow.length ) {
2487
2488            _.$nextArrow
2489                .removeClass('slick-disabled slick-arrow slick-hidden')
2490                .removeAttr('aria-hidden aria-disabled tabindex')
2491                .css('display','');
2492
2493            if ( _.htmlExpr.test( _.options.nextArrow )) {
2494                _.$nextArrow.remove();
2495            }
2496
2497        }
2498
2499
2500        if (_.$slides) {
2501
2502            _.$slides
2503                .removeClass('slick-slide slick-active slick-center slick-visible slick-current')
2504                .removeAttr('aria-hidden')
2505                .removeAttr('data-slick-index')
2506                .each(function(){
2507                    $(this).attr('style', $(this).data('originalStyling'));
2508                });
2509
2510            _.$slideTrack.children(this.options.slide).detach();
2511
2512            _.$slideTrack.detach();
2513
2514            _.$list.detach();
2515
2516            _.$slider.append(_.$slides);
2517        }
2518
2519        _.cleanUpRows();
2520
2521        _.$slider.removeClass('slick-slider');
2522        _.$slider.removeClass('slick-initialized');
2523        _.$slider.removeClass('slick-dotted');
2524
2525        _.unslicked = true;
2526
2527        if(!refresh) {
2528            _.$slider.trigger('destroy', [_]);
2529        }
2530
2531    };
2532
2533    Slick.prototype.disableTransition = function(slide) {
2534
2535        var _ = this,
2536            transition = {};
2537
2538        transition[_.transitionType] = '';
2539
2540        if (_.options.fade === false) {
2541            _.$slideTrack.css(transition);
2542        } else {
2543            _.$slides.eq(slide).css(transition);
2544        }
2545
2546    };
2547
2548    Slick.prototype.fadeSlide = function(slideIndex, callback) {
2549
2550        var _ = this;
2551
2552        if (_.cssTransitions === false) {
2553
2554            _.$slides.eq(slideIndex).css({
2555                zIndex: _.options.zIndex
2556            });
2557
2558            _.$slides.eq(slideIndex).animate({
2559                opacity: 1
2560            }, _.options.speed, _.options.easing, callback);
2561
2562        } else {
2563
2564            _.applyTransition(slideIndex);
2565
2566            _.$slides.eq(slideIndex).css({
2567                opacity: 1,
2568                zIndex: _.options.zIndex
2569            });
2570
2571            if (callback) {
2572                setTimeout(function() {
2573
2574                    _.disableTransition(slideIndex);
2575
2576                    callback.call();
2577                }, _.options.speed);
2578            }
2579
2580        }
2581
2582    };
2583
2584    Slick.prototype.fadeSlideOut = function(slideIndex) {
2585
2586        var _ = this;
2587
2588        if (_.cssTransitions === false) {
2589
2590            _.$slides.eq(slideIndex).animate({
2591                opacity: 0,
2592                zIndex: _.options.zIndex - 2
2593            }, _.options.speed, _.options.easing);
2594
2595        } else {
2596
2597            _.applyTransition(slideIndex);
2598
2599            _.$slides.eq(slideIndex).css({
2600                opacity: 0,
2601                zIndex: _.options.zIndex - 2
2602            });
2603
2604        }
2605
2606    };
2607
2608    Slick.prototype.filterSlides = Slick.prototype.slickFilter = function(filter) {
2609
2610        var _ = this;
2611
2612        if (filter !== null) {
2613
2614            _.$slidesCache = _.$slides;
2615
2616            _.unload();
2617
2618            _.$slideTrack.children(this.options.slide).detach();
2619
2620            _.$slidesCache.filter(filter).appendTo(_.$slideTrack);
2621
2622            _.reinit();
2623
2624        }
2625
2626    };
2627
2628    Slick.prototype.focusHandler = function() {
2629
2630        var _ = this;
2631
2632        _.$slider
2633            .off('focus.slick blur.slick')
2634            .on('focus.slick blur.slick',
2635                '*:not(.slick-arrow)', function(event) {
2636
2637            event.stopImmediatePropagation();
2638            var $sf = $(this);
2639
2640            setTimeout(function() {
2641
2642                if( _.options.pauseOnFocus ) {
2643                    _.focussed = $sf.is(':focus');
2644                    _.autoPlay();
2645                }
2646
2647            }, 0);
2648
2649        });
2650    };
2651
2652    Slick.prototype.getCurrent = Slick.prototype.slickCurrentSlide = function() {
2653
2654        var _ = this;
2655        return _.currentSlide;
2656
2657    };
2658
2659    Slick.prototype.getDotCount = function() {
2660
2661        var _ = this;
2662
2663        var breakPoint = 0;
2664        var counter = 0;
2665        var pagerQty = 0;
2666
2667        if (_.options.infinite === true) {
2668            while (breakPoint < _.slideCount) {
2669                ++pagerQty;
2670                breakPoint = counter + _.options.slidesToScroll;
2671                counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow;
2672            }
2673        } else if (_.options.centerMode === true) {
2674            pagerQty = _.slideCount;
2675        } else if(!_.options.asNavFor) {
2676            pagerQty = 1 + Math.ceil((_.slideCount - _.options.slidesToShow) / _.options.slidesToScroll);
2677        }else {
2678            while (breakPoint < _.slideCount) {
2679                ++pagerQty;
2680                breakPoint = counter + _.options.slidesToScroll;
2681                counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow;
2682            }
2683        }
2684
2685        return pagerQty - 1;
2686
2687    };
2688
2689    Slick.prototype.getLeft = function(slideIndex) {
2690
2691        var _ = this,
2692            targetLeft,
2693            verticalHeight,
2694            verticalOffset = 0,
2695            targetSlide;
2696
2697        _.slideOffset = 0;
2698        verticalHeight = _.$slides.first().outerHeight(true);
2699
2700        if (_.options.infinite === true) {
2701            if (_.slideCount > _.options.slidesToShow) {
2702                _.slideOffset = (_.slideWidth * _.options.slidesToShow) * -1;
2703                verticalOffset = (verticalHeight * _.options.slidesToShow) * -1;
2704            }
2705            if (_.slideCount % _.options.slidesToScroll !== 0) {
2706                if (slideIndex + _.options.slidesToScroll > _.slideCount && _.slideCount > _.options.slidesToShow) {
2707                    if (slideIndex > _.slideCount) {
2708                        _.slideOffset = ((_.options.slidesToShow - (slideIndex - _.slideCount)) * _.slideWidth) * -1;
2709                        verticalOffset = ((_.options.slidesToShow - (slideIndex - _.slideCount)) * verticalHeight) * -1;
2710                    } else {
2711                        _.slideOffset = ((_.slideCount % _.options.slidesToScroll) * _.slideWidth) * -1;
2712                        verticalOffset = ((_.slideCount % _.options.slidesToScroll) * verticalHeight) * -1;
2713                    }
2714                }
2715            }
2716        } else {
2717            if (slideIndex + _.options.slidesToShow > _.slideCount) {
2718                _.slideOffset = ((slideIndex + _.options.slidesToShow) - _.slideCount) * _.slideWidth;
2719                verticalOffset = ((slideIndex + _.options.slidesToShow) - _.slideCount) * verticalHeight;
2720            }
2721        }
2722
2723        if (_.slideCount <= _.options.slidesToShow) {
2724            _.slideOffset = 0;
2725            verticalOffset = 0;
2726        }
2727
2728       
vendor: 5,167 bytes, lines 2728-2901
2728 if (_.options.centerMode === true && _.options.infinite === true) {
2729            _.slideOffset += _.slideWidth * Math.floor(_.options.slidesToShow / 2) - _.slideWidth;
2730        } else if (_.options.centerMode === true) {
2731            _.slideOffset = 0;
2732            _.slideOffset += _.slideWidth * Math.floor(_.options.slidesToShow / 2);
2733        }
2734
2735        if (_.options.vertical === false) {
2736            targetLeft = ((slideIndex * _.slideWidth) * -1) + _.slideOffset;
2737        } else {
2738            targetLeft = ((slideIndex * verticalHeight) * -1) + verticalOffset;
2739        }
2740
2741        if (_.options.variableWidth === true) {
2742
2743            if (_.slideCount <= _.options.slidesToShow || _.options.infinite === false) {
2744                targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex);
2745            } else {
2746                targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex + _.options.slidesToShow);
2747            }
2748
2749            if (_.options.rtl === true) {
2750                if (targetSlide[0]) {
2751                    targetLeft = (_.$slideTrack.width() - targetSlide[0].offsetLeft - targetSlide.width()) * -1;
2752                } else {
2753                    targetLeft =  0;
2754                }
2755            } else {
2756                targetLeft = targetSlide[0] ? targetSlide[0].offsetLeft * -1 : 0;
2757            }
2758
2759            if (_.options.centerMode === true) {
2760                if (_.slideCount <= _.options.slidesToShow || _.options.infinite === false) {
2761                    targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex);
2762                } else {
2763                    targetSlide = _.$slideTrack.children('.slick-slide').eq(slideIndex + _.options.slidesToShow + 1);
2764                }
2765
2766                if (_.options.rtl === true) {
2767                    if (targetSlide[0]) {
2768                        targetLeft = (_.$slideTrack.width() - targetSlide[0].offsetLeft - targetSlide.width()) * -1;
2769                    } else {
2770                        targetLeft =  0;
2771                    }
2772                } else {
2773                    targetLeft = targetSlide[0] ? targetSlide[0].offsetLeft * -1 : 0;
2774                }
2775
2776                targetLeft += (_.$list.width() - targetSlide.outerWidth()) / 2;
2777            }
2778        }
2779
2780        return targetLeft;
2781
2782    };
2783
2784    Slick.prototype.getOption = Slick.prototype.slickGetOption = function(option) {
2785
2786        var _ = this;
2787
2788        return _.options[option];
2789
2790    };
2791
2792    Slick.prototype.getNavigableIndexes = function() {
2793
2794        var _ = this,
2795            breakPoint = 0,
2796            counter = 0,
2797            indexes = [],
2798            max;
2799
2800        if (_.options.infinite === false) {
2801            max = _.slideCount;
2802        } else {
2803            breakPoint = _.options.slidesToScroll * -1;
2804            counter = _.options.slidesToScroll * -1;
2805            max = _.slideCount * 2;
2806        }
2807
2808        while (breakPoint < max) {
2809            indexes.push(breakPoint);
2810            breakPoint = counter + _.options.slidesToScroll;
2811            counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow;
2812        }
2813
2814        return indexes;
2815
2816    };
2817
2818    Slick.prototype.getSlick = function() {
2819
2820        return this;
2821
2822    };
2823
2824    Slick.prototype.getSlideCount = function() {
2825
2826        var _ = this,
2827            slidesTraversed, swipedSlide, centerOffset;
2828
2829        centerOffset = _.options.centerMode === true ? _.slideWidth * Math.floor(_.options.slidesToShow / 2) : 0;
2830
2831        if (_.options.swipeToSlide === true) {
2832            _.$slideTrack.find('.slick-slide').each(function(index, slide) {
2833                if (slide.offsetLeft - centerOffset + ($(slide).outerWidth() / 2) > (_.swipeLeft * -1)) {
2834                    swipedSlide = slide;
2835                    return false;
2836                }
2837            });
2838
2839            slidesTraversed = Math.abs($(swipedSlide).attr('data-slick-index') - _.currentSlide) || 1;
2840
2841            return slidesTraversed;
2842
2843        } else {
2844            return _.options.slidesToScroll;
2845        }
2846
2847    };
2848
2849    Slick.prototype.goTo = Slick.prototype.slickGoTo = function(slide, dontAnimate) {
2850
2851        var _ = this;
2852
2853        _.changeSlide({
2854            data: {
2855                message: 'index',
2856                index: parseInt(slide)
2857            }
2858        }, dontAnimate);
2859
2860    };
2861
2862    Slick.prototype.init = function(creation) {
2863
2864        var _ = this;
2865
2866        if (!$(_.$slider).hasClass('slick-initialized')) {
2867
2868            $(_.$slider).addClass('slick-initialized');
2869
2870            _.buildRows();
2871            _.buildOut();
2872            _.setProps();
2873            _.startLoad();
2874            _.loadSlider();
2875            _.initializeEvents();
2876            _.updateArrows();
2877            _.updateDots();
2878            _.checkResponsive(true);
2879            _.focusHandler();
2880
2881        }
2882
2883        if (creation) {
2884            _.$slider.trigger('init', [_]);
2885        }
2886
2887        if (_.options.accessibility === true) {
2888            _.initADA();
2889        }
2890
2891        if ( _.options.autoplay ) {
2892
2893            _.paused = false;
2894            _.autoPlay();
2895
2896        }
2897
2898    };
2899
2900    Slick.prototype.initADA = function() {
2901        var _ = this
2901;
2902        _.$slides.add(_.$slideTrack.find('.slick-cloned')).attr({
2903            'aria-hidden': 'true',
2904            'tabindex': '-1'
2905        }).find('a, input, button, select').attr({
2906            'tabindex': '-1'
2907        });
2908
2909        _.$slideTrack.attr('role', 'listbox');
2910
2911        _.$slides.not(_.$slideTrack.find('.slick-cloned')).each(function(i) {
2912            $(this).attr({
2913                'role': 'option',
2914                'aria-describedby': 'slick-slide' + _.instanceUid + i + ''
2915            });
2916        });
2917
2918        if (_.$dots !== null) {
2919            _.$dots.attr('role', 'tablist').find('li').each(function(i) {
2920                $(this).attr({
2921                    'role': 'presentation',
2922                    'aria-selected': 'false',
2923                    'aria-controls': 'navigation' + _.instanceUid + i + '',
2924                    'id': 'slick-slide' + _.instanceUid + i + ''
2925                });
2926            })
2927                .first().attr('aria-selected', 'true').end()
2928                .find('button').attr('role', 'button').end()
2929                .closest('div').attr('role', 'toolbar');
2930        }
2931        _.activateADA();
2932
2933    };
2934
2935    Slick.prototype.initArrowEvents = function() {
2936
2937        var _ = this;
2938
2939        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
2940            _.$prevArrow
2941               .off('click.slick')
2942               .on('click.slick', {
2943                    message: 'previous'
2944               }, _.changeSlide);
2945            _.$nextArrow
2946               .off('click.slick')
2947               .on('click.slick', {
2948                    message: 'next'
2949               }, _.changeSlide);
2950        }
2951
2952    };
2953
2954    Slick.prototype.initDotEvents = function() {
2955
2956        var _ = this;
2957
2958        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
2959            $('li', _.$dots).on('click.slick', {
2960                message: 'index'
2961            }, _.changeSlide);
2962        }
2963
2964        if ( _.options.dots === true && _.options.pauseOnDotsHover === true ) {
2965
2966            $('li', _.$dots)
2967                .on('mouseenter.slick', $.proxy(_.interrupt, _, true))
2968                .on('mouseleave.slick', $.proxy(_.interrupt, _, false));
2969
2970        }
2971
2972    };
2973
2974    Slick.prototype.initSlideEvents = function() {
2975
2976        var _ = this;
2977
2978        if ( _.options.pauseOnHover ) {
2979
2980            _.$list.on('mouseenter.slick', $.proxy(_.interrupt, _, true));
2981            _.$list.on('mouseleave.slick', $.proxy(_.interrupt, _, false));
2982
2983        }
2984
2985    };
2986
2987    Slick.prototype.initializeEvents = function() {
2988
2989        var _ = this;
2990
2991        _.initArrowEvents();
2992
2993        _.initDotEvents();
2994        _.initSlideEvents();
2995
2996        _.$list.on('touchstart.slick mousedown.slick', {
2997            action: 'start'
2998        }, _.swipeHandler);
2999        _.$list.on('touchmove.slick mousemove.slick', {
3000            action: 'move'
3001        }, _.swipeHandler);
3002        _.$list.on('touchend.slick mouseup.slick', {
3003            action: 'end'
3004        }, _.swipeHandler);
vendor: 10,240 bytes, lines 3005-3382
3005        _.$list.on('touchcancel.slick mouseleave.slick', {
3006            action: 'end'
3007        }, _.swipeHandler);
3008
3009        _.$list.on('click.slick', _.clickHandler);
3010
3011        $(document).on(_.visibilityChange, $.proxy(_.visibility, _));
3012
3013        if (_.options.accessibility === true) {
3014            _.$list.on('keydown.slick', _.keyHandler);
3015        }
3016
3017        if (_.options.focusOnSelect === true) {
3018            $(_.$slideTrack).children().on('click.slick', _.selectHandler);
3019        }
3020
3021        $(window).on('orientationchange.slick.slick-' + _.instanceUid, $.proxy(_.orientationChange, _));
3022
3023        $(window).on('resize.slick.slick-' + _.instanceUid, $.proxy(_.resize, _));
3024
3025        $('[draggable!=true]', _.$slideTrack).on('dragstart', _.preventDefault);
3026
3027        $(window).on('load.slick.slick-' + _.instanceUid, _.setPosition);
3028        $(document).on('ready.slick.slick-' + _.instanceUid, _.setPosition);
3029
3030    };
3031
3032    Slick.prototype.initUI = function() {
3033
3034        var _ = this;
3035
3036        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
3037
3038            _.$prevArrow.show();
3039            _.$nextArrow.show();
3040
3041        }
3042
3043        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
3044
3045            _.$dots.show();
3046
3047        }
3048
3049    };
3050
3051    Slick.prototype.keyHandler = function(event) {
3052
3053        var _ = this;
3054         //Dont slide if the cursor is inside the form fields and arrow keys are pressed
3055        if(!event.target.tagName.match('TEXTAREA|INPUT|SELECT')) {
3056            if (event.keyCode === 37 && _.options.accessibility === true) {
3057                _.changeSlide({
3058                    data: {
3059                        message: _.options.rtl === true ? 'next' :  'previous'
3060                    }
3061                });
3062            } else if (event.keyCode === 39 && _.options.accessibility === true) {
3063                _.changeSlide({
3064                    data: {
3065                        message: _.options.rtl === true ? 'previous' : 'next'
3066                    }
3067                });
3068            }
3069        }
3070
3071    };
3072
3073    Slick.prototype.lazyLoad = function() {
3074
3075        var _ = this,
3076            loadRange, cloneRange, rangeStart, rangeEnd;
3077
3078        function loadImages(imagesScope) {
3079
3080            $('img[data-lazy]', imagesScope).each(function() {
3081
3082                var image = $(this),
3083                    imageSource = $(this).attr('data-lazy'),
3084                    imageToLoad = document.createElement('img');
3085
3086                imageToLoad.onload = function() {
3087
3088                    image
3089                        .animate({ opacity: 0 }, 100, function() {
3090                            image
3091                                .attr('src', imageSource)
3092                                .animate({ opacity: 1 }, 200, function() {
3093                                    image
3094                                        .removeAttr('data-lazy')
3095                                        .removeClass('slick-loading');
3096                                });
3097                            _.$slider.trigger('lazyLoaded', [_, image, imageSource]);
3098                        });
3099
3100                };
3101
3102                imageToLoad.onerror = function() {
3103
3104                    image
3105                        .removeAttr( 'data-lazy' )
3106                        .removeClass( 'slick-loading' )
3107                        .addClass( 'slick-lazyload-error' );
3108
3109                    _.$slider.trigger('lazyLoadError', [ _, image, imageSource ]);
3110
3111                };
3112
3113                imageToLoad.src = imageSource;
3114
3115            });
3116
3117        }
3118
3119        if (_.options.centerMode === true) {
3120            if (_.options.infinite === true) {
3121                rangeStart = _.currentSlide + (_.options.slidesToShow / 2 + 1);
3122                rangeEnd = rangeStart + _.options.slidesToShow + 2;
3123            } else {
3124                rangeStart = Math.max(0, _.currentSlide - (_.options.slidesToShow / 2 + 1));
3125                rangeEnd = 2 + (_.options.slidesToShow / 2 + 1) + _.currentSlide;
3126            }
3127        } else {
3128            rangeStart = _.options.infinite ? _.options.slidesToShow + _.currentSlide : _.currentSlide;
3129            rangeEnd = Math.ceil(rangeStart + _.options.slidesToShow);
3130            if (_.options.fade === true) {
3131                if (rangeStart > 0) rangeStart--;
3132                if (rangeEnd <= _.slideCount) rangeEnd++;
3133            }
3134        }
3135
3136        loadRange = _.$slider.find('.slick-slide').slice(rangeStart, rangeEnd);
3137        loadImages(loadRange);
3138
3139        if (_.slideCount <= _.options.slidesToShow) {
3140            cloneRange = _.$slider.find('.slick-slide');
3141            loadImages(cloneRange);
3142        } else
3143        if (_.currentSlide >= _.slideCount - _.options.slidesToShow) {
3144            cloneRange = _.$slider.find('.slick-cloned').slice(0, _.options.slidesToShow);
3145            loadImages(cloneRange);
3146        } else if (_.currentSlide === 0) {
3147            cloneRange = _.$slider.find('.slick-cloned').slice(_.options.slidesToShow * -1);
3148            loadImages(cloneRange);
3149        }
3150
3151    };
3152
3153    Slick.prototype.loadSlider = function() {
3154
3155        var _ = this;
3156
3157        _.setPosition();
3158
3159        _.$slideTrack.css({
3160            opacity: 1
3161        });
3162
3163        _.$slider.removeClass('slick-loading');
3164
3165        _.initUI();
3166
3167        if (_.options.lazyLoad === 'progressive') {
3168            _.progressiveLazyLoad();
3169        }
3170
3171    };
3172
3173    Slick.prototype.next = Slick.prototype.slickNext = function() {
3174
3175        var _ = this;
3176
3177        _.changeSlide({
3178            data: {
3179                message: 'next'
3180            }
3181        });
3182
3183    };
3184
3185    Slick.prototype.orientationChange = function() {
3186
3187        var _ = this;
3188
3189        _.checkResponsive();
3190        _.setPosition();
3191
3192    };
3193
3194    Slick.prototype.pause = Slick.prototype.slickPause = function() {
3195
3196        var _ = this;
3197
3198        _.autoPlayClear();
3199        _.paused = true;
3200
3201    };
3202
3203    Slick.prototype.play = Slick.prototype.slickPlay = function() {
3204
3205        var _ = this;
3206
3207        _.autoPlay();
3208        _.options.autoplay = true;
3209        _.paused = false;
3210        _.focussed = false;
3211        _.interrupted = false;
3212
3213    };
3214
3215    Slick.prototype.postSlide = function(index) {
3216
3217        var _ = this;
3218
3219        if( !_.unslicked ) {
3220
3221            _.$slider.trigger('afterChange', [_, index]);
3222
3223            _.animating = false;
3224
3225            _.setPosition();
3226
3227            _.swipeLeft = null;
3228
3229            if ( _.options.autoplay ) {
3230                _.autoPlay();
3231            }
3232
3233            if (_.options.accessibility === true) {
3234                _.initADA();
3235            }
3236
3237        }
3238
3239    };
3240
3241    Slick.prototype.prev = Slick.prototype.slickPrev = function() {
3242
3243        var _ = this;
3244
3245        _.changeSlide({
3246            data: {
3247                message: 'previous'
3248            }
3249        });
3250
3251    };
3252
3253    Slick.prototype.preventDefault = function(event) {
3254
3255        event.preventDefault();
3256
3257    };
3258
3259    Slick.prototype.progressiveLazyLoad = function( tryCount ) {
3260
3261        tryCount = tryCount || 1;
3262
3263        var _ = this,
3264            $imgsToLoad = $( 'img[data-lazy]', _.$slider ),
3265            image,
3266            imageSource,
3267            imageToLoad;
3268
3269        if ( $imgsToLoad.length ) {
3270
3271            image = $imgsToLoad.first();
3272            imageSource = image.attr('data-lazy');
3273            imageToLoad = document.createElement('img');
3274
3275            imageToLoad.onload = function() {
3276
3277                image
3278                    .attr( 'src', imageSource )
3279                    .removeAttr('data-lazy')
3280                    .removeClass('slick-loading');
3281
3282                if ( _.options.adaptiveHeight === true ) {
3283                    _.setPosition();
3284                }
3285
3286                _.$slider.trigger('lazyLoaded', [ _, image, imageSource ]);
3287                _.progressiveLazyLoad();
3288
3289            };
3290
3291            imageToLoad.onerror = function() {
3292
3293                if ( tryCount < 3 ) {
3294
3295                    /**
3296                     * try to load the image 3 times,
3297                     * leave a slight delay so we don't get
3298                     * servers blocking the request.
3299                     */
3300                    setTimeout( function() {
3301                        _.progressiveLazyLoad( tryCount + 1 );
3302                    }, 500 );
3303
3304                } else {
3305
3306                    image
3307                        .removeAttr( 'data-lazy' )
3308                        .removeClass( 'slick-loading' )
3309                        .addClass( 'slick-lazyload-error' );
3310
3311                    _.$slider.trigger('lazyLoadError', [ _, image, imageSource ]);
3312
3313                    _.progressiveLazyLoad();
3314
3315                }
3316
3317            };
3318
3319            imageToLoad.src = imageSource;
3320
3321        } else {
3322
3323            _.$slider.trigger('allImagesLoaded', [ _ ]);
3324
3325        }
3326
3327    };
3328
3329    Slick.prototype.refresh = function( initializing ) {
3330
3331        var _ = this, currentSlide, lastVisibleIndex;
3332
3333        lastVisibleIndex = _.slideCount - _.options.slidesToShow;
3334
3335        // in non-infinite sliders, we don't want to go past the
3336        // last visible index.
3337        if( !_.options.infinite && ( _.currentSlide > lastVisibleIndex )) {
3338            _.currentSlide = lastVisibleIndex;
3339        }
3340
3341        // if less slides than to show, go to start.
3342        if ( _.slideCount <= _.options.slidesToShow ) {
3343            _.currentSlide = 0;
3344
3345        }
3346
3347        currentSlide = _.currentSlide;
3348
3349        _.destroy(true);
3350
3351        $.extend(_, _.initials, { currentSlide: currentSlide });
3352
3353        _.init();
3354
3355        if( !initializing ) {
3356
3357            _.changeSlide({
3358                data: {
3359                    message: 'index',
3360                    index: currentSlide
3361                }
3362            }, false);
3363
3364        }
3365
3366    };
3367
3368    Slick.prototype.registerBreakpoints = function() {
3369
3370        var _ = this, breakpoint, currentBreakpoint, l,
3371            responsiveSettings = _.options.responsive || null;
3372
3373        if ( $.type(responsiveSettings) === 'array' && responsiveSettings.length ) {
3374
3375            _.respondTo = _.options.respondTo || 'window';
3376
3377            for ( breakpoint in responsiveSettings ) {
3378
3379                l = _.breakpoints.length-1;
3380                currentBreakpoint = responsiveSettings[breakpoint].breakpoint;
3381
3382                if (responsiveSettings.hasOwnProperty(breakpoint)) {
vendor: 12,466 bytes, lines 3382-3815
3382
3383
3384                    // loop through the breakpoints and cut out any existing
3385                    // ones with the same breakpoint number, we don't want dupes.
3386                    while( l >= 0 ) {
3387                        if( _.breakpoints[l] && _.breakpoints[l] === currentBreakpoint ) {
3388                            _.breakpoints.splice(l,1);
3389                        }
3390                        l--;
3391                    }
3392
3393                    _.breakpoints.push(currentBreakpoint);
3394                    _.breakpointSettings[currentBreakpoint] = responsiveSettings[breakpoint].settings;
3395
3396                }
3397
3398            }
3399
3400            _.breakpoints.sort(function(a, b) {
3401                return ( _.options.mobileFirst ) ? a-b : b-a;
3402            });
3403
3404        }
3405
3406    };
3407
3408    Slick.prototype.reinit = function() {
3409
3410        var _ = this;
3411
3412        _.$slides =
3413            _.$slideTrack
3414                .children(_.options.slide)
3415                .addClass('slick-slide');
3416
3417        _.slideCount = _.$slides.length;
3418
3419        if (_.currentSlide >= _.slideCount && _.currentSlide !== 0) {
3420            _.currentSlide = _.currentSlide - _.options.slidesToScroll;
3421        }
3422
3423        if (_.slideCount <= _.options.slidesToShow) {
3424            _.currentSlide = 0;
3425        }
3426
3427        _.registerBreakpoints();
3428
3429        _.setProps();
3430        _.setupInfinite();
3431        _.buildArrows();
3432        _.updateArrows();
3433        _.initArrowEvents();
3434        _.buildDots();
3435        _.updateDots();
3436        _.initDotEvents();
3437        _.cleanUpSlideEvents();
3438        _.initSlideEvents();
3439
3440        _.checkResponsive(false, true);
3441
3442        if (_.options.focusOnSelect === true) {
3443            $(_.$slideTrack).children().on('click.slick', _.selectHandler);
3444        }
3445
3446        _.setSlideClasses(typeof _.currentSlide === 'number' ? _.currentSlide : 0);
3447
3448        _.setPosition();
3449        _.focusHandler();
3450
3451        _.paused = !_.options.autoplay;
3452        _.autoPlay();
3453
3454        _.$slider.trigger('reInit', [_]);
3455
3456    };
3457
3458    Slick.prototype.resize = function() {
3459
3460        var _ = this;
3461
3462        if ($(window).width() !== _.windowWidth) {
3463            clearTimeout(_.windowDelay);
3464            _.windowDelay = window.setTimeout(function() {
3465                _.windowWidth = $(window).width();
3466                _.checkResponsive();
3467                if( !_.unslicked ) { _.setPosition(); }
3468            }, 50);
3469        }
3470    };
3471
3472    Slick.prototype.removeSlide = Slick.prototype.slickRemove = function(index, removeBefore, removeAll) {
3473
3474        var _ = this;
3475
3476        if (typeof(index) === 'boolean') {
3477            removeBefore = index;
3478            index = removeBefore === true ? 0 : _.slideCount - 1;
3479        } else {
3480            index = removeBefore === true ? --index : index;
3481        }
3482
3483        if (_.slideCount < 1 || index < 0 || index > _.slideCount - 1) {
3484            return false;
3485        }
3486
3487        _.unload();
3488
3489        if (removeAll === true) {
3490            _.$slideTrack.children().remove();
3491        } else {
3492            _.$slideTrack.children(this.options.slide).eq(index).remove();
3493        }
3494
3495        _.$slides = _.$slideTrack.children(this.options.slide);
3496
3497        _.$slideTrack.children(this.options.slide).detach();
3498
3499        _.$slideTrack.append(_.$slides);
3500
3501        _.$slidesCache = _.$slides;
3502
3503        _.reinit();
3504
3505    };
3506
3507    Slick.prototype.setCSS = function(position) {
3508
3509        var _ = this,
3510            positionProps = {},
3511            x, y;
3512
3513        if (_.options.rtl === true) {
3514            position = -position;
3515        }
3516        x = _.positionProp == 'left' ? Math.ceil(position) + 'px' : '0px';
3517        y = _.positionProp == 'top' ? Math.ceil(position) + 'px' : '0px';
3518
3519        positionProps[_.positionProp] = position;
3520
3521        if (_.transformsEnabled === false) {
3522            _.$slideTrack.css(positionProps);
3523        } else {
3524            positionProps = {};
3525            if (_.cssTransitions === false) {
3526                positionProps[_.animType] = 'translate(' + x + ', ' + y + ')';
3527                _.$slideTrack.css(positionProps);
3528            } else {
3529                positionProps[_.animType] = 'translate3d(' + x + ', ' + y + ', 0px)';
3530                _.$slideTrack.css(positionProps);
3531            }
3532        }
3533
3534    };
3535
3536    Slick.prototype.setDimensions = function() {
3537
3538        var _ = this;
3539
3540        if (_.options.vertical === false) {
3541            if (_.options.centerMode === true) {
3542                _.$list.css({
3543                    padding: ('0px ' + _.options.centerPadding)
3544                });
3545            }
3546        } else {
3547            _.$list.height(_.$slides.first().outerHeight(true) * _.options.slidesToShow);
3548            if (_.options.centerMode === true) {
3549                _.$list.css({
3550                    padding: (_.options.centerPadding + ' 0px')
3551                });
3552            }
3553        }
3554
3555        _.listWidth = _.$list.width();
3556        _.listHeight = _.$list.height();
3557
3558
3559        if (_.options.vertical === false && _.options.variableWidth === false) {
3560            _.slideWidth = Math.ceil(_.listWidth / _.options.slidesToShow);
3561            _.$slideTrack.width(Math.ceil((_.slideWidth * _.$slideTrack.children('.slick-slide').length)));
3562
3563        } else if (_.options.variableWidth === true) {
3564            _.$slideTrack.width(5000 * _.slideCount);
3565        } else {
3566            _.slideWidth = Math.ceil(_.listWidth);
3567            _.$slideTrack.height(Math.ceil((_.$slides.first().outerHeight(true) * _.$slideTrack.children('.slick-slide').length)));
3568        }
3569
3570        var offset = _.$slides.first().outerWidth(true) - _.$slides.first().width();
3571        if (_.options.variableWidth === false) _.$slideTrack.children('.slick-slide').width(_.slideWidth - offset);
3572
3573    };
3574
3575    Slick.prototype.setFade = function() {
3576
3577        var _ = this,
3578            targetLeft;
3579
3580        _.$slides.each(function(index, element) {
3581            targetLeft = (_.slideWidth * index) * -1;
3582            if (_.options.rtl === true) {
3583                $(element).css({
3584                    position: 'relative',
3585                    right: targetLeft,
3586                    top: 0,
3587                    zIndex: _.options.zIndex - 2,
3588                    opacity: 0
3589                });
3590            } else {
3591                $(element).css({
3592                    position: 'relative',
3593                    left: targetLeft,
3594                    top: 0,
3595                    zIndex: _.options.zIndex - 2,
3596                    opacity: 0
3597                });
3598            }
3599        });
3600
3601        _.$slides.eq(_.currentSlide).css({
3602            zIndex: _.options.zIndex - 1,
3603            opacity: 1
3604        });
3605
3606    };
3607
3608    Slick.prototype.setHeight = function() {
3609
3610        var _ = this;
3611
3612        if (_.options.slidesToShow === 1 && _.options.adaptiveHeight === true && _.options.vertical === false) {
3613            var targetHeight = _.$slides.eq(_.currentSlide).outerHeight(true);
3614            _.$list.css('height', targetHeight);
3615        }
3616
3617    };
3618
3619    Slick.prototype.setOption =
3620    Slick.prototype.slickSetOption = function() {
3621
3622        /**
3623         * accepts arguments in format of:
3624         *
3625         *  - for changing a single option's value:
3626         *     .slick("setOption", option, value, refresh )
3627         *
3628         *  - for changing a set of responsive options:
3629         *     .slick("setOption", 'responsive', [{}, ...], refresh )
3630         *
3631         *  - for updating multiple values at once (not responsive)
3632         *     .slick("setOption", { 'option': value, ... }, refresh )
3633         */
3634
3635        var _ = this, l, item, option, value, refresh = false, type;
3636
3637        if( $.type( arguments[0] ) === 'object' ) {
3638
3639            option =  arguments[0];
3640            refresh = arguments[1];
3641            type = 'multiple';
3642
3643        } else if ( $.type( arguments[0] ) === 'string' ) {
3644
3645            option =  arguments[0];
3646            value = arguments[1];
3647            refresh = arguments[2];
3648
3649            if ( arguments[0] === 'responsive' && $.type( arguments[1] ) === 'array' ) {
3650
3651                type = 'responsive';
3652
3653            } else if ( typeof arguments[1] !== 'undefined' ) {
3654
3655                type = 'single';
3656
3657            }
3658
3659        }
3660
3661        if ( type === 'single' ) {
3662
3663            _.options[option] = value;
3664
3665
3666        } else if ( type === 'multiple' ) {
3667
3668            $.each( option , function( opt, val ) {
3669
3670                _.options[opt] = val;
3671
3672            });
3673
3674
3675        } else if ( type === 'responsive' ) {
3676
3677            for ( item in value ) {
3678
3679                if( $.type( _.options.responsive ) !== 'array' ) {
3680
3681                    _.options.responsive = [ value[item] ];
3682
3683                } else {
3684
3685                    l = _.options.responsive.length-1;
3686
3687                    // loop through the responsive object and splice out duplicates.
3688                    while( l >= 0 ) {
3689
3690                        if( _.options.responsive[l].breakpoint === value[item].breakpoint ) {
3691
3692                            _.options.responsive.splice(l,1);
3693
3694                        }
3695
3696                        l--;
3697
3698                    }
3699
3700                    _.options.responsive.push( value[item] );
3701
3702                }
3703
3704            }
3705
3706        }
3707
3708        if ( refresh ) {
3709
3710            _.unload();
3711            _.reinit();
3712
3713        }
3714
3715    };
3716
3717    Slick.prototype.setPosition = function() {
3718
3719        var _ = this;
3720
3721        _.setDimensions();
3722
3723        _.setHeight();
3724
3725        if (_.options.fade === false) {
3726            _.setCSS(_.getLeft(_.currentSlide));
3727        } else {
3728            _.setFade();
3729        }
3730
3731        _.$slider.trigger('setPosition', [_]);
3732
3733    };
3734
3735    Slick.prototype.setProps = function() {
3736
3737        var _ = this,
3738            bodyStyle = document.body.style;
3739
3740        _.positionProp = _.options.vertical === true ? 'top' : 'left';
3741
3742        if (_.positionProp === 'top') {
3743            _.$slider.addClass('slick-vertical');
3744        } else {
3745            _.$slider.removeClass('slick-vertical');
3746        }
3747
3748        if (bodyStyle.WebkitTransition !== undefined ||
3749            bodyStyle.MozTransition !== undefined ||
3750            bodyStyle.msTransition !== undefined) {
3751            if (_.options.useCSS === true) {
3752                _.cssTransitions = true;
3753            }
3754        }
3755
3756        if ( _.options.fade ) {
3757            if ( typeof _.options.zIndex === 'number' ) {
3758                if( _.options.zIndex < 3 ) {
3759                    _.options.zIndex = 3;
3760                }
3761            } else {
3762                _.options.zIndex = _.defaults.zIndex;
3763            }
3764        }
3765
3766        if (bodyStyle.OTransform !== undefined) {
3767            _.animType = 'OTransform';
3768            _.transformType = '-o-transform';
3769            _.transitionType = 'OTransition';
3770            if (bodyStyle.perspectiveProperty === undefined && bodyStyle.webkitPerspective === undefined) _.animType = false;
3771        }
3772        if (bodyStyle.MozTransform !== undefined) {
3773            _.animType = 'MozTransform';
3774            _.transformType = '-moz-transform';
3775            _.transitionType = 'MozTransition';
3776            if (bodyStyle.perspectiveProperty === undefined && bodyStyle.MozPerspective === undefined) _.animType = false;
3777        }
3778        if (bodyStyle.webkitTransform !== undefined) {
3779            _.animType = 'webkitTransform';
3780            _.transformType = '-webkit-transform';
3781            _.transitionType = 'webkitTransition';
3782            if (bodyStyle.perspectiveProperty === undefined && bodyStyle.webkitPerspective === undefined) _.animType = false;
3783        }
3784        if (bodyStyle.msTransform !== undefined) {
3785            _.animType = 'msTransform';
3786            _.transformType = '-ms-transform';
3787            _.transitionType = 'msTransition';
3788            if (bodyStyle.msTransform === undefined) _.animType = false;
3789        }
3790        if (bodyStyle.transform !== undefined && _.animType !== false) {
3791            _.animType = 'transform';
3792            _.transformType = 'transform';
3793            _.transitionType = 'transition';
3794        }
3795        _.transformsEnabled = _.options.useTransform && (_.animType !== null && _.animType !== false);
3796    };
3797
3798
3799    Slick.prototype.setSlideClasses = function(index) {
3800
3801        var _ = this,
3802            centerOffset, allSlides, indexOffset, remainder;
3803
3804        allSlides = _.$slider
3805            .find('.slick-slide')
3806            .removeClass('slick-active slick-center slick-current')
3807            .attr('aria-hidden', 'true');
3808
3809        _.$slides
3810            .eq(index)
3811            .addClass('slick-current');
3812
3813        if (_.options.centerMode === true) {
3814
3815            
vendor: 17,874 bytes, lines 3815-4441
3815centerOffset = Math.floor(_.options.slidesToShow / 2);
3816
3817            if (_.options.infinite === true) {
3818
3819                if (index >= centerOffset && index <= (_.slideCount - 1) - centerOffset) {
3820
3821                    _.$slides
3822                        .slice(index - centerOffset, index + centerOffset + 1)
3823                        .addClass('slick-active')
3824                        .attr('aria-hidden', 'false');
3825
3826                } else {
3827
3828                    indexOffset = _.options.slidesToShow + index;
3829                    allSlides
3830                        .slice(indexOffset - centerOffset + 1, indexOffset + centerOffset + 2)
3831                        .addClass('slick-active')
3832                        .attr('aria-hidden', 'false');
3833
3834                }
3835
3836                if (index === 0) {
3837
3838                    allSlides
3839                        .eq(allSlides.length - 1 - _.options.slidesToShow)
3840                        .addClass('slick-center');
3841
3842                } else if (index === _.slideCount - 1) {
3843
3844                    allSlides
3845                        .eq(_.options.slidesToShow)
3846                        .addClass('slick-center');
3847
3848                }
3849
3850            }
3851
3852            _.$slides
3853                .eq(index)
3854                .addClass('slick-center');
3855
3856        } else {
3857
3858            if (index >= 0 && index <= (_.slideCount - _.options.slidesToShow)) {
3859
3860                _.$slides
3861                    .slice(index, index + _.options.slidesToShow)
3862                    .addClass('slick-active')
3863                    .attr('aria-hidden', 'false');
3864
3865            } else if (allSlides.length <= _.options.slidesToShow) {
3866
3867                allSlides
3868                    .addClass('slick-active')
3869                    .attr('aria-hidden', 'false');
3870
3871            } else {
3872
3873                remainder = _.slideCount % _.options.slidesToShow;
3874                indexOffset = _.options.infinite === true ? _.options.slidesToShow + index : index;
3875
3876                if (_.options.slidesToShow == _.options.slidesToScroll && (_.slideCount - index) < _.options.slidesToShow) {
3877
3878                    allSlides
3879                        .slice(indexOffset - (_.options.slidesToShow - remainder), indexOffset + remainder)
3880                        .addClass('slick-active')
3881                        .attr('aria-hidden', 'false');
3882
3883                } else {
3884
3885                    allSlides
3886                        .slice(indexOffset, indexOffset + _.options.slidesToShow)
3887                        .addClass('slick-active')
3888                        .attr('aria-hidden', 'false');
3889
3890                }
3891
3892            }
3893
3894        }
3895
3896        if (_.options.lazyLoad === 'ondemand') {
3897            _.lazyLoad();
3898        }
3899
3900    };
3901
3902    Slick.prototype.setupInfinite = function() {
3903
3904        var _ = this,
3905            i, slideIndex, infiniteCount;
3906
3907        if (_.options.fade === true) {
3908            _.options.centerMode = false;
3909        }
3910
3911        if (_.options.infinite === true && _.options.fade === false) {
3912
3913            slideIndex = null;
3914
3915            if (_.slideCount > _.options.slidesToShow) {
3916
3917                if (_.options.centerMode === true) {
3918                    infiniteCount = _.options.slidesToShow + 1;
3919                } else {
3920                    infiniteCount = _.options.slidesToShow;
3921                }
3922
3923                for (i = _.slideCount; i > (_.slideCount -
3924                        infiniteCount); i -= 1) {
3925                    slideIndex = i - 1;
3926                    $(_.$slides[slideIndex]).clone(true).attr('id', '')
3927                        .attr('data-slick-index', slideIndex - _.slideCount)
3928                        .prependTo(_.$slideTrack).addClass('slick-cloned');
3929                }
3930                for (i = 0; i < infiniteCount; i += 1) {
3931                    slideIndex = i;
3932                    $(_.$slides[slideIndex]).clone(true).attr('id', '')
3933                        .attr('data-slick-index', slideIndex + _.slideCount)
3934                        .appendTo(_.$slideTrack).addClass('slick-cloned');
3935                }
3936                _.$slideTrack.find('.slick-cloned').find('[id]').each(function() {
3937                    $(this).attr('id', '');
3938                });
3939
3940            }
3941
3942        }
3943
3944    };
3945
3946    Slick.prototype.interrupt = function( toggle ) {
3947
3948        var _ = this;
3949
3950        if( !toggle ) {
3951            _.autoPlay();
3952        }
3953        _.interrupted = toggle;
3954
3955    };
3956
3957    Slick.prototype.selectHandler = function(event) {
3958
3959        var _ = this;
3960
3961        var targetElement =
3962            $(event.target).is('.slick-slide') ?
3963                $(event.target) :
3964                $(event.target).parents('.slick-slide');
3965
3966        var index = parseInt(targetElement.attr('data-slick-index'));
3967
3968        if (!index) index = 0;
3969
3970        if (_.slideCount <= _.options.slidesToShow) {
3971
3972            _.setSlideClasses(index);
3973            _.asNavFor(index);
3974            return;
3975
3976        }
3977
3978        _.slideHandler(index);
3979
3980    };
3981
3982    Slick.prototype.slideHandler = function(index, sync, dontAnimate) {
3983
3984        var targetSlide, animSlide, oldSlide, slideLeft, targetLeft = null,
3985            _ = this, navTarget;
3986
3987        sync = sync || false;
3988
3989        if (_.animating === true && _.options.waitForAnimate === true) {
3990            return;
3991        }
3992
3993        if (_.options.fade === true && _.currentSlide === index) {
3994            return;
3995        }
3996
3997        if (_.slideCount <= _.options.slidesToShow) {
3998            return;
3999        }
4000
4001        if (sync === false) {
4002            _.asNavFor(index);
4003        }
4004
4005        targetSlide = index;
4006        targetLeft = _.getLeft(targetSlide);
4007        slideLeft = _.getLeft(_.currentSlide);
4008
4009        _.currentLeft = _.swipeLeft === null ? slideLeft : _.swipeLeft;
4010
4011        if (_.options.infinite === false && _.options.centerMode === false && (index < 0 || index > _.getDotCount() * _.options.slidesToScroll)) {
4012            if (_.options.fade === false) {
4013                targetSlide = _.currentSlide;
4014                if (dontAnimate !== true) {
4015                    _.animateSlide(slideLeft, function() {
4016                        _.postSlide(targetSlide);
4017                    });
4018                } else {
4019                    _.postSlide(targetSlide);
4020                }
4021            }
4022            return;
4023        } else if (_.options.infinite === false && _.options.centerMode === true && (index < 0 || index > (_.slideCount - _.options.slidesToScroll))) {
4024            if (_.options.fade === false) {
4025                targetSlide = _.currentSlide;
4026                if (dontAnimate !== true) {
4027                    _.animateSlide(slideLeft, function() {
4028                        _.postSlide(targetSlide);
4029                    });
4030                } else {
4031                    _.postSlide(targetSlide);
4032                }
4033            }
4034            return;
4035        }
4036
4037        if ( _.options.autoplay ) {
4038            clearInterval(_.autoPlayTimer);
4039        }
4040
4041        if (targetSlide < 0) {
4042            if (_.slideCount % _.options.slidesToScroll !== 0) {
4043                animSlide = _.slideCount - (_.slideCount % _.options.slidesToScroll);
4044            } else {
4045                animSlide = _.slideCount + targetSlide;
4046            }
4047        } else if (targetSlide >= _.slideCount) {
4048            if (_.slideCount % _.options.slidesToScroll !== 0) {
4049                animSlide = 0;
4050            } else {
4051                animSlide = targetSlide - _.slideCount;
4052            }
4053        } else {
4054            animSlide = targetSlide;
4055        }
4056
4057        _.animating = true;
4058
4059        _.$slider.trigger('beforeChange', [_, _.currentSlide, animSlide]);
4060
4061        oldSlide = _.currentSlide;
4062        _.currentSlide = animSlide;
4063
4064        _.setSlideClasses(_.currentSlide);
4065
4066        if ( _.options.asNavFor ) {
4067
4068            navTarget = _.getNavTarget();
4069            navTarget = navTarget.slick('getSlick');
4070
4071            if ( navTarget.slideCount <= navTarget.options.slidesToShow ) {
4072                navTarget.setSlideClasses(_.currentSlide);
4073            }
4074
4075        }
4076
4077        _.updateDots();
4078        _.updateArrows();
4079
4080        if (_.options.fade === true) {
4081            if (dontAnimate !== true) {
4082
4083                _.fadeSlideOut(oldSlide);
4084
4085                _.fadeSlide(animSlide, function() {
4086                    _.postSlide(animSlide);
4087                });
4088
4089            } else {
4090                _.postSlide(animSlide);
4091            }
4092            _.animateHeight();
4093            return;
4094        }
4095
4096        if (dontAnimate !== true) {
4097            _.animateSlide(targetLeft, function() {
4098                _.postSlide(animSlide);
4099            });
4100        } else {
4101            _.postSlide(animSlide);
4102        }
4103
4104    };
4105
4106    Slick.prototype.startLoad = function() {
4107
4108        var _ = this;
4109
4110        if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) {
4111
4112            _.$prevArrow.hide();
4113            _.$nextArrow.hide();
4114
4115        }
4116
4117        if (_.options.dots === true && _.slideCount > _.options.slidesToShow) {
4118
4119            _.$dots.hide();
4120
4121        }
4122
4123        _.$slider.addClass('slick-loading');
4124
4125    };
4126
4127    Slick.prototype.swipeDirection = function() {
4128
4129        var xDist, yDist, r, swipeAngle, _ = this;
4130
4131        xDist = _.touchObject.startX - _.touchObject.curX;
4132        yDist = _.touchObject.startY - _.touchObject.curY;
4133        r = Math.atan2(yDist, xDist);
4134
4135        swipeAngle = Math.round(r * 180 / Math.PI);
4136        if (swipeAngle < 0) {
4137            swipeAngle = 360 - Math.abs(swipeAngle);
4138        }
4139
4140        if ((swipeAngle <= 45) && (swipeAngle >= 0)) {
4141            return (_.options.rtl === false ? 'left' : 'right');
4142        }
4143        if ((swipeAngle <= 360) && (swipeAngle >= 315)) {
4144            return (_.options.rtl === false ? 'left' : 'right');
4145        }
4146        if ((swipeAngle >= 135) && (swipeAngle <= 225)) {
4147            return (_.options.rtl === false ? 'right' : 'left');
4148        }
4149        if (_.options.verticalSwiping === true) {
4150            if ((swipeAngle >= 35) && (swipeAngle <= 135)) {
4151                return 'down';
4152            } else {
4153                return 'up';
4154            }
4155        }
4156
4157        return 'vertical';
4158
4159    };
4160
4161    Slick.prototype.swipeEnd = function(event) {
4162
4163        var _ = this,
4164            slideCount,
4165            direction;
4166
4167        _.dragging = false;
4168        _.interrupted = false;
4169        _.shouldClick = ( _.touchObject.swipeLength > 10 ) ? false : true;
4170
4171        if ( _.touchObject.curX === undefined ) {
4172            return false;
4173        }
4174
4175        if ( _.touchObject.edgeHit === true ) {
4176            _.$slider.trigger('edge', [_, _.swipeDirection() ]);
4177        }
4178
4179        if ( _.touchObject.swipeLength >= _.touchObject.minSwipe ) {
4180
4181            direction = _.swipeDirection();
4182
4183            switch ( direction ) {
4184
4185                case 'left':
4186                case 'down':
4187
4188                    slideCount =
4189                        _.options.swipeToSlide ?
4190                            _.checkNavigable( _.currentSlide + _.getSlideCount() ) :
4191                            _.currentSlide + _.getSlideCount();
4192
4193                    _.currentDirection = 0;
4194
4195                    break;
4196
4197                case 'right':
4198                case 'up':
4199
4200                    slideCount =
4201                        _.options.swipeToSlide ?
4202                            _.checkNavigable( _.currentSlide - _.getSlideCount() ) :
4203                            _.currentSlide - _.getSlideCount();
4204
4205                    _.currentDirection = 1;
4206
4207                    break;
4208
4209                default:
4210
4211
4212            }
4213
4214            if( direction != 'vertical' ) {
4215
4216                _.slideHandler( slideCount );
4217                _.touchObject = {};
4218                _.$slider.trigger('swipe', [_, direction ]);
4219
4220            }
4221
4222        } else {
4223
4224            if ( _.touchObject.startX !== _.touchObject.curX ) {
4225
4226                _.slideHandler( _.currentSlide );
4227                _.touchObject = {};
4228
4229            }
4230
4231        }
4232
4233    };
4234
4235    Slick.prototype.swipeHandler = function(event) {
4236
4237        var _ = this;
4238
4239        if ((_.options.swipe === false) || ('ontouchend' in document && _.options.swipe === false)) {
4240            return;
4241        } else if (_.options.draggable === false && event.type.indexOf('mouse') !== -1) {
4242            return;
4243        }
4244
4245        _.touchObject.fingerCount = event.originalEvent && event.originalEvent.touches !== undefined ?
4246            event.originalEvent.touches.length : 1;
4247
4248        _.touchObject.minSwipe = _.listWidth / _.options
4249            .touchThreshold;
4250
4251        if (_.options.verticalSwiping === true) {
4252            _.touchObject.minSwipe = _.listHeight / _.options
4253                .touchThreshold;
4254        }
4255
4256        switch (event.data.action) {
4257
4258            case 'start':
4259                _.swipeStart(event);
4260                break;
4261
4262            case 'move':
4263                _.swipeMove(event);
4264                break;
4265
4266            case 'end':
4267                _.swipeEnd(event);
4268                break;
4269
4270        }
4271
4272    };
4273
4274    Slick.prototype.swipeMove = function(event) {
4275
4276        var _ = this,
4277            edgeWasHit = false,
4278            curLeft, swipeDirection, swipeLength, positionOffset, touches;
4279
4280        touches = event.originalEvent !== undefined ? event.originalEvent.touches : null;
4281
4282        if (!_.dragging || touches && touches.length !== 1) {
4283            return false;
4284        }
4285
4286        curLeft = _.getLeft(_.currentSlide);
4287
4288        _.touchObject.curX = touches !== undefined ? touches[0].pageX : event.clientX;
4289        _.touchObject.curY = touches !== undefined ? touches[0].pageY : event.clientY;
4290
4291        _.touchObject.swipeLength = Math.round(Math.sqrt(
4292            Math.pow(_.touchObject.curX - _.touchObject.startX, 2)));
4293
4294        if (_.options.verticalSwiping === true) {
4295            _.touchObject.swipeLength = Math.round(Math.sqrt(
4296                Math.pow(_.touchObject.curY - _.touchObject.startY, 2)));
4297        }
4298
4299        swipeDirection = _.swipeDirection();
4300
4301        if (swipeDirection === 'vertical') {
4302            return;
4303        }
4304
4305        if (event.originalEvent !== undefined && _.touchObject.swipeLength > 4) {
4306            event.preventDefault();
4307        }
4308
4309        positionOffset = (_.options.rtl === false ? 1 : -1) * (_.touchObject.curX > _.touchObject.startX ? 1 : -1);
4310        if (_.options.verticalSwiping === true) {
4311            positionOffset = _.touchObject.curY > _.touchObject.startY ? 1 : -1;
4312        }
4313
4314
4315        swipeLength = _.touchObject.swipeLength;
4316
4317        _.touchObject.edgeHit = false;
4318
4319        if (_.options.infinite === false) {
4320            if ((_.currentSlide === 0 && swipeDirection === 'right') || (_.currentSlide >= _.getDotCount() && swipeDirection === 'left')) {
4321                swipeLength = _.touchObject.swipeLength * _.options.edgeFriction;
4322                _.touchObject.edgeHit = true;
4323            }
4324        }
4325
4326        if (_.options.vertical === false) {
4327            _.swipeLeft = curLeft + swipeLength * positionOffset;
4328        } else {
4329            _.swipeLeft = curLeft + (swipeLength * (_.$list.height() / _.listWidth)) * positionOffset;
4330        }
4331        if (_.options.verticalSwiping === true) {
4332            _.swipeLeft = curLeft + swipeLength * positionOffset;
4333        }
4334
4335        if (_.options.fade === true || _.options.touchMove === false) {
4336            return false;
4337        }
4338
4339        if (_.animating === true) {
4340            _.swipeLeft = null;
4341            return false;
4342        }
4343
4344        _.setCSS(_.swipeLeft);
4345
4346    };
4347
4348    Slick.prototype.swipeStart = function(event) {
4349
4350        var _ = this,
4351            touches;
4352
4353        _.interrupted = true;
4354
4355        if (_.touchObject.fingerCount !== 1 || _.slideCount <= _.options.slidesToShow) {
4356            _.touchObject = {};
4357            return false;
4358        }
4359
4360        if (event.originalEvent !== undefined && event.originalEvent.touches !== undefined) {
4361            touches = event.originalEvent.touches[0];
4362        }
4363
4364        _.touchObject.startX = _.touchObject.curX = touches !== undefined ? touches.pageX : event.clientX;
4365        _.touchObject.startY = _.touchObject.curY = touches !== undefined ? touches.pageY : event.clientY;
4366
4367        _.dragging = true;
4368
4369    };
4370
4371    Slick.prototype.unfilterSlides = Slick.prototype.slickUnfilter = function() {
4372
4373        var _ = this;
4374
4375        if (_.$slidesCache !== null) {
4376
4377            _.unload();
4378
4379            _.$slideTrack.children(this.options.slide).detach();
4380
4381            _.$slidesCache.appendTo(_.$slideTrack);
4382
4383            _.reinit();
4384
4385        }
4386
4387    };
4388
4389    Slick.prototype.unload = function() {
4390
4391        var _ = this;
4392
4393        $('.slick-cloned', _.$slider).remove();
4394
4395        if (_.$dots) {
4396            _.$dots.remove();
4397        }
4398
4399        if (_.$prevArrow && _.htmlExpr.test(_.options.prevArrow)) {
4400            _.$prevArrow.remove();
4401        }
4402
4403        if (_.$nextArrow && _.htmlExpr.test(_.options.nextArrow)) {
4404            _.$nextArrow.remove();
4405        }
4406
4407        _.$slides
4408            .removeClass('slick-slide slick-active slick-visible slick-current')
4409            .attr('aria-hidden', 'true')
4410            .css('width', '');
4411
4412    };
4413
4414    Slick.prototype.unslick = function(fromBreakpoint) {
4415
4416        var _ = this;
4417        _.$slider.trigger('unslick', [_, fromBreakpoint]);
4418        _.destroy();
4419
4420    };
4421
4422    Slick.prototype.updateArrows = function() {
4423
4424        var _ = this,
4425            centerOffset;
4426
4427        centerOffset = Math.floor(_.options.slidesToShow / 2);
4428
4429        if ( _.options.arrows === true &&
4430            _.slideCount > _.options.slidesToShow &&
4431            !_.options.infinite ) {
4432
4433            _.$prevArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
4434            _.$nextArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
4435
4436            if (_.currentSlide === 0) {
4437
4438                _.$prevArrow.addClass('slick-disabled').attr('aria-disabled', 'true');
4439                _.$nextArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
4440
4441            } else if (_.currentSlide >
4441= _.slideCount - _.options.slidesToShow && _.options.centerMode === false) {
4442
4443                _.$nextArrow.addClass('slick-disabled').attr('aria-disabled', 'true');
4444                _.$prevArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
4445
4446            } else if (_.currentSlide >= _.slideCount - 1 && _.options.centerMode === true) {
4447
4448                _.$nextArrow.addClass('slick-disabled').attr('aria-disabled', 'true');
4449                _.$prevArrow.removeClass('slick-disabled').attr('aria-disabled', 'false');
4450
4451            }
4452
4453        }
4454
4455    };
4456
4457    Slick.prototype.updateDots = function() {
4458
4459        var _ = this;
4460
4461        if (_.$dots !== null) {
4462
4463            _.$dots
4464                .find('li')
4465                .removeClass('slick-active')
4466                .attr('aria-hidden', 'true');
4467
4468            _.$dots
4469                .find('li')
4470                .eq(Math.floor(_.currentSlide / _.options.slidesToScroll))
4471                .addClass('slick-active')
4472                .attr('aria-hidden', 'false');
4473
4474        }
4475
4476    };
4477
4478    Slick.prototype.visibility = function() {
4479
4480        var _ = this;
4481
4482        if ( _.options.autoplay ) {
4483
4484            if ( document[_.hidden] ) {
4485
4486                _.interrupted = true;
4487
4488            } else {
4489
4490                _.interrupted = false;
4491
4492            }
4493
4494        }
4495
4496    };
4497
4498    $.fn.slick = function() {
4499        var _ = this,
4500            opt = arguments[0],
4501            args = Array.prototype.slice.call(arguments, 1),
4502            l = _.length,
4503            i,
4504            ret;
4505        for (i = 0; i < l; i++) {
4506            if (typeof opt == 'object' || typeof opt == 'undefined')
4507                _[i].slick = new Slick(_[i], opt);
4508            else
4509                ret = _[i].slick[opt].apply(_[i].slick, args);
4510            if (typeof ret != 'undefined') return ret;
4511        }
4512        return _;
4513    };
4514
4515}));
4516;
4517/**
4518* DO NOT EDIT THIS FILE.
4519* See the following change record for more information,
4520* https://www.drupal.org/node/2815083
4521* @preserve
4522**/
4523
4524(function ($, Drupal) {
4525  Drupal.theme.progressBar = function (id) {
4526    return '<div id="' + id + '" class="progress" aria-live="polite">' + '<div class="progress__label">&nbsp;</div>' + '<div class="progress__track"><div class="progress__bar"></div></div>' + '<div class="progress__percentage"></div>' + '<div class="progress__description">&nbsp;</div>' + '</div>';
4527  };
4528
4529  Drupal.ProgressBar = function (id, updateCallback, method, errorCallback) {
4530    this.id = id;
4531    this.method = method || 'GET';
4532    this.updateCallback = updateCallback;
4533    this.errorCallback = errorCallback;
4534
4535    this.element = $(Drupal.theme('progressBar', id));
4536  };
4537
4538  $.extend(Drupal.ProgressBar.prototype, {
4539    setProgress: function setProgress(percentage, message, label) {
4540      if (percentage >= 0 && percentage <= 100) {
4541        $(this.element).find('div.progress__bar').css('width', percentage + '%');
4542        $(this.element).find('div.progress__percentage').html(percentage + '%');
4543      }
4544      $('div.progress__description', this.element).html(message);
4545      $('div.progress__label', this.element).html(label);
4546      if (this.updateCallback) {
4547        this.updateCallback(percentage, message, this);
4548      }
4549    },
4550    startMonitoring: function startMonitoring(uri, delay) {
4551      this.delay = delay;
4552      this.uri = uri;
4553      this.sendPing();
4554    },
4555    stopMonitoring: function stopMonitoring() {
4556      clearTimeout(this.timer);
4557
4558      this.uri = null;
4559    },
4560    sendPing: function sendPing() {
4561      if (this.timer) {
4562        clearTimeout(this.timer);
4563      }
4564      if (this.uri) {
4565        var pb = this;
4566
4567        var uri = this.uri;
4568        if (uri.indexOf('?') === -1) {
4569          uri += '?';
4570        } else {
4571          uri += '&';
4572        }
4573        uri += '_format=json';
4574        $.ajax({
4575          type: this.method,
4576          url: uri,
4577          data: '',
4578          dataType: 'json',
4579          success: function success(progress) {
4580            if (progress.status === 0) {
4581              pb.displayError(progress.data);
4582              return;
4583            }
4584
4585            pb.setProgress(progress.percentage, progress.message, progress.label);
4586
4587            pb.timer = setTimeout(function () {
4588              pb.sendPing();
4589            }, pb.delay);
4590          },
4591          error: function error(xmlhttp) {
4592            var e = new Drupal.AjaxError(xmlhttp, pb.uri);
4593            pb.displayError('<pre>' + e.message + '</pre>');
4594          }
4595        });
4596      }
4597    },
4598    displayError: function displayError(string) {
4599      var error = $('<div class="messages messages--error"></div>').html(string);
4600      $(this.element).before(error).hide();
4601
4602      if (this.errorCallback) {
4603        this.errorCallback(this);
4604      }
4605    }
4606  });
4607})(jQuery, Drupal);;
4608/**
4609* DO NOT EDIT THIS FILE.
4610* See the following change record for more information,
4611* https://www.drupal.org/node/2815083
4612* @preserve
4613**/
4614
4615(function (Drupal) {
4616  Drupal.behaviors.responsiveImageAJAX = {
4617    attach: function attach() {
4618      if (window.picturefill) {
4619        window.picturefill();
4620      }
4621    }
4622  };
4623})(Drupal);;
4624/**
4625* DO NOT EDIT THIS FILE.
4626* See the following change record for more information,
4627* https://www.drupal.org/node/2815083
4628* @preserve
4629**/
4630function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }
4631
4632(function ($, window, Drupal, drupalSettings) {
4633  Drupal.behaviors.AJAX = {
4634    attach: function attach(context, settings) {
4635      function loadAjaxBehavior(base) {
4636        var element_settings = settings.ajax[base];
4637        if (typeof element_settings.selector === 'undefined') {
4638          element_settings.selector = '#' + base;
4639        }
4640        $(element_settings.selector).once('drupal-ajax').each(function () {
4641          element_settings.element = this;
4642          element_settings.base = base;
4643          Drupal.ajax(element_settings);
4644        });
4645      }
4646
4647      for (var base in settings.ajax) {
4648        if (settings.ajax.hasOwnProperty(base)) {
4649          loadAjaxBehavior(base);
4650        }
4651      }
4652
4653      $('.use-ajax').once('ajax').each(function () {
4654        var element_settings = {};
4655
4656        element_settings.progress = { type: 'throbber' };
4657
4658        var href = $(this).attr('href');
4659        if (href) {
4660          element_settings.url = href;
4661          element_settings.event = 'click';
4662        }
4663        element_settings.dialogType = $(this).data('dialog-type');
4664        element_settings.dialogRenderer = $(this).data('dialog-renderer');
4665        element_settings.dialog = $(this).data('dialog-options');
4666        element_settings.base = $(this).attr('id');
4667        element_settings.element = this;
4668        Drupal.ajax(element_settings);
4669      });
4670
4671      $('.use-ajax-submit').once('ajax').each(function () {
4672        var element_settings = {};
4673
4674        element_settings.url = $(this.form).attr('action');
4675
4676        element_settings.setClick = true;
4677
4678        element_settings.event = 'click';
4679
4680        element_settings.progress = { type: 'throbber' };
4681        element_settings.base = $(this).attr('id');
4682        element_settings.element = this;
4683
4684        Drupal.ajax(element_settings);
4685      });
4686    },
4687    detach: function detach(context, settings, trigger) {
4688      if (trigger === 'unload') {
4689        Drupal.ajax.expired().forEach(function (instance) {
4690          Drupal.ajax.instances[instance.instanceIndex] = null;
4691        });
4692      }
4693    }
4694  };
4695
4696  Drupal.AjaxError = function (xmlhttp, uri, customMessage) {
4697    var statusCode = void 0;
4698    var statusText = void 0;
4699    var pathText = void 0;
4700    var responseText = void 0;
4701    var readyStateText = void 0;
4702    if (xmlhttp.status) {
4703      statusCode = '\n' + Drupal.t('An AJAX HTTP error occurred.') + '\n' + Drupal.t('HTTP Result Code: !status', { '!status': xmlhttp.status });
4704    } else {
4705      statusCode = '\n' + Drupal.t('An AJAX HTTP request terminated abnormally.');
4706    }
4707    statusCode += '\n' + Drupal.t('Debugging information follows.');
4708    pathText = '\n' + Drupal.t('Path: !uri', { '!uri': uri });
4709    statusText = '';
4710
4711    try {
4712      statusText = '\n' + Drupal.t('StatusText: !statusText', { '!statusText': $.trim(xmlhttp.statusText) });
4713    } catch (e) {}
4714
4715    responseText = '';
4716
4717    try {
4718      responseText = '\n' + Drupal.t('ResponseText: !responseText', { '!responseText': $.trim(xmlhttp.responseText) });
4719    } catch (e) {}
4720
4721    responseText = responseText.replace(/<("[^"]*"|'[^']*'|[^'">])*>/gi, '');
4722    responseText = responseText.replace(/[\n]+\s+/g, '\n');
4723
4724    readyStateText = xmlhttp.status === 0 ? '\n' + Drupal.t('ReadyState: !readyState', { '!readyState': xmlhttp.readyState }) : '';
4725
4726    customMessage = customMessage ? '\n' + Drupal.t('CustomMessage: !customMessage', { '!customMessage': customMessage }) : '';
4727
4728    this.message = statusCode + pathText + statusText + customMessage + responseText + readyStateText;
4729
4730    this.name = 'AjaxError';
4731  };
4732
4733  Drupal.AjaxError.prototype = new Error();
4734  Drupal.AjaxError.prototype.constructor = Drupal.AjaxError;
4735
4736  Drupal.ajax = function (settings) {
4737    if (arguments.length !== 1) {
4738      throw new Error('Drupal.ajax() function must be called with one configuration object only');
4739    }
4740
4741    var base = settings.base || false;
4742    var element = settings.element || false;
4743    delete settings.base;
4744    delete settings.element;
4745
4746    if (!settings.progress && !element) {
4747      settings.progress = false;
4748    }
4749
4750    var ajax = new Drupal.Ajax(base, element, settings);
4751    ajax.instanceIndex = Drupal.ajax.instances.length;
4752    Drupal.ajax.instances.push(ajax);
4753
4754    return ajax;
4755  };
4756
4757  Drupal.ajax.instances = [];
4758
4759  Drupal.ajax.expired = function () {
4760    return Drupal.ajax.instances.filter(function (instance) {
4761      return instance && instance.element !== false && !document.body.contains(instance.element);
4762    });
4763  };
4764
4765  Drupal.Ajax = function (base, element, element_settings) {
4766    var defaults = {
4767      event: element ? 'mousedown' : null,
4768      keypress: true,
4769      selector: base ? '#' + base : null,
4770      effect: 'none',
4771      speed: 'none',
4772      method: 'replaceWith',
4773      progress: {
4774        type: 'throbber',
4775        message: Drupal.t('Please wait...')
4776      },
4777      submit: {
4778        js: true
4779      }
4780    };
4781
4782    $.extend(this, defaults, element_settings);
4783
4784    this.commands = new Drupal.AjaxCommands();
4785
4786    this.instanceIndex = false;
4787
4788    if (this.wrapper) {
4789      this.wrapper = '#' + this.wrapper;
4790    }
4791
4792    this.element = element;
4793
4794    this.element_settings = element_settings;
4795
4796    if (this.element && this.element.form) {
4797      this.$form = $(this.element.form);
4798    }
4799
4800    if (!this.url) {
4801      var $element = $(this.element);
4802      if ($element.is('a')) {
4803        this.url = $element.attr('href');
4804      } else if (this.element && element.form) {
4805        this.url = this.$form.attr('action');
4806      }
4807    }
4808
4809    var originalUrl = this.url;
4810
4811    this.url = this.url.replace(/\/nojs(\/|$|\?|#)/g, '/ajax$1');
4812
4813    if (drupalSettings.ajaxTrustedUrl[originalUrl]) {
4814      drupalSettings.ajaxTrustedUrl[this.url] = true;
4815    }
4816
4817    var ajax = this;
4818
4819    ajax.options = {
4820      url: ajax.url,
4821      data: ajax.submit,
4822      beforeSerialize: function beforeSerialize(element_settings, options) {
4823        return ajax.beforeSerialize(element_settings, options);
4824      },
4825      beforeSubmit: function beforeSubmit(form_values, element_settings, options) {
4826        ajax.ajaxing = true;
4827        return ajax.beforeSubmit(form_values, element_settings, options);
4828      },
4829      beforeSend: function beforeSend(xmlhttprequest, options) {
4830        ajax.ajaxing = true;
4831        return ajax.beforeSend(xmlhttprequest, options);
4832      },
4833      success: function success(response, status, xmlhttprequest) {
4834        if (typeof response === 'string') {
4835          response = $.parseJSON(response);
4836        }
4837
4838        if (response !== null && !drupalSettings.ajaxTrustedUrl[ajax.url]) {
4839          if (xmlhttprequest.getResponseHeader('X-Drupal-Ajax-Token') !== '1') {
4840            var customMessage = Drupal.t('The response failed verification so will not be processed.');
4841            return ajax.error(xmlhttprequest, ajax.url, customMessage);
4842          }
4843        }
4844
4845        return ajax.success(response, status);
4846      },
4847      complete: function complete(xmlhttprequest, status) {
4848        ajax.ajaxing = false;
4849        if (status === 'error' || status === 'parsererror') {
4850          return ajax.error(xmlhttprequest, ajax.url);
4851        }
4852      },
4853
4854      dataType: 'json',
4855      type: 'POST'
4856    };
4857
4858    if (element_settings.dialog) {
4859      ajax.options.data.dialogOptions = element_settings.dialog;
4860    }
4861
4862    if (ajax.options.url.indexOf('?') === -1) {
4863      ajax.options.url += '?';
4864    } else {
4865      ajax.options.url += '&';
4866    }
4867
4868    var wrapper = 'drupal_' + (element_settings.dialogType || 'ajax');
4869    if (element_settings.dialogRenderer) {
4870      wrapper += '.' + element_settings.dialogRenderer;
4871    }
4872    ajax.options.url += Drupal.ajax.WRAPPER_FORMAT + '=' + wrapper;
4873
4874    $(ajax.element).on(element_settings.event, function (event) {
4875      if (!drupalSettings.ajaxTrustedUrl[ajax.url] && !Drupal.url.isLocal(ajax.url)) {
4876        throw new Error(Drupal.t('The callback URL is not local and not trusted: !url', { '!url': ajax.url }));
4877      }
4878      return ajax.eventResponse(this, event);
4879    });
4880
4881    if (element_settings.keypress) {
4882      $(ajax.element).on('keypress', function (event) {
4883        return ajax.keypressResponse(this, event);
4884      });
4885    }
4886
4887    if (element_settings.prevent) {
4888      $(ajax.element).on(element_settings.prevent, false);
4889    }
4890  };
4891
4892  Drupal.ajax.WRAPPER_FORMAT = '_wrapper_format';
4893
4894  Drupal.Ajax.AJAX_REQUEST_PARAMETER = '_drupal_ajax';
4895
4896  Drupal.Ajax.prototype.execute = function () {
4897    if (this.ajaxing) {
4898      return;
4899    }
4900
4901    try {
4902      this.beforeSerialize(this.element, this.options);
4903
4904      return $.ajax(this.options);
4905    } catch (e) {
4906      this.ajaxing = false;
4907      window.alert('An error occurred while attempting to process ' + this.options.url + ': ' + e.message);
4908
4909      return $.Deferred().reject();
4910    }
4911  };
4912
4913  Drupal.Ajax.prototype.keypressResponse = function (element, event) {
4914    var ajax = this;
4915
4916    if (event.which === 13 || event.which === 32 && element.type !== 'text' && element.type !== 'textarea' && element.type !== 'tel' && element.type !== 'number') {
4917      event.preventDefault();
4918      event.stopPropagation();
4919      $(element).trigger(ajax.element_settings.event);
4920    }
4921  };
4922
4923  Drupal.Ajax.prototype.eventResponse = function (element, event) {
4924    event.preventDefault();
4925    event.stopPropagation();
4926
4927    var ajax = this;
4928
4929    if (ajax.ajaxing) {
4930      return;
4931    }
4932
4933    try {
4934      if (ajax.$form) {
4935        if (ajax.setClick) {
4936          element.form.clk = element;
4937        }
4938
4939        ajax.$form.ajaxSubmit(ajax.options);
4940      } else {
4941        ajax.beforeSerialize(ajax.element, ajax.options);
4942        $.ajax(ajax.options);
4943      }
4944    } catch (e) {
4945      ajax.ajaxing = false;
4946      window.alert('An error occurred while attempting to process ' + ajax.options.url + ': ' + e.message);
4947    }
4948  };
4949
4950  Drupal.Ajax.prototype.beforeSerialize = function (element, options) {
4951    if (this.$form) {
4952      var settings = this.settings || drupalSettings;
4953      Drupal.detachBehaviors(this.$form.get(0), settings, 'serialize');
4954    }
4955
4956    options.data[Drupal.Ajax.AJAX_REQUEST_PARAMETER] = 1;
4957
4958    var pageState = drupalSettings.ajaxPageState;
4959    options.data['ajax_page_state[theme]'] = pageState.theme;
4960    options.data['ajax_page_state[theme_token]'] = pageState.theme_token;
4961    options.data['ajax_page_state[libraries]'] = pageState.libraries;
4962  };
4963
4964  Drupal.Ajax.prototype.beforeSubmit = function (form_values, element, options) {};
4965
4966  Drupal.Ajax.prototype.beforeSend = function (xmlhttprequest, options) {
4967    if (this.$form) {
4968      options.extraData = options.extraData || {};
4969
4970      options.extraData.ajax_iframe_upload = '1';
4971
4972      var v = $.fieldValue(this.element);
4973      if (v !== null) {
4974        options.extraData[this.element.name] = v;
4975      }
4976    }
4977
4978    $(this.element).prop('disabled', true);
4979
4980    if (!this.progress || !this.progress.type) {
4981      return;
4982    }
4983
4984    var progressIndicatorMethod = 'setProgressIndicator' + this.progress.type.slice(0, 1).toUpperCase() + this.progress.type.slice(1).toLowerCase();
4985    if (progressIndicatorMethod in this && typeof this[progressIndicatorMethod] === 'function') {
4986      this[progressIndicatorMethod].call(this);
4987    }
4988  };
4989
4990  Drupal.Ajax.prototype.setProgressIndicatorBar = function () {
4991    var progressBar = new Drupal.ProgressBar('ajax-progress-' + this.element.id, $.noop, this.progress.method, $.noop);
4992    if (this.progress.message) {
4993      progressBar.setProgress(-1, this.progress.message);
4994    }
4995    if (this.progress.url) {
4996      progressBar.startMonitoring(this.progress.url, this.progress.interval || 1500);
4997    }
4998    this.progress.element = $(progressBar.element).addClass('ajax-progress ajax-progress-bar');
4999    this.progress.object = progressBar;
5000    $(this.element).after(this.progress.element);
5001  };
5002
5003  Drupal.Ajax.prototype.setProgressIndicatorThrobber = function () {
5004    this.progress.element = $('<div class="ajax-progress ajax-progress-throbber"><div class="throbber">&nbsp;</div></div>');
5005    if (this.progress.message) {
5006      this.progress.element.find('.throbber').after('<div class="message">' + this.progress.message + '</div>');
5007    }
5008    $(this.element).after(this.progress.element);
5009  };
5010
5011  Drupal.Ajax.prototype.setProgressIndicatorFullscreen = function () {
5012    this.progress.element = $('<div class="ajax-progress ajax-progress-fullscreen">&nbsp;</div>');
5013    $('body').after(this.progress.element);
5014  };
5015
5016  Drupal.Ajax.prototype.success = function (response, status) {
5017    if (this.progress.element) {
5018      $(this.progress.element).remove();
5019    }
5020    if (this.progress.object) {
5021      this.progress.object.stopMonitoring();
5022    }
5023    $(this.element).prop('disabled', false);
5024
5025    var elementParents = $(this.element).parents('[data-drupal-selector]').addBack().toArray();
5026
5027    var focusChanged = false;
5028    for (var i in response) {
5029      if (response.hasOwnProperty(i) && response[i].command && this.commands[response[i].command]) {
5030        this.commands[response[i].command](this, response[i], status);
5031        if (response[i].command === 'invoke' && response[i].method === 'focus') {
5032          focusChanged = true;
5033        }
5034      }
5035    }
5036
5037    if (!focusChanged && this.element && !$(this.element).data('disable-refocus')) {
5038      var target = false;
5039
5040      for (var n = elementParents.length - 1; !target && n > 0; n--) {
5041        target = document.querySelector('[data-drupal-selector="' + elementParents[n].getAttribute('data-drupal-selector') + '"]');
5042      }
5043
5044      if (target) {
5045        $(target).trigger('focus');
5046      }
5047    }
5048
5049    if (this.$form) {
5050      var settings = this.settings || drupalSettings;
5051      Drupal.attachBehaviors(this.$form.get(0), settings);
5052    }
5053
5054    this.settings = null;
5055  };
5056
5057  Drupal.Ajax.prototype.getEffect = function (response) {
5058    var type = response.effect || this.effect;
5059    var speed = response.speed || this.speed;
5060
5061    var effect = {};
5062    if (type === 'none') {
5063      effect.showEffect = 'show';
5064      effect.hideEffect = 'hide';
5065      effect.showSpeed = '';
5066    } else if (type === 'fade') {
5067      effect.showEffect = 'fadeIn';
5068      effect.hideEffect = 'fadeOut';
5069      effect.showSpeed = speed;
5070    } else {
5071      effect.showEffect = type + 'Toggle';
5072      effect.hideEffect = type + 'Toggle';
5073      effect.showSpeed = speed;
5074    }
5075
5076    return effect;
5077  };
5078
5079  Drupal.Ajax.prototype.error = function (xmlhttprequest, uri, customMessage) {
5080    if (this.progress.element) {
5081      $(this.progress.element).remove();
5082    }
5083    if (this.progress.object) {
5084      this.progress.object.stopMonitoring();
5085    }
5086
5087    $(this.wrapper).show();
5088
5089    $(this.element).prop('disabled', false);
5090
5091    if (this.$form) {
5092      var settings = this.settings || drupalSettings;
5093      Drupal.attachBehaviors(this.$form.get(0), settings);
5094    }
5095    throw new Drupal.AjaxError(xmlhttprequest, uri, customMessage);
5096  };
5097
5098  Drupal.AjaxCommands = function () {};
5099  Drupal.AjaxCommands.prototype = {
5100    insert: function insert(ajax, response, status) {
5101      var $wrapper = response.selector ? $(response.selector) : $(ajax.wrapper);
5102      var method = response.method || ajax.method;
5103      var effect = ajax.getEffect(response);
5104      var settings = void 0;
5105
5106      var $new_content_wrapped = $('<div></div>').html(response.data);
5107      var $new_content = $new_content_wrapped.contents();
5108
5109      if ($new_content.length !== 1 || $new_content.get(0).nodeType !== 1) {
5110        $new_content = $new_content_wrapped;
5111      }
5112
5113      switch (method) {
5114        case 'html':
5115        case 'replaceWith':
5116        case 'replaceAll':
5117        case 'empty':
5118        case 'remove':
5119          settings = response.settings || ajax.settings || drupalSettings;
5120          Drupal.detachBehaviors($wrapper.get(0), settings);
5121      }
5122
5123      $wrapper[method]($new_content);
5124
5125      if (effect.showEffect !== 'show') {
5126        $new_content.hide();
5127      }
5128
5129      if ($new_content.find('.ajax-new-content').length > 0) {
5130        $new_content.find('.ajax-new-content').hide();
5131        $new_content.show();
5132        $new_content.find('.ajax-new-content')[effect.showEffect](effect.showSpeed);
5133      } else if (effect.showEffect !== 'show') {
5134        $new_content[effect.showEffect](effect.showSpeed);
5135      }
5136
5137      if ($new_content.parents('html').length > 0) {
5138        settings = response.settings || ajax.settings || drupalSettings;
5139        Drupal.attachBehaviors($new_content.get(0), settings);
5140      }
5141    },
5142    remove: function remove(ajax, response, status) {
5143      var settings = response.settings || ajax.settings || drupalSettings;
5144      $(response.selector).each(function () {
5145        Drupal.detachBehaviors(this, settings);
5146      }).remove();
5147    },
5148    changed: function changed(ajax, response, status) {
5149      var $element = $(response.selector);
5150      if (!$element.hasClass('ajax-changed')) {
5151        $element.addClass('ajax-changed');
5152        if (response.asterisk) {
5153          $element.find(response.asterisk).append(' <abbr class="ajax-changed" title="' + Drupal.t('Changed') + '">*</abbr> ');
5154        }
5155      }
5156    },
5157    alert: function alert(ajax, response, status) {
5158      window.alert(response.text, response.title);
5159    },
5160    redirect: function redirect(ajax, response, status) {
5161      window.location = response.url;
5162    },
5163    css: function css(ajax, response, status) {
5164      $(response.selector).css(response.argument);
5165    },
5166    settings: function settings(ajax, response, status) {
5167      var ajaxSettings = drupalSettings.ajax;
5168
5169      if (ajaxSettings) {
5170        Drupal.ajax.expired().forEach(function (instance) {
5171
5172          if (instance.selector) {
5173            var selector = instance.selector.replace('#', '');
5174            if (selector in ajaxSettings) {
5175              delete ajaxSettings[selector];
5176            }
5177          }
5178        });
5179      }
5180
5181      if (response.merge) {
5182        $.extend(true, drupalSettings, response.settings);
5183      } else {
5184        ajax.settings = response.settings;
5185      }
5186    },
5187    data: function data(ajax, response, status) {
5188      $(response.selector).data(response.name, response.value);
5189    },
5190    invoke: function invoke(ajax, response, status) {
5191      var $element = $(response.selector);
5192      $element[response.method].apply($element, _toConsumableArray(response.args));
5193    },
5194    restripe: function restripe(ajax, response, status) {
5195      $(response.selector).find('> tbody > tr:visible, > tr:visible').removeClass('odd even').filter(':even').addClass('odd').end().filter(':odd').addClass('even');
5196    },
5197    update_build_id: function update_build_id(ajax, response, status) {
5198      $('input[name="form_build_id"][value="' + response.old + '"]').val(response.new);
5199    },
5200    add_css: function add_css(ajax, response, status) {
5201      $('head').prepend(response.data);
5202
5203      var match = void 0;
5204      var importMatch = /^@import url\("(.*)"\);$/igm;
5205      if (document.styleSheets[0].addImport && importMatch.test(response.data)) {
5206        importMatch.lastIndex = 0;
5207        do {
5208          match = importMatch.exec(response.data);
5209          document.styleSheets[0].addImport(match[1]);
5210        } while (match);
5211      }
5212    }
5213  };
5214})(jQuery, window, Drupal, drupalSettings);;
5215(function ($, window, Drupal, drupalSettings) {
5216
5217  /**
5218   * Overrides the Full screen progress indicator.
5219   */
5220  Drupal.Ajax.prototype.setProgressIndicatorFullscreen = function () {
5221    this.progress.element = $('<div class="ajax-progress ajax-progress-fullscreen">&nbsp;</div>');
5222    $('#main').append(this.progress.element);
5223  };
5224
5225})(jQuery, window, Drupal, drupalSettings);
5226;
5227/**
5228* DO NOT EDIT THIS FILE.
5229* See the following change record for more information,
5230* https://www.drupal.org/node/2815083
5231* @preserve
5232**/
5233
5234Drupal.debounce = function (func, wait, immediate) {
5235  var timeout = void 0;
5236  var result = void 0;
5237  return function () {
5238    var context = this;
5239    var args = arguments;
5240    var later = function later() {
5241      timeout = null;
5242      if (!immediate) {
5243        result = func.apply(context, args);
5244      }
5245    };
5246    var callNow = immediate && !timeout;
5247    clearTimeout(timeout);
5248    timeout = setTimeout(later, wait);
5249    if (callNow) {
5250      result = func.apply(context, args);
5251    }
5252    return result;
5253  };
5254};;
5255/**
5256* DO NOT EDIT THIS FILE.
5257* See the following change record for more information,
5258* https://www.drupal.org/node/2815083
5259* @preserve
5260**/
5261
5262(function (Drupal, debounce) {
5263  var liveElement = void 0;
5264  var announcements = [];
5265
5266  Drupal.behaviors.drupalAnnounce = {
5267    attach: function attach(context) {
5268      if (!liveElement) {
5269        liveElement = document.createElement('div');
5270        liveElement.id = 'drupal-live-announce';
5271        liveElement.className = 'visually-hidden';
5272        liveElement.setAttribute('aria-live', 'polite');
5273        liveElement.setAttribute('aria-busy', 'false');
5274        document.body.appendChild(liveElement);
5275      }
5276    }
5277  };
5278
5279  function announce() {
5280    var text = [];
5281    var priority = 'polite';
5282    var announcement = void 0;
5283
5284    var il = announcements.length;
5285    for (var i = 0; i < il; i++) {
5286      announcement = announcements.pop();
5287      text.unshift(announcement.text);
5288
5289      if (announcement.priority === 'assertive') {
5290        priority = 'assertive';
5291      }
5292    }
5293
5294    if (text.length) {
5295      liveElement.innerHTML = '';
5296
5297      liveElement.setAttribute('aria-busy', 'true');
5298
5299      liveElement.setAttribute('aria-live', priority);
5300
5301      liveElement.innerHTML = text.join('\n');
5302
5303      liveElement.setAttribute('aria-busy', 'false');
5304    }
5305  }
5306
5307  Drupal.announce = function (text, priority) {
5308    announcements.push({
5309      text: text,
5310      priority: priority
5311    });
5312
5313    return debounce(announce, 200)();
5314  };
5315})(Drupal, Drupal.debounce);;
5316window.matchMedia||(window.matchMedia=function(){"use strict";var e=window.styleMedia||window.media;if(!e){var t=document.createElement("style"),i=document.getElementsByTagName("script")[0],n=null;t.type="text/css";t.id="matchmediajs-test";i.parentNode.insertBefore(t,i);n="getComputedStyle"in window&&window.getComputedStyle(t,null)||t.currentStyle;e={matchMedium:function(e){var i="@media "+e+"{ #matchmediajs-test { width: 1px; } }";if(t.styleSheet){t.styleSheet.cssText=i}else{t.textContent=i}return n.width==="1px"}}}return function(t){return{matches:e.matchMedium(t||"all"),media:t||"all"}}}());
5317;
5318(function(){if(window.matchMedia&&window.matchMedia("all").addListener){return false}var e=window.matchMedia,i=e("only all").matches,n=false,t=0,a=[],r=function(i){clearTimeout(t);t=setTimeout(function(){for(var i=0,n=a.length;i<n;i++){var t=a[i].mql,r=a[i].listeners||[],o=e(t.media).matches;if(o!==t.matches){t.matches=o;for(var s=0,l=r.length;s<l;s++){r[s].call(window,t)}}}},30)};window.matchMedia=function(t){var o=e(t),s=[],l=0;o.addListener=function(e){if(!i){return}if(!n){n=true;window.addEventListener("resize",r,true)}if(l===0){l=a.push({mql:o,listeners:s})}s.push(e)};o.removeListener=function(e){for(var i=0,n=s.length;i<n;i++){if(s[i]===e){s.splice(i,1)}}};return o}})();
5319;
5320/**
5321* DO NOT EDIT THIS FILE.
5322* See the following change record for more information,
5323* https://www.drupal.org/node/2815083
5324* @preserve
5325**/
5326
5327(function ($, Drupal, debounce) {
5328  var offsets = {
5329    top: 0,
5330    right: 0,
5331    bottom: 0,
5332    left: 0
5333  };
5334
5335  Drupal.behaviors.drupalDisplace = {
5336    attach: function attach() {
5337      if (this.displaceProcessed) {
5338        return;
5339      }
5340      this.displaceProcessed = true;
5341
5342      $(window).on('resize.drupalDisplace', debounce(displace, 200));
5343    }
5344  };
5345
5346  function displace(broadcast) {
5347    offsets = Drupal.displace.offsets = calculateOffsets();
5348    if (typeof broadcast === 'undefined' || broadcast) {
5349      $(document).trigger('drupalViewportOffsetChange', offsets);
5350    }
5351    return offsets;
5352  }
5353
5354  function calculateOffsets() {
5355    return {
5356      top: calculateOffset('top'),
5357      right: calculateOffset('right'),
5358      bottom: calculateOffset('bottom'),
5359      left: calculateOffset('left')
5360    };
5361  }
5362
5363  function calculateOffset(edge) {
5364    var edgeOffset = 0;
5365    var displacingElements = document.querySelectorAll('[data-offset-' + edge + ']');
5366    var n = displacingElements.length;
5367    for (var i = 0; i < n; i++) {
5368      var el = displacingElements[i];
5369
5370      if (el.style.display === 'none') {
5371        continue;
5372      }
5373
5374      var displacement = parseInt(el.getAttribute('data-offset-' + edge), 10);
5375
5376      if (isNaN(displacement)) {
5377        displacement = getRawOffset(el, edge);
5378      }
5379
5380      edgeOffset = Math.max(edgeOffset, displacement);
5381    }
5382
5383    return edgeOffset;
5384  }
5385
5386  function getRawOffset(el, edge) {
5387    var $el = $(el);
5388    var documentElement = document.documentElement;
5389    var displacement = 0;
5390    var horizontal = edge === 'left' || edge === 'right';
5391
5392    var placement = $el.offset()[horizontal ? 'left' : 'top'];
5393
5394    placement -= window['scroll' + (horizontal ? 'X' : 'Y')] || document.documentElement['scroll' + (horizontal ? 'Left' : 'Top')] || 0;
5395
5396    switch (edge) {
5397      case 'top':
5398        displacement = placement + $el.outerHeight();
5399        break;
5400
5401      case 'left':
5402        displacement = placement + $el.outerWidth();
5403        break;
5404
5405      case 'bottom':
5406        displacement = documentElement.clientHeight - placement;
5407        break;
5408
5409      case 'right':
5410        displacement = documentElement.clientWidth - placement;
5411        break;
5412
5413      default:
5414        displacement = 0;
5415    }
5416    return displacement;
5417  }
5418
5419  Drupal.displace = displace;
5420  $.extend(Drupal.displace, {
5421    offsets: offsets,
5422
5423    calculateOffset: calculateOffset
5424  });
5425})(jQuery, Drupal, Drupal.debounce);;
5426/**
5427* DO NOT EDIT THIS FILE.
5428* See the following change record for more information,
5429* https://www.drupal.org/node/2815083
5430* @preserve
5431**/
5432
5433(function ($, Drupal, drupalSettings) {
5434  var activeItem = Drupal.url(drupalSettings.path.currentPath);
5435
5436  $.fn.drupalToolbarMenu = function () {
5437    var ui = {
5438      handleOpen: Drupal.t('Extend'),
5439      handleClose: Drupal.t('Collapse')
5440    };
5441
5442    function toggleClickHandler(event) {
5443      var $toggle = $(event.target);
5444      var $item = $toggle.closest('li');
5445
5446      toggleList($item);
5447
5448      var $openItems = $item.siblings().filter('.open');
5449      toggleList($openItems, false);
5450    }
5451
5452    function linkClickHandler(event) {
5453      if (!Drupal.toolbar.models.toolbarModel.get('isFixed')) {
5454        Drupal.toolbar.models.toolbarModel.set('activeTab', null);
5455      }
5456
5457      event.stopPropagation();
5458    }
5459
5460    function toggleList($item, switcher) {
5461      var $toggle = $item.children('.toolbar-box').children('.toolbar-handle');
5462      switcher = typeof switcher !== 'undefined' ? switcher : !$item.hasClass('open');
5463
5464      $item.toggleClass('open', switcher);
5465
5466      $toggle.toggleClass('open', switcher);
5467
5468      $toggle.find('.action').text(switcher ? ui.handleClose : ui.handleOpen);
5469    }
5470
5471    function initItems($menu) {
5472      var options = {
5473        class: 'toolbar-icon toolbar-handle',
5474        action: ui.handleOpen,
5475        text: ''
5476      };
5477
5478      $menu.find('li > a').wrap('<div class="toolbar-box">');
5479
5480      $menu.find('li').each(function (index, element) {
5481        var $item = $(element);
5482        if ($item.children('ul.toolbar-menu').length) {
5483          var $box = $item.children('.toolbar-box');
5484          options.text = Drupal.t('@label', { '@label': $box.find('a').text() });
5485          $item.children('.toolbar-box').append(Drupal.theme('toolbarMenuItemToggle', options));
5486        }
5487      });
5488    }
5489
5490    function markListLevels($lists, level) {
5491      level = !level ? 1 : level;
5492      var $lis = $lists.children('li').addClass('level-' + level);
5493      $lists = $lis.children('ul');
5494      if ($lists.length) {
5495        markListLevels($lists, level + 1);
5496      }
5497    }
5498
5499    function openActiveItem($menu) {
5500      var pathItem = $menu.find('a[href="' + location.pathname + '"]');
5501      if (pathItem.length && !activeItem) {
5502        activeItem = location.pathname;
5503      }
5504      if (activeItem) {
5505        var $activeItem = $menu.find('a[href="' + activeItem + '"]').addClass('menu-item--active');
5506        var $activeTrail = $activeItem.parentsUntil('.root', 'li').addClass('menu-item--active-trail');
5507        toggleList($activeTrail, true);
5508      }
5509    }
5510
5511    return this.each(function (selector) {
5512      var $menu = $(this).once('toolbar-menu');
5513      if ($menu.length) {
5514        $menu.on('click.toolbar', '.toolbar-box', toggleClickHandler).on('click.toolbar', '.toolbar-box a', linkClickHandler);
5515
5516        $menu.addClass('root');
5517        initItems($menu);
5518        markListLevels($menu);
5519
5520        openActiveItem($menu);
5521      }
5522    });
5523  };
5524
5525  Drupal.theme.toolbarMenuItemToggle = function (options) {
5526    return '<button class="' + options.class + '"><span class="action">' + options.action + '</span><span class="label">' + options.text + '</span></button>';
5527  };
5528})(jQuery, Drupal, drupalSettings);;
5529/**
5530* DO NOT EDIT THIS FILE.
5531* See the following change record for more information,
5532* https://www.drupal.org/node/2815083
5533* @preserve
5534**/
5535
5536(function ($, Drupal, drupalSettings) {
5537  var options = $.extend({
5538    breakpoints: {
5539      'toolbar.narrow': '',
5540      'toolbar.standard': '',
5541      'toolbar.wide': ''
5542    }
5543  }, drupalSettings.toolbar, {
5544    strings: {
5545      horizontal: Drupal.t('Horizontal orientation'),
5546      vertical: Drupal.t('Vertical orientation')
5547    }
5548  });
5549
5550  Drupal.behaviors.toolbar = {
5551    attach: function attach(context) {
5552      if (!window.matchMedia('only screen').matches) {
5553        return;
5554      }
5555
5556      $(context).find('#toolbar-administration').once('toolbar').each(function () {
5557        var model = Drupal.toolbar.models.toolbarModel = new Drupal.toolbar.ToolbarModel({
5558          locked: JSON.parse(localStorage.getItem('Drupal.toolbar.trayVerticalLocked')),
5559          activeTab: document.getElementById(JSON.parse(localStorage.getItem('Drupal.toolbar.activeTabID'))),
5560          height: $('#toolbar-administration').outerHeight()
5561        });
5562
5563        for (var label in options.breakpoints) {
5564          if (options.breakpoints.hasOwnProperty(label)) {
5565            var mq = options.breakpoints[label];
5566            var mql = Drupal.toolbar.mql[label] = window.matchMedia(mq);
5567
5568            mql.addListener(Drupal.toolbar.mediaQueryChangeHandler.bind(null, model, label));
5569
5570            Drupal.toolbar.mediaQueryChangeHandler.call(null, model, label, mql);
5571          }
5572        }
5573
5574        Drupal.toolbar.views.toolbarVisualView = new Drupal.toolbar.ToolbarVisualView({
5575          el: this,
5576          model: model,
5577          strings: options.strings
5578        });
5579        Drupal.toolbar.views.toolbarAuralView = new Drupal.toolbar.ToolbarAuralView({
5580          el: this,
5581          model: model,
5582          strings: options.strings
5583        });
5584        Drupal.toolbar.views.bodyVisualView = new Drupal.toolbar.BodyVisualView({
5585          el: this,
5586          model: model
5587        });
5588
5589        model.trigger('change:isFixed', model, model.get('isFixed'));
5590        model.trigger('change:activeTray', model, model.get('activeTray'));
5591
5592        var menuModel = Drupal.toolbar.models.menuModel = new Drupal.toolbar.MenuModel();
5593        Drupal.toolbar.views.menuVisualView = new Drupal.toolbar.MenuVisualView({
5594          el: $(this).find('.toolbar-menu-administration').get(0),
5595          model: menuModel,
5596          strings: options.strings
5597        });
5598
5599        Drupal.toolbar.setSubtrees.done(function (subtrees) {
5600          menuModel.set('subtrees', subtrees);
5601          var theme = drupalSettings.ajaxPageState.theme;
5602          localStorage.setItem('Drupal.toolbar.subtrees.' + theme, JSON.stringify(subtrees));
5603
5604          model.set('areSubtreesLoaded', true);
5605        });
5606
5607        Drupal.toolbar.views.toolbarVisualView.loadSubtrees();
5608
5609        $(document).on('drupalViewportOffsetChange.toolbar', function (event, offsets) {
5610          model.set('offsets', offsets);
5611        });
5612
5613        model.on('change:orientation', function (model, orientation) {
5614          $(document).trigger('drupalToolbarOrientationChange', orientation);
5615        }).on('change:activeTab', function (model, tab) {
5616          $(document).trigger('drupalToolbarTabChange', tab);
5617        }).on('change:activeTray', function (model, tray) {
5618          $(document).trigger('drupalToolbarTrayChange', tray);
5619        });
5620
5621        if (Drupal.toolbar.models.toolbarModel.get('orientation') === 'horizontal' && Drupal.toolbar.models.toolbarModel.get('activeTab') === null) {
5622          Drupal.toolbar.models.toolbarModel.set({
5623            activeTab: $('.toolbar-bar .toolbar-tab:not(.home-toolbar-tab) a').get(0)
5624          });
5625        }
5626      });
5627    }
5628  };
5629
5630  Drupal.toolbar = {
5631    views: {},
5632
5633    models: {},
5634
5635    mql: {},
5636
5637    setSubtrees: new $.Deferred(),
5638
5639    mediaQueryChangeHandler: function mediaQueryChangeHandler(model, label, mql) {
5640      switch (label) {
5641        case 'toolbar.narrow':
5642          model.set({
5643            isOriented: mql.matches,
5644            isTrayToggleVisible: false
5645          });
5646
5647          if (!mql.matches || !model.get('orientation')) {
5648            model.set({ orientation: 'vertical' }, { validate: true });
5649          }
5650          break;
5651
5652        case 'toolbar.standard':
5653          model.set({
5654            isFixed: mql.matches
5655          });
5656          break;
5657
5658        case 'toolbar.wide':
5659          model.set({
5660            orientation: mql.matches && !model.get('locked') ? 'horizontal' : 'vertical'
5661          }, { validate: true });
5662
5663          model.set({
5664            isTrayToggleVisible: mql.matches
5665          });
5666          break;
5667
5668        default:
5669          break;
5670      }
5671    }
5672  };
5673
5674  Drupal.theme.toolbarOrientationToggle = function () {
5675    return '<div class="toolbar-toggle-orientation"><div class="toolbar-lining">' + '<button class="toolbar-icon" type="button"></button>' + '</div></div>';
5676  };
5677
5678  Drupal.AjaxCommands.prototype.setToolbarSubtrees = function (ajax, response, status) {
5679    Drupal.toolbar.setSubtrees.resolve(response.subtrees);
5680  };
5681})(jQuery, Drupal, drupalSettings);;
5682/**
5683* DO NOT EDIT THIS FILE.
5684* See the following change record for more information,
5685* https://www.drupal.org/node/2815083
5686* @preserve
5687**/
5688
5689(function (Backbone, Drupal) {
5690  Drupal.toolbar.MenuModel = Backbone.Model.extend({
5691    defaults: {
5692      subtrees: {}
5693    }
5694  });
5695})(Backbone, Drupal);;
5696/**
5697* DO NOT EDIT THIS FILE.
5698* See the following change record for more information,
5699* https://www.drupal.org/node/2815083
5700* @preserve
5701**/
5702
5703(function (Backbone, Drupal) {
5704  Drupal.toolbar.ToolbarModel = Backbone.Model.extend({
5705    defaults: {
5706      activeTab: null,
5707
5708      activeTray: null,
5709
5710      isOriented: false,
5711
5712      isFixed: false,
5713
5714      areSubtreesLoaded: false,
5715
5716      isViewportOverflowConstrained: false,
5717
5718      orientation: 'horizontal',
5719
5720      locked: false,
5721
5722      isTrayToggleVisible: true,
5723
5724      height: null,
5725
5726      offsets: {
5727        top: 0,
5728        right: 0,
5729        bottom: 0,
5730        left: 0
5731      }
5732    },
5733
5734    validate: function validate(attributes, options) {
5735      if (attributes.orientation === 'horizontal' && this.get('locked') && !options.override) {
5736        return Drupal.t('The toolbar cannot be set to a horizontal orientation when it is locked.');
5737      }
5738    }
5739  });
5740})(Backbone, Drupal);;
5741/**
5742* DO NOT EDIT THIS FILE.
5743* See the following change record for more information,
5744* https://www.drupal.org/node/2815083
5745* @preserve
5746**/
5747
5748(function ($, Drupal, Backbone) {
5749  Drupal.toolbar.BodyVisualView = Backbone.View.extend({
5750    initialize: function initialize() {
5751      this.listenTo(this.model, 'change:activeTray ', this.render);
5752      this.listenTo(this.model, 'change:isFixed change:isViewportOverflowConstrained', this.isToolbarFixed);
5753    },
5754    isToolbarFixed: function isToolbarFixed() {
5755      var isViewportOverflowConstrained = this.model.get('isViewportOverflowConstrained');
5756      $('body').toggleClass('toolbar-fixed', isViewportOverflowConstrained || this.model.get('isFixed'));
5757    },
5758    render: function render() {
5759      $('body').toggleClass('toolbar-tray-open', !!this.model.get('activeTray'));
5760    }
5761  });
5762})(jQuery, Drupal, Backbone);;
5763/**
5764* DO NOT EDIT THIS FILE.
5765* See the following change record for more information,
5766* https://www.drupal.org/node/2815083
5767* @preserve
5768**/
5769
5770(function ($, Backbone, Drupal) {
5771  Drupal.toolbar.MenuVisualView = Backbone.View.extend({
5772    initialize: function initialize() {
5773      this.listenTo(this.model, 'change:subtrees', this.render);
5774    },
5775    render: function render() {
5776      var subtrees = this.model.get('subtrees');
5777
5778      for (var id in subtrees) {
5779        if (subtrees.hasOwnProperty(id)) {
5780          this.$el.find('#toolbar-link-' + id).once('toolbar-subtrees').after(subtrees[id]);
5781        }
5782      }
5783
5784      if ('drupalToolbarMenu' in $.fn) {
5785        this.$el.children('.toolbar-menu').drupalToolbarMenu();
5786      }
5787    }
5788  });
5789})(jQuery, Backbone, Drupal);;
5790/**
5791* DO NOT EDIT THIS FILE.
5792* See the following change record for more information,
5793* https://www.drupal.org/node/2815083
5794* @preserve
5795**/
5796
5797(function (Backbone, Drupal) {
5798  Drupal.toolbar.ToolbarAuralView = Backbone.View.extend({
5799    initialize: function initialize(options) {
5800      this.strings = options.strings;
5801
5802      this.listenTo(this.model, 'change:orientation', this.onOrientationChange);
5803      this.listenTo(this.model, 'change:activeTray', this.onActiveTrayChange);
5804    },
5805    onOrientationChange: function onOrientationChange(model, orientation) {
5806      Drupal.announce(Drupal.t('Tray orientation changed to @orientation.', {
5807        '@orientation': orientation
5808      }));
5809    },
5810    onActiveTrayChange: function onActiveTrayChange(model, tray) {
5811      var relevantTray = tray === null ? model.previous('activeTray') : tray;
5812
5813      if (!relevantTray) {
5814        return;
5815      }
5816      var action = tray === null ? Drupal.t('closed') : Drupal.t('opened');
5817      var trayNameElement = relevantTray.querySelector('.toolbar-tray-name');
5818      var text = void 0;
5819      if (trayNameElement !== null) {
5820        text = Drupal.t('Tray "@tray" @action.', {
5821          '@tray': trayNameElement.textContent, '@action': action
5822        });
5823      } else {
5824        text = Drupal.t('Tray @action.', { '@action': action });
5825      }
5826      Drupal.announce(text);
5827    }
5828  });
5829})(Backbone, Drupal);;
5830/**
5831* DO NOT EDIT THIS FILE.
5832* See the following change record for more information,
5833* https://www.drupal.org/node/2815083
5834* @preserve
5835**/
5836
5837(function ($, Drupal, drupalSettings, Backbone) {
5838  Drupal.toolbar.ToolbarVisualView = Backbone.View.extend({
5839    events: function events() {
5840      var touchEndToClick = function touchEndToClick(event) {
5841        event.preventDefault();
5842        event.target.click();
5843      };
5844
5845      return {
5846        'click .toolbar-bar .toolbar-tab .trigger': 'onTabClick',
5847        'click .toolbar-toggle-orientation button': 'onOrientationToggleClick',
5848        'touchend .toolbar-bar .toolbar-tab .trigger': touchEndToClick,
5849        'touchend .toolbar-toggle-orientation button': touchEndToClick
5850      };
5851    },
5852    initialize: function initialize(options) {
5853      this.strings = options.strings;
5854
5855      this.listenTo(this.model, 'change:activeTab change:orientation change:isOriented change:isTrayToggleVisible', this.render);
5856      this.listenTo(this.model, 'change:mqMatches', this.onMediaQueryChange);
5857      this.listenTo(this.model, 'change:offsets', this.adjustPlacement);
5858      this.listenTo(this.model, 'change:activeTab change:orientation change:isOriented', this.updateToolbarHeight);
5859
5860      this.$el.find('.toolbar-tray .toolbar-lining').append(Drupal.theme('toolbarOrientationToggle'));
5861
5862      this.model.trigger('change:activeTab');
5863    },
5864    updateToolbarHeight: function updateToolbarHeight() {
5865      var toolbarTabOuterHeight = $('#toolbar-bar').find('.toolbar-tab').outerHeight() || 0;
5866      var toolbarTrayHorizontalOuterHeight = $('.is-active.toolbar-tray-horizontal').outerHeight() || 0;
5867      this.model.set('height', toolbarTabOuterHeight + toolbarTrayHorizontalOuterHeight);
5868
5869      $('body').css({
5870        'padding-top': this.model.get('height')
5871      });
5872
5873      this.triggerDisplace();
5874    },
5875    triggerDisplace: function triggerDisplace() {
5876      _.defer(function () {
5877        Drupal.displace(true);
5878      });
5879    },
5880    render: function render() {
5881      this.updateTabs();
5882      this.updateTrayOrientation();
5883      this.updateBarAttributes();
5884
5885      $('body').removeClass('toolbar-loading');
5886
5887      if (this.model.changed.orientation === 'vertical' || this.model.changed.activeTab) {
5888        this.loadSubtrees();
5889      }
5890
5891      return this;
5892    },
5893    onTabClick: function onTabClick(event) {
5894      if (event.target.hasAttribute('data-toolbar-tray')) {
5895        var activeTab = this.model.get('activeTab');
5896        var clickedTab = event.target;
5897
5898        this.model.set('activeTab', !activeTab || clickedTab !== activeTab ? clickedTab : null);
5899
5900        event.preventDefault();
5901        event.stopPropagation();
5902      }
5903    },
5904    onOrientationToggleClick: function onOrientationToggleClick(event) {
5905      var orientation = this.model.get('orientation');
5906
5907      var antiOrientation = orientation === 'vertical' ? 'horizontal' : 'vertical';
5908      var locked = antiOrientation === 'vertical';
5909
5910      if (locked) {
5911        localStorage.setItem('Drupal.toolbar.trayVerticalLocked', 'true');
5912      } else {
5913        localStorage.removeItem('Drupal.toolbar.trayVerticalLocked');
5914      }
5915
5916      this.model.set({
5917        locked: locked,
5918        orientation: antiOrientation
5919      }, {
5920        validate: true,
5921        override: true
5922      });
5923
5924      event.preventDefault();
5925      event.stopPropagation();
5926    },
5927    updateTabs: function updateTabs() {
5928      var $tab = $(this.model.get('activeTab'));
5929
5930      $(this.model.previous('activeTab')).removeClass('is-active').prop('aria-pressed', false);
5931
5932      $(this.model.previous('activeTray')).removeClass('is-active');
5933
5934      if ($tab.length > 0) {
5935        $tab.addClass('is-active').prop('aria-pressed', true);
5936        var name = $tab.attr('data-toolbar-tray');
5937
5938        var id = $tab.get(0).id;
5939        if (id) {
5940          localStorage.setItem('Drupal.toolbar.activeTabID', JSON.stringify(id));
5941        }
5942
5943        var $tray = this.$el.find('[data-toolbar-tray="' + name + '"].toolbar-tray');
5944        if ($tray.length) {
5945          $tray.addClass('is-active');
5946          this.model.set('activeTray', $tray.get(0));
5947        } else {
5948          this.model.set('activeTray', null);
5949        }
5950      } else {
5951        this.model.set('activeTray', null);
5952        localStorage.removeItem('Drupal.toolbar.activeTabID');
5953      }
5954    },
5955    updateBarAttributes: function updateBarAttributes() {
5956      var isOriented = this.model.get('isOriented');
5957      if (isOriented) {
5958        this.$el.find('.toolbar-bar').attr('data-offset-top', '');
5959      } else {
5960        this.$el.find('.toolbar-bar').removeAttr('data-offset-top');
5961      }
5962
5963      this.$el.toggleClass('toolbar-oriented', isOriented);
5964    },
5965    updateTrayOrientation: function updateTrayOrientation() {
5966      var orientation = this.model.get('orientation');
5967
5968      var antiOrientation = orientation === 'vertical' ? 'horizontal' : 'vertical';
5969
5970      $('body').toggleClass('toolbar-vertical', orientation === 'vertical').toggleClass('toolbar-horizontal', orientation === 'horizontal');
5971
5972      var removeClass = antiOrientation === 'horizontal' ? 'toolbar-tray-horizontal' : 'toolbar-tray-vertical';
5973      var $trays = this.$el.find('.toolbar-tray').removeClass(removeClass).addClass('toolbar-tray-' + orientation);
5974
5975      var iconClass = 'toolbar-icon-toggle-' + orientation;
5976      var iconAntiClass = 'toolbar-icon-toggle-' + antiOrientation;
5977      var $orientationToggle = this.$el.find('.toolbar-toggle-orientation').toggle(this.model.get('isTrayToggleVisible'));
5978      $orientationToggle.find('button').val(antiOrientation).attr('title', this.strings[antiOrientation]).text(this.strings[antiOrientation]).removeClass(iconClass).addClass(iconAntiClass);
5979
5980      var dir = document.documentElement.dir;
5981      var edge = dir === 'rtl' ? 'right' : 'left';
5982
5983      $trays.removeAttr('data-offset-left data-offset-right data-offset-top');
5984
5985      $trays.filter('.toolbar-tray-vertical.is-active').attr('data-offset-' + edge, '');
5986
5987      $trays.filter('.toolbar-tray-horizontal.is-active').attr('data-offset-top', '');
5988    },
5989    adjustPlacement: function adjustPlacement() {
5990      var $trays = this.$el.find('.toolbar-tray');
5991      if (!this.model.get('isOriented')) {
5992        $trays.removeClass('toolbar-tray-horizontal').addClass('toolbar-tray-vertical');
5993      }
5994    },
5995    loadSubtrees: function loadSubtrees() {
5996      var $activeTab = $(this.model.get('activeTab'));
5997      var orientation = this.model.get('orientation');
5998
5999      if (!this.model.get('areSubtreesLoaded') && typeof $activeTab.data('drupal-subtrees') !== 'undefined' && orientation === 'vertical') {
6000        var subtreesHash = drupalSettings.toolbar.subtreesHash;
6001        var theme = drupalSettings.ajaxPageState.theme;
6002        var endpoint = Drupal.url('toolbar/subtrees/' + subtreesHash);
6003        var cachedSubtreesHash = localStorage.getItem('Drupal.toolbar.subtreesHash.' + theme);
6004        var cachedSubtrees = JSON.parse(localStorage.getItem('Drupal.toolbar.subtrees.' + theme));
6005        var isVertical = this.model.get('orientation') === 'vertical';
6006
6007        if (isVertical && subtreesHash === cachedSubtreesHash && cachedSubtrees) {
6008          Drupal.toolbar.setSubtrees.resolve(cachedSubtrees);
6009        } else if (isVertical) {
6010            localStorage.removeItem('Drupal.toolbar.subtreesHash.' + theme);
6011            localStorage.removeItem('Drupal.toolbar.subtrees.' + theme);
6012
6013            Drupal.ajax({ url: endpoint }).execute();
6014
6015            localStorage.setItem('Drupal.toolbar.subtreesHash.' + theme, subtreesHash);
6016          }
6017      }
6018    }
6019  });
6020})(jQuery, Drupal, drupalSettings, Backbone);;
6021/**
6022 * @file image_gallery.js
6023 *
6024 * Defines and runs the image gallery field
6025 *
6026 */
6027(function ($, Drupal, drupalSettings) {
6028  "use strict";
6029
6030  Drupal.newsGallery = [];
6031
6032  Drupal.behaviors.newsGallery = {
6033    attach: function(context) {
6034      $('#image-gallery').slick({
6035        arrows: true,
6036        fade: true,
6037        slidesToScroll: 1,
6038        slidesToShow: 1,
6039        dots: true,
6040        customPaging : function(slider, i) {
6041          var caption = $(slider.$slides[i]).data('caption');
6042          return '<div class="caption"><span>' + caption + '</span><span>' + (i + 1) + '/' + slider.slideCount + '</span></div>';
6043        },
6044        infinite: false
6045      });
6046    }
6047  };
6048
6049}(jQuery, Drupal, drupalSettings));
6050;
vendor: 7,034 bytes, lines 6051-6054
6051/*! sidr - v2.2.1 - 2016-02-17
6052 * http://www.berriart.com/sidr/
6053 * Copyright (c) 2013-2016 Alberto Varela; Licensed MIT */
6054!function(){"use strict";function a(a,b,c){var d=new o(b);switch(a){case"open":d.open(c);break;case"close":d.close(c);break;case"toggle":d.toggle(c);break;default:p.error("Method "+a+" does not exist on jQuery.sidr")}}function b(a){return"status"===a?h:s[a]?s[a].apply(this,Array.prototype.slice.call(arguments,1)):"function"!=typeof a&&"string"!=typeof a&&a?void q.error("Method "+a+" does not exist on jQuery.sidr"):s.toggle.apply(this,arguments)}function c(a,b){if("function"==typeof b.source){var c=b.source(name);a.html(c)}else if("string"==typeof b.source&&i.isUrl(b.source))u.get(b.source,function(b){a.html(b)});else if("string"==typeof b.source){var d="",e=b.source.split(",");if(u.each(e,function(a,b){d+='<div class="sidr-inner">'+u(b).html()+"</div>"}),b.renaming){var f=u("<div />").html(d);f.find("*").each(function(a,b){var c=u(b);i.addPrefixes(c)}),d=f.html()}a.html(d)}else null!==b.source&&u.error("Invalid Sidr Source");return a}function d(a){var d=i.transitions,e=u.extend({name:"sidr",speed:200,side:"left",source:null,renaming:!0,body:"body",displace:!0,timing:"ease",method:"toggle",bind:"touchstart click",onOpen:function(){},onClose:function(){},onOpenEnd:function(){},onCloseEnd:function(){}},a),f=e.name,g=u("#"+f);return 0===g.length&&(g=u("<div />").attr("id",f).appendTo(u("body"))),d.supported&&g.css(d.property,e.side+" "+e.speed/1e3+"s "+e.timing),g.addClass("sidr").addClass(e.side).data({speed:e.speed,side:e.side,body:e.body,displace:e.displace,timing:e.timing,method:e.method,onOpen:e.onOpen,onClose:e.onClose,onOpenEnd:e.onOpenEnd,onCloseEnd:e.onCloseEnd}),g=c(g,e),this.each(function(){var a=u(this),c=a.data("sidr"),d=!1;c||(h.moving=!1,h.opened=!1,a.data("sidr",f),a.bind(e.bind,function(a){a.preventDefault(),d||(d=!0,b(e.method,f),setTimeout(function(){d=!1},100))}))})}var e={};e.classCallCheck=function(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")},e.createClass=function(){function a(a,b){for(var c=0;c<b.length;c++){var d=b[c];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(a,d.key,d)}}return function(b,c,d){return c&&a(b.prototype,c),d&&a(b,d),b}}();var f,g,h={moving:!1,opened:!1},i={isUrl:function(a){var b=new RegExp("^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.?)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$","i");return b.test(a)?!0:!1},addPrefixes:function(a){this.addPrefix(a,"id"),this.addPrefix(a,"class"),a.removeAttr("style")},addPrefix:function(a,b){var c=a.attr(b);"string"==typeof c&&""!==c&&"sidr-inner"!==c&&a.attr(b,c.replace(/([A-Za-z0-9_.\-]+)/g,"sidr-"+b+"-$1"))},transitions:function(){var a=document.body||document.documentElement,b=a.style,c=!1,d="transition";return d in b?c=!0:!function(){var a=["moz","webkit","o","ms"],e=void 0,f=void 0;d=d.charAt(0).toUpperCase()+d.substr(1),c=function(){for(f=0;f<a.length;f++)if(e=a[f],e+d in b)return!0;return!1}(),d=c?"-"+e.toLowerCase()+"-"+d.toLowerCase():null}(),{supported:c,property:d}}()},j=jQuery,k="sidr-animating",l="open",m="close",n="webkitTransitionEnd otransitionend oTransitionEnd msTransitionEnd transitionend",o=function(){function a(b){e.classCallCheck(this,a),this.name=b,this.item=j("#"+b),this.openClass="sidr"===b?"sidr-open":"sidr-open "+b+"-open",this.menuWidth=this.item.outerWidth(!0),this.speed=this.item.data("speed"),this.side=this.item.data("side"),this.displace=this.item.data("displace"),this.timing=this.item.data("timing"),this.method=this.item.data("method"),this.onOpenCallback=this.item.data("onOpen"),this.onCloseCallback=this.item.data("onClose"),this.onOpenEndCallback=this.item.data("onOpenEnd"),this.onCloseEndCallback=this.item.data("onCloseEnd"),this.body=j(this.item.data("body"))}return e.createClass(a,[{key:"getAnimation",value:function(a,b){var c={},d=this.side;return"open"===a&&"body"===b?c[d]=this.menuWidth+"px":"close"===a&&"menu"===b?c[d]="-"+this.menuWidth+"px":c[d]=0,c}},{key:"prepareBody",value:function(a){var b="open"===a?"hidden":"";if(this.body.is("body")){var c=j("html"),d=c.scrollTop();c.css("overflow-x",b).scrollTop(d)}}},{key:"openBody",value:function(){if(this.displace){var a=i.transitions,b=this.body;if(a.supported)b.css(a.property,this.side+" "+this.speed/1e3+"s "+this.timing).css(this.side,0).css({width:b.width(),position:"absolute"}),b.css(this.side,this.menuWidth+"px");else{var c=this.getAnimation(l,"body");b.css({width:b.width(),position:"absolute"}).animate(c,{queue:!1,duration:this.speed})}}}},{key:"onCloseBody",value:function(){var a=i.transitions,b={width:"",position:"",right:"",left:""};a.supported&&(b[a.property]=""),this.body.css(b).unbind(n)}},{key:"closeBody",value:function(){var a=this;if(this.displace)if(i.transitions.supported)this.body.css(this.side,0).one(n,function(){a.onCloseBody()});else{var b=this.getAnimation(m,"body");this.body.animate(b,{queue:!1,duration:this.speed,complete:function(){a.onCloseBody()}})}}},{key:"moveBody",value:function(a){a===l?this.openBody():this.closeBody()}},{key:"onOpenMenu",value:function(a){var b=this.name;h.moving=!1,h.opened=b,this.item.unbind(n),this.body.removeClass(k).addClass(this.openClass),this.onOpenEndCallback(),"function"==typeof a&&a(b)}},{key:"openMenu",value:function(a){var b=this,c=this.item;if(i.transitions.supported)c.css(this.side,0).one(n,function(){b.onOpenMenu(a)});else{var d=this.getAnimation(l,"menu");c.css("display","block").animate(d,{queue:!1,duration:this.speed,complete:function(){b.onOpenMenu(a)}})}}},{key:"onCloseMenu",value:function(a){this.item.css({left:"",right:""}).unbind(n),j("html").css("overflow-x",""),h.moving=!1,h.opened=!1,this.body.removeClass(k).removeClass(this.openClass),this.onCloseEndCallback(),"function"==typeof a&&a(name)}},{key:"closeMenu",value:function(a){var b=this,c=this.item;if(i.transitions.supported)c.css(this.side,"").one(n,function(){b.onCloseMenu(a)});else{var d=this.getAnimation(m,"menu");c.animate(d,{queue:!1,duration:this.speed,complete:function(){b.onCloseMenu()}})}}},{key:"moveMenu",value:function(a,b){this.body.addClass(k),a===l?this.openMenu(b):this.closeMenu(b)}},{key:"move",value:function(a,b){h.moving=!0,this.prepareBody(a),this.moveBody(a),this.moveMenu(a,b)}},{key:"open",value:function(b){var c=this;if(h.opened!==this.name&&!h.moving){if(h.opened!==!1){var d=new a(h.opened);return void d.close(function(){c.open(b)})}this.move("open",b),this.onOpenCallback()}}},{key:"close",value:function(a){h.opened!==this.name||h.moving||(this.move("close",a),this.onCloseCallback())}},{key:"toggle",value:function(a){h.opened===this.name?this.close(a):this.open(a)}}]),a}(),p=jQuery,q=jQuery,r=["open","close","toggle"],s={},t=function(b){return function(c,d){"function"==typeof c?(d=c,c="sidr"):c||(c="sidr"),a(b,c,d)}};for(f=0;f<r.length;f++)g=r[f],s[g]=t(g);var u=jQuery;jQuery.sidr=b,jQuery.fn.sidr=d}();
6054
6055;
6056/**
6057 * Thanks Paul Irish!
6058 *   http://www.paulirish.com/2009/throttled-smartresize-jquery-event-handler/
6059 *
6060 * Additions by JS:
6061 *
6062 *   - Add namespace option,
6063 *   - Add smartresizeunbind,
6064 *   - Support orientationchange event too (for iPad amongst others).
6065 *   - Add sanity infinite looping checking (needed for IE8).
6066 */
6067(function($,sr, srunbind){
6068
6069  // debouncing function from John Hann
6070  // http://unscriptable.com/index.php/2009/03/20/debouncing-javascript-methods/
6071  var debounce = function (func, threshold, execAsap) {
6072    var timeout;
6073
6074    return function debounced () {
6075      var obj = this, args = arguments;
6076      function delayed () {
6077        if (!execAsap) {
6078          func.apply(obj, args);
6079        }
6080        timeout = null;
6081      }
6082
6083      if (timeout) {
6084        clearTimeout(timeout);
6085      }
6086      else if (execAsap) {
6087        func.apply(obj, args);
6088      }
6089
6090      timeout = setTimeout(delayed, threshold || 200);
6091    };
6092  };
6093
6094  // Only run a certain callback.
6095  var oncepersizechange = function(fn) {
6096
6097    var lastdims;
6098
6099    return function(e) {
6100      var $el = $(this),
6101          $body = $('body').first();
6102      if (lastdims) {
6103        // Skip if we've already been run under exactly identical dimensions.
6104        // Test dimensions of the body *and* the element we're attached to.
6105        if ((lastdims.body.w === $body.width()) && (lastdims.body.h === $body.height())) {
6106          if (!($el && $el.width && $el.height) || ((lastdims.w === $el.width()) && (lastdims.h === $el.height()))) {
6107            return;
6108          }
6109        }
6110      }
6111      lastdims = {
6112        w: $el.width(),
6113        h: $el.height(),
6114        body: {
6115          w: $body.width(),
6116          h: $body.height()
6117        }
6118      };
6119      return fn.apply(this, Array.prototype.slice.call(arguments));
6120    };
6121
6122  };
6123
6124  // smartresize
6125  jQuery.fn[sr] = function(fn, namespace) {
6126    namespace = namespace ? ('.' + namespace) : '';
6127    return fn ? this.bind('resize' + namespace + ' orientationchange' + namespace, debounce(oncepersizechange(fn))) : this.trigger(sr);
6128  };
6129  // smartresizeunbind
6130  jQuery.fn[srunbind] = function(namespace) {
6131    namespace = namespace ? ('.' + namespace) : '';
6132    if (namespace.length) {
6133      return this.unbind('resize' + namespace + ' orientationchange' + namespace);
6134    }
6135    return false;
6136  };
6137
6138})(jQuery,'smartresize', 'smartresizeunbind');
6139;
6140(function($) {
6141    Drupal.behaviors.foundation = {
6142        attach: function (context, settings) {
6143            $("[data-reveal]").bind('init.zf.reveal', function (e) {
6144              // Wrap elements using Reveal plugin in container.
6145                $(e.target).data('zfPlugin').$overlay.find('.reveal').wrap('<div class="l-content-grid-container"></div>');
6146            });
6147
6148            $(document).foundation();
6149        }
6150    };
6151})(jQuery);
6152;
6153var niquesa = niquesa || {};
6154
6155(function($) {
6156  niquesa.breakpoints = niquesa.breakpoints || {};
6157  var small_query = '(max-width: 800px)';
6158  var large_query = '(min-width: 800px)';
6159  niquesa.breakpoints.in_small_layout = window.matchMedia(small_query).matches;
6160  niquesa.breakpoints.in_large_layout = window.matchMedia(large_query).matches;
6161
6162  $(window).smartresize(function () {
6163    var prev_small = niquesa.breakpoints.in_small_layout;
6164    var updated_small = window.matchMedia(small_query).matches;
6165    niquesa.breakpoints.in_small_layout = updated_small;
6166
6167    var prev_large = niquesa.breakpoints.in_large_layout;
6168    var updated_large = window.matchMedia(large_query).matches;
6169    niquesa.breakpoints.in_large_layout = updated_large;
6170
6171    if (prev_small != updated_small || prev_large != updated_large) {
6172      // @TODO Either supply an indication of what changed, or change binding
6173      // code to check what changed.
6174      $(window).trigger('niquesa_layout_change');
6175    }
6176  });
6177})(jQuery);
6178;
6179(function($) {
6180  Drupal.behaviors.sidr = {
6181    attach: function (context, settings) {
6182      var $trigger = $('#mobile-menu-trigger');
6183      if (!$trigger.hasClass('mobile-menu-sidr-processed')) {
6184        $trigger.sidr({
6185          name: 'sidr',
6186          side: 'right'
6187        });
6188
6189        // Close the menu on resize to avoid weirdness on rotating.
6190        $(window).resize(function () {
6191          $.sidr('close', 'sidr');
6192        });
6193
6194        $(window).click(function (e) {
6195          // If any element other than those inside the mobile menu are clicked,
6196          // then close the menu.
6197          if (!($(e.target).closest('#sidr').length)) {
6198            $.sidr('close', 'sidr');
6199          }
6200        });
6201
6202        $trigger.addClass('mobile-menu-sidr-processed');
6203      }
6204    }
6205  };
6206})(jQuery);
6207;
6208/**
6209 * @file collapse.js
6210 */
6211
6212var niquesa = niquesa || {};
6213
6214(function ($, Drupal, drupalSettings) {
6215  "use strict";
6216
6217  var mobile_collapse = function () {
6218    var width = niquesa.breakpoints.in_small_layout ? 'narrow' : 'wide';
6219    $('.collapsible').each(function () {
6220      var $this_collapsible = $(this);
6221
6222      if (width == 'wide') {
6223        $this_collapsible.parent().find('.collapsible-content').show();
6224        $this_collapsible.find('.collapsible-title').off('click', collapsible_title_handler).removeClass('expanded');
6225        $this_collapsible.find('.close-this').off('click', collapsible_close_handler).toggleClass('hide', true);
6226
6227        reinit_galleries($this_collapsible.find('#image-gallery'));
6228      }
6229      else {
6230        $this_collapsible.parent().find('.collapsible-content').hide();
6231
6232        $this_collapsible.find('.collapsible-title').on('click', collapsible_title_handler);
6233        $this_collapsible.find('.close-this').on('click', collapsible_close_handler);
6234      }
6235    });
6236  };
6237
6238  /**
6239   * Re-initialize gallery when its visibility changes. Doing so seems to re-add
6240   * the 'dots' (thumnails) though, even if they are already present, so remove
6241   * those first.
6242   */
6243  var reinit_galleries = function ($galleries) {
6244    if ($galleries.length) {
6245      $('.slick-dots', $galleries).remove();
6246      $galleries.slick('reinit');
6247    }
6248  };
6249
6250  var collapsible_title_handler = function () {
6251    var $title_parent = $(this).parent();
6252    $title_parent.find('.collapsible-title').toggleClass('expanded');
6253
6254    var $collapsible_content = $title_parent.find('.collapsible-content');
6255    $collapsible_content.toggleClass('expanded');
6256    $collapsible_content.slideToggle('slow');
6257
6258    $title_parent.find('.close-this').toggleClass('hide');
6259
6260    // Only reinit gallery on opening the collapsible gallery pane.
6261    if ($collapsible_content.hasClass('expanded')) {
6262      reinit_galleries($title_parent.find('#image-gallery'));
6263    }
6264  };
6265
6266  var collapsible_close_handler = function () {
6267    var $close = $(this);
6268    var $close_parent = $close.parent();
6269    $close_parent.find('.collapsible-content').slideToggle('slow');
6270    $close.toggleClass('hide');
6271    $close_parent.find('.collapsible-title').toggleClass('expanded');
6272  };
6273
6274  /**
6275   * Behaviors for mobile collapse.
6276   */
6277  Drupal.behaviors.mobileCollapse = {
6278    attach: function (context) {
6279      $('body').once('mobile-collapse').each(function () {
6280        mobile_collapse();
6281        $(window).on('niquesa_layout_change', mobile_collapse);
6282      });
6283    }
6284  };
6285
6286}(jQuery, Drupal, drupalSettings));
6287;
6288/*! ScrollMagic v2.0.5 | (c) 2015 Jan Paepke (@janpaepke) | license & info: http://scrollmagic.io */
6289!function(e,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():e.ScrollMagic=t()}(this,function(){"use strict";var e=function(){};e.version="2.0.5",window.addEventListener("mousewheel",function(){});var t="data-scrollmagic-pin-spacer";e.Controller=function(r){var o,s,a="ScrollMagic.Controller",l="FORWARD",c="REVERSE",u="PAUSED",f=n.defaults,d=this,h=i.extend({},f,r),g=[],p=!1,v=0,m=u,w=!0,y=0,S=!0,b=function(){for(var e in h)f.hasOwnProperty(e)||delete h[e];if(h.container=i.get.elements(h.container)[0],!h.container)throw a+" init failed.";w=h.container===window||h.container===document.body||!document.body.contains(h.container),w&&(h.container=window),y=z(),h.container.addEventListener("resize",T),h.container.addEventListener("scroll",T),h.refreshInterval=parseInt(h.refreshInterval)||f.refreshInterval,E()},E=function(){h.refreshInterval>0&&(s=window.setTimeout(A,h.refreshInterval))},x=function(){return h.vertical?i.get.scrollTop(h.container):i.get.scrollLeft(h.container)},z=function(){return h.vertical?i.get.height(h.container):i.get.width(h.container)},C=this._setScrollPos=function(e){h.vertical?w?window.scrollTo(i.get.scrollLeft(),e):h.container.scrollTop=e:w?window.scrollTo(e,i.get.scrollTop()):h.container.scrollLeft=e},F=function(){if(S&&p){var e=i.type.Array(p)?p:g.slice(0);p=!1;var t=v;v=d.scrollPos();var n=v-t;0!==n&&(m=n>0?l:c),m===c&&e.reverse(),e.forEach(function(e){e.update(!0)})}},L=function(){o=i.rAF(F)},T=function(e){"resize"==e.type&&(y=z(),m=u),p!==!0&&(p=!0,L())},A=function(){if(!w&&y!=z()){var e;try{e=new Event("resize",{bubbles:!1,cancelable:!1})}catch(t){e=document.createEvent("Event"),e.initEvent("resize",!1,!1)}
6289h.container.dispatchEvent(e)}g.forEach(function(e){e.refresh()}),E()};this._options=h;var O=function(e){if(e.length<=1)return e;var t=e.slice(0);return t.sort(function(e,t){return e.scrollOffset()>t.scrollOffset()?1:-1}),t};return this.addScene=function(t){if(i.type.Array(t))t.forEach(function(e){d.addScene(e)});else if(t instanceof e.Scene)if(t.controller()!==d)t.addTo(d);else if(g.indexOf(t)<0){g.push(t),g=O(g),t.on("shift.controller_sort",function(){g=O(g)});for(var n in h.globalSceneOptions)t[n]&&t[n].call(t,h.globalSceneOptions[n])}return d},this.removeScene=function(e){if(i.type.Array(e))e.forEach(function(e){d.removeScene(e)});else{var t=g.indexOf(e);t>-1&&(e.off("shift.controller_sort"),g.splice(t,1),e.remove())}return d},this.updateScene=function(t,n){return i.type.Array(t)?t.forEach(function(e){d.updateScene(e,n)}):n?t.update(!0):p!==!0&&t instanceof e.Scene&&(p=p||[],-1==p.indexOf(t)&&p.push(t),p=O(p),L()),d},this.update=function(e){return T({type:"resize"}),e&&F(),d},this.scrollTo=function(n,r){if(i.type.Number(n))C.call(h.container,n,r);else if(n instanceof e.Scene)n.controller()===d&&d.scrollTo(n.scrollOffset(),r);else if(i.type.Function(n))C=n;else{var o=i.get.elements(n)[0];if(o){for(;o.parentNode.hasAttribute(t);)o=o.parentNode;var s=h.vertical?"top":"left",a=i.get.offset(h.container),l=i.get.offset(o);w||(a[s]-=d.scrollPos()),d.scrollTo(l[s]-a[s],r)}}return d},this.scrollPos=function(e){return arguments.length?(i.type.Function(e)&&(x=e),d):x.call(d)},this.info=function(e){var t={size:y,vertical:h.vertical,scrollPos:v,scrollDirection:m,container:h.container,isDocument:w};return arguments.length?void 0!==t[e]?t[e]:void 0:t},this.loglevel=function(){return d},this.enabled=function(e){return arguments.length?(S!=e&&(S=!!e,d.updateScene(g,!0)),d):S},this.destroy=function(e){window.clearTimeout(s);for(var t=g.length;t--;)g[t].destroy(e);return h.container.removeEventListener("resize",T),h.container.removeEventListener("scroll",T),i.cAF(o),null},b(),d};var n={defaults:{container:window,vertical:!0,globalSceneOptions:{},loglevel:2,refreshInterval:100}};e.Controller.addOption=function(e,t){n.defaults[e]=t},e.Controller.extend=function(t){var n=this;e.Controller=function(){return n.apply(this,arguments),this.$super=i.extend({},this),t.apply(this,arguments)||this},i.extend(e.Controller,n),e.Controller.prototype=n.prototype,e.Controller.prototype.constructor=e.Controller},e.Scene=function(n){var o,s,a="BEFORE",l="DURING",c="AFTER",u=r.defaults,f=this,d=i.extend({},u,n),h=a,g=0,p={start:0,end:0},v=0,m=!0,w=function(){for(var e in d)u.hasOwnProperty(e)||delete d[e];for(var t in u)L(t);C()},y={};this.on=function(e,t){return i.type.Function(t)&&(e=e.trim().split(" "),e.forEach(function(e){var n=e.split("."),r=n[0],i=n[1];"*"!=r&&(y[r]||(y[r]=[]),y[r].push({namespace:i||"",callback:t}))})),f},this.off=function(e,t){return e?(e=e.trim().split(" "),e.forEach(function(e){var n=e.split("."),r=n[0],i=n[1]||"",o="*"===r?Object.keys(y):[r];o.forEach(function(e){for(var n=y[e]||[],r=n.length;r--;){var o=n[r];!o||i!==o.namespace&&"*"!==i||t&&t!=o.callback||n.splice(r,1)}n.length||delete y[e]})}),f):f},this.trigger=function(t,n){if(t){var r=t.trim().split("."),i=r[0],o=r[1],s=y[i];s&&s.forEach(function(t){o&&o!==t.namespace||t.callback.call(f,new e.Event(i,t.namespace,f,n))})}return f},f.on("change.internal",function(e){"loglevel"!==e.what&&"tweenChanges"!==e.what&&("triggerElement"===e.what?E():"reverse"===e.what&&f.update())}).on("shift.internal",function(){S(),f.update()}),this.addTo=function(t){return t instanceof e.Controller&&s!=t&&(s&&s.removeScene(f),s=t,C(),b(!0),E(!0),S(),s.info("container").addEventListener("resize",x),t.addScene(f),f.trigger("add",{controller:s}),f.update()),f},this.enabled=function(e){return arguments.length?(m!=e&&(m=!!e,f.update(!0)),f):m},this.remove=function(){if(s){s.info("container").removeEventListener("resize",x);var e=s;s=void 0,e.removeScene(f),f.trigger("remove")}return f},this.destroy=function(e){return f.trigger("destroy",{reset:e}),f.remove(),f.off("*.*"),null},this.update=function(e){if(s)if(e)if(s.enabled()&&m){var t,n=s.info("scrollPos");t=d.duration>0?(n-p.start)/(p.end-p.start):n>=p.start?1:0,f.trigger("update",{startPos:p.start,endPos:p.end,scrollPos:n}),f.progress(t)}else T&&h===l&&O(!0);else s.updateScene(f,!1);return f},this.refresh=function(){return b(),E(),f},this.progress=function(e){if(arguments.length){var t=!1,n=h,r=s?s.info("scrollDirection"):"PAUSED",i=d.reverse||e>=g;if(0===d.duration?(t=g!=e,g=1>e&&i?0:1,h=0===g?a:l):0>e&&h!==a&&i?(g=0,h=a,t=!0):e>=0&&1>e&&i?(g=e,h=l,t=!0):e>=1&&h!==c?(g=1,h=c,t=!0):h!==l||i||O(),t){var o={progress:g,state:h,scrollDirection:r},u=h!=n,p=function(e){f.trigger(e,o)};u&&n!==l&&(p("enter"),p(n===a?"start":"end")),p("progress"),u&&h!==l&&(p(h===a?"start":"end"),p("leave"))}return f}return g};var S=function(){p={start:v+d.offset},s&&d.triggerElement&&(p.start-=s.info("size")*d.triggerHook),p.end=p.start+d.duration},b=function(e){if(o){var t="duration";F(t,o.call(f))&&!e&&(f.trigger("change",{what:t,newval:d[t]}),f.trigger("shift",{reason:t}))}},E=function(e){var n=0,r=d.triggerElement;if(s&&r){for(var o=s.info(),a=i.get.offset(o.container),l=o.vertical?"top":"left";r.parentNode.hasAttribute(t);)r=r.parentNode;var c=i.get.offset(r);o.isDocument||(a[l]-=s.scrollPos()),n=c[l]-a[l]}var u=n!=v;v=n,u&&!e&&f.trigger("shift",{reason:"triggerElementPosition"})},x=function(){d.triggerHook>0&&f.trigger("shift",{reason:"containerResize"})},z=i.extend(r.validate,{duration:function(e){if(i.type.String(e)&&e.match(/^(\.|\d)*\d+%$/)){var t=parseFloat(e)/100;e=function(){return s?s.info("size")*t:0}}if(i.type.Function(e)){o=e;try{e=parseFloat(o())}catch(n){e=-1}}if(e=parseFloat(e),!i.type.Number(e)||0>e)throw o?(o=void 0,0):0;return e}}),C=function(e){e=arguments.length?[e]:Object.keys(z),e.forEach(function(e){var t;if(z[e])try{t=z[e](d[e])}catch(n){t=u[e]}finally{d[e]=t}})},F=function(e,t){var n=!1,r=d[e];return d[e]!=t&&(d[e]=t,C(e),n=r!=d[e]),n},L=function(e){f[e]||(f[e]=function(t){return arguments.length?("duration"===e&&(o=void 0),F(e,t)&&(f.trigger("change",{what:e,newval:d[e]}),r.shifts.indexOf(e)>-1&&f.trigger("shift",{reason:e})),f):d[e]})};this.controller=function(){return s},this.state=function(){return h},this.scrollOffset=function(){return p.start},this.triggerPosition=function(){var e=d.offset;return s&&(e+=d.triggerElement?v:s.info("size")*f.triggerHook()),e};var T,A;f.on("shift.internal",function(e){var t="duration"===e.reason;(h===c&&t||h===l&&0===d.duration)&&O(),t&&_()}).on("progress.internal",function(){O()}).on("add.internal",function(){_()}).on("destroy.internal",function(e){f.removePin(e.reset)});var O=function(e){if(T&&s){var t=s.info(),n=A.spacer.firstChild;if(e||h!==l){var r={position:A.inFlow?"relative":"absolute",top:0,left:0},o=i.css(n,"position")!=r.position;A.pushFollowers?d.duration>0&&(h===c&&0===parseFloat(i.css(A.spacer,"padding-top"))?o=!0:h===a&&0===parseFloat(i.css(A.spacer,"padding-bottom"))&&(o=!0)):r[t.vertical?"top":"left"]=d.duration*g,i.css(n,r),o&&_()}else{"fixed"!=i.css(n,"position")&&(i.css(n,{position:"fixed"}),_());var u=i.get.offset(A.spacer,!0),f=d.reverse||0===d.duration?t.scrollPos-p.start:Math.round(g*d.duration*10)/10;u[t.vertical?"top":"left"]+=f,i.css(A.spacer.firstChild,{top:u.top,left
6289:u.left})}}},_=function(){if(T&&s&&A.inFlow){var e=h===l,t=s.info("vertical"),n=A.spacer.firstChild,r=i.isMarginCollapseType(i.css(A.spacer,"display")),o={};A.relSize.width||A.relSize.autoFullWidth?e?i.css(T,{width:i.get.width(A.spacer)}):i.css(T,{width:"100%"}):(o["min-width"]=i.get.width(t?T:n,!0,!0),o.width=e?o["min-width"]:"auto"),A.relSize.height?e?i.css(T,{height:i.get.height(A.spacer)-(A.pushFollowers?d.duration:0)}):i.css(T,{height:"100%"}):(o["min-height"]=i.get.height(t?n:T,!0,!r),o.height=e?o["min-height"]:"auto"),A.pushFollowers&&(o["padding"+(t?"Top":"Left")]=d.duration*g,o["padding"+(t?"Bottom":"Right")]=d.duration*(1-g)),i.css(A.spacer,o)}},N=function(){s&&T&&h===l&&!s.info("isDocument")&&O()},P=function(){s&&T&&h===l&&((A.relSize.width||A.relSize.autoFullWidth)&&i.get.width(window)!=i.get.width(A.spacer.parentNode)||A.relSize.height&&i.get.height(window)!=i.get.height(A.spacer.parentNode))&&_()},D=function(e){s&&T&&h===l&&!s.info("isDocument")&&(e.preventDefault(),s._setScrollPos(s.info("scrollPos")-((e.wheelDelta||e[s.info("vertical")?"wheelDeltaY":"wheelDeltaX"])/3||30*-e.detail)))};this.setPin=function(e,n){var r={pushFollowers:!0,spacerClass:"scrollmagic-pin-spacer"};if(n=i.extend({},r,n),e=i.get.elements(e)[0],!e)return f;if("fixed"===i.css(e,"position"))return f;if(T){if(T===e)return f;f.removePin()}T=e;var o=T.parentNode.style.display,s=["top","left","bottom","right","margin","marginLeft","marginRight","marginTop","marginBottom"];T.parentNode.style.display="none";var a="absolute"!=i.css(T,"position"),l=i.css(T,s.concat(["display"])),c=i.css(T,["width","height"]);T.parentNode.style.display=o,!a&&n.pushFollowers&&(n.pushFollowers=!1);var u=T.parentNode.insertBefore(document.createElement("div"),T),d=i.extend(l,{position:a?"relative":"absolute",boxSizing:"content-box",mozBoxSizing:"content-box",webkitBoxSizing:"content-box"});if(a||i.extend(d,i.css(T,["width","height"])),i.css(u,d),u.setAttribute(t,""),i.addClass(u,n.spacerClass),A={spacer:u,relSize:{width:"%"===c.width.slice(-1),height:"%"===c.height.slice(-1),autoFullWidth:"auto"===c.width&&a&&i.isMarginCollapseType(l.display)},pushFollowers:n.pushFollowers,inFlow:a},!T.___origStyle){T.___origStyle={};var h=T.style,g=s.concat(["width","height","position","boxSizing","mozBoxSizing","webkitBoxSizing"]);g.forEach(function(e){T.___origStyle[e]=h[e]||""})}return A.relSize.width&&i.css(u,{width:c.width}),A.relSize.height&&i.css(u,{height:c.height}),u.appendChild(T),i.css(T,{position:a?"relative":"absolute",margin:"auto",top:"auto",left:"auto",bottom:"auto",right:"auto"}),(A.relSize.width||A.relSize.autoFullWidth)&&i.css(T,{boxSizing:"border-box",mozBoxSizing:"border-box",webkitBoxSizing:"border-box"}),window.addEventListener("scroll",N),window.addEventListener("resize",N),window.addEventListener("resize",P),T.addEventListener("mousewheel",D),T.addEventListener("DOMMouseScroll",D),O(),f},this.removePin=function(e){if(T){if(h===l&&O(!0),e||!s){var n=A.spacer.firstChild;if(n.hasAttribute(t)){var r=A.spacer.style,o=["margin","marginLeft","marginRight","marginTop","marginBottom"];margins={},o.forEach(function(e){margins[e]=r[e]||""}),i.css(n,margins)}A.spacer.parentNode.insertBefore(n,A.spacer),A.spacer.parentNode.removeChild(A.spacer),T.parentNode.hasAttribute(t)||(i.css(T,T.___origStyle),delete T.___origStyle)}window.removeEventListener("scroll",N),window.removeEventListener("resize",N),window.removeEventListener("resize",P),T.removeEventListener("mousewheel",D),T.removeEventListener("DOMMouseScroll",D),T=void 0}return f};var R,k=[];return f.on("destroy.internal",function(e){f.removeClassToggle(e.reset)}),this.setClassToggle=function(e,t){var n=i.get.elements(e);return 0!==n.length&&i.type.String(t)?(k.length>0&&f.removeClassToggle(),R=t,k=n,f.on("enter.internal_class leave.internal_class",function(e){var t="enter"===e.type?i.addClass:i.removeClass;k.forEach(function(e){t(e,R)})}),f):f},this.removeClassToggle=function(e){return e&&k.forEach(function(e){i.removeClass(e,R)}),f.off("start.internal_class end.internal_class"),R=void 0,k=[],f},w(),f};var r={defaults:{duration:0,offset:0,triggerElement:void 0,triggerHook:.5,reverse:!0,loglevel:2},validate:{offset:function(e){if(e=parseFloat(e),!i.type.Number(e))throw 0;return e},triggerElement:function(e){if(e=e||void 0){var t=i.get.elements(e)[0];if(!t)throw 0;e=t}return e},triggerHook:function(e){var t={onCenter:.5,onEnter:1,onLeave:0};if(i.type.Number(e))e=Math.max(0,Math.min(parseFloat(e),1));else{if(!(e in t))throw 0;e=t[e]}return e},reverse:function(e){return!!e}},shifts:["duration","offset","triggerHook"]};e.Scene.addOption=function(e,t,n,i){e in r.defaults||(r.defaults[e]=t,r.validate[e]=n,i&&r.shifts.push(e))},e.Scene.extend=function(t){var n=this;e.Scene=function(){return n.apply(this,arguments),this.$super=i.extend({},this),t.apply(this,arguments)||this},i.extend(e.Scene,n),e.Scene.prototype=n.prototype,e.Scene.prototype.constructor=e.Scene},e.Event=function(e,t,n,r){r=r||{};for(var i in r)this[i]=r[i];return this.type=e,this.target=this.currentTarget=n,this.namespace=t||"",this.timeStamp=this.timestamp=Date.now(),this};var i=e._util=function(e){var t,n={},r=function(e){return parseFloat(e)||0},i=function(t){return t.currentStyle?t.currentStyle:e.getComputedStyle(t)}
6289,o=function(t,n,o,s){if(n=n===document?e:n,n===e)s=!1;else if(!f.DomElement(n))return 0;t=t.charAt(0).toUpperCase()+t.substr(1).toLowerCase();var a=(o?n["offset"+t]||n["outer"+t]:n["client"+t]||n["inner"+t])||0;if(o&&s){var l=i(n);a+="Height"===t?r(l.marginTop)+r(l.marginBottom):r(l.marginLeft)+r(l.marginRight)}return a},s=function(e){return e.replace(/^[^a-z]+([a-z])/g,"$1").replace(/-([a-z])/g,function(e){return e[1].toUpperCase()})};n.extend=function(e){for(e=e||{},t=1;t<arguments.length;t++)if(arguments[t])for(var n in arguments[t])arguments[t].hasOwnProperty(n)&&(e[n]=arguments[t][n]);return e},n.isMarginCollapseType=function(e){return["block","flex","list-item","table","-webkit-box"].indexOf(e)>-1};var a=0,l=["ms","moz","webkit","o"],c=e.requestAnimationFrame,u=e.cancelAnimationFrame;for(t=0;!c&&t<l.length;++t)c=e[l[t]+"RequestAnimationFrame"],u=e[l[t]+"CancelAnimationFrame"]||e[l[t]+"CancelRequestAnimationFrame"];c||(c=function(t){var n=(new Date).getTime(),r=Math.max(0,16-(n-a)),i=e.setTimeout(function(){t(n+r)},r);return a=n+r,i}),u||(u=function(t){e.clearTimeout(t)}),n.rAF=c.bind(e),n.cAF=u.bind(e);var f=n.type=function(e){return Object.prototype.toString.call(e).replace(/^\[object (.+)\]$/,"$1").toLowerCase()};f.String=function(e){return"string"===f(e)},f.Function=function(e){return"function"===f(e)},f.Array=function(e){return Array.isArray(e)},f.Number=function(e){return!f.Array(e)&&e-parseFloat(e)+1>=0},f.DomElement=function(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&null!==e&&1===e.nodeType&&"string"==typeof e.nodeName};var d=n.get={};return d.elements=function(t){var n=[];if(f.String(t))try{t=document.querySelectorAll(t)}catch(r){return n}if("nodelist"===f(t)||f.Array(t))for(var i=0,o=n.length=t.length;o>i;i++){var s=t[i];n[i]=f.DomElement(s)?s:d.elements(s)}else(f.DomElement(t)||t===document||t===e)&&(n=[t]);return n},d.scrollTop=function(t){return t&&"number"==typeof t.scrollTop?t.scrollTop:e.pageYOffset||0},d.scrollLeft=function(t){return t&&"number"==typeof t.scrollLeft?t.scrollLeft:e.pageXOffset||0},d.width=function(e,t,n){return o("width",e,t,n)},d.height=function(e,t,n){return o("height",e,t,n)},d.offset=function(e,t){var n={top:0,left:0};if(e&&e.getBoundingClientRect){var r=e.getBoundingClientRect();n.top=r.top,n.left=r.left,t||(n.top+=d.scrollTop(),n.left+=d.scrollLeft())}return n},n.addClass=function(e,t){t&&(e.classList?e.classList.add(t):e.className+=" "+t)},n.removeClass=function(e,t){t&&(e.classList?e.classList.remove(t):e.className=e.className.replace(RegExp("(^|\\b)"+t.split(" ").join("|")+"(\\b|$)","gi")," "))},n.css=function(e,t){if(f.String(t))return i(e)[s(t)];if(f.Array(t)){var n={},r=i(e);return t.forEach(function(e){n[e]=r[s(e)]}),n}for(var o in t){var a=t[o];a==parseFloat(a)&&(a+="px"),e.style[s(o)]=a}},n}(window||{});return e});;
6290(function($) {
6291    Drupal.behaviors.experiencesListing = {
6292        attach: function (context, settings) {
6293            var $trigger = $('.js-experiences-header-dropdown__trigger');
6294            var $dropdown = $('.js-experiences-header-dropdown__content');
6295            $trigger.click(function(e) {
6296                e.preventDefault();
6297                $dropdown.slideToggle().toggleClass('open');
6298                $trigger.toggleClass('open');
6299            });
6300
6301            // Move the reset button.
6302            var formid = $('.experiences--filters').attr('id');
6303            $('#edit-reset').attr('form', formid).appendTo('.buttons');
6304
6305            // Select all links
6306            var selected = $('.form-checkboxes.fieldgroup:not(.bef-processed)');
6307            if (selected.length) {
6308                // Set up a prototype link and event handlers.
6309                var link = $('<a class="checkbox bef-toggle" href="#">All</a>');
6310                link.click(function (event) {
6311                    // Don't actually follow the link.
6312                    event.preventDefault();
6313                    event.stopPropagation();
6314
6315                    if ($(this).hasClass('checked')) {
6316                        // Unselect all the checkboxes
6317                        $(this)
6318                            .removeClass('checked')
6319                            .siblings()
6320                            .find('input:checkbox').each(function () {
6321                            $(this).prop('checked', false);
6322                        })
6323                            .end()
6324
6325                            // attr() doesn't trigger a change event, so we do it ourselves. But just on
6326                            // one checkbox otherwise we have many spinning cursors
6327                            .find('input[type=checkbox]:first').change()
6328                        ;
6329
6330                    }
6331                    else {
6332                        // Select all the checkboxes
6333                        $(this)
6334                            .addClass('checked')
6335                            .siblings()
6336                            .find('input:checkbox').each(function () {
6337                            $(this).prop('checked', true);
6338                        })
6339                            .end()
6340
6341                            // attr() doesn't trigger a change event, so we do it ourselves. But just on
6342                            // one checkbox otherwise we have many spinning cursors
6343                            .find('input[type=checkbox]:first').change()
6344                        ;
6345                    }
6346                });
6347
6348                // Add link to the page for each set of checkboxes.
6349                selected
6350                    .addClass('bef-processed')
6351                    .each(function (index) {
6352
6353                        if (selected[index].id == 'edit-month--wrapper') {
6354                            link[0].text = 'All Months';
6355                            // Clone the link prototype and insert into the DOM for the Seasons filter.
6356                            var newLink = link.clone(true);
6357                            newLink.insertBefore($(this));
6358                        }
6359
6360                        if (selected[index].id == 'edit-inspiration--wrapper') {
6361                            link[0].text = 'All Inspiration';
6362                            // Clone the link prototype and insert into the DOM for the Inspiration filter.
6363                            var newLink = link.clone(true);
6364                            newLink.insertBefore($(this));
6365                        }
6366
6367                        if (selected[index].id == 'edit-duration--wrapper') {
6368                            link[0].text = 'All Duration';
6369                            // Clone the link prototype and insert into the DOM for the Duration filter.
6370                            var newLink = link.clone(true);
6371                            newLink.insertBefore($(this));
6372                        }
6373
6374                        // If all checkboxes are already checked by default then switch to Select None
6375                        if ($('input:checkbox:checked', this).length == $('input:checkbox', this).length) {
6376                            newLink.click();
6377                        }
6378                    })
6379                ;
6380            }
6381
6382
6383        }
6384    };
6385})(jQuery);
6386;
6387(function ($, Drupal) {
6388
6389  Drupal.behaviors.mapDisableScroll = {
6390    attach: function (context) {
6391
6392      $('.field-hotel-location ').click(function () {
6393          $('.field-hotel-location .map-container').css("pointer-events", "auto");
6394      });
6395
6396      $( ".field-hotel-location " ).mouseleave(function() {
6397        $('.field-hotel-location .map-container').css("pointer-events", "none");
6398      });
6399
6400    }
6401  }
6402
6403})(jQuery, Drupal);
6404;
6405/**
6406 * @file inspirations.js
6407 */
6408(function ($) {
6409  "use strict";
6410  Drupal.behaviors.inspirations = {
6411    attach: function(context) {
6412      $('.inspiration--read-more-cta').click(function() {
6413        $('.inspiration--mobile-image-body-wrapper .hide-in-small-layout').addClass('expanded');
6414        var $galleries = $('#image-gallery');
6415        if ($galleries.length) {
6416          $('.slick-dots', $galleries).remove();
6417          $galleries.slick('reinit');
6418        }
6419        $(this).addClass('hide');
6420      });
6421
6422      $('.inspiration--close-read-more-cta').click(function() {
6423        $('.inspiration--mobile-image-body-wrapper .hide-in-small-layout').removeClass('expanded');
6424        $('.inspiration--read-more-cta').removeClass('hide');
6425      });
6426    }
6427  };
6428
6429}(jQuery));
6430;
6431(function ($, Drupal, drupalSettings) {
6432
6433  Drupal.behaviors.expert_form = {
6434    attach: function (context) {
6435      var $buttons = $('.ask-an-expert-button');
6436      $buttons.filter(':not(.ask-an-expert-processed)').each(function () {
6437        var $this_button = $(this);
6438        var $target = $this_button.siblings('.ask-an-expert');
6439        $target.append('<div class="close-expert-form"></div>');
6440
6441        $this_button.click(function() {
6442          var $this_btn = $(this);
6443          if ($this_btn.hasClass('active')) {
6444            $this_btn.removeClass('active');
6445          }
6446          else {
6447            // Close all other open forms, open this one.
6448            $buttons.removeClass('active');
6449            $this_btn.addClass('active');
6450
6451            // If this is within an experience page, the form may need scrolling
6452            // into view. This is not done for the button in the header, because
6453            // the header is always visible so the context within the page isn't
6454            // lost.
6455            if ($this_btn.parent().parent('nav').length === 0) {
6456              var $target = $this_btn.siblings('.ask-an-expert');
6457
6458              // Figure out the height of the position fixed header, if sticky.
6459              var header_height = 0;
6460              var $header = $('.sticky-menu');
6461              if ($header.length > 0 && $header.parent().hasClass('scrollmagic-pin-spacer')) {
6462                header_height = $header.first().position().top;
6463                $header.each(function () {
6464                  header_height += $(this).outerHeight()
6465                });
6466              }
6467
6468              // If the opened form is larger than the available space, bring
6469              // the top of it into view. Otherwise, bring the bottom of it into
6470              // view, unless the whole form is already visible.
6471              var scroll_pos, $body_scroller;
6472              // Original code scrolled both html & body. It's possible that only
6473              // one or the other work in different browsers?
6474              var $body_scroller_candidates = $('html,body');
6475              var scrolling_within = false;
6476              var $sidebar_candidate = $this_button.closest('.content-inner-wrapper');
6477              if ($sidebar_candidate.length > 0 && $sidebar_candidate.css('overflow-y') === 'auto') {
6478                $body_scroller_candidates = $sidebar_candidate;
6479                scrolling_within = true;
6480              }
6481              $body_scroller_candidates.each(function () {
6482                var $this = $(this);
6483                var elem_scroll_top = $this.scrollTop();
6484                if (elem_scroll_top > 0 || $this.offset().top > 0) {
6485                  scroll_pos = elem_scroll_top;
6486                  $body_scroller = $this;
6487                }
6488              });
6489
6490              if (typeof($body_scroller) !== 'undefined' && typeof(scroll_pos) !== 'undefined') {
6491                var vp_height = $body_scroller.height();
6492                var form_height = $target.outerHeight();
6493                var form_and_btn_height = form_height + $this_btn.outerHeight();
6494                var scroll = 0;
6495                var form_pos = $target.offset().top;
6496                if (scrolling_within && scroll_pos) {
6497                  form_pos = form_pos - $body_scroller.offset().top + scroll_pos;
6498                }
6499                if (form_and_btn_height >= vp_height - header_height) {
6500                  scroll = form_pos - header_height - $this_btn.outerHeight();
6501                }
6502                else {
6503                  var visible = scroll_pos + vp_height > form_pos + form_and_btn_height;
6504                  if (!visible) {
6505                    scroll = form_pos - vp_height + form_and_btn_height;
6506                  }
6507                }
6508                if (scroll > 0) {
6509                  $body_scroller.stop().animate({
6510                    scrollTop: scroll
6511                  }, 500);
6512                }
6513              }
6514            }
6515          }
6516        });
6517
6518        // Attach intl-tel-input plugin.
6519        $target.each(function () {
6520          var $form = $(this);
6521          var $phone = $form.find('input[name="phone_no"]');
6522          var $hidden = $form.find('input[name="phone_no_full"]');
6523          $phone.intlTelInput({
6524            utilsScript: '/libraries/intl-tel-input/build/js/utils.js',
6525            preferredCountries: ['gb']
6526          });
6527
6528          $form.submit(function () {
6529            var phone_val = $phone.val();
6530            var mail_val = $form.find('input[name="email"]').val();
6531            $hidden.val($phone.intlTelInput("getNumber"));
6532
6533            // Track as custom event in GA. Assumes submitted email is valid,
6534            // but does skip tracking if an email has not been supplied, as that
6535            // is the one known mandatory field. The smallest valid email
6536            // address would have 5 characters, so use that for some validation.
6537            if (typeof(ga) === 'function' && mail_val.length > 5) {
6538              var experience = '';
6539              var $page = $('#page');
6540              if ($page.hasClass('node-experience')) {
6541                experience = $.trim($('h1').first().text());
6542              }
6543              else {
6544                if ($page.hasClass('node-hotel')) {
6545                  // Extract from experience query string parameter.
6546                  var queryString = decodeURI(window.location.search);
6547                  var experience_parameter = (/experience=([^&]+)/.exec(queryString));
6548                  if (experience_parameter) {
6549                    experience = experience_parameter[1];
6550                  }
6551                }
6552                else {
6553                  // If inside an experience large_teaser, extract title.
6554                  var $teaser = $form.closest('.experience-large-teaser');
6555                  if ($teaser.length) {
6556                    experience = $.trim($teaser.find('h2').first().text());
6557                  }
6558                }
6559              }
6560
6561              // Store whether email and/or phone was supplied in the event
6562              // value, which is an integer field. As email is mandatory anyway,
6563              // just store 0 or 1, to signify whether a phone number was
6564              // supplied. This could be extended to 2 for phone only, or 3 for
6565              // neither if the email field could be left blank in future.
6566              // Admittedly, that's not intuitive, but is at least fine whilst
6567              // an email is required.
6568              var phone_supplied = 0;
6569              if (phone_val.length > 3) {
6570                phone_supplied = 1;
6571              }
6572
6573              ga('send', 'event', 'Request call back', $this_button.text(), experience, phone_supplied);
6574            }
6575          });
6576        });
6577
6578        $this_button.addClass('ask-an-expert-processed');
6579      });
6580
6581
6582      $(window).click(function (e) {
6583        // If any element other than those inside the form are clicked,
6584        // then close the form.
6585        var $target = $(e.target);
6586        var is_close = $target.hasClass('close-expert-form');
6587        var is_inside_form = $target.closest('.experience--speak-to-an-expert-wrapper').length;
6588        var is_inside_country_select = $target.closest('.intl-tel-input').length;
6589        if (is_close || (!is_inside_form && !is_inside_country_select)) {
6590          $buttons.removeClass('active');
6591        }
6592      });
6593    }
6594  };
6595
6596}(jQuery, Drupal, drupalSettings));
6597;
6598(function ($, Drupal, drupalSettings) {
6599
6600  /**
6601   * Behaviors for collapsible sections.
6602   */
6603  Drupal.behaviors.collapsibleSections = {
6604    attach: function (context, settings) {
6605      var more_label = settings.niquesa_collapsible_sections.more_label;
6606      var less_label = settings.niquesa_collapsible_sections.less_label;
6607      var selectors = [
6608        '.media-pod .field-pod-initial-text + .field-pod-body',
6609        '.experience-full .field-place-by-place .field__item + .field__item',
6610        '.destinations-full .initial-text + .full-text',
6611        '.inspiration-category-full .description + .field-feeling-full-text'
6612      ];
6613      $(selectors.join(', '), context).once('collapsible-section').each(function () {
6614        var $this_body = $(this);
6615        $this_body.toggleClass('collapsible-section-collapsed', true);
6616        $this_body.after('<button class="collapsible-toggle align-right body-font hide-in-small-layout">' + more_label + '</button>');
6617        $this_body.siblings('.collapsible-toggle').click(function () {
6618          var $this_toggle = $(this);
6619          if ($this_toggle.hasClass('collapsible-toggle-less')) {
6620            $this_toggle.text(Drupal.t('READ MORE +')).removeClass('collapsible-toggle-less');
6621            $this_body.slideUp({
6622              complete: function () {
6623                $this_body.toggleClass('collapsible-section-collapsed', true).css('display', '');
6624              }
6625            });
6626          }
6627          else {
6628            $this_toggle.text(less_label).addClass('collapsible-toggle-less');
6629            $this_body.slideDown({
6630              complete: function () {
6631                $this_body.removeClass('collapsible-section-collapsed').css('display', '');
6632              }
6633            });
6634          }
6635        });
6636      });
6637    }
6638  };
6639
6640}(jQuery, Drupal, drupalSettings));
6641;
6642/*!
6643 * imagesLoaded PACKAGED v3.1.8
6644 * JavaScript is all like "You images are done yet or what?"
6645 * MIT License
6646 */
6647
6648(function(){function e(){}function t(e,t){for(var n=e.length;n--;)if(e[n].listener===t)return n;return-1}function n(e){return function(){return this[e].apply(this,arguments)}}var i=e.prototype,r=this,o=r.EventEmitter;i.getListeners=function(e){var t,n,i=this._getEvents();if("object"==typeof e){t={};for(n in i)i.hasOwnProperty(n)&&e.test(n)&&(t[n]=i[n])}else t=i[e]||(i[e]=[]);return t},i.flattenListeners=function(e){var t,n=[];for(t=0;e.length>t;t+=1)n.push(e[t].listener);return n},i.getListenersAsObject=function(e){var t,n=this.getListeners(e);return n instanceof Array&&(t={},t[e]=n),t||n},i.addListener=function(e,n){var i,r=this.getListenersAsObject(e),o="object"==typeof n;for(i in r)r.hasOwnProperty(i)&&-1===t(r[i],n)&&r[i].push(o?n:{listener:n,once:!1});return this},i.on=n("addListener"),i.addOnceListener=function(e,t){return this.addListener(e,{listener:t,once:!0})},i.once=n("addOnceListener"),i.defineEvent=function(e){return this.getListeners(e),this},i.defineEvents=function(e){for(var t=0;e.length>t;t+=1)this.defineEvent(e[t]);return this},i.removeListener=function(e,n){var i,r,o=this.getListenersAsObject(e);for(r in o)o.hasOwnProperty(r)&&(i=t(o[r],n),-1!==i&&o[r].splice(i,1));return this},i.off=n("removeListener"),i.addListeners=function(e,t){return this.manipulateListeners(!1,e,t)},i.removeListeners=function(e,t){return this.manipulateListeners(!0,e,t)},i.manipulateListeners=function(e,t,n){var i,r,o=e?this.removeListener:this.addListener,s=e?this.removeListeners:this.addListeners;if("object"!=typeof t||t instanceof RegExp)for(i=n.length;i--;)o.call(this,t,n[i]);else for(i in t)t.hasOwnProperty(i)&&(r=t[i])&&("function"==typeof r?o.call(this,i,r):s.call(this,i,r));return this},i.removeEvent=function(e){var t,n=typeof e,i=this._getEvents();if("string"===n)delete i[e];else if("object"===n)for(t in i)i.hasOwnProperty(t)&&e.test(t)&&delete i[t];else delete this._events;return this},i.removeAllListeners=n("removeEvent"),i.emitEvent=function(e,t){var n,i,r,o,s=this.getListenersAsObject(e);for(r in s)if(s.hasOwnProperty(r))for(i=s[r].length;i--;)n=s[r][i],n.once===!0&&this.removeListener(e,n.listener),o=n.listener.apply(this,t||[]),o===this._getOnceReturnValue()&&this.removeListener(e,n.listener);return this},i.trigger=n("emitEvent"),i.emit=function(e){var t=Array.prototype.slice.call(arguments,1);return this.emitEvent(e,t)},i.setOnceReturnValue=function(e){return this._onceReturnValue=e,this},i._getOnceReturnValue=function(){return this.hasOwnProperty("_onceReturnValue")?this._onceReturnValue:!0},i._getEvents=function(){return this._events||(this._events={})},e.noConflict=function(){return r.EventEmitter=o,e},"function"==typeof define&&define.amd?define("eventEmitter/EventEmitter",[],function(){return e}):"object"==typeof module&&module.exports?module.exports=e:this.EventEmitter=e}).call(this),function(e){function t(t){var n=e.event;return n.target=n.target||n.srcElement||t,n}var n=document.documentElement,i=function(){};n.addEventListener?i=function(e,t,n){e.addEventListener(t,n,!1)}:n.attachEvent&&(i=function(e,n,i){e[n+i]=i.handleEvent?function(){var n=t(e);i.handleEvent.call(i,n)}:function(){var n=t(e);i.call(e,n)},e.attachEvent("on"+n,e[n+i])});var r=function(){};n.removeEventListener?r=function(e,t,n){e.removeEventListener(t,n,!1)}:n.detachEvent&&(r=function(e,t,n){e.detachEvent("on"+t,e[t+n]);try{delete e[t+n]}catch(i){e[t+n]=void 0}});var o={bind:i,unbind:r};"function"==typeof define&&define.amd?define("eventie/eventie",o):e.eventie=o}(this),function(e,t){"function"==typeof define&&define.amd?define(["eventEmitter/EventEmitter","eventie/eventie"],function(n,i){return t(e,n,i)}):"object"==typeof exports?module.exports=t(e,require("wolfy87-eventemitter"),require("eventie")):e.imagesLoaded=t(e,e.EventEmitter,e.eventie)}(window,function(e,t,n){function i(e,t){for(var n in t)e[n]=t[n];return e}function r(e){return"[object Array]"===d.call(e)}function o(e){var t=[];if(r(e))t=e;else if("number"==typeof e.length)for(var n=0,i=e.length;i>n;n++)t.push(e[n]);else t.push(e);return t}function s(e,t,n){if(!(this instanceof s))return new s(e,t);"string"==typeof e&&(e=document.querySelectorAll(e)),this.elements=o(e),this.options=i({},this.options),"function"==typeof t?n=t:i(this.options,t),n&&this.on("always",n),this.getImages(),a&&(this.jqDeferred=new a.Deferred);var r=this;setTimeout(function(){r.check()})}function f(e){this.img=e}function c(e){this.src=e,v[e]=this}var a=e.jQuery,u=e.console,h=u!==void 0,d=Object.prototype.toString;s.prototype=new t,s.prototype.options={},s.prototype.getImages=function(){this.images=[];for(var e=0,t=this.elements.length;t>e;e++){var n=this.elements[e];"IMG"===n.nodeName&&this.addImage(n);var i=n.nodeType;if(i&&(1===i||9===i||11===i))for(var r=n.querySelectorAll("img"),o=0,s=r.length;s>o;o++){var f=r[o];this.addImage(f)}}},s.prototype.addImage=function(e){var t=new f(e);this.images.push(t)},s.prototype.check=function(){function e(e,r){return t.options.debug&&h&&u.log("confirm",e,r),t.progress(e),n++,n===i&&t.complete(),!0}var t=this,n=0,i=this.images.length;if(this.hasAnyBroken=!1,!i)return this.complete(),void 0;for(var r=0;i>r;r++){var o=this.images[r];o.on("confirm",e),o.check()}},s.prototype.progress=function(e){this.hasAnyBroken=this.hasAnyBroken||!e.isLoaded;var t=this;setTimeout(function(){t.emit("progress",t,e),t.jqDeferred&&t.jqDeferred.notify&&t.jqDeferred.notify(t,e)})},s.prototype.complete=function(){var e=this.hasAnyBroken?"fail":"done";this.isComplete=!0;var t=this;setTimeout(function(){if(t.emit(e,t),t.emit("always",t),t.jqDeferred){var n=t.hasAnyBroken?"reject":"resolve";t.jqDeferred[n](t)}})},a&&(a.fn.imagesLoaded=function(e,t){var n=new s(this,e,t);return n.jqDeferred.promise(a(this))}),f.prototype=new t,f.prototype.check=function(){var e=v[this.img.src]||new c(this.img.src);if(e.isConfirmed)return this.confirm(e.isLoaded,"cached was confirmed"),void 0;
6648if(this.img.complete&&void 0!==this.img.naturalWidth)return this.confirm(0!==this.img.naturalWidth,"naturalWidth"),void 0;var t=this;e.on("confirm",function(e,n){return t.confirm(e.isLoaded,n),!0}),e.check()},f.prototype.confirm=function(e,t){this.isLoaded=e,this.emit("confirm",this,t)};var v={};return c.prototype=new t,c.prototype.check=function(){if(!this.isChecked){var e=new Image;n.bind(e,"load",this),n.bind(e,"error",this),e.src=this.src,this.isChecked=!0}},c.prototype.handleEvent=function(e){var t="on"+e.type;this[t]&&this[t](e)},c.prototype.onload=function(e){this.confirm(!0,"onload"),this.unbindProxyEvents(e)},c.prototype.onerror=function(e){this.confirm(!1,"onerror"),this.unbindProxyEvents(e)},c.prototype.confirm=function(e,t){this.isConfirmed=!0,this.isLoaded=e,this.emit("confirm",this,t)},c.prototype.unbindProxyEvents=function(e){n.unbind(e.target,"load",this),n.unbind(e.target,"error",this)},s});;
6649(function($) {
6650  Drupal.behaviors.bgImagesAndSidebar = {
6651    attach: function (context, settings) {
6652      var $sidebar = $('.content-sidebar', context);
6653      var $hideables = $('.content-sidebar, .opposite-content', context);
6654      $sidebar.once('sidebar-toggle').each(function () {
6655        var $sidebar_toggle_container = $('.breadcrumb-region', $sidebar);
6656        if ($sidebar_toggle_container.length === 0) {
6657          $sidebar.prepend('<div class="breadcrumb-region clearfix"></div>');
6658
6659          $sidebar_toggle_container = $('.breadcrumb-region', $sidebar);
6660        }
6661
6662        var hide_text = settings.niquesa_bg_images_and_sidebar.hide_label;
6663        $sidebar_toggle_container.append('<button class="content-sidebar-hide body-font hide-in-small-layout">' + hide_text + '</button>');
6664        var $sidebar_hide = $('.content-sidebar-hide', $sidebar_toggle_container);
6665
6666        var $images_wrapper = $('#main', context);
6667        var show_text = settings.niquesa_bg_images_and_sidebar.show_label;
6668        $images_wrapper.prepend('<div class="content-sidebar-show-wrapper hide-in-small-layout hide"><div class="l-full"><button class="button content-sidebar-show">' + show_text + '</button></div></div>');
6669        var $sidebar_show_wrapper = $('.content-sidebar-show-wrapper', $images_wrapper);
6670        var $sidebar_show = $('.content-sidebar-show', $sidebar_show_wrapper);
6671
6672        $sidebar_hide.click(function () {
6673          $hideables.animate({ opacity: 0}, 'slow', 'swing', function () {
6674            $sidebar_show_wrapper.removeClass('hide');
6675            $sidebar.toggleClass('content-sidebar-hidden', true);
6676            $images_wrapper.toggleClass('has-content-sidebar-hidden', true);
6677            $hideables.css('opacity', '');
6678          });
6679        });
6680
6681        $sidebar_show.click(function () {
6682          $hideables.css('opacity', 0);
6683          $sidebar_show_wrapper.toggleClass('hide', true);
6684          $sidebar.removeClass('content-sidebar-hidden');
6685          $images_wrapper.removeClass('has-content-sidebar-hidden');
6686          $hideables.animate({ opacity: 1}, 'slow');
6687        });
6688      });
6689
6690      var $carousel = $('.js-header-carousel', context);
6691      var $slides = $carousel.children();
6692      if ($slides.length > 1) {
6693        var slickify = function () {
6694          // Replace all placeholder src & style attributes.
6695          $('.bg-image--image[data-style]', $slides).each(function () {
6696            var $element = $(this);
6697            $element.attr('style', $element.attr('data-style'));
6698            $element.removeAttr('data-style');
6699          });
6700
6701          var arrows_selector = '#bg-images--arrows';
6702          $carousel.slick({
6703            appendArrows: arrows_selector,
6704            autoplay: $carousel.data('autoplay'),
6705            autoplaySpeed: 5000,
6706            dots: true,
6707            fade: true,
6708            pauseOnFocus: false,
6709            pauseOnHover: false,
6710            speed: parseInt($carousel.data('speed'), 10),
6711            infinite: true
6712          });
6713
6714          $('#bg-images--arrows').toggleClass('bg-images--arrows-initialized', true).click(function (e) {
6715            if (!$(e.target).hasClass('slick-arrow')) {
6716              var i = $carousel.slick('slickCurrentSlide');
6717              var $link = $('a[href]', $slides.slice(i, i+1));
6718              if ($link.length) {
6719                window.location = $link.attr('href');
6720              }
6721            }
6722          });
6723        };
6724
6725        // Only load actual images and initialise the carousel once placeholder
6726        // images have loaded, so slides are at least blurry.
6727        $carousel.once('bgImagesAndSidebar').imagesLoaded({
6728          background: '.bg-image--placeholder'
6729        }).done(slickify);
6730      }
6731    }
6732  }
6733})(jQuery);
6734;
6735(function(e){e.fn.farbtastic=function(f){e.farbtastic(this,f);return this};e.farbtastic=function(f,l){f=e(f).get(0);return f.farbtastic||(f.farbtastic=new e._farbtastic(f,l))};e._farbtastic=function(f,l){var a=this;e(f).html('<div class="farbtastic"><div class="color"></div><div class="wheel"></div><div class="overlay"></div><div class="h-marker marker"></div><div class="sl-marker marker"></div></div>');var k=e(".farbtastic",f);a.wheel=e(".wheel",f).get(0);a.radius=84;a.square=100;a.width=194;navigator.appVersion.match(/MSIE [0-6]\./)&&
6736e("*",k).each(function(){if(this.currentStyle.backgroundImage!="none"){var b=this.currentStyle.backgroundImage;b=this.currentStyle.backgroundImage.substring(5,b.length-2);e(this).css({backgroundImage:"none",filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true, sizingMethod=crop, src='"+b+"')"})}});a.linkTo=function(b){typeof a.callback=="object"&&e(a.callback).unbind("
vendor: 1,727 bytes, lines 6736-6740
6736keyup",a.updateValue);a.color=null;if(typeof b=="function")a.callback=b;else if(typeof b=="object"||typeof b=="string"){a.callback=
6737e(b);a.callback.bind("keyup",a.updateValue);a.callback.get(0).value&&a.setColor(a.callback.get(0).value)}return this};a.updateValue=function(){this.value&&this.value!=a.color&&a.setColor(this.value)};a.setColor=function(b){var c=a.unpack(b);if(a.color!=b&&c){a.color=b;a.rgb=c;a.hsl=a.RGBToHSL(a.rgb);a.updateDisplay()}return this};a.setHSL=function(b){a.hsl=b;a.rgb=a.HSLToRGB(b);a.color=a.pack(a.rgb);a.updateDisplay();return this};a.widgetCoords=function(b){var c=e(a.wheel).offset();return{x:b.pageX-
6738c.left-a.width/2,y:b.pageY-c.top-a.width/2}};a.mousedown=function(b){if(!document.dragging){e(document).bind("mousemove",a.mousemove).bind("mouseup",a.mouseup);document.dragging=true}var c=a.widgetCoords(b);a.circleDrag=Math.max(Math.abs(c.x),Math.abs(c.y))*2>a.square;a.mousemove(b);return false};a.mousemove=function(b){var c=a.widgetCoords(b);if(a.circleDrag){b=Math.atan2(c.x,-c.y)/6.28;if(b<0)b+=1;a.setHSL([b,a.hsl[1],a.hsl[2]])}else{b=Math.max(0,Math.min(1,-(c.x/a.square)+0.5));c=Math.max(0,Math.min(1,
6739-(c.y/a.square)+0.5));a.setHSL([a.hsl[0],b,c])}return false};a.mouseup=function(){e(document).unbind("mousemove",a.mousemove);e(document).unbind("mouseup",a.mouseup);document.dragging=false};a.updateDisplay=function(){var b=a.hsl[0]*6.28;e(".h-marker",k).css({left:Math.round(Math.sin(b)*a.radius+a.width/2)+"px",top:Math.round(-Math.cos(b)*a.radius+a.width/2)+"px"});e(".sl-marker",k).css({left:Math.round(a.square*(0.5-a.hsl[1])+a.width/2)+"px",top:Math.round(a.square*(0.5-a.hsl[2])+a.width/2)+"px"});
6740e(".color",k).css("backgroundColor",a.pack(a.HSLToRGB([a.hsl[0],1,0.5])));
6740if(typeof a.callback=="object"){e(a.callback).css({backgroundColor:a.color,color:a.hsl[2]>0.5?"#000":"#fff"});e(a.callback).each(function(){if(this.value&&this.value!=a.color)this.value=a.color})}else typeof a.callback=="function"&&a.callback.call(a,a.color)};a.pack=function(b){var c=Math.round(b[0]*255),d=Math.round(b[1]*255);b=Math.round(b[2]*255);return"#"+(c<16?"0":"")+c.toString(16)+(d<16?"0":"")+d.toString(16)+(b<16?"0":
6741"")+b.toString(16)};a.unpack=function(b){if(b.length==7)return[parseInt("0x"+b.substring(1,3))/255,parseInt("0x"+b.substring(3,5))/255,parseInt("0x"+b.substring(5,7))/255];else if(b.length==4)return[parseInt("0x"+b.substring(1,2))/15,parseInt("0x"+b.substring(2,3))/15,parseInt("0x"+b.substring(3,4))/15]};a.HSLToRGB=function(b){var c,d=b[0];c=b[1];b=b[2];c=b<=0.5?b*(c+1):b+c-b*c;b=b*2-c;return[this.hueToRGB(b,c,d+0.33333),this.hueToRGB(b,c,d),this.hueToRGB(b,c,d-0.33333)]};a.hueToRGB=function(b,c,
6742d){d=d<0?d+1:d>1?d-1:d;if(d*6<1)return b+(c-b)*d*6;if(d*2<1)return c;if(d*3<2)return b+(c-b)*(0.66666-d)*6;return b};a.RGBToHSL=function(b){var c,d,m,g,h=b[0],i=b[1],j=b[2];c=Math.min(h,Math.min(i,j));b=Math.max(h,Math.max(i,j));d=b-c;g=(c+b)/2;m=0;if(g>0&&g<1)m=d/(g<0.5?2*g:2-2*g);c=0;if(d>0){if(b==h&&b!=i)c+=(i-j)/d;if(b==i&&b!=j)c+=2+(j-h)/d;if(b==j&&b!=h)c+=4+(h-i)/d;c/=6}return[c,m,g]};e("*",k).mousedown(a.mousedown);a.setColor("#000000");l&&a.linkTo(l)}})(jQuery);
6743;
6744/**
6745* DO NOT EDIT THIS FILE.
6746* See the following change record for more information,
6747* https://www.drupal.org/node/2815083
6748* @preserve
6749**/
6750
6751(function ($, Drupal) {
6752  Drupal.color = {
6753    callback: function callback(context, settings, form, farb, height, width) {
6754      var accum = void 0;
6755      var delta = void 0;
6756
6757      form.find('.color-preview').css('backgroundColor', form.find('.color-palette input[name="palette[base]"]').val());
6758
6759      form.find('#text').css('color', form.find('.color-palette input[name="palette[text]"]').val());
6760      form.find('#text a, #text h2').css('color', form.find('.color-palette input[name="palette[link]"]').val());
6761
6762      function gradientLineColor(i, element) {
6763        for (var k in accum) {
6764          if (accum.hasOwnProperty(k)) {
6765            accum[k] += delta[k];
6766          }
6767        }
6768        element.style.backgroundColor = farb.pack(accum);
6769      }
6770
6771      var color_start = void 0;
6772      var color_end = void 0;
6773      for (var i in settings.gradients) {
6774        if (settings.gradients.hasOwnProperty(i)) {
6775          color_start = farb.unpack(form.find('.color-palette input[name="palette[' + settings.gradients[i].colors[0] + ']"]').val());
6776          color_end = farb.unpack(form.find('.color-palette input[name="palette[' + settings.gradients[i].colors[1] + ']"]').val());
6777          if (color_start && color_end) {
6778            delta = [];
6779            for (var j in color_start) {
6780              if (color_start.hasOwnProperty(j)) {
6781                delta[j] = (color_end[j] - color_start[j]) / (settings.gradients[i].vertical ? height[i] : width[i]);
6782              }
6783            }
6784            accum = color_start;
6785
6786            form.find('#gradient-' + i + ' > div').each(gradientLineColor);
6787          }
6788        }
6789      }
6790    }
6791  };
6792})(jQuery, Drupal);;
6793/**
6794* DO NOT EDIT THIS FILE.
6795* See the following change record for more information,
6796* https://www.drupal.org/node/2815083
6797* @preserve
6798**/
6799
6800(function ($, Drupal) {
6801  Drupal.behaviors.color = {
6802    attach: function attach(context, settings) {
6803      var i = void 0;
6804      var j = void 0;
6805      var colors = void 0;
6806
6807      var form = $(context).find('#system-theme-settings .color-form').once('color');
6808      if (form.length === 0) {
6809        return;
6810      }
6811      var inputs = [];
6812      var hooks = [];
6813      var locks = [];
6814      var focused = null;
6815
6816      $('<div class="color-placeholder"></div>').once('color').prependTo(form);
6817      var farb = $.farbtastic('.color-placeholder');
6818
6819      var reference = settings.color.reference;
6820      for (i in reference) {
6821        if (reference.hasOwnProperty(i)) {
6822          reference[i] = farb.RGBToHSL(farb.unpack(reference[i]));
6823        }
6824      }
6825
6826      var height = [];
6827      var width = [];
6828
6829      for (i in settings.gradients) {
6830        if (settings.gradients.hasOwnProperty(i)) {
6831          $('.color-preview').once('color').append('<div id="gradient-' + i + '"></div>');
6832          var gradient = $('.color-preview #gradient-' + i);
6833
6834          height.push(parseInt(gradient.css('height'), 10) / 10);
6835
6836          width.push(parseInt(gradient.css('width'), 10) / 10);
6837
6838          for (j = 0; j < (settings.gradients[i].direction === 'vertical' ? height[i] : width[i]); ++j) {
6839            gradient.append('<div class="gradient-line"></div>');
6840          }
6841        }
6842      }
6843
6844      form.find('#edit-scheme').on('change', function () {
6845        var schemes = settings.color.schemes;
6846        var colorScheme = this.options[this.selectedIndex].value;
6847        if (colorScheme !== '' && schemes[colorScheme]) {
6848          colors = schemes[colorScheme];
6849          for (var fieldName in colors) {
6850            if (colors.hasOwnProperty(fieldName)) {
6851              callback($('#edit-palette-' + fieldName), colors[fieldName], false, true);
6852            }
6853          }
6854          preview();
6855        }
6856      });
6857
6858      function preview() {
6859        Drupal.color.callback(context, settings, form, farb, height, width);
6860      }
6861
6862      function shift_color(given, ref1, ref2) {
6863        var d = void 0;
6864
6865        given = farb.RGBToHSL(farb.unpack(given));
6866
6867        given[0] += ref2[0] - ref1[0];
6868
6869        if (ref1[1] === 0 || ref2[1] === 0) {
6870          given[1] = ref2[1];
6871        } else {
6872          d = ref1[1] / ref2[1];
6873          if (d > 1) {
6874            given[1] /= d;
6875          } else {
6876            given[1] = 1 - (1 - given[1]) * d;
6877          }
6878        }
6879
6880        if (ref1[2] === 0 || ref2[2] === 0) {
6881          given[2] = ref2[2];
6882        } else {
6883          d = ref1[2] / ref2[2];
6884          if (d > 1) {
6885            given[2] /= d;
6886          } else {
6887            given[2] = 1 - (1 - given[2]) * d;
6888          }
6889        }
6890
6891        return farb.pack(farb.HSLToRGB(given));
6892      }
6893
6894      function callback(input, color, propagate, colorScheme) {
6895        var matched = void 0;
6896
6897        $(input).css({
6898          backgroundColor: color,
6899          color: farb.RGBToHSL(farb.unpack(color))[2] > 0.5 ? '#000' : '#fff'
6900        });
6901
6902        if ($(input).val() && $(input).val() !== color) {
6903          $(input).val(color);
6904
6905          if (propagate) {
6906            i = input.i;
6907            for (j = i + 1;; ++j) {
6908              if (!locks[j - 1] || $(locks[j - 1]).is('.is-unlocked')) {
6909                break;
6910              }
6911              matched = shift_color(color, reference[input.key], reference[inputs[j].key]);
6912              callback(inputs[j], matched, false);
6913            }
6914            for (j = i - 1;; --j) {
6915              if (!locks[j] || $(locks[j]).is('.is-unlocked')) {
6916                break;
6917              }
6918              matched = shift_color(color, reference[input.key], reference[inputs[j].key]);
6919              callback(inputs[j], matched, false);
6920            }
6921
6922            preview();
6923          }
6924
6925          if (!colorScheme) {
6926            resetScheme();
6927          }
6928        }
6929      }
6930
6931      function resetScheme() {
6932        form.find('#edit-scheme').each(function () {
6933          this.selectedIndex = this.options.length - 1;
6934        });
6935      }
6936
6937      function focus(e) {
6938        var input = e.target;
6939
6940        if (focused) {
6941          $(focused).off('keyup', farb.updateValue).off('keyup', preview).off('keyup', resetScheme).parent().removeClass('item-selected');
6942        }
6943
6944        focused = input;
6945        farb.linkTo(function (color) {
6946          callback(input, color, true, false);
6947        });
6948        farb.setColor(input.value);
6949        $(focused).on('keyup', farb.updateValue).on('keyup', preview).on('keyup', resetScheme).parent().addClass('item-selected');
6950      }
6951
6952      form.find('.js-color-palette input.form-text').each(function () {
6953        this.key = this.id.substring(13);
6954
6955        farb.linkTo(function () {}).setColor('#000').linkTo(this);
6956
6957        var i = inputs.length;
6958        if (inputs.length) {
6959          var toggleClick = true;
6960          var lock = $('<button class="color-palette__lock">' + Drupal.t('Unlock') + '</button>').on('click', function (e) {
6961            e.preventDefault();
6962            if (toggleClick) {
6963              $(this).addClass('is-unlocked').html(Drupal.t('Lock'));
6964              $(hooks[i - 1]).attr('class', locks[i - 2] && $(locks[i - 2]).is(':not(.is-unlocked)') ? 'color-palette__hook is-up' : 'color-palette__hook');
6965              $(hooks[i]).attr('class', locks[i] && $(locks[i]).is(':not(.is-unlocked)') ? 'color-palette__hook is-down' : 'color-palette__hook');
6966            } else {
6967              $(this).removeClass('is-unlocked').html(Drupal.t('Unlock'));
6968              $(hooks[i - 1]).attr('class', locks[i - 2] && $(locks[i - 2]).is(':not(.is-unlocked)') ? 'color-palette__hook is-both' : 'color-palette__hook is-down');
6969              $(hooks[i]).attr('class', locks[i] && $(locks[i]).is(':not(.is-unlocked)') ? 'color-palette__hook is-both' : 'color-palette__hook is-up');
6970            }
6971            toggleClick = !toggleClick;
6972          });
6973          $(this).after(lock);
6974          locks.push(lock);
6975        }
6976
6977        var hook = $('<div class="color-palette__hook"></div>');
6978        $(this).after(hook);
6979        hooks.push(hook);
6980
6981        $(this).parent().find('.color-palette__lock').trigger('click');
6982        this.i = i;
6983        inputs.push(this);
6984      }).on('focus', focus);
6985
6986      form.find('.js-color-palette label');
6987
6988      inputs[0].focus();
6989
6990      preview();
6991    }
6992  };
6993})(jQuery, Drupal);;
6994(function ($) {
6995
6996  "use strict";
6997
6998  Drupal.behaviors.environmentIndicatorSwitcher = {
6999    attach: function (context, settings) {
7000      $('#environment-indicator', context).bind('click', function () {
7001        $('#environment-indicator .environment-switcher-container', context).slideToggle('fast');
7002      });
7003    }
7004  };
7005
7006  Drupal.behaviors.environmentIndicatorToolbar = {
7007    attach: function (context, settings) {
7008      if (typeof drupalSettings.environment_indicator != 'undefined') {
7009        return;
7010      }
7011      $('#toolbar-bar', context).css('background-color', settings.environmentIndicator.bgColor);
7012      $('#toolbar-bar .toolbar-item, #toolbar-bar .toolbar-item a', context).css('color', settings.environmentIndicator.fgColor);
7013    }
7014  };
7015
7016  Drupal.behaviors.environmentIndicatorTinycon = {
7017    attach: function (context, settings) {
7018      if (typeof(settings.environmentIndicator) != 'undefined' &&
7019        typeof(settings.environmentIndicator.addFavicon) != 'undefined' &&
7020        settings.environmentIndicator.addFavicon) {
7021        // Draw favicon label.
7022        Tinycon.setBubble(settings.environmentIndicator.name.slice(0, 1));
7023        Tinycon.setOptions({
7024          background: settings.environmentIndicator.bgColor,
7025          colour: settings.environmentIndicator.fgColor
7026        });
7027      }
7028    }
7029  }
7030
7031})(jQuery);
7032;
7033var pad = function(num, totalChars) {
7034    var pad = '0';
7035    num = num + '';
7036    while (num.length < totalChars) {
7037        num = pad + num;
7038    }
7039    return num;
7040};
7041
7042// Ratio is between 0 and 1
7043var changeColor = function(color, ratio, darker) {
7044    // Trim trailing/leading whitespace
7045    color = color.replace(/^\s*|\s*$/, '');
7046
7047    // Expand three-digit hex
7048    color = color.replace(
7049        /^#?([a-f0-9])([a-f0-9])([a-f0-9])$/i,
7050        '#$1$1$2$2$3$3'
7051    );
7052
7053    // Calculate ratio
7054    var difference = Math.round(ratio * 256) * (darker ? -1 : 1),
7055        // Determine if input is RGB(A)
7056        rgb = color.match(new RegExp('^rgba?\\(\\s*' +
7057            '(\\d|[1-9]\\d|1\\d{2}|2[0-4][0-9]|25[0-5])' +
7058            '\\s*,\\s*' +
7059            '(\\d|[1-9]\\d|1\\d{2}|2[0-4][0-9]|25[0-5])' +
7060            '\\s*,\\s*' +
7061            '(\\d|[1-9]\\d|1\\d{2}|2[0-4][0-9]|25[0-5])' +
7062            '(?:\\s*,\\s*' +
7063            '(0|1|0?\\.\\d+))?' +
7064            '\\s*\\)$'
7065        , 'i')),
7066        alpha = !!rgb && rgb[4] != null ? rgb[4] : null,
7067
7068        // Convert hex to decimal
7069        decimal = !!rgb? [rgb[1], rgb[2], rgb[3]] : color.replace(
7070            /^#?([a-f0-9][a-f0-9])([a-f0-9][a-f0-9])([a-f0-9][a-f0-9])/i,
7071            function() {
7072                return parseInt(arguments[1], 16) + ',' +
7073                    parseInt(arguments[2], 16) + ',' +
7074                    parseInt(arguments[3], 16);
7075            }
7076        ).split(/,/),
7077        returnValue;
7078
7079    // Return RGB(A)
7080    return !!rgb ?
7081        'rgb' + (alpha !== null ? 'a' : '') + '(' +
7082            Math[darker ? 'max' : 'min'](
7083                parseInt(decimal[0], 10) + difference, darker ? 0 : 255
7084            ) + ', ' +
7085            Math[darker ? 'max' : 'min'](
7086                parseInt(decimal[1], 10) + difference, darker ? 0 : 255
7087            ) + ', ' +
7088            Math[darker ? 'max' : 'min'](
7089                parseInt(decimal[2], 10) + difference, darker ? 0 : 255
7090            ) +
7091            (alpha !== null ? ', ' + alpha : '') +
7092            ')' :
7093        // Return hex
7094        [
7095            '#',
7096            pad(Math[darker ? 'max' : 'min'](
7097                parseInt(decimal[0], 10) + difference, darker ? 0 : 255
7098            ).toString(16), 2),
7099            pad(Math[darker ? 'max' : 'min'](
7100                parseInt(decimal[1], 10) + difference, darker ? 0 : 255
7101            ).toString(16), 2),
7102            pad(Math[darker ? 'max' : 'min'](
7103                parseInt(decimal[2], 10) + difference, darker ? 0 : 255
7104            ).toString(16), 2)
7105        ].join('');
7106};
7107var lighterColor = function(color, ratio) {
7108    return changeColor(color, ratio, false);
7109};
7110var darkerColor = function(color, ratio) {
7111    return changeColor(color, ratio, true);
7112};
7113;
7114/*!
7115 * Tinycon - A small library for manipulating the Favicon
7116 * Tom Moor, http://tommoor.com
7117 * Copyright (c) 2015 Tom Moor
7118 * @license MIT Licensed
7119 * @version 0.6.4
7120 */
7121!function(){var a={},b=null,c=null,d=null,e=null,f={},g=window.devicePixelRatio||1,h=16*g,i={width:7,height:9,font:10*g+"px arial",colour:"#ffffff",background:"#F03D25",fallback:!0,crossOrigin:!0,abbreviate:!0},j=function(){var a=navigator.userAgent.toLowerCase();return function(b){return-1!==a.indexOf(b)}}(),k={ie:j("msie"),chrome:j("chrome"),webkit:j("chrome")||j("safari"),safari:j("safari")&&!j("chrome"),mozilla:j("mozilla")&&!j("chrome")&&!j("safari")},l=function(){for(var a=document.getElementsByTagName("link"),b=0,c=a.length;c>b;b++)if((a[b].getAttribute("rel")||"").match(/\bicon\b/))return a[b];return!1},m=function(){for(var a=document.getElementsByTagName("link"),b=document.getElementsByTagName("head")[0],c=0,d=a.length;d>c;c++){var e="undefined"!=typeof a[c];e&&(a[c].getAttribute("rel")||"").match(/\bicon\b/)&&b.removeChild(a[c])}},n=function(){if(!c||!b){var a=l();c=b=a?a.getAttribute("href"):"/favicon.ico"}return b},o=function(){return e||(e=document.createElement("canvas"),e.width=h,e.height=h),e}
7121,p=function(a){if(a){m();var b=document.createElement("link");b.type="image/x-icon",b.rel="icon",b.href=a,document.getElementsByTagName("head")[0].appendChild(b)}},q=function(a,b){if(!o().getContext||k.ie||k.safari||"force"===f.fallback)return r(a);var c=o().getContext("2d"),b=b||"#000000",e=n();d=document.createElement("img"),d.onload=function(){c.clearRect(0,0,h,h),c.drawImage(d,0,0,d.width,d.height,0,0,h,h),(a+"").length>0&&s(c,a,b),t()},!e.match(/^data/)&&f.crossOrigin&&(d.crossOrigin="anonymous"),d.src=e},r=function(a){if(f.fallback){var b=document.title;"("===b[0]&&(b=b.slice(b.indexOf(" "))),(a+"").length>0?document.title="("+a+") "+b:document.title=b}},s=function(a,b,c){"number"==typeof b&&b>99&&f.abbreviate&&(b=u(b));var d=(b+"").length-1,e=f.width*g+6*g*d,i=f.height*g,j=h-i,l=h-e-g,m=16*g,n=16*g,o=2*g;a.font=(k.webkit?"bold ":"")+f.font,a.fillStyle=f.background,a.strokeStyle=f.background,a.lineWidth=g,a.beginPath(),a.moveTo(l+o,j),a.quadraticCurveTo(l,j,l,j+o),a.lineTo(l,m-o),a.quadraticCurveTo(l,m,l+o,m),a.lineTo(n-o,m),a.quadraticCurveTo(n,m,n,m-o),a.lineTo(n,j+o),a.quadraticCurveTo(n,j,n-o,j),a.closePath(),a.fill(),a.beginPath(),a.strokeStyle="rgba(0,0,0,0.3)",a.moveTo(l+o/2,m),a.lineTo(n-o/2,m),a.stroke(),a.fillStyle=f.colour,a.textAlign="right",a.textBaseline="top",a.fillText(b,2===g?29:15,k.mozilla?7*g:6*g)},t=function(){o().getContext&&p(o().toDataURL())},u=function(a){for(var b=[["G",1e9],["M",1e6],["k",1e3]],c=0;c<b.length;++c)if(a>=b[c][1]){a=v(a/b[c][1])+b[c][0];break}return a},v=function(a,b){var c=new Number(a);return c.toFixed(b)};a.setOptions=function(a){f={};for(var b in i)f[b]=a.hasOwnProperty(b)?a[b]:i[b];return this},a.setImage=function(a){return b=a,t(),this},a.setBubble=function(a,b){return a=a||"",q(a,b),this},a.reset=function(){p(c)},a.setOptions(i),"function"==typeof define&&define.amd?define(a):"undefined"!=typeof module?module.exports=a:window.Tinycon=a}();
7122;
7123/*! jQuery UI - v1.12.1 - 2017-03-31
7124* http://jqueryui.com
7125* Copyright jQuery Foundation and other contributors; Licensed  */
7126!function(a){"function"==typeof define&&define.amd?define(["jquery","../version","../keycode"],a):a(jQuery)}(function(a){function b(a){for(var b,c;a.length&&a[0]!==document;){if(b=a.css("position"),("absolute"===b||"relative"===b||"fixed"===b)&&(c=parseInt(a.css("zIndex"),10),!isNaN(c)&&0!==c))return c;a=a.parent()}return 0}function c(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},a.extend(this._defaults,this.regional[""]),this.regional.en=a.extend(!0,{},this.regional[""]),this.regional["en-US"]=a.extend(!0,{}
vendor: 4,198 bytes, line 7126
7126,this.regional.en),this.dpDiv=d(a("<div id='"+this._mainDivId+"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>"))}function d(b){var c="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return b.on("mouseout",c,function(){a(this).removeClass("ui-state-hover"),this.className.indexOf("ui-datepicker-prev")!==-1&&a(this).removeClass("ui-datepicker-prev-hover"),this.className.indexOf("ui-datepicker-next")!==-1&&a(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",c,e)}function e(){a.datepicker._isDisabledDatepicker(g.inline?g.dpDiv.parent()[0]:g.input[0])||(a(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),a(this).addClass("ui-state-hover"),this.className.indexOf("ui-datepicker-prev")!==-1&&a(this).addClass("ui-datepicker-prev-hover"),this.className.indexOf("ui-datepicker-next")!==-1&&a(this).addClass("ui-datepicker-next-hover"))}function f(b,c){a.extend(b,c);for(var d in c)null==c[d]&&(b[d]=c[d]);return b}a.extend(a.ui,{datepicker:{version:"1.12.1"}});var g;return a.extend(c.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(a){return f(this._defaults,a||{}),this},_attachDatepicker:function(b,c){var d,e,f;d=b.nodeName.toLowerCase(),e="div"===d||"span"===d,b.id||(this.uuid+=1,b.id="dp"+this.uuid),f=this._newInst(a(b),e),f.settings=a.extend({},c||{}),"input"===d?this._connectDatepicker(b,f):e&&this._inlineDatepicker(b,f)},_newInst:function(b,c){var e=b[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1");return{id:e,input:b,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:c,dpDiv:c?d(a("<div class='"+this._inlineClass+" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>")):this.dpDiv}},_connectDatepicker:function(b,c){var d=a(b);c.append=a([]),c.trigger=a([]),d.hasClass(this.markerClassName)||(this._attachments(d,c),d.addClass(this.markerClassName).on("keydown",this._doKeyDown).on("keypress",this._doKeyPress).on("keyup",this._doKeyUp),this._autoSize(c),a.data(b,"datepicker",c),c.settings.disabled&&this._disableDatepicker(b))},_attachments:function(b,c){var d,e,f,g=this._get(c,"appendText"),h=this._get(c,"isRTL");c.append&&c.append.remove(),g&&(c.append=a("<span class='"+this._appendClass+"'>"+g+"</span>"),b[h?"before":"after"](c.append)),b.off("focus",this._showDatepicker),c.trigger&&c.trigger.remove(),d=this._get(c,"showOn"),"focus"!==d&&"both"!==d||b.on("focus",this._showDatepicker),"button"!==d&&"both"!==d||(e=this._get(c,"buttonText"),f=this._get(c,"buttonImage"),c.trigger=a(this._get(c,"buttonImageOnly")?a("<img/>").addClass(this._triggerClass).attr({src:f,alt:e,title:e}):a("<button type='button'></button>").addClass(this._triggerClass).html(f?a("<img/>").attr({src:f,alt:e,title:e}):e)),b[h?"before":"after"](c.trigger),c.trigger.on("click",function(){return a.datepicker._datepickerShowing&&a.datepicker._lastInput===b[0]?a.datepicker._hideDatepicker():a.datepicker._datepickerShowing&&a.datepicker._lastInput!==b[0]?(a.datepicker._hideDatepicker(),a.datepicker._showDatepicker(b[0])):a.datepicker._showDatepicker(b[0]),!1}))},_autoSize:function(a){if(this._get(a,"autoSize")&&!a.inline){var b,c,d,e,f=new Date(2009,11,20),g=this._get(a,"dateFormat");g.match(/[DM]/)&&(b=function(a){for(c=0,d=0,e=0;e<a.length;e++)a[e].length>c&&(c=a[e].length,d=e);return d},f.setMonth(b(this._get(a,g.match(/MM/)?"monthNames":"monthNamesShort"))),f.setDate(b(this._get(a,g.match(/DD/)?"dayNames":"dayNamesShort"))+20-f.getDay())),a.input.attr("size",this._formatDate(a,f).length)}},_inlineDatepicker:function(b,c){var d=a(b);d.hasClass(this.markerClassName)||(d.addClass(this.markerClassName).append(c.dpDiv),a.data(b,"datepicker",c),this._setDate(c,this._getDefaultDate(c),!0),this._updateDatepicker(c),this._updateAlternate(c),c.settings.disabled&&this._disableDatepicker(b),c.dpDiv.css("display","block"))},_dialogDatepicker:function(b,c,d,e,g){var h,i,j,k,l,m=this._dialogInst;return m||(this.uuid+=1,h="dp"+this.uuid,this._dialogInput=a("<input type='text' id='"+h+"' style='position: absolute; top: -100px; width: 0px;'/>
7126"),this._dialogInput.on("keydown",this._doKeyDown),a("body").append(this._dialogInput),m=this._dialogInst=this._newInst(this._dialogInput,!1),m.settings={},a.data(this._dialogInput[0],"datepicker",m)),f(m.settings,e||{}),c=c&&c.constructor===Date?this._formatDate(m,c):c,this._dialogInput.val(c),this._pos=g?g.length?g:[g.pageX,g.pageY]:null,this._pos||(i=document.documentElement.clientWidth,j=document.documentElement.clientHeight,k=document.documentElement.scrollLeft||document.body.scrollLeft,l=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[i/2-100+k,j/2-150+l]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),m.settings.onSelect=d,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),a.blockUI&&a.blockUI(this.dpDiv),a.data(this._dialogInput[0],"datepicker",m),this},_destroyDatepicker:function(b){var c,d=a(b),e=a.data(b,"datepicker");d.hasClass(this.markerClassName)&&(c=b.nodeName.toLowerCase(),a.removeData(b,"datepicker"),"input"===c?(e.append.remove(),e.trigger.remove(),d.removeClass(this.markerClassName).off("focus",this._showDatepicker).off("keydown",this._doKeyDown).off("keypress",this._doKeyPress).off("keyup",this._doKeyUp)):"div"!==c&&"span"!==c||d.removeClass(this.markerClassName).empty(),g===e&&(g=null))},_enableDatepicker:function(b){var c,d,e=a(b),f=a.data(b,"datepicker");e.hasClass(this.markerClassName)&&(c=b.nodeName.toLowerCase(),"input"===c?(b.disabled=!1,f.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):"div"!==c&&"span"!==c||(d=e.children("."+this._inlineClass),d.children().removeClass("ui-state-disabled"),d.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=a.map(this._disabledInputs,function(a){return a===b?null:a}))},_disableDatepicker:function(b){var c,d,e=a(b),f=a.data(b,"datepicker");e.hasClass(this.markerClassName)&&(c=b.nodeName.toLowerCase(),"input"===c?(b.disabled=!0,f.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):"div"!==c&&"span"!==c||(d=e.children("."+this._inlineClass),d.children().addClass("ui-state-disabled"),d.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=a.map(this._disabledInputs,function(a){return a===b?null:a}),this._disabledInputs[this._disabledInputs.length]=b)},_isDisabledDatepicker:function(a){if(!a)return!1;for(var b=0;b<this._disabledInputs.length;b++)if(this._disabledInputs[b]===a)return!0;return!1},_getInst:function(b){try{return a.data(b,"datepicker")}catch(c){throw"Missing instance data for this datepicker"}},_optionDatepicker:function(b,c,d){var e,g,h,i,j=this._getInst(b);return 2===arguments.length&&"string"==typeof c?"defaults"===c?a.extend({},a.datepicker._defaults):j?"all"===c?a.extend({},j.settings):this._get(j,c):null:(e=c||{},"string"==typeof c&&(e={},e[c]=d),void(j&&(this._curInst===j&&this._hideDatepicker(),g=this._getDateDatepicker(b,!0),h=this._getMinMaxDate(j,"min"),i=this._getMinMaxDate(j,"max"),f(j.settings,e),null!==h&&void 0!==e.dateFormat&&void 0===e.minDate&&(j.settings.minDate=this._formatDate(j,h)),null!==i&&void 0!==e.dateFormat&&void 0===e.maxDate&&(j.settings.maxDate=this._formatDate(j,i)),"disabled"in e&&(e.disabled?this._disableDatepicker(b):this._enableDatepicker(b)),this._attachments(a(b),j),this._autoSize(j),this._setDate(j,g),this._updateAlternate(j),this._updateDatepicker(j))))},_changeDatepicker:function(a,b,c){this._optionDatepicker(a,b,c)},_refreshDatepicker:function(a){var b=this._getInst(a);b&&this._updateDatepicker(b)},_setDateDatepicker:function(a,b){var c=this._getInst(a);c&&(this._setDate(c,b),this._updateDatepicker(c),this._updateAlternate(c))},_getDateDatepicker:function(a,b){var c=this._getInst(a);return c&&!c.inline&&this._setDateFromField(c,b),c?this._getDate(c):null},_doKeyDown:function(b){var c,d,e,f=a.datepicker._getInst(b.target),g=!0,h=f.dpDiv.is(".ui-datepicker-rtl");if(f._keyEvent=!0,a.datepicker._datepickerShowing)switch(b.keyCode){case 9:a.datepicker._hideDatepicker(),g=!1;break;case 13:return e=a("td."+a.datepicker._dayOverClass+":not(."+a.datepicker._currentClass+")",f.dpDiv),e[0]&&a.datepicker._selectDay(b.target,f.selectedMonth,f.selectedYear,e[0]),c=a.datepicker._get(f,"onSelect"),c?(d=a.datepicker._formatDate(f),c.apply(f.input?f.input[0]:null,[d,f])):a.datepicker._hideDatepicker(),!1;case 27:a.datepicker._hideDatepicker();break;case 33:a.datepicker._adjustDate(b.target,b.ctrlKey?-a.datepicker._get(f,"stepBigMonths"):-a.datepicker._get(f,"stepMonths"),"M");break;case 34:a.datepicker._adjustDate(b.target,b.ctrlKey?+a.datepicker._get(f,"stepBigMonths"):+a.datepicker._get(f,"stepMonths"),"M");break;case 35:(b.ctrlKey||b.metaKey)&&a.datepicker._clearDate(b.target),g=b.ctrlKey||b.metaKey;break;case 36:(b.ctrlKey||b.metaKey)&&a.datepicker._gotoToday(b.target),g=b.ctrlKey||b.metaKey;break;case 37:(b.ctrlKey||b.metaKey)&&a.datepicker._adjustDate(b.target,h?1:-1,"D"),g=b.ctrlKey||b.metaKey,b.originalEvent.altKey&&a.datepicker._adjustDate(b.target,b.ctrlKey?-a.datepicker._get(f,"stepBigMonths"):-a.datepicker._get(f,"stepMonths"),"M");break;case 38:(b.ctrlKey||b.metaKey)&&a.datepicker._adjustDate(b.target,-7,"D"),g=b.ctrlKey||b.metaKey;break;case 39:(b.ctrlKey||b.metaKey)&&a.datepicker._adjustDate(b.target,h?-1:1,"D"),g=b.ctrlKey||b.metaKey,b.originalEvent.altKey&&a.datepicker._adjustDate(b.target,b.ctrlKey?+a.datepicker._get(f,"stepBigMonths"):+a.datepicker._get(f,"stepMonths"),"M");break;case 40:(b.ctrlKey||b.metaKey)&&a.datepicker._adjustDate(b.target,7,"D"),g=b.ctrlKey||b.metaKey;break;default:g=!1}else 36===b.keyCode&&b.ctrlKey?a.datepicker._showDatepicker(this):g=!1;g&&(b.preventDefault(),b.stopPropagation())},_doKeyPress:function(b){var c,d,e=a.datepicker._getInst(b.target);if(a.datepicker._get(e,"constrainInput"))return c=a.datepicker._possibleChars(a.datepicker._get(e,"dateFormat")),d=String.fromCharCode(null==b.charCode?b.keyCode:b.charCode),b.ctrlKey||b.metaKey||d<" "||!c||c.indexOf(d)>-1},_doKeyUp:function(b){var c,d=a.datepicker._getInst(b.target);if(d.input.val()!==d.lastVal)try{c=a.datepicker.parseDate(a.datepicker._get(d,"dateFormat"),d.input?d.input.val():null,a.datepicker._getFormatConfig(d)),c&&(a.datepicker._setDateFromField(d),a.datepicker._updateAlternate(d),a.datepicker._updateDatepicker(d
vendor: 6,363 bytes, line 7126
7126))}catch(e){}return!0},_showDatepicker:function(c){if(c=c.target||c,"input"!==c.nodeName.toLowerCase()&&(c=a("input",c.parentNode)[0]),!a.datepicker._isDisabledDatepicker(c)&&a.datepicker._lastInput!==c){var d,e,g,h,i,j,k;d=a.datepicker._getInst(c),a.datepicker._curInst&&a.datepicker._curInst!==d&&(a.datepicker._curInst.dpDiv.stop(!0,!0),d&&a.datepicker._datepickerShowing&&a.datepicker._hideDatepicker(a.datepicker._curInst.input[0])),e=a.datepicker._get(d,"beforeShow"),g=e?e.apply(c,[c,d]):{},g!==!1&&(f(d.settings,g),d.lastVal=null,a.datepicker._lastInput=c,a.datepicker._setDateFromField(d),a.datepicker._inDialog&&(c.value=""),a.datepicker._pos||(a.datepicker._pos=a.datepicker._findPos(c),a.datepicker._pos[1]+=c.offsetHeight),h=!1,a(c).parents().each(function(){return h|="fixed"===a(this).css("position"),!h}),i={left:a.datepicker._pos[0],top:a.datepicker._pos[1]},a.datepicker._pos=null,d.dpDiv.empty(),d.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),a.datepicker._updateDatepicker(d),i=a.datepicker._checkOffset(d,i,h),d.dpDiv.css({position:a.datepicker._inDialog&&a.blockUI?"static":h?"fixed":"absolute",display:"none",left:i.left+"px",top:i.top+"px"}),d.inline||(j=a.datepicker._get(d,"showAnim"),k=a.datepicker._get(d,"duration"),d.dpDiv.css("z-index",b(a(c))+1),a.datepicker._datepickerShowing=!0,a.effects&&a.effects.effect[j]?d.dpDiv.show(j,a.datepicker._get(d,"showOptions"),k):d.dpDiv[j||"show"](j?k:null),a.datepicker._shouldFocusInput(d)&&d.input.trigger("focus"),a.datepicker._curInst=d))}},_updateDatepicker:function(b){this.maxRows=4,g=b,b.dpDiv.empty().append(this._generateHTML(b)),this._attachHandlers(b);var c,d=this._getNumberOfMonths(b),f=d[1],h=17,i=b.dpDiv.find("."+this._dayOverClass+" a");i.length>0&&e.apply(i.get(0)),b.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""),f>1&&b.dpDiv.addClass("ui-datepicker-multi-"+f).css("width",h*f+"em"),b.dpDiv[(1!==d[0]||1!==d[1]?"add":"remove")+"Class"]("ui-datepicker-multi"),b.dpDiv[(this._get(b,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl"),b===a.datepicker._curInst&&a.datepicker._datepickerShowing&&a.datepicker._shouldFocusInput(b)&&b.input.trigger("focus"),b.yearshtml&&(c=b.yearshtml,setTimeout(function(){c===b.yearshtml&&b.yearshtml&&b.dpDiv.find("select.ui-datepicker-year:first").replaceWith(b.yearshtml),c=b.yearshtml=null},0))},_shouldFocusInput:function(a){return a.input&&a.input.is(":visible")&&!a.input.is(":disabled")&&!a.input.is(":focus")},_checkOffset:function(b,c,d){var e=b.dpDiv.outerWidth(),f=b.dpDiv.outerHeight(),g=b.input?b.input.outerWidth():0,h=b.input?b.input.outerHeight():0,i=document.documentElement.clientWidth+(d?0:a(document).scrollLeft()),j=document.documentElement.clientHeight+(d?0:a(document).scrollTop());return c.left-=this._get(b,"isRTL")?e-g:0,c.left-=d&&c.left===b.input.offset().left?a(document).scrollLeft():0,c.top-=d&&c.top===b.input.offset().top+h?a(document).scrollTop():0,c.left-=Math.min(c.left,c.left+e>i&&i>e?Math.abs(c.left+e-i):0),c.top-=Math.min(c.top,c.top+f>j&&j>f?Math.abs(f+h):0),c},_findPos:function(b){for(var c,d=this._getInst(b),e=this._get(d,"isRTL");b&&("hidden"===b.type||1!==b.nodeType||a.expr.filters.hidden(b));)b=b[e?"previousSibling":"nextSibling"];return c=a(b).offset(),[c.left,c.top]},_hideDatepicker:function(b){var c,d,e,f,g=this._curInst;!g||b&&g!==a.data(b,"datepicker")||this._datepickerShowing&&(c=this._get(g,"showAnim"),d=this._get(g,"duration"),e=function(){a.datepicker._tidyDialog(g)},a.effects&&(a.effects.effect[c]||a.effects[c])?g.dpDiv.hide(c,a.datepicker._get(g,"showOptions"),d,e):g.dpDiv["slideDown"===c?"slideUp":"fadeIn"===c?"fadeOut":"hide"](c?d:null,e),c||e(),this._datepickerShowing=!1,f=this._get(g,"onClose"),f&&f.apply(g.input?g.input[0]:null,[g.input?g.input.val():"",g]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),a.blockUI&&(a.unblockUI(),a("body").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(a){a.dpDiv.removeClass(this._dialogClass).off(".ui-datepicker-calendar")},_checkExternalClick:function(b){if(a.datepicker._curInst){var c=a(b.target),d=a.datepicker._getInst(c[0]);(c[0].id===a.datepicker._mainDivId||0!==c.parents("#"+a.datepicker._mainDivId).length||c.hasClass(a.datepicker.markerClassName)||c.closest("."+a.datepicker._triggerClass).length||!a.datepicker._datepickerShowing||a.datepicker._inDialog&&a.blockUI)&&(!c.hasClass(a.datepicker.markerClassName)||a.datepicker._curInst===d)||a.datepicker._hideDatepicker()}},_adjustDate:function(b,c,d){var e=a(b),f=this._getInst(e[0]);this._isDisabledDatepicker(e[0])||(this._adjustInstDate(f,c+("M"===d?this._get(f,"showCurrentAtPos"):0),d),this._updateDatepicker(f))},_gotoToday:function(b){var c,d=a(b),e=this._getInst(d[0]);this._get(e,"gotoCurrent")&&e.currentDay?(e.selectedDay=e.currentDay,e.drawMonth=e.selectedMonth=e.currentMonth,e.drawYear=e.selectedYear=e.currentYear):(c=new Date,e.selectedDay=c.getDate(),e.drawMonth=e.selectedMonth=c.getMonth(),e.drawYear=e.selectedYear=c.getFullYear()),this._notifyChange(e),this._adjustDate(d)},_selectMonthYear:function(b,c,d){var e=a(b),f=this._getInst(e[0]);f["selected"+("M"===d?"Month":"Year")]=f["draw"+("M"===d?"Month":"Year")]=parseInt(c.options[c.selectedIndex].value,10),this._notifyChange(f),this._adjustDate(e)},_selectDay:function(b,c,d,e){var f,g=a(b);a(e).hasClass(this._unselectableClass)||this._isDisabledDatepicker(g[0])||(f=this._getInst(g[0]),f.selectedDay=f.currentDay=a("a",e).html(),f.selectedMonth=f.currentMonth=c,f.selectedYear=f.currentYear=d,this._selectDate(b,this._formatDate(f,f.currentDay,f.currentMonth,f.currentYear)))},_clearDate:function(b){var c=a(b);this._selectDate(c,"")},_selectDate:function(b,c){var d,e=a(b),f=this._getInst(e[0]);c=null!=c?c:this._formatDate(f),f.input&&f.input.val(c),this._updateAlternate(f),d=this._get(f,"onSelect"),d?d.apply(f.input?f.input[0]:null,[c,f]):f.input&&f.input.trigger("change"),f.inline?this._updateDatepicker(f):(this._hideDatepicker(),this._lastInput=f.input[0],"object"!=typeof f.input[0]&&f.input.trigger("focus"),this._lastInput=null)},_updateAlternate:function(b){var c,d,e,f=this._get(b,"altField");f&&(c=this._get(b,"altFormat")||this._get(b,"dateFormat"),d=this._getDate(b),e=this.formatDate(c,d,this._getFormatConfig(b)),a(f).val(e))}
vendor: 14,391 bytes, lines 7126-7127
7126,noWeekends:function(a){var b=a.getDay();return[b>0&&b<6,""]},iso8601Week:function(a){var b,c=new Date(a.getTime());return c.setDate(c.getDate()+4-(c.getDay()||7)),b=c.getTime(),c.setMonth(0),c.setDate(1),Math.floor(Math.round((b-c)/864e5)/7)+1},parseDate:function(b,c,d){if(null==b||null==c)throw"Invalid arguments";if(c="object"==typeof c?c.toString():c+"",""===c)return null;var e,f,g,h,i=0,j=(d?d.shortYearCutoff:null)||this._defaults.shortYearCutoff,k="string"!=typeof j?j:(new Date).getFullYear()%100+parseInt(j,10),l=(d?d.dayNamesShort:null)||this._defaults.dayNamesShort,m=(d?d.dayNames:null)||this._defaults.dayNames,n=(d?d.monthNamesShort:null)||this._defaults.monthNamesShort,o=(d?d.monthNames:null)||this._defaults.monthNames,p=-1,q=-1,r=-1,s=-1,t=!1,u=function(a){var c=e+1<b.length&&b.charAt(e+1)===a;return c&&e++,c},v=function(a){var b=u(a),d="@"===a?14:"!"===a?20:"y"===a&&b?4:"o"===a?3:2,e="y"===a?d:1,f=new RegExp("^\\d{"+e+","+d+"}"),g=c.substring(i).match(f);if(!g)throw"Missing number at position "+i;return i+=g[0].length,parseInt(g[0],10)},w=function(b,d,e){var f=-1,g=a.map(u(b)?e:d,function(a,b){return[[b,a]]}).sort(function(a,b){return-(a[1].length-b[1].length)});if(a.each(g,function(a,b){var d=b[1];if(c.substr(i,d.length).toLowerCase()===d.toLowerCase())return f=b[0],i+=d.length,!1}),f!==-1)return f+1;throw"Unknown name at position "+i},x=function(){if(c.charAt(i)!==b.charAt(e))throw"Unexpected literal at position "+i;i++};for(e=0;e<b.length;e++)if(t)"'"!==b.charAt(e)||u("'")?x():t=!1;else switch(b.charAt(e)){case"d":r=v("d");break;case"D":w("D",l,m);break;case"o":s=v("o");break;case"m":q=v("m");break;case"M":q=w("M",n,o);break;case"y":p=v("y");break;case"@":h=new Date(v("@")),p=h.getFullYear(),q=h.getMonth()+1,r=h.getDate();break;case"!":h=new Date((v("!")-this._ticksTo1970)/1e4),p=h.getFullYear(),q=h.getMonth()+1,r=h.getDate();break;case"'":u("'")?x():t=!0;break;default:x()}if(i<c.length&&(g=c.substr(i),!/^\s+/.test(g)))throw"Extra/unparsed characters found in date: "+g;if(p===-1?p=(new Date).getFullYear():p<100&&(p+=(new Date).getFullYear()-(new Date).getFullYear()%100+(p<=k?0:-100)),s>-1)for(q=1,r=s;;){if(f=this._getDaysInMonth(p,q-1),r<=f)break;q++,r-=f}if(h=this._daylightSavingAdjust(new Date(p,q-1,r)),h.getFullYear()!==p||h.getMonth()+1!==q||h.getDate()!==r)throw"Invalid date";return h},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TICKS:"!",TIMESTAMP:"@",W3C:"yy-mm-dd",_ticksTo1970:24*(718685+Math.floor(492.5)-Math.floor(19.7)+Math.floor(4.925))*60*60*1e7,formatDate:function(a,b,c){if(!b)return"";var d,e=(c?c.dayNamesShort:null)||this._defaults.dayNamesShort,f=(c?c.dayNames:null)||this._defaults.dayNames,g=(c?c.monthNamesShort:null)||this._defaults.monthNamesShort,h=(c?c.monthNames:null)||this._defaults.monthNames,i=function(b){var c=d+1<a.length&&a.charAt(d+1)===b;return c&&d++,c},j=function(a,b,c){var d=""+b;if(i(a))for(;d.length<c;)d="0"+d;return d},k=function(a,b,c,d){return i(a)?d[b]:c[b]},l="",m=!1;if(b)for(d=0;d<a.length;d++)if(m)"'"!==a.charAt(d)||i("'")?l+=a.charAt(d):m=!1;else switch(a.charAt(d)){case"d":l+=j("d",b.getDate(),2);break;case"D":l+=k("D",b.getDay(),e,f);break;case"o":l+=j("o",Math.round((new Date(b.getFullYear(),b.getMonth(),b.getDate()).getTime()-new Date(b.getFullYear(),0,0).getTime())/864e5),3);break;case"m":l+=j("m",b.getMonth()+1,2);break;case"M":l+=k("M",b.getMonth(),g,h);break;case"y":l+=i("y")?b.getFullYear():(b.getFullYear()%100<10?"0":"")+b.getFullYear()%100;break;case"@":l+=b.getTime();break;case"!":l+=1e4*b.getTime()+this._ticksTo1970;break;case"'":i("'")?l+="'":m=!0;break;default:l+=a.charAt(d)}return l},_possibleChars:function(a){var b,c="",d=!1,e=function(c){var d=b+1<a.length&&a.charAt(b+1)===c;return d&&b++,d};for(b=0;b<a.length;b++)if(d)"'"!==a.charAt(b)||e("'")?c+=a.charAt(b):d=!1;else switch(a.charAt(b)){case"d":case"m":case"y":case"@":c+="0123456789";break;case"D":case"M":return null;case"'":e("'")?c+="'":d=!0;break;default:c+=a.charAt(b)}return c},_get:function(a,b){return void 0!==a.settings[b]?a.settings[b]:this._defaults[b]},_setDateFromField:function(a,b){if(a.input.val()!==a.lastVal){var c=this._get(a,"dateFormat"),d=a.lastVal=a.input?a.input.val():null,e=this._getDefaultDate(a),f=e,g=this._getFormatConfig(a);try{f=this.parseDate(c,d,g)||e}catch(h){d=b?"":d}a.selectedDay=f.getDate(),a.drawMonth=a.selectedMonth=f.getMonth(),a.drawYear=a.selectedYear=f.getFullYear(),a.currentDay=d?f.getDate():0,a.currentMonth=d?f.getMonth():0,a.currentYear=d?f.getFullYear():0,this._adjustInstDate(a)}},_getDefaultDate:function(a){return this._restrictMinMax(a,this._determineDate(a,this._get(a,"defaultDate"),new Date))},_determineDate:function(b,c,d){var e=function(a){var b=new Date;return b.setDate(b.getDate()+a),b},f=function(c){try{return a.datepicker.parseDate(a.datepicker._get(b,"dateFormat"),c,a.datepicker._getFormatConfig(b))}catch(d){}for(var e=(c.toLowerCase().match(/^c/)?a.datepicker._getDate(b):null)||new Date,f=e.getFullYear(),g=e.getMonth(),h=e.getDate(),i=/([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,j=i.exec(c);j;){switch(j[2]||"d"){case"d":case"D":h+=parseInt(j[1],10);break;case"w":case"W":h+=7*parseInt(j[1],10);break;case"m":case"M":g+=parseInt(j[1],10),h=Math.min(h,a.datepicker._getDaysInMonth(f,g));break;case"y":case"Y":f+=parseInt(j[1],10),h=Math.min(h,a.datepicker._getDaysInMonth(f,g))}j=i.exec(c)}return new Date(f,g,h)},g=null==c||""===c?d:"string"==typeof c?f(c):"number"==typeof c?isNaN(c)?d:e(c):new Date(c.getTime());return g=g&&"Invalid Date"===g.toString()?d:g,g&&(g.setHours(0),g.setMinutes(0),g.setSeconds(0),g.setMilliseconds(0)),this._daylightSavingAdjust(g)},_daylightSavingAdjust:function(a){return a?(a.setHours(a.getHours()>12?a.getHours()+2:0),a):null},_setDate:function(a,b,c){var d=!b,e=a.selectedMonth,f=a.selectedYear,g=this._restrictMinMax(a,this._determineDate(a,b,new Date));a.selectedDay=a.currentDay=g.getDate(),a.drawMonth=a.selectedMonth=a.currentMonth=g.getMonth(),a.drawYear=a.selectedYear=a.currentYear=g.getFullYear(),e===a.selectedMonth&&f===a.selectedYear||c||this._notifyChange(a),this._adjustInstDate(a),a.input&&a.input.val(d?"":this._formatDate(a))},_getDate:function(a){var b=!a.currentYear||a.input&&""===a.input.val()?null:this._daylightSavingAdjust(new Date(a.currentYear,a.currentMonth,a.currentDay));return b},_attachHandlers:function(b){var c=this._get(b,"stepMonths"),d="#"+b.id.replace(/\\\\/g,"\\");b.dpDiv.find("[data-handler]").map(function(){var b={prev:function(){a.datepicker._adjustDate(d,-c,"M")},next:function(){a.datepicker._adjustDate(d,+c,"M")},hide:function(){a.datepicker._hideDatepicker()},today:function(){a.datepicker._gotoToday(d)},selectDay:function(){return a.datepicker._selectDay(d,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return a.datepicker._selectMonthYear(d,this,"M"),!1},selectYear:function(){return a.datepicker._selectMonthYear(d,this,"Y"),!1}};a(this).on(this.getAttribute("data-event"),b[this.getAttribute("data-handler")])})},_generateHTML:function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O=new Date,P=this._daylightSavingAdjust(new Date(O.getFullYear(),O.getMonth(),O.getDate())),Q=this._get(a,"isRTL"),R=this._get(a,"showButtonPanel"),S=this._get(a,"hideIfNoPrevNext"),T=this._get(a,"navigationAsDateFormat"),U=this._getNumberOfMonths(a),V=this._get(a,"showCurrentAtPos"),W=this._get(a,"stepMonths"),X=1!==U[0]||1!==U[1],Y=this._daylightSavingAdjust(a.currentDay?new Date(a.currentYear,a.currentMonth,a.currentDay):new Date(9999,9,9)),Z=this._getMinMaxDate(a,"min"),$=this._getMinMaxDate(a,"max"),_=a.drawMonth-V,aa=a.drawYear;if(_<0&&(_+=12,aa--),$)for(b=this._daylightSavingAdjust(new Date($.getFullYear(),$.getMonth()-U[0]*U[1]+1,$.getDate())),b=Z&&b<Z?Z:b;this._daylightSavingAdjust(new Date(aa,_,1))>b;)_--,_<0&&(_=11,aa--);for(a.drawMonth=_,a.drawYear=aa,c=this._get(a,"prevText"),c=T?this.formatDate(c,this._daylightSavingAdjust(new Date(aa,_-W,1)),this._getFormatConfig(a)):c,d=this._canAdjustMonth(a,-1,aa,_)?"<a class='ui-datepicker-prev ui-corner-all' data-handler='prev' data-event='click' title='"+c+"'><span class='ui-icon ui-icon-circle-triangle-"+(Q?"e":"w")+"'>"+c+"</span></a>":S?"":"<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='"+c+"'><span class='ui-icon ui-icon-circle-triangle-"+(Q?"e":"w")+"'>"+c+"</span></a>",e=this._get(a,"nextText"),e=T?this.formatDate(e,this._daylightSavingAdjust(new Date(aa,_+W,1)),this._getFormatConfig(a)):e,f=this._canAdjustMonth(a,1,aa,_)?"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click' title='"+e+"'><span class='ui-icon ui-icon-circle-triangle-"+(Q?"w":"e")+"'>"+e+"</span></a>":S?"":"<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='"+e+"'><span class='ui-icon ui-icon-circle-triangle-"+(Q?"w":"e")+"'>"+e+"</span></a>",g=this._get(a,"currentText"),h=this._get(a,"gotoCurrent")&&a.currentDay?Y:P,g=T?this.formatDate(g,h,this._getFormatConfig(a)):g,i=a.inline?"":"<button type='button' class='ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all' data-handler='hide' data-event='click'>"+this._get(a,"closeText")+"</button>",j=R?"<div class='ui-datepicker-buttonpane ui-widget-content'>"+(Q?i:"")+(this._isInRange(a,h)?"<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'>"+g+"</button>":"")+(Q?"":i)+"</div>":"",k=parseInt(this._get(a,"firstDay"),10),k=isNaN(k)?0:k,l=this._get(a,"showWeek"),m=this._get(a,"dayNames"),n=this._get(a,"dayNamesMin"),o=this._get(a,"monthNames"),p=this._get(a,"monthNamesShort"),q=this._get(a,"beforeShowDay"),r=this._get(a,"showOtherMonths"),s=this._get(a,"selectOtherMonths"),t=this._getDefaultDate(a),u="",w=0;w<U[0];w++){for(x="",this.maxRows=4,y=0;y<U[1];y++){if(z=this._daylightSavingAdjust(new Date(aa,_,a.selectedDay)),A=" ui-corner-all",B="",X){if(B+="<div class='ui-datepicker-group",U[1]>1)switch(y){case 0:B+=" ui-datepicker-group-first",A=" ui-corner-"+(Q?"right":"left");break;case U[1]-1:B+=" ui-datepicker-group-last",A=" ui-corner-"+(Q?"left":"right");break;default:B+=" ui-datepicker-group-middle",A=""}B+="'>"}for(B+="<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix"+A+"'>"+(/all|left/.test(A)&&0===w?Q?f:d:"")+(/all|right/.test(A)&&0===w?Q?d:f:"")+this._generateMonthYearHeader(a,_,aa,Z,$,w>0||y>0,o,p)+"</div><table class='ui-datepicker-calendar'><thead><tr>",C=l?"<th class='ui-datepicker-week-col'>"+this._get(a,"weekHeader")+"</th>":"",v=0;v<7;v++)D=(v+k)%7,C+="<th scope='col'"+((v+k+6)%7>=5?" class='ui-datepicker-week-end'":"")+"><span title='"+m[D]+"'>"+n[D]+"</span></th>";for(B+=C+"</tr></thead><tbody>",E=this._getDaysInMonth(aa,_),aa===a.selectedYear&&_===a.selectedMonth&&(a.selectedDay=Math.min(a.selectedDay,E)),F=(this._getFirstDayOfMonth(aa,_)-k+7)%7,G=Math.ceil((F+E)/7),H=X&&this.maxRows>G?this.maxRows:G,this.maxRows=H,I=this._daylightSavingAdjust(new Date(aa,_,1-F)),J=0;J<H;J++){for(B+="<tr>",K=l?"<td class='ui-datepicker-week-col'>"+this._get(a,"calculateWeek")(I)+"</td>":"",v=0;v<7;v++)L=q?q.apply(a.input?a.input[0]:null,[I]):[!0,""],M=I.getMonth()!==_,N=M&&!s||!L[0]||Z&&I<Z||$&&I>$,K+="<td class='"+((v+k+6)%7>=5?" ui-datepicker-week-end":"")+(M?" ui-datepicker-other-month":"")+(I.getTime()===z.getTime()&&_===a.selectedMonth&&a._keyEvent||t.getTime()===I.getTime()&&t.getTime()===z.getTime()?" "+this._dayOverClass:"")+(N?" "+this._unselectableClass+" ui-state-disabled":"")+(M&&!r?"":" "+L[1]+(I.getTime()===Y.getTime()?" "+this._currentClass:"")+(I.getTime()===P.getTime()?" ui-datepicker-today":""))+"'"+(M&&!r||!L[2]?"":" title='"+L[2].replace(/'/g,"&#39;")+"'")+(N?"":" data-handler='selectDay' data-event='click' data-month='"+I.getMonth()+"' data-year='"+I.getFullYear()+"'")+">"+(M&&!r?"&#xa0;":N?"<span class='ui-state-default'>"+I.getDate()+"</span>":"<a class='ui-state-default"+(I.getTime()===P.getTime()?" ui-state-highlight":"")+(I.getTime()===Y.getTime()?" ui-state-active":"")+(M?" ui-priority-secondary":"")+"' href='#'>"+I.getDate()+"</a>")+"</td>",I.setDate(I.getDate()+1),I=this._daylightSavingAdjust(I);B+=K+"</tr>"}_++,_>11&&(_=0,aa++),B+="</tbody></table>"+(X?"</div>"+(U[0]>0&&y===U[1]-1?"<div class='ui-datepicker-row-break'></div>":""):""),x+=B}u+=x}return u+=j,a._keyEvent=!1,u},_generateMonthYearHeader:function(a,b,c,d,e,f,g,h){var i,j,k,l,m,n,o,p,q=this._get(a,"changeMonth"),r=this._get(a,"changeYear"),s=this._get(a,"showMonthAfterYear"),t="<div class='ui-datepicker-title'>",u="";if(f||!q)u+="<span class='ui-datepicker-month'>"+g[b]+"</span>";else{
7127for(i=d&&d.getFullYear()===c,j=e&&e.getFullYear()===c,u+="<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>",k=0;k<12;k++)(!i||k>=d.getMonth())&&(!j||k<=e.getMonth())&&(u+="<option value='"+k+"'"+(k===b?" selected='selected'":"")+">"+h[k]+"</option>");u+="</select>"}if(s||(t+=u+(!f&&q&&r?"":"&#xa0;")),!a.yearshtml)if(a.yearshtml="",f||!r)t+="<span class='ui-datepicker-year'>"+c+"</span>";else{for(l=this._get(a,"yearRange").split(":"),m=(new Date).getFullYear(),n=function(a){var b=a.match(/c[+\-].*/)?c+parseInt(a.substring(1),10):a.match(/[+\-].*/)?m+parseInt(a,10):parseInt(a,10);return isNaN(b)?m:b},o=n(l[0]),p=Math.max(o,n(l[1]||"")),o=d?Math.max(o,d.getFullYear()):o,p=e?Math.min(p,e.getFullYear()):p,a.yearshtml+="<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>";o<=p;o++)a.yearshtml+="<option value='"+o+"'"+(o===c?" selected='selected'":"")+">"+o+"</option>";a.yearshtml+="</select>",t+=a.yearshtml,a.yearshtml=null}return t+=this._get(a,"yearSuffix"),s&&(t+=(!f&&q&&r?"":"&#xa0;")+u),t+="</div>"},_adjustInstDate:function(a,b,c){var d=a.selectedYear+("Y"===c?b:0),e=a.selectedMonth+("M"===c?b:0),f=Math.min(a.selectedDay,this._getDaysInMonth(d,e))+("D"===c?b:0),g=this._restrictMinMax(a,this._daylightSavingAdjust(new Date(d,e,f)));a.selectedDay=g.getDate(),a.drawMonth=a.selectedMonth=g.getMonth(),a.drawYear=a.selectedYear=g.getFullYear(),"M"!==c&&"Y"!==c||this._notifyChange(a)},_restrictMinMax:function(a,b){var c=this._getMinMaxDate(a,"min"),d=this._getMinMaxDate(a,"max"),e=c&&b<c?c:b;return d&&e>d?d:e}
7127,_notifyChange:function(a){var b=this._get(a,"onChangeMonthYear");b&&b.apply(a.input?a.input[0]:null,[a.selectedYear,a.selectedMonth+1,a])},_getNumberOfMonths:function(a){var b=this._get(a,"numberOfMonths");return null==b?[1,1]:"number"==typeof b?[1,b]:b},_getMinMaxDate:function(a,b){return this._determineDate(a,this._get(a,b+"Date"),null)},_getDaysInMonth:function(a,b){return 32-this._daylightSavingAdjust(new Date(a,b,32)).getDate()},_getFirstDayOfMonth:function(a,b){return new Date(a,b,1).getDay()},_canAdjustMonth:function(a,b,c,d){var e=this._getNumberOfMonths(a),f=this._daylightSavingAdjust(new Date(c,d+(b<0?b:e[0]*e[1]),1));return b<0&&f.setDate(this._getDaysInMonth(f.getFullYear(),f.getMonth())),this._isInRange(a,f)},_isInRange:function(a,b){var c,d,e=this._getMinMaxDate(a,"min"),f=this._getMinMaxDate(a,"max"),g=null,h=null,i=this._get(a,"yearRange");return i&&(c=i.split(":"),d=(new Date).getFullYear(),g=parseInt(c[0],10),h=parseInt(c[1],10),c[0].match(/[+\-].*/)&&(g+=d),c[1].match(/[+\-].*/)&&(h+=d)),(!e||b.getTime()>=e.getTime())&&(!f||b.getTime()<=f.getTime())&&(!g||b.getFullYear()>=g)&&(!h||b.getFullYear()<=h)},_getFormatConfig:function(a){var b=this._get(a,"shortYearCutoff");return b="string"!=typeof b?b:(new Date).getFullYear()%100+parseInt(b,10),{shortYearCutoff:b,dayNamesShort:this._get(a,"dayNamesShort"),dayNames:this._get(a,"dayNames"),monthNamesShort:this._get(a,"monthNamesShort"),monthNames:this._get(a,"monthNames")}},_formatDate:function(a,b,c,d){b||(a.currentDay=a.selectedDay,a.currentMonth=a.selectedMonth,a.currentYear=a.selectedYear);var e=b?"object"==typeof b?b:this._daylightSavingAdjust(new Date(d,c,b)):this._daylightSavingAdjust(new Date(a.currentYear,a.currentMonth,a.currentDay));return this.formatDate(this._get(a,"dateFormat"),e,this._getFormatConfig(a))}}),a.fn.datepicker=function(b){if(!this.length)return this;a.datepicker.initialized||(a(document).on("mousedown",a.datepicker._checkExternalClick),a.datepicker.initialized=!0),0===a("#"+a.datepicker._mainDivId).length&&a("body").append(a.datepicker.dpDiv);var c=Array.prototype.slice.call(arguments,1);return"string"!=typeof b||"isDisabled"!==b&&"getDate"!==b&&"widget"!==b?"option"===b&&2===arguments.length&&"string"==typeof arguments[1]?a.datepicker["_"+b+"Datepicker"].apply(a.datepicker,[this[0]].concat(c)):this.each(function(){"string"==typeof b?a.datepicker["_"+b+"Datepicker"].apply(a.datepicker,[this].concat(c)):a.datepicker._attachDatepicker(this,b)}):a.datepicker["_"+b+"Datepicker"].apply(a.datepicker,[this[0]].concat(c))},a.datepicker=new c,a.datepicker.initialized=!1,a.datepicker.uuid=(new Date).getTime(),a.datepicker.version="1.12.1",a.datepicker});;
7128/**
7129* DO NOT EDIT THIS FILE.
7130* See the following change record for more information,
7131* https://www.drupal.org/node/2815083
7132* @preserve
7133**/
7134
7135(function ($, Modernizr, Drupal) {
7136  Drupal.behaviors.date = {
7137    attach: function attach(context, settings) {
7138      var $context = $(context);
7139
7140      if (Modernizr.inputtypes.date === true) {
7141        return;
7142      }
7143      $context.find('input[data-drupal-date-format]').once('datePicker').each(function () {
7144        var $input = $(this);
7145        var datepickerSettings = {};
7146        var dateFormat = $input.data('drupalDateFormat');
7147
7148        datepickerSettings.dateFormat = dateFormat.replace('Y', 'yy').replace('m', 'mm').replace('d', 'dd');
7149
7150        if ($input.attr('min')) {
7151          datepickerSettings.minDate = $input.attr('min');
7152        }
7153        if ($input.attr('max')) {
7154          datepickerSettings.maxDate = $input.attr('max');
7155        }
7156        $input.datepicker(datepickerSettings);
7157      });
7158    },
7159    detach: function detach(context, settings, trigger) {
7160      if (trigger === 'unload') {
7161        $(context).find('input[data-drupal-date-format]').findOnce('datePicker').datepicker('destroy');
7162      }
7163    }
7164  };
7165})(jQuery, Modernizr, Drupal);;

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.