!function(e){"use strict";"function"==typeof define&&define.amd?define(["jquery"],e):e("undefined"!=typeof jQuery?jQuery:window.Zepto)}(function(e){"use strict";function t(t){var r=t.data;t.isDefaultPrevented()||(t.preventDefault(),e(t.target).ajaxSubmit(r))}function r(t){var r=t.target,a=e(r);if(!a.is("[type=submit],[type=image]")){var n=a.closest("[type=submit]");if(0===n.length)return;r=n[0]}var i=this;if(i.clk=r,"image"==r.type)if(void 0!==t.offsetX)i.clk_x=t.offsetX,i.clk_y=t.offsetY;else if("function"==typeof e.fn.offset){var o=a.offset();i.clk_x=t.pageX-o.left,i.clk_y=t.pageY-o.top}else i.clk_x=t.pageX-r.offsetLeft,i.clk_y=t.pageY-r.offsetTop;setTimeout(function(){i.clk=i.clk_x=i.clk_y=null},100)}function a(){if(e.fn.ajaxSubmit.debug){var t="[jquery.form] "+Array.prototype.join.call(arguments,"");window.console&&window.console.log?window.console.log(t):window.opera&&window.opera.postError&&window.opera.postError(t)}}var n={};n.fileapi=void 0!==e("").get(0).files,n.formdata=void 0!==window.FormData;var i=!!e.fn.prop;e.fn.attr2=function(){if(!i)return this.attr.apply(this,arguments);var e=this.prop.apply(this,arguments);return e&&e.jquery||"string"==typeof e?e:this.attr.apply(this,arguments)},e.fn.ajaxSubmit=function(t){function r(r){var a,n,i=e.param(r,t.traditional).split("&"),o=i.length,s=[];for(a=0;o>a;a++)i[a]=i[a].replace(/\+/g," "),n=i[a].split("="),s.push([decodeURIComponent(n[0]),decodeURIComponent(n[1])]);return s}function o(a){for(var n=new FormData,i=0;i').val(m.extraData[d].value).appendTo(w)[0]:e('').val(m.extraData[d]).appendTo(w)[0]);m.iframeTarget||v.appendTo("body"),g.attachEvent?g.attachEvent("onload",s):g.addEventListener("load",s,!1),setTimeout(t,15);try{w.submit()}catch(h){var x=document.createElement("form").submit;x.apply(w)}}finally{w.setAttribute("action",i),w.setAttribute("enctype",c),r?w.setAttribute("target",r):f.removeAttr("target"),e(l).remove()}}function s(t){if(!x.aborted&&!F){if(M=n(g),M||(a("cannot access response document"),t=k),t===D&&x)return x.abort("timeout"),void S.reject(x,"timeout");if(t==k&&x)return x.abort("server abort"),void S.reject(x,"error","server abort");if(M&&M.location.href!=m.iframeSrc||T){g.detachEvent?g.detachEvent("onload",s):g.removeEventListener("load",s,!1);var r,i="success";try{if(T)throw"timeout";var o="xml"==m.dataType||M.XMLDocument||e.isXMLDoc(M);if(a("isXml="+o),!o&&window.opera&&(null===M.body||!M.body.innerHTML)&&--O)return a("requeing onLoad callback, DOM not available"),void setTimeout(s,250);var u=M.body?M.body:M.documentElement;x.responseText=u?u.innerHTML:null,x.responseXML=M.XMLDocument?M.XMLDocument:M,o&&(m.dataType="xml"),x.getResponseHeader=function(e){var t={"content-type":m.dataType};return t[e.toLowerCase()]},u&&(x.status=Number(u.getAttribute("status"))||x.status,x.statusText=u.getAttribute("statusText")||x.statusText);var c=(m.dataType||"").toLowerCase(),l=/(json|script|text)/.test(c);if(l||m.textarea){var f=M.getElementsByTagName("textarea")[0];if(f)x.responseText=f.value,x.status=Number(f.getAttribute("status"))||x.status,x.statusText=f.getAttribute("statusText")||x.statusText;else if(l){var p=M.getElementsByTagName("pre")[0],h=M.getElementsByTagName("body")[0];p?x.responseText=p.textContent?p.textContent:p.innerText:h&&(x.responseText=h.textContent?h.textContent:h.innerText)}}else"xml"==c&&!x.responseXML&&x.responseText&&(x.responseXML=X(x.responseText));try{E=_(x,c,m)}catch(y){i="parsererror",x.error=r=y||i}}catch(y){a("error caught: ",y),i="error",x.error=r=y||i}x.aborted&&(a("upload aborted"),i=null),x.status&&(i=x.status>=200&&x.status<300||304===x.status?"success":"error"),"success"===i?(m.success&&m.success.call(m.context,E,"success",x),S.resolve(x.responseText,"success",x),d&&e.event.trigger("ajaxSuccess",[x,m])):i&&(void 0===r&&(r=x.statusText),m.error&&m.error.call(m.context,x,i,r),S.reject(x,"error",r),d&&e.event.trigger("ajaxError",[x,m,r])),d&&e.event.trigger("ajaxComplete",[x,m]),d&&!--e.active&&e.event.trigger("ajaxStop"),m.complete&&m.complete.call(m.context,x,i),F=!0,m.timeout&&clearTimeout(j),setTimeout(function(){m.iframeTarget?v.attr("src",m.iframeSrc):v.remove(),x.responseXML=null},100)}}}var c,l,m,d,p,v,g,x,y,b,T,j,w=f[0],S=e.Deferred();if(S.abort=function(e){x.abort(e)},r)for(l=0;l'),v.css({position:"absolute",top:"-1000px",left:"-1000px"})),g=v[0],x={aborted:0,responseText:null,responseXML:null,status:0,statusText:"n/a",getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(t){var r="timeout"===t?"timeout":"aborted";a("aborting upload... "+r),this.aborted=1;try{g.contentWindow.document.execCommand&&g.contentWindow.document.execCommand ("Stop")}catch(n){}v.attr("src",m.iframeSrc),x.error=r,m.error&&m.error.call(m.context,x,r,t),d&&e.event.trigger("ajaxError",[x,m,r]),m.complete&&m.complete.call(m.context,x,r)}},d=m.global,d&&0===e.active++&&e.event.trigger("ajaxStart"),d&&e.event.trigger("ajaxSend",[x,m]),m.beforeSend&&m.beforeSend.call(m.context,x,m)===!1)return m.global&&e.active--,S.reject(),S;if(x.aborted)return S.reject(),S;y=w.clk,y&&(b=y.name,b&&!y.disabled&&(m.extraData=m.extraData||{},m.extraData[b]=y.value,"image"==y.type&&(m.extraData[b+".x"]=w.clk_x,m.extraData[b+".y"]=w.clk_y)));var D=1,k=2,A=e("meta[name=csrf-token]").attr("content"),L=e("meta[name=csrf-param]").attr("content");L&&A&&(m.extraData=m.extraData||{},m.extraData[L]=A),m.forceSync?o():setTimeout(o,10);var E,M,F,O=50,X=e.parseXML||function(e,t){return window.ActiveXObject?(t=new ActiveXObject("Microsoft.XMLDOM"),t.async="false",t.loadXML(e)):t=(new DOMParser).parseFromString(e,"text/xml"),t&&t.documentElement&&"parsererror"!=t.documentElement.nodeName?t:null},C=e.parseJSON||function(e){return window.eval("("+e+")")},_=function(t,r,a){var n=t.getResponseHeader("content-type")||"",i="xml"===r||!r&&n.indexOf("xml")>=0,o=i?t.responseXML:t.responseText;return i&&"parsererror"===o.documentElement.nodeName&&e.error&&e.error("parsererror"),a&&a.dataFilter&&(o=a.dataFilter(o,r)),"string"==typeof o&&("json"===r||!r&&n.indexOf("json")>=0?o=C(o):("script"===r||!r&&n.indexOf("javascript")>=0)&&e.globalEval(o)),o};return S}if(!this.length)return a("ajaxSubmit: skipping submit process - no element selected"),this;var u,c,l,f=this;"function"==typeof t?t={success:t}:void 0===t&&(t={}),u=t.type||this.attr2("method"),c=t.url||this.attr2("action"),l="string"==typeof c?e.trim(c):"",l=l||window.location.href||"",l&&(l=(l.match(/^([^#]+)/)||[])[1]),t=e.extend(!0,{url:l,success:e.ajaxSettings.success,type:u||e.ajaxSettings.type,iframeSrc:/^https/i.test(window.location.href||"")?"javascript:false":"about:blank"},t);var m={};if(this.trigger("form-pre-serialize",[this,t,m]),m.veto)return a("ajaxSubmit: submit vetoed via form-pre-serialize trigger"),this;if(t.beforeSerialize&&t.beforeSerialize(this,t)===!1)return a("ajaxSubmit: submit aborted via beforeSerialize callback"),this;var d=t.traditional;void 0===d&&(d=e.ajaxSettings.traditional);var p,h=[],v=this.formToArray(t.semantic,h);if(t.data&&(t.extraData=t.data,p=e.param(t.data,d)),t.beforeSubmit&&t.beforeSubmit(v,this,t)===!1)return a("ajaxSubmit: submit aborted via beforeSubmit callback"),this;if(this.trigger("form-submit-validate",[v,this,t,m]),m.veto)return a("ajaxSubmit: submit vetoed via form-submit-validate trigger"),this;var g=e.param(v,d);p&&(g=g?g+"&"+p:p),"GET"==t.type.toUpperCase()?(t.url+=(t.url.indexOf("?")>=0?"&":"?")+g,t.data=null):t.data=g;var x=[];if(t.resetForm&&x.push(function(){f.resetForm()}),t.clearForm&&x.push(function(){f.clearForm(t.includeHidden)}),!t.dataType&&t.target){var y=t.success||function(){};x.push(function(r){var a=t.replaceTarget?"replaceWith":"html";e(t.target)[a](r).each(y,arguments)})}else t.success&&x.push(t.success);if(t.success=function(e,r,a){for(var n=t.context||this,i=0,o=x.length;o>i;i++)x[i].apply(n,[e,r,a||f,f])},t.error){var b=t.error;t.error=function(e,r,a){var n=t.context||this;b.apply(n,[e,r,a,f])}}if(t.complete){var T=t.complete;t.complete=function(e,r){var a=t.context||this;T.apply(a,[e,r,f])}}var j=e("input[type=file]:enabled",this).filter(function(){return""!==e(this).val()}),w=j.length>0,S="multipart/form-data",D=f.attr("enctype")==S||f.attr("encoding")==S,k=n.fileapi&&n.formdata;a("fileAPI :"+k);var A,L=(w||D)&&!k;t.iframe!==!1&&(t.iframe||L)?t.closeKeepAlive?e.get(t.closeKeepAlive,function(){A=s(v)}):A=s(v):A=(w||D)&&k?o(v):e.ajax(t),f.removeData("jqxhr").data("jqxhr",A);for(var E=0;Ec;c++)if(d=u[c],f=d.name,f&&!d.disabled)if(t&&o.clk&&"image"==d.type)o.clk==d&&(a.push({name:f,value:e(d).val(),type:d.type}),a.push({name:f+".x",value:o.clk_x},{name:f+".y",value:o.clk_y}));else if(m=e.fieldValue(d,!0),m&&m.constructor==Array)for(r&&r.push(d),l=0,h=m.length;h>l;l++)a.push({name:f,value:m[l]});else if(n.fileapi&&"file"==d.type){r&&r.push(d);var v=d.files;if(v.length)for(l=0;li;i++)r.push({name:a,value:n[i]});else null!==n&&"undefined"!=typeof n&&r.push({name:this.name,value:n})}}),e.param(r)},e.fn.fieldValue=function(t){for(var r=[],a=0,n=this.length;n>a;a++){var i=this[a],o=e.fieldValue(i,t);null===o||"undefined"==typeof o||o.constructor==Array&&!o.length||(o.constructor==Array?e.merge(r,o):r.push(o))}return r},e.fieldValue=function(t,r){var a=t.name,n=t.type,i=t.tagName.toLowerCase();if(void 0===r&&(r=!0),r&&(!a||t.disabled||"reset"==n||"button"==n||("checkbox"==n||"radio"==n)&&!t.checked||("submit"==n||"image"==n)&&t.form&&t.form.clk!=t||"select"==i&&-1==t.selectedIndex))return null;if("select"==i){var o=t.selectedIndex;if(0>o)return null;for(var s=[],u=t.options,c="select-one"==n,l=c?o+1:u.length,f=c?o:0;l>f;f++){var m=u[f];if(m.selected){var d=m.value;if(d||(d=m.attributes&&m.attributes.value&&!m.attributes.value.specified?m.text:m.value),c)return d;s.push(d)}}return s}return e(t).val()},e.fn.clearForm=function(t){return this.each(function(){e("input,select,textarea",this).clearFields(t)})},e.fn.clearFields=e.fn.clearInputs=function(t){var r=/^(?:color|date|datetime|email|month|number|password|range|search|tel|text|time|url|week)$/i;return this.each(function(){var a=this.type,n=this.tagName.toLowerCase();r.test(a)||"textarea"==n?this.value="":"checkbox"==a||"radio"==a?this.checked=!1:"select"==n?this.selectedIndex=-1:"file"==a?/MSIE/.test(navigator.userAgent)?e(this).replaceWith(e(this).clone(!0)):e(this).val(""):t&&(t===!0&&/hidden/.test(a)||"string"==typeof t&&e(this).is(t))&&(this.value="")})},e.fn.resetForm=function(){return this.each(function(){("function"==typeof this.reset||"object"==typeof this.reset&&!this.reset.nodeType)&&this.reset()})},e.fn.enable=function(e){return void 0===e&&(e=!0),this.each(function(){this.disabled=!e})},e.fn.selected=function(t){return void 0===t&&(t=!0),this.each(function(){var r=this.type;if("checkbox"==r||"radio"==r)this.checked=t;else if("option"==this.tagName.toLowerCase()){var a=e(this).parent("select");t&&a[0]&&"select-one"==a[0].type&&a.find("option").selected(!1),this.selected=t}})},e.fn.ajaxSubmit.debug=!1}); (function($){ 'use strict'; if(typeof _wpcf7=='undefined'||_wpcf7===null){ return; } _wpcf7=$.extend({ cached: 0 }, _wpcf7); $.fn.wpcf7InitForm=function(){ this.ajaxForm({ beforeSubmit: function(arr, $form, options){ $form.wpcf7ClearResponseOutput(); $form.find('[aria-invalid]').attr('aria-invalid', 'false'); $form.find('.ajax-loader').addClass('is-active'); return true; }, beforeSerialize: function($form, options){ $form.find('[placeholder].placeheld').each(function(i, n){ $(n).val(''); }); return true; }, data: { '_wpcf7_is_ajax_call': 1 }, dataType: 'json', success: $.wpcf7AjaxSuccess, error: function(xhr, status, error, $form){ var e=$('
').text(error.message); $form.after(e); }}); if(_wpcf7.cached){ this.wpcf7OnloadRefill(); } this.wpcf7ToggleSubmit(); this.find('.wpcf7-submit').wpcf7AjaxLoader(); this.find('.wpcf7-acceptance').click(function(){ $(this).closest('form').wpcf7ToggleSubmit(); }); this.find('.wpcf7-exclusive-checkbox').wpcf7ExclusiveCheckbox(); this.find('.wpcf7-list-item.has-free-text').wpcf7ToggleCheckboxFreetext(); this.find('[placeholder]').wpcf7Placeholder(); if(_wpcf7.jqueryUi&&! _wpcf7.supportHtml5.date){ this.find('input.wpcf7-date[type="date"]').each(function(){ $(this).datepicker({ dateFormat: 'yy-mm-dd', minDate: new Date($(this).attr('min')), maxDate: new Date($(this).attr('max')) }); }); } if(_wpcf7.jqueryUi&&! _wpcf7.supportHtml5.number){ this.find('input.wpcf7-number[type="number"]').each(function(){ $(this).spinner({ min: $(this).attr('min'), max: $(this).attr('max'), step: $(this).attr('step') }); }); } this.find('.wpcf7-character-count').wpcf7CharacterCount(); this.find('.wpcf7-validates-as-url').change(function(){ $(this).wpcf7NormalizeUrl(); }); this.find('.wpcf7-recaptcha').wpcf7Recaptcha(); }; $.wpcf7AjaxSuccess=function(data, status, xhr, $form){ if(! $.isPlainObject(data)||$.isEmptyObject(data)){ return; } var $responseOutput=$form.find('div.wpcf7-response-output'); $form.wpcf7ClearResponseOutput(); $form.find('.wpcf7-form-control').removeClass('wpcf7-not-valid'); $form.removeClass('invalid spam sent failed'); if(data.captcha){ $form.wpcf7RefillCaptcha(data.captcha); } if(data.quiz){ $form.wpcf7RefillQuiz(data.quiz); } if(data.invalids){ $.each(data.invalids, function(i, n){ $form.find(n.into).wpcf7NotValidTip(n.message); $form.find(n.into).find('.wpcf7-form-control').addClass('wpcf7-not-valid'); $form.find(n.into).find('[aria-invalid]').attr('aria-invalid', 'true'); }); $responseOutput.addClass('wpcf7-validation-errors'); $form.addClass('invalid'); $(data.into).trigger('wpcf7:invalid'); $(data.into).trigger('invalid.wpcf7'); }else if(1==data.spam){ $form.find('[name="g-recaptcha-response"]').each(function(){ if(''==$(this).val()){ var $recaptcha=$(this).closest('.wpcf7-form-control-wrap'); $recaptcha.wpcf7NotValidTip(_wpcf7.recaptcha.messages.empty); }}); $responseOutput.addClass('wpcf7-spam-blocked'); $form.addClass('spam'); $(data.into).trigger('wpcf7:spam'); $(data.into).trigger('spam.wpcf7'); }else if(1==data.mailSent){ $responseOutput.addClass('wpcf7-mail-sent-ok'); $form.addClass('sent'); if(data.onSentOk){ $.each(data.onSentOk, function(i, n){ eval(n) }); } $(data.into).trigger('wpcf7:mailsent'); $(data.into).trigger('mailsent.wpcf7'); }else{ $responseOutput.addClass('wpcf7-mail-sent-ng'); $form.addClass('failed'); $(data.into).trigger('wpcf7:mailfailed'); $(data.into).trigger('mailfailed.wpcf7'); } if(data.onSubmit){ $.each(data.onSubmit, function(i, n){ eval(n) }); } $(data.into).trigger('wpcf7:submit'); $(data.into).trigger('submit.wpcf7'); if(1==data.mailSent){ $form.resetForm(); } $form.find('[placeholder].placeheld').each(function(i, n){ $(n).val($(n).attr('placeholder')); }); $responseOutput.append(data.message).slideDown('fast'); $responseOutput.attr('role', 'alert'); $.wpcf7UpdateScreenReaderResponse($form, data); }; $.fn.wpcf7ExclusiveCheckbox=function(){ return this.find('input:checkbox').click(function(){ var name=$(this).attr('name'); $(this).closest('form').find('input:checkbox[name="' + name + '"]').not(this).prop('checked', false); }); }; $.fn.wpcf7Placeholder=function(){ if(_wpcf7.supportHtml5.placeholder){ return this; } return this.each(function(){ $(this).val($(this).attr('placeholder')); $(this).addClass('placeheld'); $(this).focus(function(){ if($(this).hasClass('placeheld')) $(this).val('').removeClass('placeheld'); }); $(this).blur(function(){ if(''==$(this).val()){ $(this).val($(this).attr('placeholder')); $(this).addClass('placeheld'); }}); }); }; $.fn.wpcf7AjaxLoader=function(){ return this.each(function(){ $(this).after(''); }); }; $.fn.wpcf7ToggleSubmit=function(){ return this.each(function(){ var form=$(this); if(this.tagName.toLowerCase()!='form'){ form=$(this).find('form').first(); } if(form.hasClass('wpcf7-acceptance-as-validation')){ return; } var submit=form.find('input:submit'); if(! submit.length) return; var acceptances=form.find('input:checkbox.wpcf7-acceptance'); if(! acceptances.length) return; submit.removeAttr('disabled'); acceptances.each(function(i, n){ n=$(n); if(n.hasClass('wpcf7-invert')&&n.is(':checked') || ! n.hasClass('wpcf7-invert')&&! n.is(':checked')){ submit.attr('disabled', 'disabled'); }}); }); }; $.fn.wpcf7ToggleCheckboxFreetext=function(){ return this.each(function(){ var $wrap=$(this).closest('.wpcf7-form-control'); if($(this).find(':checkbox, :radio').is(':checked')){ $(this).find(':input.wpcf7-free-text').prop('disabled', false); }else{ $(this).find(':input.wpcf7-free-text').prop('disabled', true); } $wrap.find(':checkbox, :radio').change(function(){ var $cb=$('.has-free-text', $wrap).find(':checkbox, :radio'); var $freetext=$(':input.wpcf7-free-text', $wrap); if($cb.is(':checked')){ $freetext.prop('disabled', false).focus(); }else{ $freetext.prop('disabled', true); }}); }); }; $.fn.wpcf7CharacterCount=function(){ return this.each(function(){ var $count=$(this); var name=$count.attr('data-target-name'); var down=$count.hasClass('down'); var starting=parseInt($count.attr('data-starting-value'), 10); var maximum=parseInt($count.attr('data-maximum-value'), 10); var minimum=parseInt($count.attr('data-minimum-value'), 10); var updateCount=function($target){ var length=$target.val().length; var count=down ? starting - length:length; $count.attr('data-current-value', count); $count.text(count); if(maximum&&maximum < length){ $count.addClass('too-long'); }else{ $count.removeClass('too-long'); } if(minimum&&length < minimum){ $count.addClass('too-short'); }else{ $count.removeClass('too-short'); }}; $count.closest('form').find(':input[name="' + name + '"]').each(function(){ updateCount($(this)); $(this).keyup(function(){ updateCount($(this)); }); }); }); }; $.fn.wpcf7NormalizeUrl=function(){ return this.each(function(){ var val=$.trim($(this).val()); if(val&&! val.match(/^[a-z][a-z0-9.+-]*:/i)){ val=val.replace(/^\/+/, ''); val='http://' + val; } $(this).val(val); }); }; $.fn.wpcf7NotValidTip=function(message){ return this.each(function(){ var $into=$(this); $into.find('span.wpcf7-not-valid-tip').remove(); $into.append('' + message + ''); if($into.is('.use-floating-validation-tip *')){ $('.wpcf7-not-valid-tip', $into).mouseover(function(){ $(this).wpcf7FadeOut(); }); $(':input', $into).focus(function(){ $('.wpcf7-not-valid-tip', $into).not(':hidden').wpcf7FadeOut(); }); }}); }; $.fn.wpcf7FadeOut=function(){ return this.each(function(){ $(this).animate({ opacity: 0 }, 'fast', function(){ $(this).css({'z-index': -100}); }); }); }; $.fn.wpcf7OnloadRefill=function(){ return this.each(function(){ var url=$(this).attr('action'); if(0 < url.indexOf('#')){ url=url.substr(0, url.indexOf('#')); } var id=$(this).find('input[name="_wpcf7"]').val(); var unitTag=$(this).find('input[name="_wpcf7_unit_tag"]').val(); $.getJSON(url, { _wpcf7_is_ajax_call: 1, _wpcf7: id, _wpcf7_request_ver: $.now() }, function(data){ if(data&&data.captcha){ $('#' + unitTag).wpcf7RefillCaptcha(data.captcha); } if(data&&data.quiz){ $('#' + unitTag).wpcf7RefillQuiz(data.quiz); }} ); }); }; $.fn.wpcf7RefillCaptcha=function(captcha){ return this.each(function(){ var form=$(this); $.each(captcha, function(i, n){ form.find(':input[name="' + i + '"]').clearFields(); form.find('img.wpcf7-captcha-' + i).attr('src', n); var match=/([0-9]+)\.(png|gif|jpeg)$/.exec(n); form.find('input:hidden[name="_wpcf7_captcha_challenge_' + i + '"]').attr('value', match[1]); }); }); }; $.fn.wpcf7RefillQuiz=function(quiz){ return this.each(function(){ var form=$(this); $.each(quiz, function(i, n){ form.find(':input[name="' + i + '"]').clearFields(); form.find(':input[name="' + i + '"]').siblings('span.wpcf7-quiz-label').text(n[0]); form.find('input:hidden[name="_wpcf7_quiz_answer_' + i + '"]').attr('value', n[1]); }); }); }; $.fn.wpcf7ClearResponseOutput=function(){ return this.each(function(){ $(this).find('div.wpcf7-response-output').hide().empty().removeClass('wpcf7-mail-sent-ok wpcf7-mail-sent-ng wpcf7-validation-errors wpcf7-spam-blocked').removeAttr('role'); $(this).find('span.wpcf7-not-valid-tip').remove(); $(this).find('.ajax-loader').removeClass('is-active'); }); }; $.fn.wpcf7Recaptcha=function(){ return this.each(function(){ var events='wpcf7:spam wpcf7:mailsent wpcf7:mailfailed'; $(this).closest('div.wpcf7').on(events, function(e){ if(recaptchaWidgets&&grecaptcha){ $.each(recaptchaWidgets, function(index, value){ grecaptcha.reset(value); }); }}); }); }; $.wpcf7UpdateScreenReaderResponse=function($form, data){ $('.wpcf7 .screen-reader-response').html('').attr('role', ''); if(data.message){ var $response=$form.siblings('.screen-reader-response').first(); $response.append(data.message); if(data.invalids){ var $invalids=$('
    '); $.each(data.invalids, function(i, n){ if(n.idref){ var $li=$('
  • ').append($('').attr('href', '#' + n.idref).append(n.message)); }else{ var $li=$('
  • ').append(n.message); } $invalids.append($li); }); $response.append($invalids); } $response.attr('role', 'alert').focus(); }}; $.wpcf7SupportHtml5=function(){ var features={}; var input=document.createElement('input'); features.placeholder='placeholder' in input; var inputTypes=['email', 'url', 'tel', 'number', 'range', 'date']; $.each(inputTypes, function(index, value){ input.setAttribute('type', value); features[value]=input.type!=='text'; }); return features; }; $(function(){ _wpcf7.supportHtml5=$.wpcf7SupportHtml5(); $('div.wpcf7 > form').wpcf7InitForm(); }); })(jQuery); !function(){function b(c,d){d=d||{bubbles:!1,cancelable:!1,detail:void 0};var e=document.createEvent("CustomEvent");return e.initCustomEvent(c,d.bubbles,d.cancelable,d.detail),e}return"function"!=typeof window.CustomEvent&&(console.log("hi"),b.prototype=window.Event.prototype,void (window.CustomEvent=b))}();var MalinkyAjaxPaging=function($){var init=function(mapVars){function debounce(a,t,n){var o;return function(){var i=this,e=arguments,p=function(){o=null,n||a.apply(i,e)},m=n&&!o;clearTimeout(o),o=setTimeout(p,t),m&&a.apply(i,e)}}var mymapAjaxLoader=mapVars.mapAjaxLoader,mymapCssLoadMore=mapVars.mapCssLoadMore,mymapCssLoadMoreButton=mapVars.mapCssLoadMoreButton,mymapInfiniteScrollBuffer=mapVars.mapInfiniteScrollBuffer,mymapLoadingTimer="",mymapLoadingMorePostsText=mapVars.mapLoadingMorePostsText,mymapLoadMoreButtonText=mapVars.mapLoadMoreButtonText,mymapPaginationClass=mapVars.mapPaginationClass,mymapPaginationClassPixelsToDocBottom=mapVars.mapPaginationClassPixelsToDocBottom,mymapPagingType=mapVars.mapPagingType,mymapPostsWrapperClass=mapVars.mapPostsWrapperClass,mymapPostClass=mapVars.mapPostClass,mymapNextPageSelector=mapVars.mapNextPageSelector,mymapNextPageUrl=mapVars.mapNextPageUrl,mymapPaginatorCount=mapVars.mapPaginatorCount,mymapUserCallback=mapVars.mapUserCallback,infiniteScrollRunning=!1,mapLoadPosts=function(){$.ajax({type:"GET",url:mymapNextPageUrl,dataType:"html",beforeSend:function(){var a=new CustomEvent("malinkyLoadPostsStart");document.dispatchEvent(a)},success:function(a){var t=$.parseHTML(a),n=($(t).find(mymapPostsWrapperClass),mapPaginatorTotalCount(t));mapAddPaginatorCount(t,n);var o=$(t).find(mymapPostsWrapperClass+'[data-paginator-count="'+mymapPaginatorCount+'"] '+mymapPostClass),i=$(mymapPostsWrapperClass+'[data-paginator-count="'+mymapPaginatorCount+'"] '+mymapPostClass).last(),e=$(mymapPostsWrapperClass+'[data-paginator-count="'+mymapPaginatorCount+'"] '+mymapPostClass);if(i.after(o),"infinite-scroll"!=mymapPagingType&&"load-more"!=mymapPagingType||(1==n?mapIsLastPage(t,mymapNextPageSelector)?mymapNextPageUrl=$(t).find(mymapNextPageSelector).attr("href"):($('#malinky-ajax-pagination-button[data-paginator-count="'+mymapPaginatorCount+'"]').parent().remove(),window.removeEventListener("scroll",mapInfiniteScroll)):mapIsLastPage(t,mymapNextPageSelector+'[data-paginator-count="'+mymapPaginatorCount+'"]')?mymapNextPageUrl=$(t).find(mymapNextPageSelector+'[data-paginator-count="'+mymapPaginatorCount+'"]').attr("href"):($('#malinky-ajax-pagination-button[data-paginator-count="'+mymapPaginatorCount+'"]').parent().remove(),window.removeEventListener("scroll",mapInfiniteScroll))),"pagination"==mymapPagingType){e.remove(),history.pushState(null,null,mymapNextPageUrl);var p=$(t).find(mymapPaginationClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').first();$(mymapPaginationClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').replaceWith(p)}mapLoaded()},error:function(a,t){mapFailed()},complete:function(requestObj){var malinkyloadPostsCompleteEvent=new CustomEvent("malinkyLoadPostsComplete");document.dispatchEvent(malinkyloadPostsCompleteEvent),"pagination"==mymapPagingType&&$("body,html").animate({scrollTop:$(mymapPostsWrapperClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').offset().top-150},400),"infinite-scroll"==mymapPagingType&&(infiniteScrollRunning=!1),"load-more"==mymapPagingType&&$('#malinky-ajax-pagination-button[data-paginator-count="'+mymapPaginatorCount+'"]').removeClass("malinky-load-more__button-disable");var mapResponse=$.parseHTML(requestObj.responseText),paginatorTotalCountAjax=mapPaginatorTotalCount(mapResponse);mapAddPaginatorCount(mapResponse,paginatorTotalCountAjax);var $mapLoadedPosts=$(mapResponse).find(mymapPostsWrapperClass+'[data-paginator-count="'+mymapPaginatorCount+'"] '+mymapPostClass);!function(loadedPosts,url){eval(mymapUserCallback)}($mapLoadedPosts,this.url)}})},mapPaginatorTotalCount=function(a){var t=0;for(var n in malinkySettings){$(a).find(malinkySettings[n].posts_wrapper).length&&$(a).find(malinkySettings[n].post_wrapper).length&&$(a).find(malinkySettings[n].pagination_wrapper).length&&t++}return t},mapAddPaginatorCount=function(a,t){var n=1;for(var o in malinkySettings){$(a).find(malinkySettings[o].posts_wrapper).length&&$(a).find(malinkySettings[o].post_wrapper).length&&$(a).find(malinkySettings[o].pagination_wrapper).length&&(1==t?($(a).find(malinkySettings[o].posts_wrapper).attr("data-paginator-count",n),$(a).find(malinkySettings[o].pagination_wrapper).attr("data-paginator-count",n)):($(a).find(malinkySettings[o].posts_wrapper).attr("data-paginator-count",n),$(a).find(malinkySettings[o].posts_wrapper+" "+malinkySettings[o].pagination_wrapper).attr("data-paginator-count",n),$(a).find(malinkySettings[o].posts_wrapper+" "+malinkySettings[o].next_page_selector).attr("data-paginator-count",n),n++))}},mapIsLastPage=function(a,t){return $(a).find(t).length},mapAddLoader=function(){$(mymapPaginationClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').last().before('
    '+mymapAjaxLoader+"
    ")},mapLoading=function(){$('.malinky-ajax-pagination-loading[data-paginator-count="'+mymapPaginatorCount+'"]').slideToggle(),"load-more"!=mymapPagingType&&"infinite-scroll"!=mymapPagingType||$('#malinky-ajax-pagination-button[data-paginator-count="'+mymapPaginatorCount+'"]').text(mymapLoadingMorePostsText)},mapLoaded=function(){$('.malinky-ajax-pagination-loading[data-paginator-count="'+mymapPaginatorCount+'"]').slideToggle(),"load-more"!=mymapPagingType&&"infinite-scroll"!=mymapPagingType||$('#malinky-ajax-pagination-button[data-paginator-count="'+mymapPaginatorCount+'"]').text(mymapLoadMoreButtonText),clearTimeout(mymapLoadingTimer)},mapFailed=function(){$('.malinky-ajax-pagination-loading[data-paginator-count="'+mymapPaginatorCount+'"]').slideToggle(),clearTimeout(mymapLoadingTimer)},mapInfiniteScroll=debounce(function(){if(!infiniteScrollRunning){var a=($(document).height()-$(window).scrollTop()-$(window).height(),$(mymapPostsWrapperClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').offset().top),t=$(mymapPostsWrapperClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').outerHeight();$(window).height()+$(window).scrollTop()+mymapInfiniteScrollBuffer>a+t&&(infiniteScrollRunning=!0,mapLoading(),mapLoadPosts())}},250);"infinite-scroll"==mymapPagingType?$(mymapNextPageSelector+'[data-paginator-count="'+mymapPaginatorCount+'"]').attr("href")&&(mapAddLoader(),$(mymapPaginationClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').remove(),window.addEventListener("scroll",mapInfiniteScroll)):"load-more"==mymapPagingType?$(mymapNextPageSelector+'[data-paginator-count="'+mymapPaginatorCount+'"]').attr("href")&&($(mymapPaginationClass+'[data-paginator-count="'+mymapPaginatorCount+'"]').last().after('"),mapAddLoader(),$(mymapPaginationClass+'[data-paginator-count="'+mymapPaginatorCount+'"]:not(:has(>a#malinky-ajax-pagination-button[data-paginator-count="'+mymapPaginatorCount+'"]))').remove(),$('#malinky-ajax-pagination-button[data-paginator-count="'+mymapPaginatorCount+'"]').click(function(a){a.preventDefault(),$(this).addClass("malinky-load-more__button-disable"),mymapLoadingTimer=setTimeout(mapLoading,750),mapLoadPosts()})):"pagination"==mymapPagingType&&(mapAddLoader(),$(document).on("click",mymapPaginationClass+'[data-paginator-count="'+mymapPaginatorCount+'"] a',function(a){a.preventDefault(),mymapLoadingTimer=setTimeout(mapLoading,750),mymapNextPageUrl=a.currentTarget.href,mapLoadPosts()}),window.addEventListener("popstate",function(a){mymapNextPageUrl=document.URL,mapLoadPosts()}))},setUp=function(){var a=0,t=1,n=0;for(var o in malinkySettings){$(malinkySettings[o].posts_wrapper).length&&$(malinkySettings[o].post_wrapper).length&&$(malinkySettings[o].pagination_wrapper).length&&$(malinkySettings[o].next_page_selector).length&&n++}for(var o in malinkySettings){if($(malinkySettings[o].posts_wrapper).length&&$(malinkySettings[o].post_wrapper).length&&$(malinkySettings[o].pagination_wrapper).length&&$(malinkySettings[o].next_page_selector).length){1==n?($(malinkySettings[o].posts_wrapper).attr("data-paginator-count",t),$(malinkySettings[o].pagination_wrapper).attr("data-paginator-count",t),$(malinkySettings[o].next_page_selector).attr("data-paginator-count",t)):($(malinkySettings[o].posts_wrapper).attr("data-paginator-count",t),$(malinkySettings[o].posts_wrapper+" "+malinkySettings[o].pagination_wrapper).attr("data-paginator-count",t),$(malinkySettings[o].posts_wrapper+" "+malinkySettings[o].next_page_selector).attr("data-paginator-count",t),t++);var i={mapAjaxLoader:malinkySettings[o].ajax_loader,mapCssLoadMore:malinkySettings[o].malinky_load_more,mapCssLoadMoreButton:malinkySettings[o].malinky_load_more_button,mapInfiniteScrollBuffer:parseInt(malinkySettings[o].infinite_scroll_buffer),mapLoadingTimer:"",mapLoadingMorePostsText:malinkySettings[o].loading_more_posts_text,mapLoadMoreButtonText:malinkySettings[o].load_more_button_text,mapPaginationClass:malinkySettings[o].pagination_wrapper,mapPagingType:malinkySettings[o].paging_type,mapPostsWrapperClass:malinkySettings[o].posts_wrapper,mapPostClass:malinkySettings[o].post_wrapper,mapNextPageSelector:malinkySettings[o].next_page_selector,mapPaginatorCount:++a,mapUserCallback:malinkySettings[o].callback_function};i.mapPaginationClassPixelsToDocBottom=jQuery(document).height()-jQuery(i.mapPaginationClass).offset().top,1==n?i.mapNextPageUrl=$(malinkySettings[o].next_page_selector).attr("href"):i.mapNextPageUrl=$(malinkySettings[o].posts_wrapper+" "+malinkySettings[o].next_page_selector).attr("href"),init(i);var e=new CustomEvent("malinkyPaginationInitialized");document.dispatchEvent(e)}}};return setUp(),{setUp:setUp}}(jQuery); if(function(t,e){"function"==typeof define&&define.amd?define(e):"object"==typeof exports?module.exports=e(require,exports,module):t.Tether=e()}(this,function(t,e,i){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function s(t){var e=t.getBoundingClientRect(),i={};for(var n in e)i[n]=e[n];if(t.ownerDocument!==document){var o=t.ownerDocument.defaultView.frameElement;if(o){var r=s(o);i.top+=r.top,i.bottom+=r.top,i.left+=r.left,i.right+=r.left}}return i}function o(t){var e=getComputedStyle(t)||{},i=e.position,n=[];if("fixed"===i)return[t];for(var s=t;(s=s.parentNode)&&s&&1===s.nodeType;){var o=void 0;try{o=getComputedStyle(s)}catch(t){}if("undefined"==typeof o||null===o)return n.push(s),n;var r=o,a=r.overflow,l=r.overflowX,h=r.overflowY;/(auto|scroll)/.test(a+h+l)&&("absolute"!==i||["relative","absolute","fixed"].indexOf(o.position)>=0)&&n.push(s)}return n.push(t.ownerDocument.body),t.ownerDocument!==document&&n.push(t.ownerDocument.defaultView),n}function r(){C&&document.body.removeChild(C),C=null}function a(t){var e=void 0;t===document?(e=document,t=document.documentElement):e=t.ownerDocument;var i=e.documentElement,n=s(t),o=D();return n.top-=o.top,n.left-=o.left,"undefined"==typeof n.width&&(n.width=document.body.scrollWidth-n.left-n.right),"undefined"==typeof n.height&&(n.height=document.body.scrollHeight-n.top-n.bottom),n.top=n.top-i.clientTop,n.left=n.left-i.clientLeft,n.right=e.body.clientWidth-n.width-n.left,n.bottom=e.body.clientHeight-n.height-n.top,n}function l(t){return t.offsetParent||document.documentElement}function h(){if(O)return O;var t=document.createElement("div");t.style.width="100%",t.style.height="200px";var e=document.createElement("div");c(e.style,{position:"absolute",top:0,left:0,pointerEvents:"none",visibility:"hidden",width:"200px",height:"150px",overflow:"hidden"}),e.appendChild(t),document.body.appendChild(e);var i=t.offsetWidth;e.style.overflow="scroll";var n=t.offsetWidth;i===n&&(n=e.clientWidth),document.body.removeChild(e);var s=i-n;return O={width:s,height:s}}function c(){var t=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],e=[];return Array.prototype.push.apply(e,arguments),e.slice(1).forEach(function(e){if(e)for(var i in e)({}).hasOwnProperty.call(e,i)&&(t[i]=e[i])}),t}function u(t,e){if("undefined"!=typeof t.classList)e.split(" ").forEach(function(e){e.trim()&&t.classList.remove(e)});else{var i=new RegExp("(^|)"+e.split(" ").join("|")+"(|$)","gi"),n=p(t).replace(i," ");g(t,n)}}function d(t,e){if("undefined"!=typeof t.classList)e.split(" ").forEach(function(e){e.trim()&&t.classList.add(e)});else{u(t,e);var i=p(t)+(" "+e);g(t,i)}}function f(t,e){if("undefined"!=typeof t.classList)return t.classList.contains(e);var i=p(t);return new RegExp("(^|)"+e+"(|$)","gi").test(i)}function p(t){return t.className instanceof t.ownerDocument.defaultView.SVGAnimatedString?t.className.baseVal:t.className}function g(t,e){t.setAttribute("class",e)}function m(t,e,i){i.forEach(function(i){e.indexOf(i)===-1&&f(t,i)&&u(t,i)}),e.forEach(function(e){f(t,e)||d(t,e)})}function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function v(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function y(t,e){var i=arguments.length<=2||void 0===arguments[2]?1:arguments[2];return t+i>=e&&e>=t-i}function _(){return"undefined"!=typeof performance&&"undefined"!=typeof performance.now?performance.now():+new Date}function E(){for(var t={top:0,left:0},e=arguments.length,i=Array(e),n=0;n1?i-1:0),s=1;s16?(e=Math.min(e-16,250),void(i=setTimeout(n,250))):void("undefined"!=typeof t&&_()-t<10||(null!=i&&(clearTimeout(i),i=null),t=_(),X(),e=_()-t))};"undefined"!=typeof window&&"undefined"!=typeof window.addEventListener&&["resize","scroll","touchmove"].forEach(function(t){window.addEventListener(t,n)})}();var M={center:"center",left:"right",right:"left"},B={middle:"middle",top:"bottom",bottom:"top"},V={top:0,left:0,middle:"50%",center:"50%",bottom:"100%",right:"100%"},j=function(t,e){var i=t.left,n=t.top;return"auto"===i&&(i=M[e.left]),"auto"===n&&(n=B[e.top]),{left:i,top:n}},U=function(t){var e=t.left,i=t.top;return"undefined"!=typeof V[t.left]&&(e=V[t.left]),"undefined"!=typeof V[t.top]&&(i=V[t.top]),{left:e,top:i}},F=function(t){var e=t.split(" "),i=L(e,2),n=i[0],s=i[1];return{top:n,left:s}},z=F,K=function(t){function e(t){var i=this;n(this,e),H(Object.getPrototypeOf(e.prototype),"constructor",this).call(this),this.position=this.position.bind(this),R.push(this),this.history=[],this.setOptions(t,!1),w.modules.forEach(function(t){"undefined"!=typeof t.initialize&&t.initialize.call(i)}),this.position()}return v(e,t),S(e,[{key:"getClass",value:function(){var t=arguments.length<=0||void 0===arguments[0]?"":arguments[0],e=this.options.classes;return"undefined"!=typeof e&&e[t]?this.options.classes[t]:this.options.classPrefix?this.options.classPrefix+"-"+t:t}},{key:"setOptions",value:function(t){var e=this,i=arguments.length<=1||void 0===arguments[1]||arguments[1],n={offset:"0 0",targetOffset:"0 0",targetAttachment:"auto auto",classPrefix:"tether"};this.options=c(n,t);var s=this.options,r=s.element,a=s.target,l=s.targetModifier;if(this.element=r,this.target=a,this.targetModifier=l,"viewport"===this.target?(this.target=document.body,this.targetModifier="visible"):"scroll-handle"===this.target&&(this.target=document.body,this.targetModifier="scroll-handle"),["element","target"].forEach(function(t){if("undefined"==typeof e[t])throw new Error("Tether Error: Both element and target must be defined");"undefined"!=typeof e[t].jquery?e[t]=e[t][0]:"string"==typeof e[t]&&(e[t]=document.querySelector(e[t]))}),d(this.element,this.getClass("element")),this.options.addTargetClasses!==!1&&d(this.target,this.getClass("target")),!this.options.attachment)throw new Error("Tether Error: You must provide an attachment");this.targetAttachment=z(this.options.targetAttachment),this.attachment=z(this.options.attachment),this.offset=F(this.options.offset),this.targetOffset=F(this.options.targetOffset),"undefined"!=typeof this.scrollParents&&this.disable(),"scroll-handle"===this.targetModifier?this.scrollParents=[this.target]:this.scrollParents=o(this.target),this.options.enabled!==!1&&this.enable(i)}},{key:"getTargetBounds",value:function(){if("undefined"==typeof this.targetModifier)return a(this.target);if("visible"===this.targetModifier){if(this.target===document.body)return{top:pageYOffset,left:pageXOffset,height:innerHeight,width:innerWidth};var t=a(this.target),e={height:t.height,width:t.width,top:t.top,left:t.left};return e.height=Math.min(e.height,t.height-(pageYOffset-t.top)),e.height=Math.min(e.height,t.height-(t.top+t.height-(pageYOffset+innerHeight))),e.height=Math.min(innerHeight,e.height),e.height-=2,e.width=Math.min(e.width,t.width-(pageXOffset-t.left)),e.width=Math.min(e.width,t.width-(t.left+t.width-(pageXOffset+innerWidth))),e.width=Math.min(innerWidth,e.width),e.width-=2,e.topi.clientWidth||[n.overflow,n.overflowX].indexOf("scroll")>=0||this.target!==document.body,o=0;s&&(o=15);var r=t.height-parseFloat(n.borderTopWidth)-parseFloat(n.borderBottomWidth)-o,e={width:15,height:.975*r*(r/i.scrollHeight),left:t.left+t.width-parseFloat(n.borderLeftWidth)-15},l=0;r<408&&this.target===document.body&&(l=-11e-5*Math.pow(r,2)-.00727*r+22.58),this.target!==document.body&&(e.height=Math.max(e.height,24));var h=this.target.scrollTop/(i.scrollHeight-r);return e.top=h*(r-e.height-l)+t.top+parseFloat(n.borderTopWidth),this.target===document.body&&(e.height=Math.max(e.height,24)),e}}},{key:"clearCache",value:function(){this._cache={}}},{key:"cache",value:function(t,e){return"undefined"==typeof this._cache&&(this._cache={}),"undefined"==typeof this._cache[t]&&(this._cache[t]=e.call(this)),this._cache[t]}},{key:"enable",value:function(){var t=this,e=arguments.length<=0||void 0===arguments[0]||arguments[0];this.options.addTargetClasses!==!1&&d(this.target,this.getClass("enabled")),d(this.element,this.getClass("enabled")),this.enabled=!0,this.scrollParents.forEach(function(e){e!==t.target.ownerDocument&&e.addEventListener("scroll",t.position)}),e&&this.position()}},{key:"disable",value:function(){var t=this;u(this.target,this.getClass("enabled")),u(this.element,this.getClass("enabled")),this.enabled=!1,"undefined"!=typeof this.scrollParents&&this.scrollParents.forEach(function(e){e.removeEventListener("scroll",t.position)})}},{key:"destroy",value:function(){var t=this;this.disable(),R.forEach(function(e,i){e===t&&R.splice(i,1)}),0===R.length&&r()}},{key:"updateAttachClasses",value:function(t,e){var i=this;t=t||this.attachment,e=e||this.targetAttachment;var n=["left","top","bottom","right","middle","center"];"undefined"!=typeof this._addAttachClasses&&this._addAttachClasses.length&&this._addAttachClasses.splice(0,this._addAttachClasses.length),"undefined"==typeof this._addAttachClasses&&(this._addAttachClasses=[]);var s=this._addAttachClasses;t.top&&s.push(this.getClass("element-attached")+"-"+t.top),t.left&&s.push(this.getClass("element-attached")+"-"+t.left),e.top&&s.push(this.getClass("target-attached")+"-"+e.top),e.left&&s.push(this.getClass("target-attached")+"-"+e.left);var o=[];n.forEach(function(t){o.push(i.getClass("element-attached")+"-"+t),o.push(i.getClass("target-attached")+"-"+t)}),x(function(){"undefined"!=typeof i._addAttachClasses&&(m(i.element,i._addAttachClasses,o),i.options.addTargetClasses!==!1&&m(i.target,i._addAttachClasses,o),delete i._addAttachClasses)})}},{key:"position",value:function(){var t=this,e=arguments.length<=0||void 0===arguments[0]||arguments[0];if(this.enabled){this.clearCache();var i=j(this.targetAttachment,this.attachment);this.updateAttachClasses(this.attachment,i);var n=this.cache("element-bounds",function(){return a(t.element)}),s=n.width,o=n.height;if(0===s&&0===o&&"undefined"!=typeof this.lastSize){var r=this.lastSize;s=r.width,o=r.height}else this.lastSize={width:s,height:o};var c=this.cache("target-bounds",function(){return t.getTargetBounds()}),u=c,d=T(U(this.attachment),{width:s,height:o}),f=T(U(i),u),p=T(this.offset,{width:s,height:o}),g=T(this.targetOffset,u);d=E(d,p),f=E(f,g);for(var m=c.left+f.left-d.left,v=c.top+f.top-d.top,y=0;yC.documentElement.clientHeight&&(I=this.cache("scrollbar-size",h),S.viewport.bottom-=I.height),A.innerWidth>C.documentElement.clientWidth&&(I=this.cache("scrollbar-size",h),S.viewport.right-=I.width),["","static"].indexOf(C.body.style.position)!==-1&&["","static"].indexOf(C.body.parentElement.style.position)!==-1||(S.page.bottom=C.body.scrollHeight-v-o,S.page.right=C.body.scrollWidth-m-s),"undefined"!=typeof this.options.optimizations&&this.options.optimizations.moveElement!==!1&&"undefined"==typeof this.targetModifier&&!function(){var e=t.cache("target-offsetparent",function(){return l(t.target)}),i=t.cache("target-offsetparent-bounds",function(){return a(e)}),n=getComputedStyle(e),s=i,o={};if(["Top","Left","Bottom","Right"].forEach(function(t){o[t.toLowerCase()]=parseFloat(n["border"+t+"Width"])}),i.right=C.body.scrollWidth-i.left-s.width+o.right,i.bottom=C.body.scrollHeight-i.top-s.height+o.bottom,S.page.top>=i.top+o.top&&S.page.bottom>=i.bottom&&S.page.left>=i.left+o.left&&S.page.right>=i.right){var r=e.scrollTop,h=e.scrollLeft;S.offset={top:S.page.top-i.top+r-o.top,left:S.page.left-i.left+h-o.left}}}(),this.move(S),this.history.unshift(S),this.history.length>3&&this.history.pop(),e&&N(),!0}}},{key:"move",value:function(t){var e=this;if("undefined"!=typeof this.element.parentNode){var i={};for(var n in t){i[n]={};for(var s in t[n]){for(var o=!1,r=0;r=0){var p=a.split(" "),m=L(p,2);u=m[0],c=m[1]}else c=u=a;var _=b(e,o);"target"!==u&&"both"!==u||(i<_[1]&&"top"===v.top&&(i+=d,v.top="bottom"),i+r>_[3]&&"bottom"===v.top&&(i-=d,v.top="top")),"together"===u&&("top"===v.top&&("bottom"===y.top&&i<_[1]?(i+=d,v.top="bottom",i+=r,y.top="top"):"top"===y.top&&i+r>_[3]&&i-(r-d)>=_[1]&&(i-=r-d,v.top="bottom",y.top="bottom")),"bottom"===v.top&&("top"===y.top&&i+r>_[3]?(i-=d,v.top="top",i-=r,y.top="bottom"):"bottom"===y.top&&i<_[1]&&i+(2*r-d)<=_[3]&&(i+=r-d,v.top="top",y.top="top")),"middle"===v.top&&(i+r>_[3]&&"top"===y.top?(i-=r,y.top="bottom"):i<_[1]&&"bottom"===y.top&&(i+=r,y.top="top"))),"target"!==c&&"both"!==c||(n<_[0]&&"left"===v.left&&(n+=f,v.left="right"),n+l>_[2]&&"right"===v.left&&(n-=f,v.left="left")),"together"===c&&(n<_[0]&&"left"===v.left?"right"===y.left?(n+=f,v.left="right",n+=l,y.left="left"):"left"===y.left&&(n+=f,v.left="right",n-=l,y.left="right"):n+l>_[2]&&"right"===v.left?"left"===y.left?(n-=f,v.left="left",n-=l,y.left="right"):"right"===y.left&&(n-=f,v.left="left",n+=l,y.left="left"):"center"===v.left&&(n+l>_[2]&&"left"===y.left?(n-=l,y.left="right"):n<_[0]&&"right"===y.left&&(n+=l,y.left="left"))),"element"!==u&&"both"!==u||(i<_[1]&&"bottom"===y.top&&(i+=r,y.top="top"),i+r>_[3]&&"top"===y.top&&(i-=r,y.top="bottom")),"element"!==c&&"both"!==c||(n<_[0]&&("right"===y.left?(n+=l,y.left="left"):"center"===y.left&&(n+=l/2,y.left="left")),n+l>_[2]&&("left"===y.left?(n-=l,y.left="right"):"center"===y.left&&(n-=l/2,y.left="right"))),"string"==typeof h?h=h.split(",").map(function(t){return t.trim()}):h===!0&&(h=["top","left","right","bottom"]),h=h||[];var E=[],T=[];i<_[1]&&(h.indexOf("top")>=0?(i=_[1],E.push("top")):T.push("top")),i+r>_[3]&&(h.indexOf("bottom")>=0?(i=_[3]-r,E.push("bottom")):T.push("bottom")),n<_[0]&&(h.indexOf("left")>=0?(n=_[0],E.push("left")):T.push("left")),n+l>_[2]&&(h.indexOf("right")>=0?(n=_[2]-l,E.push("right")):T.push("right")),E.length&&!function(){var t=void 0;t="undefined"!=typeof e.options.pinnedClass?e.options.pinnedClass:e.getClass("pinned"),g.push(t),E.forEach(function(e){g.push(t+"-"+e)})}(),T.length&&!function(){var t=void 0;t="undefined"!=typeof e.options.outOfBoundsClass?e.options.outOfBoundsClass:e.getClass("out-of-bounds"),g.push(t),T.forEach(function(e){g.push(t+"-"+e)})}(),(E.indexOf("left")>=0||E.indexOf("right")>=0)&&(y.left=v.left=!1),(E.indexOf("top")>=0||E.indexOf("bottom")>=0)&&(y.top=v.top=!1),v.top===s.top&&v.left===s.left&&y.top===e.attachment.top&&y.left===e.attachment.left||(e.updateAttachClasses(y,v),e.trigger("update",{attachment:y,targetAttachment:v}))}),x(function(){e.options.addTargetClasses!==!1&&m(e.target,g,p),m(e.element,g,p)}),{top:i,left:n}}});var W=w.Utils,a=W.getBounds,m=W.updateClasses,x=W.defer;w.modules.push({position:function(t){var e=this,i=t.top,n=t.left,s=this.cache("element-bounds",function(){return a(e.element)}),o=s.height,r=s.width,l=this.getTargetBounds(),h=i+o,c=n+r,u=[];i<=l.bottom&&h>=l.top&&["left","right"].forEach(function(t){var e=l[t];e!==n&&e!==c||u.push(t)}),n<=l.right&&c>=l.left&&["top","bottom"].forEach(function(t){var e=l[t];e!==i&&e!==h||u.push(t)});var d=[],f=[],p=["left","top","right","bottom"];return d.push(this.getClass("abutted")),p.forEach(function(t){d.push(e.getClass("abutted")+"-"+t)}),u.length&&f.push(this.getClass("abutted")),u.forEach(function(t){f.push(e.getClass("abutted")+"-"+t)}),x(function(){e.options.addTargetClasses!==!1&&m(e.target,f,d),m(e.element,f,d)}),!0}});var L=function(){function t(t,e){var i=[],n=!0,s=!1,o=void 0;try{for(var r,a=t[Symbol.iterator]();!(n=(r=a.next()).done)&&(i.push(r.value),!e||i.length!==e);n=!0);}catch(t){s=!0,o=t}finally{try{!n&&a.return&&a.return()}finally{if(s)throw o}}return i}return function(e,i){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,i);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();return w.modules.push({position:function(t){var e=t.top,i=t.left;if(this.options.shift){var n=this.options.shift;"function"==typeof this.options.shift&&(n=this.options.shift.call(this,{top:e,left:i}));var s=void 0,o=void 0;if("string"==typeof n){n=n.split(" "),n[1]=n[1]||n[0];var r=n,a=L(r,2);s=a[0],o=a[1],s=parseFloat(s,10),o=parseFloat(o,10)}else s=n.top,o=n.left;return e+=s,i+=o,{top:e,left:i}}}}),Q}),function(t,e,i){function n(t,i){this.wrapper="string"==typeof t?e.querySelector(t):t,this.scroller=this.wrapper.children[0],this.scrollerStyle=this.scroller.style,this.options={resizeScrollbars:!0,mouseWheelSpeed:20,snapThreshold:.334,startX:0,startY:0,scrollY:!0,directionLockThreshold:5,momentum:!0,bounce:!0,bounceTime:600,bounceEasing:"",preventDefault:!0,preventDefaultException:{tagName:/^(INPUT|TEXTAREA|BUTTON|SELECT)$/},HWCompositing:!0,useTransition:!0,useTransform:!0};for(var n in i)this.options[n]=i[n];this.translateZ=this.options.HWCompositing&&a.hasPerspective?" translateZ(0)":"",this.options.useTransition=a.hasTransition&&this.options.useTransition,this.options.useTransform=a.hasTransform&&this.options.useTransform,this.options.eventPassthrough=this.options.eventPassthrough===!0?"vertical":this.options.eventPassthrough,this.options.preventDefault=!this.options.eventPassthrough&&this.options.preventDefault,this.options.scrollY="vertical"!=this.options.eventPassthrough&&this.options.scrollY,this.options.scrollX="horizontal"!=this.options.eventPassthrough&&this.options.scrollX,this.options.freeScroll=this.options.freeScroll&&!this.options.eventPassthrough,this.options.directionLockThreshold=this.options.eventPassthrough?0:this.options.directionLockThreshold,this.options.bounceEasing="string"==typeof this.options.bounceEasing?a.ease[this.options.bounceEasing]||a.ease.circular:this.options.bounceEasing,this.options.resizePolling=void 0===this.options.resizePolling?60:this.options.resizePolling,this.options.tap===!0&&(this.options.tap="tap"),"scale"==this.options.shrinkScrollbars&&(this.options.useTransition=!1),this.options.invertWheelDirection=this.options.invertWheelDirection?-1:1,this.x=0,this.y=0,this.directionX=0,this.directionY=0,this._events={},this._init(),this.refresh(),this.scrollTo(this.options.startX,this.options.startY),this.enable()}function s(t,i,n){var s=e.createElement("div"),o=e.createElement("div");return n===!0&&(s.style.cssText="position:absolute;z-index:9999",o.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;position:absolute;background:rgba(0,0,0,0.5);border:1px solid rgba(255,255,255,0.9);border-radius:3px"),o.className="iScrollIndicator","h"==t?(n===!0&&(s.style.cssText+=";height:7px;left:2px;right:2px;bottom:0",o.style.height="100%"),s.className="iScrollHorizontalScrollbar"):(n===!0&&(s.style.cssText+=";width:7px;bottom:2px;top:2px;right:1px",o.style.width="100%"),s.className="iScrollVerticalScrollbar"),s.style.cssText+=";overflow:hidden",i||(s.style.pointerEvents="none"),s.appendChild(o),s}function o(i,n){this.wrapper="string"==typeof n.el?e.querySelector(n.el):n.el,this.wrapperStyle=this.wrapper.style,this.indicator=this.wrapper.children[0],this.indicatorStyle=this.indicator.style,this.scroller=i,this.options={listenX:!0,listenY:!0,interactive:!1,resize:!0,defaultScrollbars:!1,shrink:!1,fade:!1,speedRatioX:0,speedRatioY:0};for(var s in n)this.options[s]=n[s];this.sizeRatioX=1,this.sizeRatioY=1,this.maxPosX=0,this.maxPosY=0,this.options.interactive&&(this.options.disableTouch||(a.addEvent(this.indicator,"touchstart",this),a.addEvent(t,"touchend",this)),this.options.disablePointer||(a.addEvent(this.indicator,a.prefixPointerEvent("pointerdown"),this),a.addEvent(t,a.prefixPointerEvent("pointerup"),this)),this.options.disableMouse||(a.addEvent(this.indicator,"mousedown",this),a.addEvent(t,"mouseup",this))),this.options.fade&&(this.wrapperStyle[a.style.transform]=this.scroller.translateZ,this.wrapperStyle[a.style.transitionDuration]=a.isBadAndroid?"0.001s":"0ms",this.wrapperStyle.opacity="0")}var r=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame||function(e){t.setTimeout(e,1e3/60)},a=function(){function n(t){return r!==!1&&(""===r?t:r+t.charAt(0).toUpperCase()+t.substr(1))}var s={},o=e.createElement("div").style,r=function(){for(var t,e=["t","webkitT","MozT","msT","OT"],i=0,n=e.length;i0&&(a=o?o/2.5*(c/8):0,h=i.abs(t)+a,l=h/c),{destination:i.round(a),duration:l}};var a=n("transform");return s.extend(s,{hasTransform:a!==!1,hasPerspective:n("perspective")in o,hasTouch:"ontouchstart"in t,hasPointer:t.PointerEvent||t.MSPointerEvent,hasTransition:n("transition")in o}),s.isBadAndroid=/Android /.test(t.navigator.appVersion)&&!/Chrome\/\d/.test(t.navigator.appVersion),s.extend(s.style={},{transform:a,transitionTimingFunction:n("transitionTimingFunction"),transitionDuration:n("transitionDuration"),transitionDelay:n("transitionDelay"),transformOrigin:n("transformOrigin")}),s.hasClass=function(t,e){var i=new RegExp("(^|\\s)"+e+"(\\s|$)");return i.test(t.className)},s.addClass=function(t,e){if(!s.hasClass(t,e)){var i=t.className.split(" ");i.push(e),t.className=i.join(" ")}},s.removeClass=function(t,e){if(s.hasClass(t,e)){var i=new RegExp("(^|\\s)"+e+"(\\s|$)","g");t.className=t.className.replace(i," ")}},s.offset=function(t){for(var e=-t.offsetLeft,i=-t.offsetTop;t=t.offsetParent;)e-=t.offsetLeft,i-=t.offsetTop;return{left:e,top:i}},s.preventDefaultException=function(t,e){for(var i in e)if(e[i].test(t[i]))return!0;return!1},s.extend(s.eventType={},{touchstart:1,touchmove:1,touchend:1,mousedown:2,mousemove:2,mouseup:2,pointerdown:3,pointermove:3,pointerup:3,MSPointerDown:3,MSPointerMove:3,MSPointerUp:3}),s.extend(s.ease={},{quadratic:{style:"cubic-bezier(0.25, 0.46, 0.45, 0.94)",fn:function(t){return t*(2-t)}},circular:{style:"cubic-bezier(0.1, 0.57, 0.1, 1)",fn:function(t){return i.sqrt(1- --t*t)}},back:{style:"cubic-bezier(0.175, 0.885, 0.32, 1.275)",fn:function(t){var e=4;return(t-=1)*t*((e+1)*t+e)+1}},bounce:{style:"",fn:function(t){return(t/=1)<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375}},elastic:{style:"",fn:function(t){var e=.22,n=.4;return 0===t?0:1==t?1:n*i.pow(2,-10*t)*i.sin((t-e/4)*(2*i.PI)/e)+1}}}),s.tap=function(t,i){var n=e.createEvent("Event");n.initEvent(i,!0,!0),n.pageX=t.pageX,n.pageY=t.pageY,t.target.dispatchEvent(n)},s.click=function(t){var i,n=t.target;/(SELECT|INPUT|TEXTAREA)/i.test(n.tagName)||(i=e.createEvent("MouseEvents"),i.initMouseEvent("click",!0,!0,t.view,1,n.screenX,n.screenY,n.clientX,n.clientY,t.ctrlKey,t.altKey,t.shiftKey,t.metaKey,0,null),i._constructed=!0,n.dispatchEvent(i))},s}();n.prototype={version:"5.1.3",_init:function(){this._initEvents(),(this.options.scrollbars||this.options.indicators)&&this._initIndicators(), this.options.mouseWheel&&this._initWheel(),this.options.snap&&this._initSnap(),this.options.keyBindings&&this._initKeys()},destroy:function(){this._initEvents(!0),this._execEvent("destroy")},_transitionEnd:function(t){t.target==this.scroller&&this.isInTransition&&(this._transitionTime(),this.resetPosition(this.options.bounceTime)||(this.isInTransition=!1,this._execEvent("scrollEnd")))},_start:function(t){if((1==a.eventType[t.type]||0===t.button)&&this.enabled&&(!this.initiated||a.eventType[t.type]===this.initiated)){!this.options.preventDefault||a.isBadAndroid||a.preventDefaultException(t.target,this.options.preventDefaultException)||t.preventDefault();var e,n=t.touches?t.touches[0]:t;this.initiated=a.eventType[t.type],this.moved=!1,this.distX=0,this.distY=0,this.directionX=0,this.directionY=0,this.directionLocked=0,this._transitionTime(),this.startTime=a.getTime(),this.options.useTransition&&this.isInTransition?(this.isInTransition=!1,e=this.getComputedPosition(),this._translate(i.round(e.x),i.round(e.y)),this._execEvent("scrollEnd")):!this.options.useTransition&&this.isAnimating&&(this.isAnimating=!1,this._execEvent("scrollEnd")),this.startX=this.x,this.startY=this.y,this.absStartX=this.x,this.absStartY=this.y,this.pointX=n.pageX,this.pointY=n.pageY,this._execEvent("beforeScrollStart")}},_move:function(t){if(this.enabled&&a.eventType[t.type]===this.initiated){this.options.preventDefault&&t.preventDefault();var e,n,s,o,r=t.touches?t.touches[0]:t,l=r.pageX-this.pointX,h=r.pageY-this.pointY,c=a.getTime();if(this.pointX=r.pageX,this.pointY=r.pageY,this.distX+=l,this.distY+=h,s=i.abs(this.distX),o=i.abs(this.distY),!(c-this.endTime>300&&s<10&&o<10)){if(this.directionLocked||this.options.freeScroll||(s>o+this.options.directionLockThreshold?this.directionLocked="h":o>=s+this.options.directionLockThreshold?this.directionLocked="v":this.directionLocked="n"),"h"==this.directionLocked){if("vertical"==this.options.eventPassthrough)t.preventDefault();else if("horizontal"==this.options.eventPassthrough)return void(this.initiated=!1);h=0}else if("v"==this.directionLocked){if("horizontal"==this.options.eventPassthrough)t.preventDefault();else if("vertical"==this.options.eventPassthrough)return void(this.initiated=!1);l=0}l=this.hasHorizontalScroll?l:0,h=this.hasVerticalScroll?h:0,e=this.x+l,n=this.y+h,(e>0||e0?0:this.maxScrollX),(n>0||n0?0:this.maxScrollY),this.directionX=l>0?-1:l<0?1:0,this.directionY=h>0?-1:h<0?1:0,this.moved||this._execEvent("scrollStart"),this.moved=!0,this._translate(e,n),c-this.startTime>300&&(this.startTime=c,this.startX=this.x,this.startY=this.y)}}},_end:function(t){if(this.enabled&&a.eventType[t.type]===this.initiated){this.options.preventDefault&&!a.preventDefaultException(t.target,this.options.preventDefaultException)&&t.preventDefault();var e,n,s=(t.changedTouches?t.changedTouches[0]:t,a.getTime()-this.startTime),o=i.round(this.x),r=i.round(this.y),l=i.abs(o-this.startX),h=i.abs(r-this.startY),c=0,u="";if(this.isInTransition=0,this.initiated=0,this.endTime=a.getTime(),!this.resetPosition(this.options.bounceTime)){if(this.scrollTo(o,r),!this.moved)return this.options.tap&&a.tap(t,this.options.tap),this.options.click&&a.click(t),void this._execEvent("scrollCancel");if(this._events.flick&&s<200&&l<100&&h<100)return void this._execEvent("flick");if(this.options.momentum&&s<300&&(e=this.hasHorizontalScroll?a.momentum(this.x,this.startX,s,this.maxScrollX,this.options.bounce?this.wrapperWidth:0,this.options.deceleration):{destination:o,duration:0},n=this.hasVerticalScroll?a.momentum(this.y,this.startY,s,this.maxScrollY,this.options.bounce?this.wrapperHeight:0,this.options.deceleration):{destination:r,duration:0},o=e.destination,r=n.destination,c=i.max(e.duration,n.duration),this.isInTransition=1),this.options.snap){var d=this._nearestSnap(o,r);this.currentPage=d,c=this.options.snapSpeed||i.max(i.max(i.min(i.abs(o-d.x),1e3),i.min(i.abs(r-d.y),1e3)),300),o=d.x,r=d.y,this.directionX=0,this.directionY=0,u=this.options.bounceEasing}return o!=this.x||r!=this.y?((o>0||o0||r0?e=0:this.x0?i=0:this.y-1&&this._events[t].splice(i,1)}},_execEvent:function(t){if(this._events[t]){var e=0,i=this._events[t].length;if(i)for(;e0,!i||this.options.useTransition&&n.style?(this._transitionTimingFunction(n.style),this._transitionTime(i),this._translate(t,e)):this._animate(t,e,i,n.fn)},scrollToElement:function(t,e,n,s,o){if(t=t.nodeType?t:this.scroller.querySelector(t)){var r=a.offset(t);r.left-=this.wrapperOffset.left,r.top-=this.wrapperOffset.top,n===!0&&(n=i.round(t.offsetWidth/2-this.wrapper.offsetWidth/2)),s===!0&&(s=i.round(t.offsetHeight/2-this.wrapper.offsetHeight/2)),r.left-=n||0,r.top-=s||0,r.left=r.left>0?0:r.left0?0:r.top0?s--:e<0&&s++,n>0?o--:n<0&&o++,void this.goToPage(s,o);s=this.x+i.round(this.hasHorizontalScroll?e:0),o=this.y+i.round(this.hasVerticalScroll?n:0),s>0?s=0:s0?o=0:o-this.scrollerWidth;){for(this.pages[a]=[],t=0,o=0;o>-this.scrollerHeight;)this.pages[a][t]={x:i.max(h,this.maxScrollX),y:i.max(o,this.maxScrollY),width:c,height:u,cx:h-n,cy:o-s},o-=u,t++;h-=c,a++}else for(r=this.options.snap,t=r.length,e=-1;athis.maxScrollX&&l++;this.goToPage(this.currentPage.pageX||0,this.currentPage.pageY||0,0),this.options.snapThreshold%1===0?(this.snapThresholdX=this.options.snapThreshold,this.snapThresholdY=this.options.snapThreshold):(this.snapThresholdX=i.round(this.pages[this.currentPage.pageX][this.currentPage.pageY].width*this.options.snapThreshold),this.snapThresholdY=i.round(this.pages[this.currentPage.pageX][this.currentPage.pageY].height*this.options.snapThreshold))}}),this.on("flick",function(){var t=this.options.snapSpeed||i.max(i.max(i.min(i.abs(this.x-this.startX),1e3),i.min(i.abs(this.y-this.startY),1e3)),300);this.goToPage(this.currentPage.pageX+this.directionX,this.currentPage.pageY+this.directionY,t)})},_nearestSnap:function(t,e){if(!this.pages.length)return{x:0,y:0,pageX:0,pageY:0};var n=0,s=this.pages.length,o=0;if(i.abs(t-this.absStartX)0?t=0:t0?e=0:e=this.pages[n][0].cx){t=this.pages[n][0].x;break}for(s=this.pages[n].length;o=this.pages[0][o].cy){e=this.pages[0][o].y;break}return n==this.currentPage.pageX&&(n+=this.directionX,n<0?n=0:n>=this.pages.length&&(n=this.pages.length-1),t=this.pages[n][0].x),o==this.currentPage.pageY&&(o+=this.directionY,o<0?o=0:o>=this.pages[0].length&&(o=this.pages[0].length-1),e=this.pages[0][o].y),{x:t,y:e,pageX:n,pageY:o}},goToPage:function(t,e,n,s){s=s||this.options.bounceEasing,t>=this.pages.length?t=this.pages.length-1:t<0&&(t=0),e>=this.pages[t].length?e=this.pages[t].length-1:e<0&&(e=0);var o=this.pages[t][e].x,r=this.pages[t][e].y;n=void 0===n?this.options.snapSpeed||i.max(i.max(i.min(i.abs(o-this.x),1e3),i.min(i.abs(r-this.y),1e3)),300):n,this.currentPage={x:o,y:r,pageX:t,pageY:e},this.scrollTo(o,r,n,s)},next:function(t,e){var i=this.currentPage.pageX,n=this.currentPage.pageY;i++,i>=this.pages.length&&this.hasVerticalScroll&&(i=0,n++),this.goToPage(i,n,t,e)},prev:function(t,e){var i=this.currentPage.pageX,n=this.currentPage.pageY;i--,i<0&&this.hasVerticalScroll&&(i=0,n--),this.goToPage(i,n,t,e)},_initKeys:function(e){var i,n={pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40};if("object"==typeof this.options.keyBindings)for(i in this.options.keyBindings)"string"==typeof this.options.keyBindings[i]&&(this.options.keyBindings[i]=this.options.keyBindings[i].toUpperCase().charCodeAt(0));else this.options.keyBindings={};for(i in n)this.options.keyBindings[i]=this.options.keyBindings[i]||n[i];a.addEvent(t,"keydown",this),this.on("destroy",function(){a.removeEvent(t,"keydown",this)})},_key:function(t){if(this.enabled){var e,n=this.options.snap,s=n?this.currentPage.pageX:this.x,o=n?this.currentPage.pageY:this.y,r=a.getTime(),l=this.keyTime||0,h=.25;switch(this.options.useTransition&&this.isInTransition&&(e=this.getComputedPosition(),this._translate(i.round(e.x),i.round(e.y)),this.isInTransition=!1),this.keyAcceleration=r-l<200?i.min(this.keyAcceleration+h,50):0,t.keyCode){case this.options.keyBindings.pageUp:this.hasHorizontalScroll&&!this.hasVerticalScroll?s+=n?1:this.wrapperWidth:o+=n?1:this.wrapperHeight;break;case this.options.keyBindings.pageDown:this.hasHorizontalScroll&&!this.hasVerticalScroll?s-=n?1:this.wrapperWidth:o-=n?1:this.wrapperHeight;break;case this.options.keyBindings.end:s=n?this.pages.length-1:this.maxScrollX,o=n?this.pages[0].length-1:this.maxScrollY;break;case this.options.keyBindings.home:s=0,o=0;break;case this.options.keyBindings.left:s+=n?-1:5+this.keyAcceleration>>0;break;case this.options.keyBindings.up:o+=n?1:5+this.keyAcceleration>>0;break;case this.options.keyBindings.right:s-=n?-1:5+this.keyAcceleration>>0;break;case this.options.keyBindings.down:o-=n?1:5+this.keyAcceleration>>0;break;default:return}if(n)return void this.goToPage(s,o);s>0?(s=0,this.keyAcceleration=0):s0?(o=0,this.keyAcceleration=0):o=u?(o.isAnimating=!1,o._translate(t,e),void(o.resetPosition(o.options.bounceTime)||o._execEvent("scrollEnd"))):(g=(g-c)/i,p=n(g),d=(t-l)*p+l,f=(e-h)*p+h,o._translate(d,f),void(o.isAnimating&&r(s)))}var o=this,l=this.x,h=this.y,c=a.getTime(),u=c+i;this.isAnimating=!0,s()},handleEvent:function(t){switch(t.type){case"touchstart":case"pointerdown":case"MSPointerDown":case"mousedown":this._start(t);break;case"touchmove":case"pointermove":case"MSPointerMove":case"mousemove":this._move(t);break;case"touchend":case"pointerup":case"MSPointerUp":case"mouseup":case"touchcancel":case"pointercancel":case"MSPointerCancel":case"mousecancel":this._end(t);break;case"orientationchange":case"resize":this._resize();break;case"transitionend":case"webkitTransitionEnd":case"oTransitionEnd":case"MSTransitionEnd":this._transitionEnd(t);break;case"wheel":case"DOMMouseScroll":case"mousewheel":this._wheel(t);break;case"keydown":this._key(t);break;case"click":t._constructed||(t.preventDefault(),t.stopPropagation())}}},o.prototype={handleEvent:function(t){switch(t.type){case"touchstart":case"pointerdown":case"MSPointerDown":case"mousedown":this._start(t);break;case"touchmove":case"pointermove":case"MSPointerMove":case"mousemove":this._move(t);break;case"touchend":case"pointerup":case"MSPointerUp":case"mouseup":case"touchcancel":case"pointercancel":case"MSPointerCancel":case"mousecancel":this._end(t)}},destroy:function(){this.options.interactive&&(a.removeEvent(this.indicator,"touchstart",this),a.removeEvent(this.indicator,a.prefixPointerEvent("pointerdown"),this),a.removeEvent(this.indicator,"mousedown",this),a.removeEvent(t,"touchmove",this),a.removeEvent(t,a.prefixPointerEvent("pointermove"),this),a.removeEvent(t,"mousemove",this),a.removeEvent(t,"touchend",this),a.removeEvent(t,a.prefixPointerEvent("pointerup"),this),a.removeEvent(t,"mouseup",this)),this.options.defaultScrollbars&&this.wrapper.parentNode.removeChild(this.wrapper)},_start:function(e){var i=e.touches?e.touches[0]:e;e.preventDefault(),e.stopPropagation(),this.transitionTime(),this.initiated=!0,this.moved=!1,this.lastPointX=i.pageX,this.lastPointY=i.pageY,this.startTime=a.getTime(),this.options.disableTouch||a.addEvent(t,"touchmove",this),this.options.disablePointer||a.addEvent(t,a.prefixPointerEvent("pointermove"),this),this.options.disableMouse||a.addEvent(t,"mousemove",this),this.scroller._execEvent("beforeScrollStart")},_move:function(t){var e,i,n,s,o=t.touches?t.touches[0]:t;a.getTime();this.moved||this.scroller._execEvent("scrollStart"),this.moved=!0,e=o.pageX-this.lastPointX,this.lastPointX=o.pageX,i=o.pageY-this.lastPointY,this.lastPointY=o.pageY,n=this.x+e,s=this.y+i,this._pos(n,s),t.preventDefault(),t.stopPropagation()},_end:function(e){if(this.initiated){if(this.initiated=!1,e.preventDefault(),e.stopPropagation(),a.removeEvent(t,"touchmove",this),a.removeEvent(t,a.prefixPointerEvent("pointermove"),this),a.removeEvent(t,"mousemove",this),this.scroller.options.snap){var n=this.scroller._nearestSnap(this.scroller.x,this.scroller.y),s=this.options.snapSpeed||i.max(i.max(i.min(i.abs(this.scroller.x-n.x),1e3),i.min(i.abs(this.scroller.y-n.y),1e3)),300);this.scroller.x==n.x&&this.scroller.y==n.y||(this.scroller.directionX=0,this.scroller.directionY=0,this.scroller.currentPage=n,this.scroller.scrollTo(n.x,n.y,s,this.scroller.options.bounceEasing))}this.moved&&this.scroller._execEvent("scrollEnd")}},transitionTime:function(t){t=t||0,this.indicatorStyle[a.style.transitionDuration]=t+"ms",!t&&a.isBadAndroid&&(this.indicatorStyle[a.style.transitionDuration]="0.001s")},transitionTimingFunction:function(t){this.indicatorStyle[a.style.transitionTimingFunction]=t},refresh:function(){this.transitionTime(),this.options.listenX&&!this.options.listenY?this.indicatorStyle.display=this.scroller.hasHorizontalScroll?"block":"none":this.options.listenY&&!this.options.listenX?this.indicatorStyle.display=this.scroller.hasVerticalScroll?"block":"none":this.indicatorStyle.display=this.scroller.hasHorizontalScroll||this.scroller.hasVerticalScroll?"block":"none",this.scroller.hasHorizontalScroll&&this.scroller.hasVerticalScroll?(a.addClass(this.wrapper,"iScrollBothScrollbars"),a.removeClass(this.wrapper,"iScrollLoneScrollbar"),this.options.defaultScrollbars&&this.options.customStyle&&(this.options.listenX?this.wrapper.style.right="8px":this.wrapper.style.bottom="8px")):(a.removeClass(this.wrapper,"iScrollBothScrollbars"),a.addClass(this.wrapper,"iScrollLoneScrollbar"),this.options.defaultScrollbars&&this.options.customStyle&&(this.options.listenX?this.wrapper.style.right="2px":this.wrapper.style.bottom="2px"));this.wrapper.offsetHeight;this.options.listenX&&(this.wrapperWidth=this.wrapper.clientWidth,this.options.resize?(this.indicatorWidth=i.max(i.round(this.wrapperWidth*this.wrapperWidth/(this.scroller.scrollerWidth||this.wrapperWidth||1)),8),this.indicatorStyle.width=this.indicatorWidth+"px"):this.indicatorWidth=this.indicator.clientWidth,this.maxPosX=this.wrapperWidth-this.indicatorWidth,"clip"==this.options.shrink?(this.minBoundaryX=-this.indicatorWidth+8,this.maxBoundaryX=this.wrapperWidth-8):(this.minBoundaryX=0,this.maxBoundaryX=this.maxPosX),this.sizeRatioX=this.options.speedRatioX||this.scroller.maxScrollX&&this.maxPosX/this.scroller.maxScrollX),this.options.listenY&&(this.wrapperHeight=this.wrapper.clientHeight,this.options.resize?(this.indicatorHeight=i.max(i.round(this.wrapperHeight*this.wrapperHeight/(this.scroller.scrollerHeight||this.wrapperHeight||1)),8),this.indicatorStyle.height=this.indicatorHeight+"px"):this.indicatorHeight=this.indicator.clientHeight,this.maxPosY=this.wrapperHeight-this.indicatorHeight,"clip"==this.options.shrink?(this.minBoundaryY=-this.indicatorHeight+8,this.maxBoundaryY=this.wrapperHeight-8):(this.minBoundaryY=0,this.maxBoundaryY=this.maxPosY),this.maxPosY=this.wrapperHeight-this.indicatorHeight,this.sizeRatioY=this.options.speedRatioY||this.scroller.maxScrollY&&this.maxPosY/this.scroller.maxScrollY),this.updatePosition()},updatePosition:function(){var t=this.options.listenX&&i.round(this.sizeRatioX*this.scroller.x)||0,e=this.options.listenY&&i.round(this.sizeRatioY*this.scroller.y)||0;this.options.ignoreBoundaries||(tthis.maxBoundaryX?"scale"==this.options.shrink?(this.width=i.max(this.indicatorWidth-(t-this.maxPosX),8),this.indicatorStyle.width=this.width+"px",t=this.maxPosX+this.indicatorWidth-this.width):t=this.maxBoundaryX:"scale"==this.options.shrink&&this.width!=this.indicatorWidth&&(this.width=this.indicatorWidth,this.indicatorStyle.width=this.width+"px"),ethis.maxBoundaryY?"scale"==this.options.shrink?(this.height=i.max(this.indicatorHeight-3*(e-this.maxPosY),8),this.indicatorStyle.height=this.height+"px",e=this.maxPosY+this.indicatorHeight-this.height):e=this.maxBoundaryY:"scale"==this.options.shrink&&this.height!=this.indicatorHeight&&(this.height=this.indicatorHeight,this.indicatorStyle.height=this.height+"px")),this.x=t,this.y=e,this.scroller.options.useTransform?this.indicatorStyle[a.style.transform]="translate("+t+"px,"+e+"px)"+this.scroller.translateZ:(this.indicatorStyle.left=t+"px",this.indicatorStyle.top=e+"px")},_pos:function(t,e){t<0?t=0:t>this.maxPosX&&(t=this.maxPosX),e<0?e=0:e>this.maxPosY&&(e=this.maxPosY),t=this.options.listenX?i.round(t/this.sizeRatioX):this.scroller.x,e=this.options.listenY?i.round(e/this.sizeRatioY):this.scroller.y,this.scroller.scrollTo(t,e)},fade:function(t,e){if(!e||this.visible){clearTimeout(this.fadeTimeout),this.fadeTimeout=null;var i=t?250:500,n=t?0:300;t=t?"1":"0",this.wrapperStyle[a.style.transitionDuration]=i+"ms",this.fadeTimeout=setTimeout(function(t){this.wrapperStyle.opacity=t,this.visible=+t}.bind(this,t),n)}}},n.utils=a,"undefined"!=typeof module&&module.exports?module.exports=n:t.IScroll=n}(window,document,Math),"undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(t){var e=t.fn.jquery.split(" ")[0].split(".");if(e[0]<2&&e[1]<9||1==e[0]&&9==e[1]&&e[2]<1||e[0]>=4)throw new Error("Bootstrap's JavaScript requires at least jQuery v1.9.1 but less than v4.0.0")}(jQuery),+function(t){"use strict";function e(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var n=function(t,e,i){for(var n=!0;n;){var s=t,o=e,r=i;n=!1,null===s&&(s=Function.prototype);var a=Object.getOwnPropertyDescriptor(s,o);if(void 0!==a){if("value"in a)return a.value;var l=a.get;if(void 0===l)return;return l.call(r)}var h=Object.getPrototypeOf(s);if(null===h)return;t=h,e=o,i=r,n=!0,a=h=void 0}},s=function(){function t(t,e){for(var i=0;ithis._items.length-1||e<0)){if(this._isSliding)return void t(this._element).one(m.SLID,function(){return i.to(e)});if(n===e)return this.pause(),void this.cycle();var s=e>n?g.NEXT:g.PREVIOUS;this._slide(s,this._items[e])}}},{key:"dispose",value:function(){t(this._element).off(a),t.removeData(this._element,r),this._items=null,this._config=null,this._element=null,this._interval=null,this._isPaused=null,this._isSliding=null,this._activeElement=null,this._indicatorsElement=null}},{key:"_getConfig",value:function(i){return i=t.extend({},f,i),o.typeCheckConfig(e,i,p),i}},{key:"_addEventListeners",value:function(){this._config.keyboard&&t(this._element).on(m.KEYDOWN,t.proxy(this._keydown,this)),"hover"!==this._config.pause||"ontouchstart"in document.documentElement||t(this._element).on(m.MOUSEENTER,t.proxy(this.pause,this)).on(m.MOUSELEAVE,t.proxy(this.cycle,this))}},{key:"_keydown",value:function(t){if(t.preventDefault(),!/input|textarea/i.test(t.target.tagName))switch(t.which){case u:this.prev();break;case d:this.next();break;default:return}}},{key:"_getItemIndex",value:function(e){return this._items=t.makeArray(t(e).parent().find(y.ITEM)),this._items.indexOf(e)}},{key:"_getItemByDirection",value:function(t,e){var i=t===g.NEXT,n=t===g.PREVIOUS,s=this._getItemIndex(e),o=this._items.length-1,r=n&&0===s||i&&s===o;if(r&&!this._config.wrap)return e;var a=t===g.PREVIOUS?-1:1,l=(s+a)%this._items.length;return l===-1?this._items[this._items.length-1]:this._items[l]}},{key:"_triggerSlideEvent",value:function(e,i){var n=t.Event(m.SLIDE,{relatedTarget:e,direction:i});return t(this._element).trigger(n),n}},{key:"_setActiveIndicatorElement",value:function(e){if(this._indicatorsElement){t(this._indicatorsElement).find(y.ACTIVE).removeClass(v.ACTIVE);var i=this._indicatorsElement.children[this._getItemIndex(e)];i&&t(i).addClass(v.ACTIVE)}}},{key:"_slide",value:function(e,i){var n=this,s=t(this._element).find(y.ACTIVE_ITEM)[0],r=i||s&&this._getItemByDirection(e,s),a=Boolean(this._interval),l=e===g.NEXT?v.LEFT:v.RIGHT;if(r&&t(r).hasClass(v.ACTIVE))return void(this._isSliding=!1);var h=this._triggerSlideEvent(r,l);if(!h.isDefaultPrevented()&&s&&r){this._isSliding=!0,a&&this.pause(),this._setActiveIndicatorElement(r);var u=t.Event(m.SLID,{relatedTarget:r,direction:l});o.supportsTransitionEnd()&&t(this._element).hasClass(v.SLIDE)?(t(r).addClass(e),o.reflow(r),t(s).addClass(l),t(r).addClass(l),t(s).one(o.TRANSITION_END,function(){t(r).removeClass(l).removeClass(e),t(r).addClass(v.ACTIVE),t(s).removeClass(v.ACTIVE).removeClass(e).removeClass(l),n._isSliding=!1,setTimeout(function(){return t(n._element).trigger(u)},0)}).emulateTransitionEnd(c)):(t(s).removeClass(v.ACTIVE),t(r).addClass(v.ACTIVE),this._isSliding=!1,t(this._element).trigger(u)),a&&this.cycle()}}}],[{key:"_jQueryInterface",value:function(e){return this.each(function(){var i=t(this).data(r),n=t.extend({},f,t(this).data());"object"==typeof e&&t.extend(n,e);var s="string"==typeof e?e:n.slide;if(i||(i=new l(this,n),t(this).data(r,i)),"number"==typeof e)i.to(e);else if("string"==typeof s){if(void 0===i[s])throw new Error('No method named "'+s+'"');i[s]()}else n.interval&&(i.pause(),i.cycle())})}},{key:"_dataApiClickHandler",value:function(e){var i=o.getSelectorFromElement(this);if(i){var n=t(i)[0];if(n&&t(n).hasClass(v.CAROUSEL)){var s=t.extend({},t(n).data(),t(this).data()),a=this.getAttribute("data-slide-to");a&&(s.interval=!1),l._jQueryInterface.call(t(n),s),a&&t(n).data(r).to(a),e.preventDefault()}}}},{key:"VERSION",get:function(){return n}},{key:"Default",get:function(){return f}}]),l}();return t(document).on(m.CLICK_DATA_API,y.DATA_SLIDE,_._dataApiClickHandler),t(window).on(m.LOAD_DATA_API,function(){t(y.DATA_RIDE).each(function(){var e=t(this);_._jQueryInterface.call(e,e.data())})}),t.fn[e]=_._jQueryInterface,t.fn[e].Constructor=_,t.fn[e].noConflict=function(){return t.fn[e]=h,_._jQueryInterface},_}(jQuery),function(t){var e="collapse",n="4.0.0-alpha.4",r="bs.collapse",a="."+r,l=".data-api",h=t.fn[e],c=600,u={toggle:!0,parent:""},d={toggle:"boolean",parent:"string"},f={SHOW:"show"+a,SHOWN:"shown"+a,HIDE:"hide"+a,HIDDEN:"hidden"+a,CLICK_DATA_API:"click"+a+l},p={IN:"in",COLLAPSE:"collapse",COLLAPSING:"collapsing",COLLAPSED:"collapsed"},g={WIDTH:"width",HEIGHT:"height"},m={ACTIVES:".panel > .in, .panel > .collapsing",DATA_TOGGLE:'[data-toggle="collapse"]'},v=function(){function a(e,n){i(this,a),this._isTransitioning=!1,this._element=e,this._config=this._getConfig(n),this._triggerArray=t.makeArray(t('[data-toggle="collapse"][href="#'+e.id+'"],'+('[data-toggle="collapse"][data-target="#'+e.id+'"]'))),this._parent=this._config.parent?this._getParent():null,this._config.parent||this._addAriaAndCollapsedClass(this._element,this._triggerArray),this._config.toggle&&this.toggle()}return s(a,[{key:"toggle",value:function(){t(this._element).hasClass(p.IN)?this.hide():this.show()}},{key:"show",value:function(){var e=this;if(!this._isTransitioning&&!t(this._element).hasClass(p.IN)){var i=void 0,n=void 0;if(this._parent&&(i=t.makeArray(t(m.ACTIVES)),i.length||(i=null)),!(i&&(n=t(i).data(r),n&&n._isTransitioning))){var s=t.Event(f.SHOW);if(t(this._element).trigger(s),!s.isDefaultPrevented()){i&&(a._jQueryInterface.call(t(i),"hide"),n||t(i).data(r,null));var l=this._getDimension();t(this._element).removeClass(p.COLLAPSE).addClass(p.COLLAPSING),this._element.style[l]=0,this._element.setAttribute("aria-expanded",!0),this._triggerArray.length&&t(this._triggerArray).removeClass(p.COLLAPSED).attr("aria-expanded",!0),this.setTransitioning(!0);var h=function(){t(e._element).removeClass(p.COLLAPSING).addClass(p.COLLAPSE).addClass(p.IN),e._element.style[l]="",e.setTransitioning(!1),t(e._element).trigger(f.SHOWN)};if(!o.supportsTransitionEnd())return void h();var u=l[0].toUpperCase()+l.slice(1),d="scroll"+u;t(this._element).one(o.TRANSITION_END,h).emulateTransitionEnd(c),this._element.style[l]=this._element[d]+"px"}}}}},{key:"hide",value:function(){var e=this;if(!this._isTransitioning&&t(this._element).hasClass(p.IN)){var i=t.Event(f.HIDE);if(t(this._element).trigger(i),!i.isDefaultPrevented()){var n=this._getDimension(),s=n===g.WIDTH?"offsetWidth":"offsetHeight";this._element.style[n]=this._element[s]+"px",o.reflow(this._element),t(this._element).addClass(p.COLLAPSING).removeClass(p.COLLAPSE).removeClass(p.IN),this._element.setAttribute("aria-expanded",!1),this._triggerArray.length&&t(this._triggerArray).addClass(p.COLLAPSED).attr("aria-expanded",!1),this.setTransitioning(!0);var r=function(){e.setTransitioning(!1),t(e._element).removeClass(p.COLLAPSING).addClass(p.COLLAPSE).trigger(f.HIDDEN)};return this._element.style[n]=0,o.supportsTransitionEnd()?void t(this._element).one(o.TRANSITION_END,r).emulateTransitionEnd(c):void r()}}}},{key:"setTransitioning",value:function(t){this._isTransitioning=t}},{key:"dispose",value:function(){t.removeData(this._element,r),this._config=null,this._parent=null,this._element=null,this._triggerArray=null,this._isTransitioning=null}},{key:"_getConfig",value:function(i){return i=t.extend({},u,i),i.toggle=Boolean(i.toggle),o.typeCheckConfig(e,i,d),i}},{key:"_getDimension",value:function(){var e=t(this._element).hasClass(g.WIDTH);return e?g.WIDTH:g.HEIGHT}},{key:"_getParent",value:function(){var e=this,i=t(this._config.parent)[0],n='[data-toggle="collapse"][data-parent="'+this._config.parent+'"]';return t(i).find(n).each(function(t,i){e._addAriaAndCollapsedClass(a._getTargetFromElement(i),[i])}),i}},{key:"_addAriaAndCollapsedClass",value:function(e,i){if(e){var n=t(e).hasClass(p.IN);e.setAttribute("aria-expanded",n),i.length&&t(i).toggleClass(p.COLLAPSED,!n).attr("aria-expanded",n)}}}],[{key:"_getTargetFromElement",value:function(e){var i=o.getSelectorFromElement(e);return i?t(i)[0]:null}},{key:"_jQueryInterface",value:function(e){return this.each(function(){var i=t(this),n=i.data(r),s=t.extend({},u,i.data(),"object"==typeof e&&e);if(!n&&s.toggle&&/show|hide/.test(e)&&(s.toggle=!1),n||(n=new a(this,s),i.data(r,n)),"string"==typeof e){if(void 0===n[e])throw new Error('No method named "'+e+'"');n[e]()}})}},{key:"VERSION",get:function(){return n}},{key:"Default",get:function(){return u}}]),a}();return t(document).on(f.CLICK_DATA_API,m.DATA_TOGGLE,function(e){e.preventDefault();var i=v._getTargetFromElement(this),n=t(i).data(r),s=n?"toggle":t(this).data();v._jQueryInterface.call(t(i),s)}),t.fn[e]=v._jQueryInterface,t.fn[e].Constructor=v,t.fn[e].noConflict=function(){return t.fn[e]=h,v._jQueryInterface},v}(jQuery),function(t){var e="dropdown",n="4.0.0-alpha.4",r="bs.dropdown",a="."+r,l=".data-api",h=t.fn[e],c=27,u=38,d=40,f=3,p={HIDE:"hide"+a,HIDDEN:"hidden"+a,SHOW:"show"+a,SHOWN:"shown"+a,CLICK:"click"+a,CLICK_DATA_API:"click"+a+l,KEYDOWN_DATA_API:"keydown"+a+l},g={BACKDROP:"dropdown-backdrop",DISABLED:"disabled",OPEN:"open"},m={BACKDROP:".dropdown-backdrop",DATA_TOGGLE:'[data-toggle="dropdown"]',FORM_CHILD:".dropdown form",ROLE_MENU:'[role="menu"]',ROLE_LISTBOX:'[role="listbox"]',NAVBAR_NAV:".navbar-nav",VISIBLE_ITEMS:'[role="menu"] li:not(.disabled) a, [role="listbox"] li:not(.disabled) a'},v=function(){function e(t){i(this,e),this._element=t,this._addEventListeners()}return s(e,[{key:"toggle",value:function(){if(this.disabled||t(this).hasClass(g.DISABLED))return!1;var i=e._getParentFromElement(this),n=t(i).hasClass(g.OPEN);if(e._clearMenus(),n)return!1;if("ontouchstart"in document.documentElement&&!t(i).closest(m.NAVBAR_NAV).length){var s=document.createElement("div");s.className=g.BACKDROP,t(s).insertBefore(this),t(s).on("click",e._clearMenus)}var o={relatedTarget:this},r=t.Event(p.SHOW,o);return t(i).trigger(r),!r.isDefaultPrevented()&&(this.focus(),this.setAttribute("aria-expanded","true"),t(i).toggleClass(g.OPEN),t(i).trigger(t.Event(p.SHOWN,o)),!1)}},{key:"dispose",value:function(){t.removeData(this._element,r),t(this._element).off(a),this._element=null}},{key:"_addEventListeners",value:function(){t(this._element).on(p.CLICK,this.toggle)}}],[{key:"_jQueryInterface",value:function(i){return this.each(function(){var n=t(this).data(r);if(n||t(this).data(r,n=new e(this)),"string"==typeof i){if(void 0===n[i])throw new Error('No method named "'+i+'"');n[i].call(this)}})}},{key:"_clearMenus",value:function(i){if(!i||i.which!==f){var n=t(m.BACKDROP)[0];n&&n.parentNode.removeChild(n);for(var s=t.makeArray(t(m.DATA_TOGGLE)),o=0;o0&&a--,i.which===d&&adocument.documentElement.clientHeight;!this._isBodyOverflowing&&t&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),this._isBodyOverflowing&&!t&&(this._element.style.paddingRight=this._scrollbarWidth+"px")}},{key:"_resetAdjustments",value:function(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}},{key:"_checkScrollbar",value:function(){this._isBodyOverflowing=document.body.clientWidth=i){var n=this._targets[this._targets.length-1];this._activeTarget!==n&&this._activate(n)}if(this._activeTarget&&t=this._offsets[s]&&(void 0===this._offsets[s+1]||t .nav-item .fade, > .fade",ACTIVE:".active",ACTIVE_CHILD:"> .nav-item > .active, > .active",DATA_TOGGLE:'[data-toggle="tab"], [data-toggle="pill"]',DROPDOWN_TOGGLE:".dropdown-toggle",DROPDOWN_ACTIVE_CHILD:"> .dropdown-menu .active"},p=function(){function e(t){i(this,e),this._element=t}return s(e,[{key:"show",value:function(){var e=this;if(!this._element.parentNode||this._element.parentNode.nodeType!==Node.ELEMENT_NODE||!t(this._element).hasClass(d.ACTIVE)){var i=void 0,n=void 0,s=t(this._element).closest(f.UL)[0],r=o.getSelectorFromElement(this._element);s&&(n=t.makeArray(t(s).find(f.ACTIVE)),n=n[n.length-1]);var a=t.Event(u.HIDE,{relatedTarget:this._element}),l=t.Event(u.SHOW,{relatedTarget:n});if(n&&t(n).trigger(a),t(this._element).trigger(l),!l.isDefaultPrevented()&&!a.isDefaultPrevented()){r&&(i=t(r)[0]),this._activate(this._element,s);var h=function(){var i=t.Event(u.HIDDEN,{relatedTarget:e._element}),s=t.Event(u.SHOWN,{relatedTarget:n});t(n).trigger(i),t(e._element).trigger(s)};i?this._activate(i,i.parentNode,h):h()}}}},{key:"dispose",value:function(){t.removeClass(this._element,r),this._element=null}},{key:"_activate",value:function(e,i,n){var s=t(i).find(f.ACTIVE_CHILD)[0],r=n&&o.supportsTransitionEnd()&&(s&&t(s).hasClass(d.FADE)||Boolean(t(i).find(f.FADE_CHILD)[0])),a=t.proxy(this._transitionComplete,this,e,s,r,n);s&&r?t(s).one(o.TRANSITION_END,a).emulateTransitionEnd(c):a(),s&&t(s).removeClass(d.IN)}},{key:"_transitionComplete",value:function(e,i,n,s){if(i){t(i).removeClass(d.ACTIVE);var r=t(i).find(f.DROPDOWN_ACTIVE_CHILD)[0];r&&t(r).removeClass(d.ACTIVE),i.setAttribute("aria-expanded",!1)}if(t(e).addClass(d.ACTIVE),e.setAttribute("aria-expanded",!0),n?(o.reflow(e),t(e).addClass(d.IN)):t(e).removeClass(d.FADE),e.parentNode&&t(e.parentNode).hasClass(d.DROPDOWN_MENU)){var a=t(e).closest(f.DROPDOWN)[0];a&&t(a).find(f.DROPDOWN_TOGGLE).addClass(d.ACTIVE),e.setAttribute("aria-expanded",!0)}s&&s()}}],[{key:"_jQueryInterface",value:function(i){return this.each(function(){var n=t(this),s=n.data(r);if(s||(s=s=new e(this),n.data(r,s)),"string"==typeof i){if(void 0===s[i])throw new Error('No method named "'+i+'"');s[i]()}})}},{key:"VERSION",get:function(){return n}}]),e}();return t(document).on(u.CLICK_DATA_API,f.DATA_TOGGLE,function(e){e.preventDefault(),p._jQueryInterface.call(t(this),"show")}),t.fn[e]=p._jQueryInterface,t.fn[e].Constructor=p,t.fn[e].noConflict=function(){return t.fn[e]=h,p._jQueryInterface},p}(jQuery),function(t){if(void 0===window.Tether)throw new Error("Bootstrap tooltips require Tether (http://github.hubspot.com/tether/)");var e="tooltip",n="4.0.0-alpha.4",r="bs.tooltip",a="."+r,l=t.fn[e],h=150,c="bs-tether",u={animation:!0,template:'',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:"0 0",constraints:[]},d={animation:"boolean",template:"string",title:"(string|element|function)",trigger:"string",delay:"(number|object)",html:"boolean",selector:"(string|boolean)",placement:"(string|function)",offset:"string",constraints:"array"},f={TOP:"bottom center",RIGHT:"middle left",BOTTOM:"top center",LEFT:"middle right"},p={IN:"in",OUT:"out"},g={HIDE:"hide"+a,HIDDEN:"hidden"+a,SHOW:"show"+a,SHOWN:"shown"+a,INSERTED:"inserted"+a,CLICK:"click"+a,FOCUSIN:"focusin"+a,FOCUSOUT:"focusout"+a,MOUSEENTER:"mouseenter"+a,MOUSELEAVE:"mouseleave"+a},m={FADE:"fade",IN:"in"},v={TOOLTIP:".tooltip",TOOLTIP_INNER:".tooltip-inner"},y={element:!1,enabled:!1},_={HOVER:"hover",FOCUS:"focus",CLICK:"click",MANUAL:"manual"},E=function(){function l(t,e){i(this,l),this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._tether=null,this.element=t,this.config=this._getConfig(e),this.tip=null,this._setListeners()}return s(l,[{key:"enable",value:function(){this._isEnabled=!0}},{key:"disable",value:function(){this._isEnabled=!1}},{key:"toggleEnabled",value:function(){this._isEnabled=!this._isEnabled}},{key:"toggle",value:function(e){if(e){var i=this.constructor.DATA_KEY,n=t(e.currentTarget).data(i);n||(n=new this.constructor(e.currentTarget,this._getDelegateConfig()),t(e.currentTarget).data(i,n)),n._activeTrigger.click=!n._activeTrigger.click,n._isWithActiveTrigger()?n._enter(null,n):n._leave(null,n)}else{if(t(this.getTipElement()).hasClass(m.IN))return void this._leave(null,this);this._enter(null,this)}}},{key:"dispose",value:function(){clearTimeout(this._timeout),this.cleanupTether(),t.removeData(this.element,this.constructor.DATA_KEY),t(this.element).off(this.constructor.EVENT_KEY),this.tip&&t(this.tip).remove(),this._isEnabled=null,this._timeout=null,this._hoverState=null,this._activeTrigger=null,this._tether=null,this.element=null,this.config=null,this.tip=null}},{key:"show",value:function(){var e=this,i=t.Event(this.constructor.Event.SHOW);if(this.isWithContent()&&this._isEnabled){t(this.element).trigger(i);var n=t.contains(this.element.ownerDocument.documentElement,this.element);if(i.isDefaultPrevented()||!n)return;var s=this.getTipElement(),r=o.getUID(this.constructor.NAME);s.setAttribute("id",r),this.element.setAttribute("aria-describedby",r),this.setContent(),this.config.animation&&t(s).addClass(m.FADE);var a="function"==typeof this.config.placement?this.config.placement.call(this,s,this.element):this.config.placement,h=this._getAttachment(a);t(s).data(this.constructor.DATA_KEY,this).appendTo(document.body),t(this.element).trigger(this.constructor.Event.INSERTED),this._tether=new Tether({attachment:h,element:s,target:this.element,classes:y,classPrefix:c,offset:this.config.offset,constraints:this.config.constraints,addTargetClasses:!1}),o.reflow(s),this._tether.position(),t(s).addClass(m.IN);var u=function(){var i=e._hoverState;e._hoverState=null,t(e.element).trigger(e.constructor.Event.SHOWN),i===p.OUT&&e._leave(null,e)};if(o.supportsTransitionEnd()&&t(this.tip).hasClass(m.FADE))return void t(this.tip).one(o.TRANSITION_END,u).emulateTransitionEnd(l._TRANSITION_DURATION);u()}}},{key:"hide",value:function(e){var i=this,n=this.getTipElement(),s=t.Event(this.constructor.Event.HIDE),r=function(){i._hoverState!==p.IN&&n.parentNode&&n.parentNode.removeChild(n),i.element.removeAttribute("aria-describedby"),t(i.element).trigger(i.constructor.Event.HIDDEN),i.cleanupTether(),e&&e()};t(this.element).trigger(s),s.isDefaultPrevented()||(t(n).removeClass(m.IN),o.supportsTransitionEnd()&&t(this.tip).hasClass(m.FADE)?t(n).one(o.TRANSITION_END,r).emulateTransitionEnd(h):r(),this._hoverState="")}},{key:"isWithContent",value:function(){return Boolean(this.getTitle())}},{key:"getTipElement",value:function(){return this.tip=this.tip||t(this.config.template)[0]}},{key:"setContent",value:function(){var e=t(this.getTipElement());this.setElementContent(e.find(v.TOOLTIP_INNER),this.getTitle()),e.removeClass(m.FADE).removeClass(m.IN),this.cleanupTether()}},{key:"setElementContent",value:function(e,i){var n=this.config.html;"object"==typeof i&&(i.nodeType||i.jquery)?n?t(i).parent().is(e)||e.empty().append(i):e.text(t(i).text()):e[n?"html":"text"](i)}},{key:"getTitle",value:function(){ var t=this.element.getAttribute("data-original-title");return t||(t="function"==typeof this.config.title?this.config.title.call(this.element):this.config.title),t}},{key:"cleanupTether",value:function(){this._tether&&this._tether.destroy()}},{key:"_getAttachment",value:function(t){return f[t.toUpperCase()]}},{key:"_setListeners",value:function(){var e=this,i=this.config.trigger.split(" ");i.forEach(function(i){if("click"===i)t(e.element).on(e.constructor.Event.CLICK,e.config.selector,t.proxy(e.toggle,e));else if(i!==_.MANUAL){var n=i===_.HOVER?e.constructor.Event.MOUSEENTER:e.constructor.Event.FOCUSIN,s=i===_.HOVER?e.constructor.Event.MOUSELEAVE:e.constructor.Event.FOCUSOUT;t(e.element).on(n,e.config.selector,t.proxy(e._enter,e)).on(s,e.config.selector,t.proxy(e._leave,e))}}),this.config.selector?this.config=t.extend({},this.config,{trigger:"manual",selector:""}):this._fixTitle()}},{key:"_fixTitle",value:function(){var t=typeof this.element.getAttribute("data-original-title");(this.element.getAttribute("title")||"string"!==t)&&(this.element.setAttribute("data-original-title",this.element.getAttribute("title")||""),this.element.setAttribute("title",""))}},{key:"_enter",value:function(e,i){var n=this.constructor.DATA_KEY;return i=i||t(e.currentTarget).data(n),i||(i=new this.constructor(e.currentTarget,this._getDelegateConfig()),t(e.currentTarget).data(n,i)),e&&(i._activeTrigger["focusin"===e.type?_.FOCUS:_.HOVER]=!0),t(i.getTipElement()).hasClass(m.IN)||i._hoverState===p.IN?void(i._hoverState=p.IN):(clearTimeout(i._timeout),i._hoverState=p.IN,i.config.delay&&i.config.delay.show?void(i._timeout=setTimeout(function(){i._hoverState===p.IN&&i.show()},i.config.delay.show)):void i.show())}},{key:"_leave",value:function(e,i){var n=this.constructor.DATA_KEY;if(i=i||t(e.currentTarget).data(n),i||(i=new this.constructor(e.currentTarget,this._getDelegateConfig()),t(e.currentTarget).data(n,i)),e&&(i._activeTrigger["focusout"===e.type?_.FOCUS:_.HOVER]=!1),!i._isWithActiveTrigger())return clearTimeout(i._timeout),i._hoverState=p.OUT,i.config.delay&&i.config.delay.hide?void(i._timeout=setTimeout(function(){i._hoverState===p.OUT&&i.hide()},i.config.delay.hide)):void i.hide()}},{key:"_isWithActiveTrigger",value:function(){for(var t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1}},{key:"_getConfig",value:function(i){return i=t.extend({},this.constructor.Default,t(this.element).data(),i),i.delay&&"number"==typeof i.delay&&(i.delay={show:i.delay,hide:i.delay}),o.typeCheckConfig(e,i,this.constructor.DefaultType),i}},{key:"_getDelegateConfig",value:function(){var t={};if(this.config)for(var e in this.config)this.constructor.Default[e]!==this.config[e]&&(t[e]=this.config[e]);return t}}],[{key:"_jQueryInterface",value:function(e){return this.each(function(){var i=t(this).data(r),n="object"==typeof e?e:null;if((i||!/destroy|hide/.test(e))&&(i||(i=new l(this,n),t(this).data(r,i)),"string"==typeof e)){if(void 0===i[e])throw new Error('No method named "'+e+'"');i[e]()}})}},{key:"VERSION",get:function(){return n}},{key:"Default",get:function(){return u}},{key:"NAME",get:function(){return e}},{key:"DATA_KEY",get:function(){return r}},{key:"Event",get:function(){return g}},{key:"EVENT_KEY",get:function(){return a}},{key:"DefaultType",get:function(){return d}}]),l}();return t.fn[e]=E._jQueryInterface,t.fn[e].Constructor=E,t.fn[e].noConflict=function(){return t.fn[e]=l,E._jQueryInterface},E}(jQuery));(function(t){var o="popover",a="4.0.0-alpha.4",l="bs.popover",h="."+l,c=t.fn[o],u=t.extend({},r.Default,{placement:"right",trigger:"click",content:"",template:''}),d=t.extend({},r.DefaultType,{content:"(string|element|function)"}),f={FADE:"fade",IN:"in"},p={TITLE:".popover-title",CONTENT:".popover-content",ARROW:".popover-arrow"},g={HIDE:"hide"+h,HIDDEN:"hidden"+h,SHOW:"show"+h,SHOWN:"shown"+h,INSERTED:"inserted"+h,CLICK:"click"+h,FOCUSIN:"focusin"+h,FOCUSOUT:"focusout"+h,MOUSEENTER:"mouseenter"+h,MOUSELEAVE:"mouseleave"+h},m=function(r){function c(){i(this,c),n(Object.getPrototypeOf(c.prototype),"constructor",this).apply(this,arguments)}return e(c,r),s(c,[{key:"isWithContent",value:function(){return this.getTitle()||this._getContent()}},{key:"getTipElement",value:function(){return this.tip=this.tip||t(this.config.template)[0]}},{key:"setContent",value:function(){var e=t(this.getTipElement());this.setElementContent(e.find(p.TITLE),this.getTitle()),this.setElementContent(e.find(p.CONTENT),this._getContent()),e.removeClass(f.FADE).removeClass(f.IN),this.cleanupTether()}},{key:"_getContent",value:function(){return this.element.getAttribute("data-content")||("function"==typeof this.config.content?this.config.content.call(this.element):this.config.content)}}],[{key:"_jQueryInterface",value:function(e){return this.each(function(){var i=t(this).data(l),n="object"==typeof e?e:null;if((i||!/destroy|hide/.test(e))&&(i||(i=new c(this,n),t(this).data(l,i)),"string"==typeof e)){if(void 0===i[e])throw new Error('No method named "'+e+'"');i[e]()}})}},{key:"VERSION",get:function(){return a}},{key:"Default",get:function(){return u}},{key:"NAME",get:function(){return o}},{key:"DATA_KEY",get:function(){return l}},{key:"Event",get:function(){return g}},{key:"EVENT_KEY",get:function(){return h}},{key:"DefaultType",get:function(){return d}}]),c}(r);return t.fn[o]=m._jQueryInterface,t.fn[o].Constructor=m,t.fn[o].noConflict=function(){return t.fn[o]=c,m._jQueryInterface},m})(jQuery)}(jQuery),!function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports?module.exports=t(require("jquery")):t(jQuery)}(function(t){"use strict";var e="drawer",i="undefined"!=typeof document.ontouchstart,n={init:function(i){return i=t.extend({iscroll:{mouseWheel:!0,preventDefault:!1},showOverlay:!0},i),n.settings={state:!1,events:{opened:"drawer.opened",closed:"drawer.closed"},dropdownEvents:{opened:"shown.bs.dropdown",closed:"hidden.bs.dropdown"}},n.settings.class=t.extend({nav:"drawer-nav",toggle:"drawer-toggle",overlay:"drawer-overlay",open:"drawer-open",close:"drawer-close",dropdown:"drawer-dropdown"},i.class),this.each(function(){var s=this,o=t(this),r=o.data(e);r||(i=t.extend({},i),o.data(e,{options:i}),n.refresh.call(s),i.showOverlay&&n.addOverlay.call(s),t("."+n.settings.class.toggle).on("click."+e,function(){return n.toggle.call(s),s.iScroll.refresh()}),t(window).on("resize."+e,function(){return n.close.call(s),s.iScroll.refresh()}),t("."+n.settings.class.dropdown).on(n.settings.dropdownEvents.opened+" "+n.settings.dropdownEvents.closed,function(){return s.iScroll.refresh()}))})},refresh:function(){this.iScroll=new IScroll("."+n.settings.class.nav,t(this).data(e).options.iscroll)},addOverlay:function(){var e=t(this),i=t("
    ").addClass(n.settings.class.overlay+" "+n.settings.class.toggle);return e.append(i)},toggle:function(){var t=this;return n.settings.state?n.close.call(t):n.open.call(t)},open:function(){var s=t(this);return i&&s.on("touchmove."+e,function(t){t.preventDefault()}),s.removeClass(n.settings.class.close).addClass(n.settings.class.open).css({overflow:"hidden"}).drawerCallback(function(){n.settings.state=!0,s.trigger(n.settings.events.opened)})},close:function(){var s=t(this);return i&&s.off("touchmove."+e),s.removeClass(n.settings.class.open).addClass(n.settings.class.close).css({overflow:"auto"}).drawerCallback(function(){n.settings.state=!1,s.trigger(n.settings.events.closed)})},destroy:function(){return this.each(function(){var i=this,s=t(this);t("."+n.settings.class.toggle).off("click."+e),t(window).off("resize."+e),t("."+n.settings.class.dropdown).off(n.settings.dropdownEvents.opened+" "+n.settings.dropdownEvents.closed),i.iScroll.destroy(),s.removeData(e).find("."+n.settings.class.overlay).remove()})}};t.fn.drawerCallback=function(e){var i="transitionend webkitTransitionEnd";return this.each(function(){var n=t(this);n.on(i,function(){return n.off(i),e.call(this)})})},t.fn.drawer=function(i){return n[i]?n[i].apply(this,Array.prototype.slice.call(arguments,1)):"object"!=typeof i&&i?void t.error("Method "+i+" does not exist on jQuery."+e):n.init.apply(this,arguments)}}),function(t){var e={common:{init:function(){},finalize:function(){}},home:{init:function(){},finalize:function(){}},about_us:{init:function(){}}},i={fire:function(t,i,n){var s,o=e;i=void 0===i?"init":i,s=""!==t,s=s&&o[t],s=s&&"function"==typeof o[t][i],s&&o[t][i](n)},loadEvents:function(){i.fire("common"),t.each(document.body.className.replace(/-/g,"_").split(/\s+/),function(t,e){i.fire(e),i.fire(e,"finalize")}),i.fire("common","finalize")}};t(document).ready(i.loadEvents)}(jQuery);