function scrollToGatewayInputError(){var e=jQuery(".gateway-errors,.assisted-cc-input-feedback").first();(e.closest("form")||jQuery("form").first()).find('button[type="submit"],input[type="submit"]').prop("disabled",!1).removeClass("disabled").find("i.fas,i.far,i.fal,i.fab").removeAttr("class").addClass("fas fa-arrow-circle-right").find("span").toggle(),e.length&&elementOutOfViewPort(e[0])&&jQuery("html, body").animate({scrollTop:e.offset().top-50},500)}function elementOutOfViewPort(e){var e=e.getBoundingClientRect(),t={};return t.top=e.top<0,t.left=e.left<0,t.bottom=e.bottom>(window.innerHeight||document.documentElement.clientHeight),t.right=e.right>(window.innerWidth||document.documentElement.clientWidth),t.any=t.top||t.left||t.bottom||t.right,t.any}function showCheckoutError(e,t=null){jQuery(".alert-danger").hide();(t=t||jQuery([".checkout-error-feedback","#existingLoginMessage",".gateway-errors",".assisted-cc-input-feedback"].join(", ")).first()).length&&t.html(e).slideDown("fast")}!function(e,t){"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(e.document)return t(e);throw new Error("jQuery requires a window with a document")}:t(e)}("undefined"!=typeof window?window:this,function(C,P){function H(e,t){return t.toUpperCase()}var c=[],p=C.document,u=c.slice,O=c.concat,Q=c.push,F=c.indexOf,R={},B=R.toString,g=R.hasOwnProperty,m={},e="1.12.4",w=function(e,t){return new w.fn.init(e,t)},W=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,U=/^-ms-/,q=/-([\da-z])/gi;function z(e){var t=!!e&&"length"in e&&e.length,n=w.type(e);return"function"!==n&&!w.isWindow(e)&&("array"===n||0===t||"number"==typeof t&&0>10|55296,1023&i|56320)}function H(){w()}var e,p,$,o,O,g,Q,F,C,d,l,w,_,t,S,m,i,r,y,x="sizzle"+ +new Date,b=P.document,T=0,R=0,B=le(),W=le(),v=le(),U=function(e,t){return e===t&&(l=!0),0},q={}.hasOwnProperty,n=[],z=n.pop,G=n.push,k=n.push,V=n.slice,D=function(e,t){for(var n=0,i=e.length;n+~]|"+a+")"+a+"*"),te=new RegExp("="+a+"*([^\\]'\"]*?)"+a+"*\\]","g"),ne=new RegExp(X),ie=new RegExp("^"+s+"$"),h={ID:new RegExp("^#("+s+")"),CLASS:new RegExp("^\\.("+s+")"),TAG:new RegExp("^("+s+"|[*])"),ATTR:new RegExp("^"+J),PSEUDO:new RegExp("^"+X),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+a+"*(even|odd|(([+-]|)(\\d*)n|)"+a+"*(?:([+-]|)"+a+"*(\\d+)|))"+a+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+a+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+a+"*((?:-\\d)?\\d*)"+a+"*\\)|)(?=[^-]|$)","i")},re=/^(?:input|select|textarea|button)$/i,oe=/^h\d$/i,u=/^[^{]+\{\s*\[native \w/,ae=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,se=/[+~]/,de=/'|\\/g,f=new RegExp("\\\\([\\da-f]{1,6}"+a+"?|("+a+")|.)","ig");try{k.apply(n=V.call(b.childNodes),b.childNodes),n[b.childNodes.length].nodeType}catch(e){k={apply:n.length?function(e,t){G.apply(e,V.call(t))}:function(e,t){for(var n=e.length,i=0;e[n++]=t[i++];);e.length=n-1}}}function I(e,t,n,i){var r,o,a,s,d,l,u,c,h=t&&t.ownerDocument,f=t?t.nodeType:9;if(n=n||[],"string"!=typeof e||!e||1!==f&&9!==f&&11!==f)return n;if(!i&&((t?t.ownerDocument||t:b)!==_&&w(t),t=t||_,S)){if(11!==f&&(l=ae.exec(e)))if(r=l[1]){if(9===f){if(!(a=t.getElementById(r)))return n;if(a.id===r)return n.push(a),n}else if(h&&(a=h.getElementById(r))&&y(t,a)&&a.id===r)return n.push(a),n}else{if(l[2])return k.apply(n,t.getElementsByTagName(e)),n;if((r=l[3])&&p.getElementsByClassName&&t.getElementsByClassName)return k.apply(n,t.getElementsByClassName(r)),n}if(p.qsa&&!v[e+" "]&&(!m||!m.test(e))){if(1!==f)h=t,c=e;else if("object"!==t.nodeName.toLowerCase()){for((s=t.getAttribute("id"))?s=s.replace(de,"\\$&"):t.setAttribute("id",s=x),o=(u=g(e)).length,d=ie.test(s)?"#"+s:"[id='"+s+"']";o--;)u[o]=d+" "+L(u[o]);c=u.join(","),h=se.test(e)&&he(t.parentNode)||t}if(c)try{return k.apply(n,h.querySelectorAll(c)),n}catch(e){}finally{s===x&&t.removeAttribute("id")}}}return F(e.replace(j,"$1"),t,n,i)}function le(){var n=[];function i(e,t){return n.push(e+" ")>$.cacheLength&&delete i[n.shift()],i[e+" "]=t}return i}function A(e){return e[x]=!0,e}function E(e){var t=_.createElement("div");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t)}}function ue(e,t){for(var n=e.split("|"),i=n.length;i--;)$.attrHandle[n[i]]=t}function ce(e,t){var n=t&&e,i=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||1<<31)-(~e.sourceIndex||1<<31);if(i)return i;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function N(a){return A(function(o){return o=+o,A(function(e,t){for(var n,i=a([],e.length,o),r=i.length;r--;)e[n=i[r]]&&(e[n]=!(t[n]=e[n]))})})}function he(e){return e&&void 0!==e.getElementsByTagName&&e}for(e in p=I.support={},O=I.isXML=function(e){e=e&&(e.ownerDocument||e).documentElement;return!!e&&"HTML"!==e.nodeName},w=I.setDocument=function(e){var e=e?e.ownerDocument||e:b;return e!==_&&9===e.nodeType&&e.documentElement&&(t=(_=e).documentElement,S=!O(_),(e=_.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",H,!1):e.attachEvent&&e.attachEvent("onunload",H)),p.attributes=E(function(e){return e.className="i",!e.getAttribute("className")}),p.getElementsByTagName=E(function(e){return e.appendChild(_.createComment("")),!e.getElementsByTagName("*").length}),p.getElementsByClassName=u.test(_.getElementsByClassName),p.getById=E(function(e){return t.appendChild(e).id=x,!_.getElementsByName||!_.getElementsByName(x).length}),p.getById?($.find.ID=function(e,t){if(void 0!==t.getElementById&&S)return(t=t.getElementById(e))?[t]:[]},$.filter.ID=function(e){var t=e.replace(f,c);return function(e){return e.getAttribute("id")===t}}):(delete $.find.ID,$.filter.ID=function(e){var t=e.replace(f,c);return function(e){e=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return e&&e.value===t}}),$.find.TAG=p.getElementsByTagName?function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):p.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,i=[],r=0,o=t.getElementsByTagName(e);if("*"!==e)return o;for(;n=o[r++];)1===n.nodeType&&i.push(n);return i},$.find.CLASS=p.getElementsByClassName&&function(e,t){if(void 0!==t.getElementsByClassName&&S)return t.getElementsByClassName(e)},i=[],m=[],(p.qsa=u.test(_.querySelectorAll))&&(E(function(e){t.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&m.push("[*^$]="+a+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||m.push("\\["+a+"*(?:value|"+K+")"),e.querySelectorAll("[id~="+x+"-]").length||m.push("~="),e.querySelectorAll(":checked").length||m.push(":checked"),e.querySelectorAll("a#"+x+"+*").length||m.push(".#.+[+~]")}),E(function(e){var t=_.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&m.push("name"+a+"*[*^$|!~]?="),e.querySelectorAll(":enabled").length||m.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),m.push(",.*:")})),(p.matchesSelector=u.test(r=t.matches||t.webkitMatchesSelector||t.mozMatchesSelector||t.oMatchesSelector||t.msMatchesSelector))&&E(function(e){p.disconnectedMatch=r.call(e,"div"),r.call(e,"[s!='']:x"),i.push("!=",X)}),m=m.length&&new RegExp(m.join("|")),i=i.length&&new RegExp(i.join("|")),e=u.test(t.compareDocumentPosition),y=e||u.test(t.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,t=t&&t.parentNode;return e===t||!(!t||1!==t.nodeType||!(n.contains?n.contains(t):e.compareDocumentPosition&&16&e.compareDocumentPosition(t)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},U=e?function(e,t){var n;return e===t?(l=!0,0):(n=!e.compareDocumentPosition-!t.compareDocumentPosition)||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!p.sortDetached&&t.compareDocumentPosition(e)===n?e===_||e.ownerDocument===b&&y(b,e)?-1:t===_||t.ownerDocument===b&&y(b,t)?1:d?D(d,e)-D(d,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,i=0,r=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!r||!o)return e===_?-1:t===_?1:r?-1:o?1:d?D(d,e)-D(d,t):0;if(r===o)return ce(e,t);for(n=e;n=n.parentNode;)a.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;a[i]===s[i];)i++;return i?ce(a[i],s[i]):a[i]===b?-1:s[i]===b?1:0}),_},I.matches=function(e,t){return I(e,null,null,t)},I.matchesSelector=function(e,t){if((e.ownerDocument||e)!==_&&w(e),t=t.replace(te,"='$1']"),p.matchesSelector&&S&&!v[t+" "]&&(!i||!i.test(t))&&(!m||!m.test(t)))try{var n=r.call(e,t);if(n||p.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(f,c),e[3]=(e[3]||e[4]||e[5]||"").replace(f,c),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||I.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&I.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return h.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&ne.test(n)&&(t=(t=g(n,!0))&&n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(f,c).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=B[e+" "];return t||(t=new RegExp("(^|"+a+")"+e+"("+a+"|$)"))&&B(e,function(e){return t.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(t,n,i){return function(e){e=I.attr(e,t);return null==e?"!="===n:!n||(e+="","="===n?e===i:"!="===n?e!==i:"^="===n?i&&0===e.indexOf(i):"*="===n?i&&-1(?:<\/\1>|)$/,J=/^.[^:#\[\.,]*$/;function X(e,n,i){if(w.isFunction(n))return w.grep(e,function(e,t){return!!n.call(e,t,e)!==i});if(n.nodeType)return w.grep(e,function(e){return e===n!==i});if("string"==typeof n){if(J.test(n))return w.filter(n,e,i);n=w.filter(n,e)}return w.grep(e,function(e){return-1)[^>]*|#([\w-]*))$/,ee=((w.fn.init=function(e,t,n){if(e){if(n=n||Y,"string"!=typeof e)return e.nodeType?(this.context=this[0]=e,this.length=1,this):w.isFunction(e)?void 0!==n.ready?n.ready(e):e(w):(void 0!==e.selector&&(this.selector=e.selector,this.context=e.context),w.makeArray(e,this));if(!(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&3<=e.length?[null,e,null]:Z.exec(e))||!i[1]&&t)return(!t||t.jquery?t||n:this.constructor(t)).find(e);if(i[1]){if(t=t instanceof w?t[0]:t,w.merge(this,w.parseHTML(i[1],t&&t.nodeType?t.ownerDocument||t:p,!0)),K.test(i[1])&&w.isPlainObject(t))for(var i in t)w.isFunction(this[i])?this[i](t[i]):this.attr(i,t[i])}else{if((n=p.getElementById(i[2]))&&n.parentNode){if(n.id!==i[2])return Y.find(e);this.length=1,this[0]=n}this.context=p,this.selector=e}}return this}).prototype=w.fn,Y=w(p),/^(?:parents|prev(?:Until|All))/),te={children:!0,contents:!0,next:!0,prev:!0};function ne(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}w.fn.extend({has:function(e){var t,n=w(e,this),i=n.length;return this.filter(function(){for(t=0;t
a",m.leadingWhitespace=3===k.firstChild.nodeType,m.tbody=!k.getElementsByTagName("tbody").length,m.htmlSerialize=!!k.getElementsByTagName("link").length,m.html5Clone="<:nav>"!==p.createElement("nav").cloneNode(!0).outerHTML,N.type="checkbox",N.checked=!0,T.appendChild(N),m.appendChecked=N.checked,k.innerHTML="",m.noCloneChecked=!!k.cloneNode(!0).lastChild.defaultValue,T.appendChild(k),(N=p.createElement("input")).setAttribute("type","radio"),N.setAttribute("checked","checked"),N.setAttribute("name","t"),k.appendChild(N),m.checkClone=k.cloneNode(!0).cloneNode(!0).lastChild.checked,m.noCloneEvent=!!k.addEventListener,k[w.expando]=1,m.attributes=!k.getAttribute(w.expando);var b={option:[1,""],legend:[1,"
","
"],area:[1,"",""],param:[1,"",""],thead:[1,"","
"],tr:[2,"","
"],col:[2,"","
"],td:[3,"","
"],_default:m.htmlSerialize?[0,"",""]:[1,"X
","
"]};function v(e,t){var n,i,r=0,o=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(t||"*"):void 0;if(!o)for(o=[],n=e.childNodes||e;null!=(i=n[r]);r++)!t||w.nodeName(i,t)?o.push(i):w.merge(o,v(i,t));return void 0===t||t&&w.nodeName(e,t)?w.merge([e],o):o}function Ce(e,t){for(var n,i=0;null!=(n=e[i]);i++)w._data(n,"globalEval",!t||w._data(t[i],"globalEval"))}b.optgroup=b.option,b.tbody=b.tfoot=b.colgroup=b.caption=b.thead,b.th=b.td;var we=/<|&#?\w+;/,_e=/"!==c[1]||_e.test(a)?0:d:d.firstChild)&&a.childNodes.length;o--;)w.nodeName(u=a.childNodes[o],"tbody")&&!u.childNodes.length&&a.removeChild(u);for(w.merge(p,d.childNodes),d.textContent="";d.firstChild;)d.removeChild(d.firstChild);d=f.lastChild}else p.push(t.createTextNode(a));for(d&&f.removeChild(d),m.appendChecked||w.grep(v(p,"input"),Se),g=0;a=p[g++];)if(i&&-1]","i"),Qe=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,Fe=/\s*$/g,Ue=$e(p).appendChild(p.createElement("div"));function qe(e,t){return w.nodeName(e,"table")&&w.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function ze(e){return e.type=(null!==w.find.attr(e,"type"))+"/"+e.type,e}function Ge(e){var t=Be.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function Ve(e,t){if(1===t.nodeType&&w.hasData(e)){var n,i,r,e=w._data(e),o=w._data(t,e),a=e.events;if(a)for(n in delete o.handle,o.events={},a)for(i=0,r=a[n].length;i")},clone:function(e,t,n){var i,r,o,a,s,d=w.contains(e.ownerDocument,e);if(m.html5Clone||w.isXMLDoc(e)||!Oe.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Ue.innerHTML=e.outerHTML,Ue.removeChild(o=Ue.firstChild)),!(m.noCloneEvent&&m.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||w.isXMLDoc(e)))for(i=v(o),s=v(e),a=0;null!=(r=s[a]);++a)if(i[a]){c=u=l=f=h=void 0;var l,u,c,h=r,f=i[a];if(1===f.nodeType){if(l=f.nodeName.toLowerCase(),!m.noCloneEvent&&f[w.expando]){for(u in(c=w._data(f)).events)w.removeEvent(f,u,c.handle);f.removeAttribute(w.expando)}"script"===l&&f.text!==h.text?(ze(f).text=h.text,Ge(f)):"object"===l?(f.parentNode&&(f.outerHTML=h.outerHTML),m.html5Clone&&h.innerHTML&&!w.trim(f.innerHTML)&&(f.innerHTML=h.innerHTML)):"input"===l&&ge.test(h.type)?(f.defaultChecked=f.checked=h.checked,f.value!==h.value&&(f.value=h.value)):"option"===l?f.defaultSelected=f.selected=h.defaultSelected:"input"!==l&&"textarea"!==l||(f.defaultValue=h.defaultValue)}}if(t)if(n)for(s=s||v(e),i=i||v(o),a=0;null!=(r=s[a]);a++)Ve(r,i[a]);else Ve(e,o);return 0<(i=v(o,"script")).length&&Ce(i,!d&&v(e,"script")),i=s=r=null,o},cleanData:function(e,t){for(var n,i,r,o,a=0,s=w.expando,d=w.cache,l=m.attributes,u=w.event.special;null!=(n=e[a]);a++)if((t||y(n))&&(o=(r=n[s])&&d[r])){if(o.events)for(i in o.events)u[i]?w.event.remove(n,i):w.removeEvent(n,i,o.handle);d[r]&&(delete d[r],l||void 0===n.removeAttribute?n[s]=void 0:n.removeAttribute(s),c.push(r))}}}),w.fn.extend({domManip:$,detach:function(e){return Ke(this,e,!0)},remove:function(e){return Ke(this,e)},text:function(e){return h(this,function(e){return void 0===e?w.text(this):this.empty().append((this[0]&&this[0].ownerDocument||p).createTextNode(e))},null,e,arguments.length)},append:function(){return $(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||qe(this,e).appendChild(e)})},prepend:function(){return $(this,arguments,function(e){var t;1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(t=qe(this,e)).insertBefore(e,t.firstChild)})},before:function(){return $(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return $(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++){for(1===e.nodeType&&w.cleanData(v(e,!1));e.firstChild;)e.removeChild(e.firstChild);e.options&&w.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return w.clone(this,e,t)})},html:function(e){return h(this,function(e){var t=this[0]||{},n=0,i=this.length;if(void 0===e)return 1===t.nodeType?t.innerHTML.replace(He,""):void 0;if("string"==typeof e&&!Fe.test(e)&&(m.htmlSerialize||!Oe.test(e))&&(m.leadingWhitespace||!be.test(e))&&!b[(me.exec(e)||["",""])[1].toLowerCase()]){e=w.htmlPrefilter(e);try{for(;n")).appendTo(t.documentElement))[0].contentWindow||Je[0].contentDocument).document).write(),t.close(),n=Ye(e,t),Je.detach()),Xe[e]=n),n}function et(e,t,n,i){var r,o={};for(r in t)o[r]=e.style[r],e.style[r]=t[r];for(r in n=n.apply(e,i||[]),t)e.style[r]=o[r];return n}var n,tt,nt,it,rt,ot,at,o,st=/^margin/,dt=new RegExp("^("+e+")(?!px)[a-z%]+$","i"),lt=p.documentElement;function a(){var e,t=p.documentElement;t.appendChild(at),o.style.cssText="-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",n=nt=ot=!1,tt=rt=!0,C.getComputedStyle&&(e=C.getComputedStyle(o),n="1%"!==(e||{}).top,ot="2px"===(e||{}).marginLeft,nt="4px"===(e||{width:"4px"}).width,o.style.marginRight="50%",tt="4px"===(e||{marginRight:"4px"}).marginRight,(e=o.appendChild(p.createElement("div"))).style.cssText=o.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",e.style.marginRight=e.style.width="0",o.style.width="1px",rt=!parseFloat((C.getComputedStyle(e)||{}).marginRight),o.removeChild(e)),o.style.display="none",(it=0===o.getClientRects().length)&&(o.style.display="",o.innerHTML="
t
",o.childNodes[0].style.borderCollapse="separate",(e=o.getElementsByTagName("td"))[0].style.cssText="margin:0;border:0;padding:0;display:none",it=0===e[0].offsetHeight)&&(e[0].style.display="",e[1].style.display="none",it=0===e[0].offsetHeight),t.removeChild(at)}at=p.createElement("div"),(o=p.createElement("div")).style&&(o.style.cssText="float:left;opacity:.5",m.opacity="0.5"===o.style.opacity,m.cssFloat=!!o.style.cssFloat,o.style.backgroundClip="content-box",o.cloneNode(!0).style.backgroundClip="",m.clearCloneStyle="content-box"===o.style.backgroundClip,(at=p.createElement("div")).style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",o.innerHTML="",at.appendChild(o),m.boxSizing=""===o.style.boxSizing||""===o.style.MozBoxSizing||""===o.style.WebkitBoxSizing,w.extend(m,{reliableHiddenOffsets:function(){return null==n&&a(),it},boxSizingReliable:function(){return null==n&&a(),nt},pixelMarginRight:function(){return null==n&&a(),tt},pixelPosition:function(){return null==n&&a(),n},reliableMarginRight:function(){return null==n&&a(),rt},reliableMarginLeft:function(){return null==n&&a(),ot}}));var l,f,ut=/^(top|right|bottom|left)$/;function ct(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}C.getComputedStyle?(l=function(e){var t=e.ownerDocument.defaultView;return(t=t&&t.opener?t:C).getComputedStyle(e)},f=function(e,t,n){var i,r,o=e.style;return""!==(r=(n=n||l(e))?n.getPropertyValue(t)||n[t]:void 0)&&void 0!==r||w.contains(e.ownerDocument,e)||(r=w.style(e,t)),n&&!m.pixelMarginRight()&&dt.test(r)&&st.test(t)&&(e=o.width,t=o.minWidth,i=o.maxWidth,o.minWidth=o.maxWidth=o.width=r,r=n.width,o.width=e,o.minWidth=t,o.maxWidth=i),void 0===r?r:r+""}):lt.currentStyle&&(l=function(e){return e.currentStyle},f=function(e,t,n){var i,r,o,a=e.style;return null==(n=(n=n||l(e))?n[t]:void 0)&&a&&a[t]&&(n=a[t]),dt.test(n)&&!ut.test(t)&&(i=a.left,(o=(r=e.runtimeStyle)&&r.left)&&(r.left=e.currentStyle.left),a.left="fontSize"===t?"1em":n,n=a.pixelLeft+"px",a.left=i,o)&&(r.left=o),void 0===n?n:n+""||"auto"});var ht=/alpha\([^)]*\)/i,ft=/opacity\s*=\s*([^)]*)/i,pt=/^(none|table(?!-c[ea]).+)/,gt=new RegExp("^("+e+")(.*)$","i"),mt={position:"absolute",visibility:"hidden",display:"block"},yt={letterSpacing:"0",fontWeight:"400"},bt=["Webkit","O","Moz","ms"],vt=p.createElement("div").style;function $t(e){if(e in vt)return e;for(var t=e.charAt(0).toUpperCase()+e.slice(1),n=bt.length;n--;)if((e=bt[n]+t)in vt)return e}function Ct(e,t){for(var n,i,r,o=[],a=0,s=e.length;a
a",M=N.getElementsByTagName("a")[0],T.setAttribute("type","checkbox"),N.appendChild(T),(M=N.getElementsByTagName("a")[0]).style.cssText="top:1px",m.getSetAttribute="t"!==N.className,m.style=/top/.test(M.getAttribute("style")),m.hrefNormalized="/a"===M.getAttribute("href"),m.checkOn=!!T.value,m.optSelected=e.selected,m.enctype=!!p.createElement("form").enctype,k.disabled=!0,m.optDisabled=!e.disabled,(T=p.createElement("input")).setAttribute("value",""),m.input=""===T.getAttribute("value"),T.value="t",T.setAttribute("type","radio"),m.radioValue="t"===T.value;var At=/\r/g,Et=/[\x20\t\r\n\f]+/g;w.fn.extend({val:function(t){var n,e,i,r=this[0];return arguments.length?(i=w.isFunction(t),this.each(function(e){1!==this.nodeType||(null==(e=i?t.call(this,e,w(this).val()):t)?e="":"number"==typeof e?e+="":w.isArray(e)&&(e=w.map(e,function(e){return null==e?"":e+""})),(n=w.valHooks[this.type]||w.valHooks[this.nodeName.toLowerCase()])&&"set"in n&&void 0!==n.set(this,e,"value"))||(this.value=e)})):r?(n=w.valHooks[r.type]||w.valHooks[r.nodeName.toLowerCase()])&&"get"in n&&void 0!==(e=n.get(r,"value"))?e:"string"==typeof(e=r.value)?e.replace(At,""):null==e?"":e:void 0}}),w.extend({valHooks:{option:{get:function(e){var t=w.find.attr(e,"value");return null!=t?t:w.trim(w.text(e)).replace(Et," ")}},select:{get:function(e){for(var t,n=e.options,i=e.selectedIndex,r="select-one"===e.type||i<0,o=r?null:[],a=r?i+1:n.length,s=i<0?a:r?i:0;s").append(w.parseHTML(e)).find(i):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this)},w.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){w.fn[t]=function(e){return this.on(t,e)}}),w.expr.filters.animated=function(t){return w.grep(w.timers,function(e){return t===e.elem}).length},w.offset={setOffset:function(e,t,n){var i,r,o,a,s=w.css(e,"position"),d=w(e),l={};"static"===s&&(e.style.position="relative"),o=d.offset(),i=w.css(e,"top"),a=w.css(e,"left"),s=("absolute"===s||"fixed"===s)&&-1this._items.length-1||e<0||(this._isSliding?u.default(this._element).one(te,function(){return t.to(e)}):n===e?(this.pause(),this.cycle()):this._slide(n=n.clientWidth&&e>=n.clientHeight})).length?r:o)[0].key+((t=e.split("-")[1])?"-"+t:""))}function Ee(e,t,n,i){i=3d[e]&&!i.escapeWithReference&&(n=Math.min(l[t],d[e]-("right"===e?l.width:l.height))),v({},t,n)}};return t.forEach(function(e){var t=-1!==["left","top"].indexOf(e)?"primary":"secondary";l=$({},l,u[t](e))}),e.offsets.popper=l,e},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(e){var t=(n=e.offsets).popper,n=n.reference,i=e.placement.split("-")[0],r=Math.floor,o=(i=-1!==["top","bottom"].indexOf(i))?"right":"bottom",a=i?"left":"top",i=i?"width":"height";return t[o]r(n[o])&&(e.offsets.popper[a]=r(n[o])),e}},arrow:{order:500,enabled:!0,fn:function(e,t){if(Ge(e.instance.modifiers,"arrow","keepTogether")){t=t.element;if("string"==typeof t){if(!(t=e.instance.popper.querySelector(t)))return e}else if(!e.instance.popper.contains(t))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),e;var n=e.placement.split("-")[0],i=e.offsets,r=i.popper,i=i.reference,n=-1!==["left","right"].indexOf(n),o=n?"height":"width",a=n?"Top":"Left",s=a.toLowerCase(),d=n?"left":"top",n=n?"bottom":"right",l=Ne(t)[o],n=(i[n]-lr[n]&&(e.offsets.popper[s]+=i[s]+l-r[n]),e.offsets.popper=C(e.offsets.popper),i[s]+i[o]/2-l/2),i=g(e.instance.popper),u=parseFloat(i["margin"+a]),i=parseFloat(i["border"+a+"Width"]),a=n-e.offsets.popper[s]-u-i,a=Math.max(Math.min(r[o]-l,a),0);e.arrowElement=t,e.offsets.arrow=(v(n={},s,Math.round(a)),v(n,d,""),n)}return e},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(l,u){if(!(Oe(l.instance.modifiers,"inner")||l.flipped&&l.placement===l.originalPlacement)){var c=Ie(l.instance.popper,l.instance.reference,u.padding,u.boundariesElement,l.positionFixed),h=l.placement.split("-")[0],f=Le(h),p=l.placement.split("-")[1]||"",g=[];switch(u.behavior){case Xe:g=[h,f];break;case Ye:g=Je(h);break;case Ze:g=Je(h,!0);break;default:g=u.behavior}g.forEach(function(e,t){if(h!==e||g.length===t+1)return l;h=l.placement.split("-")[0],f=Le(h);var e=l.offsets.popper,n=l.offsets.reference,i=Math.floor,n="left"===h&&i(e.right)>i(n.left)||"right"===h&&i(e.left)i(n.top)||"bottom"===h&&i(e.top)i(c.right),a=i(e.top)i(c.bottom),i="left"===h&&r||"right"===h&&o||"top"===h&&a||"bottom"===h&&e,s=-1!==["top","bottom"].indexOf(h),d=!!u.flipVariations&&(s&&"start"===p&&r||s&&"end"===p&&o||!s&&"start"===p&&a||!s&&"end"===p&&e),o=!!u.flipVariationsByContent&&(s&&"start"===p&&o||s&&"end"===p&&r||!s&&"start"===p&&e||!s&&"end"===p&&a),r=d||o;(n||i||r)&&(l.flipped=!0,(n||i)&&(h=g[t+1]),r&&(p="end"===(e=p)?"start":"start"===e?"end":e),l.placement=h+(p?"-"+p:""),l.offsets.popper=$({},l.offsets.popper,Me(l.instance.popper,l.offsets.reference,l.placement)),l=He(l.instance.modifiers,l,"flip"))})}return l},behavior:"flip",padding:5,boundariesElement:"viewport",flipVariations:!1,flipVariationsByContent:!1},inner:{order:700,enabled:!1,fn:function(e){var t=e.placement,n=t.split("-")[0],i=(r=e.offsets).popper,r=r.reference,o=-1!==["left","right"].indexOf(n),a=-1===["top","left"].indexOf(n);return i[o?"left":"top"]=r[n]-(a?i[o?"width":"height"]:0),e.placement=Le(t),e.offsets.popper=C(i),e}},hide:{order:800,enabled:!0,fn:function(e){if(Ge(e.instance.modifiers,"hide","preventOverflow")){var t=e.offsets.reference,n=Pe(e.instance.modifiers,function(e){return"preventOverflow"===e.name}).boundaries;if(t.bottomn.right||t.top>n.bottom||t.rightdocument.documentElement.clientHeight)||(this._element.style.overflowY="hidden"),this._element.classList.add(kt),n=c.getTransitionDurationFromElement(this._dialog),u.default(this._element).off(c.TRANSITION_END),u.default(this._element).one(c.TRANSITION_END,function(){i._element.classList.remove(kt),t||u.default(i._element).one(c.TRANSITION_END,function(){i._element.style.overflowY=""}).emulateTransitionEnd(i._element,n)}).emulateTransitionEnd(n),this._element.focus())):this.hide()},e._showElement=function(e){function t(){n._config.focus&&n._element.focus(),n._isTransitioning=!1,u.default(n._element).trigger(o)}var n=this,i=u.default(this._element).hasClass(D),r=this._dialog?this._dialog.querySelector(".modal-body"):null,o=(this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE||document.body.appendChild(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),u.default(this._dialog).hasClass("modal-dialog-scrollable")&&r?r.scrollTop=0:this._element.scrollTop=0,i&&c.reflow(this._element),u.default(this._element).addClass(Tt),this._config.focus&&this._enforceFocus(),u.default.Event("shown.bs.modal",{relatedTarget:e}));i?(r=c.getTransitionDurationFromElement(this._dialog),u.default(this._dialog).one(c.TRANSITION_END,t).emulateTransitionEnd(r)):t()},e._enforceFocus=function(){var t=this;u.default(document).off($t).on($t,function(e){document!==e.target&&t._element!==e.target&&0===u.default(t._element).has(e.target).length&&t._element.focus()})},e._setEscapeEvent=function(){var t=this;this._isShown?u.default(this._element).on(_t,function(e){t._config.keyboard&&27===e.which?(e.preventDefault(),t.hide()):t._config.keyboard||27!==e.which||t._triggerBackdropTransition()}):this._isShown||u.default(this._element).off(_t)},e._setResizeEvent=function(){var t=this;this._isShown?u.default(window).on(Ct,function(e){return t.handleUpdate(e)}):u.default(window).off(Ct)},e._hideModal=function(){var e=this;this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._showBackdrop(function(){u.default(document.body).removeClass(xt),e._resetAdjustments(),e._resetScrollbar(),u.default(e._element).trigger(bt)})},e._removeBackdrop=function(){this._backdrop&&(u.default(this._backdrop).remove(),this._backdrop=null)},e._showBackdrop=function(e){var t,n=this,i=u.default(this._element).hasClass(D)?D:"";this._isShown&&this._config.backdrop?(this._backdrop=document.createElement("div"),this._backdrop.className="modal-backdrop",i&&this._backdrop.classList.add(i),u.default(this._backdrop).appendTo(document.body),u.default(this._element).on(wt,function(e){n._ignoreBackdropClick?n._ignoreBackdropClick=!1:e.target===e.currentTarget&&n._triggerBackdropTransition()}),i&&c.reflow(this._backdrop),u.default(this._backdrop).addClass(Tt),e&&(i?(i=c.getTransitionDurationFromElement(this._backdrop),u.default(this._backdrop).one(c.TRANSITION_END,e).emulateTransitionEnd(i)):e())):!this._isShown&&this._backdrop?(u.default(this._backdrop).removeClass(Tt),i=function(){n._removeBackdrop(),e&&e()},u.default(this._element).hasClass(D)?(t=c.getTransitionDurationFromElement(this._backdrop),u.default(this._backdrop).one(c.TRANSITION_END,i).emulateTransitionEnd(t)):i()):e&&e()},e._adjustDialog=function(){var e=this._element.scrollHeight>document.documentElement.clientHeight;!this._isBodyOverflowing&&e&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),this._isBodyOverflowing&&!e&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},e._resetAdjustments=function(){this._element.style.paddingLeft="",this._element.style.paddingRight=""},e._checkScrollbar=function(){var e=document.body.getBoundingClientRect();this._isBodyOverflowing=Math.round(e.left+e.right)
',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:0,container:!1,fallbackPlacement:"flip",boundary:"scrollParent",sanitize:!0,sanitizeFn:null,whiteList:t,popperConfig:null},Wt="show",Ut={HIDE:"hide"+I,HIDDEN:"hidden"+I,SHOW:"show"+I,SHOWN:"shown"+I,INSERTED:"inserted"+I,CLICK:"click"+I,FOCUSIN:"focusin"+I,FOCUSOUT:"focusout"+I,MOUSEENTER:"mouseenter"+I,MOUSELEAVE:"mouseleave"+I},qt="fade",zt="show",Gt="hover",Vt="focus",A=function(){function r(e,t){if(void 0===o)throw new TypeError("Bootstrap's tooltips require Popper.js (https://popper.js.org/)");this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._popper=null,this.element=e,this.config=this._getConfig(t),this.tip=null,this._setListeners()}var e=r.prototype;return e.enable=function(){this._isEnabled=!0},e.disable=function(){this._isEnabled=!1},e.toggleEnabled=function(){this._isEnabled=!this._isEnabled},e.toggle=function(e){var t,n;this._isEnabled&&(e?(t=this.constructor.DATA_KEY,(n=u.default(e.currentTarget).data(t))||(n=new this.constructor(e.currentTarget,this._getDelegateConfig()),u.default(e.currentTarget).data(t,n)),n._activeTrigger.click=!n._activeTrigger.click,n._isWithActiveTrigger()?n._enter(null,n):n._leave(null,n)):u.default(this.getTipElement()).hasClass(zt)?this._leave(null,this):this._enter(null,this))},e.dispose=function(){clearTimeout(this._timeout),u.default.removeData(this.element,this.constructor.DATA_KEY),u.default(this.element).off(this.constructor.EVENT_KEY),u.default(this.element).closest(".modal").off("hide.bs.modal",this._hideModalHandler),this.tip&&u.default(this.tip).remove(),this._isEnabled=null,this._timeout=null,this._hoverState=null,this._activeTrigger=null,this._popper&&this._popper.destroy(),this._popper=null,this.element=null,this.config=null,this.tip=null},e.show=function(){var t=this;if("none"===u.default(this.element).css("display"))throw new Error("Please use show on visible elements");var e,n,i=u.default.Event(this.constructor.Event.SHOW);this.isWithContent()&&this._isEnabled&&(u.default(this.element).trigger(i),n=c.findShadowRoot(this.element),n=u.default.contains(null!==n?n:this.element.ownerDocument.documentElement,this.element),!i.isDefaultPrevented())&&n&&(i=this.getTipElement(),n=c.getUID(this.constructor.NAME),i.setAttribute("id",n),this.element.setAttribute("aria-describedby",n),this.setContent(),this.config.animation&&u.default(i).addClass(qt),n="function"==typeof this.config.placement?this.config.placement.call(this,i,this.element):this.config.placement,n=this._getAttachment(n),this.addAttachmentClass(n),e=this._getContainer(),u.default(i).data(this.constructor.DATA_KEY,this),u.default.contains(this.element.ownerDocument.documentElement,this.tip)||u.default(i).appendTo(e),u.default(this.element).trigger(this.constructor.Event.INSERTED),this._popper=new o(this.element,i,this._getPopperConfig(n)),u.default(i).addClass(zt),"ontouchstart"in document.documentElement&&u.default(document.body).children().on("mouseover",null,u.default.noop),e=function(){t.config.animation&&t._fixTransition();var e=t._hoverState;t._hoverState=null,u.default(t.element).trigger(t.constructor.Event.SHOWN),"out"===e&&t._leave(null,t)},u.default(this.tip).hasClass(qt)?(n=c.getTransitionDurationFromElement(this.tip),u.default(this.tip).one(c.TRANSITION_END,e).emulateTransitionEnd(n)):e())},e.hide=function(e){function t(){n._hoverState!==Wt&&i.parentNode&&i.parentNode.removeChild(i),n._cleanTipClass(),n.element.removeAttribute("aria-describedby"),u.default(n.element).trigger(n.constructor.Event.HIDDEN),null!==n._popper&&n._popper.destroy(),e&&e()}var n=this,i=this.getTipElement(),r=u.default.Event(this.constructor.Event.HIDE);u.default(this.element).trigger(r),r.isDefaultPrevented()||(u.default(i).removeClass(zt),"ontouchstart"in document.documentElement&&u.default(document.body).children().off("mouseover",null,u.default.noop),this._activeTrigger.click=!1,this._activeTrigger[Vt]=!1,this._activeTrigger[Gt]=!1,u.default(this.tip).hasClass(qt)?(r=c.getTransitionDurationFromElement(i),u.default(i).one(c.TRANSITION_END,t).emulateTransitionEnd(r)):t(),this._hoverState="")},e.update=function(){null!==this._popper&&this._popper.scheduleUpdate()},e.isWithContent=function(){return Boolean(this.getTitle())},e.addAttachmentClass=function(e){u.default(this.getTipElement()).addClass(Ht+"-"+e)},e.getTipElement=function(){return this.tip=this.tip||u.default(this.config.template)[0],this.tip},e.setContent=function(){var e=this.getTipElement();this.setElementContent(u.default(e.querySelectorAll(".tooltip-inner")),this.getTitle()),u.default(e).removeClass(qt+" "+zt)},e.setElementContent=function(e,t){"object"==typeof t&&(t.nodeType||t.jquery)?this.config.html?u.default(t).parent().is(e)||e.empty().append(t):e.text(u.default(t).text()):this.config.html?(this.config.sanitize&&(t=Lt(t,this.config.whiteList,this.config.sanitizeFn)),e.html(t)):e.text(t)},e.getTitle=function(){return this.element.getAttribute("data-original-title")||("function"==typeof this.config.title?this.config.title.call(this.element):this.config.title)},e._getPopperConfig=function(e){var t=this;return s({},{placement:e,modifiers:{offset:this._getOffset(),flip:{behavior:this.config.fallbackPlacement},arrow:{element:".arrow"},preventOverflow:{boundariesElement:this.config.boundary}},onCreate:function(e){e.originalPlacement!==e.placement&&t._handlePopperPlacementChange(e)},onUpdate:function(e){return t._handlePopperPlacementChange(e)}},this.config.popperConfig)},e._getOffset=function(){var t=this,e={};return"function"==typeof this.config.offset?e.fn=function(e){return e.offsets=s({},e.offsets,t.config.offset(e.offsets,t.element)||{}),e}:e.offset=this.config.offset,e},e._getContainer=function(){return!1===this.config.container?document.body:c.isElement(this.config.container)?u.default(this.config.container):u.default(document).find(this.config.container)},e._getAttachment=function(e){return Rt[e.toUpperCase()]},e._setListeners=function(){var n=this;this.config.trigger.split(" ").forEach(function(e){var t;"click"===e?u.default(n.element).on(n.constructor.Event.CLICK,n.config.selector,function(e){return n.toggle(e)}):"manual"!==e&&(t=e===Gt?n.constructor.Event.MOUSEENTER:n.constructor.Event.FOCUSIN,e=e===Gt?n.constructor.Event.MOUSELEAVE:n.constructor.Event.FOCUSOUT,u.default(n.element).on(t,n.config.selector,function(e){return n._enter(e)}).on(e,n.config.selector,function(e){return n._leave(e)}))}),this._hideModalHandler=function(){n.element&&n.hide()},u.default(this.element).closest(".modal").on("hide.bs.modal",this._hideModalHandler),this.config.selector?this.config=s({},this.config,{trigger:"manual",selector:""}):this._fixTitle()},e._fixTitle=function(){var e=typeof this.element.getAttribute("data-original-title");!this.element.getAttribute("title")&&"string"==e||(this.element.setAttribute("data-original-title",this.element.getAttribute("title")||""),this.element.setAttribute("title",""))},e._enter=function(e,t){var n=this.constructor.DATA_KEY;(t=t||u.default(e.currentTarget).data(n))||(t=new this.constructor(e.currentTarget,this._getDelegateConfig()),u.default(e.currentTarget).data(n,t)),e&&(t._activeTrigger["focusin"===e.type?Vt:Gt]=!0),u.default(t.getTipElement()).hasClass(zt)||t._hoverState===Wt?t._hoverState=Wt:(clearTimeout(t._timeout),t._hoverState=Wt,t.config.delay&&t.config.delay.show?t._timeout=setTimeout(function(){t._hoverState===Wt&&t.show()},t.config.delay.show):t.show())},e._leave=function(e,t){var n=this.constructor.DATA_KEY;(t=t||u.default(e.currentTarget).data(n))||(t=new this.constructor(e.currentTarget,this._getDelegateConfig()),u.default(e.currentTarget).data(n,t)),e&&(t._activeTrigger["focusout"===e.type?Vt:Gt]=!1),t._isWithActiveTrigger()||(clearTimeout(t._timeout),t._hoverState="out",t.config.delay&&t.config.delay.hide?t._timeout=setTimeout(function(){"out"===t._hoverState&&t.hide()},t.config.delay.hide):t.hide())},e._isWithActiveTrigger=function(){for(var e in this._activeTrigger)if(this._activeTrigger[e])return!0;return!1},e._getConfig=function(e){var t=u.default(this.element).data();return Object.keys(t).forEach(function(e){-1!==Qt.indexOf(e)&&delete t[e]}),"number"==typeof(e=s({},this.constructor.Default,t,"object"==typeof e&&e?e:{})).delay&&(e.delay={show:e.delay,hide:e.delay}),"number"==typeof e.title&&(e.title=e.title.toString()),"number"==typeof e.content&&(e.content=e.content.toString()),c.typeCheckConfig(j,e,this.constructor.DefaultType),e.sanitize&&(e.template=Lt(e.template,e.whiteList,e.sanitizeFn)),e},e._getDelegateConfig=function(){var e={};if(this.config)for(var t in this.config)this.constructor.Default[t]!==this.config[t]&&(e[t]=this.config[t]);return e},e._cleanTipClass=function(){var e=u.default(this.getTipElement()),t=e.attr("class").match(Ot);null!==t&&t.length&&e.removeClass(t.join(""))},e._handlePopperPlacementChange=function(e){this.tip=e.instance.popper,this._cleanTipClass(),this.addAttachmentClass(this._getAttachment(e.placement))},e._fixTransition=function(){var e=this.getTipElement(),t=this.config.animation;null===e.getAttribute("x-placement")&&(u.default(e).removeClass(qt),this.config.animation=!1,this.hide(),this.show(),this.config.animation=t)},r._jQueryInterface=function(i){return this.each(function(){var e=u.default(this),t=e.data(Mt),n="object"==typeof i&&i;if((t||!/dispose|hide/.test(i))&&(t||(t=new r(this,n),e.data(Mt,t)),"string"==typeof i)){if(void 0===t[i])throw new TypeError('No method named "'+i+'"');t[i]()}})},a(r,null,[{key:"VERSION",get:function(){return"4.5.3"}},{key:"Default",get:function(){return Bt}},{key:"NAME",get:function(){return j}},{key:"DATA_KEY",get:function(){return Mt}},{key:"Event",get:function(){return Ut}},{key:"EVENT_KEY",get:function(){return I}},{key:"DefaultType",get:function(){return Ft}}]),r}(),E=(u.default.fn[j]=A._jQueryInterface,u.default.fn[j].Constructor=A,u.default.fn[j].noConflict=function(){return u.default.fn[j]=Pt,A._jQueryInterface},"popover"),Kt="bs.popover",N="."+Kt,Jt=u.default.fn[E],Xt="bs-popover",Yt=new RegExp("(^|\\s)"+Xt+"\\S+","g"),Zt=s({},A.Default,{placement:"right",trigger:"click",content:"",template:''}),en=s({},A.DefaultType,{content:"(string|element|function)"}),tn={HIDE:"hide"+N,HIDDEN:"hidden"+N,SHOW:"show"+N,SHOWN:"shown"+N,INSERTED:"inserted"+N,CLICK:"click"+N,FOCUSIN:"focusin"+N,FOCUSOUT:"focusout"+N,MOUSEENTER:"mouseenter"+N,MOUSELEAVE:"mouseleave"+N},nn=function(e){var t;function i(){return e.apply(this,arguments)||this}t=e,(n=i).prototype=Object.create(t.prototype),(n.prototype.constructor=n).__proto__=t;var n=i.prototype;return n.isWithContent=function(){return this.getTitle()||this._getContent()},n.addAttachmentClass=function(e){u.default(this.getTipElement()).addClass(Xt+"-"+e)},n.getTipElement=function(){return this.tip=this.tip||u.default(this.config.template)[0],this.tip},n.setContent=function(){var e=u.default(this.getTipElement()),t=(this.setElementContent(e.find(".popover-header"),this.getTitle()),this._getContent());"function"==typeof t&&(t=t.call(this.element)),this.setElementContent(e.find(".popover-body"),t),e.removeClass("fade show")},n._getContent=function(){return this.element.getAttribute("data-content")||this.config.content},n._cleanTipClass=function(){var e=u.default(this.getTipElement()),t=e.attr("class").match(Yt);null!==t&&0=this._offsets[i]&&(void 0===this._offsets[i+1]||e li > .active",vn=function(){function i(e){this._element=e}var e=i.prototype;return e.show=function(){var e,t,n,i,r,o,a=this;this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE&&u.default(this._element).hasClass(mn)||u.default(this._element).hasClass("disabled")||(t=u.default(this._element).closest(".nav, .list-group")[0],n=c.getSelectorFromElement(this._element),t&&(r="UL"===t.nodeName||"OL"===t.nodeName?bn:yn,i=(i=u.default.makeArray(u.default(t).find(r)))[i.length-1]),r=u.default.Event("hide.bs.tab",{relatedTarget:this._element}),o=u.default.Event("show.bs.tab",{relatedTarget:i}),i&&u.default(i).trigger(r),u.default(this._element).trigger(o),o.isDefaultPrevented())||r.isDefaultPrevented()||(n&&(e=document.querySelector(n)),this._activate(this._element,t),o=function(){var e=u.default.Event("hidden.bs.tab",{relatedTarget:a._element}),t=u.default.Event("shown.bs.tab",{relatedTarget:i});u.default(i).trigger(e),u.default(a._element).trigger(t)},e?this._activate(e,e.parentNode,o):o())},e.dispose=function(){u.default.removeData(this._element,pn),this._element=null},e._activate=function(e,t,n){function i(){return r._transitionComplete(e,o,n)}var r=this,o=(!t||"UL"!==t.nodeName&&"OL"!==t.nodeName?u.default(t).children(yn):u.default(t).find(bn))[0],t=n&&o&&u.default(o).hasClass("fade");o&&t?(t=c.getTransitionDurationFromElement(o),u.default(o).removeClass("show").one(c.TRANSITION_END,i).emulateTransitionEnd(t)):i()},e._transitionComplete=function(e,t,n){var i;t&&(u.default(t).removeClass(mn),(i=u.default(t.parentNode).find("> .dropdown-menu .active")[0])&&u.default(i).removeClass(mn),"tab"===t.getAttribute("role"))&&t.setAttribute("aria-selected",!1),u.default(e).addClass(mn),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!0),c.reflow(e),e.classList.contains("fade")&&e.classList.add("show"),e.parentNode&&u.default(e.parentNode).hasClass("dropdown-menu")&&((i=u.default(e).closest(".dropdown")[0])&&(t=[].slice.call(i.querySelectorAll(".dropdown-toggle")),u.default(t).addClass(mn)),e.setAttribute("aria-expanded",!0)),n&&n()},i._jQueryInterface=function(n){return this.each(function(){var e=u.default(this),t=e.data(pn);if(t||(t=new i(this),e.data(pn,t)),"string"==typeof n){if(void 0===t[n])throw new TypeError('No method named "'+n+'"');t[n]()}})},a(i,null,[{key:"VERSION",get:function(){return"4.5.3"}}]),i}(),$n=(u.default(document).on("click.bs.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"], [data-toggle="list"]',function(e){e.preventDefault(),vn._jQueryInterface.call(u.default(this),"show")}),u.default.fn.tab=vn._jQueryInterface,u.default.fn.tab.Constructor=vn,u.default.fn.tab.noConflict=function(){return u.default.fn.tab=gn,vn._jQueryInterface},"toast"),Cn="bs.toast",tt="."+Cn,wn=u.default.fn[$n],_n="click.dismiss"+tt,Sn="show",xn="showing",Tn={animation:"boolean",autohide:"boolean",delay:"number"},kn={animation:!0,autohide:!0,delay:500},Dn=function(){function i(e,t){this._element=e,this._config=this._getConfig(t),this._timeout=null,this._setListeners()}var e=i.prototype;return e.show=function(){var e,t=this,n=u.default.Event("show.bs.toast");u.default(this._element).trigger(n),n.isDefaultPrevented()||(this._clearTimeout(),this._config.animation&&this._element.classList.add("fade"),n=function(){t._element.classList.remove(xn),t._element.classList.add(Sn),u.default(t._element).trigger("shown.bs.toast"),t._config.autohide&&(t._timeout=setTimeout(function(){t.hide()},t._config.delay))},this._element.classList.remove("hide"),c.reflow(this._element),this._element.classList.add(xn),this._config.animation?(e=c.getTransitionDurationFromElement(this._element),u.default(this._element).one(c.TRANSITION_END,n).emulateTransitionEnd(e)):n())},e.hide=function(){var e;this._element.classList.contains(Sn)&&(e=u.default.Event("hide.bs.toast"),u.default(this._element).trigger(e),e.isDefaultPrevented()||this._close())},e.dispose=function(){this._clearTimeout(),this._element.classList.contains(Sn)&&this._element.classList.remove(Sn),u.default(this._element).off(_n),u.default.removeData(this._element,Cn),this._element=null,this._config=null},e._getConfig=function(e){return e=s({},kn,u.default(this._element).data(),"object"==typeof e&&e?e:{}),c.typeCheckConfig($n,e,this.constructor.DefaultType),e},e._setListeners=function(){var e=this;u.default(this._element).on(_n,'[data-dismiss="toast"]',function(){return e.hide()})},e._close=function(){function e(){n._element.classList.add("hide"),u.default(n._element).trigger("hidden.bs.toast")}var t,n=this;this._element.classList.remove(Sn),this._config.animation?(t=c.getTransitionDurationFromElement(this._element),u.default(this._element).one(c.TRANSITION_END,e).emulateTransitionEnd(t)):e()},e._clearTimeout=function(){clearTimeout(this._timeout),this._timeout=null},i._jQueryInterface=function(n){return this.each(function(){var e=u.default(this),t=e.data(Cn);if(t||(t=new i(this,"object"==typeof n&&n),e.data(Cn,t)),"string"==typeof n){if(void 0===t[n])throw new TypeError('No method named "'+n+'"');t[n](this)}})},a(i,null,[{key:"VERSION",get:function(){return"4.5.3"}},{key:"DefaultType",get:function(){return Tn}},{key:"Default",get:function(){return kn}}]),i}();u.default.fn[$n]=Dn._jQueryInterface,u.default.fn[$n].Constructor=Dn,u.default.fn[$n].noConflict=function(){return u.default.fn[$n]=wn,Dn._jQueryInterface},e.Alert=n,e.Button=G,e.Carousel=r,e.Collapse=ce,e.Dropdown=x,e.Modal=It,e.Popover=nn,e.Scrollspy=fn,e.Tab=vn,e.Toast=Dn,e.Tooltip=A,e.Util=c,Object.defineProperty(e,"__esModule",{value:!0})}),function(y){var b="iCheck",v=b+"-helper",$="checkbox",C="radio",w="checked",f="un"+w,_="disabled",p="determinate",S="in"+p,x="update",T="type",k="click",D="touchbegin.i touchend.i",j="addClass",I="removeClass",A="trigger",E="label",g="cursor",N=/ip(hone|od|ad)|android|blackberry|windows phone|opera mini|silk/i.test(navigator.userAgent)||"MacIntel"===navigator.platform&&1")[A]("ifCreated").parent().append(u.insert),o=y('').css(t).appendTo(l),i.data(b,{o:u,s:i.attr("style")}).css(n),u.inheritClass&&l[j](r.className||""),u.inheritID&&e&&l.attr("id",b+"-"+e),"static"==l.css("position")&&l.css("position","relative"),L(i,!0,x),a.length&&a.on(k+".i mouseover.i mouseout.i "+D,function(e){var t=e[T],n=y(this);if(!r[_]){if(t==k){if(y(e.target).is("a"))return;L(i,!1,!0)}else p&&(/ut|nd/.test(t)?(l[I](c),n[I](g)):(l[j](c),n[j](g)));if(!N)return!1;e.stopPropagation()}}),i.on(k+".i focus.i blur.i keyup.i keydown.i keypress.i",function(e){var t=e[T],e=e.keyCode;return t!=k&&("keydown"==t&&32==e?(r[T]==C&&r[w]||(r[w]?P:M)(i,w),!1):void("keyup"==t&&r[T]==C?r[w]||M(i,w):/us|ur/.test(t)&&l["blur"==t?I:j](h)))}),o.on(k+" mousedown mouseup mouseover mouseout "+D,function(e){var t=e[T],n=/wn|up/.test(t)?f:c;if(!r[_]){if(t==k?L(i,!1,!0):(/wn|er|in/.test(t)?l[j](n):l[I](n+" "+f),a.length&&p&&n==c&&a[/ut|nd/.test(t)?I:j](g)),!N)return!1;e.stopPropagation()}})}))}}(window.jQuery||window.Zepto),function(e){"object"!=typeof e.WHMCS&&(e.WHMCS={hasModule:function(e){return typeof WHMCS[e]!=="undefined"&&Object.getOwnPropertyNames(WHMCS[e]).length>0},loadModule:function(e,t){if(this.hasModule(e))return;WHMCS[e]={};if(typeof t==="function")t.apply(WHMCS[e]);else for(var n in t)if(t.hasOwnProperty(n)){WHMCS[e][n]={};t[n].apply(WHMCS[e][n])}}})}(window),jQuery(document).ready(function(){jQuery(document).on("click",".disable-on-click",function(){var e;jQuery(this).addClass("disabled"),jQuery(this).hasClass("spinner-on-click")&&(e=$(this).find("i.fas,i.far,i.fal,i.fab"),jQuery(e).removeAttr("class").addClass("fas fa-spinner fa-spin"))}).on("click","#openTicketSubmit.disabled",function(){return!1})}),WHMCS.hasModule("authn")||WHMCS.loadModule("authn",{provider:function(){var t=!1;return this.feedbackContainer=function(){return jQuery(".providerLinkingFeedback")},this.btnContainer=function(){return jQuery(".providerPreLinking")},this.feedbackMessage=function(e){void 0===e&&(e="complete_sign_in");e=jQuery("p.providerLinkingMsg-preLink-"+e);return e.length?e.first().html():""},this.showProgressMessage=function(e){this.feedbackContainer().fadeIn("fast",function(){"function"!=typeof e||t||(t=!0,e())})},this.preLinkInit=function(e){this.feedbackContainer().removeClass("alert-danger alert-success").addClass("alert alert-info").html(' '+this.feedbackMessage()).hide();var t,n=this.btnContainer();n.length?n.data("hideOnPrelink")?(t=this,n.fadeOut("false",function(){t.showProgressMessage(e)})):(n.data("disableOnPrelink")&&n.find(".btn").addClass("disabled"),this.showProgressMessage(e)):this.showProgressMessage(e)},this.displayError=function(e,t,n){jQuery("#providerLinkingMessages .provider-name").html(e);e=this.feedbackMessage("connect_error");t&&(t=this.feedbackMessage(t))&&(e=t),n&&0<$(".btn-logged-in-admin").length&&(e+=" Error: "+n),this.feedbackContainer().removeClass("alert-info alert-success").addClass("alert alert-danger").html(e).slideDown()},this.displaySuccess=function(e,t,n){var i,r,o,a=n.icon,s=t.htmlTarget,d=t.targetLogin,l=t.targetRegister,u=n.name,c="";switch(e.result){case"logged_in":case"2fa_needed":c=this.feedbackMessage("2fa_needed"),this.feedbackContainer().removeClass("alert-danger alert-warning alert-success").addClass("alert alert-info").html(c),window.location=e.redirect_url?decodeURIComponent(e.redirect_url):decodeURIComponent(t.redirectUrl);break;case"linking_complete":var h="";h=(h=e.remote_account.email||e.remote_account.firstname+" "+e.remote_account.lastname).trim(),c=this.feedbackMessage("linking_complete").trim().replace(":displayName",u),h&&(c=c.replace(/\.$/," ("+h+").")),this.feedbackContainer().removeClass("alert-danger alert-warning alert-info").addClass("alert alert-success").html(a+c);break;case"login_to_link":s===d?(c=this.feedbackMessage("login_to_link-signin-required"),this.feedbackContainer().removeClass("alert-danger alert-success alert-info").addClass("alert alert-warning").html(a+c)):(h=jQuery("input[name=email]"),i=jQuery("input[name=firstname]"),r=jQuery("input[name=lastname]"),""===h.val()&&h.val(e.remote_account.email),""===i.val()&&i.val(e.remote_account.firstname),""===r.val()&&r.val(e.remote_account.lastname),s===l?("object"==typeof WHMCS.client.registration&&WHMCS.client.registration.prefillPassword(),c=this.feedbackMessage("login_to_link-registration-required"),this.feedbackContainer().fadeOut("slow",function(){$(this).removeClass("alert-danger alert-success alert-info").addClass("alert alert-warning").html(a+c).fadeIn("fast")})):("object"==typeof WHMCS.client.registration&&WHMCS.client.registration.prefillPassword(),(o=this).feedbackContainer().each(function(e,t){var n=$(t),i=n.siblings("div .providerPreLinking").data("linkContext");n.fadeOut("slow",function(){c="checkout-new"===i?o.feedbackMessage("checkout-new"):o.feedbackMessage("login_to_link-signin-required"),n.removeClass("alert-danger alert-success alert-info").addClass("alert alert-warning").html(a+c).fadeIn("fast")})})));break;case"other_user_exists":c=this.feedbackMessage("other_user_exists"),this.feedbackContainer().removeClass("alert-info alert-success").addClass("alert alert-danger").html(a+c).slideDown();break;case"already_linked":c=this.feedbackMessage("already_linked"),this.feedbackContainer().removeClass("alert-info alert-success").addClass("alert alert-danger").html(a+c).slideDown();break;default:c=this.feedbackMessage("default"),this.feedbackContainer().removeClass("alert-info alert-success").addClass("alert alert-danger").html(a+c).slideDown()}},this.signIn=function(e,t,n,i,r){jQuery.ajax(e).done(function(e){i(),WHMCS.authn.provider.displaySuccess(e,t,n),jQuery("#tableLinkedAccounts").length&&WHMCS.ui.dataTable.getTableById("tableLinkedAccounts").ajax.reload()}).error(function(){r(),WHMCS.authn.provider.displayError()})},this}}),function(e){WHMCS.hasModule("client")||WHMCS.loadModule("client",e)}({registration:function(){return this.prefillPassword=function(i){function e(){for(var e=WHMCS.utils.simpleRNG(),t=0,n=i.form.password.length;t").attr("id","whmcsAutoPostForm").attr("target","_self").attr("method","POST").append(jQuery("").attr("type","hidden").attr("name","token").attr("value",csrfToken)),jQuery("body").append(this.postForm)),this.postForm},this.isSameOrigin=function(e){return e.origin&&e.origin===this.hostOrigin},this.isClientModopCustom=function(e){return!(!e.pathname||!e.pathname.match(/\/clientarea.php$/)||!e.searchParams||"custom"!==e.searchParams.get("modop"))},this.getFqUrl=function(e){try{return e.match(/[a-z]+:\/\//i)||(0!==e.indexOf("/")&&(e=window.location.pathname.split("/").slice(0,-1).join("/")+"/"+e),e=""+this.hostOrigin+e),url=new URL(e)}catch(e){return null}},this.isUrlEligibleForToken=function(e){return!("string"==typeof e&&!(e=this.getFqUrl(e))||"object"!=typeof e||!this.isSameOrigin(e))&&this.isClientModopCustom(e)},this.submitUrlViaPost=function(e,t){jQuery(this.getAutoPostForm()).attr("target",t||"_self").attr("action",e).submit()},this.processTokenSubmitters=function(){jQuery("a").each((e,n)=>{const i=jQuery(n).attr("href");i&&this.isUrlEligibleForToken(i)&&!jQuery(n).data("whmcs-tokenized")&&(jQuery(n).data("whmcs-tokenized",!0),jQuery(n).attr("href","#"),jQuery(n).on("click",e=>{let t=jQuery(n).attr("target");(e.metaKey||e.ctrlKey)&&(t="_blank"),e.preventDefault(),this.submitUrlViaPost(i,t)}),jQuery(n).on("contextmenu",e=>(e.preventDefault(),!1)))})}}}),function(e){WHMCS.hasModule("http")||WHMCS.loadModule("http",e)}({jqClient:function(){return _getSettings=function(e,t,n,i){return"object"==typeof e?e:("function"==typeof t&&(n=t,t=null),{url:e,data:t,success:n,dataType:i})},this.get=function(e,t,n,i){return WHMCS.http.client.request(jQuery.extend(_getSettings(e,t,n,i),{type:"GET"}))},this.post=function(e,t,n,i){return WHMCS.http.client.request(jQuery.extend(_getSettings(e,t,n,i),{type:"POST"}))},this.jsonGet=function(n){n=n||{},this.get(n.url,n.data,function(e){e.warning?(console.log("[WHMCS] Warning: "+e.warning),"function"==typeof n.warning&&n.warning(e.warning)):e.error?(console.log("[WHMCS] Error: "+e.error),"function"==typeof n.error&&n.error(e.error)):"function"==typeof n.success&&n.success(e)},"json").error(function(e,t){console.log("[WHMCS] Error: "+t),"function"==typeof n.fail&&n.fail(t)}).always(function(){"function"==typeof n.always&&n.always()})},this.jsonPost=function(i){i=i||{},this.post(i.url,i.data,function(e,t,n){e.warning?(console.log("[WHMCS] Warning: "+e.warning),"function"==typeof i.warning&&i.warning(e.warning,e,n)):e.error?(console.log("[WHMCS] Error: "+e.error),"function"==typeof i.error&&i.error(e.error,e,n)):"function"==typeof i.success&&i.success(e,n)},"json").fail(function(e,t,n){console.log("[WHMCS] Fail: "+t),"function"==typeof i.fail&&i.fail(t,e.responseJSON,e)}).always(function(e,t,n){"function"==typeof i.always&&i.always(e)})},this},client:function(){var r=this;return _beforeRequest=function(e){return void 0===e.type&&(e.type="GET"),e},this.request=function(e){return e=_beforeRequest(e||{}),jQuery.ajax(e)},jQuery.each(["get","post","put","delete"],function(e,t){var n,i;r[t]=(n=t,i=r,function(e){return(e=e||{}).type=n.toUpperCase(),i.request(e)})}),this}}),WHMCS.hasModule("ui")||WHMCS.loadModule("ui",{confirmation:function(){var t=[];return this.register=function(e){return t.indexOf(e=void 0===e?"[data-toggle=confirmation]":e)<0&&t.push(e),jQuery(e).confirmation({rootSelector:e}),t},this},dataTable:function(){return this.tables={},this.register=function(){var n=this;jQuery("table.data-driven").each(function(e,t){n.getTableById(t.id,void 0)})},this.getTableById=function(e,n){var t,i,r=jQuery("#"+e);return void 0===this.tables[e]?(void 0===n&&(n={dom:'<"listtable"ift>pl',paging:!1,lengthChange:!1,searching:!1,ordering:!0,info:!1,autoWidth:!0,columns:[],lengthMenu:[10,25,50,100,500,1e3],language:{emptyTable:r.data("langEmptyTable")?r.data("langEmptyTable"):"No records found"}}),jQuery.each(r.data(),function(e,t){void 0!==t&&("ajaxUrl"===e?n.ajax={url:t}:"lengthChange"===e?n.lengthChange=t:"pageLength"===e?n.pageLength=t:"langEmptyTable"===e?(void 0===n.language&&(n.language={}),n.language.emptyTable=t):"langZeroRecords"===e?(void 0===n.language&&(n.language={}),n.language.zeroRecords=t):n.key=t)}),jQuery.each(r.find("th"),function(){void 0===n.columns&&(n.columns=[]),n.columns.push({data:jQuery(this).data("name")})}),this.tables[e]=this.initTable(r,n)):void 0!==n&&(i=(t=this.tables[e]).init(),i=jQuery.extend(i,n),t.destroy(),this.tables[e]=this.initTable(r,i)),this.tables[e]},this.initTable=function(i,e){var e=i.DataTable(e),t=this;return i.data("on-draw")?e.on("draw.dt",function(e,t){var n=i.data("on-draw");"function"==typeof window[n]&&window[n](e,t)}):i.data("on-draw-rebind-confirmation")&&e.on("draw.dt",function(e){t.rebindConfirmation(e)}),e},this.rebindConfirmation=function(e){for(var t=this,n=e.target.id,i=WHMCS.ui.confirmation.register(),r=0,o=i.length;r").css("position","fixed").css("opacity","0").css("width","1px").css("height","1px").val($(t).val());n.append(i),i.focus().select(),document.execCommand("copy")}finally{i.remove()}e.tooltip({trigger:"click",placement:"bottom"}),WHMCS.ui.toolTip.setTip(e,"Copied!"),WHMCS.ui.toolTip.hideTip(e)},this},toolTip:function(){this.setTip=function(e,t){var n=e.data("bs.tooltip");return"in"!==n.hoverState&&(n.hoverState="in"),e.attr("data-original-title",t),n.show(),n},this.hideTip=function(e,t){return t=t||2e3,setTimeout(function(){e.data("bs.tooltip").hide()},t)}},jsonForm:function(){return this.managedElements="input,textarea,select",this.initFields=function(e){var t=this;$(e).find(t.managedElements).each(function(){var e=this;$(e).on("keypress change",function(){t.fieldHasError(e)&&t.clearFieldError(e)})})},this.init=function(t){var n=this;n.initFields(t),$(t).on("submit",function(e){e.preventDefault(),e.stopPropagation(),n.clearErrors(t);e=$(t).parents('.modal[role="dialog"]').first();$(e).length&&($(e).on("show.bs.modal hidden.bs.modal",function(){n.clearErrors(t)}),$(e).on("show.bs.modal",function(){$(t)[0].reset()})),WHMCS.http.client.post({url:$(t).attr("action"),data:$(t).serializeArray()}).done(function(e){n.onSuccess(t,e)}).fail(function(e){n.onError(t,e)}).always(function(e){n.onRequestComplete(t,e)})})},this.initAll=function(){var e=this;$('form[data-role="json-form"]').each(function(){e.init(this)})},this.markFieldErrors=function(e,t){var n,i,r=null;for(i in t)t.hasOwnProperty(i)&&(r=t[i]),n=this.managedElements.split(",").map(function(e){return e+'[name="'+i+'"]'}).join(","),n=$(e).find(n),r&&($(n).parents(".form-group").addClass("has-error"),$(n).attr("title",r),$(n).tooltip());$(e).find(".form-group.has-error input[title]").first().tooltip("show")},this.fieldHasError=function(e){return $(e).parents(".form-group").hasClass("has-error")},this.clearFieldError=function(t){try{$(t).tooltip("dispose")}catch(e){$(t).tooltip("destroy")}$(t).parents(".form-group").removeClass("has-error")},this.onSuccess=function(e,t){e=$(e).data("on-success");"function"==typeof e&&e(t.data)},this.onError=function(e,t){t.responseJSON&&t.responseJSON.fields&&"object"==typeof t.responseJSON.fields?this.markFieldErrors(e,t.responseJSON.fields):console.log("Unknown error - please try again later.");e=$(e).data("on-error");"function"==typeof e&&e(t)},this.clearErrors=function(e){var t=this;$(e).find(t.managedElements).each(function(){t.clearFieldError(this)})},this.onRequestComplete=function(e,t){},this},effects:function(){this.errorShake=function(e){var d={},d=$.extend({direction:"left",distance:8,times:3,speed:90},d);return e.each(function(){var e=$(this),t={position:e.css("position"),top:e.css("top"),bottom:e.css("bottom"),left:e.css("left"),right:e.css("right")},n=(e.css("position","relative"),"up"===d.direction||"down"===d.direction?"top":"left"),i="up"===d.direction||"left"===d.direction?"pos":"neg",r={},o={},a={};r[n]=("pos"==i?"-=":"+=")+d.distance,o[n]=("pos"==i?"+=":"-=")+2*d.distance,a[n]=("pos"==i?"-=":"+=")+2*d.distance,e.animate(r,d.speed);for(var s=1;s${gravatar} ${username} - ${name} (${email})',insertTpl:mentionsFormat,data:e.data("tagging-url"),limit:5})},this.getEditorById=function(e){var t=jQuery("#"+e);return void 0===this.editors[e]&&(this.editors[e]=this.init(t)),this.editors[e]},this.init=function(e){let i=this,r=e.attr("id");var t=r+"-footer";let o="#"+t;var t='
',n=void 0===e.data("locale")?"en":e.data("locale");let a=e.data("localStorageId"),s=csrfToken,d=e.data("fetchPreviewUrl");return i.counters[r]=0,e.markdown({footer:t,autofocus:!1,savable:!1,resize:"vertical",iconlibrary:"glyph",language:n,onShow:function(e){let t="",n=!1;"undefined"!=typeof Storage&&(t=localStorage.getItem(a),n=!0,t)&&void 0!==t&&e.setContent(t),jQuery(o).html(i.parseMdeFooter(t,n,"saved"))},onChange:function(e){let t=e.getContent(),n=!1;r=e.$element.attr("id"),"undefined"!=typeof Storage&&(i.counters[r]=3,n=!0,localStorage.setItem(a,t),i.doCountdown(r)),jQuery(o).html(i.parseMdeFooter(t,n))},onPreview:function(e){let t=e.getContent(),n;return jQuery.ajax({url:d,async:!1,data:{token:s,action:"parseMarkdown",content:t},dataType:"json",success:function(e){n=e},method:"POST"}),n.body||""},additionalButtons:[[{name:"groupCustom",data:[{name:"cmdHelp",title:"Help",hotkey:"Ctrl+F1",btnClass:"btn open-modal",icon:{glyph:"fas fa-question-circle",fa:"fas fa-question-circle","fa-3":"icon-question-sign"},callback:function(e){e.$editor.removeClass("md-fullscreen-mode")}}]}]],hiddenButtons:["cmdImage"]}),i.addEventHelpModal(e),e},this.parseMdeFooter=function(e,t,n){void 0===n&&(n="autosaving");let i=[],r=0,o=0;if(e&&(i=e.match(/[^\s]+/g),o=e.split(/\\r\\n|\\r|\\n/).length),i)for(let e=0;elines: '+o+"   words: "+r+(t?'   '+n+"":"")+""},this.doCountdown=function(e){let t=this;0<=t.counters[e]&&(0===t.counters[e]&&jQuery("span.markdown-save").html("saved"),t.counters[e]--,setTimeout(function(e){t.doCountdown(e)},1e3,e))},this.addEventHelpModal=function(e){return e.parent().find('button[data-handler="bootstrap-markdown-cmdHelp"]').attr("data-modal-title","Markdown Guide").attr("data-modal-size","modal-lg").attr("href",e.data("fetchHelpUrl")),this}}}),WHMCS.hasModule("form")||WHMCS.loadModule("form",function(){return this.checkAllBound=false,this.register=function(){if(!this.checkAllBound){this.bindCheckAll();this.checkAllBound=true}},this.bindCheckAll=function(){var e=".btn-check-all";jQuery("body").on("click",e,function(e){var t=jQuery(e.target);var n=jQuery("#"+t.data("checkbox-container")+' input[type="checkbox"]');if(t.data("btn-check-toggle")){var i="Deselect All";var r="Select All";if(t.data("label-text-deselect"))i=t.data("label-text-deselect");if(t.data("label-text-select"))r=t.data("label-text-select");if(t.hasClass("toggle-active")){n.prop("checked",false);t.text(r);t.removeClass("toggle-active")}else{n.prop("checked",true);t.text(i);t.addClass("toggle-active")}}else if(t.data("btn-toggle-on"))n.prop("checked",true);else n.prop("checked",false)})},this.reloadCaptcha=e=>{if(typeof grecaptcha!=="undefined"){recaptchaValidationComplete=false;grecaptcha.reset();WHMCS.recaptcha.restoreDefaultCallback();return}if(!e)e=jQuery("#inputCaptchaImage");const t=jQuery("#inputCaptcha");if(e.length){e.attr("src",whmcsBaseUrl+"/includes/verifyimage.php?nocache="+(new Date).getTime());t.val("")}},this});var currentcheckcontent,lastcheckcontent,lastTicketMsg,recaptchaLoadComplete=!1,recaptchaCount=0,recaptchaType="recaptcha",recaptchaValidationComplete=!1;function disableFields(e,t){"."!==e[0]&&(e="."+e);e=jQuery(e);e.prop("disabled",t),t?e.addClass("disabled"):e.removeClass("disabled")}function checkAll(e,t){"."!==e[0]&&(e="."+e),jQuery(e).removeAttr("checked"),jQuery(t).is(":checked")&&jQuery(e).click()}function clickableSafeRedirect(e,t,n){var i=e.target.tagName.toLowerCase(),r=e.target.parentNode.tagName.toLowerCase(),o=e.target.parentNode.parentNode.parentNode;return!(jQuery(o).hasClass("collapsed")||"i"===i&&jQuery(e.target).hasClass("ssl-required"))&&void("button"!==i&&"a"!==i&&"button"!==r&&"a"!==r&&(n?window.open(t):window.location.href=t))}function popupWindow(e,t,n,i,r){var o=(screen.width-n)/2,a=(screen.height-i)/2,i=(i=(i="height="+i+",")+("width="+n+",")+("top="+(a=a<0?0:a)+","))+("left="+(o=o<0?0:o)+",")+r;window.open(e,t,i).window.focus()}function selectChangeNavigate(e){e=$(e).val();"object"==typeof WHMCS.client.tokenProcessor&&WHMCS.client.tokenProcessor.isUrlEligibleForToken(e)?WHMCS.client.tokenProcessor.submitUrlViaPost(e):window.location.href=e}function getStats(t){WHMCS.http.jqClient.post("serverstatus.php","getstats=1&num="+t,function(e){jQuery("#load"+t).html(e.load),jQuery("#uptime"+t).html(e.uptime)},"json")}function checkPort(t,n){WHMCS.http.jqClient.post("serverstatus.php","ping=1&num="+t+"&port="+n,function(e){jQuery("#port"+n+"_"+t).html(e)})}function getticketsuggestions(){(currentcheckcontent=jQuery("#message").val())!==lastcheckcontent&&""!==currentcheckcontent&&(WHMCS.http.jqClient.post("submitticket.php",{action:"getkbarticles",text:currentcheckcontent},function(e){e&&jQuery("#searchresults").html(e).slideDown()}),lastcheckcontent=currentcheckcontent),setTimeout("getticketsuggestions();",3e3)}function refreshCustomFields(e){jQuery("#customFieldsContainer").load("submitticket.php",{action:"getcustomfields",deptid:$(e).val()})}function autoSubmitFormByContainer(e){"undefined"!=typeof noAutoSubmit&&!1!==noAutoSubmit||jQuery("#"+e).find("form:first").submit()}function useDefaultWhois(e){jQuery("."+e.substr(0,e.length-1)+"customwhois").attr("disabled",!0),jQuery("."+e.substr(0,e.length-1)+"defaultwhois").attr("disabled",!1),jQuery("#"+e.substr(0,e.length-1)+"1").attr("checked","checked")}function useCustomWhois(e){jQuery("."+e.substr(0,e.length-1)+"customwhois").attr("disabled",!1),jQuery("."+e.substr(0,e.length-1)+"defaultwhois").attr("disabled",!0),jQuery("#"+e.substr(0,e.length-1)+"2").attr("checked","checked")}function showNewBillingAddressFields(){jQuery("#newBillingAddress").parent("div").slideDown()}function hideNewBillingAddressFields(){jQuery("#newBillingAddress").parent("div").slideUp()}function showNewCardInputFields(){var e=jQuery(".cc-details"),t=jQuery("#inputCardNumber"),n=jQuery("#billingAddressChoice"),e=e.parent("div");e.not(":visible")&&e.show(),jQuery(".cc-details").slideDown(),t.focus(),(e=n.parent("div")).not(":visible")&&e.show(),n.slideDown().find('input[name="billingcontact"]').first().iCheck("check")}function showNewAccountInputFields(){var e=jQuery(".bank-details").parent("div");e.not(":visible")&&e.slideDown(),jQuery("#billingAddressChoice").parent("div").slideDown().find('input[name="billingcontact"]').first().iCheck("check")}function hideNewCardInputFields(){hideNewBillingAddressFields(),jQuery(".cc-details").slideUp(),jQuery("#billingAddressChoice").slideUp();var e=jQuery('input[name="ccinfo"]:checked').data("billing-contact-id");null!=e&&jQuery("#billingAddressChoice label.billing-contact-"+e).iCheck("check"),jQuery("#inputCardCvv").focus()}function hideNewAccountInputFields(){hideNewBillingAddressFields(),jQuery(".bank-details").parent("div").slideUp(),jQuery("#billingAddressChoice").parent("div").slideUp();var e=jQuery('input[name="paymethod"]:checked'),e=jQuery(e).data("billing-contact-id"),e=jQuery('.billing-contact-info[data-billing-contact-id="'+e+'"]');e.length&&(jQuery(".billing-contact-info").hide(),jQuery(e).show())}function getTicketSuggestions(){var e=jQuery("#inputMessage").val();e!==lastTicketMsg&&""!==e&&(WHMCS.http.jqClient.post("submitticket.php",{action:"getkbarticles",text:e},function(e){var t=jQuery("#autoAnswerSuggestions");e&&(t.html(e),t.not(":visible"))&&t.slideDown()}),lastTicketMsg=e),setTimeout("getTicketSuggestions()",3e3)}function smoothScroll(e){$("html, body").animate({scrollTop:$(e).offset().top},500)}WHMCS.hasModule("recaptcha")||WHMCS.loadModule("recaptcha",function(){return this.register=function(){if(recaptchaLoadComplete)return;var u=[],e=jQuery(".btn-recaptcha").parents("form"),c=false;e.each(function(e,t){if(typeof recaptcha.siteKey==="undefined"){console.error("Recaptcha site key not defined");return}if(typeof recaptcha.libUrl==="undefined"){console.error("Recaptcha client js url not defined");return}if(typeof recaptcha.apiObject==="undefined"){console.error("Recaptcha client js api object name not defined");return}recaptchaCount+=1;var n=jQuery(t),i=n.find(".btn-recaptcha"),r=typeof recaptcha.requiredText!=="undefined"?recaptcha.requiredText:"Required",o="divDynamicRecaptcha"+recaptchaCount;c=i.hasClass("btn-recaptcha-invisible");var a=n.find("#"+o+" .g-recaptcha"),s=n.find(".recaptcha-container"),d=n;if(s.length){s.attr("id",s.attr("id")+recaptchaCount);d=s}if(!a.length){d.append('
');a=d.find("#"+o)}if(!c)a.data("toggle","tooltip").data("placement","bottom").data("trigger","manual").attr("title",r).hide();var l=o+"Callback";window[l]=function(){if(c)n.submit()};if(c){recaptchaType="invisible";n.on("submit.recaptcha",function(e){var t=n.find(".g-recaptcha").data("recaptcha-id");if(!window[recaptcha.apiObject].getResponse(t).trim()){e.preventDefault();window[recaptcha.apiObject].execute(t);recaptchaValidationComplete=false}else recaptchaValidationComplete=true})}else{u.push(function(){a.slideDown("fast",function(){a.find(":first").addClass("center-block")})});u.push(function(){a.find(":first").addClass("center-block")})}});window.recaptchaLoadCallback=function(){jQuery(".g-recaptcha").each(function(e,t){var n=jQuery(t),i=n.closest("form"),r=i.find(".btn-recaptcha"),o=n.attr("id").substring(1);var a=grecaptcha.render(t,{sitekey:recaptcha.siteKey,size:r.hasClass("btn-recaptcha-invisible")?"invisible":"normal",callback:o+"Callback"});n.data("recaptcha-id",a)})};if(e.length)jQuery.getScript(recaptcha.libUrl,function(){for(var e=u.length-1;e>=0;e--)u[e]()});let t=jQuery(".captcha-overlay-badge"),n=jQuery(".captcha-overlay-popup");if(e.length&&t.length){t.show();if(n.length){let r;function i(){n.hide()}function o(n,i){return function(){const e=this;const t=arguments;clearTimeout(r);r=setTimeout(function(){n.apply(e,t)},i)}}const a=o(i,3e3);t.bind("mouseenter",function(){n.show();clearTimeout(r)});t.bind("mouseleave",a);t.bind("touchstart",function(){n.show();clearTimeout(r);r=setTimeout(i,3e3)})}}recaptchaLoadComplete=true},this.setupCallback=o=>{if(typeof o!=="function")return;jQuery(".g-recaptcha").each(function(e,t){const n=jQuery(t).attr("id").substring(1);const i=n+"Callback";const r=i+"Original";if(typeof window[r]==="undefined")window[r]=window[i];window[i]=o})},this.restoreDefaultCallback=()=>{jQuery(".g-recaptcha").each(function(e,t){const n=jQuery(t).attr("id").substring(1);const i=n+"Callback";const r=i+"Original";if(typeof window[r]!=="undefined"){window[i]=window[r];delete window[r]}})},this}),function(e){WHMCS.hasModule("payment")||WHMCS.loadModule("payment",e)}({internal:function(){this.isRenderSource=function(e){return["checkout","invoice-pay","admin-payment-method-add","admin-payment-method-edit","payment-method-add","payment-method-edit"].includes(e)},this.reportUnknownSource=function(e){return!WHMCS.payment.internal.isRenderSource(e)&&(WHMCS.payment.internal.logError("unknown source: "+e),!0)},this.logError=function(e){console.error("[WHMCS.payment] "+e)}},handler:function(){this.make=function(e){return new function(e){this.module=e,this.onGatewayInit=function(e,t={}){t={...WHMCS.payment.register.defaultEventOpts(),...t};return WHMCS.payment.register.onGatewayInit(this.module,e,t),this},this.onGatewayOptionInit=function(e,t={}){t={...WHMCS.payment.register.defaultEventOpts(),...t};return WHMCS.payment.register.onGatewayOptionInit(this.module,e,t),this},this.onGatewaySelected=function(e,t={}){t={...WHMCS.payment.register.defaultEventOpts(),...t};return WHMCS.payment.register.onGatewaySelected(this.module,e,t),this},this.onGatewayUnselected=function(e,t={}){t={...WHMCS.payment.register.defaultEventOpts(),...t};return WHMCS.payment.register.onGatewayUnselected(this.module,e,t),this},this.onCheckoutFormSubmit=function(e,t={}){t={...WHMCS.payment.register.defaultEventOpts(),...t};return WHMCS.payment.register.onCheckoutFormSubmit(this.module,e,t),this},this.onAddPayMethodFormSubmit=function(e,t={}){t={...WHMCS.payment.register.defaultEventOpts(),...t};return WHMCS.payment.register.onAddPayMethodFormSubmit(this.module,e,t),this},this.manageInputsContainer=function(n,e={}){e={...WHMCS.payment.register.defaultEventOpts(),priority:1,...e};return this.onGatewayInit(function(e,t){"invoice-pay"==e._source&&(WHMCS.payment.display.reset(),WHMCS.payment.display.show(jQuery(n)))},e),this.onGatewaySelected(function(e,t){"payment-method-add"==e._source&&(WHMCS.payment.display.reset(),jQuery("div.fieldgroup-creditcard,div.fieldgroup-bankaccount,div.fieldgroup-auxfields").hide()),WHMCS.payment.display.show(jQuery(n))},e),this.onGatewayUnselected(function(e,t){WHMCS.payment.display.hide(jQuery(n))},e),this}}(e)}},register:function(){this.onGatewayInit=function(e,t,n){return this.isFunction("register.gatewayInit",t)&&this.registerForEvent(WHMCS.payment.event.observersGatewayInit,e,t,n),this},this.onGatewayOptionInit=function(e,t,n){return this.isFunction("register.gatewayOptionInit",t)&&this.registerForEvent(WHMCS.payment.event.observersGatewayOptionInit,e,t,n),this},this.onGatewaySelected=function(e,t,n){return this.isFunction("register.onGatewaySelected",t)&&this.registerForEvent(WHMCS.payment.event.observersGatewaySelected,e,t,n),this},this.onGatewayUnselected=function(e,t,n){return this.isFunction("register.onGatewayUnselected",t)&&this.registerForEvent(WHMCS.payment.event.observersGatewayUnselected,e,t,n),this},this.onCheckoutFormSubmit=function(e,t,n){return this.isFunction("register.onCheckoutFormSubmit",t)&&this.registerForEvent(WHMCS.payment.event.observersCheckoutFormSubmit,e,t,n),this},this.onAddPayMethodFormSubmit=function(e,t,n){return this.isFunction("register.onAddPayMethodFormSubmit",t)&&this.registerForEvent(WHMCS.payment.event.observersAddPayMethodFormSubmit,e,t,n),this},this.defaultEventOpts=function(){return{priority:100,once:!1}},this.registerForEvent=function(e,t,n,i){return e.has(t)||e.set(t,new Map),e.get(t).set(i.priority,{_fn:n,...i}),this},this.isFunction=function(e,t){return"function"==typeof t||(console.error("[register."+e+"] Expecting a function, got "+t),!1)}},event:function(){this.observersGatewayInit=new Map,this.observersGatewayOptionInit=new Map,this.observersGatewaySelected=new Map,this.observersGatewayUnselected=new Map,this.observersCheckoutFormSubmit=new Map,this.observersAddPayMethodFormSubmit=new Map,this.previouslySelected=null,this.gatewayInit=function(e,t){this.notifyEvent("gatewayInit",this.observersGatewayInit,t,e)},this.gatewayOptionInit=function(e,t,n){this.notifyEvent("gatewayOptionInit",this.observersGatewayOptionInit,t,e,n)},this.gatewaySelected=function(e,t,n){this.previouslySelected={formElement:n,module:t},this.notifyEvent("gatewaySelected",this.observersGatewaySelected,t,e,n)},this.gatewayUnselected=function(e){null!=this.previouslySelected&&this.notifyEvent("gatewayUnselected",this.observersGatewayUnselected,this.previouslySelected.module,e,this.previouslySelected.formElement)},this.checkoutFormSubmit=function(e,t,n){this.notifyEvent("checkoutFormSubmit",this.observersCheckoutFormSubmit,t,e,n)},this.addPayMethodFormSubmit=function(e,t,n){this.notifyEvent("addPayMethodFormSubmit",this.observersAddPayMethodFormSubmit,t,e,n)},this.notifyEvent=function(e,t,n,i,r){var o,a;t.has(n)&&(o=t.get(n),a=[],this.notifyOrdered(o,function(e,t){e._fn(i,r),e.once&&a.push(t)}),a.forEach(function(e){o.delete(e)}))},this.notifyOrdered=function(e,t){new Map([...e.entries()].sort()).forEach(t)}},query:function(){this.isGatewaySelected=function(e){return null!=WHMCS.payment.event.previouslySelected&&WHMCS.payment.event.previouslySelected.module==e}},behavior:function(){this.disableDefaultCardValidation=function(e){"invoice-pay"==e?"function"==typeof validateCreditCardInput&&jQuery("#frmPayment").off("submit",validateCreditCardInput):"checkout"==e?"function"==typeof validateCheckoutCreditCardInput&&jQuery("#frmCheckout").off("submit",validateCheckoutCreditCardInput):WHMCS.payment.internal.reportUnknownSource(e)},this.enableDefaultCardValidation=function(e){"invoice-pay"==e?"function"==typeof validateCreditCardInput&&jQuery("#frmPayment").on("submit",validateCreditCardInput):"checkout"==e?"function"==typeof validateCheckoutCreditCardInput&&jQuery("#frmCheckout").on("submit",validateCheckoutCreditCardInput):WHMCS.payment.internal.reportUnknownSource(e)}},display:function(){this.reset=function(){var e=jQuery("#paymentGatewayInput");if(0!=e.length)return(e=e.children()).hide(),jQuery("body").append(e),this},this.show=function(e){var t=jQuery("#paymentGatewayInput");if(0!=t.length)return t.append(e),e.slideDown(),this},this.hide=function(e){return e.slideUp({complete:function(){jQuery("body").append(e)}}),this},this.error=function(e){return jQuery(".gateway-errors").html(e),this},this.errorClear=function(){var e=jQuery(".gateway-errors");if(0!=e.length)return this.error(""),e.slideUp(),this},this.errorShow=(e,t="invoice-pay")=>{var n=jQuery(".gateway-errors");if("checkout"===t&&"function"==typeof showCheckoutError&&showCheckoutError(e,n),"invoice-pay"===t){if(0===n.length)return this;this.error(e),n.slideDown()}return this},this.submitReset=function(e){"invoice-pay"==e?this.invoiceSubmitReset():"checkout"==e?this.checkoutSubmitReset():WHMCS.payment.internal.reportUnknownSource(e)},this.invoiceSubmitReset=function(){var e=jQuery("#btnSubmit").prop("disabled",!1).removeClass("disabled");e.find(".click-text").hide(),e.find(".pay-text").show()},this.checkoutSubmitReset=function(){jQuery("#btnCompleteOrder").removeClass("disabled").removeClass("disable-on-click").removeClass("spinner-on-click").addClass("disable-on-click spinner-on-click").prop("disabled",!1).find("i.fas").removeAttr("class").addClass("fas fa-arrow-circle-right")},this.submitDisable=function(e){"invoice-pay"==e?this.invoiceSubmitDisable():"checkout"==e?this.checkoutSubmitDisable():WHMCS.payment.internal.reportUnknownSource(e)},this.invoiceSubmitDisable=function(){jQuery("#btnSubmit").addClass("disabled").prop("disabled",!0)},this.checkoutSubmitDisable=function(){jQuery("#btnCompleteOrder").addClass("disabled").prop("disabled",!0)}}}),function(e,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():e.MicroPlugin=t()}(this,function(){var e={mixin:function(i){i.plugins={},i.prototype.initializePlugins=function(e){var t,n,i,r=[];if(this.plugins={names:[],settings:{},requested:{},loaded:{}},o.isArray(e))for(t=0,n=e.length;t.5)i+=btoa(v).substr(0,4);else i+=v;if(Math.random()>.5)i+=e.substr(Math.floor(Math.random()*13),1)}return i},this.getRouteUrl=function(e){return whmcsBaseUrl+"/index.php?rp="+e},this.validateBaseUrl=function(){if(typeof window.whmcsBaseUrl==="undefined"){console.log("Warning: The WHMCS Base URL definition is missing "+"from your active template. Please refer to "+"https://go.whmcs.com/1961/base-url "+"for more information and details of how to resolve this "+"warning.");window.whmcsBaseUrl=this.autoDetermineBaseUrl();window.whmcsBaseUrlAutoSet=true}else if(window.whmcsBaseUrl===""&&typeof window.whmcsBaseUrlAutoSet!=="undefined"&&window.whmcsBaseUrlAutoSet===true)window.whmcsBaseUrl=this.autoDetermineBaseUrl()},this.autoDetermineBaseUrl=function(){var e=window.location.href;var t=-1;if(typeof e!=="undefined")t=e.indexOf(".php");if(t===-1){e=jQuery("#Primary_Navbar-Home a").attr("href");if(typeof e!=="undefined")t=e.indexOf(".php")}if(t!==-1){e=e.substring(0,t);var n=e.lastIndexOf("/");if(n!==false)return e.substring(0,n)}return""},this.normaliseStringValue=function(e){return e?e.toLowerCase().replace(/\s/g,"-"):""},this.generatePassword=function(e){var t=this.getPasswordCharacterSet();var n="";for(var i=0;e>i;i++)n+=t[this.randomInt(t.length)];return n},this.getPasswordCharacterSet=function(){var e="0123456789"+"abcdefghijklmnopqrstuvwxyz"+"ABCDEFGHIJKLMNOPQRSTUVWXYZ"+"!#$%()*+,-.:;=@_|{ldelim}{rdelim}~";var t=[];for(var n=0;e.length>n;n++){var i=e.charCodeAt(n);if(55296>i||i>=57344){var r=e.charAt(n);if(t.indexOf(r)==-1)t.push(r);continue}if(56320>i?e.length>n+1:false){var o=e.charCodeAt(n+1);if(o>=56320?57344>o:false){var r=e.substring(n,n+2);n++;if(t.indexOf(r)==-1)t.push(r);continue}}throw"Invalid UTF-16"}return t},this.randomInt=function(e){var t=this.randomIntMathRandom(e);t=(t+this.randomIntBrowserCrypto(e))%e;return t},this.randomIntMathRandom=function(e){var t=Math.floor(Math.random()*e);if(0>t||t>=e)throw"Arithmetic exception";return t},this.randomIntBrowserCrypto=function(e){var t=null;if("crypto"in window)t=crypto;else if("msCrypto"in window)t=msCrypto;else return 0;if(!("getRandomValues"in t)||!("Uint32Array"in window)||typeof Uint32Array!="function")t=null;if(t==null)return 0;var n=new Uint32Array(1);do{t.getRandomValues(n)}while(n[0]-n[0]%e>4294967296-e);return n[0]%e},this}),WHMCS.utils.validateBaseUrl(),jQuery(document).ready(function(){autoCollapse("#nav",30),0===jQuery("#lightbox").length&&lightbox.init(),jQuery(window).on("resize",function(){jQuery('button[data-target="#mainNavbar"], button[data-toggle="collapse"]').is(":visible")||autoCollapse("#nav",30)}),jQuery(".item-selector .item").click(function(e){e.preventDefault(),jQuery(this).closest(".item-selector").find(".item").removeClass("active").end().find("input").val(jQuery(this).data("value")),jQuery(this).addClass("active")}),jQuery(document).on("click",".btn-reveal-pw",function(e){"password"==($targetField=jQuery(this).closest(".input-group").find(".pw-input")).attr("type")?$targetField.attr("type","text"):$targetField.attr("type","password")}),jQuery("#accountNotifications").popover({container:"body",placement:"bottom",template:'',html:!0,content:function(){return jQuery("#accountNotificationsContent").html()}}),jQuery(".card-sidebar .truncate").each(function(){jQuery(this).attr("title",jQuery(this).text()).attr("data-toggle","tooltip").attr("data-placement","bottom")}),jQuery('[data-toggle="popover"]').popover({html:!0}),jQuery(function(e){e("body").tooltip({selector:'[data-toggle="tooltip"]'})}),jQuery("body").on("click",function(e){jQuery('[data-toggle="popover"]').each(function(){jQuery(this).is(e.target)||0!==jQuery(this).has(e.target).length||0!==jQuery(".popover").has(e.target).length||jQuery(this).popover("hide")})}),jQuery(".list-group-tab-nav a").click(function(){if(jQuery(this).hasClass("disabled"))return!1;var e=this.href.split("#")[1];e&&(window.location.hash="#"+e)}),jQuery(".card-minimise").click(function(e){e.preventDefault();e=jQuery(this).closest(".card").find(".collapsable-card-body");jQuery(this).hasClass("minimised")?(e.slideDown(),jQuery(this).removeClass("minimised")):(e.slideUp(),jQuery(this).addClass("minimised"))}),jQuery(".container").width()<=720&&jQuery(".card-sidebar").find(".collapsable-card-body").hide().end().find(".card-minimise").addClass("minimised");var e=!1,t=((e="undefined"!=typeof disableInternalTabSelection&&disableInternalTabSelection?!0:e)||""!==jQuery(location).attr("hash").substr(1)&&(e=jQuery(location).attr("hash"),jQuery(".primary-content > .tab-content > .tab-pane").removeClass("active"),jQuery(e).removeClass("fade").addClass("active"),jQuery(".list-group-tab-nav a").removeClass("active"),jQuery('a[href="'+e+'"]').addClass("active"),setTimeout(function(){window.scrollTo(0,0)},1)),jQuery.prototype.bootstrapSwitch&&jQuery(".toggle-switch-success").bootstrapSwitch({onColor:"success"}),jQuery(".panel-collapsable .card-header").click(function(e){var t=jQuery(this);t.closest(".card").hasClass("panel-collapsed")?(t.closest(".card").removeClass("panel-collapsed").find(".card-body").slideDown(),t.find(".collapse-icon i").removeClass("fa-plus").addClass("fa-minus")):(t.closest(".card").addClass("panel-collapsed").find(".card-body").slideUp(),t.find(".collapse-icon i").removeClass("fa-minus").addClass("fa-plus"))}),0<"#frmLogin".length&&jQuery("#frmLogin input:text:visible:first").focus(),0<"#twofaactivation".length&&jQuery("#twofaactivation input:text:visible:first,#twofaactivation input:password:visible:first").focus(),jQuery("#inputSubaccountActivate").click(function(){null!=jQuery("#inputSubaccountActivate:checked").val()?jQuery("#subacct-container").show():jQuery("#subacct-container").hide()}),jQuery(".setBulkAction").click(function(e){e.preventDefault();var t,e=jQuery(this).attr("id").replace("Link",""),n=jQuery("#domainForm");"renewDomains"===e?n.attr("action",WHMCS.utils.getRouteUrl("/cart/domain/renew")):(0!==jQuery("#"+e).length&&(t=n.attr("action"),n.attr("action",t+"#"+e)),jQuery("#bulkaction").val(e)),n.submit()}),jQuery(".stopEventBubble").click(function(e){e.stopPropagation()}),jQuery(".tabControlLink").on("click",function(e){e.preventDefault();e=jQuery(this).attr("href");jQuery("a[href='/"+e+"']").click()}),jQuery(document).on("click",".delete-cc-email",function(){var t=jQuery(this),e=t.data("email"),n=jQuery("#divCcEmailFeedback");n.is(":visible")&&n.slideUp("fast"),WHMCS.http.jqClient.jsonPost({url:window.location.href,data:{action:"delete",email:e,token:csrfToken},success:function(e){e.success&&(t.closest(".ticket-cc-email").parent("div").slideUp("fast").remove(),n.removeClass("alert-danger").addClass("alert-success").html(e.message).slideDown("fast"))},error:function(e){e&&n.removeClass("alert-success").addClass("alert-danger").html(e).slideDown("fast")}})}).on("submit","#frmAddCcEmail",function(e){e.preventDefault();var e=jQuery(this),t=jQuery("#ccCloneRow").clone().removeAttr("id"),n=jQuery("#inputAddCcEmail"),i=jQuery("#divCcEmailFeedback");i.is(":visible")&&i.slideUp("fast"),WHMCS.http.jqClient.jsonPost({url:e.attr("action"),data:e.serialize(),success:function(e){e.success&&(t.find("span.email").html(n.val()).find("button").data("email",n.val()).end(),t.show().appendTo(jQuery("#sidebarTicketCc").find(".list-group")),n.val(""),i.slideUp("fast").removeClass("alert-danger hidden").addClass("alert-success").html(e.message).slideDown("fast"))},error:function(e){e&&i.slideUp("fast").removeClass("alert-success hidden").addClass("alert-danger").html(e).slideDown("fast")}})}),jQuery(".ticket-reply .rating span.star").click(function(e){window.location="viewticket.php?tid="+jQuery(this).parent(".rating").attr("ticketid")+"&c="+jQuery(this).parent(".rating").attr("ticketkey")+"&rating=rate"+jQuery(this).parent(".rating").attr("ticketreplyid")+"_"+jQuery(this).attr("rate")}),jQuery("a.autoLinked").click(function(e){if(e.preventDefault(),jQuery(this).hasClass("disabled"))return!1;var t=window.open();t.opener=null,t.location=e.target.href}),jQuery("#inputAllowSso").on("switchChange.bootstrapSwitch",function(e,t){(t?(jQuery("#ssoStatusTextEnabled").show(),jQuery("#ssoStatusTextDisabled")):(jQuery("#ssoStatusTextDisabled").show(),jQuery("#ssoStatusTextEnabled"))).hide(),WHMCS.http.jqClient.post("clientarea.php",jQuery("#frmSingleSignOn").serialize())}),jQuery(".btn-service-sso").on("click",function(e){e.preventDefault();var t=jQuery(this),n=t.closest("form");(n=0===n.length?t.find("form"):n).hasClass("disabled")||t.hasClass("disabled")||(e=(e=n.data("href"))||window.location.href,t.attr("disabled","disabled").addClass("disabled"),jQuery(".loading",t).show().end(),jQuery(".login-feedback",n).slideUp(),WHMCS.http.jqClient.post(e,n.serialize(),function(e){jQuery(".loading",t).hide().end().removeAttr("disabled"),jQuery(".login-feedback",n).html(""),e.error&&jQuery(".login-feedback",n).hide().html(e.error).slideDown(),void 0!==e.redirect&&"window|"===e.redirect.substr(0,7)&&window.open(e.redirect.substr(7),"_blank")},"json").always(function(){t.removeAttr("disabled").removeClass("disabled"),t.find(".loading").hide().end()}))}),jQuery(".btn-sidebar-form-submit").on("click",function(e){e.preventDefault(),jQuery(this).find(".loading").show().end().attr("disabled","disabled");e=jQuery(this).closest("form");0!==(e=0===e.length?jQuery(this).find("form"):e).length&&!1===e.hasClass("disabled")?e.submit():jQuery(this).find(".loading").hide().end().removeAttr("disabled")}),jQuery(".back-to-top").click(function(e){e.preventDefault(),jQuery("body,html").animate({scrollTop:0},500)}),jQuery(".choose-language").click(function(e){e.preventDefault()}),jQuery(".copy-to-clipboard").click(WHMCS.ui.clipboard.copy),jQuery("#modalChooseLanguage button[type=submit]").click(function(e){e.preventDefault();var e=jQuery(this).closest("form"),t=e.find('input[name="currency"]'),n=e.find('input[name="language"]'),i=[];n.data("current")!=n.val()&&i.push("language="+n.val()),t.data("current")!=t.val()&&""!=t.val()&&i.push("currency="+t.val()),window.location.replace(e.attr("action")+i.join("&"))}),jQuery(".generate-password").click(function(e){jQuery("#frmGeneratePassword").submit(),jQuery("#modalGeneratePassword").data("targetfields",jQuery(this).data("targetfields")).modal("show")}),jQuery("#frmGeneratePassword").submit(function(e){e.preventDefault();e=parseInt(jQuery("#inputGeneratePasswordLength").val(),10);e<8||64',autofocus:!1,savable:!1,resize:"vertical",iconlibrary:"fa-5",language:locale,onShow:function(e){var t="",n=!1;"undefined"!=typeof Storage&&(n=!0,t=localStorage.getItem(i))&&void 0!==t&&e.setContent(t),jQuery("#"+r).html(o(t,n,saved))},onChange:function(e){var e=e.getContent(),t=!1;"undefined"!=typeof Storage&&(n=3,t=!0,localStorage.setItem(i,e),a()),jQuery("#"+r).html(o(e,t))},onPreview:function(e){var t,e=e.getContent();return jQuery.ajax({url:WHMCS.utils.getRouteUrl("/clientarea/message/preview"),async:!1,data:{token:csrfToken,content:e},dataType:"json",success:function(e){t=e}}),t.body||""},additionalButtons:[[{name:"groupCustom",data:[{name:"cmdHelp",title:"Help",hotkey:"Ctrl+F1",btnClass:"btn open-modal",icon:{glyph:"fas fa-question-circle",fa:"fas fa-question-circle","fa-3":"icon-question-sign","fa-5":"fas fa-question-circle"},callback:function(e){e.$editor.removeClass("md-fullscreen-mode")}}]}]],hiddenButtons:["cmdImage"]}),jQuery('button[data-handler="bootstrap-markdown-cmdHelp"]').attr("data-modal-title",markdownGuide).attr("href","submitticket.php?action=markdown"),jQuery(this).closest("form").bind({submit:function(){"undefined"!=typeof Storage&&localStorage.removeItem(i)}})}),jQuery(".btn-resend-verify-email")),e=(jQuery(i).click(function(){$(this).prop("disabled",!0).find(".loader").show(),WHMCS.http.jqClient.post(jQuery(this).data("uri"),{token:csrfToken}).done(function(e){i.find(".loader").hide(),e.success?i.text(i.data("email-sent")):i.text(i.data("error-msg"))})}),jQuery("#btnEmailVerificationClose").click(function(e){e.preventDefault(),WHMCS.http.jqClient.post(jQuery(this).data("uri"),{token:csrfToken}),jQuery(".verification-banner.email-verification").hide()}),jQuery("#btnUserValidationClose").click(function(e){e.preventDefault(),WHMCS.http.jqClient.post(jQuery(this).data("uri"),{token:csrfToken}),jQuery(".verification-banner.user-validation").hide()}),jQuery("#servicesPanel").find(".list-group"));function o(e,t,n){n=n||saving;var i=[],r=0,o=0;if(e&&(i=e.match(/[^\s]+/g),o=e.split(/\\r\\n|\\r|\\n/).length),i)for(var a=0;alines: '+o+"   words: "+r+(t?'   '+n+"":"")+""}function a(){0<=n&&(0===n&&jQuery("span.markdown-save").html(saved),n--,setTimeout(a,1e3))}parseInt(e.css("height"),10)"),"active"===e.ssl.status?(jQuery("#ssl-startdate").text(e.ssl.startDate),jQuery("#ssl-expirydate").text(e.ssl.expiryDate),jQuery("#ssl-issuer").text(e.ssl.issuer)):(jQuery("#ssl-startdate").parent("div").hide(),jQuery("#ssl-expirydate").parent("div").hide(),jQuery("#ssl-issuer").parent("div").hide()),jQuery("#statusDisplayLabel").text(n))})}),jQuery(document).on("click",".ssl-state.ssl-inactive",function(e){e.preventDefault(),window.location.href=WHMCS.utils.getRouteUrl("/ssl-purchase")}),WHMCS.recaptcha.register(),jQuery("#divDynamicRecaptcha")),s=0.timeline-Tweet-text { font-size: 18px !important; line-height: 25px !important; margin-bottom: 0px !important; }"),removeRetweets(),observerTwitterWidget.observe(e,observerConfig)):elementsWaitTimeout=window.setTimeout(addTwitterWidgetObserverWhenNodeAvailable,500)}function openValidationSubmitModal(e){var t=jQuery("#validationSubmitModal");t.find(".modal-body iframe").attr("src",e.dataset.url),t.modal("show")}function completeValidationComClientWorkflow(){var e=jQuery(".user-validation"),t=jQuery(".validation-status-label"),n=jQuery(".validation-submit-div"),i=!0;return $("#validationSubmitModal").modal("hide"),0!==e.length&&(e.slideUp(),i=!1),0!==t.length&&(e=n.find("a").data("submitted-string"),t.text(e).removeClass("label-default").addClass("label-warning"),n.hide(),i=!1),i&&(window.location.href=WHMCS.utils.autoDetermineBaseUrl()),!1}var autoCollapse=function(e,t){var n=!0,i=jQuery(e),r=i.innerHeight();if(t<=r){for(jQuery(e+" .collapsable-dropdown").removeClass("d-none"),jQuery(".navbar-nav").removeClass("w-auto").addClass("w-100");t-n._handleWidth/2,n._dragEnd=!1,n.state(n.options.inverse?!e:e)):n.state(!n.options.state),n._dragStart=!1)},"mouseleave.bootstrapSwitch":function(){n.$label.trigger("mouseup.bootstrapSwitch")}})}},{key:"_externalLabelHandler",value:function(){var t=this,n=this.$element.closest("label");n.on("click",function(e){e.preventDefault(),e.stopImmediatePropagation(),e.target===n[0]&&t.toggleState()})}},{key:"_formHandler",value:function(){var e=this.$element.closest("form");e.data("bootstrap-switch")||e.on("reset.bootstrapSwitch",function(){i.setTimeout(function(){e.find("input").filter(function(){return o(this).data("bootstrap-switch")}).each(function(){return o(this).bootstrapSwitch("state",this.checked)})},1)}).data("bootstrap-switch",!0)}},{key:"_getClass",value:function(e){return this.options.baseClass+"-"+e}},{key:"_getClasses",value:function(e){return o.isArray(e)?e.map(this._getClass.bind(this)):[this._getClass(e)]}}]);var a=t;function t(i){var r=this,e=1",{class:function(){var e=[];return e.push(r.options.state?"on":"off"),r.options.size&&e.push(r.options.size),r.options.disabled&&e.push("disabled"),r.options.readonly&&e.push("readonly"),r.options.indeterminate&&e.push("indeterminate"),r.options.inverse&&e.push("inverse"),r.$element.attr("id")&&e.push("id-"+r.$element.attr("id")),e.map(r._getClass.bind(r)).concat([r.options.baseClass],r._getClasses(r.options.wrapperClass)).join(" ")}}),this.$container=o("
",{class:this._getClass("container")}),this.$on=o("",{html:this.options.onText,class:this._getClass("handle-on")+" "+this._getClass(this.options.onColor)}),this.$off=o("",{html:this.options.offText,class:this._getClass("handle-off")+" "+this._getClass(this.options.offColor)}),this.$label=o("",{html:this.options.labelText,class:this._getClass("label")}),this.$element.on("init.bootstrapSwitch",this.options.onInit.bind(this,i)),this.$element.on("switchChange.bootstrapSwitch",function(){for(var e=arguments.length,t=Array(e),n=0;n",{class:"btn-group"}),u=0;u");v.text(" "+this.__localize(p)).addClass("btn-default btn-sm").addClass(g),g.match(/btn\-(primary|success|info|warning|danger|link)/)&&v.removeClass("btn-default"),v.attr({type:"button",title:this.__localize(c.title)+b,tabindex:m,"data-provider":n,"data-handler":h,"data-hotkey":y}),!0===c.toggle&&v.attr("data-toggle","button"),(p=$("")).addClass(f),p.prependTo(v),l.append(v),i.push(h),r.push(c.callback)}t.append(l)}return t},__setListener:function(){var e=void 0!==this.$textarea.attr("rows"),t=5",{class:"md-editor",click:function(){r.focus()}});return null===this.$editor?(e=$("
",{class:"md-header btn-toolbar"}),i=[],0c.reorderButtonGroups.indexOf(t.name)?1:0}):i).length&&(e=this.__buildButtons([i],e)),c.fullscreen.enable&&e.append('
').on("click",".md-control-fullscreen",function(e){e.preventDefault(),r.setFullscreen(!0)}),h.append(e),s.is("textarea")?(s.before(h),(a=s).addClass("md-input"),h.append(a)):(t="function"==typeof toMarkdown?toMarkdown(s.html()):s.html(),t=$.trim(t),a=$("