| Current Path : /var/www/media/com_komento/scripts/ |
| Current File : /var/www/media/com_komento/scripts/site-4.0.2-basic.min.js |
function createSafeFragment(t){var e=nodeNames.split("|"),n=t.createDocumentFragment();if(n.createElement)for(;e.length;)n.createElement(e.pop());return n}function fixDefaultChecked(t){rcheckableType.test(t.type)&&(t.defaultChecked=t.checked)}function getAll(t,e){var n,i,o=0,r=typeof t.getElementsByTagName!==strundefined?t.getElementsByTagName(e||"*"):typeof t.querySelectorAll!==strundefined?t.querySelectorAll(e||"*"):void 0;if(!r)for(r=[],n=t.childNodes||t;null!=(i=n[o]);o++)!e||jQuery.nodeName(i,e)?r.push(i):jQuery.merge(r,getAll(i,e));return void 0===e||e&&jQuery.nodeName(t,e)?jQuery.merge([t],r):r}function setGlobalEval(t,e){for(var n,i=0;null!=(n=t[i]);i++)jQuery._data(n,"globalEval",!e||jQuery._data(e[i],"globalEval"))}!function(){function t(e){function t(){n.push([this,arguments]),i||t.execute()}var n=[],i=1,o=0,e=e;return t.execute=function(){if(!o){var t;for(o=1,i=0;t=n.shift();)e.apply(t[0],t[1]);o=0}},t.lock=function(){i=0},t}var o,e,l={},u=0,r=[],n=window.KTVendors={setup:function(t){e=t,n.init()},jquery:function(t){o||(o=t,n.init())},init:function(){u||o&&e&&(n.$=o.initialize(e),n.plugin.execute(),u=1)},plugin:t(function(t,e){e.apply(n,[o])}),module:t(function(t,e){o.module(t,e)}),installer:function(t,e,n){if(r[t]||(r[t]=[]),!e)return r[t];var i=l[t];if(i.registered)return i.install(e,n);r[t].push([e,n])},component:function(a,t){if(!a)return l;if(!t)return l[a];if("function"==typeof t)return(n=t).registered=!0,l[a]=n;function i(t,e,n){for(var i=0;i<e.length;i++){var o=e[i];t[o]=function(t,e,n){return function(){return(n||s).push(r(t,this,arguments)),e}}(o,t,n)}return t}function e(e,n){return function(){var t=[r(e,this,arguments)];return s.push(t),i({},n,t)}}var n,s=[],r=function(t,e,n){return{method:t,context:this,args:n}};return s.execute=function(){for(var t=l[a],e=0;e<s.length;e++){var n=s[e];if("[object Array]"===Object.prototype.toString.call(n))for(var i=n,o=t,r=0;r<i.length;r++)o=o[i[r].method].apply(o,i[r].args);else t[n.method].apply(t,n.args)}},(n=i(function(){n.run.apply(this.arguments)},["run","ready","template","dialog"])).className=a,n.options=t,n.queue=s,n.module=e("module",["done","always","fail","progress"]),n.require=e("require",["library","script","stylesheet","language","template","app","view","done","always","fail","progress"]),window[a]=l[a]=n,u&&o.Component.register(n),n}}}(),KTVendors.setup({environment:window.kt.environment,source:"local",mode:"production"==window.kt.environment?"compressed":"uncompressed",path:window.kt.rootUrl+"/media/com_komento/scripts/vendors",cdn:"",extension:".js",cdnPath:"",rootPath:window.kt.rootUrl,basePath:window.kt.rootUrl,indexUrl:window.kt.rootUrl+"/index.php",token:window.kt.token,joomla:{appendTitle:window.kt.appendTitle,sitename:window.kt.siteName},locale:{lang:window.kt.locale}}),KTVendors.component("Komento",{environment:window.kt.environment,source:"local",mode:(window.kt.environment,"compressed"),version:"3.0",momentLang:window.kt.momentLang,ajaxUrl:window.kt.ajaxUrl}),jQuery.version="4.0",jQuery.long_version="4.0.37";var support={};!function(){function t(){var t,e,n,i=document.getElementsByTagName("body")[0];i&&i.style&&(t=document.createElement("div"),(e=document.createElement("div")).style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",i.appendChild(e).appendChild(t),t.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",o=r=!1,s=!0,window.getComputedStyle&&(o="1%"!==(window.getComputedStyle(t,null)||{}).top,r="4px"===(window.getComputedStyle(t,null)||{width:"4px"}).width,(n=t.appendChild(document.createElement("div"))).style.cssText=t.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",n.style.marginRight=n.style.width="0",t.style.width="1px",s=!parseFloat((window.getComputedStyle(n,null)||{}).marginRight),t.removeChild(n)),t.innerHTML="<table><tr><td></td><td>t</td></tr></table>",(n=t.getElementsByTagName("td"))[0].style.cssText="margin:0;border:0;padding:0;display:none",(a=0===n[0].offsetHeight)&&(n[0].style.display="",n[1].style.display="none",a=0===n[0].offsetHeight),i.removeChild(e))}var e,o,r,a,s,n=document.createElement("div");n.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",(e=(e=n.getElementsByTagName("a")[0])&&e.style)&&(e.cssText="float:left;opacity:.5",support.opacity="0.5"===e.opacity,support.cssFloat=!!e.cssFloat,n.style.backgroundClip="content-box",n.cloneNode(!0).style.backgroundClip="",support.clearCloneStyle="content-box"===n.style.backgroundClip,support.boxSizing=""===e.boxSizing||""===e.MozBoxSizing||""===e.WebkitBoxSizing,jQuery.extend(support,{reliableHiddenOffsets:function(){return null==a&&t(),a},boxSizingReliable:function(){return null==r&&t(),r},pixelPosition:function(){return null==o&&t(),o},reliableMarginRight:function(){return null==s&&t(),s}}))}();var strundefined="undefined",rcheckableType=/^(?:checkbox|radio)$/i,nodeNames="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",rinlinejQuery=/ jQuery\d+="(?:null|\d+)"/g,rnoshimcache=new RegExp("<(?:"+nodeNames+")[\\s/>]","i"),rleadingWhitespace=/^\s+/,rxhtmlTag=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,rtagName=/<([\w:]+)/,rtbody=/<tbody/i,rhtml=/<|&#?\w+;/,rnoInnerhtml=/<(?:script|style|link)/i,rchecked=/checked\s*(?:[^=]|=\s*.checked.)/i,rscriptType=/^$|\/(?:java|ecma)script/i,rscriptTypeMasked=/^true\/(.*)/,rcleanScript=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,wrapMap={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]},safeFragment=createSafeFragment(document),fragmentDiv=safeFragment.appendChild(document.createElement("div")),matched,browser;wrapMap.optgroup=wrapMap.option,wrapMap.tbody=wrapMap.tfoot=wrapMap.colgroup=wrapMap.caption=wrapMap.thead,wrapMap.th=wrapMap.td,jQuery.uid=function(t,e){return(t||"")+Math.random().toString().replace(".","")+(e||"")},jQuery.globalNamespace=jQuery.uid("Komento"),window[jQuery.globalNamespace]=jQuery,jQuery.run=function(t){return jQuery.isFunction(t)?t(jQuery):null},jQuery.initialize=function(t){jQuery.initialized||(jQuery.buildFragment=function(t,e,n,i){for(var o,r,a,s,l,u,c,d=t.length,f=createSafeFragment(e),h=[],p=0;p<d;p++)if((r=t[p])||0===r)if("object"===jQuery.type(r))jQuery.merge(h,r.nodeType?[r]:r);else if(rhtml.test(r)){for(s=s||f.appendChild(e.createElement("div")),l=(rtagName.exec(r)||["",""])[1].toLowerCase(),c=wrapMap[l]||wrapMap._default,s.innerHTML=c[1]+r.replace(rxhtmlTag,"<$1></$2>")+c[2],o=c[0];o--;)s=s.lastChild;if(!support.leadingWhitespace&&rleadingWhitespace.test(r)&&h.push(e.createTextNode(rleadingWhitespace.exec(r)[0])),!support.tbody)for(o=(r="table"!==l||rtbody.test(r)?"<table>"!==c[1]||rtbody.test(r)?0:s:s.firstChild)&&r.childNodes.length;o--;)jQuery.nodeName(u=r.childNodes[o],"tbody")&&!u.childNodes.length&&r.removeChild(u);for(jQuery.merge(h,s.childNodes),s.textContent="";s.firstChild;)s.removeChild(s.firstChild);s=f.lastChild}else h.push(e.createTextNode(r));for(s&&f.removeChild(s),support.appendChecked||jQuery.grep(getAll(h,"input"),fixDefaultChecked),p=0;r=h[p++];)if((!i||-1===jQuery.inArray(r,i))&&(a=jQuery.contains(r.ownerDocument,r),s=getAll(f.appendChild(r),"script"),a&&setGlobalEval(s),n))for(o=0;r=s[o++];)rscriptType.test(r.type||"")&&n.push(r);return s=null,f},jQuery.extend(jQuery,t),jQuery.initialized=!0,KTVendors.module.execute())},jQuery.uaMatch=function(t){t=t.toLowerCase();t=/(chrome)[ \/]([\w.]+)/.exec(t)||/(webkit)[ \/]([\w.]+)/.exec(t)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(t)||/(msie) ([\w.]+)/.exec(t)||t.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(t)||[];return{browser:t[1]||"",version:t[2]||"0"}},jQuery.browser||(matched=jQuery.uaMatch(navigator.userAgent),browser={},matched.browser&&(browser[matched.browser]=!0,browser.version=matched.version),browser.chrome?browser.webkit=!0:browser.webkit&&(browser.safari=!0),jQuery.browser=browser),KTVendors.jquery(jQuery),"function"==typeof define&&define.amd&&define("jquery",[],function(){return jQuery}),KTVendors.plugin("lodash",function(n){function ee(t,e,n){for(var i=(n||0)-1,o=t?t.length:0;++i<o;)if(t[i]===e)return i;return-1}function ne(t,e){var n=typeof e;return t=t.cache,"boolean"==n||null==e?t[e]?0:-1:(t=(t=t[n="number"!=n&&"string"!=n?"object":n])&&t["number"==n?e:pe+e],"object"==n?t&&-1<ee(t,e)?0:-1:t?0:-1)}function s(t){var e,n=this.cache,i=typeof t;"boolean"==i||null==t?n[t]=!0:(e="number"==(i="number"!=i&&"string"!=i?"object":i)?t:pe+t,n=n[i]||(n[i]={}),"object"==i?(n[e]||(n[e]=[])).push(t):n[e]=!0)}function ie(t){return t.charCodeAt(0)}function oe(t,e){for(var n=t.criteria,i=e.criteria,o=-1,r=n.length;++o<r;){var a=n[o],s=i[o];if(a!==s){if(s<a||void 0===a)return 1;if(a<s||void 0===s)return-1}}return t.index-e.index}function re(t){var e=-1,n=t.length,i=t[0],o=t[n/2|0],r=t[n-1];if(i&&"object"==typeof i&&o&&"object"==typeof o&&r&&"object"==typeof r)return!1;r=le();r.false=r.null=r.true=r[void 0]=!1;var a=le();for(a.array=t,a.cache=r,a.push=s;++e<n;)a.push(t[e]);return a}function ae(t){return"\\"+r[t]}function se(){return e.pop()||[]}function le(){return i.pop()||{array:null,cache:null,criteria:null,false:!1,index:0,null:!1,number:null,object:null,push:null,string:null,true:!1,undefined:!1,value:null}}function ue(t){t.length=0,e.length<o&&e.push(t)}function ce(t){var e=t.cache;e&&ce(e),t.array=t.cache=t.criteria=t.object=t.number=t.string=t.value=null,i.length<o&&i.push(t)}function de(t,e,n){for(var i=-1,o=(n=void 0===n?t?t.length:0:n)-(e=e||0)||0,r=Array(o<0?0:o);++i<o;)r[i]=t[e+i];return r}var fe,e=[],i=[],he=0,pe=+new Date+"",me=75,o=40,ge=" \t\v\f \ufeff\n\r\u2028\u2029 ",ve=/\b__p \+= '';/g,ye=/\b(__p \+=) '' \+/g,be=/(__e\(.*?\)|\b__t\)) \+\n'';/g,we=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,xe=/\w*$/,_e=/^\s*function[ \n\r\t]+\w/,ke=/<%=([\s\S]+?)%>/g,Ce=RegExp("^["+ge+"]*0+(?=.$)"),Te=/($^)/,Ee=/\bthis\b/,Se=/['\n\r\t\u2028\u2029\\]/g,De=["Array","Boolean","Date","Function","Math","Number","Object","RegExp","String","_","attachEvent","clearTimeout","isFinite","isNaN","parseInt","setTimeout"],Ie=0,Me="[object Arguments]",Ae="[object Array]",Oe="[object Boolean]",$e="[object Date]",Fe="[object Function]",je="[object Number]",Pe="[object Object]",Le="[object RegExp]",Ne="[object String]",Re={};Re[Fe]=!1;var ze={leading:!(Re[Me]=Re[Ae]=Re[Oe]=Re[$e]=Re[je]=Re[Pe]=Re[Le]=Re[Ne]=!0),maxWait:0,trailing:!1},We={configurable:!1,enumerable:!1,value:null,writable:!1},Ue={boolean:!1,function:!0,object:!0,number:!1,string:!1,undefined:!1},r={"\\":"\\","'":"'","\n":"n","\r":"r","\t":"t","\u2028":"u2028","\u2029":"u2029"},He=Ue[typeof window]&&window||this,t=Ue[typeof exports]&&exports&&!exports.nodeType&&exports,a=Ue[typeof module]&&module&&!module.nodeType&&module,t=(a&&a.exports,Ue[typeof global]&&global);!t||t.global!==t&&t.window!==t||(He=t);var Ye=n._=function t(n){function d(t){return t&&"object"==typeof t&&!Ht(t)&&Ct.call(t,"__wrapped__")?t:new l(t)}function l(t,e){this.__chain__=!!e,this.__wrapped__=t}function f(t){function i(){var t;if(r&&(t=de(r),Tt.apply(t,arguments)),this instanceof i){var e=m(o.prototype),n=o.apply(e,t||arguments);return E(n)?n:e}return o.apply(a,t||arguments)}var o=t[0],r=t[2],a=t[4];return Ut(i,t),i}function c(t,n,i,o,r){if(i){var a=i(t);if(void 0!==a)return a}if(!E(t))return t;var e=vt.call(t);if(!Re[e])return t;var s=Rt[e];switch(e){case Oe:case $e:return new s(+t);case je:case Ne:return new s(t);case Le:return(a=s(t.source,xe.exec(t))).lastIndex=t.lastIndex,a}if(e=Ht(t),n){var l=!o;o=o||se(),r=r||se();for(var u=o.length;u--;)if(o[u]==t)return r[u];a=e?s(t.length):{}}else a=e?de(t):Vt({},t);return e&&(Ct.call(t,"index")&&(a.index=t.index),Ct.call(t,"input")&&(a.input=t.input)),n&&(o.push(t),r.push(a),(e?F:Jt)(t,function(t,e){a[e]=c(t,n,i,o,r)}),l&&(ue(o),ue(r))),a}function m(t,e){return E(t)?Mt(t):{}}function h(o,r,t){if("function"!=typeof o)return J;if(void 0===r||!("prototype"in o))return o;var e,n=o.__bindData__;if(void 0===n&&((n=(n=zt.funcNames?!o.name:n)||!zt.funcDecomp)||(e=_t.call(o),(n=zt.funcNames?n:!_e.test(e))||(n=Ee.test(e),Ut(o,n)))),!1===n||!0!==n&&1&n[1])return o;switch(t){case 1:return function(t){return o.call(r,t)};case 2:return function(t,e){return o.call(r,t,e)};case 3:return function(t,e,n){return o.call(r,t,e,n)};case 4:return function(t,e,n,i){return o.call(r,t,e,n,i)}}return V(o,r)}function g(t){function i(){var t,e=c?l:this;if(a&&(t=de(a),Tt.apply(t,arguments)),(s||f)&&(t=t||de(arguments),s&&Tt.apply(t,s),f&&t.length<u))return r|=16,g([o,h?r:-4&r,t,null,l,u]);if(t=t||arguments,d&&(o=e[p]),this instanceof i){var e=m(o.prototype),n=o.apply(e,t);return E(n)?n:e}return o.apply(e,t)}var o=t[0],r=t[1],a=t[2],s=t[3],l=t[4],u=t[5],c=1&r,d=2&r,f=4&r,h=8&r,p=o;return Ut(i,t),i}function u(t,e){var n,i=-1,o=b(),r=t?t.length:0,a=me<=r&&o===ee,s=[];for(a&&((n=re(e))?(o=ne,e=n):a=!1);++i<r;){var l=t[i];o(e,l)<0&&s.push(l)}return a&&ce(e),s}function p(t,e,n,i){for(var o=(i||0)-1,r=t?t.length:0,a=[];++o<r;){var s=t[o];if(s&&"object"==typeof s&&"number"==typeof s.length&&(Ht(s)||x(s))){var l=-1,u=(s=e?s:p(s,e,n)).length,c=a.length;for(a.length+=u;++l<u;)a[c++]=s[l]}else n||a.push(s)}return a}function v(i,t,o,r,a,s){if(o&&void 0!==(f=o(i,t)))return!!f;if(i===t)return 0!==i||1/i==1/t;if(!(i!=i||i&&Ue[typeof i]||t&&Ue[typeof t]))return!1;if(null==i||null==t)return i===t;var e=vt.call(i),n=vt.call(t);if((e=e==Me?Pe:e)!=(n=n==Me?Pe:n))return!1;switch(e){case Oe:case $e:return+i==+t;case je:return i!=+i?t!=+t:0==i?1/i==1/t:i==+t;case Le:case Ne:return i==ft(t)}var l=e==Ae;if(!l){var n=Ct.call(i,"__wrapped__"),u=Ct.call(t,"__wrapped__");if(n||u)return v(n?i.__wrapped__:i,u?t.__wrapped__:t,o,r,a,s);if(e!=Pe)return!1;if(e=i.constructor,u=t.constructor,e!=u&&!(T(e)&&e instanceof e&&T(u)&&u instanceof u)&&"constructor"in i&&"constructor"in t)return!1}u=!a,a=a||se(),s=s||se();for(var c=a.length;c--;)if(a[c]==i)return s[c]==t;var d=0,f=!0;if(a.push(i),s.push(t),l){if(c=i.length,d=t.length,(f=d==c)||r)for(;d--;){var h=c,p=t[d];if(r)for(;h--&&!(f=v(i[h],p,o,r,a,s)););else if(!(f=v(i[d],p,o,r,a,s)))break}}else Qt(t,function(t,e,n){if(Ct.call(n,e))return d++,f=Ct.call(i,e)&&v(i[e],t,o,r,a,s)}),f&&!r&&Qt(i,function(t,e,n){if(Ct.call(n,e))return f=-1<--d});return a.pop(),s.pop(),u&&(ue(a),ue(s)),f}function r(t,e){return t+xt(Nt()*(e-t+1))}function o(t,e,n){var i=-1,o=b(),r=t?t.length:0,a=[],s=!e&&me<=r&&o===ee,l=n||s?se():a;for(s&&(o=ne,l=re(l));++i<r;){var u=t[i],c=n?n(u,i,t):u;(e?!i||l[l.length-1]!==c:o(l,c)<0)&&((n||s)&&l.push(c),a.push(u))}return s?(ue(l.array),ce(l)):n&&ue(l),a}function e(s){return function(t,i,e){var o={};i=d.createCallback(i,e,3);var n=-1,r=t?t.length:0;if("number"==typeof r)for(;++n<r;){var a=t[n];s(o,a,i(a,n,t),t)}else Jt(t,function(t,e,n){s(o,t,i(t,e,n),n)});return o}}function y(t,e,n,i,o,r){var a=1&e,s=4&e,l=16&e,u=32&e;if(!(2&e||T(t)))throw new ht;l&&!n.length&&(e&=-17,l=n=!1),u&&!i.length&&(e&=-33,u=i=!1);var c=t&&t.__bindData__;return c&&!0!==c?((c=de(c))[2]&&(c[2]=de(c[2])),c[3]&&(c[3]=de(c[3])),!a||1&c[1]||(c[4]=o),!a&&1&c[1]&&(e|=8),!s||4&c[1]||(c[5]=r),l&&Tt.apply(c[2]||(c[2]=[]),n),u&&Dt.apply(c[3]||(c[3]=[]),i),c[1]|=e,y.apply(null,c)):(1==e||17===e?f:g)([t,e,n,i,o,r])}function i(t){return Kt[t]}function b(){var t=(t=d.indexOf)===H?ee:t;return t}function a(t){return"function"==typeof t&&yt.test(t)}function s(t){var e,n;return!(!t||vt.call(t)!=Pe||T(e=t.constructor)&&!(e instanceof e))&&(Qt(t,function(t,e){n=e}),void 0===n||Ct.call(t,n))}function w(t){return Bt[t]}function x(t){return t&&"object"==typeof t&&"number"==typeof t.length&&vt.call(t)==Me||!1}function _(t,e,n){var i=Yt(t),o=i.length;for(e=h(e,n,3);o--;){var r=i[o];if(!1===e(t[r],r,t))break}return t}function k(t){var n=[];return Qt(t,function(t,e){T(t)&&n.push(e)}),n.sort()}function C(t){for(var e=-1,n=Yt(t),i=n.length,o={};++e<i;){var r=n[e];o[t[r]]=r}return o}function T(t){return"function"==typeof t}function E(t){return!(!t||!Ue[typeof t])}function S(t){return"number"==typeof t||t&&"object"==typeof t&&vt.call(t)==je||!1}function D(t){return"string"==typeof t||t&&"object"==typeof t&&vt.call(t)==Ne||!1}function I(t){for(var e=-1,n=Yt(t),i=n.length,o=ot(i);++e<i;)o[e]=t[n[e]];return o}function M(t,e,n){var i=-1,o=b(),r=t?t.length:0,a=!1;return n=(n<0?jt(0,r+n):n)||0,Ht(t)?a=-1<o(t,e,n):"number"==typeof r?a=-1<(D(t)?t.indexOf(e,n):o(t,e,n)):Jt(t,function(t){if(++i>=n)return!(a=t===e)}),a}function A(t,i,e){var o=!0;i=d.createCallback(i,e,3);var n=-1,r=t?t.length:0;if("number"==typeof r)for(;++n<r&&(o=!!i(t[n],n,t)););else Jt(t,function(t,e,n){return o=!!i(t,e,n)});return o}function O(t,i,e){var o=[];i=d.createCallback(i,e,3);var n=-1,r=t?t.length:0;if("number"==typeof r)for(;++n<r;){var a=t[n];i(a,n,t)&&o.push(a)}else Jt(t,function(t,e,n){i(t,e,n)&&o.push(t)});return o}function $(t,i,e){i=d.createCallback(i,e,3);var o,n=-1,r=t?t.length:0;if("number"!=typeof r)return Jt(t,function(t,e,n){if(i(t,e,n))return o=t,!1}),o;for(;++n<r;){var a=t[n];if(i(a,n,t))return a}}function F(t,e,n){var i=-1,o=t?t.length:0;if(e=e&&void 0===n?e:h(e,n,3),"number"==typeof o)for(;++i<o&&!1!==e(t[i],i,t););else Jt(t,e);return t}function j(t,i,e){var o=t?t.length:0;if(i=i&&void 0===e?i:h(i,e,3),"number"==typeof o)for(;o--&&!1!==i(t[o],o,t););else{var r=Yt(t),o=r.length;Jt(t,function(t,e,n){return e=r?r[--o]:--o,i(n[e],e,n)})}return t}function P(t,i,e){var o=-1,n=t?t.length:0;if(i=d.createCallback(i,e,3),"number"==typeof n)for(var r=ot(n);++o<n;)r[o]=i(t[o],o,t);else r=[],Jt(t,function(t,e,n){r[++o]=i(t,e,n)});return r}function L(t,i,e){var o=-1/0,r=o;if(null==(i="function"!=typeof i&&e&&e[i]===t?null:i)&&Ht(t))for(var n=-1,a=t.length;++n<a;){var s=t[n];r<s&&(r=s)}else i=null==i&&D(t)?ie:d.createCallback(i,e,3),F(t,function(t,e,n){n=i(t,e,n),o<n&&(o=n,r=t)});return r}function N(t,i,o,e){if(!t)return o;var r=arguments.length<3;i=d.createCallback(i,e,4);var n=-1,a=t.length;if("number"==typeof a)for(r&&(o=t[++n]);++n<a;)o=i(o,t[n],n,t);else Jt(t,function(t,e,n){o=r?(r=!1,t):i(o,t,e,n)});return o}function R(t,i,o,e){var r=arguments.length<3;return i=d.createCallback(i,e,4),j(t,function(t,e,n){o=r?(r=!1,t):i(o,t,e,n)}),o}function z(t){var n=-1,e=t?t.length:0,i=ot("number"==typeof e?e:0);return F(t,function(t){var e=r(0,++n);i[n]=i[e],i[e]=t}),i}function W(t,i,e){var o;i=d.createCallback(i,e,3);var n=-1,r=t?t.length:0;if("number"==typeof r)for(;++n<r&&!(o=i(t[n],n,t)););else Jt(t,function(t,e,n){return!(o=i(t,e,n))});return!!o}function U(t,e,n){var i=0,o=t?t.length:0;if("number"!=typeof e&&null!=e){var r=-1;for(e=d.createCallback(e,n,3);++r<o&&e(t[r],r,t);)i++}else if(null==(i=e)||n)return t?t[0]:fe;return de(t,0,Pt(jt(0,i),o))}function H(t,e,n){if("number"==typeof n){var i=t?t.length:0;n=n<0?jt(0,i+n):n||0}else if(n)return i=K(t,e),t[i]===e?i:-1;return ee(t,e,n)}function Y(t,e,n){if("number"!=typeof e&&null!=e){var i=0,o=-1,r=t?t.length:0;for(e=d.createCallback(e,n,3);++o<r&&e(t[o],o,t);)i++}else i=null==e||n?1:jt(0,e);return de(t,i)}function K(t,e,n,i){var o=0,r=t?t.length:o;for(e=(n=n?d.createCallback(n,i,1):J)(e);o<r;){var a=o+r>>>1;n(t[a])<e?o=1+a:r=a}return o}function B(t,e,n,i){return"boolean"!=typeof e&&null!=e&&(i=n,n="function"!=typeof e&&i&&i[e]===t?null:e,e=!1),o(t,e,n=null!=n?d.createCallback(n,i,3):n)}function G(){for(var t=1<arguments.length?arguments:arguments[0],e=-1,n=t?L(Xt(t,"length")):0,i=ot(n<0?0:n);++e<n;)i[e]=Xt(t,e);return i}function q(t,e){var n=-1,i=t?t.length:0,o={};for(e||!i||Ht(t[0])||(e=[]);++n<i;){var r=t[n];e?o[r]=e[n]:r&&(o[r[0]]=r[1])}return o}function V(t,e){return 2<arguments.length?y(t,17,de(arguments,2),null,e):y(t,1,null,null,e)}function Q(i,o,t){function r(){var t,e=o-(te()-c);e<=0?(l&&wt(l),t=h,l=f=h=fe,t&&(m=te(),u=i.apply(d,s),f||l||(s=d=null))):f=Et(r,e)}function a(){f&&wt(f),l=f=h=fe,!v&&g===o||(m=te(),u=i.apply(d,s),f||l||(s=d=null))}var s,l,u,c,d,f,h,p,m=0,g=!1,v=!0;if(!T(i))throw new ht;return o=jt(0,o)||0,!0===t?v=!(p=!0):E(t)&&(p=t.leading,g="maxWait"in t&&(jt(o,t.maxWait)||0),v="trailing"in t?t.trailing:v),function(){var t,e,n;return s=arguments,c=te(),d=this,h=v&&(f||!p),!1===g?t=p&&!f:(n=(e=g-(c-(m=l||p?m:c)))<=0)?(l=l&&wt(l),m=c,u=i.apply(d,s)):l=l||Et(a,e),n&&f?f=wt(f):f||o===g||(f=Et(r,o)),t&&(n=!0,u=i.apply(d,s)),!n||f||l||(s=d=null),u}}function J(t){return t}function Z(o,e,t){var r=!0,n=e&&k(e);e&&(t||n.length)||(null==t&&(t=e),a=l,e=o,o=d,n=k(e)),!1===t?r=!1:E(t)&&"chain"in t&&(r=t.chain);var a=o,s=T(a);F(n,function(t){var i=o[t]=e[t];s&&(a.prototype[t]=function(){var t=this.__chain__,e=this.__wrapped__,n=[e];if(Tt.apply(n,arguments),n=i.apply(o,n),r||t){if(e===n&&E(n))return this;(n=new a(n)).__chain__=t}return n})})}function X(){}function tt(e){return function(t){return t[e]}}function et(){return this.__wrapped__}function nt(){}function it(t,e,n){var i,o,r=t;if(!t)return r;for(var a=arguments,s=0,l="number"==typeof n?2:a.length;++s<l;)if((o=a[s])&&Ue[typeof o])for(var u=-1,c=Ue[typeof o]&&Yt(o),d=c?c.length:0;++u<d;)void 0===r[i=c[u]]&&(r[i]=o[i]);return r}var ot=(n=n?Ye.defaults(He.Object(),n,Ye.pick(He,De)):He).Array,rt=n.Boolean,at=n.Date,st=n.Function,lt=n.Math,ut=n.Number,ct=n.Object,dt=n.RegExp,ft=n.String,ht=n.TypeError,pt=[],mt=ct.prototype,gt=n._,vt=mt.toString,yt=dt("^"+ft(vt).replace(/[.*+?^${}()|[\]\\]/g,"\\$&").replace(/toString| for [^\]]+/g,".*?")+"$"),bt=lt.ceil,wt=n.clearTimeout,xt=lt.floor,_t=st.prototype.toString,kt=a(kt=ct.getPrototypeOf)&&kt,Ct=mt.hasOwnProperty,Tt=pt.push,Et=n.setTimeout,St=pt.splice,Dt=pt.unshift,It=function(){try{var t={},e=a(e=ct.defineProperty)&&e,n=e(t,t,t)&&e}catch(t){}return n}(),Mt=a(Mt=ct.create)&&Mt,At=a(At=ot.isArray)&&At,Ot=n.isFinite,$t=n.isNaN,Ft=a(Ft=ct.keys)&&Ft,jt=lt.max,Pt=lt.min,Lt=n.parseInt,Nt=lt.random,Rt={};Rt[Ae]=ot,Rt[Oe]=rt,Rt[$e]=at,Rt[Fe]=st,Rt[Pe]=ct,Rt[je]=ut,Rt[Le]=dt,Rt[Ne]=ft,l.prototype=d.prototype;var zt=d.support={};zt.funcDecomp=!a(n.WinRTError)&&Ee.test(t),zt.funcNames="string"==typeof st.name,d.templateSettings={escape:/<%-([\s\S]+?)%>/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:ke,variable:"",imports:{_:d}},Mt||(m=function(t){var e;return E(t)&&(nt.prototype=t,e=new nt,nt.prototype=null),e||n.Object()});var Wt,Ut=It?function(t,e){We.value=e,It(t,"__bindData__",We)}:X,Ht=At||function(t){return t&&"object"==typeof t&&"number"==typeof t.length&&vt.call(t)==Ae||!1},Yt=Ft?function(t){return E(t)?Ft(t):[]}:function(t){var e,n=t,i=[];if(!n)return i;if(!Ue[typeof t])return i;for(e in n)Ct.call(n,e)&&i.push(e);return i},Kt={"&":"&","<":"<",">":">",'"':""","'":"'"},Bt=C(Kt),Gt=dt("("+Yt(Bt).join("|")+")","g"),qt=dt("["+Yt(Kt).join("")+"]","g"),Vt=function(t,e,n){var i,o,r=t;if(!t)return r;var a,s=arguments,l=0,u="number"==typeof n?2:s.length;for(3<u&&"function"==typeof s[u-2]?a=h(s[--u-1],s[u--],2):2<u&&"function"==typeof s[u-1]&&(a=s[--u]);++l<u;)if((o=s[l])&&Ue[typeof o])for(var c=-1,d=Ue[typeof o]&&Yt(o),f=d?d.length:0;++c<f;)r[i=d[c]]=a?a(r[i],o[i]):o[i];return r},Qt=function(t,e,n){var i,o=t,r=o;if(!o)return r;if(!Ue[typeof o])return r;for(i in e=e&&void 0===n?e:h(e,n,3),o)if(!1===e(o[i],i,t))return r;return r},Jt=function(t,e,n){var i,o=t,r=o;if(!o)return r;if(!Ue[typeof o])return r;e=e&&void 0===n?e:h(e,n,3);for(var a=-1,s=Ue[typeof o]&&Yt(o),l=s?s.length:0;++a<l;)if(!1===e(o[i=s[a]],i,t))return r;return r},Zt=kt?function(t){if(!t||vt.call(t)!=Pe)return!1;var e=t.valueOf,n=a(e)&&(n=kt(e))&&kt(n);return n?t==n||kt(t)==n:s(t)}:s,mt=e(function(t,e,n){Ct.call(t,n)?t[n]++:t[n]=1}),lt=e(function(t,e,n){(Ct.call(t,n)?t[n]:t[n]=[]).push(e)}),rt=e(function(t,e,n){t[n]=e}),Xt=P,ut=O,te=a(te=at.now)&&te||function(){return(new at).getTime()},At=8==Lt(ge+"08")?Lt:function(t,e){return Lt(D(t)?t.replace(Ce,""):t,e||0)};return d.after=function(t,e){if(!T(e))throw new ht;return function(){if(--t<1)return e.apply(this,arguments)}},d.assign=Vt,d.at=function(t){for(var e=arguments,n=-1,i=p(e,!0,!1,1),o=e[2]&&e[2][e[1]]===t?1:i.length,r=ot(o);++n<o;)r[n]=t[i[n]];return r},d.bind=V,d.bindAll=function(t){for(var e=1<arguments.length?p(arguments,!0,!1,1):k(t),n=-1,i=e.length;++n<i;){var o=e[n];t[o]=y(t[o],1,null,null,t)}return t},d.bindKey=function(t,e){return 2<arguments.length?y(e,19,de(arguments,2),null,t):y(e,3,null,null,t)},d.chain=function(t){return(t=new l(t)).__chain__=!0,t},d.compact=function(t){for(var e=-1,n=t?t.length:0,i=[];++e<n;){var o=t[e];o&&i.push(o)}return i},d.compose=function(){for(var n=arguments,t=n.length;t--;)if(!T(n[t]))throw new ht;return function(){for(var t=arguments,e=n.length;e--;)t=[n[e].apply(this,t)];return t[0]}},d.constant=function(t){return function(){return t}},d.countBy=mt,d.create=function(t,e){return t=m(t),e?Vt(t,e):t},d.createCallback=function(i,t,e){var n=typeof i;if(null==i||"function"==n)return h(i,t,e);if("object"!=n)return tt(i);var o=Yt(i),r=o[0],a=i[r];return 1!=o.length||a!=a||E(a)?function(t){for(var e=o.length,n=!1;e--&&(n=v(t[o[e]],i[o[e]],null,!0)););return n}:function(t){return t=t[r],a===t&&(0!==a||1/a==1/t)}},d.curry=function(t,e){return y(t,4,null,null,null,e="number"==typeof e?e:+e||t.length)},d.debounce=Q,d.defaults=it,d.defer=function(t){if(!T(t))throw new ht;var e=de(arguments,1);return Et(function(){t.apply(fe,e)},1)},d.delay=function(t,e){if(!T(t))throw new ht;var n=de(arguments,2);return Et(function(){t.apply(fe,n)},e)},d.difference=function(t){return u(t,p(arguments,!0,!0,1))},d.filter=O,d.flatten=function(t,e,n,i){return"boolean"!=typeof e&&null!=e&&(i=n,n="function"!=typeof e&&i&&i[e]===t?null:e,e=!1),p(t=null!=n?P(t,n,i):t,e)},d.forEach=F,d.forEachRight=j,d.forIn=Qt,d.forInRight=function(t,e,n){var i=[];Qt(t,function(t,e){i.push(e,t)});var o=i.length;for(e=h(e,n,3);o--&&!1!==e(i[o--],i[o],t););return t},d.forOwn=Jt,d.forOwnRight=_,d.functions=k,d.groupBy=lt,d.indexBy=rt,d.initial=function(t,e,n){var i=0,o=t?t.length:0;if("number"!=typeof e&&null!=e){var r=o;for(e=d.createCallback(e,n,3);r--&&e(t[r],r,t);)i++}else i=null==e||n?1:e||i;return de(t,0,Pt(jt(0,o-i),o))},d.intersection=function(){for(var t=[],e=-1,n=arguments.length,i=se(),o=b(),r=o===ee,a=se();++e<n;){var s=arguments[e];(Ht(s)||x(s))&&(t.push(s),i.push(r&&s.length>=me&&re(e?t[e]:a)))}var l=t[0],u=-1,c=l?l.length:0,d=[];t:for(;++u<c;){var f=i[0],s=l[u];if((f?ne(f,s):o(a,s))<0){for(e=n,(f||a).push(s);--e;)if(((f=i[e])?ne(f,s):o(t[e],s))<0)continue t;d.push(s)}}for(;n--;)(f=i[n])&&ce(f);return ue(i),ue(a),d},d.invert=C,d.invoke=function(t,e){var n=de(arguments,2),i=-1,o="function"==typeof e,r=t?t.length:0,a=ot("number"==typeof r?r:0);return F(t,function(t){a[++i]=(o?e:t[e]).apply(t,n)}),a},d.keys=Yt,d.map=P,d.mapValues=function(t,i,e){var o={};return i=d.createCallback(i,e,3),Jt(t,function(t,e,n){o[e]=i(t,e,n)}),o},d.max=L,d.memoize=function(n,i){function o(){var t=o.cache,e=i?i.apply(this,arguments):pe+arguments[0];return Ct.call(t,e)?t[e]:t[e]=n.apply(this,arguments)}if(!T(n))throw new ht;return o.cache={},o.reset=function(){var t=o.cache,e=i?i.apply(this,arguments):pe+arguments[0];Ct.call(t,e)&&delete t[e]},o},d.merge=function(t){var e,n=arguments,i=2;if(!E(t))return t;3<(i="number"!=typeof n[2]?n.length:i)&&"function"==typeof n[i-2]?e=h(n[--i-1],n[i--],2):2<i&&"function"==typeof n[i-1]&&(e=n[--i]);for(var o=de(arguments,1,i),r=-1,a=se(),s=se();++r<i;)!function l(u,t,c,d,f){(Ht(t)?F:Jt)(t,function(t,e){var n,i,o=t,r=u[e];if(t&&((i=Ht(t))||Zt(t))){for(var a,s=d.length;s--;)if(n=d[s]==t){r=f[s];break}n||(c&&(a=void 0!==(o=c(r,t)))&&(r=o),a||(r=i?Ht(r)?r:[]:Zt(r)?r:{}),d.push(t),f.push(r),a||l(r,t,c,d,f))}else void 0!==(o=c&&void 0===(o=c(r,t))?t:o)&&(r=o);u[e]=r})}(t,o[r],e,a,s);return ue(a),ue(s),t},d.min=function(t,i,e){var o=1/0,r=o;if(null==(i="function"!=typeof i&&e&&e[i]===t?null:i)&&Ht(t))for(var n=-1,a=t.length;++n<a;){var s=t[n];s<r&&(r=s)}else i=null==i&&D(t)?ie:d.createCallback(i,e,3),F(t,function(t,e,n){(n=i(t,e,n))<o&&(o=n,r=t)});return r},d.omit=function(t,i,e){var o={};if("function"!=typeof i){var n=[];Qt(t,function(t,e){n.push(e)});for(var r=-1,a=(n=u(n,p(arguments,!0,!1,1))).length;++r<a;){var s=n[r];o[s]=t[s]}}else i=d.createCallback(i,e,3),Qt(t,function(t,e,n){i(t,e,n)||(o[e]=t)});return o},d.once=function(t){var e,n;if(!T(t))throw new ht;return function(){return e||(e=!0,n=t.apply(this,arguments),t=null),n}},d.pairs=function(t){for(var e=-1,n=Yt(t),i=n.length,o=ot(i);++e<i;){var r=n[e];o[e]=[r,t[r]]}return o},d.partial=function(t){return y(t,16,de(arguments,1))},d.partialRight=function(t){return y(t,32,null,de(arguments,1))},d.pick=function(t,i,e){var o={};if("function"!=typeof i)for(var n=-1,r=p(arguments,!0,!1,1),a=E(t)?r.length:0;++n<a;){var s=r[n];s in t&&(o[s]=t[s])}else i=d.createCallback(i,e,3),Qt(t,function(t,e,n){i(t,e,n)&&(o[e]=t)});return o},d.pluck=Xt,d.property=tt,d.pull=function(t){for(var e=arguments,n=0,i=e.length,o=t?t.length:0;++n<i;)for(var r=-1,a=e[n];++r<o;)t[r]===a&&(St.call(t,r--,1),o--);return t},d.range=function(t,e,n){t=+t||0,null==e&&(e=t,t=0);for(var i=-1,o=jt(0,bt((e-t)/((n="number"==typeof n?n:+n||1)||1))),r=ot(o);++i<o;)r[i]=t,t+=n;return r},d.reject=function(t,i,e){return i=d.createCallback(i,e,3),O(t,function(t,e,n){return!i(t,e,n)})},d.remove=function(t,e,n){var i=-1,o=t?t.length:0,r=[];for(e=d.createCallback(e,n,3);++i<o;){var a=t[i];e(a,i,t)&&(r.push(a),St.call(t,i--,1),o--)}return r},d.rest=Y,d.shuffle=z,d.sortBy=function(t,o,e){var r=-1,a=Ht(o),n=t?t.length:0,s=ot("number"==typeof n?n:0);for(a||(o=d.createCallback(o,e,3)),F(t,function(e,t,n){var i=s[++r]=le();a?i.criteria=P(o,function(t){return e[t]}):(i.criteria=se())[0]=o(e,t,n),i.index=r,i.value=e}),n=s.length,s.sort(oe);n--;){var i=s[n];s[n]=i.value,a||ue(i.criteria),ce(i)}return s},d.tap=function(t,e){return e(t),t},d.throttle=function(t,e,n){var i=!0,o=!0;if(!T(t))throw new ht;return!1===n?i=!1:E(n)&&(i="leading"in n?n.leading:i,o="trailing"in n?n.trailing:o),ze.leading=i,ze.maxWait=e,ze.trailing=o,Q(t,e,ze)},d.times=function(t,e,n){t=-1<(t=+t)?t:0;var i=-1,o=ot(t);for(e=h(e,n,1);++i<t;)o[i]=e(i);return o},d.toArray=function(t){return(t&&"number"==typeof t.length?de:I)(t)},d.transform=function(t,i,o,e){var n,r=Ht(t);return null==o&&(o=r?[]:m((n=t&&t.constructor)&&n.prototype)),i&&(i=d.createCallback(i,e,4),(r?F:Jt)(t,function(t,e,n){return i(o,t,e,n)})),o},d.union=function(){return o(p(arguments,!0,!0))},d.uniq=B,d.values=I,d.where=ut,d.without=function(t){return u(t,de(arguments,1))},d.wrap=function(t,e){return y(e,16,[t])},d.xor=function(){for(var t=-1,e=arguments.length;++t<e;){var n,i=arguments[t];(Ht(i)||x(i))&&(n=n?o(u(n,i).concat(u(i,n))):i)}return n||[]},d.zip=G,d.zipObject=q,d.collect=P,d.drop=Y,d.each=F,d.eachRight=j,d.extend=Vt,d.methods=k,d.object=q,d.select=O,d.tail=Y,d.unique=B,d.unzip=G,Z(d),d.clone=function(t,e,n,i){return"boolean"!=typeof e&&null!=e&&(i=n,n=e,e=!1),c(t,e,"function"==typeof n&&h(n,i,1))},d.cloneDeep=function(t,e,n){return c(t,!0,"function"==typeof e&&h(e,n,1))},d.contains=M,d.escape=function(t){return null==t?"":ft(t).replace(qt,i)},d.every=A,d.find=$,d.findIndex=function(t,e,n){var i=-1,o=t?t.length:0;for(e=d.createCallback(e,n,3);++i<o;)if(e(t[i],i,t))return i;return-1},d.findKey=function(t,i,e){var o;return i=d.createCallback(i,e,3),Jt(t,function(t,e,n){if(i(t,e,n))return o=e,!1}),o},d.findLast=function(t,i,e){var o;return i=d.createCallback(i,e,3),j(t,function(t,e,n){if(i(t,e,n))return o=t,!1}),o},d.findLastIndex=function(t,e,n){var i=t?t.length:0;for(e=d.createCallback(e,n,3);i--;)if(e(t[i],i,t))return i;return-1},d.findLastKey=function(t,i,e){var o;return i=d.createCallback(i,e,3),_(t,function(t,e,n){if(i(t,e,n))return o=e,!1}),o},d.has=function(t,e){return!!t&&Ct.call(t,e)},d.identity=J,d.indexOf=H,d.isArguments=x,d.isArray=Ht,d.isBoolean=function(t){return!0===t||!1===t||t&&"object"==typeof t&&vt.call(t)==Oe||!1},d.isDate=function(t){return t&&"object"==typeof t&&vt.call(t)==$e||!1},d.isElement=function(t){return t&&1===t.nodeType||!1},d.isEmpty=function(t){var e=!0;if(!t)return e;var n=vt.call(t),i=t.length;return n==Ae||n==Ne||n==Me||n==Pe&&"number"==typeof i&&T(t.splice)?!i:(Jt(t,function(){return e=!1}),e)},d.isEqual=function(t,e,n,i){return v(t,e,"function"==typeof n&&h(n,i,2))},d.isFinite=function(t){return Ot(t)&&!$t(parseFloat(t))},d.isFunction=T,d.isNaN=function(t){return S(t)&&t!=+t},d.isNull=function(t){return null===t},d.isNumber=S,d.isObject=E,d.isPlainObject=Zt,d.isRegExp=function(t){return t&&"object"==typeof t&&vt.call(t)==Le||!1},d.isString=D,d.isUndefined=function(t){return void 0===t},d.lastIndexOf=function(t,e,n){var i=t?t.length:0;for("number"==typeof n&&(i=(n<0?jt(0,i+n):Pt(n,i-1))+1);i--;)if(t[i]===e)return i;return-1},d.mixin=Z,d.noConflict=function(){return n._=gt,this},d.noop=X,d.now=te,d.parseInt=At,d.random=function(t,e,n){var i=null==t,o=null==e;return null==n&&("boolean"==typeof t&&o?(n=t,t=1):o||"boolean"!=typeof e||(n=e,o=!0)),i&&o&&(e=1),t=+t||0,o?(e=t,t=0):e=+e||0,n||t%1||e%1?(n=Nt(),Pt(t+n*(e-t+parseFloat("1e-"+((n+"").length-1))),e)):r(t,e)},d.reduce=N,d.reduceRight=R,d.result=function(t,e){if(t){var n=t[e];return T(n)?t[e]():n}},d.runInContext=t,d.size=function(t){var e=t?t.length:0;return"number"==typeof e?e:Yt(t).length},d.some=W,d.sortedIndex=K,d.template=function(a,t,e){var n=d.templateSettings;a=ft(a||""),e=it({},e,n);var s,i=it({},e.imports,n.imports),o=Yt(i),r=I(i),l=0,n=e.interpolate||Te,u="__p += '",i=dt((e.escape||Te).source+"|"+n.source+"|"+(n===ke?we:Te).source+"|"+(e.evaluate||Te).source+"|$","g");a.replace(i,function(t,e,n,i,o,r){return n=n||i,u+=a.slice(l,r).replace(Se,ae),e&&(u+="' +\n__e("+e+") +\n'"),o&&(s=!0,u+="';\n"+o+";\n__p += '"),n&&(u+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),l=r+t.length,t}),u+="';\n",n=e.variable,(i=n)||(u="with ("+(n="obj")+") {\n"+u+"\n}\n"),u=(s?u.replace(ve,""):u).replace(ye,"$1").replace(be,"$1;"),u="function("+n+") {\n"+(i?"":n+" || ("+n+" = {});\n")+"var __t, __p = '', __e = _.escape"+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+u+"return __p\n}",e="\n/*\n//# sourceURL="+(e.sourceURL||"/lodash/template/source["+Ie+++"]")+"\n*/";try{var c=st(o,"return "+u+e).apply(fe,r)}catch(t){throw t.source=u,t}return t?c(t):(c.source=u,c)},d.unescape=function(t){return null==t?"":ft(t).replace(Gt,w)},d.uniqueId=function(t){var e=++he;return ft(null==t?"":t)+e},d.all=A,d.any=W,d.detect=$,d.findWhere=$,d.foldl=N,d.foldr=R,d.include=M,d.inject=N,Z((Wt={},Jt(d,function(t,e){d.prototype[e]||(Wt[e]=t)}),Wt),!1),d.first=U,d.last=function(t,e,n){var i=0,o=t?t.length:0;if("number"!=typeof e&&null!=e){var r=o;for(e=d.createCallback(e,n,3);r--&&e(t[r],r,t);)i++}else if(null==(i=e)||n)return t?t[o-1]:fe;return de(t,jt(0,o-i))},d.sample=function(t,e,n){return t&&"number"!=typeof t.length&&(t=I(t)),null==e||n?t?t[r(0,t.length-1)]:fe:((t=z(t)).length=Pt(jt(0,e),t.length),t)},d.take=U,d.head=U,Jt(d,function(o,t){var r="sample"!==t;d.prototype[t]||(d.prototype[t]=function(t,e){var n=this.__chain__,i=o(this.__wrapped__,t,e);return n||null!=t&&(!e||r&&"function"==typeof t)?new l(i,n):i})}),d.VERSION="2.4.1",d.prototype.chain=function(){return this.__chain__=!0,this},d.prototype.toString=function(){return ft(this.__wrapped__)},d.prototype.value=et,d.prototype.valueOf=et,F(["join","pop","shift"],function(t){var n=pt[t];d.prototype[t]=function(){var t=this.__chain__,e=n.apply(this.__wrapped__,arguments);return t?new l(e,t):e}}),F(["push","reverse","sort","unshift"],function(t){var e=pt[t];d.prototype[t]=function(){return e.apply(this.__wrapped__,arguments),this}}),F(["concat","slice","splice"],function(t){var e=pt[t];d.prototype[t]=function(){return new l(e.apply(this.__wrapped__,arguments),this.__chain__)}}),d}();n.each(Ye,function(t,e){Object.hasOwnProperty.call(Ye,t)&&!/VERSION/.test(name)&&(n[t]||(n[t]=e))})}),KTVendors.plugin("bootstrap3",function(t){if(window["Komento/Bootstrap"])throw new Error("An instance of Bootstrap has been initialized before this.");window["Komento/Bootstrap"]={version:"3.0.3",foundry:t},function(i){"use strict";i.fn.emulateTransitionEnd=function(t){var e=!1,n=this;i(this).one(i.support.transition.end,function(){e=!0});return setTimeout(function(){e||i(n).trigger(i.support.transition.end)},t),this},i(function(){i.support.transition=function(){var t,e=document.createElement("bootstrap"),n={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(t in n)if(void 0!==e.style[t])return{end:n[t]}}()})}(t),function(r){"use strict";function i(t){r(t).on("click",e,this.close)}var e='[data-bs-dismiss="alert"]';i.prototype.close=function(t){function e(){o.trigger("closed.bs.alert").remove()}var n=r(this),i=(i=n.attr("data-target"))||(i=n.attr("href"))&&i.replace(/.*(?=#[^\s]*$)/,""),o=r(i);t&&t.preventDefault(),(o=!o.length?n.hasClass("alert")?n:n.parent():o).trigger(t=r.Event("close.bs.alert")),t.isDefaultPrevented()||(o.removeClass("in"),r.support.transition&&o.hasClass("fade")?o.one(r.support.transition.end,e).emulateTransitionEnd(150):e())};var t=r.fn.alert;r.fn.alert=function(n){return this.each(function(){var t=r(this),e=t.data("bs.alert");e||t.data("bs.alert",e=new i(this)),"string"==typeof n&&e[n].call(t)})},r.fn.alert.Constructor=i,r.fn.alert.noConflict=function(){return r.fn.alert=t,this},r(document).on("click.bs.alert.data-api",e,i.prototype.close)}(t),function(o){"use strict";function r(){o(".dropdown-backdrop").remove(),o(s).each(function(t){var e=a(o(this));e.hasClass("open")&&(e.triggerHandler(t=o.Event("hide.bs.dropdown")),t.isDefaultPrevented()||e.removeClass("open").trigger("hidden.bs.dropdown"))})}function a(t){var e=t.attr("data-target"),e=(e=e||(e=t.attr("href"))&&/#/.test(e)&&e.replace(/.*(?=#[^\s]*$)/,""))&&o(e);return e&&e.length?e:t.parent()}function i(t){o(t).on("click.bs.dropdown",this.toggle)}var s="[data-kt-toggle=dropdown]";i.prototype.toggle=function(t){var e=o(this);if(!e.is(".disabled, :disabled")){var n=a(e),i=n.hasClass("open");if(r(),!i){if("ontouchstart"in document.documentElement&&!n.closest(".navbar-nav").length&&o('<div class="dropdown-backdrop"/>').insertAfter(o(this)).on("click",r),n.triggerHandler(t=o.Event("show.bs.dropdown")),t.isDefaultPrevented())return;n.toggleClass("open").trigger("shown.bs.dropdown"),e.focus()}return!1}},i.prototype.keydown=function(t){if(/(38|40|27)/.test(t.keyCode)){var e=o(this);if(t.preventDefault(),t.stopPropagation(),!e.is(".disabled, :disabled")){var n=a(e),i=n.hasClass("open");if(!i||27==t.keyCode)return 27==t.which&&n.find(s).focus(),e.click();e=o("[role=menu] li:not(.divider):visible a",n);e.length&&(n=e.index(e.filter(":focus")),38==t.keyCode&&0<n&&n--,40==t.keyCode&&n<e.length-1&&n++,e.eq(n=!~n?0:n).focus())}}};var t=o.fn.dropdown;o.fn.dropdown=function(n){return this.each(function(){var t=o(this),e=t.data("bs.dropdown");e||t.data("bs.dropdown",e=new i(this)),"string"==typeof n&&e[n].call(t)})},o.fn.dropdown.Constructor=i,o.fn.dropdown.noConflict=function(){return o.fn.dropdown=t,this},o(document).on("click.bs.dropdown.data-api",r).on("click.bs.dropdown.data-api",".dropdown_ form, .dropdown-static",function(t){t.stopPropagation()}).on("click.bs.dropdown.data-api",s,i.prototype.toggle).on("keydown.bs.dropdown.data-api",s+", [role=menu]",i.prototype.keydown)}(t),function(c){"use strict";function i(t,e){this.type=this.options=this.enabled=this.timeout=this.hoverState=this.$element=null,this.init("tooltip",t,e)}i.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1},i.prototype.init=function(t,e,n){this.enabled=!0,this.type=t,this.$element=c(e),this.options=this.getOptions(n);for(var i=this.options.trigger.split(" "),o=i.length;o--;){var r,a=i[o];"click"==a?this.$element.on("click."+this.type,this.options.selector,c.proxy(this.toggle,this)):"manual"!=a&&(r="hover"==a?"mouseleave":"blur",this.$element.on(("hover"==a?"mouseenter":"focus")+"."+this.type,this.options.selector,c.proxy(this.enter,this)),this.$element.on(r+"."+this.type,this.options.selector,c.proxy(this.leave,this)))}this.options.selector?this._options=c.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},i.prototype.getDefaults=function(){return i.DEFAULTS},i.prototype.getOptions=function(t){return(t=c.extend({},this.getDefaults(),this.$element.data(),t)).delay&&"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),t},i.prototype.getDelegateOptions=function(){var n={},i=this.getDefaults();return this._options&&c.each(this._options,function(t,e){i[t]!=e&&(n[t]=e)}),n},i.prototype.enter=function(t){var e=t instanceof this.constructor?t:c(t.currentTarget)[this.type](this.getDelegateOptions()).data("bs."+this.type);if(clearTimeout(e.timeout),e.hoverState="in",!e.options.delay||!e.options.delay.show)return e.show();e.timeout=setTimeout(function(){"in"==e.hoverState&&e.show()},e.options.delay.show)},i.prototype.leave=function(t){var e=t instanceof this.constructor?t:c(t.currentTarget)[this.type](this.getDelegateOptions()).data("bs."+this.type);if(clearTimeout(e.timeout),e.hoverState="out",!e.options.delay||!e.options.delay.hide)return e.hide();e.timeout=setTimeout(function(){"out"==e.hoverState&&e.hide()},e.options.delay.hide)},i.prototype.show=function(){var t,e,n,i,o,r,a,s,l,u=c.Event("show.bs."+this.type);this.hasContent()&&this.enabled&&(this.$element.triggerHandler(u),u.isDefaultPrevented()||(t=this.tip(),this.setContent(),this.options.animation&&t.addClass("fade"),s="function"==typeof this.options.placement?this.options.placement.call(this,t[0],this.$element[0]):this.options.placement,(r=(o=/\s?auto?\s?/i).test(s))&&(s=s.replace(o,"")||"top"),t.detach().css({top:0,left:0,display:"block"}).addClass(s.split("-")[0]),this.options.container?t.appendTo(this.options.container):t.insertAfter(this.$element),e=this.getPosition(),n=t[0].offsetWidth,l=t[0].offsetHeight,r&&(a=this.$element.parent(),i=s,u=document.documentElement.scrollTop||document.body.scrollTop,o="body"==this.options.container?window.innerWidth:a.outerWidth(),r="body"==this.options.container?window.innerHeight:a.outerHeight(),a="body"==this.options.container?0:a.offset().left,s="bottom"==s&&e.top+e.height+l-u>r?"top":"top"==s&&e.top-u-l<0?"bottom":"right"==s&&e.right+n>o?"left":"left"==s&&e.left-n<a?"right":s,t.removeClass(i).addClass(s)),l=this.getCalculatedOffset(s,e,n,l),this.applyPlacement(l,s),this.$element.trigger("shown.bs."+this.type)))},i.prototype.applyPlacement=function(t,e){var n,i=this.tip(),o=i[0].offsetWidth,r=i[0].offsetHeight,a=parseInt(i.css("margin-top"),10),s=parseInt(i.css("margin-left"),10);isNaN(a)&&(a=0),isNaN(s)&&(s=0),t.top=t.top+a,t.left=t.left+s,i.offset(t).addClass("in");var l=i[0].offsetWidth,a=i[0].offsetHeight;"top"==e&&a!=r&&(n=!0,t.top=t.top+r-a),0===["top","bottom"].indexOf(e.split("-")[0])&&(t.left<(s=0)&&(s=-2*t.left,t.left=0,i.offset(t),l=i[0].offsetWidth,a=i[0].offsetHeight),this.replaceArrow(s-o+l,l,"left")),0===["left","right"].indexOf(e.split("-")[0])&&this.replaceArrow(a-r,a,"top"),n&&i.offset(t)},i.prototype.replaceArrow=function(t,e,n){this.arrow().css(n,t?50*(1-t/e)+"%":"")},i.prototype.setContent=function(){var t=this.tip(),e=this.getTitle();t.find(".tooltip-inner")[this.options.html?"html":"text"](e),t.removeClass("fade in top bottom left right")},i.prototype.hide=function(){function t(){"in"!=e.hoverState&&n.detach()}var e=this,n=this.tip(),i=c.Event("hide.bs."+this.type);if(this.$element.triggerHandler(i),!i.isDefaultPrevented())return n.removeClass("in"),c.support.transition&&this.$tip.hasClass("fade")?n.one(c.support.transition.end,t).emulateTransitionEnd(150):t(),this.$element.trigger("hidden.bs."+this.type),this},i.prototype.fixTitle=function(){var t=this.$element;!t.attr("title")&&"string"==typeof t.attr("data-original-title")||t.attr("data-original-title",t.attr("title")||"").attr("title","")},i.prototype.hasContent=function(){return this.getTitle()},i.prototype.getPosition=function(){var t=this.$element[0];return c.extend({},"function"==typeof t.getBoundingClientRect?t.getBoundingClientRect():{width:t.offsetWidth,height:t.offsetHeight},this.$element.offset())},i.prototype.getCalculatedOffset=function(t,e,n,i){return"left-top"==t?{top:e.top,left:e.left-n}:"left-bottom"==t?{top:e.top+e.height-i,left:e.left-n}:"right-top"==t?{top:e.top,left:e.left+e.width}:"right-bottom"==t?{top:e.top+e.height-i,left:e.left+e.width}:"top-left"==t?{top:e.top-i,left:e.left}:"top-right"==t?{top:e.top-i,left:e.left+e.width-n}:"bottom-left"==t?{top:e.top+e.height,left:e.left}:"bottom-right"==t?{top:e.top+e.height,left:e.left+e.width-n}:"bottom"==t?{top:e.top+e.height,left:e.left+e.width/2-n/2}:"top"==t?{top:e.top-i,left:e.left+e.width/2-n/2}:"left"==t?{top:e.top+e.height/2-i/2,left:e.left-n}:{top:e.top+e.height/2-i/2,left:e.left+e.width}},i.prototype.getTitle=function(){var t=this.$element,e=this.options;return t.attr("data-original-title")||("function"==typeof e.title?e.title.call(t[0]):e.title)},i.prototype.tip=function(){return this.$tip=this.$tip||c(this.options.template)},i.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},i.prototype.validate=function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},i.prototype.enable=function(){this.enabled=!0},i.prototype.disable=function(){this.enabled=!1},i.prototype.toggleEnabled=function(){this.enabled=!this.enabled},i.prototype.toggle=function(t){t=t?c(t.currentTarget)[this.type](this.getDelegateOptions()).data("bs."+this.type):this;t.tip().hasClass("in")?t.leave(t):t.enter(t)},i.prototype.destroy=function(){this.hide().$element.off("."+this.type).removeData("bs."+this.type)};var t=c.fn.tooltip;c.fn.tooltip=function(n){return this.each(function(){var t=c(this),e=t.data("bs.tooltip");e||t.data("bs.tooltip",e=new i(this,"object"==typeof n&&n)),"string"==typeof n&&e[n]()})},c.fn.tooltip.Constructor=i,c.fn.tooltip.noConflict=function(){return c.fn.tooltip=t,this}}(t),function(i){"use strict";function o(t,e){this.init("popover",t,e)}if(!i.fn.tooltip)throw new Error("Popover requires tooltip.js");o.DEFAULTS=i.extend({},i.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div id="kt" class="o-popover--kt"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),o.prototype=i.extend({},i.fn.tooltip.Constructor.prototype),(o.prototype.constructor=o).prototype.getDefaults=function(){return o.DEFAULTS},o.prototype.setContent=function(){var t=this.tip(),e=this.getTitle(),n=this.getContent();t.find(".popover-title")[this.options.html?"html":"text"](e),t.find(".popover-content")[this.options.html?"html":"text"](n),t.removeClass("fade top bottom left right in"),t.find(".popover-title").html()||t.find(".popover-title").hide()},o.prototype.hasContent=function(){return this.getTitle()||this.getContent()},o.prototype.getContent=function(){var t=this.$element,e=this.options;return t.attr("data-content")||("function"==typeof e.content?e.content.call(t[0]):e.content)},o.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")},o.prototype.tip=function(){return this.$tip||(this.$tip=i(this.options.template)),this.$tip};var t=i.fn.popover;i.fn.popover=function(n){return this.each(function(){var t=i(this),e=t.data("bs.popover");e||t.data("bs.popover",e=new o(this,"object"==typeof n&&n)),"string"==typeof n&&e[n]()})},i.fn.popover.Constructor=o,i.fn.popover.noConflict=function(){return i.fn.popover=t,this}}(t),function(a){"use strict";function o(t,e){this.$element=a(t),this.options=a.extend({},o.DEFAULTS,e),this.transitioning=null,this.options.parent&&(this.$parent=a(this.options.parent)),this.options.toggle&&this.toggle()}o.DEFAULTS={toggle:!0},o.prototype.dimension=function(){return this.$element.hasClass("width")?"width":"height"},o.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var t=a.Event("show.bs.collapse");if(this.$element.triggerHandler(t),!t.isDefaultPrevented()){t=this.$parent&&this.$parent.find("> .panel > .in");if(t&&t.length){var e=t.data("bs.collapse");if(e&&e.transitioning)return;t.collapse("hide"),e||t.data("bs.collapse",null)}var n=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[n](0),this.transitioning=1;e=function(){this.$element.removeClass("collapsing").addClass("in")[n]("auto"),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return e.call(this);t=a.camelCase(["scroll",n].join("-"));this.$element.one(a.support.transition.end,a.proxy(e,this)).emulateTransitionEnd(350)[n](this.$element[0][t])}}},o.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var t=a.Event("hide.bs.collapse");if(this.$element.triggerHandler(t),!t.isDefaultPrevented()){var e=this.dimension();this.$element[e](this.$element[e]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse").removeClass("in"),this.transitioning=1;t=function(){this.transitioning=0,this.$element.trigger("hidden.bs.collapse").removeClass("collapsing").addClass("collapse")};if(!a.support.transition)return t.call(this);this.$element[e](0).one(a.support.transition.end,a.proxy(t,this)).emulateTransitionEnd(350)}}},o.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()};var t=a.fn.collapse;a.fn.collapse=function(i){return this.each(function(){var t=a(this),e=t.data("bs.collapse"),n=a.extend({},o.DEFAULTS,t.data(),"object"==typeof i&&i);e||t.data("bs.collapse",e=new o(this,n)),"string"==typeof i&&e[i]()})},a.fn.collapse.Constructor=o,a.fn.collapse.noConflict=function(){return a.fn.collapse=t,this},a(document).on("click.bs.collapse.data-api","[data-bp-toggle=collapse]",function(t){var e=a(this),n=e.attr("data-target")||t.preventDefault()||(r=e.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,""),i=a(n),o=i.data("bs.collapse"),t=o?"toggle":e.data(),r=e.attr("data-parent"),n=r&&a(r);o&&o.transitioning||(n&&n.find('[data-bp-toggle=collapse][data-parent="'+r+'"]').not(e).addClass("collapsed"),e[i.hasClass("in")?"addClass":"removeClass"]("collapsed")),i.collapse(t)})}(t),function(a){"use strict";function i(t){this.element=a(t)}i.prototype.show=function(){var t,e,n=this.element,i=n.closest("ul:not(.dropdown-menu)"),o=(o=n.data("target"))||(o=n.attr("href"))&&o.replace(/.*(?=#[^\s]*$)/,"");n.parent("li").hasClass("active")||(t=i.find(".active:last a")[0],e=a.Event("show.bs.tab",{relatedTarget:t}),n.triggerHandler(e),e.isDefaultPrevented()||(o=a(o),this.activate(n.parent("li"),i),this.activate(o,o.parent(),function(){n.trigger({type:"shown.bs.tab",relatedTarget:t})})))},i.prototype.activate=function(t,e,n){function i(){o.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),t.addClass("active"),r?(t[0].offsetWidth,t.addClass("in")):t.removeClass("fade"),t.parent(".dropdown-menu")&&t.closest("li.dropdown").addClass("active"),n&&n()}var o=e.find("> .active"),r=n&&a.support.transition&&o.hasClass("fade");r?o.one(a.support.transition.end,i).emulateTransitionEnd(150):i(),o.removeClass("in")};var t=a.fn.tab;a.fn.tab=function(n){return this.each(function(){var t=a(this),e=t.data("bs.tab");e||t.data("bs.tab",e=new i(this)),"string"==typeof n&&e[n]()})},a.fn.tab.Constructor=i,a.fn.tab.noConflict=function(){return a.fn.tab=t,this},a(document).on("click.bs.tab.data-api",'[data-bs-toggle="tab"], [data-bs-toggle="pill"]',function(t){t.preventDefault(),a(this).tab("show")})}(t)}),KTVendors.plugin("utils",function(c){function e(t){this.items=t,this.start=0,this.end=t.length-1,this.node=null,this.stopped=!1}function n(){this.lastId=0}var o,r,i,a,s,l;function u(t){this.threads=[],this.threadCount=0,this.threadLimit=t.threadLimit||1,this.threadDelay=t.threadDelay||0}function d(t){return{r:(t=parseInt(-1<t.indexOf("#")?t.substring(1):t,16))>>16,g:(65280&t)>>8,b:255&t}}function f(t){var e={h:0,s:0,b:0},n=Math.min(t.r,t.g,t.b),i=Math.max(t.r,t.g,t.b),n=i-n;return e.b=i,e.s=0!=i?255*n/i:0,0!=e.s?(t.r==i?e.h=(t.g-t.b)/n:t.g==i?e.h=2+(t.b-t.r)/n:e.h=4+(t.r-t.g)/n,e.h*=60):e.h=360,e.h<0&&(e.h+=360),e.s*=100/255,e.b*=100/255,e}function h(t){var e={},n=t.h,i=255*t.s/100,o=255*t.b/100;return 0==i?e.r=e.g=e.b=o:(o=n%60*((t=o)-(i=(255-i)*o/255))/60,(n=360==n?0:n)<60?(e.r=t,e.b=i,e.g=i+o):n<120?(e.g=t,e.b=i,e.r=t-o):n<180?(e.g=t,e.r=i,e.b=i+o):n<240?(e.b=t,e.r=i,e.g=t-o):n<300?(e.b=t,e.g=i,e.r=i+o):n<360?(e.r=t,e.g=i,e.b=t-o):(e.r=0,e.g=0,e.b=0)),{r:Math.round(e.r),g:Math.round(e.g),b:Math.round(e.b)}}function p(t){var n=[t.r.toString(16),t.g.toString(16),t.b.toString(16)];return c.each(n,function(t,e){1==e.length&&(n[t]="0"+e)}),n.join("")}function m(t){return t.split(".")[0]}function g(t){this.fnList={},this.events={},this.mode=t}c.extend(e.prototype,{isLooping:function(){return!this.stopped&&(1<Math.abs(this.start-this.end)&&(this.node=Math.floor((this.start+this.end)/2),!0))},flip:function(t){t?this.end=this.node-1:this.start=this.node+1},stop:function(){this.stop=!0}}),c.Bloop=function(t){return new e(t)},c.Chunk=function(n,t){c.isArray(n)&&(n=[]);var t=c.extend({},{size:256,every:1e3},t),i=c.extend(c.Deferred(),{size:t.size,every:t.every,from:0,to:n.length,process:function(t){return i.process.fn=t,i},chunkStart:function(t){return i.chunkStart.fn=t,i},chunkEnd:function(t){return i.chunkEnd.fn=t,i},start:function(){return i.stopped=!1,i.iterate(),i},iterate:function(){if(!i.stopped){var t=i.process.fn;if(t){i.to=from.size+i.size;var e=n.length;i.to>e&&(i.to=e);e={from:i.from,to:i.to};for(i.chunkStart.fn&&i.chunkStart.fn.call(i,e.from,e.to);i.from<i.to&&!i.stopped;)t.call(i,n[i.from]),i.from++;return i.chunkEnd.fn&&i.chunkEnd.fn.call(i,e.from,e.to),i.completed=i.from>=n.length-1,i.completed?i.resolveWith(i):i.nextIteration=setTimeout(i.iterate,i.every),i}}},pause:function(){return i.stopped=!0,clearTimeout(i.nextIteration),i},restart:function(){return"rejected"===i.state()||(i.from=0,i.start()),i},stop:function(){return i.pause(),i.rejectWith(i,[i.from]),i}});return i},o=c.isFunction,n.prototype.queue=function(e){var n=this,i=c.uid();return n.lastId=i,function(){if(n.lastId===i){var t=arguments,t=o(e)?e.apply(this,t):t;return o(n.fn)?n.fn.apply(this,t):t}}},c.Enqueue=function(t){var e=new n;o(t)&&(e.fn=t);t=c.proxy(e.queue,e);return t.reset=function(){e.lastId=0},t},r={error:"error",warning:"warn",success:"log",info:"info"},c.Exception=function(t){var e=arguments,n=1==e.length,i=3==e.length;return t=c.isPlainObject(t)?t:{type:n?"error":e[0],message:n?e[0]:e[1]},i&&c.extend(t,e[2]),"development"==c.environment&&console[r[t.type]](t.message,t),t},c.IE=function(){var t=navigator.userAgent;if(t.match(/MSIE 9/))return 9;if(t.match(/MSIE 10/))return 10;if(t.match(/rv:11/i))return 11;for(var e=3,n=document.createElement("div"),i=n.getElementsByTagName("i");n.innerHTML="\x3c!--[if gt IE "+ ++e+"]><i></i><![endif]--\x3e",i[0];);return 4<e?e:void 0}(),c.Task=function(t){var e=c.extend(c.Deferred(),{data:{},list:[],add:function(t){t=c.extend(c.Deferred(),{name:t,item:void 0});return e.list.push(t),t},process:function(){return e._promise||(e._promise=c.when.apply(c,e.list).then(e.resolve,e.reject,e.progress)),e}},t);return e},c.extend(u.prototype,{add:function(t,e){c.isFunction(t)&&(t.type=e||"normal","deferred"==e&&(t.deferred=c.Deferred().always(c.proxy(this.next,this))),this.threads.push(t),this.run())},addDeferred:function(t){return this.add(t,"deferred")},next:function(){this.threadCount--,this.run()},run:function(){var e=this;setTimeout(function(){if(!(e.threads.length<1)&&e.threadCount<e.threadLimit){e.threadCount++;var t=e.threads.shift();try{t.call(t,t.deferred)}catch(t){console.error(t)}t.deferred||e.next()}},e.threadDelay)}}),c.Threads=function(t){return new u(t)},c.callback=function(t,e){if(c.isFunction(t)){var n=c.uid("cb");return window[n]=function(){return e||delete window[n],t.apply(null,arguments)},n}c.isString(t)&&"destroy"===t&&(n=e,delete window[n])},c.fn.checkList=function(n){function t(){var t,e;a||(t=o.filter(":checked"),e=o.not(":checked"),t.length<1&&r.removeAttr("checked"),t.length==o.length&&r.prop("checked",!0),n.change.call(i,t,e))}var n=c.extend({},{checkbox:".checkbox",masterCheckbox:".master-checkbox",check:function(){},uncheck:function(){},change:function(){}},n),i=this,o=i.find(n.checkbox),r=i.find(n.masterCheckbox),a=!1;return o.checked(function(){n.check.apply(i),t()},function(){n.uncheck.apply(i),t()}),r.checked(function(){a=!0,o.checked(!0),a=!1,t()},function(){a=!0,o.checked(!1),a=!1,t()}),t(),this},c.fn.switchClass=function(n,t){var t=t||"-",i=n.split(t)[0]+t,o=i.length;return this.each(function(){var t=c(this),e=c.map((t.attr("class")||"").split(" "),function(t){return t.slice(0,o)==i||""==t?null:t});e.push(n),t.attr("class",e.join(" "))})},c.fn.activateClass=function(t){return this.prevObject.removeClass(t),c(this).addClass(t)},c.extend(c,{hexToRgb:d,hexToHsb:function(t){return f(d(t))},rgbToHsb:f,hsbToRgb:h,rgbToHex:p,hsbToHex:function(t){return p(h(t))},fixHsb:function(t){return{h:Math.min(360,Math.max(0,t.h)),s:Math.min(100,Math.max(0,t.s)),b:Math.min(100,Math.max(0,t.b))}},fixRgb:function(t){return{r:Math.min(255,Math.max(0,t.r)),g:Math.min(255,Math.max(0,t.g)),b:Math.min(255,Math.max(0,t.b))}},fixHex:function(t){var e=6-t.length;if(3==e)for(var n,i=t.split(""),t="";n=i.shift();)t+=n+n;else for(;e--;)t="0"+t;return t.replace(/[^A-Fa-f0-9]/g,"0"),t}}),c.fn.htmlData=function(t,r){var a,r=void 0===r||r,s=new RegExp("^data-"+(t?t+"-":"")+"(.*)","i"),l={};return this.length<=0?{}:(c.each(this[0].attributes,function(t,e){if(e.specified&&(a=e.name.match(s))&&a[1])if(r){var n,i=a[1].split("-"),o=l;for(max=i.length-1,t=0;t<=max;t++)n=i[t],t==max?o[n]=e.value:(o[n]||(o[n]={}),o=o[n])}else l[a[1]]=e.value}),l)},c.fn.defineData=function(t,e){return void 0===this.data(t)&&this.data(t,e),this},c.deletes=function(n,t){c.each(t,function(t,e){delete n[e]})},c.fn.disabled=function(t){return void 0===t?this.is(":disabled")||this.hasClass("disabled"):this.prop("disabled",!!t).toggleClass("disabled",!!t)},c.fn.enabled=function(t){return void 0===t?!this.disabled():this.disabled(!t)},c.distinct=function(n){var t=c.unique;if(!(n.length<1)){if(n[0].nodeType)return t.apply(this,arguments);if("object"!=typeof n[0])return c.grep(n,function(t,e){return c.inArray(t,n)===e});var e=Math.random(),i=[];return c.each(n,function(t){n[t][e]||(i.push(n[t]),n[t][e]=!0)}),c.each(i,function(t){delete i[t][e]}),i}},c.fn.tagName=function(){return(this[0]||{}).tagName},c.create=function(t){return c(document.createElement(t))},c.fn.editable=function(t){return c.isUndefined(t)?"true"===this.prop("contenteditable"):(this.prop("contenteditable",t),!1===t&&this.removeAttr("contenteditable"),this)},c.download=function(t){return c("<iframe>").hide().appendTo("body").bind("load",function(){c(this).remove()}).attr("src",t)},c.ns=function(t,e){return t.split(" ").join(e+" ")+e},c.getPointerPosition=function(t){return t.type.match("touch")?{x:t.originalEvent.changedTouches[0].pageX,y:t.originalEvent.changedTouches[0].pageY}:{x:t.pageX,y:t.pageY}},i="___eventable",a=["on","off","fire"],c.extend(g.prototype,{createEvent:function(t){return this.events[t]=c.Callbacks(this.mode)},on:function(t,e){if(!t||!c.isFunction(e))return this;var n=this.fnList;(n[t]||(n[t]=[])).push(e);t=m(t);return(this.events[t]||this.createEvent(t)).add(e),this},off:function(t){if(!t)return this;var n=m(t),i=this.events[n];if(!i)return this;function o(t){c.each(t,function(t,e){i.remove(e)})}return n!==t?c.each(this.fnList,function(t,e){-1<t.indexOf(n)&&o(e)}):o(this.fnList[t]),this},fire:function(t){var e=this.events[t];if(e)return e.fire.apply(e,c.makeArray(arguments).slice(1)),this},destroy:function(){for(name in this.events)this.events[name].disable()}}),c.eventable=function(t,e){var n=t[i];return n&&"destroy"===e?(n.destroy(),c.deletes(t,a),delete t[i]):(n=t[i]=new g(e),t.on=c.proxy(n.on,n),t.off=c.proxy(n.off,n),t.fire=c.proxy(n.fire,n),t)},c.fn.checkList=function(n){function t(){var t,e;a||(t=o.filter(":checked"),e=o.not(":checked"),t.length<1&&r.removeAttr("checked"),t.length==o.length&&r.prop("checked",!0),n.change.call(i,t,e))}var n=c.extend({},{checkbox:".checkbox",masterCheckbox:".master-checkbox",check:function(){},uncheck:function(){},change:function(){}},n),i=this,o=i.find(n.checkbox),r=i.find(n.masterCheckbox),a=!1;return o.checked(function(){n.check.apply(i),t()},function(){n.uncheck.apply(i),t()}),r.checked(function(){a=!0,o.checked(!0),a=!1,t()},function(){a=!0,o.checked(!1),a=!1,t()}),t(),this},c.fn.checked=function(n,i){return arguments.length<1?this.is(":checked"):(this.each(function(t){var e=c(this);"boolean"!=typeof n?(e.is("input[type=checkbox]")||e.is("input[type=radio]"))&&e.off("change.checked").on("change.checked",function(){try{return(e.is(":checked")?n:i).apply(e)}catch(t){}}):e.attr("checked",n).trigger("change")}),this)},c.fn.locate=function(t){var n="data";return c.each(this[0].attributes,function(t,e){if(e.specified&&"$"===e.value)return n=e.name,!1}),this.find("["+n+"-"+t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()+"]")},s=["overflow","overflow-x","overflow-y"],c.fn.noscroll=function(t){return void 0===t&&(t=!0),this.each(function(){var n=c(this),i=n.data("noscroll");!i&&t&&(i={},c.each(s,function(t,e){i[e]=n.css(e)}),n.data("noscroll",i)),t?c.each(s,function(t,e){n.css(e,"hidden")}):i&&n.css(i)})},c.fn.visible=function(t){var e=c(this),n=c(window);if(!(e.length<1)){var i=n.scrollTop(),o=i+n.height(),n=e.offset().top,e=n+e.height();return(!0===t?n:e)<=o&&i<=(!0===t?e:n)}},c.fn.where=c.fn.filterBy=function(t,e,n){n=n||"=",e="[data-"+t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()+n+e+"]";return this.filter(e)},c.fn.checked=function(n,i){return arguments.length<1?this.is(":checked"):(this.each(function(t){var e=c(this);"boolean"!=typeof n?(e.is("input[type=checkbox]")||e.is("input[type=radio]"))&&e.off("change.checked").on("change.checked",function(){try{return(e.is(":checked")?n:i).apply(e)}catch(t){}}):e.attr("checked",n).trigger("change")}),this)},c.fn.selectAll=function(){return this.each(function(){this.select()})},c.fn.unselect=function(){return this.each(function(){var t=this.value;this.value+=" ",this.value=t})},c.fn.toObject=c.fn.serializeObject=function(){var n={};return c.each(c(this).serializeArray(),function(t,e){n.hasOwnProperty(e.name)?(c.isArray(n[e.name])||(n[e.name]=[n[e.name]]),n[e.name].push(e.value)):n[e.name]=e.value}),n},c.fn.toJSON=c.fn.serializeJSON=function(){return JSON.stringify(c(this).serializeObject())},c.sanitizeHTML=function(t){return c(c.parseHTML(t,document,!0)).toHTML()},c.toHTML=function(t){return c("<div>").html(t).html()},c.fn.toHTML=function(){return c.toHTML(this.clone())},c.toXHTML=function(t,e){var n=t.innerHTML?String(t.innerHTML):t,i=n.match(/(<.+[^>])/g);if(i)for(var o=0;o<i.length;o+=1){var r,a=i[o];if(i[o]=i[o].replace(/([<|<\/].+?\w+).+[^>]/,function(t){return t}),r=i[o].match(/\=[a-zA-Z\.\:\[\]_\(\)\&\$\%#\@\!0-9\/]+[?\s+|?>]/g))for(var s=0,l=r.length;s<l;)i[o]=i[o].replace(r[s],r[s].replace(/(\=)([a-zA-Z\.\:\[\]_\(\)\&\$\%#\@\!0-9\/]+)?([\s+|?>])/g,function(){var t=Array.prototype.slice.call(arguments);return'="'+(e?t[2]:t[2].toLowerCase())+'"'+t[3]})),s+=1;n=n.replace(a,i[o])}return n},c.fn.xhtml=function(){return c.IE?c.toXHTML(this[0]):this.html()},c.buildHTML=function(t,e){if(t instanceof c)return t;var n,i=document;window.CloudFlare&&((n=c.buildHTML.iframe)&&n.contentDocument||((n=c.buildHTML.iframe=document.createElement("iframe")).style.display="none",document.body.appendChild(n)),i=n.contentDocument);var t=c.trim(t),o=[],t=c.buildFragment([t],i,o),r=c.merge([],t.childNodes);if(!e&&0<o.length){var a=i.createElement("script");a.text="try{"+c.callback(function(){c(o).remove()})+"();}catch(e){}";for(var s,l,u=r.length-1;(s=r[u--])&&("SCRIPT"===s.nodeName?l=r.push(a):1===s.nodeType&&(l=s.appendChild(a)),!l););l||r.push(a),o.push(a)}return c(r)},c.intersects=function(t,e){return(e=c.isArray(e)?{top:e.y,left:e.x,bottom:e.y,right:e.x}:e).left<=t.right&&t.left<=e.right&&e.top<=t.bottom&&t.top<=e.bottom},c.fn.intersectsWith=function(t,e,n,i){var o=this.offset(),o={top:o.top,left:o.left,bottom:o.top+(sourceHeight=this.height()),right:o.left+(sourceWidth=this.width()),width:sourceWidth,height:sourceHeight},i={top:t,left:e,bottom:t+(i=i||0),right:e+(n=n||0),width:n,height:i};return!!c.intersects(o,i)&&{reference:o,subject:i}},c.isDeferred=function(t){return t&&c.isFunction(t.always)},c.isNumeric=function(t){return!isNaN(parseFloat(t))&&isFinite(t)},c.rotateNumber=function(t,e,n,i){return(t+=i=void 0===i?0:i)<e?t+=n+1:n<t&&(t-=n+1),t},c.regExpEscape=function(t){return t.replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")},c.remap=function(n,i,t){return c.each(t,function(t,e){n[e]=i[e]}),obj},(l=c.Ajax=function(t){t.autostart=!1;var e=c.ajax(t);return"function"==typeof e.send&&l.queue.addDeferred(function(t){e.send(),setTimeout(t.resolve,l.interval)}),e}).queue=c.Threads({threadLimit:1}),l.interval=1200,l.interval=0,function(){c.fn.addTransitoryClass=function(t,e){var n=this.addClass(t);return setTimeout(function(){n.removeClass(t)},e||1),this};function n(t,e,n){var i=this;return setTimeout(function(){i[t+"Class"](e)},n||50),this}c.fn.addClassAfter=function(t,e){return n.call(this,"add",t,e)},c.fn.removeClassAfter=function(t,e){return n.call(this,"remove",t,e)};function i(t,e,n,i){var o=t?"-in":"-out";return this.addTransitoryClass(e.replace(/ /g,o+" ")+o,n||1e3)[(t?"add":"remove")+"ClassAfter"](e),i&&setTimeout(i,n),this}c.fn.addTransitionClass=function(t,e,n){return i.call(this,!0,t,e,n)},c.fn.removeTransitionClass=function(t,e,n){return i.call(this,!1,t,e,n)}}(),c.trimSeparators=function(t,e,n){return t=t.replace(new RegExp("^["+e+"\\s]+|["+e+",\\s]+$","g"),"").replace(new RegExp(e+"["+e+"\\s]*"+e,"g"),e).replace(new RegExp("[\\s]+"+e,"g"),e).replace(new RegExp(e+"[\\s]+","g"),e),t=n?c.distinct(t.split(e)).join(e):t},c.uid=function(t,e){return(t||"")+Math.random().toString().replace(".","")+(e||"")}}),KTVendors.plugin("uri",function(t){t.isUrl=function(t){return/^(http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/|\/([\w#!:.?+=&%@!\-\/]))?/.test(t)};function p(t){"use strict";function s(t){return t=(t=decodeURIComponent(t)).replace("+"," ")}function a(t,e){for(var n,i,o,r=[],a=0;a<u.length;a++)n=u[a],i=s(n[0])===s(t),o=s(n[1])===s(e),(1!==arguments.length||i)&&(2!==arguments.length||i||o)||r.push(n);return u=r,this}function l(t,e,n){return 3===arguments.length&&-1!==n?(n=Math.min(n,u.length),u.splice(n,0,[t,e])):0<arguments.length&&u.push([t,e]),this}var u=function(t){var e,n,i,o,r,a=[];if(null==t||""===t)return a;for(n=(t=0===t.indexOf("?")?t.substring(1):t).toString().split(/[&;]/),e=0;e<n.length;e++)o=(r=(i=n[e]).split("="))[0],r=-1===i.indexOf("=")?null:null===r[1]?"":r[1],a.push([o,r]);return a}(t);return{getParamValue:function(t){for(var e,n=0;n<u.length;n++)if(e=u[n],s(t)===s(e[0]))return e[1]},getParamValues:function(t){for(var e,n=[],i=0;i<u.length;i++)e=u[i],s(t)===s(e[0])&&n.push(e[1]);return n},deleteParam:a,addParam:l,replaceParam:function(t,e,n){var i,o,r=-1;if(3===arguments.length){for(i=0;i<u.length;i++)if(o=u[i],s(o[0])===s(t)&&decodeURIComponent(o[1])===s(n)){r=i;break}a(t,n).addParam(t,e,r)}else{for(i=0;i<u.length;i++)if(o=u[i],s(o[0])===s(t)){r=i;break}a(t),l(t,e,r)}return this},toString:function(){for(var t,e="",n=0;n<u.length;n++)t=u[n],0<e.length&&(e+="&"),null===t[1]?e+=t[0]:e+=t.join("=");return 0<e.length?"?"+e:e}}}function m(n){"use strict";function i(t){return void 0!==t&&(f.protocol=t),f.protocol}function o(t){return null===(h=void 0!==t?t:h)?-1!==f.source.indexOf("//"):h}function r(t){return void 0!==t&&(f.userInfo=t),f.userInfo}function a(t){return void 0!==t&&(f.host=t),f.host}function s(t){return void 0!==t&&(f.port=t),f.port}function l(t){return void 0!==t&&(f.path=t),f.path}function u(t){return e=void 0!==t?new p(t):e}function c(t){return void 0!==t&&(f.anchor=t),f.anchor}function t(){function t(t){return null!==t&&""!==t}var e="";return t(i())?(e+=i(),i().indexOf(":")!==i().length-1&&(e+=":"),e+="//"):o()&&t(a())&&(e+="//"),t(r())&&t(a())&&(e+=r(),r().indexOf("@")!==r().length-1&&(e+="@")),t(a())&&(e+=a(),t(s())&&(e+=":"+s())),t(l())?e+=l():t(a())&&(t(u().toString())||t(c()))&&(e+="/"),t(u().toString())&&(0!==u().toString().indexOf("?")&&(e+="?"),e+=u().toString()),t(c())&&(0!==c().indexOf("#")&&(e+="#"),e+=c()),e}var d=/[-a-zA-Z0-9@:%_\+.~#?&//=]{2,256}\.[a-z]{2,4}\b(\/[-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)?/gi,f=function(t){for(var e=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],i="queryKey",n=/(?:^|&)([^&=]*)=?([^&]*)/g,o=/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/.exec(t),r={},a=14;a--;)r[e[a]]=o[a]||"";return r[i]={},r[e[12]].replace(n,function(t,e,n){e&&(r[i][e]=n)}),r}(n||""),e=new p(f.query),h=null;return{protocol:i,hasAuthorityPrefix:o,userInfo:r,host:a,port:s,path:l,query:u,anchor:c,setProtocol:function(t){return i(t),this},setHasAuthorityPrefix:function(t){return o(t),this},setUserInfo:function(t){return r(t),this},setHost:function(t){return a(t),this},setPort:function(t){return s(t),this},setPath:function(t){return l(t),this},setQuery:function(t){return u(t),this},setAnchor:function(t){return c(t),this},getQueryParamValue:function(t){return u().getParamValue(t)},getQueryParamValues:function(t){return u().getParamValues(t)},deleteQueryParam:function(t,e){return 2===arguments.length?u().deleteParam(t,e):u().deleteParam(t),this},addQueryParam:function(t,e,n){return 3===arguments.length?u().addParam(t,e,n):u().addParam(t,e),this},replaceQueryParam:function(t,e,n){return 3===arguments.length?u().replaceParam(t,e,n):u().replaceParam(t,e),this},extract:function(t){var e=n.match(d)||[];return void 0===t?e:e[t]||""},toPath:function(t){if(void 0===t)return f.path;if("/"==t.substring(0,1))return f.path=t;var e,n=f.path.split("/"),i=t.split("/");for(""===n.slice(-1)[0]&&n.pop();e=i.shift();)switch(e){case"..":1<n.length&&n.pop();break;case".":break;default:n.push(e)}return f.path=n.join("/"),this},toString:t,clone:function(){return new m(t())}}}t.uri=function(t){return new m(t)}}),KTVendors.plugin("mvc",function($){function hw(t,e,n){return void 0!==t[e]?t[e]:n&&(t[e]={})}function iw(t){var e=typeof t;return t&&("function"==e||"object"==e)}var jw,gw,kw,Xw,Yw,Zw,$w,kx,ox,Px,Qx,Rx,Sx,Tx,Ux,Wx,Yx;function Vx(t,e){return t.concat(Qx(e))}function Xx(t,o,e){for(var n in e=e||t,t)e[n]=Rx(t[n])&&Rx(o[n])&&Wx.test(t[n])?function(n,i){return function(){var t,e=this._super;return this._super=o[n],t=i.apply(this,arguments),this._super=e,t}}(n,t[n]):t[n]}gw={undHash:/_|-/,colons:/::/,words:/([A-Z]+)([A-Z][a-z])/g,lowUp:/([a-z\d])([A-Z])/g,dash:/([a-z\d])([A-Z])/g,replacer:/\{([^\}]+)\}/g,dot:/\./},kw=$.String=$.extend($.String||{},{getObject:jw=function(t,e,n){var i,o,r,a=t?t.split(gw.dot):[],s=a.length,l=0;if(e=$.isArray(e)?e:[e||window],0==s)return e[0];for(;i=e[l++];){for(r=0;r<s-1&&iw(i);r++)i=hw(i,a[r],n);if(iw(i)&&void 0!==(o=hw(i,a[r],n)))return!1===n&&delete i[a[r]],o}},capitalize:function(t,e){return t.charAt(0).toUpperCase()+t.substr(1)},camelize:function(t){return(t=kw.classize(t)).charAt(0).toLowerCase()+t.substr(1)},classize:function(t,e){for(var n=t.split(gw.undHash),i=0;i<n.length;i++)n[i]=kw.capitalize(n[i]);return n.join(e||"")},niceName:function(t){return kw.classize(t," ")},underscore:function(t){return t.replace(gw.colons,"/").replace(gw.words,"$1_$2").replace(gw.lowUp,"$1_$2").replace(gw.dash,"_").toLowerCase()},sub:function(t,n,i){var o=[];return o.push(t.replace(gw.replacer,function(t,e){t=jw(t,n,"boolean"==typeof i?!i:i)||jw(e,n,"boolean"==typeof i?!i:i),e=typeof t;return"object"!=e&&"function"!=e||null===e?""+t:(o.push(t),"")})),o.length<=1?o[0]:o},_regs:gw}),$.extend($,kw),$.String.rsplit=function(t,e){for(var n,i=e.exec(t),o=[];null!==i;)n=i.index,e.lastIndex,0!==n&&(o.push(t.substring(0,n)),t=t.slice(n)),o.push(i[0]),t=t.slice(i[0].length),i=e.exec(t);return""!==t&&o.push(t),o},Xw=/^\d+$/,Yw=/([^\[\]]+)|(\[\])/g,Zw=/\+/g,$w=/([^?#]*)(#.*)?$/,$.String=$.extend($.String||{},{deparam:function(t){if(!t||!$w.test(t))return{};for(var e={},n=t.split("&"),i=0;i<n.length;i++){var o=e,r=n[i].split("=");2!=r.length&&(r=[r[0],r.slice(1).join("=")]);for(var a=decodeURIComponent(r[0].replace(Zw," ")),r=decodeURIComponent(r[1].replace(Zw," ")),s=a.match(Yw),l=0;l<s.length-1;l++){var u=s[l];o[u]||(o[u]=Xw.test(s[l+1])||"[]"==s[l+1]?[]:{}),o=o[u]}lastPart=s[s.length-1],"[]"==lastPart?o.push(r):o[lastPart]=r}return e}}),kx=$.cleanData,$.cleanData=function(t){for(var e,n=0;void 0!==(e=t[n]);n++)$(e).triggerHandler("destroyed");kx(t)},ox=$.fn._closest=$.fn.closest,$.fn.closest=function(n,t){if(n instanceof $||$.isElement(n))return ox.call(this,arguments);var e,i,o,r,a={},s=!0,l="string"==typeof n?[n]:n;if($.each(l,function(t,e){if(0==e.indexOf(">")){if(-1!=e.indexOf(" "))throw" closest does not work with > followed by spaces!";a[l[t]=e.substr(1)]=e,"string"==typeof n&&(n=e.substr(1)),s=!1}}),e=ox.call(this,n,t),s)return e;for(o=0;o<e.length;)r=(i=e[o]).selector,void 0===a[r]||(i.selector=a[r],a[r]=!1,"string"==typeof i.selector&&i.elem.parentNode===t)?o++:e.splice(o,1);return e},$.cookie=function(t,e,n){if(void 0===e){var i=null;if(document.cookie&&""!=document.cookie)for(var o=document.cookie.split(";"),r=0;r<o.length;r++){var a=jQuery.trim(o[r]);if(a.substring(0,t.length+1)==t+"="){i=decodeURIComponent(a.substring(t.length+1));break}}if(jQuery.evalJSON&&i&&i.match(/^\s*\{/))try{i=jQuery.evalJSON(i)}catch(t){}return i}n=n||{},null===e&&(e="",n.expires=-1),"object"==typeof e&&jQuery.toJSON&&(e=jQuery.toJSON(e));var s="";n.expires&&("number"==typeof n.expires||n.expires.toUTCString)&&("number"==typeof n.expires?(u=new Date).setTime(u.getTime()+24*n.expires*60*60*1e3):u=n.expires,s="; expires="+u.toUTCString());var l=n.path?"; path="+n.path:"",u=n.domain?"; domain="+n.domain:"",n=n.secure?"; secure":"";document.cookie=[t,"=",encodeURIComponent(e),s,l,u,n].join("")},Px=!1,Qx=$.makeArray,Rx=$.isFunction,Sx=$.isArray,Tx=$.extend,Ux=$.String.getObject,Wx=/xyz/.test(function(){xyz})?/\b_super\b/:/.*/,Yx="prototype",clss=$.Class=function(){arguments.length&&clss.extend.apply(clss,arguments)},Tx(clss,{proxy:function(r){var a,s=Qx(arguments);return r=s.shift(),Sx(r)||(r=[r]),a=this,function(){for(var t,e,n=Vx(s,arguments),i=r.length,o=0;o<i;o++)(e=r[o])&&((t="string"==typeof e)&&a._set_called&&(a.called=e),n=(t?a[e]:e).apply(a,n||[]),o<i-1&&(n=!Sx(n)||n._use_call?[n]:n));return n}},newInstance:function(){var t,e=this.rawInstance();return e.setup&&(t=e.setup.apply(e,arguments)),e.init&&e.init.apply(e,Sx(t)?t:arguments),e},setup:function(t,e){return this.defaults=Tx(!0,{},t.defaults,this.defaults),arguments},rawInstance:function(){Px=!0;var t=new this;return Px=!1,t},extend:function(t,e,n){function i(){if(!Px)return this.constructor!==i&&arguments.length?arguments.callee.extend.apply(arguments.callee,arguments):this.Class.newInstance.apply(this.Class,arguments)}"string"!=typeof t&&(n=e,e=t,t=null),n||(n=e,e=null),n=n||{};var o,r,a,s=this[Yx];for(o in Px=!0,r=new this,Px=!1,Xx(n,s,r),this)this.hasOwnProperty(o)&&(i[o]=this[o]);Xx(e,this,i),t&&(e&&e.root&&(a=e.root,$.isString(a)&&(a=Ux(a,window,!0))),l=(s=t.split(/\./)).pop(),s=Ux(s.join("."),a||window,!0),Tx(!0,i,(a=s)[l]),s[l]=i),Tx(i,{prototype:r,namespace:a,shortName:l,constructor:i,fullName:t});var l=(i[Yx].Class=i[Yx].constructor=i).setup.apply(i,Vx([this],arguments));return i.init&&i.init.apply(i,l||Vx([this],arguments)),i}}),clss.callback=clss[Yx].callback=clss[Yx].proxy=clss.proxy,function(){function s(t,e,n,i,o){return i?function(t,e,n,i,o){0===e.indexOf(">")&&(e=(t.data("directSelector")+" "||"")+e);var r=t.delegate&&t.undelegate?t:$(k(t)?[t]:t);return o?r.delegate(e,n,o,i):r.delegate(e,n,i),function(){r.undelegate(e,n,i),r=t=n=i=e=null}}(t,i,e,n,o):(a=e,s=n,o=o,u=(r=t).bind&&r.unbind?r:$(k(r)?[r]:r),0===a.indexOf(">")&&(a=a.substr(1),l=function(t){t.target===r&&s.apply(this,arguments)}),o?u.bind(a,o,l||s):u.bind(a,l||s),function(){u.unbind(a,l||s),r=a=s=l=null});var r,a,s,l,u}function l(t,e){var n="string"==typeof e?t[e]:e;return _(n)&&k(n[1])&&(n=n[1]),function(){return t.called=e,n.apply(t,[this.nodeName?$(this):this].concat(i.call(arguments,0)))}}function b(t){return u.underscore(t.replace($.globalNamespace+".","").replace(n,"_").replace(o,""))}function w(t,e){return $.data(t,"controllers",e)}var x=$.makeArray,_=$.isArray,k=$.isFunction,C=$.isString,m=$.extend,u=$.String,g=$.each,e=u.getObject,T="prototype",v="constructor",i=Array[T].slice,n=/\./g,o=/_?controllers?/gi,r=/^\S(.*)\s(.*)/,c=/\{([^\}]+)\}/g,d=/\{([^\.]+[\.][^\.]+)\}/g,f=/^(?:(.*?)\s)?([\w\.\:>]+)$/,a=$.globalNamespace+".Controller";$.Controller=function(t){var e=x(arguments),n={root:a},e=2<e.length?(n=$.extend(n,e[1]),e[2]):e[1];return n.namespace&&(t=n.namespace+"."+t),$.Controller.Class(t,n,e)};var E=a+".Class";$.Class(E,{setup:function(t,e){if(this._super.apply(this,arguments),this.shortName&&this.fullName!=E){for(var n=this.elements||[],i=0,o=this.defaults;element=n[i++];){var r=element.indexOf("{"),a=element.indexOf("}"),s=(element.length,element.slice(0,r)),l=element.slice(a+1),u=element.slice(r+1,a).split("|"),c=0,a=s.match(/^\^(\S*)\s(.*)/),d="";for(a&&(d=a[1]+"-",s=a[2]);e=u[c++];){var f="{"+$.camelize(d+e)+"}";$.has(o,f)||(o[f]=s+e+l)}}this._fullName=b(this.fullName),this._shortName=b(this.shortName);var h,p,m=this;C(this.pluginName)&&(p=this._fullName,v=this.pluginName,$.fn[v]||($.fn[v]=function(n){var i=x(arguments);if($.isString(n)&&"controller"===n){var t=w(this[0]);return t&&t[p]}return this.each(function(){var t=w(this),e=t&&t[p];e?$.isString(n)?(t=e[n],$.isFunction(t)&&t.apply(e,i.slice(1))):e.update.apply(e,i):m.newInstance.apply(m,[this].concat(i))})}));var g,v=x(arguments),y=this[T],v=v[3<v.length?3:2];for(h in k(v)&&(this.protoFactory=v,y=this.protoFactory.call(this,null)),this.actions={},y)"constructor"!=h&&this._isAction(h)&&(g=y[h],(k(g)||_(g)&&k(g[1]))&&(this.actions[h]=this._action(h)));$.module("$:/Controllers/"+this.fullName).resolve(this)}},hookup:function(t){return new this(t)},_isAction:function(t){return!!r.test(t)||(-1<$.inArray(t,this.listensTo)||$.event.special[t]||h[t])},_action:function(t,n){if(c.lastIndex=0,!n&&c.test(t))return null;var i,o,e=t=t.replace("{self} ","");n&&(a=!1,d.test(t)&&(o="",e=t.replace(d,function(t,e){e=e.split(".");return i=n["{"+e[0]+"}"]||{},o=$.isControllerInstance(i)?(i[e[1]]||{}).selector:o}).match(f),a=!!o,e=[i.element].concat(e||[])),a||(e=u.sub(t,[n,window])));var r=_(e),a=(r?e[1]:e).match(f),t=a[2];return{processor:h[t]||p,parts:a,delegate:r?e[0]:void 0}},processors:{},listensTo:[],defaults:{},hostname:"parent"},{setup:function(t,e){var n,i=this,o=i[v],r=(i[T],o._fullName);i.instanceId=$.uid(r+"_");var a,s,l,u,c=i.options=m(!0,{},o.defaults,o.defaultOptions,e),d=i.element=$(t);for(a in o.protoFactory&&(n=o.protoFactory.apply(o,[i,c,d]),m(!0,i,n)),(w(t)||w(t,{}))[r]=i,d.data("directSelector")||(f=$.uid("DS"),d.addClass(f).data("directSelector","."+f)),i.selectors={},c)a.match(/^\{.+\}$/)&&(s=a.replace(/^\{|\}$/g,""),l=c[a],C(l)?(u=i[s],i[s]=i.selectors[s]=function(e,i,t){i=/^(\.|\#)$/.test(i)?i+t:i;function o(t){var n=(o.baseElement||e.element).find(i);return $.isString(t)&&(n=n.filter(t)),$.isPlainObject(t)&&$.each(t,function(t,e){n=n.filterBy(t,e)}),n}return o.selector=i,o.css=function(){var e,t,n=o.cssRule;return n||(e=d.data("directSelector"),t=$.map(i.split(","),function(t){return e+" "+t}),(n=o.cssRule=$.cssRule(t)).important=!0),arguments.length?n.css.apply(n,arguments):n},o.inside=function(t){return $(t).find(i)},o.of=function(t){return $(t).parents(i).eq(0)},o.under=function(t){var e=[];return o().each(function(){$(this).parents().filter(t).length&&e.push(this)}),$(e)},$.isPlainObject(u)&&$.extend(o,u),o}(i,l,s)):i[s]=l);var f=c.view,h=i.view;i.view=function(){return h.apply(this,arguments)},g(f||{},function(n,t){i.view[n]=function(t){var e=x(arguments);return $.isBoolean(t)?e=e.slice(1):t=!1,i.view.apply(i,[t,n].concat(e))}}),$.extend(i,c.controller),i.pluginInstances={},i.called="init",i._bind();var p=i.init||$.noop;return i.init=function(){return i.init=p,result=p.apply(i,arguments),i.trigger("init."+o.fullName.toLowerCase(),[i]),result},[d,c].concat(x(arguments).slice(2))},on:function(t){var e=x(arguments),n=this.element,i=e.length;return 2==i?this._binder(n,t,e[1]):3==i&&C(e[1])?this._binder(n,t,e[2],e[1]):this._binder(e[1],t,e[2])},_bind:function(){var i=this,o=i[v],r=o.actions,a=i._bindings=[],s=i.element;g(r||{},function(t,e){var n;r.hasOwnProperty(t)&&(n=o.actions[t]||o._action(t,i.options),$.isControllerInstance(n.delegate)&&(n.delegate=n.delegate.element),a.push(n.processor(n.delegate||s,n.parts[2],n.parts[1],t,i)))});var e=l(this,"destroy");return s.bind("destroyed",e),a.push(function(t){$(t).unbind("destroyed",e)}),a.length},_binder:function(t,e,n,i){return"string"==typeof n&&(n=l(this,n)),this._bindings.push(s(t,e,n,i)),this._bindings.length},_unbind:function(){var n=this.element[0];g(this._bindings,function(t,e){e(n)}),this._bindings=[]},trigger:function(t){var e=this.element;if(e){var n=$.Event(t);return e.trigger.apply(e,[n].concat($.makeArray(arguments).slice(1))),n}},delegate:function(t,e,n,i){return"string"==typeof t&&(i=n,n=e,e=t,t=this.element),this._binder(t,n,i,e)},update:function(t){m(this.options,t),this._unbind(),this._bind()},destroy:function(){if(!this._destroyed){var t=this[v]._fullName;for(pname in this.pluginInstances)this.removePlugin(pname);this._destroyed=!0,this.element.removeClass(t),this._unbind(),delete this._actions,delete this.element.data("controllers")[t],$(this).triggerHandler("destroyed"),this.element=$()}},find:function(t){return this.element.find(t)},view:function(){var t,e=x(arguments),n=e,i=!1,o=this[v].component||$,r=this.options.view||{};return"boolean"==typeof e[0]&&(i=e[0],n=e.slice(1)),null==(n[0]=r[n[0]])?i?"":$(""):(t=o.View.apply(o,n),i?t:$($.parseHTML($.trim(t))))},getPlugin:function(t){return this.pluginInstances[t]},addSubscriber:function(t){var t=$.isArray(t)?t:[t||{}],n=this,i=this.Class.hostname,o={};return o["{"+i+"}"]=n,$.map(t,function(t,e){return!!$.isControllerInstance(t)&&(t.options[i]===this?t:(t[i]=n,t.update(o)))}),t},addPlugin:function(t,e,n){if(t){(e||n)&&!$.isPlainObject(e)||(n=e,e=[this.Class.root,this.Class.fullName,$.String.capitalize(t)].join(".")),$.isString(e)&&(e=$.getController(e));var i=$.isControllerInstance(e);if(k(e)||i){var o=(this.Class.pluginExtendsInstance?this.options:this.options.plugin||{})[t];n=$.extend(!0,{element:this.element},n,o);o=i?"instance":$.isController(e)?"controller":"function";this.trigger("addPlugin",[t,e,n,o]);var r,a=this.Class.hostname;switch(n["{"+a+"}"]=this,o){case"instance":(r=e).update(n),e[a]=this;break;case"controller":r=n.element.addController(e,n);break;case"function":r=e(this,n)}if(r)return this.pluginInstances[t]=r,this.Class.pluginExtendsInstance&&(this[t]=r),"function"!=o&&((i={})["{"+t+"}"]=r,this.update(i)),this.trigger("registerPlugin",[t,r,n,o]),r}}},removePlugin:function(t){var e=this.getPlugin(t);if(e)return this.trigger("removePlugin",[t,e]),delete this.pluginInstances[t],$.isFunction(e.destroy)?e.destroy():null},invokePlugin:function(t,e,n){var i=this.getPlugin(t);if(i&&$.isFunction(i[e]))return this.trigger("invokePlugin",[t,i,n]),i[e].apply(this,n)},getMessageGroup:function(){var t=$.isFunction(this.messageGroup)?this.messageGroup():this.element.find("[data-message-group]");return t=t.length<1?$("<div data-message-group></div>").prependTo(this.element):t},setMessage:function(t,e){var n,i,o={type:"warning",message:"",parent:this.getMessageGroup(),element:$('<div class="o-alert o-alert--dismissible"><button type="button" class="o-alert__close" data-bs-dismiss="alert">×</button></div>')},r={},a=$.isDeferred(t),r=$.isPlainObject(t)&&!a?t:{message:t,type:e||"warning"},s=$.extend({},o,r),l=s.element;return $.isDeferred(t)?(n=arguments.callee,i=this,t.done(function(t,e){s.message=t,s.type=e||"warning",n.call(i,s),l.show()})):(l.addClass("o-alert--"+s.type).append(s.message),$("html").has(l).length<1&&l.appendTo(s.parent)),l},clearMessage:function(){this.getMessageGroup().empty()},_set_called:!0});var h=$.Controller.Class.processors,p=function(t,e,n,i,o){var r,a=o[i];return _(a)&&k(a[1])&&(r=a[0]),s(t,e,l(o,i),n,r)};g("change click contextmenu dblclick keydown keyup keypress mousedown mousemove mouseout mouseover mouseup reset resize scroll select submit focusin focusout mouseenter mouseleave".split(" "),function(t,e){h[e]=p});function y(t){return t.replace("$.Controller",a)}function S(t){if(C(t)&&(t=y(t),t=e(t)||e(a+"."+t)),D(t))return t}function D(t){return k(t)&&t.hasOwnProperty("_fullName")}function I(t){return $.map(t,function(t){return(_(t)?I:S)(t)})}$.getController=S,$.isController=function(t){return!!S(t)},$.isControllerInstance=function(t){return t&&t[v]&&D(t[v])},$.isControllerOf=function(t,e){if(!e)return!1;_(e)||(e=[e]);for(var n=0;n<e.length;n++)if(t instanceof S(e[n]))return!0;return!1},$.fn.extend({controllers:function(){var i=I(x(arguments)),o=[];return this.each(function(){var n=$.data(this,"controllers");g(n||{},function(t,e){n.hasOwnProperty(t)&&(i.length&&!$.isControllerOf(e,i)||o.push(e))})}),o},controller:function(t,e){return void 0===e?this.controllers(t)[0]:(this.addController.apply(this,arguments),this)},hasController:function(t){t=(S(t)||{})._fullName||(C(t)?b(y(t)):"");return!!t&&($(this).data("controllers")||{}).hasOwnProperty(t)},addController:function(e,n,i){var o=S(e);if(o){var r=[];return this.each(function(){var t;1===this.nodeType&&"SCRIPT"!=this.nodeName&&((t=$(this).controller(e))?r.push(t):(t=new o(this,n),k(i)&&i.apply(t,[$(this),t]),r.push(t)))}),1<r.length?r:r[0]}},removeController:function(e){return this.each(function(){for(var t=$(this).controllers(e);t.length;)t.shift().destroy()}),this},addControllerWhenAvailable:function(t){var e=this,n=arguments,i=$.Deferred();return $.isController(t)&&(t=t.fullName),C(t)?($.module("$:/Controllers/"+t).pipe(function(){var t=e.addController.apply(e,n);i.resolveWith(t,[e,t])},i.reject,i.fail),i):i.reject()},implement:function(){return this.addController.apply(this,arguments),this}}),function(){for(var t,e=["is","find"],n={};t=e.shift();)n[t]=$.fn[t],$.fn[t]=function(e){return function(t){return n[e].apply(this,(t||{}).hasOwnProperty("of")?[t.selector]:arguments)}}(t)}()}(),function(){function d(t){return t.replace(/^\/\//,"").replace(/[\/\.]/g,"_")}function f(t,e){if(!t.match(/[^\s]/))throw"$.View ERROR: There is no template or an empty template at "+e}var l=$.makeArray,n=1,h=$.View=function(t,o,r,a){"function"==typeof r&&(a=r,r=void 0);var e=c(o);if(e.length){var s=$.Deferred();return e.push(i(t,!0)),$.when.apply($,e).then(function(t){var e=l(arguments),n=e.pop()[0];if(u(o))o=p(t);else for(var i in o)u(o[i])&&(o[i]=p(e.shift()));n=n(o,r),s.resolve(n),a&&a(n)}),s.promise()}var n,e="function"==typeof a,s=i(t,e);return e?(n=s).done(function(t){a(t(o,r))}):s.done(function(t){n=t(o,r)}),n},i=function(t,e){return $.ajax({url:t,dataType:"view",async:e})},u=function(t){return t&&$.isFunction(t.always)},c=function(t){var e,n=[];if(u(t))return[t];for(e in t)u(t[e])&&n.push(t[e]);return n},p=function(t){return $.isArray(t)&&3===t.length&&"success"===t[1]?t[0]:t};$.ajaxTransport("view",function(t,n){function i(t){return t=u.renderer(r,t),h.cache&&(h.cached[r]=t),{view:t}}var o,r,a,e,s=n.url,l=s.match(/\.[\w\d]+$/);(l=(o=document.getElementById(s))?"."+o.type.match(/\/(x\-)?(.+)/)[2]:l)||(l=h.ext,s+=h.ext),r=d(s),s.match(/^\/\//)&&(e=s.substr(2),s="undefined"==typeof steal?"/"+e:steal.root.mapJoin(e)+"");var u=h.types[l],c=$.template()[n.url];return{send:function(t,e){return c?(u=h.types["."+c.type],e(200,"success",i(c.content))):h.cached[r]?e(200,"success",{view:h.cached[r]}):void(o?e(200,"success",i(o.innerHTML)):a=$.ajax({async:n.async,url:s,dataType:"text",error:function(){f("",s),e(404)},success:function(t){f(t,s),e(200,"success",i(t))}}))},abort:function(){a&&a.abort()}}}),$.extend(h,{hookups:{},hookup:function(t){var e=++n;return h.hookups[e]=t,e},cached:{},cache:!0,register:function(t){this.types["."+t.suffix]=t,window.steal&&steal.type(t.suffix+" view js",function(t,e,n){var i=h.types["."+t.type],o=d(t.rootSrc+"");t.text=i.script(o,t.text),e()})},types:{},ext:".ejs",registerScript:function(t,e,n){return"$.View.preload('"+e+"',"+h.types["."+t].script(e,n)+");"},preload:function(t,n){h.cached[t]=function(t,e){return n.call(t,t,e)}}}),window.steal&&steal.type("view js",function(t,e,n){var i=h.types["."+t.type],o=d(t.rootSrc+"");t.text="steal('"+(i.plugin||"jquery/view/"+t.type)+"').then(function($){$.View.preload('"+o+"',"+t.text+");\n})",e()});var a={val:!0,text:!0},o=function(o){var r=$.fn[o];$.fn[o]=function(){var e,t,n=l(arguments),i=this;if(u(n[0]))return n[0].done(function(t){s.call(i,[t],r)}),this;if(m(n)){if(t=v(n))return e=n[t],n[t]=function(t){s.call(i,[t],r),e.call(i,t)},h.apply(h,n),this;if(t=h.apply(h,n),u(t))return t.done(function(t){s.call(i,[t],r)}),this;n=[t]}return a[o]?r.apply(this,n):s.call(this,n,r)}},s=function(t,e){var n,i;for(i in h.hookups)break;return i&&t[0]&&g(t[0])&&(n=h.hookups,h.hookups={},t[0]=$(t[0])),e=e.apply(this,t),n&&y(t[0],n),e},m=function(t){var e=typeof t[1];return"string"==typeof t[0]&&("object"==e||"function"==e)&&!r(t[1])},r=function(t){return t.nodeType||t.jquery},g=function(t){return!!r(t)||"string"==typeof t&&("<"===(t=$.trim(t)).substr(0,1)&&">"===t.substr(t.length-1,1)&&3<=t.length)},v=function(t){return"function"==typeof t[3]?3:"function"==typeof t[2]&&2},y=function(t,e){for(var n,i,o,r=0,a=(n=(t=t.filter(function(){return 3!=this.nodeType})).add("[data-view-id]",t)).length;r<a;r++)n[r].getAttribute&&(i=n[r].getAttribute("data-view-id"))&&(o=e[i])&&(o(n[r],i),delete e[i],n[r].removeAttribute("data-view-id"));$.extend(h.hookups,e)};$.fn.hookup=function(){var t=h.hookups;return h.hookups={},y(this,t),this},$.each(["prepend","append","after","before","text","html","replaceWith","val"],function(t,e){o(e)})}(),function(){var myEval=function(script){eval(script)},rSplit=$.String.rsplit,extend=$.extend,isArray=$.isArray,returnReg=/\r\n/g,retReg=/\r/g,newReg=/\n/g,nReg=/\n/,slashReg=/\\/g,quoteReg=/"/g,singleQuoteReg=/'/g,tabReg=/\t/g,leftBracket=/\{/g,rightBracket=/\}/g,quickFunc=/\s*\(([\$\w]+)\)\s*->([^\n]*)/,clean=function(t){return t.replace(slashReg,"\\\\").replace(newReg,"\\n").replace(quoteReg,'\\"').replace(tabReg,"\\t")},escapeHTML=function(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(quoteReg,""").replace(singleQuoteReg,"'")},$View=$.View,bracketNum=function(t){var e=t.match(leftBracket),t=t.match(rightBracket);return(e?e.length:0)-(t?t.length:0)},EJS=function(t){if(this.constructor!=EJS){var n=new EJS(t);return function(t,e){return n.render(t,e)}}"function"!=typeof t?(extend(this,EJS.options,t),this.template=compile(this.text,this.type,this.name)):this.template={fn:t}};$&&($.EJS=EJS),EJS.prototype.render=function(t,e){t=t||{},this._extra_helpers=e;e=new EJS.Helpers(t,e||{});return this.template.fn.call(t,t,e)},extend(EJS,{text:function(i){if("string"==typeof i)return i;if(null==i)return"";var t=(i.hookup?function(t,e){i.hookup.call(i,t,e)}:"function"==typeof i&&i)||isArray(i)&&function(t,e){for(var n=0;n<i.length;n++)i[n].hookup?i[n].hookup(t,e):i[n](t,e)};return t?"data-view-id='"+$View.hookup(t)+"'":i.toString?i.toString():""},clean:function(t){return"string"==typeof t?escapeHTML(t):"number"==typeof t?t:EJS.text(t)},options:{type:"[",ext:".ejs"}});var scan=function(t,e,n){for(var i=rSplit(e,nReg),o=0;o<i.length;o++)scanline(t,i[o],n)},scanline=function(t,e,n){t.lines++;for(var i,o=rSplit(e,t.splitter),r=0;r<o.length;r++)null!==(i=o[r])&&n(i,t)},makeScanner=function(t,e){var n={};return extend(n,{left:t+"%",right:"%"+e,dLeft:t+"%%",dRight:"%%"+e,eeLeft:t+"%==",eLeft:t+"%=",cmnt:t+"%#",cleanLeft:t+"%~",scan:scan,lines:0}),n.splitter=new RegExp("("+[n.dLeft,n.dRight,n.eeLeft,n.eLeft,n.cmnt,n.left,n.right+"\n",n.right,"\n"].join(")|(").replace(/\[/g,"\\[").replace(/\]/g,"\\]")+")"),n},compile=function(t,e,n){t=t.replace(returnReg,"\n").replace(retReg,"\n"),e=e||"[";function o(t){u.push(i,'"',clean(t),'");')}function r(){c=""}var i="___v1ew.push(",a=i,s="var ___v1ew = [];",l="return ___v1ew.join('')",u=new EJS.Buffer([s],[]),c="",d=null,f="));",h=[];scan(makeScanner(e,"["===e?"]":">"),t||"",function(t,e){if(null===d)switch(t){case"\n":o(c+="\n"),u.cr(),r();break;case e.left:case e.eLeft:case e.eeLeft:case e.cmnt:d=t,0<c.length&&o(c),r();break;case e.dLeft:c+=e.left;break;default:c+=t}else switch(t){case e.right:switch(d){case e.left:var n=bracketNum(c),i=h.length&&-1==n?h.pop():";";i===f&&u.push(l),u.push(c,i),1===n&&h.push(";");break;case e.eLeft:(n=bracketNum(c))&&h.push(f),quickFunc.test(c)&&(c="function(__){var "+(i=c.match(quickFunc))[1]+"=$(__);"+i[2]+"}"),u.push(a,$.globalNamespace+".EJS.clean(",c,n?s:f);break;case e.eeLeft:(n=bracketNum(c))&&h.push(f),u.push(a,$.globalNamespace+".EJS.text(",c,n?s:f)}d=null,r();break;case e.dRight:c+=e.right;break;default:c+=t}}),0<c.length&&u.push(i,'"',clean(c)+'");');t={out:"try { with(_VIEW) { with (_CONTEXT) {"+u.close()+" "+l+"}}}catch(e){e.lineNumber=null;throw e;}"};return myEval.call(t,"this.fn = (function(_CONTEXT,_VIEW){ var $ = "+$.globalNamespace+";"+t.out+"});"),t};EJS.Buffer=function(t,e){this.line=[],this.script=[],this.post=e,this.push.apply(this,t)},EJS.Buffer.prototype={push:function(){this.line.push.apply(this.line,arguments)},cr:function(){this.script.push(this.line.join(""),"\n"),this.line=[]},close:function(){return 0<this.line.length&&(this.script.push(this.line.join("")),this.line=[]),this.post.length&&this.push.apply(this,this.post),this.script.push(";"),this.script.join("")}},EJS.Helpers=function(t,e){this._data=t,this._extras=e,extend(this,e)},EJS.Helpers.prototype={plugin:function(t){var e=$.makeArray(arguments),n=e.shift();return function(t){t=$(t);t[n].apply(t,e)}},view:function(t,e,n){return n=n||this._extras,e=e||this._data,$View(t,e,n)}},$View.register({suffix:"ejs",script:function(t,e){return $.globalNamespace+".EJS(function(_CONTEXT,_VIEW) { "+new EJS({text:e,name:t}).template.out+" })"},renderer:function(t,e){return EJS({text:e,name:t})}})}(),function(){function s(t){return"object"==typeof t&&null!==t&&t}function l(i,o,r){return i instanceof $.Observe?a([i],r._namespace):i=new(h(i)?$.Observe.List:$.Observe)(i),i.bind("change"+r._namespace,function(t,e){var n=$.makeArray(arguments),t=n.shift();n[0]="*"===o?r.indexOf(i)+"."+n[0]:o+"."+n[0],$.event.trigger(t,n,r)}),i}function a(t,e){for(var n,i=0;i<t.length;i++)(n=t[i])&&n.unbind&&n.unbind("change"+e)}function u(){if(!o)return o=[],!0}function c(t,e,n){return!t._init&&(o?void o.push({t:t,ev:e,args:n}):$.event.trigger(e,n,t,!0))}function d(){var t,e=o.length,n=o.slice(0);o=null,r++;for(var i=0;i<e;i++)t=n[i],$.event.trigger({type:t.ev,batchNum:r},t.args,t.t)}function f(t,n,i){return t.each(function(t,e){i[t]=s(e)&&"function"==typeof e[n]?e[n]():e}),i}var h=$.isArray,p=$.makeArray,t=$.each,n=0,o=null,r=0;$.Class($.globalNamespace+".Observe",{init:function(t){this._data={},this._namespace=".observe"+ ++n,this._init=!0,this.attrs(t),delete this._init},attr:function(t,e){return void 0===e?this._get(t):(this._set(t,e),this)},each:function(){return t.apply(null,[this.__get()].concat(p(arguments)))},removeAttr:function(t){var e=h(t)?t:t.split("."),n=e.shift(),t=this._data[n];return e.length?t.removeAttr(e):(delete this._data[n],c(this,"change",[n,"remove",void 0,t]),t)},_get:function(t){var e=h(t)?t:(""+t).split("."),t=this.__get(e.shift());return e.length?t?t._get(e):void 0:t},__get:function(t){return t?this._data[t]:this._data},_set:function(t,e){var n=h(t)?t:(""+t).split("."),i=n.shift(),t=this.__get(i);if(s(t)&&n.length)t._set(n,e);else{if(n.length)throw"jQuery.Observe: set a property on an object that does not exist";e!==t&&(n=this.__get().hasOwnProperty(i)?"set":"add",this.__set(i,s(e)?l(e,i,this):e),c(this,"change",[i,n,e,t]),t&&a([t],this._namespace))}},__set:function(t,e){this._data[t]=e,t in this.constructor.prototype||(this[t]=e)},bind:function(t,e){return $.fn.bind.apply($([this]),arguments),this},unbind:function(t,e){return $.fn.unbind.apply($([this]),arguments),this},serialize:function(){return f(this,"serialize",{})},attrs:function(t,e){if(void 0===t)return f(this,"attrs",{});t=$.extend(!0,{},t);var n,i=u();for(n in this._data){var o=this._data[n],r=t[n];void 0!==r?(s(o)&&s(r)?o.attrs(r,e):o!=r&&this._set(n,r),delete t[n]):e&&this.removeAttr(n)}for(n in t)r=t[n],this._set(n,r);i&&d()}});function m(t){return t[0]&&$.isArray(t[0])?t[0]:p(t)}var e=$.Observe($.globalNamespace+".Observe.List",{init:function(t,e){this.length=0,this._namespace=".list"+ ++n,this._init=!0,this.bind("change",this.proxy("_changes")),this.push.apply(this,p(t||[])),$.extend(this,e),this.comparator&&this.sort(),delete this._init},_changes:function(t,e,n,i,o){if(this.comparator&&/^\d+./.test(e)){var r=+/^\d+/.exec(e)[0],a=this[r],s=this.sortedIndex(a);if(s!==r)return[].splice.call(this,r,1),[].splice.call(this,s,0,a),c(this,"move",[a,s,r]),t.stopImmediatePropagation(),void c(this,"change",[e.replace(/^\d+/,s),n,i,o])}-1===e.indexOf(".")&&("add"===n?c(this,n,[i,+e]):"remove"===n&&c(this,n,[o,+e]))},sortedIndex:function(t){for(var e=t.attr(this.comparator),n=0,i=0;i<this.length;i++)if(t!==this[i]){if(e<=this[i].attr(this.comparator))return i+n}else n=-1;return i+n},__get:function(t){return t?this[t]:this},__set:function(t,e){this[t]=e},serialize:function(){return f(this,"serialize",[])},splice:function(t,e){for(var n=p(arguments),i=2;i<n.length;i++){var o=n[i];s(o)&&(n[i]=l(o,"*",this))}void 0===e&&(e=n[1]=this.length-t);var r=[].splice.apply(this,n);return 0<e&&(c(this,"change",[""+t,"remove",void 0,r]),a(r,this._namespace)),2<n.length&&c(this,"change",[""+t,"add",n.slice(2),r]),r},attrs:function(t,e){if(void 0===t)return f(this,"attrs",[]);t=t.slice(0);for(var n=Math.min(t.length,this.length),i=u(),o=0;o<n;o++){var r=this[o],a=t[o];s(r)&&s(a)?r.attrs(a,e):r!=a&&this._set(o,a)}t.length>this.length?this.push(t.slice(this.length)):t.length<this.length&&e&&this.splice(t.length),i&&d()},sort:function(t,e){var n=this.comparator;[].sort.apply(this,n?[function(t,e){return(t=t[n])===(e=e[n])?0:t<e?-1:1}]:[]);e||c(this,"reset")}});t({push:"length",unshift:0},function(r,a){e.prototype[r]=function(){for(var t=m(arguments),e=a?this.length:0,n=0;n<t.length;n++){var i=t[n];s(i)&&(t[n]=l(i,"*",this))}if(1==t.length&&this.comparator){var o=this.sortedIndex(t[0]);return this.splice(o,0,t[0]),this.length}o=[][r].apply(this,t);return this.comparator&&1<t.length?(this.sort(null,!0),c(this,"reset",[t])):c(this,"change",[""+e,"add",t,void 0]),o}}),t({pop:"length",shift:0},function(n,i){e.prototype[n]=function(){var t=m(arguments),e=i&&this.length?this.length-1:0,t=[][n].apply(this,t);return c(this,"change",[""+e,"remove",void 0,[t]]),t&&t.unbind&&t.unbind("change"+this._namespace),t}}),e.prototype.indexOf=[].indexOf||function(t){return $.inArray(t,this)},$.O=function(t,e){return new(h(t)||t instanceof $.Observe.List?$.Observe.List:$.Observe)(t,e)}}()}),KTVendors.plugin("joomla",function(n){var i={squeezebox:function(){return window.parent.SqueezeBox}};n.Joomla=function(t,e){if(n.isFunction(e))window.Joomla[t]=e;else{t=i[t]||window.Joomla[t];if(n.isFunction(t))return t.apply(window,e)}}}),KTVendors.plugin("module",function(o){function e(t){var e=this,n=o.Callbacks("once memory");o.extend(this,o.Deferred(),{name:t,status:"pending",ready:function(t){!0===t&&n.fire.call(e,o),o.isFunction(t)&&n.add(t)}}),e.then(function(){e.exports=this,e.status="resolved"},function(){e.status="rejected"});var i=e.done;e.done=function(){e.required=!0;var t=e.factory;return t&&"ready"===e.status&&t.call(e,o),e.done=i,e.done.apply(this,arguments)}}function i(t,e){var n;if("string"==typeof t){if(n=i.get(t),void 0===e)return n;if(o.isFunction(e))return"resolved"==n.status||(n.factory=e,n.status="ready",n.ready("true"),n.required&&(n.status="executing",e.call(n,o))),n}o.isArray(t)&&(t=o.map(t,function(t){var e=i.get(o.isString(t)?t:t.name);if(e)return"pending"===e.status&&(e.status="ready"),o.isPlainObject(t)?t:void 0}),o.each(t,function(t,e){i(e.name,e.factory)}))}o.module=(o.extend(i,{registry:{},get:function(t){if(t)return o.isModule(t)&&(t=t.replace("module://","")),i.registry[t]||i.create(t)},create:function(t){return i.registry[t]=new e(t)},remove:function(t){delete i.registry[t]}}),i),o.isModule=function(t){return o.isString(t)?!!t.match("module://"):t&&t instanceof e}}),KTVendors.plugin("script",function(i){i.Script=function(t){var e=document.createElement("script");return e.text=i.isString(t)?t:i.callback(t)+"();",i(e)},i.script=function(){function e(t){(t=i.extend(this,t)).manager=i.Deferred(),i.extend(t,t.manager.promise()),t.load()}var n=document.getElementsByTagName("head")[0];document.getElementsByTagName("base")[0];return i.extend(e.prototype,{timeout:7e3,retry:3,retryCount:1,type:"text/javascript",async:!1,charset:"UTF-8",verbose:!1,head:n,insert:function(){var t=this.node;this.head.appendChild(t)},remove:function(){var t=this.node;setTimeout(function(){t.onload=t.onerror=t.onreadystatechange=null;try{n.removeChild(t)}catch(t){}},1e3)},load:function(){var t,e=this;e.endTime=void 0,e.startTime=new Date,e.node=t=document.createElement("script"),e.insert(),e._ready=i.proxy(e.ready,e),e._error=i.proxy(e.error,e),t.attachEvent&&!i.browser.opera?(t.attachEvent("onreadystatechange",e._ready),t.attachEvent("onerror",e._error)):(t.addEventListener("load",e._ready,!1),t.addEventListener("error",e._error,!1)),i(t).attr({type:e.type,async:e.async,charset:e.charset,src:e.url}),e.monitor()},monitor:function(){var t=this;t.retryCount>t.retry?t._error():setTimeout(function(){"resolved"!==t.state()&&(t.verbose&&console.warn("$.script: Load timeout. [Retry: "+t.retryCount+"]",t),t.remove(),t.retryCount++,t.load())},t.timeout*t.retryCount)},ready:function(t){var e=this,n=e.node;"load"!==t.type&&!/loaded|complete/.test(n.readyState)||(e.complete.call(e,t),e.manager.resolve(e))},error:function(t){var e=this;e.verbose&&console.error("$.script: Unable to load ",e),e.complete.call(e,t),e.remove(),e.manager.reject(e)},complete:function(t){var e=this,n=e.node;e.endTime=new Date,n.detachEvent&&!i.browser.opera?(n.detachEvent("onreadystatechange",e._ready),n.detachEvent("onerror",e._error)):(n.removeEventListener("load",e._ready,!1),n.removeEventListener("error",e._error,!1))}}),function(t){if(void 0!==t)return new e(t="string"==typeof t?{url:t}:t)}}()}),KTVendors.plugin("template",function(i){function o(t,e){return void 0===t?o.templates:"string"==typeof e?(n=i.isPlainObject(e)?e:i.extend({},r,{name:t,content:e}),o.templates[t]=n):(n=o.templates[t]||{}).content||"";var n}var r;i.template=(r={content:"",type:"ejs"},i.extend(o,{templates:{},remove:function(t){delete o.templates[t]}}),o)}),KTVendors.plugin("require",function(a){function r(){var i=this,t=a.makeArray(arguments),t=a.isPlainObject(t[0])?(o=t[0],t.slice(1)):t,o=a.extend({},r.defaultOptions,i.options,o,{batch:i});a.each(t,function(t,e){var n=new r.task(e,o),e=r.images[n.url],n=e||n;i.addTask(n),e||(r.images[n.url]=n).start()})}a.require=function(){function i(t){return t=new n(t),i.batches[t.id]=t}var t=function(t){return a.uri(t).setAnchor("").setQuery("").toPath("../").toString()};a.extend(i,{defaultOptions:{path:(t=a.path||a("[require-path]").attr("require-path")||t(a("script:last").attr("src"))||t(window.location.href),t=/^(\/|\.)/.test(t)?a.uri(window.location.href).toPath(t).toString():t),timeout:1e4,retry:3,verbose:"development"==a.environment},setup:function(t){a.extend(i.defaultOptions,t)},batches:{},status:function(r){return a.each(i.batches,function(t,e){var n={pending:0,resolved:0,rejected:0,ready:0,total:0},i=[];a.each(e.tasks,function(t,e){state=e.module&&"ready"==e.module.status?"ready":e.state(),n[state]++,n.total++,i.push({state:state,content:"["+state+"] "+e.name})});var o=e.id+": "+e.state()+" ["+n.resolved+"/"+n.total+"]";r&&n[r]<1||(a.IE?(console.log('$.require.batches["'+e.id+'"]'),a.each(i,function(t,e){console.log(e.content)}),console.log("")):(console.groupCollapsed(o),console.log('$.require.batches["'+e.id+'"]',e),a.each(i,function(t,e){var n=e.state,i=e.content;if(!r||n==r)switch(n){case"pending":console.warn(i);break;case"rejected":console.error(i);break;default:console.info(i)}}),console.groupEnd(o)))}),"$.require.status(pending|resolved|rejected|ready);"},loaders:{},addLoader:function(t,e){i[t]=e,n.prototype[t]=function(){return this.autoFinalize(),e.apply(this,arguments),this},i.loaders[t]=i[t]=e},removeLoader:function(t){delete n.prototype[t],delete i[t]}});var o=0,n=function(t){var e=a.Callbacks("once memory"),n=!1;return a.extend(this,{id:++o,tasks:[],options:a.extend({},i.defaultOptions,t),autoFinalizeDuration:300,finalized:!1,required:function(t){return!0===t&&(n=e.fire()),a.isFunction(t)&&e.add(t),n}})};return a.extend(n.prototype,{addTask:function(t){a.isDeferred(t)&&(this.finalized||(this.tasks.push(t),t.batch=this))},autoFinalize:function(){var t=this,e=t.autoFinalizeDuration;!1!==e&&(clearTimeout(t.autoFinalizeTimer),t.autoFinalizeTimer=setTimeout(function(){t.finalize()},e))},finalize:function(){var t,e,n,i,o=this;o.finalized||(o.finalized=!0,t=o.manager=a.when.apply(null,o.tasks),e=t.promise(),n=a.Callbacks(),a.extend(o,e,{progress:n.add,notify:n.fire,done:function(){return o.required(!0),o.done=e.done,o.done.apply(o,arguments)}}),i=o.options.verbose,t.progress(function(t,e){i&&"rejected"==t&&console.warn("Require: Task "+e.name+" failed to load.",e)}).fail(function(){i&&console.warn("Require: Batch "+o.id+" failed.",o)}),setTimeout(function(){a.each(o.tasks,function(t,e){e.then(function(){o.notify("resolved",e)},function(){o.notify("rejected",e)},function(){o.notify("progress",e)})})},1))},expand:function(t,e){var t=a.makeArray(t),n=e||{},i=[],i=a.isPlainObject(t[0])?(n=a.extend(t[0],e),t.slice(1)):t;return{options:n,names:i}}}),a.each(["done","fail","progress","always","then"],function(t,e){n.prototype[e]=function(){return this.finalize(),this[e].apply(this,arguments)}}),i}(),a.require.addLoader("script",function(){var t=a.uri(a.indexUrl).host();t!==a.uri(document.location.href).host()&&t.match("xn--")&&(a.support.cors=!0);function r(){var n,i=this,t=a.makeArray(arguments),t=a.isPlainObject(t[0])?(o=t[0],t.slice(1)):t,o=a.extend({},r.defaultOptions,i.options,o,{batch:i});a.each(t,function(t,e){e=new r.task(e,o,n);i.addTask(e),o.serial&&void 0!==n?n.always(e.start):e.start(),n=e})}!0===document.createElement("script").async||"MozAppearance"in document.documentElement.style||window.opera;return a.extend(r,{defaultOptions:{path:"",extension:"compressed"==a.mode?"min.js":"js",serial:!1,async:!1,xhr:!1},setup:function(){a.extend(r.defaultOptions,options)},scripts:{},task:function(t,e,n){var i=a.extend(this,a.Deferred());i.name=t,i.options=e,i.taskBefore=n,a.isArray(t)&&(i.name=t[0]+"@"+t[1],i.moduleName=t[0],t[2]||(i.defineModule=!0,a.module.registry[i.moduleName]&&console.warn("$.require.script: "+i.moduleName+" exists! Using existing module instead."),i.options.xhr=!0),t=t[1],i.module=a.module(i.moduleName)),a.isUrl(t)?i.url=t:/^(\/|\.)/.test(t)?i.url=a.uri(i.options.path).toPath(t).toString():(i.url=a.uri(i.options.path).toPath("./"+t+"."+i.options.extension).toString(),i.module=a.module(t))}}),a.extend(r.task.prototype,{start:function(){var t=this.module;t&&"pending"!==t.status?this.waitForModule():this.load()},waitForModule:function(){var t=this,e=t.module;e.then(t.resolve,t.reject,t.notify),t.batch.required(function(){e.done(t.resolve)})},load:function(){var t,n=this,i=n.taskBefore;n.script=r.scripts[n.url]||(t=n.options.xhr?a.ajax({url:n.url,dataType:"text"}):a.script({url:n.url,type:"text/javascript",async:n.options.async,timeout:n.batch.options.timeout,retry:n.batch.options.retry,verbose:n.batch.options.verbose}),r.scripts[n.url]=t),n.script.done(function(t){function e(){n.module?n.waitForModule():n.resolve()}n.options.xhr&&(n.defineModule&&(n.module=a.module(n.moduleName,function(){a.globalEval(t),this.resolveWith(t)})),!n.options.async||i)?i.done(function(){a.globalEval(t),e()}):e()}).fail(function(){n.reject()})}}),r}()),a.require.addLoader("library",function(){var t=a.makeArray(arguments),e={},t=a.isPlainObject(t[0])?(e=t[0],t.slice(1)):t;return a.extend(e,{path:a.scriptPath}),this.script.apply(this,[e].concat(t))}),a.require.addLoader("image",(a.extend(r,{defaultOptions:{path:""},setup:function(){a.extend(r.defaultOptions,options)},images:{},task:function(t,e){var n=a.extend(this,a.Deferred());n.name=t,n.options=e,a.isUrl(t)?n.url=t:/^(\/|\.)/.test(t)?n.url=a.uri(n.options.path).toPath(t).toString():n.url=a.uri(n.options.path).toPath("./"+t).toString(),n.options.url=n.url}}),a.extend(r.task.prototype,{start:function(){var t=this;t.image=a(new Image).load(function(){t.resolve()}).error(function(){t.reject()}).attr("src",t.options.url)}}),r))}),KTVendors.plugin("server",function($){var self=$.server=function(i){var o=$.Deferred(),t=$.extend(!0,{},self.defaultOptions,i,{success:function(){}}),t=o.xhr=$.Ajax(t).done(function(t){if("string"==typeof t)try{t=$.parseJSON(t)}catch(t){o.rejectWith(o,["Unable to parse Ajax commands.","error"])}var n;$.isArray(t)?(n=function(t){var e=t.type,e=self.parsers[e]||i[e];if($.isFunction(e))return e.apply(o,t.data)},t=$.map(t,function(t){return"notify"!=t.type?t:void n(t)}),$.each(t,function(t,e){n(e)})):o.rejectWith(o,["Invalid ajax commands.","error"]),"pending"===o.state()&&o.resolveWith(o)}).fail(function(t,e,n){o.rejectWith(o,[n,e])});return o.abort=t.abort,o};self.defaultOptions={type:"POST",data:{tmpl:"component",format:"ajax",no_html:1},cache:!1,contentType:"application/x-www-form-urlencoded",dataType:"json"},self.parsers={script:function(){var data=$.makeArray(arguments);if("string"!=typeof data[0]){var chain=window,chainBroken=!1;$.each(data,function(t,e){"Foundry"===e.property&&(e.property=$.globalNamespace),"Foundry"===e.method&&(e.method=$.globalNamespace);try{switch(e.type){case"get":chain=chain[e.property];break;case"set":chain[e.property]=e.value,chainBroken=!0;break;case"call":chain=chain[e.method].apply(chain,e.args)}}catch(t){chainBroken=!0}})}else try{eval(data[0])}catch(err){}},resolve:function(){this.resolveWith(this,arguments)},reject:function(){this.rejectWith(this,arguments)},notify:function(){this.notifyWith(this,arguments)},redirect:function(t){window.location=t}}}),KTVendors.plugin("component",function(s){var a=s.Component=function(t,e){return arguments.length<1?a.registry:arguments.length<2?a.registry[t]:a.register(t,e)};a.registry={},a.proxy=function(t,e,n){s.isFunction(n)?t[e]=s.proxy(n,t):t[e]=n},a.register=function(t,e){var n;s.isFunction(t)&&(t=(n=t).className,e=n.options);var i=a.registry[t]=window[t]=function(t){return s.isFunction(t)?t(s):component};if(s.each(a.prototype,function(t,e){a.proxy(i,t,e)}),i.$=s,i.options=e,i.className=t,i.identifier="komento",i.componentName="com_komento",i.prefix=i.identifier+"/",i.version=e.version,i.safeVersion=i.version.replace(/\./g,""),i.environment=e.environment||s.environment,i.mode=e.mode||s.mode,i.debug="development"===i.environment,i.console=a.console(i),i.language=e.language||s.locale.lang||"en",i.ajaxUrl=e.ajaxUrl||s.basePath+"/?option="+i.componentName,i.scriptPath=e.scriptPath||s.rootPath+"/media/"+i.componentName+"/scripts/",i.stylePath=e.stylePath||s.rootPath+"/media/"+i.componentName+"/styles/",i.templatePath=e.templatePath||e.scriptPath,i.languagePath=e.languagePath||i.ajaxUrl+"&tmpl=component&no_html=1&controller=lang&task=getLanguage",i.viewPath=e.viewPath||i.ajaxUrl+"&tmpl=component&no_html=1&controller=themes&task=getAjaxTemplate",i.optimizeResources=!0,i.resourcePath=e.resourcePath||i.ajaxUrl+"&tmpl=component&no_html=1&controller=foundry&task=getResource",i.resourceInterval=1200,i.scriptVersioning=e.scriptVersioning||!1,i.tasks=[],KTVendors.component(t,i),n)if(i.debug)n.queue.execute();else{for(var o,r=KTVendors.installer(t);o=r.shift();)i.install.apply(i,o);s.when(i.install("definitions"),i.install("scripts"),i.install("resources")).done(function(){n.queue.execute()})}},a.extend=function(n,i){a.prototype[n]=i,s.each(a.registry,function(t,e){a.proxy(e,n,i)})},s.template("component/console",'<div id="[%== component.identifier %]-console" class="foundry-console" style="display: none; z-index: 999999;"><div class="console-header"><div class="console-title">[%= component.className %] [%= component.version %]</div><div class="console-remove-button">x</div></div><div class="console-log-item-group"></div><style type="text/css">.foundry-console{position:fixed;width:50%;height:50%;bottom:0;left:0;background:white;box-shadow: 0 0 5px 0;margin-left: 25px;}.console-log-item-group{width: 100%;height: 100%;overflow-y:scroll;}.console-header{position: absolute;background:red;color:white;font-weight:bold;top:-24px;left: 0;line-height:24px;width:100%}.console-remove-button{text-align:center;cursor: pointer;display:block;width: 24px;float:right}.console-remove-button:hover{color: yellow}.console-title{padding: 0 5px;float:left}.console-log-item{padding: 5px}.console-log-item + .console-log-item{border-top: 1px solid #ccc}</style></div>'),a.console=function(t){return o=t,n.selector="#"+o.identifier+"-console",n.init=function(){return(r=s(n.selector)).length<1&&(r=s(s.View("component/console",{component:o})).appendTo("body")).find(".console-remove-button").click(function(){r.hide()}),n.element=r,arguments.callee},n.methods={log:function(t,e,n){e=e||"info";var i=r.find(".console-log-item-group"),t=s(document.createElement("div")).addClass("console-log-item type-"+e).attr("data-code",n).html(t);i.append(t),i[0].scrollTop=i[0].scrollHeight,o.debug&&r.show()},toggle:function(){r.toggle()},reset:function(){r.find(".console-log-item-group").empty()}},s.each(n.methods,function(t,e){n[t]=function(){return n.init(),e.apply(n,arguments)}}),n;function n(t){return arguments.length<1?n.toggle():n[t]&&n[t].apply(n,arguments)}var o,r};var e=s(document),t=a.prototype;s.extend(t,{run:function(t){return s.isFunction(t)?t(s):this},ready:(e.ready(function(){t.ready=t.run}),function(t){s.isFunction(t)&&e.ready(function(){t(s)})}),install:function(t,e){var n=this,i=n.tasks[t]||(n.tasks[t]=s.Deferred());if(!e)return i;function o(){return e(s,n),i.resolve()}if("definitions"==t)return o();s.when(n.install("definitions")).done(o)},token:function(){return this.token.value||(this.token.value=window.kt.token)},template:function(t){var e=this;return null==t?s.grep(s.template(),function(t){return 0==t.indexOf(e.prefix)}):(arguments[0]=e.prefix+t,s.template.apply(null,arguments))},require:function(t){var r=this,t=t||{},a=s.require(t),n={};return s.each(["library","script","template","done"],function(t,e){n[e]=a[e]}),a.resource=function(t){if(s.isPlainObject(t)&&t.type&&t.name&&s.isDeferred(t.loader)){var i=r.resourceCollector;i||(i=r.resourceCollector=s.Deferred(),s.extend(i,{name:s.uid("ResourceCollector"),manifest:[],loaderList:[],loaders:[],load:function(){var e,t;delete r.resourceCollector,i.manifest.length<0?i.resolve():(e=0,(t=function(){e++,s.Ajax({type:"POST",url:r.resourcePath,dataType:"json",data:{resource:i.manifest}}).done(function(t){s.isArray(t)?(s.each(t,function(t,e){var n=e.content;i.loaders[e.id][void 0!==n?"resolve":"reject"](n)}),1<e&&r.debug&&console.info("Attempt to try and get resources again was successful!")):i.reject("Server did not return a valid resource manifest.")}).fail(function(){2<e?r.debug&&console.error("Unable to get resource again. Giving up!"):(r.debug&&console.warn("Unable to get resource. Trying again..."),t())})})(),s.when.apply(null,i.loaderList).done(i.resolve).fail(i.reject))}}),setTimeout(i.load,r.resourceCollectionInterval));var e=t.id=s.uid("Resource");return i.loaders[e]=t.loader,i.loaderList.push(t.loader),delete t.loader,i.manifest.push(t),a}},a.view=function(){var i=this,t=i.expand(arguments,{path:r.viewPath}),o={},e=t.options,t=s.map(t.names,function(t){var e=r.prefix+t,n=s.require.template.loaders[e];if(!n){if((n=s.require.template.loader(e)).name=e,i.addTask(n),!r.optimizeResources)return o[t]=n,t;a.resource({type:"view",name:t,loader:n})}});return 0<t.length&&s.Ajax({url:e.path,dataType:"json",data:{names:t}}).done(function(t){s.isArray(t)&&s.each(t,function(t,e){var n=e.content;o[e.name][void 0!==n?"resolve":"reject"](n)})}),a},a.library=function(){return n.script.apply(this,arguments),a},a.script=function(){var e=this.expand(arguments,{path:r.scriptPath}),t=s.map(e.names,function(t){return s.isArray(t)||s.isUrl(t)||/^(\/|\.)/.test(t)?t:[[r.prefix+t,s.uri(e.options.path).toPath("./"+t+"."+(e.options.extension||"js")+(r.scriptVersioning?"?version="+r.safeVersion:"")).toString(),!0]]});return n.script.apply(a,[e.options].concat(t)),a},a.template=function(){var t=this.expand(arguments,{path:r.templatePath});return n.template.apply(a,[t.options].concat(s.map(t.names,function(t){return[[r.prefix+t,t]]}))),a},a.app=function(){var i=this.expand(arguments,{path:r.scriptPath});return names=s.map(i.names,function(t){if(s.isArray(t)||s.isUrl(t)||/^(\/|\.)/.test(t))return t;var e=t.split("/"),n=s.rootPath+"/media/"+r.componentName+"/apps";return 4===e.length&&(n+="/"+e.shift()),n+="/"+e[0]+"/"+e[1]+"/scripts/"+e[2],[[r.prefix+t,n+"."+(i.options.extension||"js")+(r.scriptVersioning?"?version="+r.safeVersion:""),!0]]}),n.script.apply(a,[i.options].concat(names)),a},a.done=function(t){return n.done.call(a,function(){r.ready(t)})},a},module:function(t,e){if(!s.isArray(t)){t=this.prefix+t;return e?s.module.apply(null,[t,function(){e.call(this,s)}]):s.module(t)}}}),s.Component.extend("ajax",function(t,e,n){var i=this,o=new Date,r={url:i.ajaxUrl+"&_ts="+o.getTime(),data:s.extend(e,{option:i.componentName,namespace:t})};if((r=s.extend(!0,r,i.options.ajax)).data[i.token()]=1,r.data.hasOwnProperty("args")&&(r.data.args=s.toJSON(r.data.args)),s.isPlainObject(n)){if(n.type){switch(n.type){case"jsonp":n.dataType="jsonp",n.crossDomain=!0,r.data.transport="jsonp";break;case"iframe":n.iframe=!0,n.processData=!1,n.files=r.data.files,delete r.data.files,r.data.transport="iframe"}delete n.type}s.extend(r,n)}s.isFunction(n)&&(r.success=n);t=s.server(r);return t.progress(function(t,e,n){i.debug&&"debug"==e&&i.console.log(t,e,n)}),t}),s.Component.extend("Controller",function(){var t,e=s.makeArray(arguments),n=e[0];return 1==e.length?s.String.getObject(n):(e=2<e.length?(t=e[1],e[2]):(t={},e[1]),s.extend(t,{root:this.className+".Controller",component:this}),s.Controller.apply(this,[n,t,e]))}),s.Component.extend("View",function(t){return arguments.length<1?this.template():(arguments[0]=this.prefix+t,s.View.apply(this,arguments))}),KTVendors.module.execute(),s.each(KTVendors.component(),function(t,e){e.registered||s.Component.register(e)})}),KTVendors.plugin("static",function($){$.module(["dialog","expanding","moment","plupload","scrollTo","ui/autocomplete","ui/core","ui/menu","ui/position","ui/widget"]),KTVendors.module("dialog",function(t){function e(){jQuery(document).ready(function(){Komento.dialog=jQuery.extend(fd.dialog,{appearance:kt.appearance,theme:kt.theme,mobile:kt.mobile,ios:kt.ios,jqueryNamespace:t.globalNamespace})})}e(),this.resolveWith(e)}),KTVendors.module("expanding",function(u){function t(){function n(){u(this).data("textareaClone").find("div").text(this.value.replace(/\r\n/g,"\n")+" "),u(this).trigger("resize.expanding")}u.expandingTextarea=u.extend({autoInitialize:!0,initialSelector:"textarea.expanding",opts:{resize:function(){}}},u.expandingTextarea||{});var r=["lineHeight","textDecoration","letterSpacing","fontSize","fontFamily","fontStyle","fontWeight","textTransform","textAlign","direction","wordSpacing","fontSizeAdjust","wordWrap","word-break","borderLeftWidth","borderRightWidth","borderTopWidth","borderBottomWidth","paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom","boxSizing","webkitBoxSizing","mozBoxSizing","msBoxSizing"],a={position:"absolute",height:"100%",resize:"none"},s={visibility:"hidden",border:"0 solid",whiteSpace:"pre-wrap"},l={position:"relative"};u.fn.expandingTextarea=function(t){var e=u.extend({},u.expandingTextarea.opts,t);return"resize"===t?this.trigger("input.expanding"):("destroy"===t?this.filter(".expanding-init").each(function(){var t=u(this).removeClass("expanding-init");t.attr("style",t.data("expanding-styles")||"").removeData("expanding-styles")}):this.filter("textarea").not(".expanding-init").addClass("expanding-init").each(function(){var i=u(this),t=i.parent(),o=u(u.parseHTML("<pre class='textareaClone'><div></div></pre>"));i.after(o).data("textareaClone",o),t.css(l),i.data("expanding-styles",i.attr("style")),i.css(a),o.css(s),u.each(r,function(t,e){var n=i.css(e);o.css(e)!==n&&o.css(e,n)}),i.bind("input.expanding propertychange.expanding keyup.expanding",n),n.apply(this),e.resize&&i.bind("resize.expanding",e.resize)}),this)},u(function(){u.expandingTextarea.autoInitialize&&u(u.expandingTextarea.initialSelector).expandingTextarea()})}t(),this.resolveWith(t)}),KTVendors.module("moment",function(jt){function t(){!function(u){function a(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1}}function t(t,e){var n=!0;return s(function(){return n&&(!1===H.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t),n=!1),e.apply(this,arguments)},e)}function e(e,n){return function(t){return c(e.call(this,t),n)}}function o(){}function i(t){w(t),s(this,t)}function r(t){var e=m(t),n=e.year||0,i=e.quarter||0,o=e.month||0,r=e.week||0,a=e.day||0,s=e.hour||0,l=e.minute||0,t=e.second||0,e=e.millisecond||0;this._milliseconds=+e+1e3*t+6e4*l+36e5*s,this._days=+a+7*r,this._months=+o+3*i+12*n,this._data={},this._bubble()}function s(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return e.hasOwnProperty("toString")&&(t.toString=e.toString),e.hasOwnProperty("valueOf")&&(t.valueOf=e.valueOf),t}function l(t){return t<0?Math.ceil(t):Math.floor(t)}function c(t,e,n){for(var i=""+Math.abs(t),t=0<=t;i.length<e;)i="0"+i;return(t?n?"+":"":"-")+i}function d(t,e,n,i){var o=e._milliseconds,r=e._days,e=e._months;i=null==i||i,o&&t._d.setTime(+t._d+o*n),r&&z(t,"Date",R(t,"Date")+r*n),e&&N(t,R(t,"Month")+e*n),i&&H.updateOffset(t,r||e)}function f(t){return"[object Array]"===Object.prototype.toString.call(t)}function h(t,e,n){for(var i=Math.min(t.length,e.length),o=Math.abs(t.length-e.length),r=0,a=0;a<i;a++)(n&&t[a]!==e[a]||!n&&g(t[a])!==g(e[a]))&&r++;return r+o}function p(t){var e;return t&&(e=t.toLowerCase().replace(/(.)s$/,"$1"),t=Dt[t]||It[e]||e),t}function m(t){var e,n,i={};for(n in t)t.hasOwnProperty(n)&&(e=p(n))&&(i[e]=t[n]);return i}function g(t){var e=+t,t=0;return t=0!=e&&isFinite(e)?0<=e?Math.floor(e):Math.ceil(e):t}function v(t,e){return new Date(Date.UTC(t,e+1,0)).getUTCDate()}function n(t,e,n){return j(H([t,11,31+e-n]),e,n).week}function y(t){return b(t)?366:365}function b(t){return t%4==0&&t%100!=0||t%400==0}function w(t){var e;t._a&&-2===t._pf.overflow&&(e=t._a[G]<0||11<t._a[G]?G:t._a[q]<1||t._a[q]>v(t._a[B],t._a[G])?q:t._a[V]<0||23<t._a[V]?V:t._a[Q]<0||59<t._a[Q]?Q:t._a[J]<0||59<t._a[J]?J:t._a[Z]<0||999<t._a[Z]?Z:-1,t._pf._overflowDayOfYear&&(e<B||q<e)&&(e=q),t._pf.overflow=e)}function x(t){return null==t._isValid&&(t._isValid=!isNaN(t._d.getTime())&&t._pf.overflow<0&&!t._pf.empty&&!t._pf.invalidMonth&&!t._pf.nullInput&&!t._pf.invalidFormat&&!t._pf.userInvalidated,t._strict&&(t._isValid=t._isValid&&0===t._pf.charsLeftOver&&0===t._pf.unusedTokens.length)),t._isValid}function _(t){return t&&t.toLowerCase().replace("_","-")}function k(t,e){return e._isUTC?H(t).zone(e._offset||0):H(t).local()}function C(t){function e(t){if(!X[t]&&et)try{require("./lang/"+t)}catch(t){}return X[t]}var n,i,o,r,a=0;if(!t)return H.fn._lang;if(!f(t)){if(i=e(t))return i;t=[t]}for(;a<t.length;){for(n=(r=_(t[a]).split("-")).length,o=(o=_(t[a+1]))?o.split("-"):null;0<n;){if(i=e(r.slice(0,n).join("-")))return i;if(o&&o.length>=n&&h(r,o,!0)>=n-1)break;n--}a++}return H.fn._lang}function T(t,e){return t.isValid()?(e=E(e,t.lang()),Mt[e]||(Mt[e]=function(n){for(var t,i=n.match(rt),o=0,r=i.length;o<r;o++)$t[i[o]]?i[o]=$t[i[o]]:i[o]=(t=i[o]).match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"");return function(t){var e="";for(o=0;o<r;o++)e+=i[o]instanceof Function?i[o].call(t,n):i[o];return e}}(e)),Mt[e](t)):t.lang().invalidDate()}function E(t,e){function n(t){return e.longDateFormat(t)||t}var i=5;for(at.lastIndex=0;0<=i&&at.test(t);)t=t.replace(at,n),at.lastIndex=0,--i;return t}function S(t){var e=(t=t||"").match(ht)||[],t=((e[e.length-1]||[])+"").match(Et)||["-",0,0],e=60*t[1]+g(t[2]);return"+"===t[0]?-e:e}function D(n){var t,e,i,o,r,a,s,l=[];if(!n._d){for(a=n,s=new Date,e=a._useUTC?[s.getUTCFullYear(),s.getUTCMonth(),s.getUTCDate()]:[s.getFullYear(),s.getMonth(),s.getDate()],n._w&&null==n._a[q]&&null==n._a[G]&&(i=function(t){var e=parseInt(t,10);return t?t.length<3?68<e?1900+e:2e3+e:e:null==n._a[B]?H().weekYear():n._a[B]},r=null!=(o=n._w).GG||null!=o.W||null!=o.E?P(i(o.GG),o.W||1,o.E,4,1):(r=C(n._l),a=null!=o.d?$(o.d,r):null!=o.e?parseInt(o.e,10)+r._week.dow:0,s=parseInt(o.w,10)||1,null!=o.d&&a<r._week.dow&&s++,P(i(o.gg),s,a,r._week.doy,r._week.dow)),n._a[B]=r.year,n._dayOfYear=r.dayOfYear),n._dayOfYear&&(r=(null==n._a[B]?e:n._a)[B],n._dayOfYear>y(r)&&(n._pf._overflowDayOfYear=!0),r=O(r,0,n._dayOfYear),n._a[G]=r.getUTCMonth(),n._a[q]=r.getUTCDate()),t=0;t<3&&null==n._a[t];++t)n._a[t]=l[t]=e[t];for(;t<7;t++)n._a[t]=l[t]=null==n._a[t]?2===t?1:0:n._a[t];l[V]+=g((n._tzm||0)/60),l[Q]+=g((n._tzm||0)%60),n._d=(n._useUTC?O:A).apply(null,l)}}function I(t){t._a=[],t._pf.empty=!0;for(var e,n,i,o=C(t._l),r=""+t._i,a=r.length,s=0,l=E(t._f,o).match(rt)||[],u=0;u<l.length;u++)n=l[u],(e=(r.match(function(t,e){var n=e._strict;switch(t){case"Q":return vt;case"DDDD":return bt;case"YYYY":case"GGGG":case"gggg":return n?wt:ut;case"Y":case"G":case"g":return _t;case"YYYYYY":case"YYYYY":case"GGGGG":case"ggggg":return n?xt:ct;case"S":if(n)return vt;case"SS":if(n)return yt;case"SSS":if(n)return bt;case"DDD":return lt;case"MMM":case"MMMM":case"dd":case"ddd":case"dddd":return ft;case"a":case"A":return C(e._l)._meridiemParse;case"X":return mt;case"Z":case"ZZ":return ht;case"T":return pt;case"SSSS":return dt;case"MM":case"DD":case"YY":case"GG":case"gg":case"HH":case"hh":case"mm":case"ss":case"ww":case"WW":return n?yt:st;case"M":case"D":case"d":case"H":case"h":case"m":case"s":case"w":case"W":case"e":case"E":return st;case"Do":return gt;default:return new RegExp(t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,n,i,o){return e||n||i||o}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"))}}(n,t))||[])[0])&&(0<(i=r.substr(0,r.indexOf(e))).length&&t._pf.unusedInput.push(i),r=r.slice(r.indexOf(e)+e.length),s+=e.length),$t[n]?(e?t._pf.empty=!1:t._pf.unusedTokens.push(n),function(t,e,n){var i,o=n._a;switch(t){case"Q":null!=e&&(o[G]=3*(g(e)-1));break;case"M":case"MM":null!=e&&(o[G]=g(e)-1);break;case"MMM":case"MMMM":null!=(i=C(n._l).monthsParse(e))?o[G]=i:n._pf.invalidMonth=e;break;case"D":case"DD":null!=e&&(o[q]=g(e));break;case"Do":null!=e&&(o[q]=g(parseInt(e,10)));break;case"DDD":case"DDDD":null!=e&&(n._dayOfYear=g(e));break;case"YY":o[B]=H.parseTwoDigitYear(e);break;case"YYYY":case"YYYYY":case"YYYYYY":o[B]=g(e);break;case"a":case"A":n._isPm=C(n._l).isPM(e);break;case"H":case"HH":case"h":case"hh":o[V]=g(e);break;case"m":case"mm":o[Q]=g(e);break;case"s":case"ss":o[J]=g(e);break;case"S":case"SS":case"SSS":case"SSSS":o[Z]=g(1e3*("0."+e));break;case"X":n._d=new Date(1e3*parseFloat(e));break;case"Z":case"ZZ":n._useUTC=!0,n._tzm=S(e);break;case"w":case"ww":case"W":case"WW":case"d":case"dd":case"ddd":case"dddd":case"e":case"E":t=t.substr(0,1);case"gg":case"gggg":case"GG":case"GGGG":case"GGGGG":t=t.substr(0,2),e&&(n._w=n._w||{},n._w[t]=e)}}(n,e,t)):t._strict&&!e&&t._pf.unusedTokens.push(n);t._pf.charsLeftOver=a-s,0<r.length&&t._pf.unusedInput.push(r),t._isPm&&t._a[V]<12&&(t._a[V]+=12),!1===t._isPm&&12===t._a[V]&&(t._a[V]=0),D(t),w(t)}function M(t){var e,n=t._i,i=nt.exec(n);n===u?t._d=new Date:i?t._d=new Date(+i[1]):"string"==typeof n?function(t){var e,n,i=t._i,o=kt.exec(i);if(o){for(t._pf.iso=!0,e=0,n=Ct.length;e<n;e++)if(Ct[e][1].exec(i)){t._f=Ct[e][0]+(o[6]||" ");break}for(e=0,n=Tt.length;e<n;e++)if(Tt[e][1].exec(i)){t._f+=Tt[e][0];break}i.match(ht)&&(t._f+="Z"),I(t)}else H.createFromInputFallback(t)}(t):f(n)?(t._a=n.slice(0),D(t)):(e=n,"[object Date]"===Object.prototype.toString.call(e)||e instanceof Date?t._d=new Date(+n):"object"==typeof n?(i=t)._d||(e=m(i._i),i._a=[e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond],D(i)):"number"==typeof n?t._d=new Date(n):H.createFromInputFallback(t))}function A(t,e,n,i,o,r,a){a=new Date(t,e,n,i,o,r,a);return t<1970&&a.setFullYear(t),a}function O(t){var e=new Date(Date.UTC.apply(null,arguments));return t<1970&&e.setUTCFullYear(t),e}function $(t,e){if("string"==typeof t)if(isNaN(t)){if("number"!=typeof(t=e.weekdaysParse(t)))return null}else t=parseInt(t,10);return t}function F(t,e,n){var i=K(Math.abs(t)/1e3),o=K(i/60),r=K(o/60),a=K(r/24),s=K(a/365),s=(i<45?["s",i]:1===o&&["m"])||o<45&&["mm",o]||1===r&&["h"]||r<22&&["hh",r]||1===a&&["d"]||a<=25&&["dd",a]||a<=45&&["M"]||a<345&&["MM",K(a/30)]||1===s&&["y"]||["yy",s];return s[2]=e,s[3]=0<t,s[4]=n,function(t,e,n,i,o){return o.relativeTime(e||1,!!n,t,i)}.apply({},s)}function j(t,e,n){e=n-e,n-=t.day();return e<n&&(n-=7),n<e-7&&(n+=7),n=H(t).add("d",n),{week:Math.ceil(n.dayOfYear()/7),year:n.year()}}function P(t,e,n,i,o){var r=O(t,0,1).getUTCDay();return{year:0<(o=7*(e-1)+((n=null!=n?n:o)-o)+(o-r+(i<r?7:0)-(r<o?7:0))+1)?t:t-1,dayOfYear:0<o?o:y(t-1)+o}}function L(t){var e=t._i,n=t._f;return null===e||n===u&&""===e?H.invalid({nullInput:!0}):("string"==typeof e&&(t._i=e=C().preparse(e)),H.isMoment(e)?(t=function(t){var e,n={};for(e in t)t.hasOwnProperty(e)&&tt.hasOwnProperty(e)&&(n[e]=t[e]);return n}(e))._d=new Date(+e._d):(n?f(n)?function(t){var e,n,i,o,r;if(0===t._f.length)return t._pf.invalidFormat=!0,t._d=new Date(NaN);for(o=0;o<t._f.length;o++)r=0,(e=s({},t))._pf=a(),e._f=t._f[o],I(e),x(e)&&(r+=e._pf.charsLeftOver,r+=10*e._pf.unusedTokens.length,e._pf.score=r,(null==i||r<i)&&(i=r,n=e));s(t,n||e)}:I:M)(t),new i(t))}function N(t,e){var n;return"string"==typeof e&&"number"!=typeof(e=t.lang().monthsParse(e))||(n=Math.min(t.date(),v(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n)),t}function R(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function z(t,e,n){return"Month"===e?N(t,n):t._d["set"+(t._isUTC?"UTC":"")+e](n)}function W(e,n){return function(t){return null!=t?(z(this,e,t),H.updateOffset(this,n),this):R(this,e)}}function U(t,e){H.duration.fn["as"+t]=function(){return+this/e}}for(var H,Y,K=Math.round,B=0,G=1,q=2,V=3,Q=4,J=5,Z=6,X={},tt={_isAMomentObject:null,_i:null,_f:null,_l:null,_strict:null,_isUTC:null,_offset:null,_pf:null,_lang:null},et=void 0!==Pt&&Pt.exports,nt=/^\/?Date\((\-?\d+)/i,it=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,ot=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/,rt=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,4}|X|zz?|ZZ?|.)/g,at=/(\[[^\[]*\])|(\\)?(LT|LL?L?L?|l{1,4})/g,st=/\d\d?/,lt=/\d{1,3}/,ut=/\d{1,4}/,ct=/[+\-]?\d{1,6}/,dt=/\d+/,ft=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,ht=/Z|[\+\-]\d\d:?\d\d/gi,pt=/T/i,mt=/[\+\-]?\d+(\.\d{1,3})?/,gt=/\d{1,2}/,vt=/\d/,yt=/\d\d/,bt=/\d{3}/,wt=/\d{4}/,xt=/[+-]?\d{6}/,_t=/[+-]?\d+/,kt=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Ct=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],Tt=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],Et=/([\+\-]|\d\d)/gi,St=("Date|Hours|Minutes|Seconds|Milliseconds".split("|"),{Milliseconds:1,Seconds:1e3,Minutes:6e4,Hours:36e5,Days:864e5,Months:2592e6,Years:31536e6}),Dt={ms:"millisecond",s:"second",m:"minute",h:"hour",d:"day",D:"date",w:"week",W:"isoWeek",M:"month",Q:"quarter",y:"year",DDD:"dayOfYear",e:"weekday",E:"isoWeekday",gg:"weekYear",GG:"isoWeekYear"},It={dayofyear:"dayOfYear",isoweekday:"isoWeekday",isoweek:"isoWeek",weekyear:"weekYear",isoweekyear:"isoWeekYear"},Mt={},At="DDD w W M D d".split(" "),Ot="M D H h m s w W".split(" "),$t={M:function(){return this.month()+1},MMM:function(t){return this.lang().monthsShort(this,t)},MMMM:function(t){return this.lang().months(this,t)},D:function(){return this.date()},DDD:function(){return this.dayOfYear()},d:function(){return this.day()},dd:function(t){return this.lang().weekdaysMin(this,t)},ddd:function(t){return this.lang().weekdaysShort(this,t)},dddd:function(t){return this.lang().weekdays(this,t)},w:function(){return this.week()},W:function(){return this.isoWeek()},YY:function(){return c(this.year()%100,2)},YYYY:function(){return c(this.year(),4)},YYYYY:function(){return c(this.year(),5)},YYYYYY:function(){var t=this.year();return(0<=t?"+":"-")+c(Math.abs(t),6)},gg:function(){return c(this.weekYear()%100,2)},gggg:function(){return c(this.weekYear(),4)},ggggg:function(){return c(this.weekYear(),5)},GG:function(){return c(this.isoWeekYear()%100,2)},GGGG:function(){return c(this.isoWeekYear(),4)},GGGGG:function(){return c(this.isoWeekYear(),5)},e:function(){return this.weekday()},E:function(){return this.isoWeekday()},a:function(){return this.lang().meridiem(this.hours(),this.minutes(),!0)},A:function(){return this.lang().meridiem(this.hours(),this.minutes(),!1)},H:function(){return this.hours()},h:function(){return this.hours()%12||12},m:function(){return this.minutes()},s:function(){return this.seconds()},S:function(){return g(this.milliseconds()/100)},SS:function(){return c(g(this.milliseconds()/10),2)},SSS:function(){return c(this.milliseconds(),3)},SSSS:function(){return c(this.milliseconds(),3)},Z:function(){var t=-this.zone(),e="+";return t<0&&(t=-t,e="-"),e+c(g(t/60),2)+":"+c(g(t)%60,2)},ZZ:function(){var t=-this.zone(),e="+";return t<0&&(t=-t,e="-"),e+c(g(t/60),2)+c(g(t)%60,2)},z:function(){return this.zoneAbbr()},zz:function(){return this.zoneName()},X:function(){return this.unix()},Q:function(){return this.quarter()}},Ft=["months","monthsShort","weekdays","weekdaysShort","weekdaysMin"];At.length;)Y=At.pop(),$t[Y+"o"]=function(e,n){return function(t){return this.lang().ordinal(e.call(this,t),n)}}($t[Y],Y);for(;Ot.length;)Y=Ot.pop(),$t[Y+Y]=e($t[Y],2);for($t.DDDD=e($t.DDD,3),s(o.prototype,{set:function(t){var e,n;for(n in t)"function"==typeof(e=t[n])?this[n]=e:this["_"+n]=e},_months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),months:function(t){return this._months[t.month()]},_monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),monthsShort:function(t){return this._monthsShort[t.month()]},monthsParse:function(t){var e,n;for(this._monthsParse||(this._monthsParse=[]),e=0;e<12;e++)if(this._monthsParse[e]||(n=H.utc([2e3,e]),n="^"+this.months(n,"")+"|^"+this.monthsShort(n,""),this._monthsParse[e]=new RegExp(n.replace(".",""),"i")),this._monthsParse[e].test(t))return e},_weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdays:function(t){return this._weekdays[t.day()]},_weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysShort:function(t){return this._weekdaysShort[t.day()]},_weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),weekdaysMin:function(t){return this._weekdaysMin[t.day()]},weekdaysParse:function(t){var e,n;for(this._weekdaysParse||(this._weekdaysParse=[]),e=0;e<7;e++)if(this._weekdaysParse[e]||(n=H([2e3,1]).day(e),n="^"+this.weekdays(n,"")+"|^"+this.weekdaysShort(n,"")+"|^"+this.weekdaysMin(n,""),this._weekdaysParse[e]=new RegExp(n.replace(".",""),"i")),this._weekdaysParse[e].test(t))return e},_longDateFormat:{LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D YYYY",LLL:"MMMM D YYYY LT",LLLL:"dddd, MMMM D YYYY LT"},longDateFormat:function(t){var e=this._longDateFormat[t];return!e&&this._longDateFormat[t.toUpperCase()]&&(e=this._longDateFormat[t.toUpperCase()].replace(/MMMM|MM|DD|dddd/g,function(t){return t.slice(1)}),this._longDateFormat[t]=e),e},isPM:function(t){return"p"===(t+"").toLowerCase().charAt(0)},_meridiemParse:/[ap]\.?m?\.?/i,meridiem:function(t,e,n){return 11<t?n?"pm":"PM":n?"am":"AM"},_calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},calendar:function(t,e){t=this._calendar[t];return"function"==typeof t?t.apply(e):t},_relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},relativeTime:function(t,e,n,i){var o=this._relativeTime[n];return"function"==typeof o?o(t,e,n,i):o.replace(/%d/i,t)},pastFuture:function(t,e){t=this._relativeTime[0<t?"future":"past"];return"function"==typeof t?t(e):t.replace(/%s/i,e)},ordinal:function(t){return this._ordinal.replace("%d",t)},_ordinal:"%d",preparse:function(t){return t},postformat:function(t){return t},week:function(t){return j(t,this._week.dow,this._week.doy).week},_week:{dow:0,doy:6},_invalidDate:"Invalid date",invalidDate:function(){return this._invalidDate}}),(H=function(t,e,n,i){var o;return"boolean"==typeof n&&(i=n,n=u),(o={_isAMomentObject:!0})._i=t,o._f=e,o._l=n,o._strict=i,o._isUTC=!1,o._pf=a(),L(o)}).suppressDeprecationWarnings=!1,H.createFromInputFallback=t("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(t){t._d=new Date(t._i)}),H.utc=function(t,e,n,i){var o;return"boolean"==typeof n&&(i=n,n=u),(o={_isAMomentObject:!0,_useUTC:!0,_isUTC:!0})._l=n,o._i=t,o._f=e,o._strict=i,o._pf=a(),L(o).utc()},H.unix=function(t){return H(1e3*t)},H.duration=function(t,e){var n,i=t,o=null;return H.isDuration(t)?i={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(i={},e?i[e]=t:i.milliseconds=t):(o=it.exec(t))?(n="-"===o[1]?-1:1,i={y:0,d:g(o[q])*n,h:g(o[V])*n,m:g(o[Q])*n,s:g(o[J])*n,ms:g(o[Z])*n}):(o=ot.exec(t))&&(n="-"===o[1]?-1:1,i={y:(e=function(t){t=t&&parseFloat(t.replace(",","."));return(isNaN(t)?0:t)*n})(o[2]),M:e(o[3]),d:e(o[4]),h:e(o[5]),m:e(o[6]),s:e(o[7]),w:e(o[8])}),i=new r(i),H.isDuration(t)&&t.hasOwnProperty("_lang")&&(i._lang=t._lang),i},H.version="2.6.0",H.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",H.momentProperties=tt,H.updateOffset=function(){},H.lang=function(t,e){var n,i;return t?(e?(n=_(t),(i=e).abbr=n,X[n]||(X[n]=new o),X[n].set(i),X[n]):null===e?(delete X[t],t="en"):X[t]||C(t),(H.duration.fn._lang=H.fn._lang=C(t))._abbr):H.fn._lang._abbr},H.langData=function(t){return C(t=t&&t._lang&&t._lang._abbr?t._lang._abbr:t)},H.isMoment=function(t){return t instanceof i||null!=t&&t.hasOwnProperty("_isAMomentObject")},H.isDuration=function(t){return t instanceof r},Y=Ft.length-1;0<=Y;--Y)!function(a){var s,l;if(0===a.indexOf("week"))s=7,l="day";else{if(0!==a.indexOf("month"))return;s=12,l="month"}H[a]=function(e,t){var n,i,o=H.fn._lang[a],r=[];if("number"==typeof e&&(t=e,e=u),i=function(t){t=H().utc().set(l,t);return o.call(H.fn._lang,t,e||"")},null!=t)return i(t);for(n=0;n<s;n++)r.push(i(n));return r}}(Ft[Y]);for(Y in H.normalizeUnits=p,H.invalid=function(t){var e=H.utc(NaN);return null!=t?s(e._pf,t):e._pf.userInvalidated=!0,e},H.parseZone=function(){return H.apply(null,arguments).parseZone()},H.parseTwoDigitYear=function(t){return g(t)+(68<g(t)?1900:2e3)},s(H.fn=i.prototype,{clone:function(){return H(this)},valueOf:function(){return+this._d+6e4*(this._offset||0)},unix:function(){return Math.floor(+this/1e3)},toString:function(){return this.clone().lang("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},toDate:function(){return this._offset?new Date(+this):this._d},toISOString:function(){var t=H(this).utc();return 0<t.year()&&t.year()<=9999?T(t,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):T(t,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]")},toArray:function(){var t=this;return[t.year(),t.month(),t.date(),t.hours(),t.minutes(),t.seconds(),t.milliseconds()]},isValid:function(){return x(this)},isDSTShifted:function(){return!!this._a&&(this.isValid()&&0<h(this._a,(this._isUTC?H.utc(this._a):H(this._a)).toArray()))},parsingFlags:function(){return s({},this._pf)},invalidAt:function(){return this._pf.overflow},utc:function(){return this.zone(0)},local:function(){return this.zone(0),this._isUTC=!1,this},format:function(t){t=T(this,t||H.defaultFormat);return this.lang().postformat(t)},add:function(t,e){e="string"==typeof t?H.duration(+e,t):H.duration(t,e);return d(this,e,1),this},subtract:function(t,e){e="string"==typeof t?H.duration(+e,t):H.duration(t,e);return d(this,e,-1),this},diff:function(t,e,n){var i,o,r=k(t,this),t=6e4*(this.zone()-r.zone());return"year"===(e=p(e))||"month"===e?(i=432e5*(this.daysInMonth()+r.daysInMonth()),o=12*(this.year()-r.year())+(this.month()-r.month()),o+=(this-H(this).startOf("month")-(r-H(r).startOf("month")))/i,o-=6e4*(this.zone()-H(this).startOf("month").zone()-(r.zone()-H(r).startOf("month").zone()))/i,"year"===e&&(o/=12)):(i=this-r,o="second"===e?i/1e3:"minute"===e?i/6e4:"hour"===e?i/36e5:"day"===e?(i-t)/864e5:"week"===e?(i-t)/6048e5:i),n?o:l(o)},from:function(t,e){return H.duration(this.diff(t)).lang(this.lang()._abbr).humanize(!e)},fromNow:function(t){return this.from(H(),t)},calendar:function(){var t=k(H(),this).startOf("day"),t=this.diff(t,"days",!0),t=t<-6?"sameElse":t<-1?"lastWeek":t<0?"lastDay":t<1?"sameDay":t<2?"nextDay":t<7?"nextWeek":"sameElse";return this.format(this.lang().calendar(t,this))},isLeapYear:function(){return b(this.year())},isDST:function(){return this.zone()<this.clone().month(0).zone()||this.zone()<this.clone().month(5).zone()},day:function(t){var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=$(t,this.lang()),this.add({d:t-e})):e},month:W("Month",!0),startOf:function(t){switch(t=p(t)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===t?this.weekday(0):"isoWeek"===t&&this.isoWeekday(1),"quarter"===t&&this.month(3*Math.floor(this.month()/3)),this},endOf:function(t){return t=p(t),this.startOf(t).add("isoWeek"===t?"week":t,1).subtract("ms",1)},isAfter:function(t,e){return e=void 0!==e?e:"millisecond",+this.clone().startOf(e)>+H(t).startOf(e)},isBefore:function(t,e){return e=void 0!==e?e:"millisecond",+this.clone().startOf(e)<+H(t).startOf(e)},isSame:function(t,e){return e=e||"ms",+this.clone().startOf(e)==+k(t,this).startOf(e)},min:function(t){return(t=H.apply(null,arguments))<this?this:t},max:function(t){return this<(t=H.apply(null,arguments))?this:t},zone:function(t,e){var n=this._offset||0;return null==t?this._isUTC?n:this._d.getTimezoneOffset():("string"==typeof t&&(t=S(t)),Math.abs(t)<16&&(t*=60),this._offset=t,this._isUTC=!0,n!==t&&(!e||this._changeInProgress?d(this,H.duration(n-t,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,H.updateOffset(this,!0),this._changeInProgress=null)),this)},zoneAbbr:function(){return this._isUTC?"UTC":""},zoneName:function(){return this._isUTC?"Coordinated Universal Time":""},parseZone:function(){return this._tzm?this.zone(this._tzm):"string"==typeof this._i&&this.zone(this._i),this},hasAlignedHourOffset:function(t){return t=t?H(t).zone():0,(this.zone()-t)%60==0},daysInMonth:function(){return v(this.year(),this.month())},dayOfYear:function(t){var e=K((H(this).startOf("day")-H(this).startOf("year"))/864e5)+1;return null==t?e:this.add("d",t-e)},quarter:function(t){return null==t?Math.ceil((this.month()+1)/3):this.month(3*(t-1)+this.month()%3)},weekYear:function(t){var e=j(this,this.lang()._week.dow,this.lang()._week.doy).year;return null==t?e:this.add("y",t-e)},isoWeekYear:function(t){var e=j(this,1,4).year;return null==t?e:this.add("y",t-e)},week:function(t){var e=this.lang().week(this);return null==t?e:this.add("d",7*(t-e))},isoWeek:function(t){var e=j(this,1,4).week;return null==t?e:this.add("d",7*(t-e))},weekday:function(t){var e=(this.day()+7-this.lang()._week.dow)%7;return null==t?e:this.add("d",t-e)},isoWeekday:function(t){return null==t?this.day()||7:this.day(this.day()%7?t:t-7)},isoWeeksInYear:function(){return n(this.year(),1,4)},weeksInYear:function(){var t=this._lang._week;return n(this.year(),t.dow,t.doy)},get:function(t){return this[t=p(t)]()},set:function(t,e){return"function"==typeof this[t=p(t)]&&this[t](e),this},lang:function(t){return t===u?this._lang:(this._lang=C(t),this)}}),H.fn.millisecond=H.fn.milliseconds=W("Milliseconds",!1),H.fn.second=H.fn.seconds=W("Seconds",!1),H.fn.minute=H.fn.minutes=W("Minutes",!1),H.fn.hour=H.fn.hours=W("Hours",!0),H.fn.date=W("Date",!0),H.fn.dates=t("dates accessor is deprecated. Use date instead.",W("Date",!0)),H.fn.year=W("FullYear",!0),H.fn.years=t("years accessor is deprecated. Use year instead.",W("FullYear",!0)),H.fn.days=H.fn.day,H.fn.months=H.fn.month,H.fn.weeks=H.fn.week,H.fn.isoWeeks=H.fn.isoWeek,H.fn.quarters=H.fn.quarter,H.fn.toJSON=H.fn.toISOString,s(H.duration.fn=r.prototype,{_bubble:function(){var t=this._milliseconds,e=this._days,n=this._months,i=this._data;i.milliseconds=t%1e3,t=l(t/1e3),i.seconds=t%60,t=l(t/60),i.minutes=t%60,t=l(t/60),i.hours=t%24,e+=l(t/24),i.days=e%30,n+=l(e/30),i.months=n%12,n=l(n/12),i.years=n},weeks:function(){return l(this.days()/7)},valueOf:function(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*g(this._months/12)},humanize:function(t){var e=+this,n=F(e,!t,this.lang());return t&&(n=this.lang().pastFuture(e,n)),this.lang().postformat(n)},add:function(t,e){e=H.duration(t,e);return this._milliseconds+=e._milliseconds,this._days+=e._days,this._months+=e._months,this._bubble(),this},subtract:function(t,e){e=H.duration(t,e);return this._milliseconds-=e._milliseconds,this._days-=e._days,this._months-=e._months,this._bubble(),this},get:function(t){return this[(t=p(t)).toLowerCase()+"s"]()},as:function(t){return this["as"+(t=p(t)).charAt(0).toUpperCase()+t.slice(1)+"s"]()},lang:H.fn.lang,toIsoString:function(){var t=Math.abs(this.years()),e=Math.abs(this.months()),n=Math.abs(this.days()),i=Math.abs(this.hours()),o=Math.abs(this.minutes()),r=Math.abs(this.seconds()+this.milliseconds()/1e3);return this.asSeconds()?(this.asSeconds()<0?"-":"")+"P"+(t?t+"Y":"")+(e?e+"M":"")+(n?n+"D":"")+(i||o||r?"T":"")+(i?i+"H":"")+(o?o+"M":"")+(r?r+"S":""):"P0D"}}),St)St.hasOwnProperty(Y)&&(U(Y,St[Y]),function(t){H.duration.fn[t]=function(){return this._data[t]}}(Y.toLowerCase()));U("Weeks",6048e5),H.duration.fn.asMonths=function(){return(+this-31536e6*this.years())/2592e6+12*this.years()},H.lang("en",{ordinal:function(t){var e=t%10;return t+(1===g(t%100/10)?"th":1==e?"st":2==e?"nd":3==e?"rd":"th")}}),jt.moment=H}.call(this)}var Pt=this;t(),Pt.resolveWith(t)}),function(){var moduleFactory=function($){var module=this,jQuery=$,exports=function(){function caa(t){return __.getElementById(t)}var $_,__,aaa,v0a,w0a,x0a,y0a,A0a,z0a;function D0a(t,e,n){var i=t.naturalWidth,o=t.naturalHeight,r=n.width,a=n.height,s=e.getContext("2d");s.save(),function(t){var e=t.naturalWidth;if(1048576<e*t.naturalHeight){var n=w0a.createElement("canvas");n.width=n.height=1;n=n.getContext("2d");return n.drawImage(t,1-e,0),0===n.getImageData(0,0,1,1).data[3]}return!1}(t)&&(i/=2,o/=2);var l=w0a.createElement("canvas");l.width=l.height=1024;for(var u=l.getContext("2d"),c=function(t,e){var n=w0a.createElement("canvas");n.width=1,n.height=e,(n=n.getContext("2d")).drawImage(t,0,0);for(var i=n.getImageData(0,0,1,e).data,o=0,r=e,a=e;o<a;)0===i[4*(a-1)+3]?r=a:o=a,a=r+o>>1;return 0==(e=a/e)?1:e}(t,o),d=0;d<o;){for(var f=o<d+1024?o-d:1024,h=0;h<i;){var p=i<h+1024?i-h:1024;u.clearRect(0,0,1024,1024),u.drawImage(t,-h,-d);var m=h*r/i<<0,g=Math.ceil(p*r/i),v=d*a/o/c<<0,y=Math.ceil(f*a/o/c);s.drawImage(l,0,0,p,f,m,v,g,y),h+=1024}d+=1024}s.restore()}function F0a(t,e){var n;if(!("FileReader"in v0a))return e(t.getAsBinary());(n=new FileReader).readAsBinaryString(t),n.onload=function(){e(n.result)}}function G0a(r,a,s,l){var u,c,d,f=this;!function(t,e){var n;if(!("FileReader"in v0a))return e(t.getAsDataURL());(n=new FileReader).readAsDataURL(t),n.onload=function(){e(n.result)}}(z0a[r.id],function(o){(u=w0a.createElement("canvas")).style.display="none",w0a.body.appendChild(u),(c=new Image).onerror=c.onabort=function(){l({success:!1})},c.onload=function(){var t,e,n,i;if(a.width||(a.width=c.width),a.height||(a.height=c.height),(d=Math.min(a.width/c.width,a.height/c.height))<1)t=Math.round(c.width*d),e=Math.round(c.height*d);else{if(!a.quality||"image/jpeg"!==s)return void l({success:!1});t=c.width,e=c.height}if(u.width=t,u.height=e,D0a(c,u,{width:t,height:e}),"image/jpeg"===s&&(n=new I0a(atob(o.substring(o.indexOf("base64,")+7)))).headers&&n.headers.length&&(i=new J0a).init(n.get("exif")[0])&&(i.setExif("PixelXDimension",t),i.setExif("PixelYDimension",e),n.set("exif",i.getBinary()),f.hasEventListener("ExifData")&&f.trigger("ExifData",r,i.EXIF()),f.hasEventListener("GpsData")&&f.trigger("GpsData",r,i.GPS())),a.quality&&"image/jpeg"===s)try{o=u.toDataURL(s,a.quality/100)}catch(t){o=u.toDataURL(s)}else o=u.toDataURL(s);o=o.substring(o.indexOf("base64,")+7),o=atob(o),n&&n.headers&&n.headers.length&&(o=n.restore(o),n.purge()),u.parentNode.removeChild(u),l({success:!0,data:o})},c.src=o})}function H0a(){function i(t,e){for(var n=s?0:-8*(e-1),i=0,o=0;o<e;o++)i|=r.charCodeAt(t+o)<<Math.abs(n+8*o);return i}function a(t,e,n){n=3===arguments.length?n:r.length-e-1;r=r.substr(0,e)+t+r.substr(n+e)}var r,s=!1;return{II:function(t){if(t===y0a)return s;s=t},init:function(t){s=!1,r=t},SEGMENT:function(t,e,n){switch(arguments.length){case 1:return r.substr(t,r.length-t-1);case 2:return r.substr(t,e);case 3:a(n,t,e);break;default:return r}},BYTE:function(t){return i(t,1)},SHORT:function(t){return i(t,2)},LONG:function(t,e){if(e===y0a)return i(t,4);!function(t,e,n){for(var i="",o=s?0:-8*(n-1),r=0;r<n;r++)i+=String.fromCharCode(e>>Math.abs(o+8*r)&255);a(i,t,n)}(t,e,4)},SLONG:function(t){t=i(t,4);return 2147483647<t?t-4294967296:t},STRING:function(t,e){var n="";for(e+=t;t<e;t++)n+=String.fromCharCode(i(t,1));return n}}}function I0a(t){var r,e,n,i,o={65505:{app:"EXIF",name:"APP1",signature:"Exif\0"},65506:{app:"ICC",name:"APP2",signature:"ICC_PROFILE\0"},65517:{app:"IPTC",name:"APP13",signature:"Photoshop 3.0\0"}},a=[],s=new H0a;if(s.init(t),65496===s.SHORT(0)){for(r=2,i=Math.min(1048576,t.length);r<=i;)if(65488<=(e=s.SHORT(r))&&e<=65495)r+=2;else{if(65498===e||65497===e)break;n=s.SHORT(r+2)+2,o[e]&&s.STRING(r+4,o[e].signature.length)===o[e].signature&&a.push({hex:e,app:o[e].app.toUpperCase(),name:o[e].name.toUpperCase(),start:r,length:n,segment:s.SEGMENT(r,n)}),r+=n}return s.init(null),{headers:a,restore:function(t){s.init(t);var e=new I0a(t);if(!e.headers)return!1;for(var n=e.headers.length;0<n;n--){var i=e.headers[n-1];s.SEGMENT(i.start,i.length,"")}e.purge(),r=65504==s.SHORT(2)?4+s.SHORT(4):2;for(var n=0,o=a.length;n<o;n++)s.SEGMENT(r,0,a[n].segment),r+=a[n].length;return s.SEGMENT()},get:function(t){for(var e=[],n=0,i=a.length;n<i;n++)a[n].app===t.toUpperCase()&&e.push(a[n].segment);return e},set:function(t,e){var n=[];"string"==typeof e?n.push(e):n=e;for(var i=ii=0,o=a.length;i<o&&(a[i].app===t.toUpperCase()&&(a[i].segment=n[ii],a[i].length=n[ii].length,ii++),!(ii>=n.length));i++);},purge:function(){a=[],s.init(null)}}}}function J0a(){function o(t,e){for(var n,i,o,r,a,s=f.SHORT(t),l=[],u={},c=0;c<s;c++)if(r=t+12*c+2,(i=e[f.SHORT(r)])!==y0a){switch(a=f.SHORT(r+=2),o=f.LONG(r+=2),r+=4,l=[],a){case 1:case 7:for(4<o&&(r=f.LONG(r)+d.tiffHeader),n=0;n<o;n++)l[n]=f.BYTE(r+n);break;case 2:4<o&&(r=f.LONG(r)+d.tiffHeader),u[i]=f.STRING(r,o-1);continue;case 3:for(2<o&&(r=f.LONG(r)+d.tiffHeader),n=0;n<o;n++)l[n]=f.SHORT(r+2*n);break;case 4:for(1<o&&(r=f.LONG(r)+d.tiffHeader),n=0;n<o;n++)l[n]=f.LONG(r+4*n);break;case 5:for(r=f.LONG(r)+d.tiffHeader,n=0;n<o;n++)l[n]=f.LONG(r+4*n)/f.LONG(r+4*n+4);break;case 9:for(r=f.LONG(r)+d.tiffHeader,n=0;n<o;n++)l[n]=f.SLONG(r+4*n);break;case 10:for(r=f.LONG(r)+d.tiffHeader,n=0;n<o;n++)l[n]=f.SLONG(r+4*n)/f.SLONG(r+4*n+4);break;default:continue}a=1==o?l[0]:l,h.hasOwnProperty(i)&&"object"!=typeof a?u[i]=h[i][a]:u[i]=a}return u}var d={},f=new H0a,u={tiff:{274:"Orientation",34665:"ExifIFDPointer",34853:"GPSInfoIFDPointer"},exif:{36864:"ExifVersion",40961:"ColorSpace",40962:"PixelXDimension",40963:"PixelYDimension",36867:"DateTimeOriginal",33434:"ExposureTime",33437:"FNumber",34855:"ISOSpeedRatings",37377:"ShutterSpeedValue",37378:"ApertureValue",37383:"MeteringMode",37384:"LightSource",37385:"Flash",41986:"ExposureMode",41987:"WhiteBalance",41990:"SceneCaptureType",41988:"DigitalZoomRatio",41992:"Contrast",41993:"Saturation",41994:"Sharpness"},gps:{0:"GPSVersionID",1:"GPSLatitudeRef",2:"GPSLatitude",3:"GPSLongitudeRef",4:"GPSLongitude"}},h={ColorSpace:{1:"sRGB",0:"Uncalibrated"},MeteringMode:{0:"Unknown",1:"Average",2:"CenterWeightedAverage",3:"Spot",4:"MultiSpot",5:"Pattern",6:"Partial",255:"Other"},LightSource:{1:"Daylight",2:"Fliorescent",3:"Tungsten",4:"Flash",9:"Fine weather",10:"Cloudy weather",11:"Shade",12:"Daylight fluorescent (D 5700 - 7100K)",13:"Day white fluorescent (N 4600 -5400K)",14:"Cool white fluorescent (W 3900 - 4500K)",15:"White fluorescent (WW 3200 - 3700K)",17:"Standard light A",18:"Standard light B",19:"Standard light C",20:"D55",21:"D65",22:"D75",23:"D50",24:"ISO studio tungsten",255:"Other"},Flash:{0:"Flash did not fire.",1:"Flash fired.",5:"Strobe return light not detected.",7:"Strobe return light detected.",9:"Flash fired, compulsory flash mode",13:"Flash fired, compulsory flash mode, return light not detected",15:"Flash fired, compulsory flash mode, return light detected",16:"Flash did not fire, compulsory flash mode",24:"Flash did not fire, auto mode",25:"Flash fired, auto mode",29:"Flash fired, auto mode, return light not detected",31:"Flash fired, auto mode, return light detected",32:"No flash function",65:"Flash fired, red-eye reduction mode",69:"Flash fired, red-eye reduction mode, return light not detected",71:"Flash fired, red-eye reduction mode, return light detected",73:"Flash fired, compulsory flash mode, red-eye reduction mode",77:"Flash fired, compulsory flash mode, red-eye reduction mode, return light not detected",79:"Flash fired, compulsory flash mode, red-eye reduction mode, return light detected",89:"Flash fired, auto mode, red-eye reduction mode",93:"Flash fired, auto mode, return light not detected, red-eye reduction mode",95:"Flash fired, auto mode, return light detected, red-eye reduction mode"},ExposureMode:{0:"Auto exposure",1:"Manual exposure",2:"Auto bracket"},WhiteBalance:{0:"Auto white balance",1:"Manual white balance"},SceneCaptureType:{0:"Standard",1:"Landscape",2:"Portrait",3:"Night scene"},Contrast:{0:"Normal",1:"Soft",2:"Hard"},Saturation:{0:"Normal",1:"Low saturation",2:"High saturation"},Sharpness:{0:"Normal",1:"Soft",2:"Hard"},GPSLatitudeRef:{N:"North latitude",S:"South latitude"},GPSLongitudeRef:{E:"East longitude",W:"West longitude"}};return{init:function(t){return d={tiffHeader:10},!(t===y0a||!t.length)&&(f.init(t),65505===f.SHORT(0)&&"EXIF\0"===f.STRING(4,5).toUpperCase()&&(t=d.tiffHeader,f.II(18761==f.SHORT(t)),42===f.SHORT(t+=2)&&(d.IFD0=d.tiffHeader+f.LONG(t+=2),t=o(d.IFD0,u.tiff),d.exifIFD="ExifIFDPointer"in t?d.tiffHeader+t.ExifIFDPointer:y0a,d.gpsIFD="GPSInfoIFDPointer"in t?d.tiffHeader+t.GPSInfoIFDPointer:y0a,!0)))},EXIF:function(){var t=o(d.exifIFD,u.exif);if(t.ExifVersion&&"array"===x0a.typeOf(t.ExifVersion)){for(var e=0,n="";e<t.ExifVersion.length;e++)n+=String.fromCharCode(t.ExifVersion[e]);t.ExifVersion=n}return t},GPS:function(){var t=o(d.gpsIFD,u.gps);return t.GPSVersionID&&(t.GPSVersionID=t.GPSVersionID.join(".")),t},setExif:function(t,e){return("PixelXDimension"===t||"PixelYDimension"===t)&&function(t,e,n){var o,r,a,s=0;if("string"==typeof e){var l=u[t.toLowerCase()];for(hex in l)if(l[hex]===e){e=hex;break}}for(o=d[t.toLowerCase()+"IFD"],r=f.SHORT(o),i=0;i<r;i++)if(a=o+12*i+2,f.SHORT(a)==e){s=a+8;break}return!!s&&(f.LONG(s,n),!0)}("exif",t,e)},getBinary:function(){return f.SEGMENT()}}}!function(){function a(){this.returnValue=!1}function s(){this.cancelBubble=!0}var c,l,n=0,d=[],e={},o={},i={"<":"lt",">":"gt","&":"amp",'"':"quot","'":"#39"},r=/[<>&\"\']/g,f=window.setTimeout,u={};!function(){for(var t,e,n="application/msword,doc dot,application/pdf,pdf,application/pgp-signature,pgp,application/postscript,ps ai eps,application/rtf,rtf,application/vnd.ms-excel,xls xlb,application/vnd.ms-powerpoint,ppt pps pot,application/zip,zip,application/x-shockwave-flash,swf swfl,application/vnd.openxmlformats-officedocument.wordprocessingml.document,docx,application/vnd.openxmlformats-officedocument.wordprocessingml.template,dotx,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,xlsx,application/vnd.openxmlformats-officedocument.presentationml.presentation,pptx,application/vnd.openxmlformats-officedocument.presentationml.template,potx,application/vnd.openxmlformats-officedocument.presentationml.slideshow,ppsx,application/x-javascript,js,application/json,json,audio/mpeg,mpga mpega mp2 mp3,audio/x-wav,wav,audio/mp4,m4a,image/bmp,bmp,image/gif,gif,image/jpeg,jpeg jpg jpe,image/photoshop,psd,image/png,png,image/svg+xml,svg svgz,image/tiff,tiff tif,text/plain,asc txt text diff log,text/html,htm html xhtml,text/css,css,text/csv,csv,text/rtf,rtf,video/mpeg,mpeg mpg mpe m2v,video/quicktime,qt mov,video/mp4,mp4,video/x-m4v,m4v,video/x-flv,flv,video/x-ms-wmv,wmv,video/avi,avi,video/webm,webm,video/3gpp,3gp,video/3gpp2,3g2,video/vnd.rn-realvideo,rv,application/vnd.oasis.opendocument.formula-template,otf,application/octet-stream,exe,.rar,rar".split(/,/),i=0;i<n.length;i+=2)for(e=n[i+1].split(/ /),t=0;t<e.length;t++)o[e[t]]=n[i]}();var t,h,p,m,g,v={VERSION:"@@version@@",STOPPED:1,STARTED:2,QUEUED:1,UPLOADING:2,FAILED:4,DONE:5,GENERIC_ERROR:-100,HTTP_ERROR:-200,IO_ERROR:-300,SECURITY_ERROR:-400,INIT_ERROR:-500,FILE_SIZE_ERROR:-600,FILE_EXTENSION_ERROR:-601,IMAGE_FORMAT_ERROR:-700,IMAGE_MEMORY_ERROR:-701,IMAGE_DIMENSIONS_ERROR:-702,mimeTypes:o,ua:(t=navigator,h=t.userAgent,p=t.vendor,m=/WebKit/.test(h),g=m&&-1!==p.indexOf("Apple"),p=window.opera&&window.opera.buildNumber,{windows:-1!==navigator.platform.indexOf("Win"),android:/Android/.test(h),ie:!m&&!p&&/MSIE/gi.test(h)&&/Explorer/gi.test(t.appName),webkit:m,gecko:!m&&/Gecko/.test(h),safari:g,opera:!!p}),typeOf:function(t){return{}.toString.call(t).match(/\s([a-z|A-Z]+)/)[1].toLowerCase()},extend:function(n){return v.each(arguments,function(t,e){0<e&&v.each(t,function(t,e){n[e]=t})}),n},cleanName:function(t){for(var e=[/[\300-\306]/g,"A",/[\340-\346]/g,"a",/\307/g,"C",/\347/g,"c",/[\310-\313]/g,"E",/[\350-\353]/g,"e",/[\314-\317]/g,"I",/[\354-\357]/g,"i",/\321/g,"N",/\361/g,"n",/[\322-\330]/g,"O",/[\362-\370]/g,"o",/[\331-\334]/g,"U",/[\371-\374]/g,"u"],n=0;n<e.length;n+=2)t=t.replace(e[n],e[n+1]);return t=(t=t.replace(/\s+/g,"_")).replace(/[^a-z0-9_\-\.]+/gi,"")},addRuntime:function(t,e){return e.name=t,d[t]=e,d.push(e),e},guid:function(){for(var t=(new Date).getTime().toString(32),e=0;e<5;e++)t+=Math.floor(65535*Math.random()).toString(32);return(v.guidPrefix||"p")+t+(n++).toString(32)},buildUrl:function(t,e){var n="";return v.each(e,function(t,e){n+=(n?"&":"")+encodeURIComponent(e)+"="+encodeURIComponent(t)}),n&&(t+=(0<t.indexOf("?")?"&":"?")+n),t},each:function(t,e){var n,i,o;if(t)if((n=t.length)===c){for(i in t)if(t.hasOwnProperty(i)&&!1===e(t[i],i))return}else for(o=0;o<n;o++)if(!1===e(t[o],o))return},formatSize:function(t){return t===c||/\D/.test(t)?v.translate("N/A"):1073741824<t?Math.round(t/1073741824,1)+" GB":1048576<t?Math.round(t/1048576,1)+" MB":1024<t?Math.round(t/1024,1)+" KB":t+" b"},getPos:function(t,e){function n(t){var e,n=0,i=0;return t&&(e=t.getBoundingClientRect(),t="CSS1Compat"===l.compatMode?l.documentElement:l.body,n=e.left+t.scrollLeft,i=e.top+t.scrollTop),{x:n,y:i}}var i,o,r,a=0,s=0,l=document;if(e=e||l.body,t&&t.getBoundingClientRect&&v.ua.ie&&(!l.documentMode||l.documentMode<8))return o=n(t),r=n(e),{x:o.x-r.x,y:o.y-r.y};for(i=t;i&&i!=e&&i.nodeType;)a+=i.offsetLeft||0,s+=i.offsetTop||0,i=i.offsetParent;for(i=t.parentNode;i&&i!=e&&i.nodeType;)a-=i.scrollLeft||0,s-=i.scrollTop||0,i=i.parentNode;return{x:a,y:s}},getSize:function(t){return{w:t.offsetWidth||t.clientWidth,h:t.offsetHeight||t.clientHeight}},parseSize:function(t){var e;return"string"==typeof t&&(e=(t=/^([0-9]+)([mgk]?)$/.exec(t.toLowerCase().replace(/[^0-9mkg]/g,"")))[2],t=+t[1],"g"==e&&(t*=1073741824),"m"==e&&(t*=1048576),"k"==e&&(t*=1024)),t},xmlEncode:function(t){return t&&(""+t).replace(r,function(t){return i[t]?"&"+i[t]+";":t})},toArray:function(t){for(var e=[],n=0;n<t.length;n++)e[n]=t[n];return e},inArray:function(t,e){if(e){if(Array.prototype.indexOf)return Array.prototype.indexOf.call(e,t);for(var n=0,i=e.length;n<i;n++)if(e[n]===t)return n}return-1},addI18n:function(t){return v.extend(e,t)},translate:function(t){return e[t]||t},isEmptyObj:function(t){if(t===c)return!0;for(var e in t)return!1;return!0},hasClass:function(t,e){return""!=t.className&&new RegExp("(^|\\s+)"+e+"(\\s+|$)").test(t.className)},addClass:function(t,e){v.hasClass(t,e)||(t.className=""==t.className?e:t.className.replace(/\s+$/,"")+" "+e)},removeClass:function(t,e){e=new RegExp("(^|\\s+)"+e+"(\\s+|$)");t.className=t.className.replace(e,function(t,e,n){return" "===e&&" "===n?" ":""})},getStyle:function(t,e){return t.currentStyle?t.currentStyle[e]:window.getComputedStyle?window.getComputedStyle(t,null)[e]:void 0},addEvent:function(t,e,n){var i,o,r=arguments[3];e=e.toLowerCase(),l===c&&(l="Plupload_"+v.guid()),t.addEventListener?t.addEventListener(e,i=n,!1):t.attachEvent&&t.attachEvent("on"+e,i=function(){var t=window.event;t.target||(t.target=t.srcElement),t.preventDefault=a,t.stopPropagation=s,n(t)}),t[l]===c&&(t[l]=v.guid()),u.hasOwnProperty(t[l])||(u[t[l]]={}),(o=u[t[l]]).hasOwnProperty(e)||(o[e]=[]),o[e].push({func:i,orig:n,key:r})},removeEvent:function(e,t){var n,i;if("function"==typeof arguments[2]?n=arguments[2]:i=arguments[2],t=t.toLowerCase(),e[l]&&u[e[l]]&&u[e[l]][t]){for(var o,r=(o=u[e[l]][t]).length-1;0<=r&&(o[r].key!==i&&o[r].orig!==n||(e.removeEventListener?e.removeEventListener(t,o[r].func,!1):e.detachEvent&&e.detachEvent("on"+t,o[r].func),o[r].orig=null,o[r].func=null,o.splice(r,1),n===c));r--);if(o.length||delete u[e[l]][t],v.isEmptyObj(u[e[l]])){delete u[e[l]];try{delete e[l]}catch(t){e[l]=c}}}},removeAllEvents:function(n){var i=arguments[1];n[l]!==c&&n[l]&&v.each(u[n[l]],function(t,e){v.removeEvent(n,e,i)})}};v.Uploader=function(l){function n(){var t,e,n=0;if(this.state==v.STARTED){for(e=0;e<u.length;e++)t||u[e].status!=v.QUEUED?n++:((t=u[e]).status=v.UPLOADING,this.trigger("BeforeUpload",t)&&this.trigger("UploadFile",t));n==u.length&&(this.stop(),this.trigger("UploadComplete",u))}}function i(){var t,e;for(a.reset(),t=0;t<u.length;t++)(e=u[t]).size!==c?(a.size+=e.size,a.loaded+=e.loaded):a.size=c,e.status==v.DONE?a.uploaded++:e.status==v.FAILED?a.failed++:a.queued++;a.size===c?a.percent=0<u.length?Math.ceil(a.uploaded/u.length*100):0:(a.bytesPerSec=Math.ceil(a.loaded/((+new Date-o||1)/1e3)),a.percent=0<a.size?Math.ceil(a.loaded/a.size*100):0)}var o,t,r={},u=[],a=new v.QueueProgress;l=v.extend({chunk_size:0,multipart:!0,multi_selection:!0,file_data_name:"file",filters:[]},l),v.extend(this,{state:v.STOPPED,runtime:"",features:{},files:u,settings:l,total:a,id:v.guid(),init:function(){var e,r,t,s=this,a=0;if("function"==typeof l.preinit?l.preinit(s):v.each(l.preinit,function(t,e){s.bind(e,t)}),l.page_url=l.page_url||document.location.pathname.replace(/\/[^\/]+$/g,"/"),/^(\w+:\/\/|\/)/.test(l.url)||(l.url=l.page_url+l.url),l.chunk_size=v.parseSize(l.chunk_size),l.max_file_size=v.parseSize(l.max_file_size),s.bind("FilesAdded",function(t,e){var n,i,o,r=0,a=l.filters;for(a&&a.length&&(o=[],v.each(a,function(t){v.each(t.extensions.split(/,/),function(t){/^\s*\*\s*$/.test(t)?o.push("\\.*"):o.push("\\."+t.replace(new RegExp("["+"/^$.*+?|()[]{}\\".replace(/./g,"\\$&")+"]","g"),"\\$&"))})}),o=new RegExp(o.join("|")+"$","i")),n=0;n<e.length;n++)(i=e[n]).loaded=0,i.percent=0,i.status=v.QUEUED,!o||o.test(i.name)?i.size!==c&&i.size>l.max_file_size?t.trigger("Error",{code:v.FILE_SIZE_ERROR,message:v.translate("File size error."),file:i}):(u.push(i),r++):t.trigger("Error",{code:v.FILE_EXTENSION_ERROR,message:v.translate("File extension error."),file:i});if(!r)return!1;f(function(){s.trigger("QueueChanged"),s.refresh()},1)}),l.unique_names&&s.bind("UploadFile",function(t,e){var n=e.name.match(/\.([^.]+)$/),i="tmp";n&&(i=n[1]),e.target_name=e.id+"."+i}),s.bind("UploadProgress",function(t,e){e.percent=0<e.size?Math.ceil(e.loaded/e.size*100):100,i()}),s.bind("StateChanged",function(t){if(t.state==v.STARTED)o=+new Date;else if(t.state==v.STOPPED)for(e=t.files.length-1;0<=e;e--)t.files[e].status==v.UPLOADING&&(t.files[e].status=v.QUEUED,i())}),s.bind("QueueChanged",i),s.bind("Error",function(t,e){e.file&&(e.file.status=v.FAILED,i(),t.state==v.STARTED&&f(function(){n.call(s)},1))}),s.bind("FileUploaded",function(t,e){e.status=v.DONE,e.loaded=e.size,t.trigger("UploadProgress",e),f(function(){n.call(s)},1)}),l.runtimes)for(r=[],t=l.runtimes.split(/\s?,\s?/),e=0;e<t.length;e++)d[t[e]]&&r.push(d[t[e]]);else r=d;!function e(){var n,t,i,o=r[a++];if(o){if(n=o.getFeatures(),t=s.settings.required_features)for(t=t.split(","),i=0;i<t.length;i++)if(!n[t[i]])return void e();o.init(s,function(t){t&&t.success?(s.features=n,s.runtime=o.name,s.trigger("Init",{runtime:o.name}),s.trigger("PostInit"),s.refresh()):e()})}else s.trigger("Error",{code:v.INIT_ERROR,message:v.translate("Init error.")})}(),"function"==typeof l.init?l.init(s):v.each(l.init,function(t,e){s.bind(e,t)})},refresh:function(){this.trigger("Refresh")},start:function(){u.length&&this.state!=v.STARTED&&(this.state=v.STARTED,this.trigger("StateChanged"),n.call(this))},stop:function(){this.state!=v.STOPPED&&(this.state=v.STOPPED,this.trigger("CancelUpload"),this.trigger("StateChanged"))},disableBrowse:function(){t=arguments[0]===c||arguments[0],this.trigger("DisableBrowse",t)},getFile:function(t){for(var e=u.length-1;0<=e;e--)if(u[e].id===t)return u[e]},removeFile:function(t){for(var e=u.length-1;0<=e;e--)if(u[e].id===t.id)return this.splice(e,1)[0]},splice:function(t,e){e=u.splice(t===c?0:t,e===c?u.length:e);return this.trigger("FilesRemoved",e),this.trigger("QueueChanged"),e},trigger:function(t){var e,n,i=r[t.toLowerCase()];if(i)for((n=Array.prototype.slice.call(arguments))[0]=this,e=0;e<i.length;e++)if(!1===i[e].func.apply(i[e].scope,n))return!1;return!0},hasEventListener:function(t){return!!r[t.toLowerCase()]},bind:function(t,e,n){var i;t=t.toLowerCase(),(i=r[t]||[]).push({func:e,scope:n||this}),r[t]=i},unbind:function(t){t=t.toLowerCase();var e,n=r[t],i=arguments[1];if(n){if(i!==c){for(e=n.length-1;0<=e;e--)if(n[e].func===i){n.splice(e,1);break}}else n=[];n.length||delete r[t]}},unbindAll:function(){var n=this;v.each(r,function(t,e){n.unbind(e)})},destroy:function(){this.stop(),this.trigger("Destroy"),this.unbindAll()}})},v.File=function(t,e,n){var i=this;i.id=t,i.name=e,i.size=n,i.loaded=0,i.percent=0,i.status=0},v.Runtime=function(){this.getFeatures=function(){},this.init=function(t,e){}},v.QueueProgress=function(){var t=this;t.size=0,t.loaded=0,t.uploaded=0,t.failed=0,t.queued=0,t.percent=0,t.bytesPerSec=0,t.reset=function(){t.size=t.loaded=t.uploaded=t.failed=t.queued=t.percent=t.bytesPerSec=0}},v.runtimes={},$.plupload=v}(),$_=window,__=document,aaa=$.plupload,aaa.runtimes.Html4=aaa.addRuntime("html4",{getFeatures:function(){return{multipart:!0,triggerDialog:aaa.ua.gecko&&$_.FormData||aaa.ua.webkit}},init:function(p,t){p.bind("Init",function(a){var n,o,s,t,e,i,r,l=__.body,u="javascript",c=[],d=/MSIE/.test(navigator.userAgent),f=[],h=a.settings.filters;t:for(t=0;t<h.length;t++)for(e=h[t].extensions.split(/,/),r=0;r<e.length;r++){if("*"===e[r]){f=[];break t}(i=aaa.mimeTypes[e[r]])&&-1===aaa.inArray(i,f)&&f.push(i)}f=f.join(","),a.settings.container&&(l=caa(a.settings.container),"static"===aaa.getStyle(l,"position")&&(l.style.position="relative")),a.bind("UploadFile",function(t,e){var i;e.status!=aaa.DONE&&e.status!=aaa.FAILED&&t.state!=aaa.STOPPED&&(i=caa("form_"+e.id),caa("input_"+e.id).setAttribute("name",t.settings.file_data_name),i.setAttribute("action",t.settings.url),aaa.each(aaa.extend({name:e.target_name||e.name},t.settings.multipart_params),function(t,e){var n=__.createElement("input");aaa.extend(n,{type:"hidden",name:e,value:t}),i.insertBefore(n,i.firstChild)}),o=e,caa("form_"+s).style.top="-1048575px",i.submit())}),a.bind("FileUploaded",function(t){t.refresh()}),a.bind("StateChanged",function(t){var e;t.state==aaa.STARTED?((e=__.createElement("div")).innerHTML='<iframe id="'+a.id+'_iframe" name="'+a.id+'_iframe" src="'+u+':""" style="display:none"></iframe>',n=e.firstChild,l.appendChild(n),aaa.addEvent(n,"load",function(t){var e,t=t.target;if(o){try{e=t.contentWindow.document||t.contentDocument||$_.frames[t.id].document}catch(t){return void a.trigger("Error",{code:aaa.SECURITY_ERROR,message:aaa.translate("Security error."),file:o})}(e=e.documentElement.innerText||e.documentElement.textContent)&&(o.status=aaa.DONE,o.loaded=1025,o.percent=100,a.trigger("UploadProgress",o),a.trigger("FileUploaded",o,{response:e}))}},a.id)):t.state==aaa.STOPPED&&$_.setTimeout(function(){aaa.removeEvent(n,"load",t.id),n.parentNode&&n.parentNode.removeChild(n)},0),aaa.each(t.files,function(t,e){t.status!==aaa.DONE&&t.status!==aaa.FAILED||(t=caa("form_"+t.id))&&t.parentNode.removeChild(t)})}),a.bind("Refresh",function(t){var e,n,i,o,r,a=caa(t.settings.browse_button);a&&(i=aaa.getPos(a,caa(t.settings.container)),r=aaa.getSize(a),o=caa("form_"+s),caa("input_"+s),aaa.extend(o.style,{top:i.y+"px",left:i.x+"px",width:r.w+"px",height:r.h+"px"}),t.features.triggerDialog&&("static"===aaa.getStyle(a,"position")&&aaa.extend(a.style,{position:"relative"}),r=parseInt(a.style.zIndex,10),isNaN(r)&&(r=0),aaa.extend(a.style,{zIndex:r}),aaa.extend(o.style,{zIndex:r-1})),e=t.settings.browse_button_hover,n=t.settings.browse_button_active,o=t.features.triggerDialog?a:o,e&&(aaa.addEvent(o,"mouseover",function(){aaa.addClass(a,e)},t.id),aaa.addEvent(o,"mouseout",function(){aaa.removeClass(a,e)},t.id)),n&&(aaa.addEvent(o,"mousedown",function(){aaa.addClass(a,n)},t.id),aaa.addEvent(__.body,"mouseup",function(){aaa.removeClass(a,n)},t.id)))}),p.bind("FilesRemoved",function(t,e){for(var n,i=0;i<e.length;i++)(n=caa("form_"+e[i].id))&&n.parentNode.removeChild(n)}),p.bind("DisableBrowse",function(t,e){var n=__.getElementById("input_"+s);n&&(n.disabled=e)}),p.bind("Destroy",function(t){var e,n,i,o={inputContainer:"form_"+s,inputFile:"input_"+s,browseButton:t.settings.browse_button};for(e in o)(n=caa(o[e]))&&aaa.removeAllEvents(n,t.id);aaa.removeAllEvents(__.body,t.id),aaa.each(c,function(t,e){(i=caa("form_"+t))&&i.parentNode.removeChild(i)})}),function n(){var i,o,t,r;s=aaa.guid(),c.push(s),(i=__.createElement("form")).setAttribute("id","form_"+s),i.setAttribute("method","post"),i.setAttribute("enctype","multipart/form-data"),i.setAttribute("encoding","multipart/form-data"),i.setAttribute("target",a.id+"_iframe"),i.style.position="absolute",(o=__.createElement("input")).setAttribute("id","input_"+s),o.setAttribute("type","file"),o.setAttribute("accept",f),o.setAttribute("size",1),r=caa(a.settings.browse_button),a.features.triggerDialog&&r&&aaa.addEvent(caa(a.settings.browse_button),"click",function(t){o.disabled||o.click(),t.preventDefault()},a.id),aaa.extend(o.style,{width:"100%",height:"100%",opacity:0,fontSize:"99px",cursor:"pointer"}),aaa.extend(i.style,{overflow:"hidden"}),(t=a.settings.shim_bgcolor)&&(i.style.background=t),d&&aaa.extend(o.style,{filter:"alpha(opacity=0)"}),aaa.addEvent(o,"change",function(t){var e=t.target,t=[];e.value&&(caa("form_"+s).style.top="-1048575px",e=(e=e.value.replace(/\\/g,"/")).substring(e.length,e.lastIndexOf("/")+1),t.push(new aaa.File(s,e)),a.features.triggerDialog?aaa.removeEvent(r,"click",a.id):aaa.removeAllEvents(i,a.id),aaa.removeEvent(o,"change",a.id),n(),t.length&&p.trigger("FilesAdded",t))},a.id),i.appendChild(o),l.appendChild(i),a.refresh()}()}),t({success:!0})}}),v0a=window,w0a=document,x0a=$.plupload,z0a={},x0a.runtimes.Html5=x0a.addRuntime("html5",{getFeatures:function(){var t,e,n,i,o,r=e=i=o=!1;return v0a.XMLHttpRequest&&(e=!!(t=new XMLHttpRequest).upload,r=!(!t.sendAsBinary&&!t.upload)),r&&(n=!!(t.sendAsBinary||v0a.Uint8Array&&v0a.ArrayBuffer),i=!(!File||!File.prototype.getAsDataURL&&!v0a.FileReader||!n),o=!(!File||!(File.prototype.mozSlice||File.prototype.webkitSlice||File.prototype.slice))),A0a=x0a.ua.safari&&x0a.ua.windows,{html5:r,dragdrop:"draggable"in(r=w0a.createElement("div"))||"ondragstart"in r&&"ondrop"in r,jpgresize:i,pngresize:i,multipart:i||!!v0a.FileReader||!!v0a.FormData,canSendBinary:n,cantSendBlobInFormData:!(!(x0a.ua.gecko&&v0a.FormData&&v0a.FileReader)||FileReader.prototype.readAsArrayBuffer)||x0a.ua.android,progress:e,chunks:o,multi_selection:!(x0a.ua.safari&&x0a.ua.windows),triggerDialog:x0a.ua.gecko&&v0a.FormData||x0a.ua.webkit}},init:function(f,t){function h(t){for(var e,n,i=[],o={},r=0;r<t.length;r++)o[(e=t[r]).name]&&x0a.ua.safari&&x0a.ua.windows||(o[e.name]=!0,n=x0a.guid(),z0a[n]=e,i.push(new x0a.File(n,e.fileName||e.name,e.fileSize||e.size)));i.length&&f.trigger("FilesAdded",i)}var b,w=this.getFeatures();w.html5?(f.bind("Init",function(n){var t,e,i,o,r,a,s,l=[],u=n.settings.filters,c=w0a.body,d=w0a.createElement("div");d.id=n.id+"_html5_container",x0a.extend(d.style,{position:"absolute",background:f.settings.shim_bgcolor||"transparent",width:"100px",height:"100px",overflow:"hidden",zIndex:99999,opacity:f.settings.shim_bgcolor?"":0}),d.className="plupload html5",f.settings.container&&(c=w0a.getElementById(f.settings.container),"static"===x0a.getStyle(c,"position")&&(c.style.position="relative")),c.appendChild(d);t:for(e=0;e<u.length;e++)for(o=u[e].extensions.split(/,/),i=0;i<o.length;i++){if("*"===o[i]){l=[];break t}(r=x0a.mimeTypes[o[i]])&&-1===x0a.inArray(r,l)&&l.push(r)}d.innerHTML='<input id="'+f.id+'_html5" style="font-size:999px" type="file" accept="'+l.join(",")+'" '+(f.settings.multi_selection&&f.features.multi_selection?'multiple="multiple"':"")+" />",d.scrollTop=100,c=w0a.getElementById(f.id+"_html5"),n.features.triggerDialog?x0a.extend(c.style,{position:"absolute",width:"100%",height:"100%"}):x0a.extend(c.style,{cssFloat:"right",styleFloat:"right"}),c.onchange=function(){h(this.files),this.value=""},(t=w0a.getElementById(n.settings.browse_button))&&(a=n.settings.browse_button_hover,s=n.settings.browse_button_active,d=n.features.triggerDialog?t:d,a&&(x0a.addEvent(d,"mouseover",function(){x0a.addClass(t,a)},n.id),x0a.addEvent(d,"mouseout",function(){x0a.removeClass(t,a)},n.id)),s&&(x0a.addEvent(d,"mousedown",function(){x0a.addClass(t,s)},n.id),x0a.addEvent(w0a.body,"mouseup",function(){x0a.removeClass(t,s)},n.id)),n.features.triggerDialog&&x0a.addEvent(t,"click",function(t){var e=w0a.getElementById(n.id+"_html5");e&&!e.disabled&&e.click(),t.preventDefault()},n.id))}),f.bind("PostInit",function(){var i=w0a.getElementById(f.settings.drop_element);i&&(A0a?x0a.addEvent(i,"dragenter",function(t){var e,n=w0a.getElementById(f.id+"_drop");n||((n=w0a.createElement("input")).setAttribute("type","file"),n.setAttribute("id",f.id+"_drop"),n.setAttribute("multiple","multiple"),x0a.addEvent(n,"change",function(){h(this.files),x0a.removeEvent(n,"change",f.id),n.parentNode.removeChild(n)},f.id),x0a.addEvent(n,"dragover",function(t){t.stopPropagation()},f.id),i.appendChild(n)),x0a.getPos(i,w0a.getElementById(f.settings.container)),e=x0a.getSize(i),"static"===x0a.getStyle(i,"position")&&x0a.extend(i.style,{position:"relative"}),x0a.extend(n.style,{position:"absolute",display:"block",top:0,left:0,width:e.w+"px",height:e.h+"px",opacity:0})},f.id):(x0a.addEvent(i,"dragover",function(t){t.preventDefault()},f.id),x0a.addEvent(i,"drop",function(t){var e=t.dataTransfer;e&&e.files&&h(e.files),t.preventDefault()},f.id)))}),f.bind("Refresh",function(t){var e,n,i=w0a.getElementById(f.settings.browse_button);i&&(e=x0a.getPos(i,w0a.getElementById(t.settings.container)),n=x0a.getSize(i),t=w0a.getElementById(f.id+"_html5_container"),x0a.extend(t.style,{top:e.y+"px",left:e.x+"px",width:n.w+"px",height:n.h+"px"}),f.features.triggerDialog&&("static"===x0a.getStyle(i,"position")&&x0a.extend(i.style,{position:"relative"}),n=parseInt(x0a.getStyle(i,"zIndex"),10),isNaN(n)&&(n=0),x0a.extend(i.style,{zIndex:n}),x0a.extend(t.style,{zIndex:n-1})))}),f.bind("DisableBrowse",function(t,e){t=w0a.getElementById(t.id+"_html5");t&&(t.disabled=e)}),f.bind("CancelUpload",function(){b&&b.abort&&b.abort()}),f.bind("UploadFile",function(v,y){function e(i){var m=0,g=0;!function s(){function t(t){if(b.sendAsBinary)b.sendAsBinary(t);else if(v.features.canSendBinary){for(var e=new Uint8Array(t.length),n=0;n<t.length;n++)e[n]=255&t.charCodeAt(n);b.send(e.buffer)}}function e(n){var i,e=0,o="----pluploadboundary"+x0a.guid(),r="\r\n",a="";if((b=new XMLHttpRequest).upload&&(b.upload.onprogress=function(t){y.loaded=Math.min(y.size,g+t.loaded-e),v.trigger("UploadProgress",y)}),b.onreadystatechange=function(){var e,t;if(4==b.readyState&&v.state!==x0a.STOPPED){try{e=b.status}catch(t){e=0}if(400<=e)v.trigger("Error",{code:x0a.HTTP_ERROR,message:x0a.translate("HTTP Error."),file:y,status:e});else{if(u){if(t={chunk:m,chunks:u,response:b.responseText,status:e},v.trigger("ChunkUploaded",y,t),g+=d,t.cancelled)return void(y.status=x0a.FAILED);y.loaded=Math.min(y.size,(m+1)*c)}else y.loaded=y.size;v.trigger("UploadProgress",y),n=l=i=a=null,!u||++m>=u?(y.status=x0a.DONE,v.trigger("FileUploaded",y,{response:b.responseText,status:e})):s()}}},v.settings.multipart&&w.multipart){if(h.name=y.target_name||y.name,b.open("post",p,!0),x0a.each(v.settings.headers,function(t,e){b.setRequestHeader(e,t)}),"string"!=typeof n&&v0a.FormData)return i=new FormData,x0a.each(x0a.extend(h,v.settings.multipart_params),function(t,e){i.append(e,t)}),i.append(v.settings.file_data_name,n),void b.send(i);if("string"==typeof n)return b.setRequestHeader("Content-Type","multipart/form-data; boundary="+o),x0a.each(x0a.extend(h,v.settings.multipart_params),function(t,e){a+="--"+o+r+'Content-Disposition: form-data; name="'+e+'"'+r+r,a+=unescape(encodeURIComponent(t))+r}),f=x0a.mimeTypes[y.name.replace(/^.+\.([^.]+)/,"$1").toLowerCase()]||"application/octet-stream",a+="--"+o+r+'Content-Disposition: form-data; name="'+v.settings.file_data_name+'"; filename="'+unescape(encodeURIComponent(y.name))+'"'+r+"Content-Type: "+f+r+r+n+r+"--"+o+"--"+r,e=a.length-n.length,void t(n=a)}p=x0a.buildUrl(v.settings.url,x0a.extend(h,v.settings.multipart_params)),b.open("post",p,!0),b.setRequestHeader("Content-Type","application/octet-stream"),x0a.each(v.settings.headers,function(t,e){b.setRequestHeader(e,t)}),"string"==typeof n?t(n):b.send(n)}var l,u,c,d,f,n,h,p=v.settings.url;y.status!=x0a.DONE&&y.status!=x0a.FAILED&&v.state!=x0a.STOPPED&&(h={name:y.target_name||y.name},o.chunk_size&&y.size>o.chunk_size&&(w.chunks||"string"==typeof i)?(c=o.chunk_size,u=Math.ceil(y.size/c),d=Math.min(c,y.size-m*c),l="string"==typeof i?i.substring(m*c,m*c+d):function(e,n,i){var t;if(!File.prototype.slice)return(t=File.prototype.webkitSlice||File.prototype.mozSlice)?t.call(e,n,i):null;try{return e.slice(),e.slice(n,i)}catch(t){return e.slice(n,i-n)}}(i,m*c,m*c+d),h.chunk=m,h.chunks=u):(d=y.size,l=i),v.settings.multipart&&w.multipart&&"string"!=typeof l&&v0a.FileReader&&w.cantSendBlobInFormData&&w.chunks&&v.settings.chunk_size?((n=new FileReader).onload=function(){e(n.result),n=null},n.readAsBinaryString(l)):e(l))}()}var o=v.settings,n=z0a[y.id];w.jpgresize&&v.settings.resize&&/\.(png|jpg|jpeg)$/i.test(y.name)?G0a.call(v,y,v.settings.resize,/\.png$/i.test(y.name)?"image/png":"image/jpeg",function(t){t.success?(y.size=t.data.length,e(t.data)):w.chunks?e(n):F0a(n,e)}):!w.chunks&&w.jpgresize?F0a(n,e):e(n)}),f.bind("Destroy",function(t){var e,n,i=w0a.body,o={inputContainer:t.id+"_html5_container",inputFile:t.id+"_html5",browseButton:t.settings.browse_button,dropElm:t.settings.drop_element};for(e in o)(n=w0a.getElementById(o[e]))&&x0a.removeAllEvents(n,t.id);x0a.removeAllEvents(w0a.body,t.id),(i=t.settings.container?w0a.getElementById(t.settings.container):i).removeChild(w0a.getElementById(o.inputContainer))}),t({success:!0})):t({success:!1})}}),$.Controller("plupload",{pluginName:"plupload",hostname:"plupload",defaultOptions:{"{uploader}":"[data-plupload-uploader]","{uploadButton}":"[data-plupload-upload-button]","{uploadDropsite}":"[data-plupload-dropsite]",settings:{runtimes:"html5, html4",url:$.indexUrl,max_file_count:20,unique_names:!0}}},function(self,opts,base){return{init:function(){var t=self.options.settings,e=$.uid("uploadContainer-");self.element.attr("id",e),t.container=e;e=self.uploadButtonId=$.uid("uploadButton-");self.uploadButtonMain=self.uploadButton(":first").attr("id",e),t.browse_button=e;e=$.uid("uploadDropsite-");0<self.uploadDropsite().length&&(self.uploadDropsite().attr("id",e),t.drop_element=e),self.uploader=$(self.uploader()[0]||self.element),self.plupload=new $.plupload.Uploader(t),self.plupload.bind("PostInit",function(){self.eventHandler("PostInit",$.makeArray(arguments))}),self.plupload.init();$.each(["BeforeUpload","ChunkUploaded","Destroy","Error","FilesAdded","FilesRemoved","FileUploaded","Init","QueueChanged","Refresh","StateChanged","UploadComplete","UploadFile","UploadProgress"],function(t,e){self.plupload.bind(e,function(){self.eventHandler(e,$.makeArray(arguments))})}),$.IE||"html5"!=self.plupload.runtime||base.addClass("can-drop-file"),base.addClass("can-upload")},"{uploadButton} click":function(t){t[0]!=self.uploadButtonMain[0]&&self.plupload.features.triggerDialog&&self.uploadButtonMain.click()},"{uploadButton} mouseover":function(t){self.plupload.features.triggerDialog||(self.uploadButton().removeAttr("id"),t.attr("id",self.uploadButtonId),self.plupload.refresh())},eventHandler:function(t,e){var n,i,o=self["plupload::"+t];(i=(self.uploader.data("events")||{})[t])&&i[0].handler;!1!==(n=$.isFunction(o)?o.apply(self,e):n)&&self.uploader.trigger(t,n||e)},"plupload::FileUploaded":function(up,file,data,handler){var response;try{response=eval("("+data.response+")")}catch(e){response={type:"error",message:"Unable to parse server response.",data:data}}return"error"==response.type?(self.uploader.trigger("FileError",[up,file,response]),!1):[up,file,response]},"plupload::Error":function(t,e){try{console.log("plupload Error: ",t,e)}catch(t){}}}})};exports(),module.resolveWith(exports)};KTVendors.module("plupload",moduleFactory)}(),KTVendors.module("scrollTo",function(t){var e=this,n=t,t=function(){!function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):void 0!==e&&e.exports?e.exports=t(require("jquery")):t(n)}(function(o){"use strict";function r(t){return!t.nodeName||-1!==o.inArray(t.nodeName.toLowerCase(),["iframe","#document","html","body"])}function e(t){return o.isFunction(t)||o.isPlainObject(t)?t:{top:t,left:t}}var v=o.scrollTo=function(t,e,n){return o(window).scrollTo(t,e,n)};return v.defaults={axis:"xy",duration:0,limit:!0},o.fn.scrollTo=function(t,n,m){"object"==typeof n&&(m=n,n=0),"function"==typeof m&&(m={onAfter:m}),"max"===t&&(t=9e9),m=o.extend({},v.defaults,m),n=n||m.duration;var g=m.queue&&1<m.axis.length;return g&&(n/=2),m.offset=e(m.offset),m.over=e(m.over),this.each(function(){function s(t){var e=o.extend({},m,{queue:!0,duration:n,complete:t&&function(){t.call(c,f,m)}});d.animate(h,e)}if(null!==t){var l,u=r(this),c=u?this.contentWindow||window:this,d=o(c),f=t,h={};switch(typeof f){case"number":case"string":if(/^([+-]=?)?\d+(\.\d+)?(px|%)?$/.test(f)){f=e(f);break}f=u?o(f):o(f,c);case"object":if(0===f.length)return;(f.is||f.style)&&(l=(f=o(f)).offset())}var p=o.isFunction(m.offset)&&m.offset(c,f)||m.offset;o.each(m.axis.split(""),function(t,e){var n="x"===e?"Left":"Top",i=n.toLowerCase(),o="scroll"+n,r=d[o](),a=v.max(c,e);l?(h[o]=l[i]+(u?0:r-d.offset()[i]),m.margin&&(h[o]-=parseInt(f.css("margin"+n),10)||0,h[o]-=parseInt(f.css("border"+n+"Width"),10)||0),h[o]+=p[i]||0,m.over[i]&&(h[o]+=f["x"===e?"width":"height"]()*m.over[i])):(i=f[i],h[o]=i.slice&&"%"===i.slice(-1)?parseFloat(i)/100*a:i),m.limit&&/^\d+$/.test(h[o])&&(h[o]=h[o]<=0?0:Math.min(h[o],a)),!t&&1<m.axis.length&&(r===h[o]?h={}:g&&(s(m.onAfterFirst),h={}))}),s(m.onAfter)}})},v.max=function(t,e){var n="x"===e?"Width":"Height",i="scroll"+n;if(!r(t))return t[i]-o(t)[n.toLowerCase()]();e="client"+n,n=t.ownerDocument||t.document,t=n.documentElement,n=n.body;return Math.max(t[i],n[i])-Math.min(t[e],n[e])},o.Tween.propHooks.scrollLeft=o.Tween.propHooks.scrollTop={get:function(t){return o(t.elem)[t.prop]()},set:function(t){var e=this.get(t);if(t.options.interrupt&&t._last&&t._last!==e)return o(t.elem).stop();var n=Math.round(t.now);e!==n&&(o(t.elem)[t.prop](n),t._last=this.get(t))}},v})};t(),e.resolveWith(t)}),KTVendors.module("ui/autocomplete",function(t){var e=this,n=t;t.require().script("ui/core","ui/widget","ui/position","ui/menu").done(function(){function t(){var r,i,o,t,e;i=0,(r=n).widget("ui.autocomplete",{version:"1.10.4pre",defaultElement:"<input>",options:{appendTo:"#kt.ui",autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},pending:0,_create:function(){var n,i,o,t=this.element[0].nodeName.toLowerCase(),e="textarea"===t,t="input"===t;this.isMultiLine=e||!t&&this.element.prop("isContentEditable"),this.valueMethod=this.element[e||t?"val":"text"],this.isNewMenu=!0,this.element.addClass("ui-autocomplete-input").attr("autocomplete","off"),this._on(this.element,{keydown:function(t){if(this.element.prop("readOnly"))i=o=n=!0;else{i=o=n=!1;var e=r.ui.keyCode;switch(t.keyCode){case e.PAGE_UP:n=!0,this._move("previousPage",t);break;case e.PAGE_DOWN:n=!0,this._move("nextPage",t);break;case e.UP:n=!0,this._keyEvent("previous",t);break;case e.DOWN:n=!0,this._keyEvent("next",t);break;case e.ENTER:case e.NUMPAD_ENTER:this.menu.active&&(n=!0,t.preventDefault(),this.menu.select(t));break;case e.TAB:this.menu.active&&this.menu.select(t);break;case e.ESCAPE:this.menu.element.is(":visible")&&(this._value(this.term),this.close(t),t.preventDefault());break;default:i=!0,this._searchTimeout(t)}}},keypress:function(t){if(n)return n=!1,void(this.isMultiLine&&!this.menu.element.is(":visible")||t.preventDefault());if(!i){var e=r.ui.keyCode;switch(t.keyCode){case e.PAGE_UP:this._move("previousPage",t);break;case e.PAGE_DOWN:this._move("nextPage",t);break;case e.UP:this._keyEvent("previous",t);break;case e.DOWN:this._keyEvent("next",t)}}},input:function(t){if(o)return o=!1,void t.preventDefault();this._searchTimeout(t)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){this.cancelBlur?delete this.cancelBlur:(clearTimeout(this.searching),this.close(t),this._change(t))}}),this._initSource(),this.menu=r("<ul>").addClass("ui-autocomplete ui-front").appendTo(this._appendTo()).menu({role:null}).hide().data("ui-menu"),this._on(this.menu.element,{mousedown:function(t){t.preventDefault(),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur});var n=this.menu.element[0];r(t.target).closest(".ui-menu-item").length||this._delay(function(){var e=this;this.document.one("mousedown",function(t){t.target===e.element[0]||t.target===n||r.contains(n,t.target)||e.close()})})},menufocus:function(t,e){if(this.isNewMenu&&(this.isNewMenu=!1,t.originalEvent&&/^mouse/.test(t.originalEvent.type)))return this.menu.blur(),void this.document.one("mousemove",function(){r(t.target).trigger(t.originalEvent)});e=e.item.data("ui-autocomplete-item");!1!==this._trigger("focus",t,{item:e})?t.originalEvent&&/^key/.test(t.originalEvent.type)&&this._value(e.value):this.liveRegion.text(e.value)},menuselect:function(t,e){var n=e.item.data("ui-autocomplete-item"),i=this.previous;this.element[0]!==this.document[0].activeElement&&(this.element.focus(),this.previous=i,this._delay(function(){this.previous=i,this.selectedItem=n})),!1!==this._trigger("select",t,{item:n})&&this._value(n.value),this.term=this._value(),this.close(t),this.selectedItem=n}}),this.liveRegion=r("<span>",{role:"status","aria-live":"polite"}).addClass("ui-helper-hidden-accessible").insertBefore(this.element),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_destroy:function(){clearTimeout(this.searching),this.element.removeClass("ui-autocomplete-input").removeAttr("autocomplete"),this.menu.element.remove(),this.liveRegion.remove()},_setOption:function(t,e){this._super(t,e),"source"===t&&this._initSource(),"appendTo"===t&&this.menu.element.appendTo(this._appendTo()),"disabled"===t&&e&&this.xhr&&this.xhr.abort()},_appendTo:function(){var t=this.options.appendTo;return t=!(t=(t=t&&(t.jquery||t.nodeType?r(t):this.document.find(t).eq(0)))||this.element.closest(".ui-front")).length?this.document[0].body:t},_initSource:function(){var n,i,o=this;r.isArray(this.options.source)?(n=this.options.source,this.source=function(t,e){e(r.ui.autocomplete.filter(n,t.term))}):"string"==typeof this.options.source?(i=this.options.source,this.source=function(t,e){o.xhr&&o.xhr.abort(),o.xhr=r.ajax({url:i,data:t,dataType:"json",success:function(t){e(t)},error:function(){e([])}})}):this.source=this.options.source},_searchTimeout:function(t){clearTimeout(this.searching),this.searching=this._delay(function(){this.term!==this._value()&&(this.selectedItem=null,this.search(null,t))},this.options.delay)},search:function(t,e){return t=null!=t?t:this._value(),this.term=this._value(),t.length<this.options.minLength?this.close(e):!1!==this._trigger("search",e)?this._search(t):void 0},_search:function(t){this.pending++,this.element.addClass("ui-autocomplete-loading"),this.cancelSearch=!1,this.source({term:t},this._response())},_response:function(){var e=this,n=++i;return function(t){n===i&&e.__response(t),e.pending--,e.pending||e.element.removeClass("ui-autocomplete-loading")}},__response:function(t){t=t&&this._normalize(t),this._trigger("response",null,{content:t}),!this.options.disabled&&t&&t.length&&!this.cancelSearch?(this._suggest(t),this._trigger("open")):this._close()},close:function(t){this.cancelSearch=!0,this._close(t)},_close:function(t){this.menu.element.is(":visible")&&(this.menu.element.hide(),this.menu.blur(),this.isNewMenu=!0,this._trigger("close",t))},_change:function(t){this.previous!==this._value()&&this._trigger("change",t,{item:this.selectedItem})},_normalize:function(t){return t.length&&t[0].label&&t[0].value?t:r.map(t,function(t){return"string"==typeof t?{label:t,value:t}:r.extend({label:t.label||t.value,value:t.value||t.label},t)})},_suggest:function(t){var e=this.menu.element.empty();this._renderMenu(e,t),this.isNewMenu=!0,this.menu.refresh(),e.show(),this._resizeMenu(),e.position(r.extend({of:this.element},this.options.position)),this.options.autoFocus&&this.menu.next()},_resizeMenu:function(){var t=this.menu.element;t.outerWidth(Math.max(t.width("").outerWidth()+1,this.element.outerWidth()))},_renderMenu:function(n,t){var i=this;r.each(t,function(t,e){i._renderItemData(n,e)})},_renderItemData:function(t,e){return this._renderItem(t,e).data("ui-autocomplete-item",e)},_renderItem:function(t,e){return r("<li>").append(r("<a>").text(e.label)).appendTo(t)},_move:function(t,e){if(this.menu.element.is(":visible"))return this.menu.isFirstItem()&&/^previous/.test(t)||this.menu.isLastItem()&&/^next/.test(t)?(this._value(this.term),void this.menu.blur()):void this.menu[t](e);this.search(null,e)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(t,e){this.isMultiLine&&!this.menu.element.is(":visible")||(this._move(t,e),e.preventDefault())}}),r.extend(r.ui.autocomplete,{escapeRegex:function(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(t,e){var n=new RegExp(r.ui.autocomplete.escapeRegex(e),"i");return r.grep(t,function(t){return n.test(t.label||t.value||t)})}}),r.widget("ui.autocomplete",r.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(t){return t+(1<t?" results are":" result is")+" available, use up and down arrow keys to navigate."}}},__response:function(t){var e;this._superApply(arguments),this.options.disabled||this.cancelSearch||(e=t&&t.length?this.options.messages.results(t.length):this.options.messages.noResults,this.liveRegion.text(e))}}),t=(o=n).ui.autocomplete.prototype,e=t._initSource,o.extend(t,{_initSource:function(){this.options.html&&o.isArray(this.options.source)?this.source=function(t,e){var n;e((e=this.options.source,t=t.term,n=new RegExp(o.ui.autocomplete.escapeRegex(t),"i"),o.grep(e,function(t){return n.test(o("<div>").html(t.label||t.value||t).text())})))}:e.call(this)},_renderItem:function(t,e){return o("<li></li>").data("item.autocomplete",e).append(o("<a></a>")[this.options.html?"html":"text"](e.label)).appendTo(t)}})}t(),e.resolveWith(t)})}),KTVendors.module("ui/core",function(t){var a=t,t=function(){function i(t,e){var n,i,o=t.nodeName.toLowerCase();return"area"===o?(i=(n=t.parentNode).name,!(!t.href||!i||"map"!==n.nodeName.toLowerCase())&&(!!(i=s("img[usemap=#"+i+"]")[0])&&r(i))):(/input|select|textarea|button|object/.test(o)?!t.disabled:"a"===o&&t.href||e)&&r(t)}function r(t){return s.expr.filters.visible(t)&&!s(t).parents().addBack().filter(function(){return"hidden"===s.css(this,"visibility")}).length}var s,t,e,n,o;n=0,o=/^ui-id-\d+$/,(s=a).ui=s.ui||{},s.extend(s.ui,{version:"1.10.4pre",keyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}}),s.fn.extend({focus:(t=s.fn.focus,function(e,n){return"number"==typeof e?this.each(function(){var t=this;setTimeout(function(){s(t).focus(),n&&n.call(t)},e)}):t.apply(this,arguments)}),scrollParent:function(){var t=(s.ui.ie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(s.css(this,"position"))&&/(auto|scroll)/.test(s.css(this,"overflow")+s.css(this,"overflow-y")+s.css(this,"overflow-x"))}):this.parents().filter(function(){return/(auto|scroll)/.test(s.css(this,"overflow")+s.css(this,"overflow-y")+s.css(this,"overflow-x"))})).eq(0);return/fixed/.test(this.css("position"))||!t.length?s(document):t},zIndex:function(t){if(void 0!==t)return this.css("zIndex",t);if(this.length)for(var e,n,i=s(this[0]);i.length&&i[0]!==document;){if(("absolute"===(e=i.css("position"))||"relative"===e||"fixed"===e)&&(n=parseInt(i.css("zIndex"),10),!isNaN(n)&&0!==n))return n;i=i.parent()}return 0},uniqueId:function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++n)})},removeUniqueId:function(){return this.each(function(){o.test(this.id)&&s(this).removeAttr("id")})}}),s.extend(s.expr[":"],{data:s.expr.createPseudo?s.expr.createPseudo(function(e){return function(t){return!!s.data(t,e)}}):function(t,e,n){return!!s.data(t,n[3])},focusable:function(t){return i(t,!isNaN(s.attr(t,"tabindex")))},tabbable:function(t){var e=s.attr(t,"tabindex"),n=isNaN(e);return(n||0<=e)&&i(t,!n)}}),s("<a>").outerWidth(1).jquery||s.each(["Width","Height"],function(t,n){function i(t,e,n,i){return s.each(o,function(){e-=parseFloat(s.css(t,"padding"+this))||0,n&&(e-=parseFloat(s.css(t,"border"+this+"Width"))||0),i&&(e-=parseFloat(s.css(t,"margin"+this))||0)}),e}var o="Width"===n?["Left","Right"]:["Top","Bottom"],r=n.toLowerCase(),a={innerWidth:s.fn.innerWidth,innerHeight:s.fn.innerHeight,outerWidth:s.fn.outerWidth,outerHeight:s.fn.outerHeight};s.fn["inner"+n]=function(t){return void 0===t?a["inner"+n].call(this):this.each(function(){s(this).css(r,i(this,t)+"px")})},s.fn["outer"+n]=function(t,e){return"number"!=typeof t?a["outer"+n].call(this,t):this.each(function(){s(this).css(r,i(this,t,!0,e)+"px")})}}),s.fn.addBack||(s.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),s("<a>").data("a-b","a").removeData("a-b").data("a-b")&&(s.fn.removeData=(e=s.fn.removeData,function(t){return arguments.length?e.call(this,s.camelCase(t)):e.call(this)})),s.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),s.support.selectstart="onselectstart"in document.createElement("div"),s.fn.extend({disableSelection:function(){return this.bind((s.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(t){t.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")}}),s.extend(s.ui,{plugin:{add:function(t,e,n){var i,o=s.ui[t].prototype;for(i in n)o.plugins[i]=o.plugins[i]||[],o.plugins[i].push([e,n[i]])},call:function(t,e,n){var i,o=t.plugins[e];if(o&&t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType)for(i=0;i<o.length;i++)t.options[o[i][0]]&&o[i][1].apply(t.element,n)}},hasScroll:function(t,e){if("hidden"===s(t).css("overflow"))return!1;var n=e&&"left"===e?"scrollLeft":"scrollTop",e=!1;return 0<t[n]||(t[n]=1,e=0<t[n],t[n]=0,e)}}),s(function(){0<s("body > [id=kt].ui").length||s(document.createElement("div")).attr("id","kt").addClass("ui").css({position:"absolute",top:0,left:0,overflow:"visible",width:0,height:0,zIndex:10002}).appendTo("body")})};t(),this.resolveWith(t)}),KTVendors.module("ui/menu",function(t){var e=this,n=t;t.require().script("ui/widget").done(function(){function t(){var s;(s=n).widget("ui.menu",{version:"1.10.4pre",defaultElement:"<ul>",delay:300,options:{icons:{submenu:"ui-icon-carat-1-e"},menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.element.uniqueId().addClass("ui-menu ui-widget ui-widget-content ui-corner-all").toggleClass("ui-menu-icons",!!this.element.find(".ui-icon").length).attr({role:this.options.role,tabIndex:0}).bind("click"+this.eventNamespace,s.proxy(function(t){this.options.disabled&&t.preventDefault()},this)),this.options.disabled&&this.element.addClass("ui-state-disabled").attr("aria-disabled","true"),this._on({"mousedown .ui-menu-item > a":function(t){t.preventDefault()},"click .ui-state-disabled > a":function(t){t.preventDefault()},"click .ui-menu-item:has(a)":function(t){var e=s(t.target).closest(".ui-menu-item");!this.mouseHandled&&e.not(".ui-state-disabled").length&&(this.mouseHandled=!0,this.select(t),e.has(".ui-menu").length?this.expand(t):this.element.is(":focus")||(this.element.trigger("focus",[!0]),this.active&&1===this.active.parents(".ui-menu").length&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":function(t){var e=s(t.currentTarget);e.siblings().children(".ui-state-active").removeClass("ui-state-active"),this.focus(t,e)},mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(t,e){var n=this.active||this.element.children(".ui-menu-item").eq(0);e||this.focus(t,n)},blur:function(t){this._delay(function(){s.contains(this.element[0],this.document[0].activeElement)||this.collapseAll(t)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(t){s(t.target).closest(".ui-menu").length||this.collapseAll(t),this.mouseHandled=!1}})},_destroy:function(){this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeClass("ui-menu ui-widget ui-widget-content ui-corner-all ui-menu-icons").removeAttr("role").removeAttr("tabIndex").removeAttr("aria-labelledby").removeAttr("aria-expanded").removeAttr("aria-hidden").removeAttr("aria-disabled").removeUniqueId().show(),this.element.find(".ui-menu-item").removeClass("ui-menu-item").removeAttr("role").removeAttr("aria-disabled").children("a").removeUniqueId().removeClass("ui-corner-all ui-state-hover").removeAttr("tabIndex").removeAttr("role").removeAttr("aria-haspopup").children().each(function(){var t=s(this);t.data("ui-menu-submenu-carat")&&t.remove()}),this.element.find(".ui-menu-divider").removeClass("ui-menu-divider ui-widget-content")},_keydown:function(t){function e(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}var n,i,o,r,a=!0;switch(t.keyCode){case s.ui.keyCode.PAGE_UP:this.previousPage(t);break;case s.ui.keyCode.PAGE_DOWN:this.nextPage(t);break;case s.ui.keyCode.HOME:this._move("first","first",t);break;case s.ui.keyCode.END:this._move("last","last",t);break;case s.ui.keyCode.UP:this.previous(t);break;case s.ui.keyCode.DOWN:this.next(t);break;case s.ui.keyCode.LEFT:this.collapse(t);break;case s.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(t);break;case s.ui.keyCode.ENTER:case s.ui.keyCode.SPACE:this._activate(t);break;case s.ui.keyCode.ESCAPE:this.collapse(t);break;default:a=!1,n=this.previousFilter||"",i=String.fromCharCode(t.keyCode),o=!1,clearTimeout(this.filterTimer),i===n?o=!0:i=n+i,r=new RegExp("^"+e(i),"i"),n=this.activeMenu.children(".ui-menu-item").filter(function(){return r.test(s(this).children("a").text())}),(n=o&&-1!==n.index(this.active.next())?this.active.nextAll(".ui-menu-item"):n).length||(i=String.fromCharCode(t.keyCode),r=new RegExp("^"+e(i),"i"),n=this.activeMenu.children(".ui-menu-item").filter(function(){return r.test(s(this).children("a").text())})),n.length?(this.focus(t,n),1<n.length?(this.previousFilter=i,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter):delete this.previousFilter}a&&t.preventDefault()},_activate:function(t){this.active.is(".ui-state-disabled")||(this.active.children("a[aria-haspopup='true']").length?this.expand(t):this.select(t))},refresh:function(){var i=this.options.icons.submenu,t=this.element.find(this.options.menus);t.filter(":not(.ui-menu)").addClass("ui-menu ui-widget ui-widget-content ui-corner-all").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var t=s(this),e=t.prev("a"),n=s("<span>").addClass("ui-menu-icon ui-icon "+i).data("ui-menu-submenu-carat",!0);e.attr("aria-haspopup","true").prepend(n),t.attr("aria-labelledby",e.attr("id"))}),(t=t.add(this.element)).children(":not(.ui-menu-item):has(a)").addClass("ui-menu-item").attr("role","presentation").children("a").uniqueId().addClass("ui-corner-all").attr({tabIndex:-1,role:this._itemRole()}),t.children(":not(.ui-menu-item)").each(function(){var t=s(this);/[^\-\u2014\u2013\s]/.test(t.text())||t.addClass("ui-widget-content ui-menu-divider")}),t.children(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!s.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(t,e){"icons"===t&&this.element.find(".ui-menu-icon").removeClass(this.options.icons.submenu).addClass(e.submenu),this._super(t,e)},focus:function(t,e){var n;this.blur(t,t&&"focus"===t.type),this._scrollIntoView(e),this.active=e.first(),n=this.active.children("a").addClass("ui-state-focus"),this.options.role&&this.element.attr("aria-activedescendant",n.attr("id")),this.active.parent().closest(".ui-menu-item").children("a:first").addClass("ui-state-active"),t&&"keydown"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),(n=e.children(".ui-menu")).length&&/^mouse/.test(t.type)&&this._startOpening(n),this.activeMenu=e.parent(),this._trigger("focus",t,{item:e})},_scrollIntoView:function(t){var e,n,i;this._hasScroll()&&(n=parseFloat(s.css(this.activeMenu[0],"borderTopWidth"))||0,i=parseFloat(s.css(this.activeMenu[0],"paddingTop"))||0,e=t.offset().top-this.activeMenu.offset().top-n-i,n=this.activeMenu.scrollTop(),i=this.activeMenu.height(),t=t.height(),e<0?this.activeMenu.scrollTop(n+e):i<e+t&&this.activeMenu.scrollTop(n+e-i+t))},blur:function(t,e){e||clearTimeout(this.timer),this.active&&(this.active.children("a").removeClass("ui-state-focus"),this.active=null,this._trigger("blur",t,{item:this.active}))},_startOpening:function(t){clearTimeout(this.timer),"true"===t.attr("aria-hidden")&&(this.timer=this._delay(function(){this._close(),this._open(t)},this.delay))},_open:function(t){var e=s.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(t.parents(".ui-menu")).hide().attr("aria-hidden","true"),t.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(e)},collapseAll:function(e,n){clearTimeout(this.timer),this.timer=this._delay(function(){var t=n?this.element:s(e&&e.target).closest(this.element.find(".ui-menu"));t.length||(t=this.element),this._close(t),this.blur(e),this.activeMenu=t},this.delay)},_close:function(t){(t=t||(this.active?this.active.parent():this.element)).find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false").end().find("a.ui-state-active").removeClass("ui-state-active")},collapse:function(t){var e=this.active&&this.active.parent().closest(".ui-menu-item",this.element);e&&e.length&&(this._close(),this.focus(t,e))},expand:function(t){var e=this.active&&this.active.children(".ui-menu ").children(".ui-menu-item").first();e&&e.length&&(this._open(e.parent()),this._delay(function(){this.focus(t,e)}))},next:function(t){this._move("next","first",t)},previous:function(t){this._move("prev","last",t)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_move:function(t,e,n){var i;(i=this.active?"first"===t||"last"===t?this.active["first"===t?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[t+"All"](".ui-menu-item").eq(0):i)&&i.length&&this.active||(i=this.activeMenu.children(".ui-menu-item")[e]()),this.focus(n,i)},nextPage:function(t){var e,n,i;this.active?this.isLastItem()||(this._hasScroll()?(n=this.active.offset().top,i=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return(e=s(this)).offset().top-n-i<0}),this.focus(t,e)):this.focus(t,this.activeMenu.children(".ui-menu-item")[this.active?"last":"first"]())):this.next(t)},previousPage:function(t){var e,n,i;this.active?this.isFirstItem()||(this._hasScroll()?(n=this.active.offset().top,i=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return 0<(e=s(this)).offset().top-n+i}),this.focus(t,e)):this.focus(t,this.activeMenu.children(".ui-menu-item").first())):this.next(t)},_hasScroll:function(){return this.element.outerHeight()<this.element.prop("scrollHeight")},select:function(t){this.active=this.active||s(t.target).closest(".ui-menu-item");var e={item:this.active};this.active.has(".ui-menu").length||this.collapseAll(t,!0),this._trigger("select",t,e)}})}t(),e.resolveWith(t)})}),KTVendors.module("ui/position",function(t){var e=t,t=function(){!function(_){function k(t,e,n){return[parseFloat(t[0])*(l.test(t[0])?e/100:1),parseFloat(t[1])*(l.test(t[1])?n/100:1)]}function C(t,e){return parseInt(_.css(t,e),10)||0}_.ui=_.ui||{};var i,T=Math.max,E=Math.abs,S=Math.round,o=/left|center|right/,r=/top|center|bottom/,a=/[\+\-]\d+(\.[\d]+)?%?/,s=/^\w+/,l=/%$/,n=_.fn.position;_.position={scrollbarWidth:function(){if(void 0!==i)return i;var t,e=_("<div style='display:block;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>"),n=e.children()[0];return _("body").append(e),t=n.offsetWidth,e.css("overflow","scroll"),t===(n=n.offsetWidth)&&(n=e[0].clientWidth),e.remove(),i=t-n},getScrollInfo:function(t){var e=t.isWindow?"":t.element.css("overflow-x"),n=t.isWindow?"":t.element.css("overflow-y"),e="scroll"===e||"auto"===e&&t.width<t.element[0].scrollWidth;return{width:"scroll"===n||"auto"===n&&t.height<t.element[0].scrollHeight?_.position.scrollbarWidth():0,height:e?_.position.scrollbarWidth():0}},getWithinInfo:function(t){var e=_(t||window),t=_.isWindow(e[0]);return{element:e,isWindow:t,offset:e.offset()||{left:0,top:0},scrollLeft:e.scrollLeft(),scrollTop:e.scrollTop(),width:t?e.width():e.outerWidth(),height:t?e.height():e.outerHeight()}}},_.fn.position=function(d){if(!d||!d.of)return n.apply(this,arguments);d=_.extend({},d);var f,h,p,m,g,t,v=_(d.of),y=_.position.getWithinInfo(d.within),b=_.position.getScrollInfo(y),w=(d.collision||"flip").split(" "),x={},e=9===(t=(e=v)[0]).nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:_.isWindow(t)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:t.preventDefault?{width:0,height:0,offset:{top:t.pageY,left:t.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()};return v[0].preventDefault&&(d.at="left top"),h=e.width,p=e.height,m=e.offset,g=_.extend({},m),_.each(["my","at"],function(){var t,e,n=(d[this]||"").split(" ");(n=1===n.length?o.test(n[0])?n.concat(["center"]):r.test(n[0])?["center"].concat(n):["center","center"]:n)[0]=o.test(n[0])?n[0]:"center",n[1]=r.test(n[1])?n[1]:"center",t=a.exec(n[0]),e=a.exec(n[1]),x[this]=[t?t[0]:0,e?e[0]:0],d[this]=[s.exec(n[0])[0],s.exec(n[1])[0]]}),1===w.length&&(w[1]=w[0]),"right"===d.at[0]?g.left+=h:"center"===d.at[0]&&(g.left+=h/2),"bottom"===d.at[1]?g.top+=p:"center"===d.at[1]&&(g.top+=p/2),f=k(x.at,h,p),g.left+=f[0],g.top+=f[1],this.each(function(){var n,t,a=_(this),s=a.outerWidth(),l=a.outerHeight(),e=C(this,"marginLeft"),i=C(this,"marginTop"),o=s+e+C(this,"marginRight")+b.width,r=l+i+C(this,"marginBottom")+b.height,u=_.extend({},g),c=k(x.my,a.outerWidth(),a.outerHeight());"right"===d.my[0]?u.left-=s:"center"===d.my[0]&&(u.left-=s/2),"bottom"===d.my[1]?u.top-=l:"center"===d.my[1]&&(u.top-=l/2),u.left+=c[0],u.top+=c[1],_.support.offsetFractions||(u.left=S(u.left),u.top=S(u.top)),n={marginLeft:e,marginTop:i},_.each(["left","top"],function(t,e){_.ui.position[w[t]]&&_.ui.position[w[t]][e](u,{targetWidth:h,targetHeight:p,elemWidth:s,elemHeight:l,collisionPosition:n,collisionWidth:o,collisionHeight:r,offset:[f[0]+c[0],f[1]+c[1]],my:d.my,at:d.at,within:y,elem:a})}),d.using&&(t=function(t){var e=m.left-u.left,n=e+h-s,i=m.top-u.top,o=i+p-l,r={target:{element:v,left:m.left,top:m.top,width:h,height:p},element:{element:a,left:u.left,top:u.top,width:s,height:l},horizontal:n<0?"left":0<e?"right":"center",vertical:o<0?"top":0<i?"bottom":"middle"};h<s&&E(e+n)<h&&(r.horizontal="center"),p<l&&E(i+o)<p&&(r.vertical="middle"),T(E(e),E(n))>T(E(i),E(o))?r.important="horizontal":r.important="vertical",d.using.call(this,t,r)}),a.offset(_.extend(u,{using:t}))})},_.ui.position={fit:{left:function(t,e){var n=e.within,i=n.isWindow?n.scrollLeft:n.offset.left,o=n.width,r=t.left-e.collisionPosition.marginLeft,a=i-r,s=r+e.collisionWidth-o-i;e.collisionWidth>o?0<a&&s<=0?(n=t.left+a+e.collisionWidth-o-i,t.left+=a-n):t.left=!(0<s&&a<=0)&&s<a?i+o-e.collisionWidth:i:0<a?t.left+=a:0<s?t.left-=s:t.left=T(t.left-r,t.left)},top:function(t,e){var n=e.within,i=n.isWindow?n.scrollTop:n.offset.top,o=e.within.height,r=t.top-e.collisionPosition.marginTop,a=i-r,s=r+e.collisionHeight-o-i;e.collisionHeight>o?0<a&&s<=0?(n=t.top+a+e.collisionHeight-o-i,t.top+=a-n):t.top=!(0<s&&a<=0)&&s<a?i+o-e.collisionHeight:i:0<a?t.top+=a:0<s?t.top-=s:t.top=T(t.top-r,t.top)}},flip:{left:function(t,e){var n=e.within,i=n.offset.left+n.scrollLeft,o=n.width,r=n.isWindow?n.scrollLeft:n.offset.left,a=t.left-e.collisionPosition.marginLeft,s=a-r,l=a+e.collisionWidth-o-r,u="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,n="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,a=-2*e.offset[0];s<0?((i=t.left+u+n+a+e.collisionWidth-o-i)<0||i<E(s))&&(t.left+=u+n+a):0<l&&(0<(r=t.left-e.collisionPosition.marginLeft+u+n+a-r)||E(r)<l)&&(t.left+=u+n+a)},top:function(t,e){var n=e.within,i=n.offset.top+n.scrollTop,o=n.height,r=n.isWindow?n.scrollTop:n.offset.top,a=t.top-e.collisionPosition.marginTop,s=a-r,l=a+e.collisionHeight-o-r,u="top"===e.my[1]?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,n="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,a=-2*e.offset[1];s<0?(i=t.top+u+n+a+e.collisionHeight-o-i,t.top+u+n+a>s&&(i<0||i<E(s))&&(t.top+=u+n+a)):0<l&&(r=t.top-e.collisionPosition.marginTop+u+n+a-r,t.top+u+n+a>l&&(0<r||E(r)<l)&&(t.top+=u+n+a))}},flipfit:{left:function(){_.ui.position.flip.left.apply(this,arguments),_.ui.position.fit.left.apply(this,arguments)},top:function(){_.ui.position.flip.top.apply(this,arguments),_.ui.position.fit.top.apply(this,arguments)}}},function(){var t,e=document.getElementsByTagName("body")[0],n=document.createElement("div"),i=document.createElement(e?"div":"body"),o={visibility:"hidden",width:0,height:0,border:0,margin:0,background:"none"};for(t in e&&_.extend(o,{position:"absolute",left:"-1000px",top:"-1000px"}),o)i.style[t]=o[t];i.appendChild(n),(e=e||document.documentElement).insertBefore(i,e.firstChild),n.style.cssText="position: absolute; left: 10.7432222px;",n=_(n).offset().left,_.support.offsetFractions=10<n&&n<11,i.innerHTML="",e.removeChild(i)}()}(e)};t(),this.resolveWith(t)}),KTVendors.module("ui/widget",function(t){var e=t,t=function(){var u,s,n,l,i;u=e,n=0,l=Array.prototype.slice,i=u.cleanData,u.cleanData=function(t){for(var e,n=0;null!=(e=t[n]);n++)try{u(e).triggerHandler("remove")}catch(t){}i(t)},u.widget=function(t,n,e){var i,o,r,a,s={},l=t.split(".")[0];t=t.split(".")[1],i=l+"-"+t,e||(e=n,n=u.Widget),u.expr[":"][i.toLowerCase()]=function(t){return!!u.data(t,i)},u[l]=u[l]||{},o=u[l][t],r=u[l][t]=function(t,e){if(!this._createWidget)return new r(t,e);arguments.length&&this._createWidget(t,e)},u.extend(r,o,{version:e.version,_proto:u.extend({},e),_childConstructors:[]}),(a=new n).options=u.widget.extend({},a.options),u.each(e,function(e,i){function o(){return n.prototype[e].apply(this,arguments)}function r(t){return n.prototype[e].apply(this,t)}u.isFunction(i)?s[e]=function(){var t,e=this._super,n=this._superApply;return this._super=o,this._superApply=r,t=i.apply(this,arguments),this._super=e,this._superApply=n,t}:s[e]=i}),r.prototype=u.widget.extend(a,{widgetEventPrefix:o?a.widgetEventPrefix:t},s,{constructor:r,namespace:l,widgetName:t,widgetFullName:i}),o?(u.each(o._childConstructors,function(t,e){var n=e.prototype;u.widget(n.namespace+"."+n.widgetName,r,e._proto)}),delete o._childConstructors):n._childConstructors.push(r),u.widget.bridge(t,r)},u.widget.extend=function(t){for(var e,n,i=l.call(arguments,1),o=0,r=i.length;o<r;o++)for(e in i[o])n=i[o][e],i[o].hasOwnProperty(e)&&n!==s&&(u.isPlainObject(n)?t[e]=u.isPlainObject(t[e])?u.widget.extend({},t[e],n):u.widget.extend({},n):t[e]=n);return t},u.widget.bridge=function(r,e){var a=e.prototype.widgetFullName||r;u.fn[r]=function(n){var t="string"==typeof n,i=l.call(arguments,1),o=this;return n=!t&&i.length?u.widget.extend.apply(null,[n].concat(i)):n,t?this.each(function(){var t,e=u.data(this,a);return e?u.isFunction(e[n])&&"_"!==n.charAt(0)?(t=e[n].apply(e,i))!==e&&t!==s?(o=t&&t.jquery?o.pushStack(t.get()):t,!1):void 0:u.error("no such method '"+n+"' for "+r+" widget instance"):u.error("cannot call methods on "+r+" prior to initialization; attempted to call method '"+n+"'")}):this.each(function(){var t=u.data(this,a);t?t.option(n||{})._init():u.data(this,a,new e(n,this))}),o}},u.Widget=function(){},u.Widget._childConstructors=[],u.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{disabled:!1,create:null},_createWidget:function(t,e){e=u(e||this.defaultElement||this)[0],this.element=u(e),this.uuid=n++,this.eventNamespace="."+this.widgetName+this.uuid,this.options=u.widget.extend({},this.options,this._getCreateOptions(),t),this.bindings=u(),this.hoverable=u(),this.focusable=u(),e!==this&&(u.data(e,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===e&&this.destroy()}}),this.document=u(e.style?e.ownerDocument:e.document||e),this.window=u(this.document[0].defaultView||this.document[0].parentWindow)),this._create(),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:u.noop,_getCreateEventData:u.noop,_create:u.noop,_init:u.noop,destroy:function(){this._destroy(),this.element.unbind(this.eventNamespace).removeData(this.widgetName).removeData(this.widgetFullName).removeData(u.camelCase(this.widgetFullName)),this.widget().unbind(this.eventNamespace).removeAttr("aria-disabled").removeClass(this.widgetFullName+"-disabled ui-state-disabled"),this.bindings.unbind(this.eventNamespace),this.hoverable.removeClass("ui-state-hover"),this.focusable.removeClass("ui-state-focus")},_destroy:u.noop,widget:function(){return this.element},option:function(t,e){var n,i,o,r=t;if(0===arguments.length)return u.widget.extend({},this.options);if("string"==typeof t)if(r={},t=(n=t.split(".")).shift(),n.length){for(i=r[t]=u.widget.extend({},this.options[t]),o=0;o<n.length-1;o++)i[n[o]]=i[n[o]]||{},i=i[n[o]];if(t=n.pop(),e===s)return i[t]===s?null:i[t];i[t]=e}else{if(e===s)return this.options[t]===s?null:this.options[t];r[t]=e}return this._setOptions(r),this},_setOptions:function(t){for(var e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return this.options[t]=e,"disabled"===t&&(this.widget().toggleClass(this.widgetFullName+"-disabled ui-state-disabled",!!e).attr("aria-disabled",e),this.hoverable.removeClass("ui-state-hover"),this.focusable.removeClass("ui-state-focus")),this},enable:function(){return this._setOption("disabled",!1)},disable:function(){return this._setOption("disabled",!0)},_on:function(o,r,t){var a,s=this;"boolean"!=typeof o&&(t=r,r=o,o=!1),t?(r=a=u(r),this.bindings=this.bindings.add(r)):(t=r,r=this.element,a=this.widget()),u.each(t,function(t,e){function n(){if(o||!0!==s.options.disabled&&!u(this).hasClass("ui-state-disabled"))return("string"==typeof e?s[e]:e).apply(s,arguments)}"string"!=typeof e&&(n.guid=e.guid=e.guid||n.guid||u.guid++);var i=t.match(/^(\w+)\s*(.*)$/),t=i[1]+s.eventNamespace,i=i[2];i?a.delegate(i,t,n):r.bind(t,n)})},_off:function(t,e){e=(e||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,t.unbind(e).undelegate(e)},_delay:function(t,e){var n=this;return setTimeout(function(){return("string"==typeof t?n[t]:t).apply(n,arguments)},e||0)},_hoverable:function(t){this.hoverable=this.hoverable.add(t),this._on(t,{mouseenter:function(t){u(t.currentTarget).addClass("ui-state-hover")},mouseleave:function(t){u(t.currentTarget).removeClass("ui-state-hover")}})},_focusable:function(t){this.focusable=this.focusable.add(t),this._on(t,{focusin:function(t){u(t.currentTarget).addClass("ui-state-focus")},focusout:function(t){u(t.currentTarget).removeClass("ui-state-focus")}})},_trigger:function(t,e,n){var i,o,r=this.options[t];if(n=n||{},(e=u.Event(e)).type=(t===this.widgetEventPrefix?t:this.widgetEventPrefix+t).toLowerCase(),e.target=this.element[0],o=e.originalEvent)for(i in o)i in e||(e[i]=o[i]);return this.element.trigger(e,n),!(u.isFunction(r)&&!1===r.apply(this.element[0],[e].concat(n))||e.isDefaultPrevented())}},u.each({show:"fadeIn",hide:"fadeOut"},function(r,a){u.Widget.prototype["_"+r]=function(e,t,n){var i=(t="string"==typeof t?{effect:t}:t)?!0!==t&&"number"!=typeof t&&t.effect||a:r,o=!u.isEmptyObject(t="number"==typeof(t=t||{})?{duration:t}:t);t.complete=n,t.delay&&e.delay(t.delay),o&&u.effects&&u.effects.effect[i]?e[r](t):i!==r&&e[i]?e[i](t.duration,t.easing,n):e.queue(function(t){u(this)[r](),n&&n.call(e[0]),t()})}})};t(),this.resolveWith(t)})}),KTVendors.installer("Komento","definitions",function(t){t.module(["komento/shared/elements","komento/shared/foundry","komento/site/comments/list","komento/site/comments/wrapper","komento/site/common","komento/site/dashboard/default","komento/site/dashboard/item","komento/site/form/attachments","komento/site/form/form","komento/site/form/location","komento/site/site","komento/site/structure/structure","komento/site/subscriptions/default","komento/site/subscriptions/item"])}),KTVendors.installer("Komento","scripts",function(t){Komento.module("shared/elements",function(t){var e=!1;Komento.isMobile=function(){try{return document.createEvent("TouchEvent"),!0}catch(t){return!1}};var n=0;window.onmousemove=function(){n++,i()};var i=t.debounce(function(){!e&&10<n?(e=!0,n=0,t(document).on("mouseover.tooltip.data-kt-api","[data-kt-provide=tooltip]",function(){t(this).tooltip({delay:{show:200,hide:100},animation:!1,template:'<div id="kt" class="tooltip tooltip-kt"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',container:"body"}).tooltip("show")})):n=0},500);Komento.isMobile()||t(document).on("mouseover.tooltip.data-kt-api","[data-kt-provide=tooltip]",function(){t(this).tooltip({delay:{show:200,hide:100},animation:!1,template:'<div id="kt" class="tooltip tooltip-kt"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',container:"body"}).tooltip("show")}),t(document).on("mouseover.popover.data-kt-api","[data-kt-provide=popover]",function(){t(this).popover({delay:{show:200,hide:100},animation:!1,trigger:"hover",container:"body"}).popover("show")}),this.resolve()}),Komento.module("shared/foundry",function(n){jQuery(document).on("fd.komento.user.browse",function(t,e,n,i){window.insertUser=function(t,e){n.val(e),i.val(t),Komento.dialog().close()},Komento.dialog({content:Komento.ajax("admin/views/users/browse")})}),jQuery(document).on("fd.komento.textcopy.copied",function(t,e){(e=n(e)).attr("data-original-title",e.data("copied")).tooltip("show")}),jQuery(document).on("fd.komento.textcopy.mouseout",function(t,e){n(e).attr("data-original-title",n(e).data("copy")).tooltip("show")}),this.resolve()}),Komento.module("site/comments/list",function(t){var e=this;FD.require().script("shared").done(function(){Komento.require().library("expanding").script("site/common").done(function(u){Komento.Controller("Comments.List",{defaults:{"{item}":"[data-kt-comment-item]","{attachmentWrapper}":"[data-kt-attachment-wrapper]","{attachmentItem}":"[data-fd-attachment]","{deleteAttachment}":"[data-fd-attachment-delete]","{permalink}":"[data-kt-permalink]","{delete}":"[data-kt-manage-delete]","{unpublish}":"[data-kt-manage-unpublish]","{pin}":"[data-kt-manage-pin]","{unpin}":"[data-kt-manage-unpin]","{submitSpam}":"[data-kt-submit-spam]","{minimize}":"[data-kt-manage-minimize]","{expand}":"[data-kt-manage-expand]","{userExpand}":"[data-kt-user-expand-comment]","{reply}":"[data-kt-reply]","{edit}":"[data-kt-manage-edit]","{editCancel}":"[data-kt-edit-cancel]","{editSave}":"[data-kt-edit-save]","{editForm}":"[data-kt-edit-form]","{like}":"[data-kt-likes-action]","{dislike}":"[data-kt-dislikes-action]","{likeBrowserContents}":"[data-kt-likes-browser-contents]","{likeWrapper}":"[data-kt-likes-wrapper]","{likeCounter}":"[data-kt-likes-counter]","{likeViewAll}":"[data-kt-likes-view-all]","{dislikeWrapper}":"[data-kt-dislikes-wrapper]","{dislikeCounter}":"[data-kt-dislikes-counter]","{dislikeBrowserContents}":"[data-kt-dislikes-browser-contents]","{report}":"[data-kt-report]","{viewreplies}":"[data-kt-view-reply]","{attachmentViewLink}":"[data-kt-attachment-viewlink]","{viewFeaturedReplies}":"[data-kt-view-featured-replies]"}},function(s,l){return{init:function(){window.kt.mobile||(s.initLikes("[data-kt-likes-wrapper]"),s.initLikes("[data-kt-dislikes-wrapper]"))},initRatings:function(t){jQuery(document).trigger("fd.init.ratings",[t.find("[data-fd-rating]")])},initLikes:function(t){const o=s.likeWrapper().next().html();fd.dropdown(t,{arrow:!1,appendTo:document.body,maxWidth:"none",role:"fd-dropdown",allowHTML:!0,theme:"fd-light",interactive:!0,onCreate:()=>{},onDestroy:()=>{},onHidden:()=>{},onMount:()=>{},onShow:e=>{if(!0!==e.state.fetching&&!1!==e.state.canFetch){const n=u(e.popper),i=n.find("[data-fd-dropdown-body]");var t=u(o).find("[data-fd-dropdown-body]").html();i.html(t),e.state.fetching=!0,e.state.canFetch=!1;const a=u(e.reference).data("commentid"),s=u(e.reference).data("action");Komento.ajax("site/views/comments/getLikedUsers",{id:a,type:s}).done(function(t){i.html(t);const r=i.find("[data-kt-liked-users-loadmore]");0<r.length&&r.off("click.kt.liked.loadmore").on("click.kt.liked.loadmore",function(){const i=u(this);var t=i.data("limit-start");const o=n.find("[data-kt-liked-users-list]");i.addClass("is-loading"),Komento.ajax("site/views/comments/loadmoreLikedUsers",{id:a,type:s,start:t}).done(function(t,e,n){o.append(t),i.data("limit-start",n),i.removeClass("is-loading"),e||r.remove()})}),e.state.fetching=!1,e.state.canFetch=!0})}},content:o,trigger:"mouseenter",placement:"bottom"})},insertRow:function(t,e,n){var i=(t=u(t)).data("depth");s.element.removeClass("is-empty");var o=0<t.find("[data-fd-rating]").length;if(null!=e&&""!=e&&"0"!=e){var r=s.fintInsertRowPosition(e,n);if(!1===r){if(r=s.element.find("[data-id="+e+"]"),1==i){const a=u(document.createElement("div"));a.addClass("kt-comments"),a.attr("data-kt-replies-"+e,""),a.append(t),a.insertAfter(r)}1!=i&&t.insertAfter(r)}else"latest"==n?t.insertBefore(r):t.insertAfter(r)}else"latest"==n?t.prependTo(s.element):t.appendTo(s.element);o&&s.initRatings(t),l.prism&&Prism.highlightAll()},fintInsertRowPosition:function(t,e){if(0<s.element.find("[data-parentid=kmt-"+t+"]").length){var n=null,n="latest"==e?s.element.find("[data-parentid=kmt-"+t+"]").first():s.element.find("[data-parentid=kmt-"+t+"]").last();return lastItemParentId=u(n).data("id"),0<s.element.find("[data-parentid=kmt-"+lastItemParentId+"]").length?s.fintInsertRowPosition(lastItemParentId,e):n}return!1},insertStylesheet:function(t){var e=u("head");e.find('link[rel="stylesheet"][href="'+t+'"]').length<1&&e.append('<link rel="stylesheet" href="'+t+'" type="text/css" />')},getWrapper:function(){return s.element.parents("[data-kt-wrapper]").controller()},getItem:function(t){return t.closest(s.item.selector)},"{attachmentViewLink} click":function(t,e){var n=s.getItem(t),i=(s.getWrapper(),n.data("id")),o=n.hasClass("attachment-open"),t=u('[data-kt-attachment-item-preview][data-id="'+i+'"]'),r=(s.attachmentViewLink(),n.find(t));o?n.hasClass("attachment-open expanded")?(r.addClass("t-hidden"),n.removeClass("expanded")):(r.removeClass("t-hidden"),n.addClass("expanded")):(r.addClass("is-loading"),Komento.ajax("site/views/comments/viewAttachmentItems",{id:i}).done(function(t){n.addClass("attachment-open expanded"),r.html(t),r.removeClass("is-loading")}))},"{deleteAttachment} click":function(t,e){var n=s.getItem(t),i=(n.data("id"),t.data("id")),o=t.parents(s.attachmentItem().selector);Komento.dialog({content:Komento.ajax("site/views/attachments/confirmDelete",{id:i}),bindings:{"{submit} click":function(){Komento.ajax("site/views/attachments/delete",{id:i}).done(function(){Komento.dialog().close(),o.remove(),n.find(s.attachmentItem.selector).length<=0&&s.attachmentWrapper().remove()})}}})},"{delete} click":function(t,e){var n=s.getItem(t),i=s.getWrapper(),o=n.data("id");Komento.dialog({content:Komento.ajax("site/views/comments/confirmDelete",{id:o}),bindings:{"{submit} click":function(){Komento.ajax("site/views/comments/delete",{id:o}).done(function(t,e){u.each(t,function(t,e){s.find("[data-id="+e+"]").remove()}),Komento.dialog().close();t=t.length+1;n.remove(),i.decreaseCounter(t)})}}})},clearNotifications:function(){u("[data-kt-alert]").html("").removeClass("error").addClass("t-hidden")},"{reply} click":function(t,e){var n=s.getWrapper().getForm(),t=s.getItem(t);s.clearNotifications(),n.reply(t)},"{edit} click":function(t,e){var r=s.getItem(t),n=r.data("id");r.addClass("is-editing");var i=r.find(s.editForm.selector),t=r.find("[data-kt-comment-content]");if(0<i.length)return i.removeClass("t-hidden"),void t.addClass("t-hidden");Komento.ajax("site/views/comments/edit",{id:n}).done(function(e,t){var n=(e=u(e)).find("[data-kt-editor]"),i=r.find("[data-kt-comment-content]").first();i.after(e),i.addClass("t-hidden"),Komento.bbcode&&FD.require().script("vendor/markitup").done(function(){jQuery(n).foundryMarkItUp(Komento.bbcodeButtons())}),n.expandingTextarea(),u(document).trigger("kt.init.emoji",[s.editForm.selector+" .fd-markitup-emoji"]),u(document).trigger("kt.init.giphy",[s.editForm.selector+" .fd-markitup-giphy"]),u(document).trigger("kt.init.tribute",[n.get()]);var o=s.editForm().find("[data-fd-rating]");0<o.length&&jQuery(document).trigger("fd.init.ratings",[o]),e.find(s.editCancel.selector).off("click").on("click",function(){e.addClass("t-hidden"),i.removeClass("t-hidden")}),n.off("keydown.save.comment").on("keydown.save.comment",function(t){(t.metaKey||t.ctrlKey)&&13==t.keyCode&&(e.find(s.editSave.selector).click(),t.preventDefault())})})},"{viewreplies} click":function(e,t){var n=e.data("id"),i=e.data("rownumber");e.find("a").addClass("is-loading"),e.find("a > span").addClass("t-hidden"),s.loadReplies(n,i).done(function(t){t&&((t=u.buildHTML(t)).insertAfter(e),0<t.find("[data-fd-rating]").length&&s.initRatings(t),l.prism&&Prism.highlightAll()),e.find("a").removeClass("is-loading"),e.find("a > span").removeClass("t-hidden"),e.addClass("t-hidden")})},loadReplies:function(t,e){var n=s.getWrapper();return Komento.ajax("site/views/comments/loadReplies",{component:n.component,cid:n.cid,sort:n.sort,parentid:t,rownumber:e,contentLink:n.contentLink})},"{report} click":function(t,e){var n=s.getItem(t).data("id");Komento.dialog({content:Komento.ajax("site/views/reports/confirmReport",{id:n}),bindings:{"{submit} click":function(){Komento.ajax("site/views/reports/report",{id:n}).done(function(){Komento.dialog().close()})}}})},"{publishButton} click":function(t,e){e.stopPropagation(),0<s.item.childs?s.showPublishDialog(t):s.publishComment(t)},"{unpublish} click":function(t,e){var n=s.getItem(t),i=n.data("id"),o=s.getWrapper();Komento.dialog({content:Komento.ajax("site/views/comments/confirmUnpublish",{id:i}),bindings:{"{submit} click":function(){Komento.ajax("site/views/comments/unpublish",{id:i}).done(function(){Komento.dialog().close();var t=s.item("[data-parentid="+i+"]"),e=t.length+1;t.remove(),n.remove(),o.decreaseCounter(e)})}}})},"{userExpand} click":function(t,e){t=s.getItem(t);t.removeClass("is-minimized"),t.removeClass("can-expand").addClass("can-minimize")},"{expand} click":function(t,e){var n=s.getItem(t),t=n.data("id");Komento.ajax("site/views/comments/expand",{id:t}).done(function(){n.removeClass("is-minimized"),n.removeClass("can-expand").addClass("can-minimize")})},"{minimize} click":function(t,e){var n=s.getItem(t),t=n.data("id");Komento.ajax("site/views/comments/minimize",{id:t}).done(function(){n.addClass("is-minimized"),n.removeClass("can-minimize").addClass("can-expand")})},"{viewFeaturedReplies} click":function(t,e){var n=s.find("[data-kt-replies-container]");n.length&&n.removeClass("t-hidden"),u(t).addClass("t-hidden")},"{pin} click":function(t,e){var n=s.getItem(t),i=n.data("id"),o=s.getWrapper().find("[data-kt-comments-pinned]").length;Komento.dialog({content:Komento.ajax("site/views/comments/confirmPin",{id:i}),bindings:{"{submit} click":function(){Komento.ajax("site/views/comments/pin",{id:i,hasFeatured:o}).done(function(t){n.remove();var e=u("[data-kt-replies-"+i+"]");void 0!==e&&e.remove(),o?u(t).appendTo("[data-kt-comments-pinned]"):(u(t).prependTo("[data-kt-comments-container]"),u("[data-kt-comments-pinned]").implement(Komento.Controller.Comments.List,{prism:l.prism,cleanGist:!0})),Komento.dialog().close()})}}})},"{unpin} click":function(t,e){var n=s.getItem(t),i=n.data("id");s.getWrapper();Komento.dialog({content:Komento.ajax("site/views/comments/confirmUnpin",{id:i}),bindings:{"{submit} click":function(){Komento.ajax("site/views/comments/unpin",{id:i}).done(function(){n.removeClass("is-featured"),n.remove();var t=u("[data-kt-replies-"+i+"]");void 0!==t&&t.remove(),Komento.dialog().close()})}}})},"{submitSpam} click":function(t,e){var n=s.getItem(t),i=n.data("id"),o=s.getWrapper();Komento.dialog({content:Komento.ajax("site/views/comments/confirmSubmitSpam",{id:i}),bindings:{"{submit} click":function(){Komento.ajax("site/views/comments/submitSpam",{id:i}).done(function(){Komento.dialog().close();var t=s.item("[data-parentid="+i+"]"),e=t.length+1;t.remove(),n.remove(),o.decreaseCounter(e)})}}})},"{permalink} click":function(t,e){t=s.getItem(t).data("id");s.getWrapper().scrollToComment(t)},updateLike:function(t,e){var n=t.find("[data-kt-likes-wrapper]").first(),i=t.find("[data-kt-likes-counter]").first(),t=parseInt(i.text());if("unlike"===e)return n.removeClass("text-success-500 is-liked").addClass("text-gray-500"),void i.text(t-1);n.removeClass("text-gray-500").addClass("text-success-500 is-liked"),i.text(t+1)},updateDislike:function(t,e){var n=t.find("[data-kt-dislikes-wrapper]").first(),i=t.find("[data-kt-dislikes-counter]").first(),t=parseInt(i.text());if("removedislike"===e)return n.removeClass("text-danger-500 is-disliked").addClass("text-gray-500"),void i.text(t-1);n.removeClass("text-gray-500").addClass("text-danger-500 is-disliked"),i.text(t+1)},"{like} click":function(t,e){var n=s.getItem(t),i=n.find("[data-kt-likes-wrapper]").first().hasClass("is-liked")?"unlike":"like";Komento.ajax("site/views/likes/action",{type:i,id:n.data("id")}).done(function(t){s.updateLike(n,i),"removedislike"===t&&s.updateDislike(n,"removedislike")})},"{dislike} click":function(t,e){var n=s.getItem(t),i=n.find("[data-kt-dislikes-wrapper]").first().hasClass("is-disliked")?"removedislike":"dislike";Komento.ajax("site/views/likes/action",{type:i,id:n.data("id")}).done(function(t){s.updateDislike(n,i),"unlike"===t&&s.updateLike(n,"unlike")})},"{likeViewAll} click":function(t){t=t.data("id");Komento.dialog({content:Komento.ajax("site/views/likes/browseAll",{id:t})})}}}),e.resolve()})})}),Komento.module("site/comments/wrapper",function(t){var e=this;FD.require().script("vendor/prism").done(function(){Komento.require().library("scrollTo").script("site/comments/list").done(function(d){Komento.Controller("Wrapper",{defaults:{component:null,cid:null,currentUrl:null,"{sortButton}":"[data-kt-sort]","{sortLabel}":"[data-kt-sort-label]","{form}":"[data-kt-form]","{comments}":"[data-kt-comments]","{pinned}":"[data-kt-comments-pinned]","{loadMore}":"[data-kt-loadmore]","{counter}":"[data-kt-counter]","{subscribe}":"[data-kt-subscribe]","{unsubscribe}":"[data-kt-unsubscribe]"}},function(u,c){return{init:function(){var t;c.component=u.element.data("component"),c.cid=u.element.data("cid"),c.currentUrl=u.element.data("url"),u.component=c.component,u.cid=c.cid,u.currentUrl=c.currentUrl,u.contentLink=c.contentLink,u.sort=c.sort,c.live={enabled:1==u.element.data("live"),interval:parseInt(u.element.data("live-interval"))},c.live.enabled&&!c.guest&&(c.timer=1e3*c.live.interval,u.monitorNewComments()),c.initList&&(d("[data-kt-comments]").implement(Komento.Controller.Comments.List,{prism:c.prism}),d("[data-kt-comments-pinned]").implement(Komento.Controller.Comments.List,{prism:c.prism})),window.location.hash&&(t=window.location.hash.substring(1),u.processFragments(t))},processFragments:function(t){var e,n,i,o=t.split("comments_");1<o.length?u.getComments(o[1]):0<=o[0].indexOf("comment-")&&(n=(e=o[0].split("comment-")[1].split(","))[0],i=e[1],t=0,null!=e[2]&&(t=e[2]),o="",null!=e[3]&&(o=e[3]),u.getComments(t,n,i,o))},excludeIds:[],monitorNewComments:function(){FD.require().script("vendor/toast").done(function(){setInterval(function(){Komento.ajax("site/views/comments/check",{component:c.component,cid:c.cid,lastchecktime:c.lastchecktime,excludeIds:u.excludeIds}).done(function(t,i){if(0<t.length){const o=u.comments();o.removeClass("is-empty"),t.forEach(function(t,e){const n=d(t.html);o.controller().insertRow(n,t.parent_id,i.sorting),fd.toast(t.message,{avatar:t.avatar,background:"#F9F9FA",scrollTo:n.find(".kt-comment"),scrollBehavior:"inline"!==i.placement?"auto":"smooth",icon:"fdi far fa-comment-dots"}),u.excludeIds.push(t.id)})}})},c.timer)})},getCurrentUrl:function(){return c.currentUrl},getTotal:function(){return parseInt(u.counter().text())},scrollToComment:function(t){var e="#comment-"+t;setTimeout(function(){d(document).scrollTo(e)},150)},setCounter:function(t){u.counter().text(t)},increaseCounter:function(t){void 0===t&&(t=1);t=u.getTotal()+t;u.setCounter(t)},decreaseCounter:function(t){void 0===t&&(t=1);t=u.getTotal()-t;u.setCounter(t)},getForm:function(){return u.form().controller()},getComments:function(t,o,r,a){var s=!1;null==a||""==a?a=u.sort:(u.sort=a,s=!0);var l=d.Deferred();0<t||s?(u.loadMore().addClass("disabled").attr("disabled","disabled"),u.comments().find("[data-kt-comment-item]").remove(),u.comments().addClass("is-loading"),Komento.ajax("site/views/comments/loadComments",{component:u.component,cid:u.cid,endlimit:t,sort:a,contentLink:u.contentLink,sticked:"0"}).done(function(t,e){var n,t=d(t),i=0<u.comments().find("[data-kt-comment-item]").length?"prepend":"append";"prepend"==i&&(n=u.comments().find("[data-kt-comment-item]").last(),t.insertBefore(n)),"append"==i&&t.appendTo(u.comments()),u.comments().controller().initRatings(u.comments()),c.prism&&Prism.highlightAll(),"-1"!=e?(u.loadMore().removeClass("is-loading disabled").removeAttr("disabled").show(),u.loadMore().attr("href","#comments_"+e),u.loadMore().data("nextstart",e)):u.loadMore().hide(),s&&(u.sortButton().parent().removeClass("is-active"),d('[data-kt-sort="'+a+'"]').parent().addClass("is-active")),l.resolve(o,r)}).fail(function(){l.resolve(o,r)}).always(function(){u.comments().removeClass("is-loading")})):l.resolve(o,r),l.done(function(e,t){var n,i,o;null!=e&&e&&(0<d("#comment-"+e).length?u.scrollToComment(e):null==t||!t||0<(n=d('[data-kt-view-reply][data-id="'+t+'"]')).length&&(t=n.data("id"),i=n.data("rownumber"),void 0!==(o=u.comments().controller())&&o.loadReplies(t,i).done(function(t){d(t).insertAfter(n),0<d(t).find("[data-fd-rating]").length&&o.initRatings(d(t)),c.prism&&Prism.highlightAll(),n.find("a").removeClass("is-loading"),n.find("a > span").removeClass("t-hidden"),n.addClass("t-hidden"),d(document).scrollTo("#comment-"+e)})))})},"{loadMore} click":function(t,e){u.loadMore().addClass("is-loading").attr("disabled",!0),t=t.data("nextstart"),Komento.ajax("site/views/comments/loadmore",{component:u.component,cid:u.cid,start:t,sort:u.sort,contentLink:u.contentLink}).done(function(t,e){const n=u.comments().controller(),i=d.buildHTML(t);i.insertAfter(u.comments().find("[data-kt-comment-item]").last()),0<i.find("[data-fd-rating]").length&&n.initRatings(i),c.prism&&Prism.highlightAll(),"-1"!=e?(u.loadMore().removeClass("is-loading").removeAttr("disabled"),u.loadMore().attr("href","#comments_"+e),u.loadMore().data("nextstart",e)):u.loadMore().hide()})},"{sortButton} click":function(t,e){var n=t.data("kt-sort"),i=t.text();u.sort!==n&&(u.sortLabel().text(i),u.sortButton().parent().removeClass("is-active"),t.parent().addClass("is-active"),u.getComments(0,0,0,n))},"{subscribe} click":function(t,e){Komento.dialog({content:Komento.ajax("site/views/subscriptions/subscribe",{component:c.component,cid:c.cid,currentUrl:c.currentUrl}),bindings:{"{submit} click":function(){return""==this.name().val()?(this.name().parents(".o-form-group").addClass("has-error"),!1):""==this.email().val()?(this.email().parents(".o-form-group").addClass("has-error"),!1):void this.form().submit()}}})},"{unsubscribe} click":function(t,e){Komento.dialog({content:Komento.ajax("site/views/subscriptions/confirmUnsubscribe",{component:c.component,cid:c.cid,currentUrl:c.currentUrl}),bindings:{"{submit} click":function(){this.form().submit()}}})}}}),e.resolve()})})}),Komento.module("site/common",function(e){var t=e.fn.hide,n=e.fn.show;e.fn.hide=function(){return t.apply(this,arguments),this.addClass("hidden"),this},e.fn.show=function(){return n.apply(this,arguments),this.removeClass("hidden"),this},e.fn.scroll=function(){var t;t=this,e.scrollTo(t,500)},e.fn.highlight=function(){return this.effect("highlight",{color:"#FDFFE0"},2e3),this},e.fn.enable=function(){return this.removeClass("disabled"),this},e.fn.disable=function(){return this.addClass("disabled"),this},e.fn.switchOn=function(){return this.removeClass("cancel"),this},e.fn.switchOff=function(){return this.addClass("cancel"),this},e.fn.checkSwitch=function(){return!this.hasClass("cancel")},e.fn.checkClick=function(){return!this.hasClass("disabled")&&(this.addClass("disabled"),!0)},e.fn.exists=function(){return 0<this.length},this.resolve()}),Komento.module("site/dashboard/default",function(n){Komento.Controller("Dashboard",{defaults:{"{checkAll}":"[data-kt-dashboard-checkall]","{actions}":"[data-kt-dashboard-actions]","{filter}":"[data-kt-filter]","{form}":"[data-dashboard-form]","{task}":"[data-fd-table-task=komento]","{apply}":"[data-kt-apply]","{action}":"[data-action]","{item}":"[data-kt-dashboard-item]","{checkbox}":"[data-kt-dashboard-item-checkbox]"}},function(i,o){return{getItems:function(t){var e=i.checkbox(":checked");return void 0!==t?e:e.map(function(){return this.value}).get()},"{checkbox} change":function(t,e){t.is(":checked"),t.parents(i.item.selector);if(0<i.checkbox(":checked").length)return i.filter().addClass("t-hidden"),void i.actions().removeClass("t-hidden");i.filter().removeClass("t-hidden"),i.actions().addClass("t-hidden")},deleteComments:function(t,e){var n=this.getItems();console.log(n),n&&Komento.dialog({content:Komento.ajax("site/views/dashboard/confirmDelete",{items:n,return:o.return})})},spam:function(){var t=this.getItems();t&&Komento.dialog({content:Komento.ajax("site/views/dashboard/confirmSpam",{items:t,return:o.return})})},removeSpam:function(){var t=this.getItems();t&&Komento.dialog({content:Komento.ajax("site/views/dashboard/confirmRemoveSpam",{items:t,return:o.return})})},clearReports:function(){var t=this.getItems();t&&Komento.dialog({content:Komento.ajax("site/views/dashboard/confirmClearReports",{items:t,return:o.return})})},moderate:function(t){var e=this.getItems();e&&Komento.dialog({content:Komento.ajax("site/views/dashboard/confirmModerate",{items:e,return:o.return,action:t})})},"{filter} change":function(){i.form().submit()},"{checkAll} change":function(t,e){t=t.is(":checked");i.checkbox().prop("checked",t),i.checkbox().trigger("change")},"{item} click":function(t,e){t=t.find(i.checkbox.selector),t.is(":checked");n(e.target).is(i.checkbox.selector)||(t.is(":checked")?t.removeAttr("checked"):t.prop("checked","checked")).trigger("change")},"{apply} click":function(t,e){var n=i.action().val();"delete"!==n?"spam"!==n?"notspam"!==n?"clear"!==n?"approve"!==n?"reject"!==n?(i.task().val(i.action().val()),i.form().submit()):i.moderate("reject"):i.moderate("approve"):i.clearReports():i.removeSpam():i.spam():i.deleteComments()}}}),this.resolve()}),Komento.module("site/dashboard/item",function(i){Komento.Controller("Dashboard.Item",{defaults:{commentId:0}},function(n){return{unpublishComment:function(){var t=n.options.commentId.split("-")[1];Komento.ajax("site/views/comments/unpublish",{id:t}).done(function(){n.closeDialog(),n.unpublishChild(n.element.attr("id")),n.statusButton().text(i.language("COM_KOMENTO_UNPUBLISHED")),n.publishButton().show(),n.unpublishButton().hide(),n.statusOptions().hide()})},unpublishChild:function(t){var e=i.language("COM_KOMENTO_UNPUBLISHED");i('li[parentid="'+t+'"]').each(function(){i(this).find(".kmt-status").text(e),i(this).find(".kmt-unpublish").hide(),i(this).find(".kmt-publish").show(),n.unpublishChild(i(this).attr("id"))})}}}),this.resolve()}),Komento.module("site/form/attachments",function(t){var e=this;Komento.require().library("plupload").done(function(s){Komento.Controller("Uploader",{defaults:{uploadUrl:s.indexUrl+"?option=com_komento&controller=file&tmpl=component&task=upload&component="+Komento.component,uploadedId:[],types:{image:["jpg","png","gif","jpeg"],archive:["zip","rar","gz","gzip"]},"{uploader}":"[data-kt-attachments-form]","{uploadButton}":"[data-kt-attachments-button]","{attachmentWrapper}":"[data-kt-attachments-wrapper]","{attachmentList}":"[data-kt-attachments-list]","{template}":"[data-kt-attachments-item][data-template]","{item}":"[data-kt-attachments-item]","{counter}":"[data-kt-attachments-counter]","{removeFile}":"[data-fd-attachment-delete]"}},function(r,a){return{init:function(){var t;r.initTemplate(),r.uploader().implement("plupload",{settings:{runtimes:"html5",url:r.options.uploadUrl+"&"+Komento.token()+"=1",max_file_size:a.upload_max_size,filters:[{title:"Allowed File Type",extensions:a.extensions}]},"{uploader}":r.uploader.selector,"{uploadButton}":r.uploadButton.selector},function(){r.plupload=this.plupload}),a.files&&(t=JSON.parse(a.files),s.each(t,function(t,e){r.loadTemplate(e)}))},loadTemplate:function(t){var e=parseInt(t.size/1024),n=r.getAttachmentType(t.name),n=r.getItemTemplate({id:t.id,title:t.name,size:e,type:n});r.attachmentWrapper().removeClass("t-hidden"),r.attachmentList().append(n)},resetForm:function(){a.uploadedId=[],r.item().each(function(t,e){e=s(e);r.removeItem(e)})},getUploadedIds:function(){return a.uploadedId},initTemplate:function(){a.itemTemplate=r.template().clone(),r.template().remove()},getItemTemplate:function(t){var e=a.itemTemplate.clone();return e.removeAttr("data-template"),e.attr("id",t.id),e.find("[data-fd-attachment-size]").html(t.size),e.find("[data-fd-attachment-title]").html(t.title),e.find("[data-fd-attachment-preview]").addClass("is-icon is-icon--"+t.type),e.removeClass("t-hidden"),e.data("file",t),e},hasItems:function(){return 0<a.uploadedId.length},startUpload:function(){0<r.plupload.files.length?r.plupload.start():r.parent.saveComment()},existInArray:function(t,e){var n=!1;if(e.length)for(var i=0;e.length>i;i++)if(t.toLowerCase()==e[i].toLowerCase()){n=!0;break}return n},getAttachmentType:function(t){var e=t.substr(t.lastIndexOf(".")+1),t="doc";return r.existInArray(e,r.options.types.image)&&(t="img"),t=r.existInArray(e,r.options.types.archive)?"zip":t},addFiles:function(t){t.length<1||(r.parent.clearNotifications(),s.each(t,function(t,e){return r.plupload.files.length>a.upload_max_files?(r.plupload.removeFile(e),!0):1!=e.status||void r.loadTemplate(e)}))},removeItem:function(t){t.remove();var e=t.attr("id"),t=r.plupload.getFile(e);r.plupload.removeFile(t),r.parent.removeFile(e),r.item().length||r.attachmentWrapper().addClass("t-hidden")},"{uploader} FilesAdded":function(t,e,n,i){r.addFiles(i)},"{uploader} UploadComplete":function(t,e,n,i){r.parent.saveComment()},"{uploader} FileUploaded":function(t,e,n,i,o){if(1==o.status&&a.uploadedId.push(o.id),"notallowed"==o.status)return r.plupload.stop(),void r.kmt.form.errorNotification(s.language("COM_KOMENTO_FORM_NOTIFICATION_UPLOAD_NOT_ALLOWED"));"exceedfilesize"==o.status&&(r.plupload.stop(),r.kmt.form.errorNotification(s.language("COM_KOMENTO_FORM_NOTIFICATION_MAX_FILE_SIZE",Komento.options.config.upload_max_size+"mb")))},"{uploader} QueueChanged":function(t,e,n){r.counter().text(n.files.length)},"{uploader} Error":function(t,e,n,i){r.parent.clearNotifications(),-600===i.code&&r.parent.notification(i.message,"error")},"{removeFile} click":function(t){t=t.parents(r.item().selector);r.removeItem(t)}}}),e.resolve()})}),Komento.module("site/form/form",function(t){var e=this;Komento.require().library("expanding","scrollTo").script("site/form/location","site/form/attachments").done(function(l){Komento.Controller("Form",{defaults:{"{form}":"[data-kt-form-element]","{parentId}":"[data-kt-parent]","{terms}":"[data-kt-terms]","{ratingReset}":"[data-fd-rating-reset]","{loginButton}":"[data-kt-login]","{loginForm}":"[data-kt-login-form]","{userInfo}":"[data-kt-userinfo]","{postAsGuest}":"[data-kt-post-as-guest]","{editorWrapper}":"[data-editor-wrapper]","{editor}":"[data-kt-editor]","{cancel}":"[data-kt-cancel]","{save}":"[data-kt-submit]","{editSaveButton}":"[data-kt-edit-save]","{viewTnc}":"[data-kt-tnc-view]","{tncCheckbox}":"[data-kt-terms]","{location}":"[data-kt-location]","{attachments}":"[data-kt-attachments]","{alert}":"[data-kt-alert]","{recaptchaResponse}":"[data-kt-recaptcha-response]","{counter}":"[data-kt-text-counter]"}},function(s,i){return{init:function(){i.location&&s.initLocation(),i.attachments.enabled&&s.initAttachments(),void 0===i.isEdit&&(s.initEditor(),s.resetForm()),s.originalComment=s.editor().val()},getLocationController:function(){return s.location().controller(Komento.Controller.Location.Form)},getAttachmentsController:function(){return s.attachments().controller(Komento.Controller.Uploader)},getWrapper:function(){var t=s.element.parents("[data-kt-wrapper]");return(t=void 0===t.controller()?l(document.body).find("[data-kt-wrapper]"):t).controller()},getCommentsList:function(){return this.getWrapper().comments()},initEditor:function(){i.bbcode&&FD.require().script("vendor/markitup").done(function(){jQuery(s.editor()).foundryMarkItUp(i.markupSet()),s.editor().expandingTextarea()})},initAttachments:function(){s.attachments().addController(Komento.Controller.Uploader,{upload_max_size:i.attachments.upload_max_size,upload_max_files:i.attachments.upload_max_files,extensions:i.attachments.extensions,files:i.attachments.files,"{parent}":this})},initLocation:function(){s.location().addController(Komento.Controller.Location.Form,{"{parent}":this,location_key:i.location_key,isEdit:i.isEdit})},insertText:function(t,e){var e=null==e?0:e,n=s.editor().val(),n=0==e?t+n:n.substring(0,e)+t+n.substring(e,n.length);s.editor().val(n),s.editor().focus(),s.updateCommentLength()},resetForm:function(){s.editor().val(""),0!=s.parentId().val()&&s.cancel().click(),s.counter().text("0"),0<s.location().length&&void 0!==s.getLocationController()&&s.getLocationController().removeLocation(),i.attachments.enabled&&void 0!==s.getAttachmentsController()&&s.getAttachmentsController().resetForm(),0<s.ratingReset().length&&jQuery(s.ratingReset.selector).trigger("click"),s.save().removeAttr("disabled").removeClass("is-loading")},updateCommentLength:function(){s.counter().text(s.editor().val().length)},saveState:l.Deferred(),"{save} click":function(t,e){editItem=!1,e.preventDefault(),e.stopPropagation(),t.attr("disabled",!0).addClass("is-loading"),s.clearNotifications();e=[];t.trigger("onSubmitComment",[e]),e.length<=0?s.saveState.resolve():l.when.apply(null,e).done(function(){s.saveState.resolve()}).fail(function(){s.saveState.reject()}),s.saveState.done(function(){i.attachments.enabled?s.getAttachmentsController().startUpload():s.saveComment()})},editItem:null,"{editSaveButton} click":function(t,e){e.preventDefault(),e.stopPropagation(),editItem=t.closest("[data-kt-comment-item]"),i.attachments.enabled?s.getAttachmentsController().startUpload():s.saveEdit()},filesRemoved:[],originalComment:"",removeFile:function(t){s.filesRemoved.push(t)},saveEdit:function(){var r=editItem.find("[data-kt-comment-content]"),t=!1,a=editItem.find(i.formElement),e=a.serializeObject();if(e.id=editItem.data("id"),s.originalComment!==e.comment&&(t=!0),i.attachments.enabled&&(e.attachments=s.getAttachmentsController().getUploadedIds(),e.filesRemoved=s.filesRemoved,(0<e.filesRemoved.length||0<e.attachments.length)&&(t=!0)),0<s.location().length){const n=s.getLocationController();n.updated&&(t=!0,a.find("[data-kt-location-button]").html(n.address().val()))}if(!1===(t=i.currentRating!==e.ratings?!0:t))return a.addClass("t-hidden"),void r.removeClass("t-hidden");""===e.ratings&&delete e.ratings,Komento.ajax("site/views/comments/save",l.extend({},e)).done(function(t,e,n,i,o){r.html(e),editItem.find("[data-kt-attachment-wrapper]").html(n),editItem.find("[data-kt-location-wrapper]").html(i),editItem.find("[data-kt-ratings-wrapper]").html(o);o=editItem.find("[data-fd-rating]");0<o.length&&jQuery(document).trigger("fd.init.ratings",[o]);o=editItem.find("[data-kt-comment-edited]").first();0<o.length&&(editItem.addClass("is-edited"),o.html(t)),a.addClass("t-hidden"),r.removeClass("t-hidden")})},saveComment:function(){var r,t;editItem?s.saveEdit():(r=s.element.find(i.formElement).serializeObject(),i.attachments.enabled&&(r.attachments=s.getAttachmentsController().getUploadedIds()),t=s.getWrapper(),r.component=t.component,r.cid=t.cid,r.contentLink=t.contentLink,r.parent_id=s.parentId().val(),r.tnc=s.tncCheckbox().is(":checked"),r.recaptchaResponse=s.recaptchaResponse().val(),Komento.ajax("site/views/comments/add",l.extend({},r)).done(function(t,e,n,i){1==n&&s.getWrapper().increaseCounter();var o=s.getCommentsList(),e=l(e);3==n&&s.notification(t,"warning"),3!=n&&(0<o.length&&o.controller().insertRow(e,r.parent_id,i),type=2==n?"info":"success",s.notification(t,type)),s.resetForm(),s.reloadCaptcha(),l("[data-kt-comments-container]").removeClass("is-empty")}).fail(function(t){s.notification(t,"danger")}).always(function(){s.save().removeAttr("disabled").removeClass("is-loading")}))},reloadCaptcha:function(){if(i.recaptcha_invisible)return s.saveState=l.Deferred(),void s.save().trigger("onReloadCaptcha");i.showCaptcha&&(i.recaptcha?grecaptcha.reset():s.trigger("onReloadCaptcha"))},reply:function(t){s.resetForm();var e=t.data("id");parseInt(t.data("depth"));s.parentId().val(e),s.element.addClass("is-replying").appendTo(t),s.isCompactForm()||s.element.scroll()},notification:function(t,e){"error"===e&&(e="danger"),s.alert().removeClass("o-alert--success o-alert--danger o-alert--warning o-alert--info o-alert--error").addClass("o-alert--"+e).html(t).removeClass("t-hidden")},closeNotification:function(){s.alert().addClass("t-hidden")},clearNotifications:function(){s.alert().html("").addClass("t-hidden")},getCompactFormWrapper:function(){return s.element.parents("[data-kt-wrapper]").find("[data-kt-compact-form]")},isCompactForm:function(){return 0<s.getCompactFormWrapper().length},"{loginButton} click":function(){s.loginForm().removeClass("t-hidden"),s.userInfo().addClass("t-hidden"),s.postAsGuest().replaceWith(function(){return'<a href="javascript:void(0);" data-kt-post-as-guest>'+l(this).text()+"</a>"}),s.loginButton().replaceWith(function(){return"<span data-kt-login>"+l(this).text()+"</span>"})},"{postAsGuest} click":function(){s.loginForm().addClass("t-hidden"),s.userInfo().removeClass("t-hidden"),s.postAsGuest().replaceWith(function(){return"<span data-kt-post-as-guest>"+l(this).text()+"</span>"}),s.loginButton().replaceWith(function(){return'<a href="javascript:void(0);" data-kt-login>'+l(this).text()+"</a>"})},"{viewTnc} click":function(){Komento.dialog({content:Komento.ajax("site/views/comments/terms")})},"{editor} keydown":function(t,e){(e.metaKey||e.ctrlKey)&&13==e.keyCode&&(s.save().click(),e.preventDefault())},"{editor} keyup":function(t){s.updateCommentLength()},"{cancel} click":function(t,e){s.parentid=0,s.parentId().val("");var n=(n=s.getWrapper()).element;s.isCompactForm()&&(n=s.getCompactFormWrapper()),s.resetForm(),s.element.removeClass("is-replying"),s.element.appendTo(n)},"{captchaReload} click":function(){s.reloadCaptcha()}}}),e.resolve()})}),Komento.module("site/form/location",function(t){var e=this;Komento.require().library("ui/autocomplete").done(function(a){Komento.Controller("Location.Form",{defaultOptions:{language:"en",initialLocation:null,searchMode:"detect",geomode:"native","{button}":"[data-kt-location-button]","{form}":"[data-kt-location-form]","{address}":"[data-location-address]","{latitude}":"[data-location-lat]","{longitude}":"[data-location-lng]","{detect}":"[data-location-detect]","{remove}":"[data-location-remove]"}},function(o,r){return{tip:null,loading:!1,updated:!1,init:function(){void 0===o.options.isEdit&&o.resetForm(),navigator.geolocation&&window.kt.isHttps&&o.detect().removeClass("t-hidden"),navigator.geolocation||(r.geomode="external"),r.geomode="native";var t=a.uid("ext");window[t]=function(){a.___GoogleMaps.resolve()},a.___GoogleMaps||(a.___GoogleMaps=a.Deferred(),void 0===window.google||void 0===window.google.maps?Komento.require().script({prefetch:!1},"https://maps.googleapis.com/maps/api/js?sensor=true&language="+o.options.language+"&callback="+t+"&key="+r.location_key):a.___GoogleMaps.resolve()),a.___GoogleMaps.done(function(){o._init()})},resetForm:function(){o.locationResolved=!1,o.latitude().val(""),o.longitude().val(""),o.address().val(""),o.remove().addClass("t-hidden")},_init:function(){o.geocoder=new google.maps.Geocoder,o.hasGeolocation=void 0!==navigator.geolocation,o.hasGeolocation?o.detect().show():o.detect().remove(),o.address().addClass("location-suggestion");var t=a.trim(o.options.initialLocation);t&&o.getLocationByAddress(t,function(t){o.setLocation(t[0])}),o.busy(!1)},busy:function(t){o.address().toggleClass("is-loading",t),o.detect().removeClass("is-loading")},getUserLocations:function(e){o.getLocationAutomatically(function(t){o.userLocations=o.buildDataset(t),e&&e(t)})},getLocationByAddress:function(t,e){o.geocoder.geocode({address:t},e)},getLocationByCoords:function(t,e,n){o.geocoder.geocode({location:new google.maps.LatLng(t,e)},n)},getLocationAutomatically:function(e,t){if(!navigator.geolocation)return fail("ERRCODE","Browser does not support geolocation or do not have permission to retrieve location data.");navigator.geolocation.getCurrentPosition(function(t){o.getLocationByCoords(t.coords.latitude,t.coords.longitude,e)},t)},setLocation:function(t){t&&(o.locationResolved=!0,o.lastResolvedLocation=t,o.address().val(t.formatted_address),o.latitude().val(t.geometry.location.lat()),o.longitude().val(t.geometry.location.lng()))},removeLocation:function(){o.resetForm()},buildDataset:function(t){return a.map(t,function(t){return{label:t.formatted_address,value:t.formatted_address,location:t}})},suggest:function(t){if(o.busy(!0),!o.loading){null!==o.tip&&o.tip.hide();const i=o.address().width();var e=tippy("[data-location-address]",{content:t=>t.nextElementSibling.innerHTML,onShow(n){a(n.popper).css("width",i),o.loading||(o.loading=!0,("detect"===r.searchMode?o.search().done(a.debounce(function(t){const e=a(n.popper).find("[data-fd-dropdown-body]");e.html(t);t=e.find("[data-location-suggestion]");0<t.length&&t.on("click",function(){var t=a(this).data("location-suggestion-latitude"),e=a(this).data("location-suggestion-longitude"),n=a(this).data("location-suggestion-value");o.latitude().val(t),o.longitude().val(e),o.address().val(n),o.tip.hide(),o.updated=!0,o.remove().removeClass("t-hidden")})},50)).fail(function(t){}):o.searchManual(t).done(a.debounce(function(t){const e=a(n.popper).find("[data-fd-dropdown-body]");e.html(t);t=e.find("[data-location-suggestion]");0<t.length&&t.on("click",function(){var t=a(this).data("location-suggestion-latitude"),e=a(this).data("location-suggestion-longitude"),n=a(this).data("location-suggestion-value");o.latitude().val(t),o.longitude().val(e),o.address().val(n),o.tip.hide(),o.updated=!0,o.remove().removeClass("t-hidden")})},100)).fail(function(t){})).always(function(){o.loading=!1}))},placement:"bottom",maxWidth:i,role:"fd-dropdown",allowHTML:!0,theme:"fd-light",trigger:"manual",arrow:!1,interactive:!0,appendTo:document.body});o.tip=e[0],o.tip.show()}},search:function(){return o.getUserCoords().then(function(t){return Komento.ajax("site/views/comments/getLocations",{latitude:t.latitude,longitude:t.longitude})}).fail(function(t){}).always(function(){})},searchManual:a.memoize(function(t){var e=a.Deferred();return Komento.ajax("site/views/comments/getLocations",{query:t}).done(function(){e.resolve()}).always(function(){})}),userCoords:null,getUserCoords:function(){var e=a.Deferred(),t=o.userCoords;return t?(e.resolve(t),e):("native"===r.geomode?navigator.geolocation.getCurrentPosition(function(t){t=t.coords;e.resolve({latitude:t.latitude,longitude:t.longitude})},function(){o.getUserCoordsByIP().done(e.resolve).fail(e.reject)}):e=o.getUserCoordsByIP(),e.done(function(t){o.userCoords=t}))},getUserCoordsByIP:function(){a.getJSON("//www.telize.com/geoip?callback=?").then(function(t){return{latitude:t.latitude,longitude:t.longitude}})},suggestUserLocations:function(){o.hasGeolocation&&o.userLocations&&(o.resetForm(),r.searchMode="detect",o.suggest()),o.busy(!1)},"{button} click":function(t,e){t.toggleClass("is-active"),o.form().toggleClass("t-hidden")},"{detect} click":function(){o.busy(!0),o.detect().addClass("is-loading"),r.searchMode="detect",o.suggest()},"{remove} click":function(){o.resetForm()},"{address} keypress":function(t){t.keypress(function(t){if(13==t.which)return!1})},"{address} keyup":a.debounce(function(t){t=t.val();r.searchMode="manual",t&&""!=a.trim(t)&&o.suggest(t)},300)}}),e.resolve()})}),Komento.require().script("site/common","shared/elements").library("dialog").done(function(t){}),Komento.module("site/structure/structure",function(r){Komento.Controller("Structure",{defaults:{cid:"",component:"",type:"","{toggleButton}":"[data-kt-toggle]"}},function(i,o){return{init:function(){i.initArea(),"inline"!==o.type&&r(document.body).addClass("has-kt-compact-"+o.type),!0===o.initialLoad&&i.loadComments()},initArea:function(){var t=i.getWrapper();"inline"===o.type?t.appendTo(i.element):t.appendTo(r(document.body)),t.find("[data-kt-compact-close]").on("click",function(){i.toggleComments()})},loadComments:function(){var e=r.Deferred();return i.reset(),i.showLoader(),Komento.ajax("site/views/comments/fetchComments",o).done(function(t){t=r.buildHTML(t);i.updateContent(t),i.hideLoader(),e.resolve()}),e},getWrapper:function(){return r('[data-kt-compact-wrapper][data-component="'+o.component+'"][data-cid="'+o.cid+'"][data-type="'+o.type+'"]')},wrapperHasContent:function(){return 0<i.getWrapper().find("[data-kt-container-content]").html().length},updateContent:function(t){var e,n=i.getWrapper().find("[data-kt-container-content]");n.html(t),"inline"!==o.type&&(e=n.find("[data-kt-perfectscroll]")[0],FD.require().script("vendor/perfectscrollbar").done(function(){new PerfectScrollbar(e,{suppressScrollX:!0})})),FD.require().script("vendor/lightbox").done(function(){r(n).on("click","a[rel^=lightbox], area[rel^=lightbox], a[data-fd-lightbox], area[data-lightbox]",function(t){return lightbox.start(r(t.currentTarget)),!1})});t=n.find("[data-fd-rating]");0<t.length&&jQuery(document).trigger("fd.init.ratings",[t])},toggleComments:function(){r("[data-kt-compact-wrapper]").not(i.getWrapper()).addClass("is-hide"),i.getWrapper().toggleClass("is-hide"),i.getWrapper().hasClass("is-hide")?fd.toggleScrollLock(!1):fd.toggleScrollLock(!0)},hideArea:function(){r("[data-kt-compact-wrapper]").addClass("is-hide")},showArea:function(){r("[data-kt-compact-wrapper]").not(i.getWrapper()).addClass("is-hide"),i.getWrapper().removeClass("is-hide")},showLoader:function(){i.getWrapper().find("[data-kt-loader]").removeClass("t-hidden")},hideLoader:function(){i.getWrapper().find("[data-kt-loader]").addClass("t-hidden")},reset:function(){r(document).find("[data-kt-container-content]").html(""),r(document).find("[data-kt-wrapper]").each(function(t,e){e=r(e);void 0!==e.controller()&&e.removeController()})},"{toggleButton} click":function(t,e){if(e.preventDefault(),e.stopPropagation(),i.wrapperHasContent())return i.toggleComments(),!0;i.showArea(),i.loadComments(),fd.toggleScrollLock(!0)}}}),this.resolve()}),Komento.module("site/subscriptions/default",function(o){Komento.Controller("Subscriptions",{defaults:{userid:0,"{checkAll}":"[data-kt-subscriptions-checkall]","{actions}":"[data-kt-subscriptions-actions]","{form}":"[data-subscriptions-form]","{task}":"[data-fd-table-task=komento]","{actionUnsubscribe}":"[data-kt-unsubscribe]","{action}":"[data-action]","{unSubscribeBtn}":"[data-kt-subscriptions-unsubscribe]","{item}":"[data-kt-subscriptions-item]","{checkbox}":"[data-kt-subscriptions-item-checkbox]","{intervalInput}":"[data-subscription-interval]","{postcountInput}":"[data-subscription-postcount]"}},function(i,n){return{init:function(){i.loading=!1},getItems:function(t){var e=i.checkbox(":checked");return void 0!==t?e:e.map(function(){return this.value}).get()},"{checkbox} change":function(t,e){t.is(":checked"),t.parents(i.item.selector);0<i.checkbox(":checked").length?i.actions().removeClass("t-invisible"):i.actions().addClass("t-invisible")},"{intervalInput} change":function(t,e){i.loading||(i.loading=!0,t=o(t).val(),Komento.ajax("site/views/subscriptions/updateInterval",{uid:n.userid,interval:t}).done(function(){i.loading=!1}))},"{postcountInput} change":function(t,e){i.loading||(i.loading=!0,t=o(t).val(),Komento.ajax("site/views/subscriptions/updatePostCount",{uid:n.userid,postcount:t}).done(function(){i.loading=!1}))},unSubscribe:function(t){t&&Komento.dialog({content:Komento.ajax("site/views/subscriptions/dashboardConfirmUnsubscribe",{cids:t}),bindings:{"{submit} click":function(){Komento.ajax("site/views/subscriptions/dashboardUnsubscribe",{cids:t}).done(function(){Komento.dialog().close(),window.location.reload()})}}})},"{checkAll} change":function(t,e){t=t.is(":checked");i.checkbox().prop("checked",t),i.checkbox().trigger("change")},"{actionUnsubscribe} click":function(t,e){var n=this.getItems();i.unSubscribe(n)},"{unSubscribeBtn} click":function(t,e){i.checkAll().prop("checked",!1),i.checkAll().trigger("change"),t.closest("[data-kt-subscriptions-item]").find(i.checkbox.selector).prop("checked","checked").trigger("change");t=this.getItems();i.unSubscribe(t)}}}),this.resolve()}),Komento.module("site/dashboard/item",function(i){Komento.Controller("Dashboard.Item",{defaults:{commentId:0}},function(n){return{unpublishComment:function(){var t=n.options.commentId.split("-")[1];Komento.ajax("site/views/comments/unpublish",{id:t}).done(function(){n.closeDialog(),n.unpublishChild(n.element.attr("id")),n.statusButton().text(i.language("COM_KOMENTO_UNPUBLISHED")),n.publishButton().show(),n.unpublishButton().hide(),n.statusOptions().hide()})},unpublishChild:function(t){var e=i.language("COM_KOMENTO_UNPUBLISHED");i('li[parentid="'+t+'"]').each(function(){i(this).find(".kmt-status").text(e),i(this).find(".kmt-unpublish").hide(),i(this).find(".kmt-publish").show(),n.unpublishChild(i(this).attr("id"))})}}}),this.resolve()})});