File: /var/www/test.kaunokolegija.lt/kk_wp_content/plugins/advanced-post-block/build/index.js
/*! For license information please see index.js.LICENSE.txt */
(()=>{var e={42:e=>{var t=function(){this.Diff_Timeout=1,this.Diff_EditCost=4,this.Match_Threshold=.5,this.Match_Distance=1e3,this.Patch_DeleteThreshold=.5,this.Patch_Margin=4,this.Match_MaxBits=32},n=-1;t.Diff=function(e,t){return[e,t]},t.prototype.diff_main=function(e,n,i,r){void 0===r&&(r=this.Diff_Timeout<=0?Number.MAX_VALUE:(new Date).getTime()+1e3*this.Diff_Timeout);var o=r;if(null==e||null==n)throw new Error("Null input. (diff_main)");if(e==n)return e?[new t.Diff(0,e)]:[];void 0===i&&(i=!0);var a=i,s=this.diff_commonPrefix(e,n),l=e.substring(0,s);e=e.substring(s),n=n.substring(s),s=this.diff_commonSuffix(e,n);var c=e.substring(e.length-s);e=e.substring(0,e.length-s),n=n.substring(0,n.length-s);var d=this.diff_compute_(e,n,a,o);return l&&d.unshift(new t.Diff(0,l)),c&&d.push(new t.Diff(0,c)),this.diff_cleanupMerge(d),d},t.prototype.diff_compute_=function(e,i,r,o){var a;if(!e)return[new t.Diff(1,i)];if(!i)return[new t.Diff(n,e)];var s=e.length>i.length?e:i,l=e.length>i.length?i:e,c=s.indexOf(l);if(-1!=c)return a=[new t.Diff(1,s.substring(0,c)),new t.Diff(0,l),new t.Diff(1,s.substring(c+l.length))],e.length>i.length&&(a[0][0]=a[2][0]=n),a;if(1==l.length)return[new t.Diff(n,e),new t.Diff(1,i)];var d=this.diff_halfMatch_(e,i);if(d){var u=d[0],h=d[1],p=d[2],g=d[3],f=d[4],m=this.diff_main(u,p,r,o),y=this.diff_main(h,g,r,o);return m.concat([new t.Diff(0,f)],y)}return r&&e.length>100&&i.length>100?this.diff_lineMode_(e,i,o):this.diff_bisect_(e,i,o)},t.prototype.diff_lineMode_=function(e,i,r){var o=this.diff_linesToChars_(e,i);e=o.chars1,i=o.chars2;var a=o.lineArray,s=this.diff_main(e,i,!1,r);this.diff_charsToLines_(s,a),this.diff_cleanupSemantic(s),s.push(new t.Diff(0,""));for(var l=0,c=0,d=0,u="",h="";l<s.length;){switch(s[l][0]){case 1:d++,h+=s[l][1];break;case n:c++,u+=s[l][1];break;case 0:if(c>=1&&d>=1){s.splice(l-c-d,c+d),l=l-c-d;for(var p=this.diff_main(u,h,!1,r),g=p.length-1;g>=0;g--)s.splice(l,0,p[g]);l+=p.length}d=0,c=0,u="",h=""}l++}return s.pop(),s},t.prototype.diff_bisect_=function(e,i,r){for(var o=e.length,a=i.length,s=Math.ceil((o+a)/2),l=s,c=2*s,d=new Array(c),u=new Array(c),h=0;h<c;h++)d[h]=-1,u[h]=-1;d[l+1]=0,u[l+1]=0;for(var p=o-a,g=p%2!=0,f=0,m=0,y=0,v=0,b=0;b<s&&!((new Date).getTime()>r);b++){for(var w=-b+f;w<=b-m;w+=2){for(var C=l+w,x=($=w==-b||w!=b&&d[C-1]<d[C+1]?d[C+1]:d[C-1]+1)-w;$<o&&x<a&&e.charAt($)==i.charAt(x);)$++,x++;if(d[C]=$,$>o)m+=2;else if(x>a)f+=2;else if(g&&(E=l+p-w)>=0&&E<c&&-1!=u[E]&&$>=(_=o-u[E]))return this.diff_bisectSplit_(e,i,$,x,r)}for(var S=-b+y;S<=b-v;S+=2){for(var _,E=l+S,k=(_=S==-b||S!=b&&u[E-1]<u[E+1]?u[E+1]:u[E-1]+1)-S;_<o&&k<a&&e.charAt(o-_-1)==i.charAt(a-k-1);)_++,k++;if(u[E]=_,_>o)v+=2;else if(k>a)y+=2;else if(!g){var $;if((C=l+p-S)>=0&&C<c&&-1!=d[C])if(x=l+($=d[C])-C,$>=(_=o-_))return this.diff_bisectSplit_(e,i,$,x,r)}}}return[new t.Diff(n,e),new t.Diff(1,i)]},t.prototype.diff_bisectSplit_=function(e,t,n,i,r){var o=e.substring(0,n),a=t.substring(0,i),s=e.substring(n),l=t.substring(i),c=this.diff_main(o,a,!1,r),d=this.diff_main(s,l,!1,r);return c.concat(d)},t.prototype.diff_linesToChars_=function(e,t){var n=[],i={};function r(e){for(var t="",r=0,a=-1,s=n.length;a<e.length-1;){-1==(a=e.indexOf("\n",r))&&(a=e.length-1);var l=e.substring(r,a+1);(i.hasOwnProperty?i.hasOwnProperty(l):void 0!==i[l])?t+=String.fromCharCode(i[l]):(s==o&&(l=e.substring(r),a=e.length),t+=String.fromCharCode(s),i[l]=s,n[s++]=l),r=a+1}return t}n[0]="";var o=4e4,a=r(e);return o=65535,{chars1:a,chars2:r(t),lineArray:n}},t.prototype.diff_charsToLines_=function(e,t){for(var n=0;n<e.length;n++){for(var i=e[n][1],r=[],o=0;o<i.length;o++)r[o]=t[i.charCodeAt(o)];e[n][1]=r.join("")}},t.prototype.diff_commonPrefix=function(e,t){if(!e||!t||e.charAt(0)!=t.charAt(0))return 0;for(var n=0,i=Math.min(e.length,t.length),r=i,o=0;n<r;)e.substring(o,r)==t.substring(o,r)?o=n=r:i=r,r=Math.floor((i-n)/2+n);return r},t.prototype.diff_commonSuffix=function(e,t){if(!e||!t||e.charAt(e.length-1)!=t.charAt(t.length-1))return 0;for(var n=0,i=Math.min(e.length,t.length),r=i,o=0;n<r;)e.substring(e.length-r,e.length-o)==t.substring(t.length-r,t.length-o)?o=n=r:i=r,r=Math.floor((i-n)/2+n);return r},t.prototype.diff_commonOverlap_=function(e,t){var n=e.length,i=t.length;if(0==n||0==i)return 0;n>i?e=e.substring(n-i):n<i&&(t=t.substring(0,n));var r=Math.min(n,i);if(e==t)return r;for(var o=0,a=1;;){var s=e.substring(r-a),l=t.indexOf(s);if(-1==l)return o;a+=l,0!=l&&e.substring(r-a)!=t.substring(0,a)||(o=a,a++)}},t.prototype.diff_halfMatch_=function(e,t){if(this.Diff_Timeout<=0)return null;var n=e.length>t.length?e:t,i=e.length>t.length?t:e;if(n.length<4||2*i.length<n.length)return null;var r=this;function o(e,t,n){for(var i,o,a,s,l=e.substring(n,n+Math.floor(e.length/4)),c=-1,d="";-1!=(c=t.indexOf(l,c+1));){var u=r.diff_commonPrefix(e.substring(n),t.substring(c)),h=r.diff_commonSuffix(e.substring(0,n),t.substring(0,c));d.length<h+u&&(d=t.substring(c-h,c)+t.substring(c,c+u),i=e.substring(0,n-h),o=e.substring(n+u),a=t.substring(0,c-h),s=t.substring(c+u))}return 2*d.length>=e.length?[i,o,a,s,d]:null}var a,s,l,c,d,u=o(n,i,Math.ceil(n.length/4)),h=o(n,i,Math.ceil(n.length/2));return u||h?(a=h?u&&u[4].length>h[4].length?u:h:u,e.length>t.length?(s=a[0],l=a[1],c=a[2],d=a[3]):(c=a[0],d=a[1],s=a[2],l=a[3]),[s,l,c,d,a[4]]):null},t.prototype.diff_cleanupSemantic=function(e){for(var i=!1,r=[],o=0,a=null,s=0,l=0,c=0,d=0,u=0;s<e.length;)0==e[s][0]?(r[o++]=s,l=d,c=u,d=0,u=0,a=e[s][1]):(1==e[s][0]?d+=e[s][1].length:u+=e[s][1].length,a&&a.length<=Math.max(l,c)&&a.length<=Math.max(d,u)&&(e.splice(r[o-1],0,new t.Diff(n,a)),e[r[o-1]+1][0]=1,o--,s=--o>0?r[o-1]:-1,l=0,c=0,d=0,u=0,a=null,i=!0)),s++;for(i&&this.diff_cleanupMerge(e),this.diff_cleanupSemanticLossless(e),s=1;s<e.length;){if(e[s-1][0]==n&&1==e[s][0]){var h=e[s-1][1],p=e[s][1],g=this.diff_commonOverlap_(h,p),f=this.diff_commonOverlap_(p,h);g>=f?(g>=h.length/2||g>=p.length/2)&&(e.splice(s,0,new t.Diff(0,p.substring(0,g))),e[s-1][1]=h.substring(0,h.length-g),e[s+1][1]=p.substring(g),s++):(f>=h.length/2||f>=p.length/2)&&(e.splice(s,0,new t.Diff(0,h.substring(0,f))),e[s-1][0]=1,e[s-1][1]=p.substring(0,p.length-f),e[s+1][0]=n,e[s+1][1]=h.substring(f),s++),s++}s++}},t.prototype.diff_cleanupSemanticLossless=function(e){function n(e,n){if(!e||!n)return 6;var i=e.charAt(e.length-1),r=n.charAt(0),o=i.match(t.nonAlphaNumericRegex_),a=r.match(t.nonAlphaNumericRegex_),s=o&&i.match(t.whitespaceRegex_),l=a&&r.match(t.whitespaceRegex_),c=s&&i.match(t.linebreakRegex_),d=l&&r.match(t.linebreakRegex_),u=c&&e.match(t.blanklineEndRegex_),h=d&&n.match(t.blanklineStartRegex_);return u||h?5:c||d?4:o&&!s&&l?3:s||l?2:o||a?1:0}for(var i=1;i<e.length-1;){if(0==e[i-1][0]&&0==e[i+1][0]){var r=e[i-1][1],o=e[i][1],a=e[i+1][1],s=this.diff_commonSuffix(r,o);if(s){var l=o.substring(o.length-s);r=r.substring(0,r.length-s),o=l+o.substring(0,o.length-s),a=l+a}for(var c=r,d=o,u=a,h=n(r,o)+n(o,a);o.charAt(0)===a.charAt(0);){r+=o.charAt(0),o=o.substring(1)+a.charAt(0),a=a.substring(1);var p=n(r,o)+n(o,a);p>=h&&(h=p,c=r,d=o,u=a)}e[i-1][1]!=c&&(c?e[i-1][1]=c:(e.splice(i-1,1),i--),e[i][1]=d,u?e[i+1][1]=u:(e.splice(i+1,1),i--))}i++}},t.nonAlphaNumericRegex_=/[^a-zA-Z0-9]/,t.whitespaceRegex_=/\s/,t.linebreakRegex_=/[\r\n]/,t.blanklineEndRegex_=/\n\r?\n$/,t.blanklineStartRegex_=/^\r?\n\r?\n/,t.prototype.diff_cleanupEfficiency=function(e){for(var i=!1,r=[],o=0,a=null,s=0,l=!1,c=!1,d=!1,u=!1;s<e.length;)0==e[s][0]?(e[s][1].length<this.Diff_EditCost&&(d||u)?(r[o++]=s,l=d,c=u,a=e[s][1]):(o=0,a=null),d=u=!1):(e[s][0]==n?u=!0:d=!0,a&&(l&&c&&d&&u||a.length<this.Diff_EditCost/2&&l+c+d+u==3)&&(e.splice(r[o-1],0,new t.Diff(n,a)),e[r[o-1]+1][0]=1,o--,a=null,l&&c?(d=u=!0,o=0):(s=--o>0?r[o-1]:-1,d=u=!1),i=!0)),s++;i&&this.diff_cleanupMerge(e)},t.prototype.diff_cleanupMerge=function(e){e.push(new t.Diff(0,""));for(var i,r=0,o=0,a=0,s="",l="";r<e.length;)switch(e[r][0]){case 1:a++,l+=e[r][1],r++;break;case n:o++,s+=e[r][1],r++;break;case 0:o+a>1?(0!==o&&0!==a&&(0!==(i=this.diff_commonPrefix(l,s))&&(r-o-a>0&&0==e[r-o-a-1][0]?e[r-o-a-1][1]+=l.substring(0,i):(e.splice(0,0,new t.Diff(0,l.substring(0,i))),r++),l=l.substring(i),s=s.substring(i)),0!==(i=this.diff_commonSuffix(l,s))&&(e[r][1]=l.substring(l.length-i)+e[r][1],l=l.substring(0,l.length-i),s=s.substring(0,s.length-i))),r-=o+a,e.splice(r,o+a),s.length&&(e.splice(r,0,new t.Diff(n,s)),r++),l.length&&(e.splice(r,0,new t.Diff(1,l)),r++),r++):0!==r&&0==e[r-1][0]?(e[r-1][1]+=e[r][1],e.splice(r,1)):r++,a=0,o=0,s="",l=""}""===e[e.length-1][1]&&e.pop();var c=!1;for(r=1;r<e.length-1;)0==e[r-1][0]&&0==e[r+1][0]&&(e[r][1].substring(e[r][1].length-e[r-1][1].length)==e[r-1][1]?(e[r][1]=e[r-1][1]+e[r][1].substring(0,e[r][1].length-e[r-1][1].length),e[r+1][1]=e[r-1][1]+e[r+1][1],e.splice(r-1,1),c=!0):e[r][1].substring(0,e[r+1][1].length)==e[r+1][1]&&(e[r-1][1]+=e[r+1][1],e[r][1]=e[r][1].substring(e[r+1][1].length)+e[r+1][1],e.splice(r+1,1),c=!0)),r++;c&&this.diff_cleanupMerge(e)},t.prototype.diff_xIndex=function(e,t){var i,r=0,o=0,a=0,s=0;for(i=0;i<e.length&&(1!==e[i][0]&&(r+=e[i][1].length),e[i][0]!==n&&(o+=e[i][1].length),!(r>t));i++)a=r,s=o;return e.length!=i&&e[i][0]===n?s:s+(t-a)},t.prototype.diff_prettyHtml=function(e){for(var t=[],i=/&/g,r=/</g,o=/>/g,a=/\n/g,s=0;s<e.length;s++){var l=e[s][0],c=e[s][1].replace(i,"&").replace(r,"<").replace(o,">").replace(a,"¶<br>");switch(l){case 1:t[s]='<ins style="background:#e6ffe6;">'+c+"</ins>";break;case n:t[s]='<del style="background:#ffe6e6;">'+c+"</del>";break;case 0:t[s]="<span>"+c+"</span>"}}return t.join("")},t.prototype.diff_text1=function(e){for(var t=[],n=0;n<e.length;n++)1!==e[n][0]&&(t[n]=e[n][1]);return t.join("")},t.prototype.diff_text2=function(e){for(var t=[],i=0;i<e.length;i++)e[i][0]!==n&&(t[i]=e[i][1]);return t.join("")},t.prototype.diff_levenshtein=function(e){for(var t=0,i=0,r=0,o=0;o<e.length;o++){var a=e[o][0],s=e[o][1];switch(a){case 1:i+=s.length;break;case n:r+=s.length;break;case 0:t+=Math.max(i,r),i=0,r=0}}return t+Math.max(i,r)},t.prototype.diff_toDelta=function(e){for(var t=[],i=0;i<e.length;i++)switch(e[i][0]){case 1:t[i]="+"+encodeURI(e[i][1]);break;case n:t[i]="-"+e[i][1].length;break;case 0:t[i]="="+e[i][1].length}return t.join("\t").replace(/%20/g," ")},t.prototype.diff_fromDelta=function(e,i){for(var r=[],o=0,a=0,s=i.split(/\t/g),l=0;l<s.length;l++){var c=s[l].substring(1);switch(s[l].charAt(0)){case"+":try{r[o++]=new t.Diff(1,decodeURI(c))}catch(e){throw new Error("Illegal escape in diff_fromDelta: "+c)}break;case"-":case"=":var d=parseInt(c,10);if(isNaN(d)||d<0)throw new Error("Invalid number in diff_fromDelta: "+c);var u=e.substring(a,a+=d);"="==s[l].charAt(0)?r[o++]=new t.Diff(0,u):r[o++]=new t.Diff(n,u);break;default:if(s[l])throw new Error("Invalid diff operation in diff_fromDelta: "+s[l])}}if(a!=e.length)throw new Error("Delta length ("+a+") does not equal source text length ("+e.length+").");return r},t.prototype.match_main=function(e,t,n){if(null==e||null==t||null==n)throw new Error("Null input. (match_main)");return n=Math.max(0,Math.min(n,e.length)),e==t?0:e.length?e.substring(n,n+t.length)==t?n:this.match_bitap_(e,t,n):-1},t.prototype.match_bitap_=function(e,t,n){if(t.length>this.Match_MaxBits)throw new Error("Pattern too long for this browser.");var i=this.match_alphabet_(t),r=this;function o(e,i){var o=e/t.length,a=Math.abs(n-i);return r.Match_Distance?o+a/r.Match_Distance:a?1:o}var a=this.Match_Threshold,s=e.indexOf(t,n);-1!=s&&(a=Math.min(o(0,s),a),-1!=(s=e.lastIndexOf(t,n+t.length))&&(a=Math.min(o(0,s),a)));var l,c,d=1<<t.length-1;s=-1;for(var u,h=t.length+e.length,p=0;p<t.length;p++){for(l=0,c=h;l<c;)o(p,n+c)<=a?l=c:h=c,c=Math.floor((h-l)/2+l);h=c;var g=Math.max(1,n-c+1),f=Math.min(n+c,e.length)+t.length,m=Array(f+2);m[f+1]=(1<<p)-1;for(var y=f;y>=g;y--){var v=i[e.charAt(y-1)];if(m[y]=0===p?(m[y+1]<<1|1)&v:(m[y+1]<<1|1)&v|(u[y+1]|u[y])<<1|1|u[y+1],m[y]&d){var b=o(p,y-1);if(b<=a){if(a=b,!((s=y-1)>n))break;g=Math.max(1,2*n-s)}}}if(o(p+1,n)>a)break;u=m}return s},t.prototype.match_alphabet_=function(e){for(var t={},n=0;n<e.length;n++)t[e.charAt(n)]=0;for(n=0;n<e.length;n++)t[e.charAt(n)]|=1<<e.length-n-1;return t},t.prototype.patch_addContext_=function(e,n){if(0!=n.length){if(null===e.start2)throw Error("patch not initialized");for(var i=n.substring(e.start2,e.start2+e.length1),r=0;n.indexOf(i)!=n.lastIndexOf(i)&&i.length<this.Match_MaxBits-this.Patch_Margin-this.Patch_Margin;)r+=this.Patch_Margin,i=n.substring(e.start2-r,e.start2+e.length1+r);r+=this.Patch_Margin;var o=n.substring(e.start2-r,e.start2);o&&e.diffs.unshift(new t.Diff(0,o));var a=n.substring(e.start2+e.length1,e.start2+e.length1+r);a&&e.diffs.push(new t.Diff(0,a)),e.start1-=o.length,e.start2-=o.length,e.length1+=o.length+a.length,e.length2+=o.length+a.length}},t.prototype.patch_make=function(e,i,r){var o,a;if("string"==typeof e&&"string"==typeof i&&void 0===r)o=e,(a=this.diff_main(o,i,!0)).length>2&&(this.diff_cleanupSemantic(a),this.diff_cleanupEfficiency(a));else if(e&&"object"==typeof e&&void 0===i&&void 0===r)a=e,o=this.diff_text1(a);else if("string"==typeof e&&i&&"object"==typeof i&&void 0===r)o=e,a=i;else{if("string"!=typeof e||"string"!=typeof i||!r||"object"!=typeof r)throw new Error("Unknown call format to patch_make.");o=e,a=r}if(0===a.length)return[];for(var s=[],l=new t.patch_obj,c=0,d=0,u=0,h=o,p=o,g=0;g<a.length;g++){var f=a[g][0],m=a[g][1];switch(c||0===f||(l.start1=d,l.start2=u),f){case 1:l.diffs[c++]=a[g],l.length2+=m.length,p=p.substring(0,u)+m+p.substring(u);break;case n:l.length1+=m.length,l.diffs[c++]=a[g],p=p.substring(0,u)+p.substring(u+m.length);break;case 0:m.length<=2*this.Patch_Margin&&c&&a.length!=g+1?(l.diffs[c++]=a[g],l.length1+=m.length,l.length2+=m.length):m.length>=2*this.Patch_Margin&&c&&(this.patch_addContext_(l,h),s.push(l),l=new t.patch_obj,c=0,h=p,d=u)}1!==f&&(d+=m.length),f!==n&&(u+=m.length)}return c&&(this.patch_addContext_(l,h),s.push(l)),s},t.prototype.patch_deepCopy=function(e){for(var n=[],i=0;i<e.length;i++){var r=e[i],o=new t.patch_obj;o.diffs=[];for(var a=0;a<r.diffs.length;a++)o.diffs[a]=new t.Diff(r.diffs[a][0],r.diffs[a][1]);o.start1=r.start1,o.start2=r.start2,o.length1=r.length1,o.length2=r.length2,n[i]=o}return n},t.prototype.patch_apply=function(e,t){if(0==e.length)return[t,[]];e=this.patch_deepCopy(e);var i=this.patch_addPadding(e);t=i+t+i,this.patch_splitMax(e);for(var r=0,o=[],a=0;a<e.length;a++){var s,l,c=e[a].start2+r,d=this.diff_text1(e[a].diffs),u=-1;if(d.length>this.Match_MaxBits?-1!=(s=this.match_main(t,d.substring(0,this.Match_MaxBits),c))&&(-1==(u=this.match_main(t,d.substring(d.length-this.Match_MaxBits),c+d.length-this.Match_MaxBits))||s>=u)&&(s=-1):s=this.match_main(t,d,c),-1==s)o[a]=!1,r-=e[a].length2-e[a].length1;else if(o[a]=!0,r=s-c,d==(l=-1==u?t.substring(s,s+d.length):t.substring(s,u+this.Match_MaxBits)))t=t.substring(0,s)+this.diff_text2(e[a].diffs)+t.substring(s+d.length);else{var h=this.diff_main(d,l,!1);if(d.length>this.Match_MaxBits&&this.diff_levenshtein(h)/d.length>this.Patch_DeleteThreshold)o[a]=!1;else{this.diff_cleanupSemanticLossless(h);for(var p,g=0,f=0;f<e[a].diffs.length;f++){var m=e[a].diffs[f];0!==m[0]&&(p=this.diff_xIndex(h,g)),1===m[0]?t=t.substring(0,s+p)+m[1]+t.substring(s+p):m[0]===n&&(t=t.substring(0,s+p)+t.substring(s+this.diff_xIndex(h,g+m[1].length))),m[0]!==n&&(g+=m[1].length)}}}}return[t=t.substring(i.length,t.length-i.length),o]},t.prototype.patch_addPadding=function(e){for(var n=this.Patch_Margin,i="",r=1;r<=n;r++)i+=String.fromCharCode(r);for(r=0;r<e.length;r++)e[r].start1+=n,e[r].start2+=n;var o=e[0],a=o.diffs;if(0==a.length||0!=a[0][0])a.unshift(new t.Diff(0,i)),o.start1-=n,o.start2-=n,o.length1+=n,o.length2+=n;else if(n>a[0][1].length){var s=n-a[0][1].length;a[0][1]=i.substring(a[0][1].length)+a[0][1],o.start1-=s,o.start2-=s,o.length1+=s,o.length2+=s}return 0==(a=(o=e[e.length-1]).diffs).length||0!=a[a.length-1][0]?(a.push(new t.Diff(0,i)),o.length1+=n,o.length2+=n):n>a[a.length-1][1].length&&(s=n-a[a.length-1][1].length,a[a.length-1][1]+=i.substring(0,s),o.length1+=s,o.length2+=s),i},t.prototype.patch_splitMax=function(e){for(var i=this.Match_MaxBits,r=0;r<e.length;r++)if(!(e[r].length1<=i)){var o=e[r];e.splice(r--,1);for(var a=o.start1,s=o.start2,l="";0!==o.diffs.length;){var c=new t.patch_obj,d=!0;for(c.start1=a-l.length,c.start2=s-l.length,""!==l&&(c.length1=c.length2=l.length,c.diffs.push(new t.Diff(0,l)));0!==o.diffs.length&&c.length1<i-this.Patch_Margin;){var u=o.diffs[0][0],h=o.diffs[0][1];1===u?(c.length2+=h.length,s+=h.length,c.diffs.push(o.diffs.shift()),d=!1):u===n&&1==c.diffs.length&&0==c.diffs[0][0]&&h.length>2*i?(c.length1+=h.length,a+=h.length,d=!1,c.diffs.push(new t.Diff(u,h)),o.diffs.shift()):(h=h.substring(0,i-c.length1-this.Patch_Margin),c.length1+=h.length,a+=h.length,0===u?(c.length2+=h.length,s+=h.length):d=!1,c.diffs.push(new t.Diff(u,h)),h==o.diffs[0][1]?o.diffs.shift():o.diffs[0][1]=o.diffs[0][1].substring(h.length))}l=(l=this.diff_text2(c.diffs)).substring(l.length-this.Patch_Margin);var p=this.diff_text1(o.diffs).substring(0,this.Patch_Margin);""!==p&&(c.length1+=p.length,c.length2+=p.length,0!==c.diffs.length&&0===c.diffs[c.diffs.length-1][0]?c.diffs[c.diffs.length-1][1]+=p:c.diffs.push(new t.Diff(0,p))),d||e.splice(++r,0,c)}}},t.prototype.patch_toText=function(e){for(var t=[],n=0;n<e.length;n++)t[n]=e[n];return t.join("")},t.prototype.patch_fromText=function(e){var i=[];if(!e)return i;for(var r=e.split("\n"),o=0,a=/^@@ -(\d+),?(\d*) \+(\d+),?(\d*) @@$/;o<r.length;){var s=r[o].match(a);if(!s)throw new Error("Invalid patch string: "+r[o]);var l=new t.patch_obj;for(i.push(l),l.start1=parseInt(s[1],10),""===s[2]?(l.start1--,l.length1=1):"0"==s[2]?l.length1=0:(l.start1--,l.length1=parseInt(s[2],10)),l.start2=parseInt(s[3],10),""===s[4]?(l.start2--,l.length2=1):"0"==s[4]?l.length2=0:(l.start2--,l.length2=parseInt(s[4],10)),o++;o<r.length;){var c=r[o].charAt(0);try{var d=decodeURI(r[o].substring(1))}catch(e){throw new Error("Illegal escape in patch_fromText: "+d)}if("-"==c)l.diffs.push(new t.Diff(n,d));else if("+"==c)l.diffs.push(new t.Diff(1,d));else if(" "==c)l.diffs.push(new t.Diff(0,d));else{if("@"==c)break;if(""!==c)throw new Error('Invalid patch mode "'+c+'" in: '+d)}o++}}return i},(t.patch_obj=function(){this.diffs=[],this.start1=null,this.start2=null,this.length1=0,this.length2=0}).prototype.toString=function(){for(var e,t=["@@ -"+(0===this.length1?this.start1+",0":1==this.length1?this.start1+1:this.start1+1+","+this.length1)+" +"+(0===this.length2?this.start2+",0":1==this.length2?this.start2+1:this.start2+1+","+this.length2)+" @@\n"],i=0;i<this.diffs.length;i++){switch(this.diffs[i][0]){case 1:e="+";break;case n:e="-";break;case 0:e=" "}t[i+1]=e+encodeURI(this.diffs[i][1])+"\n"}return t.join("").replace(/%20/g," ")},e.exports=t,e.exports.diff_match_patch=t,e.exports.DIFF_DELETE=n,e.exports.DIFF_INSERT=1,e.exports.DIFF_EQUAL=0},44:(e,t,n)=>{e=n.nmd(e),ace.define("ace/snippets",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/range_list","ace/keyboard/hash_handler","ace/tokenizer","ace/clipboard","ace/editor"],(function(e,t,n){"use strict";var i=e("./lib/dom"),r=e("./lib/oop"),o=e("./lib/event_emitter").EventEmitter,a=e("./lib/lang"),s=e("./range").Range,l=e("./range_list").RangeList,c=e("./keyboard/hash_handler").HashHandler,d=e("./tokenizer").Tokenizer,u=e("./clipboard"),h={CURRENT_WORD:function(e){return e.session.getTextRange(e.session.getWordRange())},SELECTION:function(e,t,n){var i=e.session.getTextRange();return n?i.replace(/\n\r?([ \t]*\S)/g,"\n"+n+"$1"):i},CURRENT_LINE:function(e){return e.session.getLine(e.getCursorPosition().row)},PREV_LINE:function(e){return e.session.getLine(e.getCursorPosition().row-1)},LINE_INDEX:function(e){return e.getCursorPosition().row},LINE_NUMBER:function(e){return e.getCursorPosition().row+1},SOFT_TABS:function(e){return e.session.getUseSoftTabs()?"YES":"NO"},TAB_SIZE:function(e){return e.session.getTabSize()},CLIPBOARD:function(e){return u.getText&&u.getText()},FILENAME:function(e){return/[^/\\]*$/.exec(this.FILEPATH(e))[0]},FILENAME_BASE:function(e){return/[^/\\]*$/.exec(this.FILEPATH(e))[0].replace(/\.[^.]*$/,"")},DIRECTORY:function(e){return this.FILEPATH(e).replace(/[^/\\]*$/,"")},FILEPATH:function(e){return"/not implemented.txt"},WORKSPACE_NAME:function(){return"Unknown"},FULLNAME:function(){return"Unknown"},BLOCK_COMMENT_START:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.start||""},BLOCK_COMMENT_END:function(e){var t=e.session.$mode||{};return t.blockComment&&t.blockComment.end||""},LINE_COMMENT:function(e){return(e.session.$mode||{}).lineCommentStart||""},CURRENT_YEAR:p.bind(null,{year:"numeric"}),CURRENT_YEAR_SHORT:p.bind(null,{year:"2-digit"}),CURRENT_MONTH:p.bind(null,{month:"numeric"}),CURRENT_MONTH_NAME:p.bind(null,{month:"long"}),CURRENT_MONTH_NAME_SHORT:p.bind(null,{month:"short"}),CURRENT_DATE:p.bind(null,{day:"2-digit"}),CURRENT_DAY_NAME:p.bind(null,{weekday:"long"}),CURRENT_DAY_NAME_SHORT:p.bind(null,{weekday:"short"}),CURRENT_HOUR:p.bind(null,{hour:"2-digit",hour12:!1}),CURRENT_MINUTE:p.bind(null,{minute:"2-digit"}),CURRENT_SECOND:p.bind(null,{second:"2-digit"})};function p(e){var t=(new Date).toLocaleString("en-us",e);return 1==t.length?"0"+t:t}h.SELECTED_TEXT=h.SELECTION;var g=function(){function e(){this.snippetMap={},this.snippetNameMap={},this.variables=h}return e.prototype.getTokenizer=function(){return e.$tokenizer||this.createTokenizer()},e.prototype.createTokenizer=function(){function t(e){return e=e.substr(1),/^\d+$/.test(e)?[{tabstopId:parseInt(e,10)}]:[{text:e}]}function n(e){return"(?:[^\\\\"+e+"]|\\\\.)"}var i={regex:"/("+n("/")+"+)/",onMatch:function(e,t,n){var i=n[0];return i.fmtString=!0,i.guard=e.slice(1,-1),i.flag="",""},next:"formatString"};return e.$tokenizer=new d({start:[{regex:/\\./,onMatch:function(e,t,n){var i=e[1];return("}"==i&&n.length||-1!="`$\\".indexOf(i))&&(e=i),[e]}},{regex:/}/,onMatch:function(e,t,n){return[n.length?n.shift():e]}},{regex:/\$(?:\d+|\w+)/,onMatch:t},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(e,n,i){var r=t(e.substr(1));return i.unshift(r[0]),r},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+n("\\|")+"*\\|",onMatch:function(e,t,n){var i=e.slice(1,-1).replace(/\\[,|\\]|,/g,(function(e){return 2==e.length?e[1]:"\0"})).split("\0").map((function(e){return{value:e}}));return n[0].choices=i,[i[0]]},next:"start"},i,{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:/:/,onMatch:function(e,t,n){return n.length&&n[0].expectElse?(n[0].expectElse=!1,n[0].ifEnd={elseEnd:n[0]},[n[0].ifEnd]):":"}},{regex:/\\./,onMatch:function(e,t,n){var i=e[1];return"}"==i&&n.length||-1!="`$\\".indexOf(i)?e=i:"n"==i?e="\n":"t"==i?e="\t":-1!="ulULE".indexOf(i)&&(e={changeCase:i,local:i>"a"}),[e]}},{regex:"/\\w*}",onMatch:function(e,t,n){var i=n.shift();return i&&(i.flag=e.slice(1,-1)),this.next=i&&i.tabstopId?"start":"",[i||e]},next:"start"},{regex:/\$(?:\d+|\w+)/,onMatch:function(e,t,n){return[{text:e.slice(1)}]}},{regex:/\${\w+/,onMatch:function(e,t,n){var i={text:e.slice(2)};return n.unshift(i),[i]},next:"formatStringVar"},{regex:/\n/,token:"newline",merge:!1},{regex:/}/,onMatch:function(e,t,n){var i=n.shift();return this.next=i&&i.tabstopId?"start":"",[i||e]},next:"start"}],formatStringVar:[{regex:/:\/\w+}/,onMatch:function(e,t,n){return n[0].formatFunction=e.slice(2,-1),[n.shift()]},next:"formatString"},i,{regex:/:[\?\-+]?/,onMatch:function(e,t,n){"+"==e[1]&&(n[0].ifEnd=n[0]),"?"==e[1]&&(n[0].expectElse=!0)},next:"formatString"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"formatString"}]}),e.$tokenizer},e.prototype.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map((function(e){return e.value||e}))},e.prototype.getVariableValue=function(e,t,n){if(/^\d+$/.test(t))return(this.variables.__||{})[t]||"";if(/^[A-Z]\d+$/.test(t))return(this.variables[t[0]+"__"]||{})[t.substr(1)]||"";if(t=t.replace(/^TM_/,""),!this.variables.hasOwnProperty(t))return"";var i=this.variables[t];return"function"==typeof i&&(i=this.variables[t](e,t,n)),null==i?"":i},e.prototype.tmStrFormat=function(e,t,n){if(!t.fmt)return e;var i=t.flag||"",r=t.guard;r=new RegExp(r,i.replace(/[^gim]/g,""));var o="string"==typeof t.fmt?this.tokenizeTmSnippet(t.fmt,"formatString"):t.fmt,a=this,s=e.replace(r,(function(){var e=a.variables.__;a.variables.__=[].slice.call(arguments);for(var t=a.resolveVariables(o,n),i="E",r=0;r<t.length;r++){var s=t[r];if("object"==typeof s)if(t[r]="",s.changeCase&&s.local){var l=t[r+1];l&&"string"==typeof l&&("u"==s.changeCase?t[r]=l[0].toUpperCase():t[r]=l[0].toLowerCase(),t[r+1]=l.substr(1))}else s.changeCase&&(i=s.changeCase);else"U"==i?t[r]=s.toUpperCase():"L"==i&&(t[r]=s.toLowerCase())}return a.variables.__=e,t.join("")}));return s},e.prototype.tmFormatFunction=function(e,t,n){return"upcase"==t.formatFunction?e.toUpperCase():"downcase"==t.formatFunction?e.toLowerCase():e},e.prototype.resolveVariables=function(e,t){for(var n=[],i="",r=!0,o=0;o<e.length;o++){var a=e[o];if("string"!=typeof a){if(a){if(r=!1,a.fmtString){var s=e.indexOf(a,o+1);-1==s&&(s=e.length),a.fmt=e.slice(o+1,s),o=s}if(a.text){var l=this.getVariableValue(t,a.text,i)+"";a.fmtString&&(l=this.tmStrFormat(l,a,t)),a.formatFunction&&(l=this.tmFormatFunction(l,a,t)),l&&!a.ifEnd?(n.push(l),c(a)):!l&&a.ifEnd&&c(a.ifEnd)}else a.elseEnd?c(a.elseEnd):(null!=a.tabstopId||null!=a.changeCase)&&n.push(a)}}else n.push(a),"\n"==a?(r=!0,i=""):r&&(i=/^\t*/.exec(a)[0],r=/\S/.test(a))}function c(t){var n=e.indexOf(t,o+1);-1!=n&&(o=n)}return n},e.prototype.getDisplayTextForSnippet=function(e,t){return f.call(this,e,t).text},e.prototype.insertSnippetForSelection=function(e,t,n){void 0===n&&(n={});var i=f.call(this,e,t,n),r=e.getSelectionRange(),o=e.session.replace(r,i.text),a=new m(e),s=e.inVirtualSelectionMode&&e.selection.index;a.addTabstops(i.tabstops,r.start,o,s)},e.prototype.insertSnippet=function(e,t,n){void 0===n&&(n={});var i=this;if(e.inVirtualSelectionMode)return i.insertSnippetForSelection(e,t,n);e.forEachSelection((function(){i.insertSnippetForSelection(e,t,n)}),null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},e.prototype.$getScope=function(e){var t=e.session.$mode.$id||"";if("html"===(t=t.split("/").pop())||"php"===t){"php"!==t||e.session.$mode.inlinePhp||(t="html");var n=e.getCursorPosition(),i=e.session.getState(n.row);"object"==typeof i&&(i=i[0]),i.substring&&("js-"==i.substring(0,3)?t="javascript":"css-"==i.substring(0,4)?t="css":"php-"==i.substring(0,4)&&(t="php"))}return t},e.prototype.getActiveScopes=function(e){var t=this.$getScope(e),n=[t],i=this.snippetMap;return i[t]&&i[t].includeScopes&&n.push.apply(n,i[t].includeScopes),n.push("_"),n},e.prototype.expandWithTab=function(e,t){var n=this,i=e.forEachSelection((function(){return n.expandSnippetForSelection(e,t)}),null,{keepOrder:!0});return i&&e.tabstopManager&&e.tabstopManager.tabNext(),i},e.prototype.expandSnippetForSelection=function(e,t){var n,i=e.getCursorPosition(),r=e.session.getLine(i.row),o=r.substring(0,i.column),a=r.substr(i.column),s=this.snippetMap;return this.getActiveScopes(e).some((function(e){var t=s[e];return t&&(n=this.findMatchingSnippet(t,o,a)),!!n}),this),!!n&&(t&&t.dryRun||(e.session.doc.removeInLine(i.row,i.column-n.replaceBefore.length,i.column+n.replaceAfter.length),this.variables.M__=n.matchBefore,this.variables.T__=n.matchAfter,this.insertSnippetForSelection(e,n.content),this.variables.M__=this.variables.T__=null),!0)},e.prototype.findMatchingSnippet=function(e,t,n){for(var i=e.length;i--;){var r=e[i];if((!r.startRe||r.startRe.test(t))&&(!r.endRe||r.endRe.test(n))&&(r.startRe||r.endRe))return r.matchBefore=r.startRe?r.startRe.exec(t):[""],r.matchAfter=r.endRe?r.endRe.exec(n):[""],r.replaceBefore=r.triggerRe?r.triggerRe.exec(t)[0]:"",r.replaceAfter=r.endTriggerRe?r.endTriggerRe.exec(n)[0]:"",r}},e.prototype.register=function(e,t){var n=this.snippetMap,i=this.snippetNameMap,r=this;function o(e){return e&&!/^\^?\(.*\)\$?$|^\\b$/.test(e)&&(e="(?:"+e+")"),e||""}function s(e,t,n){return e=o(e),t=o(t),n?(e=t+e)&&"$"!=e[e.length-1]&&(e+="$"):(e+=t)&&"^"!=e[0]&&(e="^"+e),new RegExp(e)}function l(e){e.scope||(e.scope=t||"_"),t=e.scope,n[t]||(n[t]=[],i[t]={});var o=i[t];if(e.name){var l=o[e.name];l&&r.unregister(l),o[e.name]=e}n[t].push(e),e.prefix&&(e.tabTrigger=e.prefix),!e.content&&e.body&&(e.content=Array.isArray(e.body)?e.body.join("\n"):e.body),e.tabTrigger&&!e.trigger&&(!e.guard&&/^\w/.test(e.tabTrigger)&&(e.guard="\\b"),e.trigger=a.escapeRegExp(e.tabTrigger)),(e.trigger||e.guard||e.endTrigger||e.endGuard)&&(e.startRe=s(e.trigger,e.guard,!0),e.triggerRe=new RegExp(e.trigger),e.endRe=s(e.endTrigger,e.endGuard,!0),e.endTriggerRe=new RegExp(e.endTrigger))}e||(e=[]),Array.isArray(e)?e.forEach(l):Object.keys(e).forEach((function(t){l(e[t])})),this._signal("registerSnippets",{scope:t})},e.prototype.unregister=function(e,t){var n=this.snippetMap,i=this.snippetNameMap;function r(e){var r=i[e.scope||t];if(r&&r[e.name]){delete r[e.name];var o=n[e.scope||t],a=o&&o.indexOf(e);a>=0&&o.splice(a,1)}}e.content?r(e):Array.isArray(e)&&e.forEach(r)},e.prototype.parseSnippetFile=function(e){e=e.replace(/\r/g,"");for(var t,n=[],i={},r=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm;t=r.exec(e);){if(t[1])try{i=JSON.parse(t[1]),n.push(i)}catch(e){}if(t[4])i.content=t[4].replace(/^\t/gm,""),n.push(i),i={};else{var o=t[2],a=t[3];if("regex"==o){var s=/\/((?:[^\/\\]|\\.)*)|$/g;i.guard=s.exec(a)[1],i.trigger=s.exec(a)[1],i.endTrigger=s.exec(a)[1],i.endGuard=s.exec(a)[1]}else"snippet"==o?(i.tabTrigger=a.match(/^\S*/)[0],i.name||(i.name=a)):o&&(i[o]=a)}}return n},e.prototype.getSnippetByName=function(e,t){var n,i=this.snippetNameMap;return this.getActiveScopes(t).some((function(t){var r=i[t];return r&&(n=r[e]),!!n}),this),n},e}();r.implement(g.prototype,o);var f=function(e,t,n){void 0===n&&(n={});var i=e.getCursorPosition(),r=e.session.getLine(i.row),o=e.session.getTabString(),a=r.match(/^\s*/)[0];i.column<a.length&&(a=a.slice(0,i.column)),t=t.replace(/\r/g,"");var s=this.tokenizeTmSnippet(t);s=(s=this.resolveVariables(s,e)).map((function(e){return"\n"!=e||n.excludeExtraIndent?"string"==typeof e?e.replace(/\t/g,o):e:e+a}));var l=[];s.forEach((function(e,t){if("object"==typeof e){var n=e.tabstopId,i=l[n];if(i||((i=l[n]=[]).index=n,i.value="",i.parents={}),-1===i.indexOf(e)){e.choices&&!i.choices&&(i.choices=e.choices),i.push(e);var r=s.indexOf(e,t+1);if(-1!==r){var o=s.slice(t+1,r);o.some((function(e){return"object"==typeof e}))&&!i.value?i.value=o:!o.length||i.value&&"string"==typeof i.value||(i.value=o.join(""))}}}})),l.forEach((function(e){e.length=0}));var c={};function d(e){for(var t=[],n=0;n<e.length;n++){var i=e[n];if("object"==typeof i){if(c[i.tabstopId])continue;i=t[e.lastIndexOf(i,n-1)]||{tabstopId:i.tabstopId}}t[n]=i}return t}for(var u=0;u<s.length;u++){var h=s[u];if("object"==typeof h){var p=h.tabstopId,g=l[p],f=s.indexOf(h,u+1);if(c[p])c[p]===h&&(delete c[p],Object.keys(c).forEach((function(e){g.parents[e]=!0})));else{c[p]=h;var m=g.value;"string"!=typeof m?m=d(m):h.fmt&&(m=this.tmStrFormat(m,h,e)),s.splice.apply(s,[u+1,Math.max(0,f-u)].concat(m,h)),-1===g.indexOf(h)&&g.push(h)}}}var y=0,v=0,b="";return s.forEach((function(e){if("string"==typeof e){var t=e.split("\n");t.length>1?(v=t[t.length-1].length,y+=t.length-1):v+=e.length,b+=e}else e&&(e.start?e.end={row:y,column:v}:e.start={row:y,column:v})})),{text:b,tabstops:l,tokens:s}},m=function(){function e(e){if(this.index=0,this.ranges=[],this.tabstops=[],e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=a.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)}return e.prototype.attach=function(e){this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.session=e.session,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},e.prototype.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges.length=0,this.tabstops.length=0,this.selectedTabstop=null,this.editor.off("change",this.$onChange),this.editor.off("changeSelection",this.$onChangeSelection),this.editor.off("changeSession",this.$onChangeSession),this.editor.commands.off("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.session=null,this.editor=null},e.prototype.onChange=function(e){for(var t="r"==e.action[0],n=this.selectedTabstop||{},i=n.parents||{},r=this.tabstops.slice(),o=0;o<r.length;o++){var a=r[o],s=a==n||i[a.index];if(a.rangeList.$bias=s?0:1,"remove"==e.action&&a!==n){var l=a.parents&&a.parents[n.index],c=a.rangeList.pointIndex(e.start,l);c=c<0?-c-1:c+1;var d=a.rangeList.pointIndex(e.end,l);d=d<0?-d-1:d-1;for(var u=a.rangeList.ranges.slice(c,d),h=0;h<u.length;h++)this.removeRange(u[h])}a.rangeList.$onChange(e)}var p=this.session;this.$inChange||!t||1!=p.getLength()||p.getValue()||this.detach()},e.prototype.updateLinkedFields=function(){var e=this.selectedTabstop;if(e&&e.hasLinkedRanges&&e.firstNonLinked){this.$inChange=!0;for(var n=this.session,i=n.getTextRange(e.firstNonLinked),r=0;r<e.length;r++){var o=e[r];if(o.linked){var a=o.original,s=t.snippetManager.tmStrFormat(i,a,this.editor);n.replace(o,s)}}this.$inChange=!1}},e.prototype.onAfterExec=function(e){e.command&&!e.command.readOnly&&this.updateLinkedFields()},e.prototype.onChangeSelection=function(){if(this.editor){for(var e=this.editor.selection.lead,t=this.editor.selection.anchor,n=this.editor.selection.isEmpty(),i=0;i<this.ranges.length;i++)if(!this.ranges[i].linked){var r=this.ranges[i].contains(e.row,e.column),o=n||this.ranges[i].contains(t.row,t.column);if(r&&o)return}this.detach()}},e.prototype.onChangeSession=function(){this.detach()},e.prototype.tabNext=function(e){var t=this.tabstops.length,n=this.index+(e||1);(n=Math.min(Math.max(n,1),t))==t&&(n=0),this.selectTabstop(n),this.updateTabstopMarkers(),0===n&&this.detach()},e.prototype.selectTabstop=function(e){this.$openTabstops=null;var t=this.tabstops[this.index];if(t&&this.addTabstopMarkers(t),this.index=e,(t=this.tabstops[this.index])&&t.length){this.selectedTabstop=t;var n=t.firstNonLinked||t;if(t.choices&&(n.cursor=n.start),this.editor.inVirtualSelectionMode)this.editor.selection.fromOrientedRange(n);else{var i=this.editor.multiSelect;i.toSingleRange(n);for(var r=0;r<t.length;r++)t.hasLinkedRanges&&t[r].linked||i.addRange(t[r].clone(),!0)}this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler),this.selectedTabstop&&this.selectedTabstop.choices&&this.editor.execCommand("startAutocomplete",{matches:this.selectedTabstop.choices})}},e.prototype.addTabstops=function(e,t,n){var i=this.useLink||!this.editor.getOption("enableMultiselect");if(this.$openTabstops||(this.$openTabstops=[]),!e[0]){var r=s.fromPoints(n,n);v(r.start,t),v(r.end,t),e[0]=[r],e[0].index=0}var o=[this.index+1,0],a=this.ranges,c=this.snippetId=(this.snippetId||0)+1;e.forEach((function(e,n){var r=this.$openTabstops[n]||e;r.snippetId=c;for(var d=0;d<e.length;d++){var u=e[d],h=s.fromPoints(u.start,u.end||u.start);y(h.start,t),y(h.end,t),h.original=u,h.tabstop=r,a.push(h),r!=e?r.unshift(h):r[d]=h,u.fmtString||r.firstNonLinked&&i?(h.linked=!0,r.hasLinkedRanges=!0):r.firstNonLinked||(r.firstNonLinked=h)}r.firstNonLinked||(r.hasLinkedRanges=!1),r===e&&(o.push(r),this.$openTabstops[n]=r),this.addTabstopMarkers(r),r.rangeList=r.rangeList||new l,r.rangeList.$bias=0,r.rangeList.addList(r)}),this),o.length>2&&(this.tabstops.length&&o.push(o.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,o))},e.prototype.addTabstopMarkers=function(e){var t=this.session;e.forEach((function(e){e.markerId||(e.markerId=t.addMarker(e,"ace_snippet-marker","text"))}))},e.prototype.removeTabstopMarkers=function(e){var t=this.session;e.forEach((function(e){t.removeMarker(e.markerId),e.markerId=null}))},e.prototype.updateTabstopMarkers=function(){if(this.selectedTabstop){var e=this.selectedTabstop.snippetId;0===this.selectedTabstop.index&&e--,this.tabstops.forEach((function(t){t.snippetId===e?this.addTabstopMarkers(t):this.removeTabstopMarkers(t)}),this)}},e.prototype.removeRange=function(e){var t=e.tabstop.indexOf(e);-1!=t&&e.tabstop.splice(t,1),-1!=(t=this.ranges.indexOf(e))&&this.ranges.splice(t,1),-1!=(t=e.tabstop.rangeList.ranges.indexOf(e))&&e.tabstop.splice(t,1),this.session.removeMarker(e.markerId),e.tabstop.length||(-1!=(t=this.tabstops.indexOf(e.tabstop))&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},e}();m.prototype.keyboardHandler=new c,m.prototype.keyboardHandler.bindKeys({Tab:function(e){t.snippetManager&&t.snippetManager.expandWithTab(e)||(e.tabstopManager.tabNext(1),e.renderer.scrollCursorIntoView())},"Shift-Tab":function(e){e.tabstopManager.tabNext(-1),e.renderer.scrollCursorIntoView()},Esc:function(e){e.tabstopManager.detach()}});var y=function(e,t){0==e.row&&(e.column+=t.column),e.row+=t.row},v=function(e,t){e.row==t.row&&(e.column-=t.column),e.row-=t.row};i.importCssString("\n.ace_snippet-marker {\n -moz-box-sizing: border-box;\n box-sizing: border-box;\n background: rgba(194, 193, 208, 0.09);\n border: 1px dotted rgba(211, 208, 235, 0.62);\n position: absolute;\n}","snippets.css",!1),t.snippetManager=new g;var b=e("./editor").Editor;(function(){this.insertSnippet=function(e,n){return t.snippetManager.insertSnippet(this,e,n)},this.expandSnippet=function(e){return t.snippetManager.expandWithTab(this,e)}}).call(b.prototype)})),ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom","ace/config","ace/lib/useragent"],(function(e,t,n){"use strict";var i=e("../virtual_renderer").VirtualRenderer,r=e("../editor").Editor,o=e("../range").Range,a=e("../lib/event"),s=e("../lib/lang"),l=e("../lib/dom"),c=e("../config").nls,d=e("./../lib/useragent"),u=function(e){return"suggest-aria-id:".concat(e)},h=d.isSafari?"menu":"listbox",p=d.isSafari?"menuitem":"option",g=d.isSafari?"aria-current":"aria-selected",f=function(e){var t=new i(e);t.$maxLines=4;var n=new r(t);return n.setHighlightActiveLine(!1),n.setShowPrintMargin(!1),n.renderer.setShowGutter(!1),n.renderer.setHighlightGutterLine(!1),n.$mouseHandler.$focusTimeout=0,n.$highlightTagPending=!0,n};l.importCssString('\n.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\n background-color: #CAD6FA;\n z-index: 1;\n}\n.ace_dark.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\n background-color: #3a674e;\n}\n.ace_editor.ace_autocomplete .ace_line-hover {\n border: 1px solid #abbffe;\n margin-top: -1px;\n background: rgba(233,233,253,0.4);\n position: absolute;\n z-index: 2;\n}\n.ace_dark.ace_editor.ace_autocomplete .ace_line-hover {\n border: 1px solid rgba(109, 150, 13, 0.8);\n background: rgba(58, 103, 78, 0.62);\n}\n.ace_completion-meta {\n opacity: 0.5;\n margin-left: 0.9em;\n}\n.ace_completion-message {\n margin-left: 0.9em;\n color: blue;\n}\n.ace_editor.ace_autocomplete .ace_completion-highlight{\n color: #2d69c7;\n}\n.ace_dark.ace_editor.ace_autocomplete .ace_completion-highlight{\n color: #93ca12;\n}\n.ace_editor.ace_autocomplete {\n width: 300px;\n z-index: 200000;\n border: 1px lightgray solid;\n position: fixed;\n box-shadow: 2px 3px 5px rgba(0,0,0,.2);\n line-height: 1.4;\n background: #fefefe;\n color: #111;\n}\n.ace_dark.ace_editor.ace_autocomplete {\n border: 1px #484747 solid;\n box-shadow: 2px 3px 5px rgba(0, 0, 0, 0.51);\n line-height: 1.4;\n background: #25282c;\n color: #c1c1c1;\n}\n.ace_autocomplete .ace_text-layer {\n width: calc(100% - 8px);\n}\n.ace_autocomplete .ace_line {\n display: flex;\n align-items: center;\n}\n.ace_autocomplete .ace_line > * {\n min-width: 0;\n flex: 0 0 auto;\n}\n.ace_autocomplete .ace_line .ace_ {\n flex: 0 1 auto;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.ace_autocomplete .ace_completion-spacer {\n flex: 1;\n}\n.ace_autocomplete.ace_loading:after {\n content: "";\n position: absolute;\n top: 0px;\n height: 2px;\n width: 8%;\n background: blue;\n z-index: 100;\n animation: ace_progress 3s infinite linear;\n animation-delay: 300ms;\n transform: translateX(-100%) scaleX(1);\n}\n@keyframes ace_progress {\n 0% { transform: translateX(-100%) scaleX(1) }\n 50% { transform: translateX(625%) scaleX(2) } \n 100% { transform: translateX(1500%) scaleX(3) } \n}\n@media (prefers-reduced-motion) {\n .ace_autocomplete.ace_loading:after {\n transform: translateX(625%) scaleX(2);\n animation: none;\n }\n}\n',"autocompletion.css",!1),t.AcePopup=function(e){var t=l.createElement("div"),n=f(t);e&&e.appendChild(t),t.style.display="none",n.renderer.content.style.cursor="default",n.renderer.setStyle("ace_autocomplete"),n.renderer.$textLayer.element.setAttribute("role",h),n.renderer.$textLayer.element.setAttribute("aria-roledescription",c("autocomplete.popup.aria-roledescription","Autocomplete suggestions")),n.renderer.$textLayer.element.setAttribute("aria-label",c("autocomplete.popup.aria-label","Autocomplete suggestions")),n.renderer.textarea.setAttribute("aria-hidden","true"),n.setOption("displayIndentGuides",!1),n.setOption("dragDelay",150);var i,r=function(){};n.focus=r,n.$isFocused=!0,n.renderer.$cursorLayer.restartTimer=r,n.renderer.$cursorLayer.element.style.opacity="0",n.renderer.$maxLines=8,n.renderer.$keepTextAreaAtCursor=!1,n.setHighlightActiveLine(!1),n.session.highlight(""),n.session.$searchHighlight.clazz="ace_highlight-marker",n.on("mousedown",(function(e){var t=e.getDocumentPosition();n.selection.moveToPosition(t),m.start.row=m.end.row=t.row,e.stop()}));var d=new o(-1,0,-1,1/0),m=new o(-1,0,-1,1/0);m.id=n.session.addMarker(m,"ace_active-line","fullLine"),n.setSelectOnHover=function(e){e?d.id&&(n.session.removeMarker(d.id),d.id=null):d.id=n.session.addMarker(d,"ace_line-hover","fullLine")},n.setSelectOnHover(!1),n.on("mousemove",(function(e){if(i){if(i.x!=e.x||i.y!=e.y){(i=e).scrollTop=n.renderer.scrollTop,n.isMouseOver=!0;var t=i.getDocumentPosition().row;d.start.row!=t&&(d.id||n.setRow(t),v(t))}}else i=e})),n.renderer.on("beforeRender",(function(){if(i&&-1!=d.start.row){i.$pos=null;var e=i.getDocumentPosition().row;d.id||n.setRow(e),v(e,!0)}})),n.renderer.on("afterRender",(function(){for(var e=n.renderer.$textLayer,t=e.config.firstRow,i=e.config.lastRow;t<=i;t++){var r=e.element.childNodes[t-e.config.firstRow];r.setAttribute("role",p),r.setAttribute("aria-roledescription",c("autocomplete.popup.item.aria-roledescription","item")),r.setAttribute("aria-setsize",n.data.length),r.setAttribute("aria-describedby","doc-tooltip"),r.setAttribute("aria-posinset",t+1);var o=n.getData(t);if(o){var a="".concat(o.caption||o.value).concat(o.meta?", ".concat(o.meta):"");r.setAttribute("aria-label",a)}r.querySelectorAll(".ace_completion-highlight").forEach((function(e){e.setAttribute("role","mark")}))}})),n.renderer.on("afterRender",(function(){var e=n.getRow(),t=n.renderer.$textLayer,i=t.element.childNodes[e-t.config.firstRow],r=document.activeElement;if(i!==n.selectedNode&&n.selectedNode&&(l.removeCssClass(n.selectedNode,"ace_selected"),n.selectedNode.removeAttribute(g),n.selectedNode.removeAttribute("id")),r.removeAttribute("aria-activedescendant"),n.selectedNode=i,i){var o=u(e);l.addCssClass(i,"ace_selected"),i.id=o,t.element.setAttribute("aria-activedescendant",o),r.setAttribute("aria-activedescendant",o),i.setAttribute(g,"true")}}));var y=function(){v(-1)},v=function(e,t){e!==d.start.row&&(d.start.row=d.end.row=e,t||n.session._emit("changeBackMarker"),n._emit("changeHoverMarker"))};n.getHoveredRow=function(){return d.start.row},a.addListener(n.container,"mouseout",(function(){n.isMouseOver=!1,y()})),n.on("hide",y),n.on("changeSelection",y),n.session.doc.getLength=function(){return n.data.length},n.session.doc.getLine=function(e){var t=n.data[e];return"string"==typeof t?t:t&&t.value||""};var b=n.session.bgTokenizer;return b.$tokenizeRow=function(e){var t=n.data[e],i=[];if(!t)return i;"string"==typeof t&&(t={value:t});var r=t.caption||t.value||t.name;function o(e,n){e&&i.push({type:(t.className||"")+(n||""),value:e})}for(var a=r.toLowerCase(),s=(n.filterText||"").toLowerCase(),l=0,c=0,d=0;d<=s.length;d++)if(d!=c&&(t.matchMask&1<<d||d==s.length)){var u=s.slice(c,d);c=d;var h=a.indexOf(u,l);if(-1==h)continue;o(r.slice(l,h),""),l=h+u.length,o(r.slice(h,l),"completion-highlight")}return o(r.slice(l,r.length),""),i.push({type:"completion-spacer",value:" "}),t.meta&&i.push({type:"completion-meta",value:t.meta}),t.message&&i.push({type:"completion-message",value:t.message}),i},b.$updateOnChange=r,b.start=r,n.session.$computeWidth=function(){return this.screenWidth=0},n.isOpen=!1,n.isTopdown=!1,n.autoSelect=!0,n.filterText="",n.isMouseOver=!1,n.data=[],n.setData=function(e,t){n.filterText=t||"",n.setValue(s.stringRepeat("\n",e.length),-1),n.data=e||[],n.setRow(0)},n.getData=function(e){return n.data[e]},n.getRow=function(){return m.start.row},n.setRow=function(e){e=Math.max(this.autoSelect?0:-1,Math.min(this.data.length-1,e)),m.start.row!=e&&(n.selection.clearSelection(),m.start.row=m.end.row=e||0,n.session._emit("changeBackMarker"),n.moveCursorTo(e||0,0),n.isOpen&&n._signal("select"))},n.on("changeSelection",(function(){n.isOpen&&n.setRow(n.selection.lead.row),n.renderer.scrollCursorIntoView()})),n.hide=function(){this.container.style.display="none",n.anchorPos=null,n.anchor=null,n.isOpen&&(n.isOpen=!1,this._signal("hide"))},n.tryShow=function(e,t,r,o){if(!o&&n.isOpen&&n.anchorPos&&n.anchor&&n.anchorPos.top===e.top&&n.anchorPos.left===e.left&&n.anchor===r)return!0;var a=this.container,s=this.renderer.scrollBar.width||10,l=window.innerHeight-s,c=window.innerWidth-s,d=this.renderer,u=d.$maxLines*t*1.4,h={top:0,bottom:0,left:0},p=l-e.top-3*this.$borderSize-t,g=e.top-3*this.$borderSize;r||(r=g<=p||p>=u?"bottom":"top"),"top"===r?(h.bottom=e.top-this.$borderSize,h.top=h.bottom-u):"bottom"===r&&(h.top=e.top+t+this.$borderSize,h.bottom=h.top+u);var f=h.top>=0&&h.bottom<=l;if(!o&&!f)return!1;d.$maxPixelHeight=f?null:"top"===r?g:p,"top"===r?(a.style.top="",a.style.bottom=l+s-h.bottom+"px",n.isTopdown=!1):(a.style.top=h.top+"px",a.style.bottom="",n.isTopdown=!0),a.style.display="";var m=e.left;return m+a.offsetWidth>c&&(m=c-a.offsetWidth),a.style.left=m+"px",a.style.right="",n.isOpen||(n.isOpen=!0,this._signal("show"),i=null),n.anchorPos=e,n.anchor=r,!0},n.show=function(e,t,n){this.tryShow(e,t,n?"bottom":void 0,!0)},n.goTo=function(e){var t=this.getRow(),n=this.session.getLength()-1;switch(e){case"up":t=t<=0?n:t-1;break;case"down":t=t>=n?-1:t+1;break;case"start":t=0;break;case"end":t=n}this.setRow(t)},n.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},n.$imageSize=0,n.$borderSize=1,n},t.$singleLineEditor=f,t.getAriaId=u})),ace.define("ace/autocomplete/inline_screenreader",["require","exports","module"],(function(e,t,n){"use strict";var i=function(){function e(e){this.editor=e,this.screenReaderDiv=document.createElement("div"),this.screenReaderDiv.classList.add("ace_screenreader-only"),this.editor.container.appendChild(this.screenReaderDiv)}return e.prototype.setScreenReaderContent=function(e){for(!this.popup&&this.editor.completer&&this.editor.completer.popup&&(this.popup=this.editor.completer.popup,this.popup.renderer.on("afterRender",function(){var e=this.popup.getRow(),t=this.popup.renderer.$textLayer,n=t.element.childNodes[e-t.config.firstRow];if(n){for(var i="doc-tooltip ",r=0;r<this._lines.length;r++)i+="ace-inline-screenreader-line-".concat(r," ");n.setAttribute("aria-describedby",i)}}.bind(this)));this.screenReaderDiv.firstChild;)this.screenReaderDiv.removeChild(this.screenReaderDiv.firstChild);this._lines=e.split(/\r\n|\r|\n/);var t=this.createCodeBlock();this.screenReaderDiv.appendChild(t)},e.prototype.destroy=function(){this.screenReaderDiv.remove()},e.prototype.createCodeBlock=function(){var e=document.createElement("pre");e.setAttribute("id","ace-inline-screenreader");for(var t=0;t<this._lines.length;t++){var n=document.createElement("code");n.setAttribute("id","ace-inline-screenreader-line-".concat(t));var i=document.createTextNode(this._lines[t]);n.appendChild(i),e.appendChild(n)}return e},e}();t.AceInlineScreenReader=i})),ace.define("ace/autocomplete/inline",["require","exports","module","ace/snippets","ace/autocomplete/inline_screenreader"],(function(e,t,n){"use strict";var i=e("../snippets").snippetManager,r=e("./inline_screenreader").AceInlineScreenReader,o=function(){function e(){this.editor=null}return e.prototype.show=function(e,t,n){if(n=n||"",e&&this.editor&&this.editor!==e&&(this.hide(),this.editor=null,this.inlineScreenReader=null),!e||!t)return!1;this.inlineScreenReader||(this.inlineScreenReader=new r(e));var o=t.snippet?i.getDisplayTextForSnippet(e,t.snippet):t.value;return!(t.hideInlinePreview||!o||!o.startsWith(n)||(this.editor=e,this.inlineScreenReader.setScreenReaderContent(o),""===(o=o.slice(n.length))?e.removeGhostText():e.setGhostText(o),0))},e.prototype.isOpen=function(){return!!this.editor&&!!this.editor.renderer.$ghostText},e.prototype.hide=function(){return!!this.editor&&(this.editor.removeGhostText(),!0)},e.prototype.destroy=function(){this.hide(),this.editor=null,this.inlineScreenReader&&(this.inlineScreenReader.destroy(),this.inlineScreenReader=null)},e}();t.AceInline=o})),ace.define("ace/autocomplete/util",["require","exports","module"],(function(e,t,n){"use strict";t.parForEach=function(e,t,n){var i=0,r=e.length;0===r&&n();for(var o=0;o<r;o++)t(e[o],(function(e,t){++i===r&&n(e,t)}))};var i=/[a-zA-Z_0-9\$\-\u00A2-\u2000\u2070-\uFFFF]/;t.retrievePrecedingIdentifier=function(e,t,n){n=n||i;for(var r=[],o=t-1;o>=0&&n.test(e[o]);o--)r.push(e[o]);return r.reverse().join("")},t.retrieveFollowingIdentifier=function(e,t,n){n=n||i;for(var r=[],o=t;o<e.length&&n.test(e[o]);o++)r.push(e[o]);return r},t.getCompletionPrefix=function(e){var t,n=e.getCursorPosition(),i=e.session.getLine(n.row);return e.completers.forEach(function(e){e.identifierRegexps&&e.identifierRegexps.forEach(function(e){!t&&e&&(t=this.retrievePrecedingIdentifier(i,n.column,e))}.bind(this))}.bind(this)),t||this.retrievePrecedingIdentifier(i,n.column)},t.triggerAutocomplete=function(e,t){return t=null==t?e.session.getPrecedingCharacter():t,e.completers.some((function(e){if(e.triggerCharacters&&Array.isArray(e.triggerCharacters))return e.triggerCharacters.includes(t)}))}})),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/inline","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/lang","ace/lib/dom","ace/snippets","ace/config","ace/lib/event","ace/lib/scroll"],(function(e,t,n){"use strict";var i=e("./keyboard/hash_handler").HashHandler,r=e("./autocomplete/popup").AcePopup,o=e("./autocomplete/inline").AceInline,a=e("./autocomplete/popup").getAriaId,s=e("./autocomplete/util"),l=e("./lib/lang"),c=e("./lib/dom"),d=e("./snippets").snippetManager,u=e("./config"),h=e("./lib/event"),p=e("./lib/scroll").preventParentScroll,g=function(e,t){t.completer&&t.completer.destroy()},f=function(){function e(){this.autoInsert=!1,this.autoSelect=!0,this.autoShown=!1,this.exactMatch=!1,this.inlineEnabled=!1,this.keyboardHandler=new i,this.keyboardHandler.bindKeys(this.commands),this.parentNode=null,this.setSelectOnHover=!1,this.hasSeen=new Set,this.showLoadingState=!1,this.stickySelectionDelay=500,this.blurListener=this.blurListener.bind(this),this.changeListener=this.changeListener.bind(this),this.mousedownListener=this.mousedownListener.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this),this.onLayoutChange=this.onLayoutChange.bind(this),this.changeTimer=l.delayedCall(function(){this.updateCompletions(!0)}.bind(this)),this.tooltipTimer=l.delayedCall(this.updateDocTooltip.bind(this),50),this.popupTimer=l.delayedCall(this.$updatePopupPosition.bind(this),50),this.stickySelectionTimer=l.delayedCall(function(){this.stickySelection=!0}.bind(this),this.stickySelectionDelay),this.$firstOpenTimer=l.delayedCall(function(){var t=this.completionProvider&&this.completionProvider.initialPosition;this.autoShown||this.popup&&this.popup.isOpen||!t||0===this.editor.completers.length||(this.completions=new y(e.completionsForLoading),this.openPopup(this.editor,t.prefix,!1),this.popup.renderer.setStyle("ace_loading",!0))}.bind(this),this.stickySelectionDelay)}return Object.defineProperty(e,"completionsForLoading",{get:function(){return[{caption:u.nls("autocomplete.loading","Loading..."),value:""}]},enumerable:!1,configurable:!0}),e.prototype.$init=function(){return this.popup=new r(this.parentNode||document.body||document.documentElement),this.popup.on("click",function(e){this.insertMatch(),e.stop()}.bind(this)),this.popup.focus=this.editor.focus.bind(this.editor),this.popup.on("show",this.$onPopupShow.bind(this)),this.popup.on("hide",this.$onHidePopup.bind(this)),this.popup.on("select",this.$onPopupChange.bind(this)),h.addListener(this.popup.container,"mouseout",this.mouseOutListener.bind(this)),this.popup.on("changeHoverMarker",this.tooltipTimer.bind(null,null)),this.popup.renderer.on("afterRender",this.$onPopupRender.bind(this)),this.popup},e.prototype.$initInline=function(){if(this.inlineEnabled&&!this.inlineRenderer)return this.inlineRenderer=new o,this.inlineRenderer},e.prototype.getPopup=function(){return this.popup||this.$init()},e.prototype.$onHidePopup=function(){this.inlineRenderer&&this.inlineRenderer.hide(),this.hideDocTooltip(),this.stickySelectionTimer.cancel(),this.popupTimer.cancel(),this.stickySelection=!1},e.prototype.$seen=function(e){!this.hasSeen.has(e)&&e&&e.completer&&e.completer.onSeen&&"function"==typeof e.completer.onSeen&&(e.completer.onSeen(this.editor,e),this.hasSeen.add(e))},e.prototype.$onPopupChange=function(e){if(this.inlineRenderer&&this.inlineEnabled){var t=e?null:this.popup.getData(this.popup.getRow());if(this.$updateGhostText(t),this.popup.isMouseOver&&this.setSelectOnHover)return void this.tooltipTimer.call(null,null);this.popupTimer.schedule(),this.tooltipTimer.schedule()}else this.popupTimer.call(null,null),this.tooltipTimer.call(null,null)},e.prototype.$updateGhostText=function(e){var t=this.base.row,n=this.base.column,i=this.editor.getCursorPosition().column,r=this.editor.session.getLine(t).slice(n,i);this.inlineRenderer.show(this.editor,e,r)?this.$seen(e):this.inlineRenderer.hide()},e.prototype.$onPopupRender=function(){var e=this.inlineRenderer&&this.inlineEnabled;if(this.completions&&this.completions.filtered&&this.completions.filtered.length>0)for(var t=this.popup.getFirstVisibleRow();t<=this.popup.getLastVisibleRow();t++){var n=this.popup.getData(t);!n||e&&!n.hideInlinePreview||this.$seen(n)}},e.prototype.$onPopupShow=function(e){this.$onPopupChange(e),this.stickySelection=!1,this.stickySelectionDelay>=0&&this.stickySelectionTimer.schedule(this.stickySelectionDelay)},e.prototype.observeLayoutChanges=function(){if(!this.$elements&&this.editor){window.addEventListener("resize",this.onLayoutChange,{passive:!0}),window.addEventListener("wheel",this.mousewheelListener);for(var e=this.editor.container.parentNode,t=[];e;)t.push(e),e.addEventListener("scroll",this.onLayoutChange,{passive:!0}),e=e.parentNode;this.$elements=t}},e.prototype.unObserveLayoutChanges=function(){var e=this;window.removeEventListener("resize",this.onLayoutChange,{passive:!0}),window.removeEventListener("wheel",this.mousewheelListener),this.$elements&&this.$elements.forEach((function(t){t.removeEventListener("scroll",e.onLayoutChange,{passive:!0})})),this.$elements=null},e.prototype.onLayoutChange=function(){if(!this.popup.isOpen)return this.unObserveLayoutChanges();this.$updatePopupPosition(),this.updateDocTooltip()},e.prototype.$updatePopupPosition=function(){var e=this.editor,t=e.renderer,n=t.layerConfig.lineHeight,i=t.$cursorLayer.getPixelPosition(this.base,!0);i.left-=this.popup.getTextLeftOffset();var r=e.container.getBoundingClientRect();i.top+=r.top-t.layerConfig.offset,i.left+=r.left-e.renderer.scrollLeft,i.left+=t.gutterWidth;var o={top:i.top,left:i.left};t.$ghostText&&t.$ghostTextWidget&&this.base.row===t.$ghostText.position.row&&(o.top+=t.$ghostTextWidget.el.offsetHeight);var a=e.container.getBoundingClientRect().bottom-n,s=a<o.top?{top:a,left:o.left}:o;this.popup.tryShow(s,n,"bottom")||this.popup.tryShow(i,n,"top")||this.popup.show(i,n)},e.prototype.openPopup=function(e,t,n){this.$firstOpenTimer.cancel(),this.popup||this.$init(),this.inlineEnabled&&!this.inlineRenderer&&this.$initInline(),this.popup.autoSelect=this.autoSelect,this.popup.setSelectOnHover(this.setSelectOnHover);var i,r=this.popup.getRow(),o=this.popup.data[r];this.popup.setData(this.completions.filtered,this.completions.filterText),this.editor.textInput.setAriaOptions&&this.editor.textInput.setAriaOptions({activeDescendant:a(this.popup.getRow()),inline:this.inlineEnabled}),e.keyBinding.addKeyboardHandler(this.keyboardHandler),this.stickySelection&&(i=this.popup.data.indexOf(o)),i&&-1!==i||(i=0),this.popup.setRow(this.autoSelect?i:-1),i===r&&o!==this.completions.filtered[i]&&this.$onPopupChange();var s=this.inlineRenderer&&this.inlineEnabled;if(i===r&&s){var l=this.popup.getData(this.popup.getRow());this.$updateGhostText(l)}n||(this.popup.setTheme(e.getTheme()),this.popup.setFontSize(e.getFontSize()),this.$updatePopupPosition(),this.tooltipNode&&this.updateDocTooltip()),this.changeTimer.cancel(),this.observeLayoutChanges()},e.prototype.detach=function(){this.editor&&(this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.off("changeSelection",this.changeListener),this.editor.off("blur",this.blurListener),this.editor.off("mousedown",this.mousedownListener),this.editor.off("mousewheel",this.mousewheelListener)),this.$firstOpenTimer.cancel(),this.changeTimer.cancel(),this.hideDocTooltip(),this.completionProvider&&this.completionProvider.detach(),this.popup&&this.popup.isOpen&&this.popup.hide(),this.popup&&this.popup.renderer&&this.popup.renderer.off("afterRender",this.$onPopupRender),this.base&&this.base.detach(),this.activated=!1,this.completionProvider=this.completions=this.base=null,this.unObserveLayoutChanges()},e.prototype.changeListener=function(e){var t=this.editor.selection.lead;(t.row!=this.base.row||t.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},e.prototype.blurListener=function(e){var t=document.activeElement,n=this.editor.textInput.getElement(),i=e.relatedTarget&&this.tooltipNode&&this.tooltipNode.contains(e.relatedTarget),r=this.popup&&this.popup.container;t==n||t.parentNode==r||i||t==this.tooltipNode||e.relatedTarget==n||this.detach()},e.prototype.mousedownListener=function(e){this.detach()},e.prototype.mousewheelListener=function(e){this.popup&&!this.popup.isMouseOver&&this.detach()},e.prototype.mouseOutListener=function(e){this.popup.isOpen&&this.$updatePopupPosition()},e.prototype.goTo=function(e){this.popup.goTo(e)},e.prototype.insertMatch=function(e,t){if(e||(e=this.popup.getData(this.popup.getRow())),!e)return!1;if(""===e.value)return this.detach();var n=this.completions,i=this.getCompletionProvider().insertMatch(this.editor,e,n.filterText,t);return this.completions==n&&this.detach(),i},e.prototype.showPopup=function(e,t){this.editor&&this.detach(),this.activated=!0,this.editor=e,e.completer!=this&&(e.completer&&e.completer.detach(),e.completer=this),e.on("changeSelection",this.changeListener),e.on("blur",this.blurListener),e.on("mousedown",this.mousedownListener),e.on("mousewheel",this.mousewheelListener),this.updateCompletions(!1,t)},e.prototype.getCompletionProvider=function(e){return this.completionProvider||(this.completionProvider=new m(e)),this.completionProvider},e.prototype.gatherCompletions=function(e,t){return this.getCompletionProvider().gatherCompletions(e,t)},e.prototype.updateCompletions=function(t,n){if(t&&this.base&&this.completions){var i=this.editor.getCursorPosition();if((o=this.editor.session.getTextRange({start:this.base,end:i}))==this.completions.filterText)return;return this.completions.setFilter(o),this.completions.filtered.length&&(1!=this.completions.filtered.length||this.completions.filtered[0].value!=o||this.completions.filtered[0].snippet)?void this.openPopup(this.editor,o,t):this.detach()}if(n&&n.matches)return i=this.editor.getSelectionRange().start,this.base=this.editor.session.doc.createAnchor(i.row,i.column),this.base.$insertRight=!0,this.completions=new y(n.matches),this.getCompletionProvider().completions=this.completions,this.openPopup(this.editor,"",t);var r=this.editor.getSession(),o=(i=this.editor.getCursorPosition(),s.getCompletionPrefix(this.editor));this.base=r.doc.createAnchor(i.row,i.column-o.length),this.base.$insertRight=!0;var a={exactMatch:this.exactMatch,ignoreCaption:this.ignoreCaption};this.getCompletionProvider({prefix:o,pos:i}).provideCompletions(this.editor,a,function(n,i,r){var o=i.filtered,a=s.getCompletionPrefix(this.editor);if(this.$firstOpenTimer.cancel(),r){if(!o.length){var l=!this.autoShown&&this.emptyMessage;if("function"==typeof l&&(l=this.emptyMessage(a)),l){var c=[{caption:l,value:""}];return this.completions=new y(c),this.openPopup(this.editor,a,t),this.popup.renderer.setStyle("ace_loading",!1),void this.popup.renderer.setStyle("ace_empty-message",!0)}return this.detach()}if(1==o.length&&o[0].value==a&&!o[0].snippet)return this.detach();if(this.autoInsert&&!this.autoShown&&1==o.length)return this.insertMatch(o[0])}this.completions=!r&&this.showLoadingState?new y(e.completionsForLoading.concat(o),i.filterText):i,this.openPopup(this.editor,a,t),this.popup.renderer.setStyle("ace_empty-message",!1),this.popup.renderer.setStyle("ace_loading",!r)}.bind(this)),!this.showLoadingState||this.autoShown||this.popup&&this.popup.isOpen||this.$firstOpenTimer.delay(this.stickySelectionDelay/2)},e.prototype.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()},e.prototype.updateDocTooltip=function(){var e=this.popup,t=this.completions&&this.completions.filtered,n=t&&(t[e.getHoveredRow()]||t[e.getRow()]),i=null;if(!n||!this.editor||!this.popup.isOpen)return this.hideDocTooltip();for(var r=this.editor.completers.length,o=0;o<r;o++){var a=this.editor.completers[o];if(a.getDocTooltip&&n.completerId===a.id){i=a.getDocTooltip(n);break}}if(i||"string"==typeof n||(i=n),"string"==typeof i&&(i={docText:i}),!i||!i.docHTML&&!i.docText)return this.hideDocTooltip();this.showDocTooltip(i)},e.prototype.showDocTooltip=function(e){this.tooltipNode||(this.tooltipNode=c.createElement("div"),this.tooltipNode.style.margin="0",this.tooltipNode.style.pointerEvents="auto",this.tooltipNode.style.overscrollBehavior="contain",this.tooltipNode.tabIndex=-1,this.tooltipNode.onblur=this.blurListener.bind(this),this.tooltipNode.onclick=this.onTooltipClick.bind(this),this.tooltipNode.id="doc-tooltip",this.tooltipNode.setAttribute("role","tooltip"),this.tooltipNode.addEventListener("wheel",p));var t=this.editor.renderer.theme;this.tooltipNode.className="ace_tooltip ace_doc-tooltip "+(t.isDark?"ace_dark ":"")+(t.cssClass||"");var n=this.tooltipNode;e.docHTML?n.innerHTML=e.docHTML:e.docText&&(n.textContent=e.docText),n.parentNode||this.popup.container.appendChild(this.tooltipNode);var i=this.popup,r=i.container.getBoundingClientRect(),o=400,a=300,s=i.renderer.scrollBar.width||10,l=r.left,d=window.innerWidth-r.right-s,u=i.isTopdown?r.top:window.innerHeight-s-r.bottom,h=[Math.min(d/o,1),Math.min(l/o,1),Math.min(u/a*.9)],g=Math.max.apply(Math,h),f=n.style;f.display="block",g==h[0]?(f.left=r.right+1+"px",f.right="",f.maxWidth=o*g+"px",f.top=r.top+"px",f.bottom="",f.maxHeight=Math.min(window.innerHeight-s-r.top,a)+"px"):g==h[1]?(f.right=window.innerWidth-r.left+"px",f.left="",f.maxWidth=o*g+"px",f.top=r.top+"px",f.bottom="",f.maxHeight=Math.min(window.innerHeight-s-r.top,a)+"px"):g==h[2]&&(f.left=window.innerWidth-r.left+"px",f.maxWidth=Math.min(o,window.innerWidth)+"px",i.isTopdown?(f.top=r.bottom+"px",f.left=r.left+"px",f.right="",f.bottom="",f.maxHeight=Math.min(window.innerHeight-s-r.bottom,a)+"px"):(f.top=i.container.offsetTop-n.offsetHeight+"px",f.left=r.left+"px",f.right="",f.bottom="",f.maxHeight=Math.min(i.container.offsetTop,a)+"px"))},e.prototype.hideDocTooltip=function(){if(this.tooltipTimer.cancel(),this.tooltipNode){var e=this.tooltipNode;this.editor.isFocused()||document.activeElement!=e||this.editor.focus(),this.tooltipNode=null,e.parentNode&&e.parentNode.removeChild(e)}},e.prototype.onTooltipClick=function(e){for(var t=e.target;t&&t!=this.tooltipNode;){if("A"==t.nodeName&&t.href){t.rel="noreferrer",t.target="_blank";break}t=t.parentNode}},e.prototype.destroy=function(){if(this.detach(),this.popup){this.popup.destroy();var e=this.popup.container;e&&e.parentNode&&e.parentNode.removeChild(e)}this.editor&&this.editor.completer==this&&(this.editor.off("destroy",g),this.editor.completer=null),this.inlineRenderer=this.popup=this.editor=null},e.for=function(t){return t.completer instanceof e||(t.completer&&(t.completer.destroy(),t.completer=null),u.get("sharedPopups")?(e.$sharedInstance||(e.$sharedInstance=new e),t.completer=e.$sharedInstance):(t.completer=new e,t.once("destroy",g))),t.completer},e}();f.prototype.commands={Up:function(e){e.completer.goTo("up")},Down:function(e){e.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(e){e.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(e){e.completer.goTo("end")},Esc:function(e){e.completer.detach()},Return:function(e){return e.completer.insertMatch()},"Shift-Return":function(e){e.completer.insertMatch(null,{deleteSuffix:!0})},Tab:function(e){var t=e.completer.insertMatch();if(t||e.tabstopManager)return t;e.completer.goTo("down")},Backspace:function(e){e.execCommand("backspace"),!s.getCompletionPrefix(e)&&e.completer&&e.completer.detach()},PageUp:function(e){e.completer.popup.gotoPageUp()},PageDown:function(e){e.completer.popup.gotoPageDown()}},f.startCommand={name:"startAutocomplete",exec:function(e,t){var n=f.for(e);n.autoInsert=!1,n.autoSelect=!0,n.autoShown=!1,n.showPopup(e,t),n.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var m=function(){function e(e){this.initialPosition=e,this.active=!0}return e.prototype.insertByIndex=function(e,t,n){return!(!this.completions||!this.completions.filtered)&&this.insertMatch(e,this.completions.filtered[t],n)},e.prototype.insertMatch=function(e,t,n){if(!t)return!1;if(e.startOperation({command:{name:"insertMatch"}}),t.completer&&t.completer.insertMatch)t.completer.insertMatch(e,t);else{if(!this.completions)return!1;var i=this.completions.filterText.length,r=0;if(t.range&&t.range.start.row===t.range.end.row&&(i-=this.initialPosition.prefix.length,i+=this.initialPosition.pos.column-t.range.start.column,r+=t.range.end.column-this.initialPosition.pos.column),i||r){var o;o=e.selection.getAllRanges?e.selection.getAllRanges():[e.getSelectionRange()];for(var a,s=0;a=o[s];s++)a.start.column-=i,a.end.column+=r,e.session.remove(a)}t.snippet?d.insertSnippet(e,t.snippet):this.$insertString(e,t),t.completer&&t.completer.onInsert&&"function"==typeof t.completer.onInsert&&t.completer.onInsert(e,t),t.command&&"startAutocomplete"===t.command&&e.execCommand(t.command)}return e.endOperation(),!0},e.prototype.$insertString=function(e,t){var n=t.value||t;e.execCommand("insertstring",n)},e.prototype.gatherCompletions=function(e,t){var n=e.getSession(),i=e.getCursorPosition(),r=s.getCompletionPrefix(e),o=[];this.completers=e.completers;var a=e.completers.length;return e.completers.forEach((function(l,c){l.getCompletions(e,n,i,r,(function(n,i){l.hideInlinePreview&&(i=i.map((function(e){return Object.assign(e,{hideInlinePreview:l.hideInlinePreview})}))),!n&&i&&(o=o.concat(i)),t(null,{prefix:s.getCompletionPrefix(e),matches:o,finished:0==--a})}))})),!0},e.prototype.provideCompletions=function(e,t,n){var i=function(e){var i=e.prefix,r=e.matches;this.completions=new y(r),t.exactMatch&&(this.completions.exactMatch=!0),t.ignoreCaption&&(this.completions.ignoreCaption=!0),this.completions.setFilter(i),(e.finished||this.completions.filtered.length)&&n(null,this.completions,e.finished)}.bind(this),r=!0,o=null;if(this.gatherCompletions(e,function(e,t){this.active&&(e&&(n(e,[],!0),this.detach()),0===t.prefix.indexOf(t.prefix)&&(r?o=t:i(t)))}.bind(this)),r=!1,o){var a=o;o=null,i(a)}},e.prototype.detach=function(){this.active=!1,this.completers&&this.completers.forEach((function(e){"function"==typeof e.cancel&&e.cancel()}))},e}(),y=function(){function e(e,t){this.all=e,this.filtered=e,this.filterText=t||"",this.exactMatch=!1,this.ignoreCaption=!1}return e.prototype.setFilter=function(e){if(e.length>this.filterText&&0===e.lastIndexOf(this.filterText,0))var t=this.filtered;else t=this.all;this.filterText=e,t=(t=this.filterCompletions(t,this.filterText)).sort((function(e,t){return t.exactMatch-e.exactMatch||t.$score-e.$score||(e.caption||e.value).localeCompare(t.caption||t.value)}));var n=null;t=t.filter((function(e){var t=e.snippet||e.caption||e.value;return t!==n&&(n=t,!0)})),this.filtered=t},e.prototype.filterCompletions=function(e,t){var n=[],i=t.toUpperCase(),r=t.toLowerCase();e:for(var o,a=0;o=e[a];a++)if(o.skipFilter)o.$score=o.score,n.push(o);else{var s=!this.ignoreCaption&&o.caption||o.value||o.snippet;if(s){var l,c,d=-1,u=0,h=0;if(this.exactMatch){if(t!==s.substr(0,t.length))continue e}else{var p=s.toLowerCase().indexOf(r);if(p>-1)h=p;else for(var g=0;g<t.length;g++){var f=s.indexOf(r[g],d+1),m=s.indexOf(i[g],d+1);if((l=f>=0&&(m<0||f<m)?f:m)<0)continue e;(c=l-d-1)>0&&(-1===d&&(h+=10),h+=c,u|=1<<g),d=l}}o.matchMask=u,o.exactMatch=h?0:1,o.$score=(o.score||0)-h,n.push(o)}}return n},e}();t.Autocomplete=f,t.CompletionProvider=m,t.FilteredList=y})),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],(function(e,t,n){var i=e("../range").Range,r=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;t.getCompletions=function(e,t,n,o,a){var s=function(e,t){var n=function(e,t){return e.getTextRange(i.fromPoints({row:0,column:0},t)).split(r).length-1}(e,t),o=e.getValue().split(r),a=Object.create(null),s=o[n];return o.forEach((function(e,t){if(e&&e!==s){var i=Math.abs(n-t),r=o.length-i;a[e]?a[e]=Math.max(r,a[e]):a[e]=r}})),a}(t,n);a(null,Object.keys(s).map((function(e){return{caption:e,value:e,score:s[e],meta:"local"}})))}})),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/autocomplete/text_completer","ace/editor","ace/config"],(function(e,t,n){"use strict";var i=e("../snippets").snippetManager,r=e("../autocomplete").Autocomplete,o=e("../config"),a=e("../lib/lang"),s=e("../autocomplete/util"),l=e("../autocomplete/text_completer"),c={getCompletions:function(e,t,n,i,r){if(t.$mode.completer)return t.$mode.completer.getCompletions(e,t,n,i,r);var o=e.session.getState(n.row),a=t.$mode.getCompletions(o,t,n,i);r(null,a=a.map((function(e){return e.completerId=c.id,e})))},id:"keywordCompleter"},d={getCompletions:function(e,t,n,r,o){var a=[],s=t.getTokenAt(n.row,n.column);s&&s.type.match(/(tag-name|tag-open|tag-whitespace|attribute-name|attribute-value)\.xml$/)?a.push("html-tag"):a=i.getActiveScopes(e);var l=i.snippetMap,c=[];a.forEach((function(e){for(var t=l[e]||[],n=t.length;n--;){var i=t[n],r=i.name||i.tabTrigger;r&&c.push({caption:r,snippet:i.content,meta:i.tabTrigger&&!i.name?i.tabTrigger+"⇥ ":"snippet",completerId:d.id})}}),this),o(null,c)},getDocTooltip:function(e){var t,n;e.snippet&&!e.docHTML&&(e.docHTML=["<b>",a.escapeHTML(e.caption),"</b>","<hr></hr>",a.escapeHTML((t=e.snippet,n={},t.replace(/\${(\d+)(:(.*?))?}/g,(function(e,t,i,r){return n[t]=r||""})).replace(/\$(\d+?)/g,(function(e,t){return n[t]}))))].join(""))},id:"snippetCompleter"},u=[d,l,c];t.setCompleters=function(e){u.length=0,e&&u.push.apply(u,e)},t.addCompleter=function(e){u.push(e)},t.textCompleter=l,t.keyWordCompleter=c,t.snippetCompleter=d;var h,p={name:"expandSnippet",exec:function(e){return i.expandWithTab(e)},bindKey:"Tab"},g=function(e,t){f(t.session.$mode)},f=function(e){"string"==typeof e&&(e=o.$modes[e]),e&&(i.files||(i.files={}),m(e.$id,e.snippetFileId),e.modes&&e.modes.forEach(f))},m=function(e,t){t&&e&&!i.files[e]&&(i.files[e]={},o.loadModule(t,(function(t){t&&(i.files[e]=t,!t.snippets&&t.snippetText&&(t.snippets=i.parseSnippetFile(t.snippetText)),i.register(t.snippets||[],t.scope),t.includeScopes&&(i.snippetMap[t.scope].includeScopes=t.includeScopes,t.includeScopes.forEach((function(e){f("ace/mode/"+e)}))))})))},y=function(e){var t=e.editor,n=t.completer&&t.completer.activated;if("backspace"===e.command.name)n&&!s.getCompletionPrefix(t)&&t.completer.detach();else if("insertstring"===e.command.name&&!n){h=e;var i=e.editor.$liveAutocompletionDelay;i?v.delay(i):b(e)}},v=a.delayedCall((function(){b(h)}),0),b=function(e){var t=e.editor,n=s.getCompletionPrefix(t),i=e.args,o=s.triggerAutocomplete(t,i);if(n&&n.length>=t.$liveAutocompletionThreshold||o){var a=r.for(t);a.autoShown=!0,a.showPopup(t)}},w=e("../editor").Editor;e("../config").defineOptions(w.prototype,"editor",{enableBasicAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:u),this.commands.addCommand(r.startCommand)):this.commands.removeCommand(r.startCommand)},value:!1},enableLiveAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:u),this.commands.on("afterExec",y)):this.commands.off("afterExec",y)},value:!1},liveAutocompletionDelay:{initialValue:0},liveAutocompletionThreshold:{initialValue:0},enableSnippets:{set:function(e){e?(this.commands.addCommand(p),this.on("changeMode",g),g(0,this)):(this.commands.removeCommand(p),this.off("changeMode",g))},value:!1}})})),ace.require(["ace/ext/language_tools"],(function(t){e&&(e.exports=t)}))},97:(e,t,n)=>{e=n.nmd(e);var i="__lodash_hash_undefined__",r=9007199254740991,o="[object Arguments]",a="[object Array]",s="[object Boolean]",l="[object Date]",c="[object Error]",d="[object Function]",u="[object Map]",h="[object Number]",p="[object Object]",g="[object Promise]",f="[object RegExp]",m="[object Set]",y="[object String]",v="[object WeakMap]",b="[object ArrayBuffer]",w="[object DataView]",C=/^\[object .+?Constructor\]$/,x=/^(?:0|[1-9]\d*)$/,S={};S["[object Float32Array]"]=S["[object Float64Array]"]=S["[object Int8Array]"]=S["[object Int16Array]"]=S["[object Int32Array]"]=S["[object Uint8Array]"]=S["[object Uint8ClampedArray]"]=S["[object Uint16Array]"]=S["[object Uint32Array]"]=!0,S[o]=S[a]=S[b]=S[s]=S[w]=S[l]=S[c]=S[d]=S[u]=S[h]=S[p]=S[f]=S[m]=S[y]=S[v]=!1;var _="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,E="object"==typeof self&&self&&self.Object===Object&&self,k=_||E||Function("return this")(),$=t&&!t.nodeType&&t,M=$&&e&&!e.nodeType&&e,T=M&&M.exports===$,A=T&&_.process,L=function(){try{return A&&A.binding&&A.binding("util")}catch(e){}}(),R=L&&L.isTypedArray;function O(e,t){for(var n=-1,i=null==e?0:e.length;++n<i;)if(t(e[n],n,e))return!0;return!1}function I(e){var t=-1,n=Array(e.size);return e.forEach((function(e,i){n[++t]=[i,e]})),n}function P(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}var N,D,z,F=Array.prototype,B=Function.prototype,H=Object.prototype,W=k["__core-js_shared__"],j=B.toString,G=H.hasOwnProperty,V=(N=/[^.]+$/.exec(W&&W.keys&&W.keys.IE_PROTO||""))?"Symbol(src)_1."+N:"",U=H.toString,K=RegExp("^"+j.call(G).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Y=T?k.Buffer:void 0,q=k.Symbol,Q=k.Uint8Array,X=H.propertyIsEnumerable,Z=F.splice,J=q?q.toStringTag:void 0,ee=Object.getOwnPropertySymbols,te=Y?Y.isBuffer:void 0,ne=(D=Object.keys,z=Object,function(e){return D(z(e))}),ie=Me(k,"DataView"),re=Me(k,"Map"),oe=Me(k,"Promise"),ae=Me(k,"Set"),se=Me(k,"WeakMap"),le=Me(Object,"create"),ce=Re(ie),de=Re(re),ue=Re(oe),he=Re(ae),pe=Re(se),ge=q?q.prototype:void 0,fe=ge?ge.valueOf:void 0;function me(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function ye(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function ve(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function be(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new ve;++t<n;)this.add(e[t])}function we(e){var t=this.__data__=new ye(e);this.size=t.size}function Ce(e,t){for(var n=e.length;n--;)if(Oe(e[n][0],t))return n;return-1}function xe(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":J&&J in Object(e)?function(e){var t=G.call(e,J),n=e[J];try{e[J]=void 0;var i=!0}catch(e){}var r=U.call(e);return i&&(t?e[J]=n:delete e[J]),r}(e):function(e){return U.call(e)}(e)}function Se(e){return Be(e)&&xe(e)==o}function _e(e,t,n,i,r){return e===t||(null==e||null==t||!Be(e)&&!Be(t)?e!=e&&t!=t:function(e,t,n,i,r,d){var g=Pe(e),v=Pe(t),C=g?a:Ae(e),x=v?a:Ae(t),S=(C=C==o?p:C)==p,_=(x=x==o?p:x)==p,E=C==x;if(E&&Ne(e)){if(!Ne(t))return!1;g=!0,S=!1}if(E&&!S)return d||(d=new we),g||He(e)?Ee(e,t,n,i,r,d):function(e,t,n,i,r,o,a){switch(n){case w:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case b:return!(e.byteLength!=t.byteLength||!o(new Q(e),new Q(t)));case s:case l:case h:return Oe(+e,+t);case c:return e.name==t.name&&e.message==t.message;case f:case y:return e==t+"";case u:var d=I;case m:var p=1&i;if(d||(d=P),e.size!=t.size&&!p)return!1;var g=a.get(e);if(g)return g==t;i|=2,a.set(e,t);var v=Ee(d(e),d(t),i,r,o,a);return a.delete(e),v;case"[object Symbol]":if(fe)return fe.call(e)==fe.call(t)}return!1}(e,t,C,n,i,r,d);if(!(1&n)){var k=S&&G.call(e,"__wrapped__"),$=_&&G.call(t,"__wrapped__");if(k||$){var M=k?e.value():e,T=$?t.value():t;return d||(d=new we),r(M,T,n,i,d)}}return!!E&&(d||(d=new we),function(e,t,n,i,r,o){var a=1&n,s=ke(e),l=s.length;if(l!=ke(t).length&&!a)return!1;for(var c=l;c--;){var d=s[c];if(!(a?d in t:G.call(t,d)))return!1}var u=o.get(e);if(u&&o.get(t))return u==t;var h=!0;o.set(e,t),o.set(t,e);for(var p=a;++c<l;){var g=e[d=s[c]],f=t[d];if(i)var m=a?i(f,g,d,t,e,o):i(g,f,d,e,t,o);if(!(void 0===m?g===f||r(g,f,n,i,o):m)){h=!1;break}p||(p="constructor"==d)}if(h&&!p){var y=e.constructor,v=t.constructor;y==v||!("constructor"in e)||!("constructor"in t)||"function"==typeof y&&y instanceof y&&"function"==typeof v&&v instanceof v||(h=!1)}return o.delete(e),o.delete(t),h}(e,t,n,i,r,d))}(e,t,n,i,_e,r))}function Ee(e,t,n,i,r,o){var a=1&n,s=e.length,l=t.length;if(s!=l&&!(a&&l>s))return!1;var c=o.get(e);if(c&&o.get(t))return c==t;var d=-1,u=!0,h=2&n?new be:void 0;for(o.set(e,t),o.set(t,e);++d<s;){var p=e[d],g=t[d];if(i)var f=a?i(g,p,d,t,e,o):i(p,g,d,e,t,o);if(void 0!==f){if(f)continue;u=!1;break}if(h){if(!O(t,(function(e,t){if(a=t,!h.has(a)&&(p===e||r(p,e,n,i,o)))return h.push(t);var a}))){u=!1;break}}else if(p!==g&&!r(p,g,n,i,o)){u=!1;break}}return o.delete(e),o.delete(t),u}function ke(e){return function(e,t,n){var i=t(e);return Pe(e)?i:function(e,t){for(var n=-1,i=t.length,r=e.length;++n<i;)e[r+n]=t[n];return e}(i,n(e))}(e,We,Te)}function $e(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function Me(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return function(e){return!(!Fe(e)||function(e){return!!V&&V in e}(e))&&(De(e)?K:C).test(Re(e))}(n)?n:void 0}me.prototype.clear=function(){this.__data__=le?le(null):{},this.size=0},me.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},me.prototype.get=function(e){var t=this.__data__;if(le){var n=t[e];return n===i?void 0:n}return G.call(t,e)?t[e]:void 0},me.prototype.has=function(e){var t=this.__data__;return le?void 0!==t[e]:G.call(t,e)},me.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=le&&void 0===t?i:t,this},ye.prototype.clear=function(){this.__data__=[],this.size=0},ye.prototype.delete=function(e){var t=this.__data__,n=Ce(t,e);return!(n<0||(n==t.length-1?t.pop():Z.call(t,n,1),--this.size,0))},ye.prototype.get=function(e){var t=this.__data__,n=Ce(t,e);return n<0?void 0:t[n][1]},ye.prototype.has=function(e){return Ce(this.__data__,e)>-1},ye.prototype.set=function(e,t){var n=this.__data__,i=Ce(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this},ve.prototype.clear=function(){this.size=0,this.__data__={hash:new me,map:new(re||ye),string:new me}},ve.prototype.delete=function(e){var t=$e(this,e).delete(e);return this.size-=t?1:0,t},ve.prototype.get=function(e){return $e(this,e).get(e)},ve.prototype.has=function(e){return $e(this,e).has(e)},ve.prototype.set=function(e,t){var n=$e(this,e),i=n.size;return n.set(e,t),this.size+=n.size==i?0:1,this},be.prototype.add=be.prototype.push=function(e){return this.__data__.set(e,i),this},be.prototype.has=function(e){return this.__data__.has(e)},we.prototype.clear=function(){this.__data__=new ye,this.size=0},we.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},we.prototype.get=function(e){return this.__data__.get(e)},we.prototype.has=function(e){return this.__data__.has(e)},we.prototype.set=function(e,t){var n=this.__data__;if(n instanceof ye){var i=n.__data__;if(!re||i.length<199)return i.push([e,t]),this.size=++n.size,this;n=this.__data__=new ve(i)}return n.set(e,t),this.size=n.size,this};var Te=ee?function(e){return null==e?[]:(e=Object(e),function(t){for(var n=-1,i=null==t?0:t.length,r=0,o=[];++n<i;){var a=t[n];s=a,X.call(e,s)&&(o[r++]=a)}var s;return o}(ee(e)))}:function(){return[]},Ae=xe;function Le(e,t){return!!(t=null==t?r:t)&&("number"==typeof e||x.test(e))&&e>-1&&e%1==0&&e<t}function Re(e){if(null!=e){try{return j.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Oe(e,t){return e===t||e!=e&&t!=t}(ie&&Ae(new ie(new ArrayBuffer(1)))!=w||re&&Ae(new re)!=u||oe&&Ae(oe.resolve())!=g||ae&&Ae(new ae)!=m||se&&Ae(new se)!=v)&&(Ae=function(e){var t=xe(e),n=t==p?e.constructor:void 0,i=n?Re(n):"";if(i)switch(i){case ce:return w;case de:return u;case ue:return g;case he:return m;case pe:return v}return t});var Ie=Se(function(){return arguments}())?Se:function(e){return Be(e)&&G.call(e,"callee")&&!X.call(e,"callee")},Pe=Array.isArray,Ne=te||function(){return!1};function De(e){if(!Fe(e))return!1;var t=xe(e);return t==d||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}function ze(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}function Fe(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Be(e){return null!=e&&"object"==typeof e}var He=R?function(e){return function(t){return e(t)}}(R):function(e){return Be(e)&&ze(e.length)&&!!S[xe(e)]};function We(e){return function(e){return null!=e&&ze(e.length)&&!De(e)}(e)?function(e,t){var n=Pe(e),i=!n&&Ie(e),r=!n&&!i&&Ne(e),o=!n&&!i&&!r&&He(e),a=n||i||r||o,s=a?function(e,t){for(var n=-1,i=Array(e);++n<e;)i[n]=t(n);return i}(e.length,String):[],l=s.length;for(var c in e)!t&&!G.call(e,c)||a&&("length"==c||r&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||Le(c,l))||s.push(c);return s}(e):function(e){if(!function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||H)}(e))return ne(e);var t=[];for(var n in Object(e))G.call(e,n)&&"constructor"!=n&&t.push(n);return t}(e)}e.exports=function(e,t){return _e(e,t)}},135:(e,t,n)=>{e.exports=n(176)()},144:(e,t,n)=>{e=n.nmd(e),ace.define("ace/theme/monokai-css",["require","exports","module"],(function(e,t,n){n.exports=".ace-monokai .ace_gutter {\n background: #2F3129;\n color: #8F908A\n}\n\n.ace-monokai .ace_print-margin {\n width: 1px;\n background: #555651\n}\n\n.ace-monokai {\n background-color: #272822;\n color: #F8F8F2\n}\n\n.ace-monokai .ace_cursor {\n color: #F8F8F0\n}\n\n.ace-monokai .ace_marker-layer .ace_selection {\n background: #49483E\n}\n\n.ace-monokai.ace_multiselect .ace_selection.ace_start {\n box-shadow: 0 0 3px 0px #272822;\n}\n\n.ace-monokai .ace_marker-layer .ace_step {\n background: rgb(102, 82, 0)\n}\n\n.ace-monokai .ace_marker-layer .ace_bracket {\n margin: -1px 0 0 -1px;\n border: 1px solid #49483E\n}\n\n.ace-monokai .ace_marker-layer .ace_active-line {\n background: #202020\n}\n\n.ace-monokai .ace_gutter-active-line {\n background-color: #272727\n}\n\n.ace-monokai .ace_marker-layer .ace_selected-word {\n border: 1px solid #49483E\n}\n\n.ace-monokai .ace_invisible {\n color: #52524d\n}\n\n.ace-monokai .ace_entity.ace_name.ace_tag,\n.ace-monokai .ace_keyword,\n.ace-monokai .ace_meta.ace_tag,\n.ace-monokai .ace_storage {\n color: #F92672\n}\n\n.ace-monokai .ace_punctuation,\n.ace-monokai .ace_punctuation.ace_tag {\n color: #fff\n}\n\n.ace-monokai .ace_constant.ace_character,\n.ace-monokai .ace_constant.ace_language,\n.ace-monokai .ace_constant.ace_numeric,\n.ace-monokai .ace_constant.ace_other {\n color: #AE81FF\n}\n\n.ace-monokai .ace_invalid {\n color: #F8F8F0;\n background-color: #F92672\n}\n\n.ace-monokai .ace_invalid.ace_deprecated {\n color: #F8F8F0;\n background-color: #AE81FF\n}\n\n.ace-monokai .ace_support.ace_constant,\n.ace-monokai .ace_support.ace_function {\n color: #66D9EF\n}\n\n.ace-monokai .ace_fold {\n background-color: #A6E22E;\n border-color: #F8F8F2\n}\n\n.ace-monokai .ace_storage.ace_type,\n.ace-monokai .ace_support.ace_class,\n.ace-monokai .ace_support.ace_type {\n font-style: italic;\n color: #66D9EF\n}\n\n.ace-monokai .ace_entity.ace_name.ace_function,\n.ace-monokai .ace_entity.ace_other,\n.ace-monokai .ace_entity.ace_other.ace_attribute-name,\n.ace-monokai .ace_variable {\n color: #A6E22E\n}\n\n.ace-monokai .ace_variable.ace_parameter {\n font-style: italic;\n color: #FD971F\n}\n\n.ace-monokai .ace_string {\n color: #E6DB74\n}\n\n.ace-monokai .ace_comment {\n color: #75715E\n}\n\n.ace-monokai .ace_indent-guide {\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWPQ0FD0ZXBzd/wPAAjVAoxeSgNeAAAAAElFTkSuQmCC) right repeat-y\n}\n\n.ace-monokai .ace_indent-guide-active {\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQIW2PQ1dX9zzBz5sz/ABCcBFFentLlAAAAAElFTkSuQmCC) right repeat-y;\n}\n"})),ace.define("ace/theme/monokai",["require","exports","module","ace/theme/monokai-css","ace/lib/dom"],(function(e,t,n){t.isDark=!0,t.cssClass="ace-monokai",t.cssText=e("./monokai-css"),e("../lib/dom").importCssString(t.cssText,t.cssClass,!1)})),ace.require(["ace/theme/monokai"],(function(t){e&&(e.exports=t)}))},176:(e,t,n)=>{"use strict";var i=n(212);function r(){}function o(){}o.resetWarningCache=r,e.exports=function(){function e(e,t,n,r,o,a){if(a!==i){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:r};return n.PropTypes=n,n}},194:e=>{"use strict";e.exports=function(e,t,n,i,r,o,a,s){if(!e){var l;if(void 0===t)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,i,r,o,a,s],d=0;(l=new Error(t.replace(/%s/g,(function(){return c[d++]})))).name="Invariant Violation"}throw l.framesToPop=1,l}}},212:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},327:(e,t,n)=>{"use strict";var i,r=(i=n(364))&&i.__esModule?i:{default:i};function o(e){return function(e){if(Array.isArray(e))return a(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,i)}return n}function l(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?s(Object(n),!0).forEach((function(t){c(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function d(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}var u={select:"select-pure__select",dropdownShown:"select-pure__select--opened",multiselect:"select-pure__select--multiple",label:"select-pure__label",placeholder:"select-pure__placeholder",dropdown:"select-pure__options",option:"select-pure__option",optionDisabled:"select-pure__option--disabled",autocompleteInput:"select-pure__autocomplete",selectedLabel:"select-pure__selected-label",selectedOption:"select-pure__option--selected",placeholderHidden:"select-pure__placeholder--hidden",optionHidden:"select-pure__option--hidden"},h=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._config=l(l({},n),{},{classNames:l(l({},u),n.classNames),disabledOptions:[]}),this._state={opened:!1},this._icons=[],this._boundHandleClick=this._handleClick.bind(this),this._boundUnselectOption=this._unselectOption.bind(this),this._boundSortOptions=this._sortOptions.bind(this),this._body=new r.default(document.body),this._create(t),this._config.value&&this._setValue()}var t,n;return t=e,(n=[{key:"value",value:function(){return this._config.value}},{key:"reset",value:function(){this._config.value=this._config.multiple?[]:null,this._setValue()}},{key:"_create",value:function(e){var t="string"==typeof e?document.querySelector(e):e;this._parent=new r.default(t),this._select=new r.default("div",{class:this._config.classNames.select}),this._label=new r.default("span",{class:this._config.classNames.label}),this._optionsWrapper=new r.default("div",{class:this._config.classNames.dropdown}),this._config.multiple&&this._select.addClass(this._config.classNames.multiselect),this._options=this._generateOptions(),this._select.addEventListener("click",this._boundHandleClick),this._select.append(this._label.get()),this._select.append(this._optionsWrapper.get()),this._parent.append(this._select.get()),this._placeholder=new r.default("span",{class:this._config.classNames.placeholder,textContent:this._config.placeholder}),this._select.append(this._placeholder.get())}},{key:"_generateOptions",value:function(){var e=this;return this._config.autocomplete&&(this._autocomplete=new r.default("input",{class:this._config.classNames.autocompleteInput,type:"text"}),this._autocomplete.addEventListener("input",this._boundSortOptions),this._optionsWrapper.append(this._autocomplete.get())),this._config.options.map((function(t){var n=new r.default("div",{class:"".concat(e._config.classNames.option).concat(t.disabled?" "+e._config.classNames.optionDisabled:""),value:t.value,textContent:t.label,disabled:t.disabled});return t.disabled&&e._config.disabledOptions.push(String(t.value)),e._optionsWrapper.append(n.get()),n}))}},{key:"_handleClick",value:function(e){if(e.stopPropagation(),e.target.className!==this._config.classNames.autocompleteInput){if(this._state.opened){var t=this._options.find((function(t){return t.get()===e.target}));return t&&this._setValue(t.get().getAttribute("data-value"),!0),this._select.removeClass(this._config.classNames.dropdownShown),this._body.removeEventListener("click",this._boundHandleClick),this._select.addEventListener("click",this._boundHandleClick),void(this._state.opened=!1)}e.target.className!==this._config.icon&&(this._select.addClass(this._config.classNames.dropdownShown),this._body.addEventListener("click",this._boundHandleClick),this._select.removeEventListener("click",this._boundHandleClick),this._state.opened=!0,this._autocomplete&&this._autocomplete.focus())}}},{key:"_setValue",value:function(e,t,n){var i=this;if(!(this._config.disabledOptions.indexOf(e)>-1)){if(e&&!n&&(this._config.value=this._config.multiple?[].concat(o(this._config.value||[]),[e]):e),e&&n&&(this._config.value=e),this._options.forEach((function(e){e.removeClass(i._config.classNames.selectedOption)})),this._placeholder.removeClass(this._config.classNames.placeholderHidden),this._config.multiple){var r=this._config.value.map((function(e){var t=i._config.options.find((function(t){return t.value===e}));return i._options.find((function(e){return e.get().getAttribute("data-value")===t.value.toString()})).addClass(i._config.classNames.selectedOption),t}));return r.length&&this._placeholder.addClass(this._config.classNames.placeholderHidden),void this._selectOptions(r,t)}var a=this._config.value?this._config.options.find((function(e){return e.value.toString()===i._config.value})):this._config.options[0],s=this._options.find((function(e){return e.get().getAttribute("data-value")===a.value.toString()}));this._config.value?(s.addClass(this._config.classNames.selectedOption),this._placeholder.addClass(this._config.classNames.placeholderHidden),this._selectOption(a,t)):this._label.setText("")}}},{key:"_selectOption",value:function(e,t){this._selectedOption=e,this._label.setText(e.label),this._config.onChange&&t&&this._config.onChange(e.value)}},{key:"_selectOptions",value:function(e,t){var n=this;this._label.setText(""),this._icons=e.map((function(e){var t=new r.default("span",{class:n._config.classNames.selectedLabel,textContent:e.label}),i=new r.default(n._config.inlineIcon?n._config.inlineIcon.cloneNode(!0):"i",{class:n._config.icon,value:e.value});return i.addEventListener("click",n._boundUnselectOption),t.append(i.get()),n._label.append(t.get()),i.get()})),t&&this._optionsWrapper.setTop(Number(this._select.getHeight().split("px")[0])+5),this._config.onChange&&t&&this._config.onChange(this._config.value)}},{key:"_unselectOption",value:function(e){var t=o(this._config.value),n=t.indexOf(e.target.getAttribute("data-value"));-1!==n&&t.splice(n,1),this._setValue(t,!0,!0)}},{key:"_sortOptions",value:function(e){var t=this;this._options.forEach((function(n){n.get().textContent.toLowerCase().startsWith(e.target.value.toLowerCase())?n.removeClass(t._config.classNames.optionHidden):n.addClass(t._config.classNames.optionHidden)}))}}])&&d(t.prototype,n),e}();t.A=h},336:(e,t,n)=>{e=n.nmd(e),ace.define("ace/split",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/editor","ace/virtual_renderer","ace/edit_session"],(function(e,t,n){"use strict";var i,r=e("./lib/oop"),o=(e("./lib/lang"),e("./lib/event_emitter").EventEmitter),a=e("./editor").Editor,s=e("./virtual_renderer").VirtualRenderer,l=e("./edit_session").EditSession;(function(){r.implement(this,o),this.$createEditor=function(){var e=document.createElement("div");e.className=this.$editorCSS,e.style.cssText="position: absolute; top:0px; bottom:0px",this.$container.appendChild(e);var t=new a(new s(e,this.$theme));return t.on("focus",function(){this._emit("focus",t)}.bind(this)),this.$editors.push(t),t.setFontSize(this.$fontSize),t},this.setSplits=function(e){var t;if(e<1)throw"The number of splits have to be > 0!";if(e!=this.$splits){if(e>this.$splits){for(;this.$splits<this.$editors.length&&this.$splits<e;)t=this.$editors[this.$splits],this.$container.appendChild(t.container),t.setFontSize(this.$fontSize),this.$splits++;for(;this.$splits<e;)this.$createEditor(),this.$splits++}else for(;this.$splits>e;)t=this.$editors[this.$splits-1],this.$container.removeChild(t.container),this.$splits--;this.resize()}},this.getSplits=function(){return this.$splits},this.getEditor=function(e){return this.$editors[e]},this.getCurrentEditor=function(){return this.$cEditor},this.focus=function(){this.$cEditor.focus()},this.blur=function(){this.$cEditor.blur()},this.setTheme=function(e){this.$editors.forEach((function(t){t.setTheme(e)}))},this.setKeyboardHandler=function(e){this.$editors.forEach((function(t){t.setKeyboardHandler(e)}))},this.forEach=function(e,t){this.$editors.forEach(e,t)},this.$fontSize="",this.setFontSize=function(e){this.$fontSize=e,this.forEach((function(t){t.setFontSize(e)}))},this.$cloneSession=function(e){var t=new l(e.getDocument(),e.getMode()),n=e.getUndoManager();return t.setUndoManager(n),t.setTabSize(e.getTabSize()),t.setUseSoftTabs(e.getUseSoftTabs()),t.setOverwrite(e.getOverwrite()),t.setBreakpoints(e.getBreakpoints()),t.setUseWrapMode(e.getUseWrapMode()),t.setUseWorker(e.getUseWorker()),t.setWrapLimitRange(e.$wrapLimitRange.min,e.$wrapLimitRange.max),t.$foldData=e.$cloneFoldData(),t},this.setSession=function(e,t){var n;n=null==t?this.$cEditor:this.$editors[t];var i=this.$editors.some((function(t){return t.session===e}));return i&&(e=this.$cloneSession(e)),n.setSession(e),e},this.getOrientation=function(){return this.$orientation},this.setOrientation=function(e){this.$orientation!=e&&(this.$orientation=e,this.resize())},this.resize=function(){var e,t=this.$container.clientWidth,n=this.$container.clientHeight;if(this.$orientation==this.BESIDE)for(var i=t/this.$splits,r=0;r<this.$splits;r++)(e=this.$editors[r]).container.style.width=i+"px",e.container.style.top="0px",e.container.style.left=r*i+"px",e.container.style.height=n+"px",e.resize();else{var o=n/this.$splits;for(r=0;r<this.$splits;r++)(e=this.$editors[r]).container.style.width=t+"px",e.container.style.top=r*o+"px",e.container.style.left="0px",e.container.style.height=o+"px",e.resize()}}}).call((i=function(e,t,n){this.BELOW=1,this.BESIDE=0,this.$container=e,this.$theme=t,this.$splits=0,this.$editorCSS="",this.$editors=[],this.$orientation=this.BESIDE,this.setSplits(n||1),this.$cEditor=this.$editors[0],this.on("focus",function(e){this.$cEditor=e}.bind(this))}).prototype),t.Split=i})),ace.define("ace/ext/split",["require","exports","module","ace/split"],(function(e,t,n){"use strict";n.exports=e("../split")})),ace.require(["ace/ext/split"],(function(t){e&&(e.exports=t)}))},364:(e,t)=>{"use strict";function n(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}Object.defineProperty(t,"__esModule",{value:!0});var i={value:"data-value",disabled:"data-disabled",class:"class",type:"type"},r=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._node=t instanceof HTMLElement?t:document.createElement(t),this._config={i18n:i},this._setAttributes(n),n.textContent&&this._setTextContent(n.textContent),this}var t,r;return t=e,(r=[{key:"get",value:function(){return this._node}},{key:"append",value:function(e){return this._node.appendChild(e),this}},{key:"addClass",value:function(e){return this._node.classList.add(e),this}},{key:"removeClass",value:function(e){return this._node.classList.remove(e),this}},{key:"toggleClass",value:function(e){return this._node.classList.toggle(e),this}},{key:"addEventListener",value:function(e,t){return this._node.addEventListener(e,t),this}},{key:"removeEventListener",value:function(e,t){return this._node.removeEventListener(e,t),this}},{key:"setText",value:function(e){return this._setTextContent(e),this}},{key:"getHeight",value:function(){return window.getComputedStyle(this._node).height}},{key:"setTop",value:function(e){return this._node.style.top="".concat(e,"px"),this}},{key:"focus",value:function(){return this._node.focus(),this}},{key:"_setTextContent",value:function(e){this._node.textContent=e}},{key:"_setAttributes",value:function(e){for(var t in e)i[t]&&e[t]&&this._setAttribute(i[t],e[t])}},{key:"_setAttribute",value:function(e,t){this._node.setAttribute(e,t)}}])&&n(t.prototype,r),e}();t.default=r},378:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAceInstance=t.debounce=t.editorEvents=t.editorOptions=void 0,t.editorOptions=["minLines","maxLines","readOnly","highlightActiveLine","tabSize","enableBasicAutocompletion","enableLiveAutocompletion","enableSnippets"],t.editorEvents=["onChange","onFocus","onInput","onBlur","onCopy","onPaste","onSelectionChange","onCursorChange","onScroll","handleOptions","updateRef"],t.getAceInstance=function(){var e;return"undefined"==typeof window?(n.g.window={},e=n(973),delete n.g.window):window.ace?(e=window.ace).acequire=window.ace.require||window.ace.acequire:e=n(973),e},t.debounce=function(e,t){var n=null;return function(){var i=this,r=arguments;clearTimeout(n),n=setTimeout((function(){e.apply(i,r)}),t)}}},468:function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return o=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},o.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(973),s=n(135),l=n(609),c=n(97),d=n(378),u=(0,d.getAceInstance)(),h=function(e){function t(t){var n=e.call(this,t)||this;return d.editorEvents.forEach((function(e){n[e]=n[e].bind(n)})),n.debounce=d.debounce,n}return r(t,e),t.prototype.isInShadow=function(e){for(var t=e&&e.parentNode;t;){if("[object ShadowRoot]"===t.toString())return!0;t=t.parentNode}return!1},t.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.className,i=t.onBeforeLoad,r=t.onValidate,o=t.mode,a=t.focus,s=t.theme,l=t.fontSize,c=t.lineHeight,h=t.value,p=t.defaultValue,g=t.showGutter,f=t.wrapEnabled,m=t.showPrintMargin,y=t.scrollMargin,v=void 0===y?[0,0,0,0]:y,b=t.keyboardHandler,w=t.onLoad,C=t.commands,x=t.annotations,S=t.markers,_=t.placeholder;this.editor=u.edit(this.refEditor),i&&i(u);for(var E=Object.keys(this.props.editorProps),k=0;k<E.length;k++)this.editor[E[k]]=this.props.editorProps[E[k]];this.props.debounceChangePeriod&&(this.onChange=this.debounce(this.onChange,this.props.debounceChangePeriod)),this.editor.renderer.setScrollMargin(v[0],v[1],v[2],v[3]),this.isInShadow(this.refEditor)&&this.editor.renderer.attachToShadowRoot(),this.editor.getSession().setMode("string"==typeof o?"ace/mode/".concat(o):o),s&&""!==s&&this.editor.setTheme("ace/theme/".concat(s)),this.editor.setFontSize("number"==typeof l?"".concat(l,"px"):l),c&&(this.editor.container.style.lineHeight="number"==typeof c?"".concat(c,"px"):"".concat(c),this.editor.renderer.updateFontSize()),this.editor.getSession().setValue(p||h||""),this.props.navigateToFileEnd&&this.editor.navigateFileEnd(),this.editor.renderer.setShowGutter(g),this.editor.getSession().setUseWrapMode(f),this.editor.setShowPrintMargin(m),this.editor.on("focus",this.onFocus),this.editor.on("blur",this.onBlur),this.editor.on("copy",this.onCopy),this.editor.on("paste",this.onPaste),this.editor.on("change",this.onChange),this.editor.on("input",this.onInput),_&&this.updatePlaceholder(),this.editor.getSession().selection.on("changeSelection",this.onSelectionChange),this.editor.getSession().selection.on("changeCursor",this.onCursorChange),r&&this.editor.getSession().on("changeAnnotation",(function(){var t=e.editor.getSession().getAnnotations();e.props.onValidate(t)})),this.editor.session.on("changeScrollTop",this.onScroll),this.editor.getSession().setAnnotations(x||[]),S&&S.length>0&&this.handleMarkers(S);var $=this.editor.$options;d.editorOptions.forEach((function(t){$.hasOwnProperty(t)?e.editor.setOption(t,e.props[t]):e.props[t]&&console.warn("ReactAce: editor option ".concat(t," was activated but not found. Did you need to import a related tool or did you possibly mispell the option?"))})),this.handleOptions(this.props),Array.isArray(C)&&C.forEach((function(t){"string"==typeof t.exec?e.editor.commands.bindKey(t.bindKey,t.exec):e.editor.commands.addCommand(t)})),b&&this.editor.setKeyboardHandler("ace/keyboard/"+b),n&&(this.refEditor.className+=" "+n),w&&w(this.editor),this.editor.resize(),a&&this.editor.focus()},t.prototype.componentDidUpdate=function(e){for(var t=e,n=this.props,i=0;i<d.editorOptions.length;i++){var r=d.editorOptions[i];n[r]!==t[r]&&this.editor.setOption(r,n[r])}if(n.className!==t.className){var o=this.refEditor.className.trim().split(" ");t.className.trim().split(" ").forEach((function(e){var t=o.indexOf(e);o.splice(t,1)})),this.refEditor.className=" "+n.className+" "+o.join(" ")}var a=this.editor&&null!=n.value&&this.editor.getValue()!==n.value;if(a){this.silent=!0;var s=this.editor.session.selection.toJSON();this.editor.setValue(n.value,n.cursorStart),this.editor.session.selection.fromJSON(s),this.silent=!1}n.placeholder!==t.placeholder&&this.updatePlaceholder(),n.mode!==t.mode&&this.editor.getSession().setMode("string"==typeof n.mode?"ace/mode/".concat(n.mode):n.mode),n.theme!==t.theme&&this.editor.setTheme("ace/theme/"+n.theme),n.keyboardHandler!==t.keyboardHandler&&(n.keyboardHandler?this.editor.setKeyboardHandler("ace/keyboard/"+n.keyboardHandler):this.editor.setKeyboardHandler(null)),n.fontSize!==t.fontSize&&this.editor.setFontSize("number"==typeof n.fontSize?"".concat(n.fontSize,"px"):n.fontSize),n.lineHeight!==t.lineHeight&&(this.editor.container.style.lineHeight="number"==typeof n.lineHeight?"".concat(n.lineHeight,"px"):n.lineHeight,this.editor.renderer.updateFontSize()),n.wrapEnabled!==t.wrapEnabled&&this.editor.getSession().setUseWrapMode(n.wrapEnabled),n.showPrintMargin!==t.showPrintMargin&&this.editor.setShowPrintMargin(n.showPrintMargin),n.showGutter!==t.showGutter&&this.editor.renderer.setShowGutter(n.showGutter),c(n.setOptions,t.setOptions)||this.handleOptions(n),!a&&c(n.annotations,t.annotations)||this.editor.getSession().setAnnotations(n.annotations||[]),!c(n.markers,t.markers)&&Array.isArray(n.markers)&&this.handleMarkers(n.markers),c(n.scrollMargin,t.scrollMargin)||this.handleScrollMargins(n.scrollMargin),e.height===this.props.height&&e.width===this.props.width||this.editor.resize(),this.props.focus&&!e.focus&&this.editor.focus()},t.prototype.handleScrollMargins=function(e){void 0===e&&(e=[0,0,0,0]),this.editor.renderer.setScrollMargin(e[0],e[1],e[2],e[3])},t.prototype.componentWillUnmount=function(){this.editor&&(this.editor.destroy(),this.editor=null)},t.prototype.onChange=function(e){if(this.editor&&this.props.onChange&&!this.silent){var t=this.editor.getValue();this.props.onChange(t,e)}},t.prototype.onSelectionChange=function(e){if(this.props.onSelectionChange){var t=this.editor.getSelection();this.props.onSelectionChange(t,e)}},t.prototype.onCursorChange=function(e){if(this.props.onCursorChange){var t=this.editor.getSelection();this.props.onCursorChange(t,e)}},t.prototype.onInput=function(e){this.props.onInput&&this.props.onInput(e),this.props.placeholder&&this.updatePlaceholder()},t.prototype.onFocus=function(e){this.props.onFocus&&this.props.onFocus(e,this.editor)},t.prototype.onBlur=function(e){this.props.onBlur&&this.props.onBlur(e,this.editor)},t.prototype.onCopy=function(e){var t=e.text;this.props.onCopy&&this.props.onCopy(t)},t.prototype.onPaste=function(e){var t=e.text;this.props.onPaste&&this.props.onPaste(t)},t.prototype.onScroll=function(){this.props.onScroll&&this.props.onScroll(this.editor)},t.prototype.handleOptions=function(e){for(var t=Object.keys(e.setOptions),n=0;n<t.length;n++)this.editor.setOption(t[n],e.setOptions[t[n]])},t.prototype.handleMarkers=function(e){var t=this,n=this.editor.getSession().getMarkers(!0);for(var i in n)n.hasOwnProperty(i)&&this.editor.getSession().removeMarker(n[i].id);for(var i in n=this.editor.getSession().getMarkers(!1))n.hasOwnProperty(i)&&"ace_active-line"!==n[i].clazz&&"ace_selected-word"!==n[i].clazz&&this.editor.getSession().removeMarker(n[i].id);e.forEach((function(e){var n=e.startRow,i=e.startCol,r=e.endRow,o=e.endCol,s=e.className,l=e.type,c=e.inFront,d=void 0!==c&&c,u=new a.Range(n,i,r,o);t.editor.getSession().addMarker(u,s,l,d)}))},t.prototype.updatePlaceholder=function(){var e=this.editor,t=this.props.placeholder,n=!e.session.getValue().length,i=e.renderer.placeholderNode;!n&&i?(e.renderer.scroller.removeChild(e.renderer.placeholderNode),e.renderer.placeholderNode=null):n&&!i?((i=e.renderer.placeholderNode=document.createElement("div")).textContent=t||"",i.className="ace_comment ace_placeholder",i.style.padding="0 9px",i.style.position="absolute",i.style.zIndex="3",e.renderer.scroller.appendChild(i)):n&&i&&(i.textContent=t)},t.prototype.updateRef=function(e){this.refEditor=e},t.prototype.render=function(){var e=this.props,t=e.name,n=e.width,i=e.height,r=e.style,a=o({width:n,height:i},r);return l.createElement("div",{ref:this.updateRef,id:t,style:a})},t.propTypes={mode:s.oneOfType([s.string,s.object]),focus:s.bool,theme:s.string,name:s.string,className:s.string,height:s.string,width:s.string,fontSize:s.oneOfType([s.number,s.string]),lineHeight:s.oneOfType([s.number,s.string]),showGutter:s.bool,onChange:s.func,onCopy:s.func,onPaste:s.func,onFocus:s.func,onInput:s.func,onBlur:s.func,onScroll:s.func,value:s.string,defaultValue:s.string,onLoad:s.func,onSelectionChange:s.func,onCursorChange:s.func,onBeforeLoad:s.func,onValidate:s.func,minLines:s.number,maxLines:s.number,readOnly:s.bool,highlightActiveLine:s.bool,tabSize:s.number,showPrintMargin:s.bool,cursorStart:s.number,debounceChangePeriod:s.number,editorProps:s.object,setOptions:s.object,style:s.object,scrollMargin:s.array,annotations:s.array,markers:s.array,keyboardHandler:s.string,wrapEnabled:s.bool,enableSnippets:s.bool,enableBasicAutocompletion:s.oneOfType([s.bool,s.array]),enableLiveAutocompletion:s.oneOfType([s.bool,s.array]),navigateToFileEnd:s.bool,commands:s.array,placeholder:s.string},t.defaultProps={name:"ace-editor",focus:!1,mode:"",theme:"",height:"500px",width:"500px",fontSize:12,enableSnippets:!1,showGutter:!0,onChange:null,onPaste:null,onLoad:null,onScroll:null,minLines:null,maxLines:null,readOnly:!1,highlightActiveLine:!0,showPrintMargin:!0,tabSize:4,cursorStart:1,editorProps:{},style:{},scrollMargin:[0,0,0,0],setOptions:{},wrapEnabled:!1,enableBasicAutocompletion:!1,enableLiveAutocompletion:!1,placeholder:null,navigateToFileEnd:!0},t}(l.Component);t.default=h},529:(e,t,n)=>{var i,r="__lodash_hash_undefined__",o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/,s=/^\./,l=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,c=/\\(\\)?/g,d=/^\[object .+?Constructor\]$/,u="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,h="object"==typeof self&&self&&self.Object===Object&&self,p=u||h||Function("return this")(),g=Array.prototype,f=Function.prototype,m=Object.prototype,y=p["__core-js_shared__"],v=(i=/[^.]+$/.exec(y&&y.keys&&y.keys.IE_PROTO||""))?"Symbol(src)_1."+i:"",b=f.toString,w=m.hasOwnProperty,C=m.toString,x=RegExp("^"+b.call(w).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),S=p.Symbol,_=g.splice,E=I(p,"Map"),k=I(Object,"create"),$=S?S.prototype:void 0,M=$?$.toString:void 0;function T(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function A(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function L(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var i=e[t];this.set(i[0],i[1])}}function R(e,t){for(var n=e.length;n--;)if(z(e[n][0],t))return n;return-1}function O(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function I(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return function(e){if(!B(e)||v&&v in e)return!1;var t=function(e){var t=B(e)?C.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?x:d;return t.test(function(e){if(null!=e){try{return b.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))}(n)?n:void 0}T.prototype.clear=function(){this.__data__=k?k(null):{}},T.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},T.prototype.get=function(e){var t=this.__data__;if(k){var n=t[e];return n===r?void 0:n}return w.call(t,e)?t[e]:void 0},T.prototype.has=function(e){var t=this.__data__;return k?void 0!==t[e]:w.call(t,e)},T.prototype.set=function(e,t){return this.__data__[e]=k&&void 0===t?r:t,this},A.prototype.clear=function(){this.__data__=[]},A.prototype.delete=function(e){var t=this.__data__,n=R(t,e);return!(n<0||(n==t.length-1?t.pop():_.call(t,n,1),0))},A.prototype.get=function(e){var t=this.__data__,n=R(t,e);return n<0?void 0:t[n][1]},A.prototype.has=function(e){return R(this.__data__,e)>-1},A.prototype.set=function(e,t){var n=this.__data__,i=R(n,e);return i<0?n.push([e,t]):n[i][1]=t,this},L.prototype.clear=function(){this.__data__={hash:new T,map:new(E||A),string:new T}},L.prototype.delete=function(e){return O(this,e).delete(e)},L.prototype.get=function(e){return O(this,e).get(e)},L.prototype.has=function(e){return O(this,e).has(e)},L.prototype.set=function(e,t){return O(this,e).set(e,t),this};var P=D((function(e){e=function(e){return null==e?"":function(e){if("string"==typeof e)return e;if(H(e))return M?M.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)}(e);var t=[];return s.test(e)&&t.push(""),e.replace(l,(function(e,n,i,r){t.push(i?r.replace(c,"$1"):n||e)})),t}));function N(e){if("string"==typeof e||H(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function D(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var i=arguments,r=t?t.apply(this,i):i[0],o=n.cache;if(o.has(r))return o.get(r);var a=e.apply(this,i);return n.cache=o.set(r,a),a};return n.cache=new(D.Cache||L),n}function z(e,t){return e===t||e!=e&&t!=t}D.Cache=L;var F=Array.isArray;function B(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function H(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==C.call(e)}e.exports=function(e,t,n){var i=null==e?void 0:function(e,t){t=function(e,t){if(F(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!H(e))||a.test(e)||!o.test(e)||null!=t&&e in Object(t)}(t,e)?[t]:function(e){return F(e)?e:P(e)}(t);for(var n=0,i=t.length;null!=e&&n<i;)e=e[N(t[n++])];return n&&n==i?e:void 0}(e,t);return void 0===i?n:i}},579:(e,t,n)=>{"use strict";var i=n(468);n(831).default,n(911).default,i.default},609:e=>{"use strict";e.exports=window.React},831:function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(135),a=n(609),s=n(911),l=n(42),c=function(e){function t(t){var n=e.call(this,t)||this;return n.state={value:n.props.value},n.onChange=n.onChange.bind(n),n.diff=n.diff.bind(n),n}return r(t,e),t.prototype.componentDidUpdate=function(){var e=this.props.value;e!==this.state.value&&this.setState({value:e})},t.prototype.onChange=function(e){this.setState({value:e}),this.props.onChange&&this.props.onChange(e)},t.prototype.diff=function(){var e=new l,t=this.state.value[0],n=this.state.value[1];if(0===t.length&&0===n.length)return[];var i=e.diff_main(t,n);e.diff_cleanupSemantic(i);var r=this.generateDiffedLines(i);return this.setCodeMarkers(r)},t.prototype.generateDiffedLines=function(e){var t={left:[],right:[]},n={left:1,right:1};return e.forEach((function(e){var i=e[0],r=e[1],o=r.split("\n").length-1;if(0!==r.length){var a=r[0],s=r[r.length-1],l=0;switch(i){case 0:n.left+=o,n.right+=o;break;case-1:"\n"===a&&(n.left++,o--),0===(l=o)&&t.right.push({startLine:n.right,endLine:n.right}),"\n"===s&&(l-=1),t.left.push({startLine:n.left,endLine:n.left+l}),n.left+=o;break;case 1:"\n"===a&&(n.right++,o--),0===(l=o)&&t.left.push({startLine:n.left,endLine:n.left}),"\n"===s&&(l-=1),t.right.push({startLine:n.right,endLine:n.right+l}),n.right+=o;break;default:throw new Error("Diff type was not defined.")}}})),t},t.prototype.setCodeMarkers=function(e){void 0===e&&(e={left:[],right:[]});for(var t=[],n={left:[],right:[]},i=0;i<e.left.length;i++){var r={startRow:e.left[i].startLine-1,endRow:e.left[i].endLine,type:"text",className:"codeMarker"};n.left.push(r)}for(i=0;i<e.right.length;i++)r={startRow:e.right[i].startLine-1,endRow:e.right[i].endLine,type:"text",className:"codeMarker"},n.right.push(r);return t[0]=n.left,t[1]=n.right,t},t.prototype.render=function(){var e=this.diff();return a.createElement(s.default,{name:this.props.name,className:this.props.className,focus:this.props.focus,orientation:this.props.orientation,splits:this.props.splits,mode:this.props.mode,theme:this.props.theme,height:this.props.height,width:this.props.width,fontSize:this.props.fontSize,showGutter:this.props.showGutter,onChange:this.onChange,onPaste:this.props.onPaste,onLoad:this.props.onLoad,onScroll:this.props.onScroll,minLines:this.props.minLines,maxLines:this.props.maxLines,readOnly:this.props.readOnly,highlightActiveLine:this.props.highlightActiveLine,showPrintMargin:this.props.showPrintMargin,tabSize:this.props.tabSize,cursorStart:this.props.cursorStart,editorProps:this.props.editorProps,style:this.props.style,scrollMargin:this.props.scrollMargin,setOptions:this.props.setOptions,wrapEnabled:this.props.wrapEnabled,enableBasicAutocompletion:this.props.enableBasicAutocompletion,enableLiveAutocompletion:this.props.enableLiveAutocompletion,value:this.state.value,markers:e})},t.propTypes={cursorStart:o.number,editorProps:o.object,enableBasicAutocompletion:o.bool,enableLiveAutocompletion:o.bool,focus:o.bool,fontSize:o.number,height:o.string,highlightActiveLine:o.bool,maxLines:o.number,minLines:o.number,mode:o.string,name:o.string,className:o.string,onLoad:o.func,onPaste:o.func,onScroll:o.func,onChange:o.func,orientation:o.string,readOnly:o.bool,scrollMargin:o.array,setOptions:o.object,showGutter:o.bool,showPrintMargin:o.bool,splits:o.number,style:o.object,tabSize:o.number,theme:o.string,value:o.array,width:o.string,wrapEnabled:o.bool},t.defaultProps={cursorStart:1,editorProps:{},enableBasicAutocompletion:!1,enableLiveAutocompletion:!1,focus:!1,fontSize:12,height:"500px",highlightActiveLine:!0,maxLines:null,minLines:null,mode:"",name:"ace-editor",onLoad:null,onScroll:null,onPaste:null,onChange:null,orientation:"beside",readOnly:!1,scrollMargin:[0,0,0,0],setOptions:{},showGutter:!0,showPrintMargin:!0,splits:2,style:{},tabSize:4,theme:"github",value:["",""],width:"500px",wrapEnabled:!0},t}(a.Component);t.default=c},911:function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return o=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},o.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(378),s=(0,a.getAceInstance)(),l=n(973),c=n(336),d=n(135),u=n(609),h=n(97),p=n(529),g=function(e){function t(t){var n=e.call(this,t)||this;return a.editorEvents.forEach((function(e){n[e]=n[e].bind(n)})),n.debounce=a.debounce,n}return r(t,e),t.prototype.isInShadow=function(e){for(var t=e&&e.parentNode;t;){if("[object ShadowRoot]"===t.toString())return!0;t=t.parentNode}return!1},t.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.className,i=t.onBeforeLoad,r=t.mode,o=t.focus,l=t.theme,d=t.fontSize,u=t.value,h=t.defaultValue,g=t.cursorStart,f=t.showGutter,m=t.wrapEnabled,y=t.showPrintMargin,v=t.scrollMargin,b=void 0===v?[0,0,0,0]:v,w=t.keyboardHandler,C=t.onLoad,x=t.commands,S=t.annotations,_=t.markers,E=t.splits;this.editor=s.edit(this.refEditor),this.isInShadow(this.refEditor)&&this.editor.renderer.attachToShadowRoot(),this.editor.setTheme("ace/theme/".concat(l)),i&&i(s);var k=Object.keys(this.props.editorProps),$=new c.Split(this.editor.container,"ace/theme/".concat(l),E);this.editor.env.split=$,this.splitEditor=$.getEditor(0),this.split=$,this.editor.setShowPrintMargin(!1),this.editor.renderer.setShowGutter(!1);var M=this.splitEditor.$options;this.props.debounceChangePeriod&&(this.onChange=this.debounce(this.onChange,this.props.debounceChangePeriod)),$.forEach((function(t,n){for(var i=0;i<k.length;i++)t[k[i]]=e.props.editorProps[k[i]];var o=p(h,n),c=p(u,n,"");t.session.setUndoManager(new s.UndoManager),t.setTheme("ace/theme/".concat(l)),t.renderer.setScrollMargin(b[0],b[1],b[2],b[3]),t.getSession().setMode("ace/mode/".concat(r)),t.setFontSize(d),t.renderer.setShowGutter(f),t.getSession().setUseWrapMode(m),t.setShowPrintMargin(y),t.on("focus",e.onFocus),t.on("blur",e.onBlur),t.on("input",e.onInput),t.on("copy",e.onCopy),t.on("paste",e.onPaste),t.on("change",e.onChange),t.getSession().selection.on("changeSelection",e.onSelectionChange),t.getSession().selection.on("changeCursor",e.onCursorChange),t.session.on("changeScrollTop",e.onScroll),t.setValue(void 0===o?c:o,g);var v=p(S,n,[]),C=p(_,n,[]);for(t.getSession().setAnnotations(v),C&&C.length>0&&e.handleMarkers(C,t),i=0;i<a.editorOptions.length;i++){var E=a.editorOptions[i];M.hasOwnProperty(E)?t.setOption(E,e.props[E]):e.props[E]&&console.warn("ReaceAce: editor option ".concat(E," was activated but not found. Did you need to import a related tool or did you possibly mispell the option?"))}e.handleOptions(e.props,t),Array.isArray(x)&&x.forEach((function(e){"string"==typeof e.exec?t.commands.bindKey(e.bindKey,e.exec):t.commands.addCommand(e)})),w&&t.setKeyboardHandler("ace/keyboard/"+w)})),n&&(this.refEditor.className+=" "+n),o&&this.splitEditor.focus();var T=this.editor.env.split;T.setOrientation("below"===this.props.orientation?T.BELOW:T.BESIDE),T.resize(!0),C&&C(T)},t.prototype.componentDidUpdate=function(e){var t=this,n=e,i=this.props,r=this.editor.env.split;if(i.splits!==n.splits&&r.setSplits(i.splits),i.orientation!==n.orientation&&r.setOrientation("below"===i.orientation?r.BELOW:r.BESIDE),r.forEach((function(e,r){i.mode!==n.mode&&e.getSession().setMode("ace/mode/"+i.mode),i.keyboardHandler!==n.keyboardHandler&&(i.keyboardHandler?e.setKeyboardHandler("ace/keyboard/"+i.keyboardHandler):e.setKeyboardHandler(null)),i.fontSize!==n.fontSize&&e.setFontSize(i.fontSize),i.wrapEnabled!==n.wrapEnabled&&e.getSession().setUseWrapMode(i.wrapEnabled),i.showPrintMargin!==n.showPrintMargin&&e.setShowPrintMargin(i.showPrintMargin),i.showGutter!==n.showGutter&&e.renderer.setShowGutter(i.showGutter);for(var o=0;o<a.editorOptions.length;o++){var s=a.editorOptions[o];i[s]!==n[s]&&e.setOption(s,i[s])}h(i.setOptions,n.setOptions)||t.handleOptions(i,e);var l=p(i.value,r,"");if(e.getValue()!==l){t.silent=!0;var c=e.session.selection.toJSON();e.setValue(l,i.cursorStart),e.session.selection.fromJSON(c),t.silent=!1}var d=p(i.annotations,r,[]),u=p(n.annotations,r,[]);h(d,u)||e.getSession().setAnnotations(d);var g=p(i.markers,r,[]),f=p(n.markers,r,[]);!h(g,f)&&Array.isArray(g)&&t.handleMarkers(g,e)})),i.className!==n.className){var o=this.refEditor.className.trim().split(" ");n.className.trim().split(" ").forEach((function(e){var t=o.indexOf(e);o.splice(t,1)})),this.refEditor.className=" "+i.className+" "+o.join(" ")}i.theme!==n.theme&&r.setTheme("ace/theme/"+i.theme),i.focus&&!n.focus&&this.splitEditor.focus(),i.height===this.props.height&&i.width===this.props.width||this.editor.resize()},t.prototype.componentWillUnmount=function(){this.editor.destroy(),this.editor=null},t.prototype.onChange=function(e){if(this.props.onChange&&!this.silent){var t=[];this.editor.env.split.forEach((function(e){t.push(e.getValue())})),this.props.onChange(t,e)}},t.prototype.onSelectionChange=function(e){if(this.props.onSelectionChange){var t=[];this.editor.env.split.forEach((function(e){t.push(e.getSelection())})),this.props.onSelectionChange(t,e)}},t.prototype.onCursorChange=function(e){if(this.props.onCursorChange){var t=[];this.editor.env.split.forEach((function(e){t.push(e.getSelection())})),this.props.onCursorChange(t,e)}},t.prototype.onFocus=function(e){this.props.onFocus&&this.props.onFocus(e)},t.prototype.onInput=function(e){this.props.onInput&&this.props.onInput(e)},t.prototype.onBlur=function(e){this.props.onBlur&&this.props.onBlur(e)},t.prototype.onCopy=function(e){this.props.onCopy&&this.props.onCopy(e)},t.prototype.onPaste=function(e){this.props.onPaste&&this.props.onPaste(e)},t.prototype.onScroll=function(){this.props.onScroll&&this.props.onScroll(this.editor)},t.prototype.handleOptions=function(e,t){for(var n=Object.keys(e.setOptions),i=0;i<n.length;i++)t.setOption(n[i],e.setOptions[n[i]])},t.prototype.handleMarkers=function(e,t){var n=t.getSession().getMarkers(!0);for(var i in n)n.hasOwnProperty(i)&&t.getSession().removeMarker(n[i].id);for(var i in n=t.getSession().getMarkers(!1))n.hasOwnProperty(i)&&t.getSession().removeMarker(n[i].id);e.forEach((function(e){var n=e.startRow,i=e.startCol,r=e.endRow,o=e.endCol,a=e.className,s=e.type,c=e.inFront,d=void 0!==c&&c,u=new l.Range(n,i,r,o);t.getSession().addMarker(u,a,s,d)}))},t.prototype.updateRef=function(e){this.refEditor=e},t.prototype.render=function(){var e=this.props,t=e.name,n=e.width,i=e.height,r=e.style,a=o({width:n,height:i},r);return u.createElement("div",{ref:this.updateRef,id:t,style:a})},t.propTypes={className:d.string,debounceChangePeriod:d.number,defaultValue:d.arrayOf(d.string),focus:d.bool,fontSize:d.oneOfType([d.number,d.string]),height:d.string,mode:d.string,name:d.string,onBlur:d.func,onChange:d.func,onCopy:d.func,onFocus:d.func,onInput:d.func,onLoad:d.func,onPaste:d.func,onScroll:d.func,orientation:d.string,showGutter:d.bool,splits:d.number,theme:d.string,value:d.arrayOf(d.string),width:d.string,onSelectionChange:d.func,onCursorChange:d.func,onBeforeLoad:d.func,minLines:d.number,maxLines:d.number,readOnly:d.bool,highlightActiveLine:d.bool,tabSize:d.number,showPrintMargin:d.bool,cursorStart:d.number,editorProps:d.object,setOptions:d.object,style:d.object,scrollMargin:d.array,annotations:d.array,markers:d.array,keyboardHandler:d.string,wrapEnabled:d.bool,enableBasicAutocompletion:d.oneOfType([d.bool,d.array]),enableLiveAutocompletion:d.oneOfType([d.bool,d.array]),commands:d.array},t.defaultProps={name:"ace-editor",focus:!1,orientation:"beside",splits:2,mode:"",theme:"",height:"500px",width:"500px",value:[],fontSize:12,showGutter:!0,onChange:null,onPaste:null,onLoad:null,onScroll:null,minLines:null,maxLines:null,readOnly:!1,highlightActiveLine:!0,showPrintMargin:!0,tabSize:4,cursorStart:1,editorProps:{},style:{},scrollMargin:[0,0,0,0],setOptions:{},wrapEnabled:!1,enableBasicAutocompletion:!1,enableLiveAutocompletion:!1},t}(u.Component);t.default=g},973:(e,t,n)=>{e=n.nmd(e),function(){var e=function(){return this}();e||"undefined"==typeof window||(e=window);var t=function(e,n,i){"string"==typeof e?(2==arguments.length&&(i=n),t.modules[e]||(t.payloads[e]=i,t.modules[e]=null)):t.original?t.original.apply(this,arguments):(console.error("dropping module because define wasn't a string."),console.trace())};t.modules={},t.payloads={};var n,i,r=function(e,t,n){if("string"==typeof t){var i=s(e,t);if(null!=i)return n&&n(),i}else if("[object Array]"===Object.prototype.toString.call(t)){for(var r=[],a=0,l=t.length;a<l;++a){var c=s(e,t[a]);if(null==c&&o.original)return;r.push(c)}return n&&n.apply(null,r)||!0}},o=function(e,t){var n=r("",e,t);return null==n&&o.original?o.original.apply(this,arguments):n},a=function(e,t){if(-1!==t.indexOf("!")){var n=t.split("!");return a(e,n[0])+"!"+a(e,n[1])}if("."==t.charAt(0))for(t=e.split("/").slice(0,-1).join("/")+"/"+t;-1!==t.indexOf(".")&&i!=t;){var i=t;t=t.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}return t},s=function(e,n){n=a(e,n);var i=t.modules[n];if(!i){if("function"==typeof(i=t.payloads[n])){var o={},s={id:n,uri:"",exports:o,packaged:!0};o=i((function(e,t){return r(n,e,t)}),o,s)||s.exports,t.modules[n]=o,delete t.payloads[n]}i=t.modules[n]=o||i}return i};i=e,(n="ace")&&(e[n]||(e[n]={}),i=e[n]),i.define&&i.define.packaged||(t.original=i.define,i.define=t,i.define.packaged=!0),i.require&&i.require.packaged||(o.original=i.require,i.require=o,i.require.packaged=!0)}(),ace.define("ace/lib/es6-shim",["require","exports","module"],(function(e,t,n){function i(e,t,n){Object.defineProperty(e,t,{value:n,enumerable:!1,writable:!0,configurable:!0})}String.prototype.startsWith||i(String.prototype,"startsWith",(function(e,t){return t=t||0,this.lastIndexOf(e,t)===t})),String.prototype.endsWith||i(String.prototype,"endsWith",(function(e,t){var n=this;(void 0===t||t>n.length)&&(t=n.length),t-=e.length;var i=n.indexOf(e,t);return-1!==i&&i===t})),String.prototype.repeat||i(String.prototype,"repeat",(function(e){for(var t="",n=this;e>0;)1&e&&(t+=n),(e>>=1)&&(n+=n);return t})),String.prototype.includes||i(String.prototype,"includes",(function(e,t){return-1!=this.indexOf(e,t)})),Object.assign||(Object.assign=function(e){if(null==e)throw new TypeError("Cannot convert undefined or null to object");for(var t=Object(e),n=1;n<arguments.length;n++){var i=arguments[n];null!=i&&Object.keys(i).forEach((function(e){t[e]=i[e]}))}return t}),Object.values||(Object.values=function(e){return Object.keys(e).map((function(t){return e[t]}))}),Array.prototype.find||i(Array.prototype,"find",(function(e){for(var t=this.length,n=arguments[1],i=0;i<t;i++){var r=this[i];if(e.call(n,r,i,this))return r}})),Array.prototype.findIndex||i(Array.prototype,"findIndex",(function(e){for(var t=this.length,n=arguments[1],i=0;i<t;i++){var r=this[i];if(e.call(n,r,i,this))return i}})),Array.prototype.includes||i(Array.prototype,"includes",(function(e,t){return-1!=this.indexOf(e,t)})),Array.prototype.fill||i(Array.prototype,"fill",(function(e){for(var t=this,n=t.length>>>0,i=0|arguments[1],r=i<0?Math.max(n+i,0):Math.min(i,n),o=arguments[2],a=void 0===o?n:0|o,s=a<0?Math.max(n+a,0):Math.min(a,n);r<s;)t[r]=e,r++;return t})),Array.of||i(Array,"of",(function(){return Array.prototype.slice.call(arguments)}))})),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/es6-shim"],(function(e,t,n){"use strict";e("./es6-shim")})),ace.define("ace/lib/deep_copy",["require","exports","module"],(function(e,t,n){t.deepCopy=function e(t){if("object"!=typeof t||!t)return t;var n;if(Array.isArray(t)){n=[];for(var i=0;i<t.length;i++)n[i]=e(t[i]);return n}if("[object Object]"!==Object.prototype.toString.call(t))return t;for(var i in n={},t)n[i]=e(t[i]);return n}})),ace.define("ace/lib/lang",["require","exports","module","ace/lib/deep_copy"],(function(e,t,n){"use strict";t.last=function(e){return e[e.length-1]},t.stringReverse=function(e){return e.split("").reverse().join("")},t.stringRepeat=function(e,t){for(var n="";t>0;)1&t&&(n+=e),(t>>=1)&&(e+=e);return n};var i=/^\s\s*/,r=/\s\s*$/;t.stringTrimLeft=function(e){return e.replace(i,"")},t.stringTrimRight=function(e){return e.replace(r,"")},t.copyObject=function(e){var t={};for(var n in e)t[n]=e[n];return t},t.copyArray=function(e){for(var t=[],n=0,i=e.length;n<i;n++)e[n]&&"object"==typeof e[n]?t[n]=this.copyObject(e[n]):t[n]=e[n];return t},t.deepCopy=e("./deep_copy").deepCopy,t.arrayToMap=function(e){for(var t={},n=0;n<e.length;n++)t[e[n]]=1;return t},t.createMap=function(e){var t=Object.create(null);for(var n in e)t[n]=e[n];return t},t.arrayRemove=function(e,t){for(var n=0;n<=e.length;n++)t===e[n]&&e.splice(n,1)},t.escapeRegExp=function(e){return e.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},t.escapeHTML=function(e){return(""+e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<")},t.getMatchOffsets=function(e,t){var n=[];return e.replace(t,(function(e){n.push({offset:arguments[arguments.length-2],length:e.length})})),n},t.deferredCall=function(e){var t=null,n=function(){t=null,e()},i=function(e){return i.cancel(),t=setTimeout(n,e||0),i};return i.schedule=i,i.call=function(){return this.cancel(),e(),i},i.cancel=function(){return clearTimeout(t),t=null,i},i.isPending=function(){return t},i},t.delayedCall=function(e,t){var n=null,i=function(){n=null,e()},r=function(e){null==n&&(n=setTimeout(i,e||t))};return r.delay=function(e){n&&clearTimeout(n),n=setTimeout(i,e||t)},r.schedule=r,r.call=function(){this.cancel(),e()},r.cancel=function(){n&&clearTimeout(n),n=null},r.isPending=function(){return n},r},t.supportsLookbehind=function(){try{new RegExp("(?<=.)")}catch(e){return!1}return!0},t.skipEmptyMatch=function(e,t,n){return n&&e.codePointAt(t)>65535?2:1}})),ace.define("ace/lib/useragent",["require","exports","module"],(function(e,t,n){"use strict";t.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},t.getOS=function(){return t.isMac?t.OS.MAC:t.isLinux?t.OS.LINUX:t.OS.WINDOWS};var i="object"==typeof navigator?navigator:{},r=(/mac|win|linux/i.exec(i.platform)||["other"])[0].toLowerCase(),o=i.userAgent||"",a=i.appName||"";t.isWin="win"==r,t.isMac="mac"==r,t.isLinux="linux"==r,t.isIE="Microsoft Internet Explorer"==a||a.indexOf("MSAppHost")>=0?parseFloat((o.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((o.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),t.isOldIE=t.isIE&&t.isIE<9,t.isGecko=t.isMozilla=o.match(/ Gecko\/\d+/),t.isOpera="object"==typeof opera&&"[object Opera]"==Object.prototype.toString.call(window.opera),t.isWebKit=parseFloat(o.split("WebKit/")[1])||void 0,t.isChrome=parseFloat(o.split(" Chrome/")[1])||void 0,t.isSafari=parseFloat(o.split(" Safari/")[1])&&!t.isChrome||void 0,t.isEdge=parseFloat(o.split(" Edge/")[1])||void 0,t.isAIR=o.indexOf("AdobeAIR")>=0,t.isAndroid=o.indexOf("Android")>=0,t.isChromeOS=o.indexOf(" CrOS ")>=0,t.isIOS=/iPad|iPhone|iPod/.test(o)&&!window.MSStream,t.isIOS&&(t.isMac=!0),t.isMobile=t.isIOS||t.isAndroid})),ace.define("ace/lib/dom",["require","exports","module","ace/lib/useragent"],(function(e,t,n){"use strict";var i,r=e("./useragent");t.buildDom=function e(t,n,i){if("string"==typeof t&&t){var r=document.createTextNode(t);return n&&n.appendChild(r),r}if(!Array.isArray(t))return t&&t.appendChild&&n&&n.appendChild(t),t;if("string"!=typeof t[0]||!t[0]){for(var o=[],a=0;a<t.length;a++){var s=e(t[a],n,i);s&&o.push(s)}return o}var l=document.createElement(t[0]),c=t[1],d=1;for(c&&"object"==typeof c&&!Array.isArray(c)&&(d=2),a=d;a<t.length;a++)e(t[a],l,i);return 2==d&&Object.keys(c).forEach((function(e){var t=c[e];"class"===e?l.className=Array.isArray(t)?t.join(" "):t:"function"==typeof t||"value"==e||"$"==e[0]?l[e]=t:"ref"===e?i&&(i[t]=l):"style"===e?"string"==typeof t&&(l.style.cssText=t):null!=t&&l.setAttribute(e,t)})),n&&n.appendChild(l),l},t.getDocumentHead=function(e){return e||(e=document),e.head||e.getElementsByTagName("head")[0]||e.documentElement},t.createElement=function(e,t){return document.createElementNS?document.createElementNS(t||"http://www.w3.org/1999/xhtml",e):document.createElement(e)},t.removeChildren=function(e){e.innerHTML=""},t.createTextNode=function(e,t){return(t?t.ownerDocument:document).createTextNode(e)},t.createFragment=function(e){return(e?e.ownerDocument:document).createDocumentFragment()},t.hasCssClass=function(e,t){return-1!==(e.className+"").split(/\s+/g).indexOf(t)},t.addCssClass=function(e,n){t.hasCssClass(e,n)||(e.className+=" "+n)},t.removeCssClass=function(e,t){for(var n=e.className.split(/\s+/g);;){var i=n.indexOf(t);if(-1==i)break;n.splice(i,1)}e.className=n.join(" ")},t.toggleCssClass=function(e,t){for(var n=e.className.split(/\s+/g),i=!0;;){var r=n.indexOf(t);if(-1==r)break;i=!1,n.splice(r,1)}return i&&n.push(t),e.className=n.join(" "),i},t.setCssClass=function(e,n,i){i?t.addCssClass(e,n):t.removeCssClass(e,n)},t.hasCssString=function(e,t){var n,i=0;if(n=(t=t||document).querySelectorAll("style"))for(;i<n.length;)if(n[i++].id===e)return!0},t.removeElementById=function(e,t){(t=t||document).getElementById(e)&&t.getElementById(e).remove()};var o=[];function a(){var e=o;o=null,e&&e.forEach((function(e){s(e[0],e[1])}))}function s(e,n,r){if("undefined"!=typeof document){if(o)if(r)a();else if(!1===r)return o.push([e,n]);if(!i){var s=r;r&&r.getRootNode&&(s=r.getRootNode())&&s!=r||(s=document);var l=s.ownerDocument||s;if(n&&t.hasCssString(n,s))return null;n&&(e+="\n/*# sourceURL=ace/css/"+n+" */");var c=t.createElement("style");c.appendChild(l.createTextNode(e)),n&&(c.id=n),s==l&&(s=t.getDocumentHead(l)),s.insertBefore(c,s.firstChild)}}}if(t.useStrictCSP=function(e){i=e,0==e?a():o||(o=[])},t.importCssString=s,t.importCssStylsheet=function(e,n){t.buildDom(["link",{rel:"stylesheet",href:e}],t.getDocumentHead(n))},t.scrollbarWidth=function(e){var n=t.createElement("ace_inner");n.style.width="100%",n.style.minWidth="0px",n.style.height="200px",n.style.display="block";var i=t.createElement("ace_outer"),r=i.style;r.position="absolute",r.left="-10000px",r.overflow="hidden",r.width="200px",r.minWidth="0px",r.height="150px",r.display="block",i.appendChild(n);var o=e&&e.documentElement||document&&document.documentElement;if(!o)return 0;o.appendChild(i);var a=n.offsetWidth;r.overflow="scroll";var s=n.offsetWidth;return a===s&&(s=i.clientWidth),o.removeChild(i),a-s},t.computedStyle=function(e,t){return window.getComputedStyle(e,"")||{}},t.setStyle=function(e,t,n){e[t]!==n&&(e[t]=n)},t.HAS_CSS_ANIMATION=!1,t.HAS_CSS_TRANSFORMS=!1,t.HI_DPI=!r.isWin||"undefined"!=typeof window&&window.devicePixelRatio>=1.5,r.isChromeOS&&(t.HI_DPI=!1),"undefined"!=typeof document){var l=document.createElement("div");t.HI_DPI&&void 0!==l.style.transform&&(t.HAS_CSS_TRANSFORMS=!0),r.isEdge||void 0===l.style.animationName||(t.HAS_CSS_ANIMATION=!0),l=null}t.HAS_CSS_TRANSFORMS?t.translate=function(e,t,n){e.style.transform="translate("+Math.round(t)+"px, "+Math.round(n)+"px)"}:t.translate=function(e,t,n){e.style.top=Math.round(n)+"px",e.style.left=Math.round(t)+"px"}})),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var i=e("./dom");t.get=function(e,t){var n=new XMLHttpRequest;n.open("GET",e,!0),n.onreadystatechange=function(){4===n.readyState&&t(n.responseText)},n.send(null)},t.loadScript=function(e,t){var n=i.getDocumentHead(),r=document.createElement("script");r.src=e,n.appendChild(r),r.onload=r.onreadystatechange=function(e,n){!n&&r.readyState&&"loaded"!=r.readyState&&"complete"!=r.readyState||(r=r.onload=r.onreadystatechange=null,n||t())}},t.qualifyURL=function(e){var t=document.createElement("a");return t.href=e,t.href}})),ace.define("ace/lib/oop",["require","exports","module"],(function(e,t,n){"use strict";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var n in t)e[n]=t[n];return e},t.implement=function(e,n){t.mixin(e,n)}})),ace.define("ace/lib/event_emitter",["require","exports","module"],(function(e,t,n){"use strict";var i={},r=function(){this.propagationStopped=!0},o=function(){this.defaultPrevented=!0};i._emit=i._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var n=this._eventRegistry[e]||[],i=this._defaultHandlers[e];if(n.length||i){"object"==typeof t&&t||(t={}),t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=r),t.preventDefault||(t.preventDefault=o),n=n.slice();for(var a=0;a<n.length&&(n[a](t,this),!t.propagationStopped);a++);return i&&!t.defaultPrevented?i(t,this):void 0}},i._signal=function(e,t){var n=(this._eventRegistry||{})[e];if(n){n=n.slice();for(var i=0;i<n.length;i++)n[i](t,this)}},i.once=function(e,t){var n=this;if(this.on(e,(function i(){n.off(e,i),t.apply(null,arguments)})),!t)return new Promise((function(e){t=e}))},i.setDefaultHandler=function(e,t){var n=this._defaultHandlers;if(n||(n=this._defaultHandlers={_disabled_:{}}),n[e]){var i=n[e],r=n._disabled_[e];r||(n._disabled_[e]=r=[]),r.push(i);var o=r.indexOf(t);-1!=o&&r.splice(o,1)}n[e]=t},i.removeDefaultHandler=function(e,t){var n=this._defaultHandlers;if(n){var i=n._disabled_[e];if(n[e]==t)i&&this.setDefaultHandler(e,i.pop());else if(i){var r=i.indexOf(t);-1!=r&&i.splice(r,1)}}},i.on=i.addEventListener=function(e,t,n){this._eventRegistry=this._eventRegistry||{};var i=this._eventRegistry[e];return i||(i=this._eventRegistry[e]=[]),-1==i.indexOf(t)&&i[n?"unshift":"push"](t),t},i.off=i.removeListener=i.removeEventListener=function(e,t){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[e];if(n){var i=n.indexOf(t);-1!==i&&n.splice(i,1)}},i.removeAllListeners=function(e){e||(this._eventRegistry=this._defaultHandlers=void 0),this._eventRegistry&&(this._eventRegistry[e]=void 0),this._defaultHandlers&&(this._defaultHandlers[e]=void 0)},t.EventEmitter=i})),ace.define("ace/lib/report_error",["require","exports","module"],(function(e,t,n){t.reportError=function(e,t){var n=new Error(e);n.data=t,"object"==typeof console&&console.error&&console.error(n),setTimeout((function(){throw n}))}})),ace.define("ace/lib/default_english_messages",["require","exports","module"],(function(e,t,n){t.defaultEnglishMessages={"autocomplete.popup.aria-roledescription":"Autocomplete suggestions","autocomplete.popup.aria-label":"Autocomplete suggestions","autocomplete.popup.item.aria-roledescription":"item","autocomplete.loading":"Loading...","editor.scroller.aria-roledescription":"editor","editor.scroller.aria-label":"Editor content, press Enter to start editing, press Escape to exit","editor.gutter.aria-roledescription":"editor gutter","editor.gutter.aria-label":"Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit","error-marker.good-state":"Looks good!","prompt.recently-used":"Recently used","prompt.other-commands":"Other commands","prompt.no-matching-commands":"No matching commands","search-box.find.placeholder":"Search for","search-box.find-all.text":"All","search-box.replace.placeholder":"Replace with","search-box.replace-next.text":"Replace","search-box.replace-all.text":"All","search-box.toggle-replace.title":"Toggle Replace mode","search-box.toggle-regexp.title":"RegExp Search","search-box.toggle-case.title":"CaseSensitive Search","search-box.toggle-whole-word.title":"Whole Word Search","search-box.toggle-in-selection.title":"Search In Selection","search-box.search-counter":"$0 of $1","text-input.aria-roledescription":"editor","text-input.aria-label":"Cursor at row $0","gutter.code-folding.range.aria-label":"Toggle code folding, rows $0 through $1","gutter.code-folding.closed.aria-label":"Toggle code folding, rows $0 through $1","gutter.code-folding.open.aria-label":"Toggle code folding, row $0","gutter.code-folding.closed.title":"Unfold code","gutter.code-folding.open.title":"Fold code","gutter.annotation.aria-label.error":"Error, read annotations row $0","gutter.annotation.aria-label.warning":"Warning, read annotations row $0","gutter.annotation.aria-label.info":"Info, read annotations row $0","inline-fold.closed.title":"Unfold code","gutter-tooltip.aria-label.error.singular":"error","gutter-tooltip.aria-label.error.plural":"errors","gutter-tooltip.aria-label.warning.singular":"warning","gutter-tooltip.aria-label.warning.plural":"warnings","gutter-tooltip.aria-label.info.singular":"information message","gutter-tooltip.aria-label.info.plural":"information messages","gutter.annotation.aria-label.security":"Security finding, read annotations row $0","gutter.annotation.aria-label.hint":"Suggestion, read annotations row $0","gutter-tooltip.aria-label.security.singular":"security finding","gutter-tooltip.aria-label.security.plural":"security findings","gutter-tooltip.aria-label.hint.singular":"suggestion","gutter-tooltip.aria-label.hint.plural":"suggestions","editor.tooltip.disable-editing":"Editing is disabled"}})),ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/report_error","ace/lib/default_english_messages"],(function(e,t,n){var i,r,o=e("./oop"),a=e("./event_emitter").EventEmitter,s=e("./report_error").reportError,l=e("./default_english_messages").defaultEnglishMessages,c={setOptions:function(e){Object.keys(e).forEach((function(t){this.setOption(t,e[t])}),this)},getOptions:function(e){var t={};if(e)Array.isArray(e)||(t=e,e=Object.keys(t));else{var n=this.$options;e=Object.keys(n).filter((function(e){return!n[e].hidden}))}return e.forEach((function(e){t[e]=this.getOption(e)}),this),t},setOption:function(e,t){if(this["$"+e]!==t){var n=this.$options[e];if(!n)return d('misspelled option "'+e+'"');if(n.forwardTo)return this[n.forwardTo]&&this[n.forwardTo].setOption(e,t);n.handlesSet||(this["$"+e]=t),n&&n.set&&n.set.call(this,t)}},getOption:function(e){var t=this.$options[e];return t?t.forwardTo?this[t.forwardTo]&&this[t.forwardTo].getOption(e):t&&t.get?t.get.call(this):this["$"+e]:d('misspelled option "'+e+'"')}};function d(e){"undefined"!=typeof console&&console.warn&&console.warn.apply(console,arguments)}var u=function(){function e(){this.$defaultOptions={},i=l,r="dollarSigns"}return e.prototype.defineOptions=function(e,t,n){return e.$options||(this.$defaultOptions[t]=e.$options={}),Object.keys(n).forEach((function(t){var i=n[t];"string"==typeof i&&(i={forwardTo:i}),i.name||(i.name=t),e.$options[i.name]=i,"initialValue"in i&&(e["$"+i.name]=i.initialValue)})),o.implement(e,c),this},e.prototype.resetOptions=function(e){Object.keys(e.$options).forEach((function(t){var n=e.$options[t];"value"in n&&e.setOption(t,n.value)}))},e.prototype.setDefaultValue=function(e,t,n){if(!e){for(e in this.$defaultOptions)if(this.$defaultOptions[e][t])break;if(!this.$defaultOptions[e][t])return!1}var i=this.$defaultOptions[e]||(this.$defaultOptions[e]={});i[t]&&(i.forwardTo?this.setDefaultValue(i.forwardTo,t,n):i[t].value=n)},e.prototype.setDefaultValues=function(e,t){Object.keys(t).forEach((function(n){this.setDefaultValue(e,n,t[n])}),this)},e.prototype.setMessages=function(e,t){i=e,t&&t.placeholders&&(r=t.placeholders)},e.prototype.nls=function(e,t,n){i[e]||(d("No message found for the key '"+e+"' in messages with id "+i.$id+", trying to find a translation for the default string '"+t+"'."),i[t]||d("No message found for the default string '"+t+"' in the provided messages. Falling back to the default English message."));var o=i[e]||i[t]||t;return n&&("dollarSigns"===r&&(o=o.replace(/\$(\$|[\d]+)/g,(function(e,t){return"$"==t?"$":n[t]}))),"curlyBrackets"===r&&(o=o.replace(/\{([^\}]+)\}/g,(function(e,t){return n[t]})))),o},e}();u.prototype.warn=d,u.prototype.reportError=s,o.implement(u.prototype,a),t.AppConfig=u})),ace.define("ace/theme/textmate-css",["require","exports","module"],(function(e,t,n){n.exports='.ace-tm .ace_gutter {\n background: #f0f0f0;\n color: #333;\n}\n\n.ace-tm .ace_print-margin {\n width: 1px;\n background: #e8e8e8;\n}\n\n.ace-tm .ace_fold {\n background-color: #6B72E6;\n}\n\n.ace-tm {\n background-color: #FFFFFF;\n color: black;\n}\n\n.ace-tm .ace_cursor {\n color: black;\n}\n \n.ace-tm .ace_invisible {\n color: rgb(191, 191, 191);\n}\n\n.ace-tm .ace_storage,\n.ace-tm .ace_keyword {\n color: blue;\n}\n\n.ace-tm .ace_constant {\n color: rgb(197, 6, 11);\n}\n\n.ace-tm .ace_constant.ace_buildin {\n color: rgb(88, 72, 246);\n}\n\n.ace-tm .ace_constant.ace_language {\n color: rgb(88, 92, 246);\n}\n\n.ace-tm .ace_constant.ace_library {\n color: rgb(6, 150, 14);\n}\n\n.ace-tm .ace_invalid {\n background-color: rgba(255, 0, 0, 0.1);\n color: red;\n}\n\n.ace-tm .ace_support.ace_function {\n color: rgb(60, 76, 114);\n}\n\n.ace-tm .ace_support.ace_constant {\n color: rgb(6, 150, 14);\n}\n\n.ace-tm .ace_support.ace_type,\n.ace-tm .ace_support.ace_class {\n color: rgb(109, 121, 222);\n}\n\n.ace-tm .ace_keyword.ace_operator {\n color: rgb(104, 118, 135);\n}\n\n.ace-tm .ace_string {\n color: rgb(3, 106, 7);\n}\n\n.ace-tm .ace_comment {\n color: rgb(76, 136, 107);\n}\n\n.ace-tm .ace_comment.ace_doc {\n color: rgb(0, 102, 255);\n}\n\n.ace-tm .ace_comment.ace_doc.ace_tag {\n color: rgb(128, 159, 191);\n}\n\n.ace-tm .ace_constant.ace_numeric {\n color: rgb(0, 0, 205);\n}\n\n.ace-tm .ace_variable {\n color: rgb(49, 132, 149);\n}\n\n.ace-tm .ace_xml-pe {\n color: rgb(104, 104, 91);\n}\n\n.ace-tm .ace_entity.ace_name.ace_function {\n color: #0000A2;\n}\n\n\n.ace-tm .ace_heading {\n color: rgb(12, 7, 255);\n}\n\n.ace-tm .ace_list {\n color:rgb(185, 6, 144);\n}\n\n.ace-tm .ace_meta.ace_tag {\n color:rgb(0, 22, 142);\n}\n\n.ace-tm .ace_string.ace_regex {\n color: rgb(255, 0, 0)\n}\n\n.ace-tm .ace_marker-layer .ace_selection {\n background: rgb(181, 213, 255);\n}\n.ace-tm.ace_multiselect .ace_selection.ace_start {\n box-shadow: 0 0 3px 0px white;\n}\n.ace-tm .ace_marker-layer .ace_step {\n background: rgb(252, 255, 0);\n}\n\n.ace-tm .ace_marker-layer .ace_stack {\n background: rgb(164, 229, 101);\n}\n\n.ace-tm .ace_marker-layer .ace_bracket {\n margin: -1px 0 0 -1px;\n border: 1px solid rgb(192, 192, 192);\n}\n\n.ace-tm .ace_marker-layer .ace_active-line {\n background: rgba(0, 0, 0, 0.07);\n}\n\n.ace-tm .ace_gutter-active-line {\n background-color : #dcdcdc;\n}\n\n.ace-tm .ace_marker-layer .ace_selected-word {\n background: rgb(250, 250, 255);\n border: 1px solid rgb(200, 200, 250);\n}\n\n.ace-tm .ace_indent-guide {\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;\n}\n\n.ace-tm .ace_indent-guide-active {\n background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAAZSURBVHjaYvj///9/hivKyv8BAAAA//8DACLqBhbvk+/eAAAAAElFTkSuQmCC") right repeat-y;\n}\n'})),ace.define("ace/theme/textmate",["require","exports","module","ace/theme/textmate-css","ace/lib/dom"],(function(e,t,n){"use strict";t.isDark=!1,t.cssClass="ace-tm",t.cssText=e("./textmate-css"),t.$id="ace/theme/textmate",e("../lib/dom").importCssString(t.cssText,t.cssClass,!1)})),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/net","ace/lib/dom","ace/lib/app_config","ace/theme/textmate"],(function(e,t,n){var i=e("./lib/lang"),r=e("./lib/net"),o=e("./lib/dom"),a=e("./lib/app_config").AppConfig;n.exports=t=new a;var s,l={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{},loadWorkerFromBlob:!0,sharedPopups:!1,useStrictCSP:null};t.get=function(e){if(!l.hasOwnProperty(e))throw new Error("Unknown config key: "+e);return l[e]},t.set=function(e,t){if(l.hasOwnProperty(e))l[e]=t;else if(0==this.setDefaultValue("",e,t))throw new Error("Unknown config key: "+e);"useStrictCSP"==e&&o.useStrictCSP(t)},t.all=function(){return i.copyObject(l)},t.$modes={},t.moduleUrl=function(e,t){if(l.$moduleUrls[e])return l.$moduleUrls[e];var n=e.split("/"),i="snippets"==(t=t||n[n.length-2]||"")?"/":"-",r=n[n.length-1];if("worker"==t&&"-"==i){var o=new RegExp("^"+t+"[\\-_]|[\\-_]"+t+"$","g");r=r.replace(o,"")}(!r||r==t)&&n.length>1&&(r=n[n.length-2]);var a=l[t+"Path"];return null==a?a=l.basePath:"/"==i&&(t=i=""),a&&"/"!=a.slice(-1)&&(a+="/"),a+t+i+r+this.get("suffix")},t.setModuleUrl=function(e,t){return l.$moduleUrls[e]=t},t.setLoader=function(e){s=e},t.dynamicModules=Object.create(null),t.$loading={},t.$loaded={},t.loadModule=function(n,i){var o;if(Array.isArray(n))var a=n[0],l=n[1];else"string"==typeof n&&(l=n);var d=function(n){if(n&&!t.$loading[l])return i&&i(n);if(t.$loading[l]||(t.$loading[l]=[]),t.$loading[l].push(i),!(t.$loading[l].length>1)){var o=function(){!function(t,n){"ace/theme/textmate"===t||"./theme/textmate"===t?n(0,e("./theme/textmate")):s?s(t,n):console.error("loader is not configured")}(l,(function(e,n){n&&(t.$loaded[l]=n),t._emit("load.module",{name:l,module:n});var i=t.$loading[l];t.$loading[l]=null,i.forEach((function(e){e&&e(n)}))}))};if(!t.get("packaged"))return o();r.loadScript(t.moduleUrl(l,a),o),c()}};if(t.dynamicModules[l])t.dynamicModules[l]().then((function(e){e.default?d(e.default):d(e)}));else{try{o=this.$require(l)}catch(e){}d(o||t.$loaded[l])}},t.$require=function(e){if("function"==typeof n.require)return n.require(e)},t.setModuleLoader=function(e,n){t.dynamicModules[e]=n};var c=function(){l.basePath||l.workerPath||l.modePath||l.themePath||Object.keys(l.$moduleUrls).length||(console.error("Unable to infer path to ace from script src,","use ace.config.set('basePath', 'path') to enable dynamic loading of modes and themes","or with webpack use ace/webpack-resolver"),c=function(){})};t.version="1.39.1"})),ace.define("ace/loader_build",["require","exports","module","ace/lib/fixoldbrowsers","ace/config"],(function(e,t,i){"use strict";e("./lib/fixoldbrowsers");var r=e("./config");r.setLoader((function(t,n){e([t],(function(e){n(null,e)}))}));var o=function(){return this||"undefined"!=typeof window&&window}();function a(t){if(o&&o.document){r.set("packaged",t||e.packaged||i.packaged||o.define&&n.amdD.packaged);var a={},s="",l=document.currentScript||document._currentScript,c=l&&l.ownerDocument||document;l&&l.src&&(s=l.src.split(/[?#]/)[0].split("/").slice(0,-1).join("/")||"");for(var d,u=c.getElementsByTagName("script"),h=0;h<u.length;h++){var p=u[h],g=p.src||p.getAttribute("src");if(g){for(var f=p.attributes,m=0,y=f.length;m<y;m++){var v=f[m];0===v.name.indexOf("data-ace-")&&(a[(d=v.name.replace(/^data-ace-/,""),d.replace(/-(.)/g,(function(e,t){return t.toUpperCase()})))]=v.value)}var b=g.match(/^(.*)\/ace([\-.]\w+)?\.js(\?|$)/);b&&(s=b[1])}}for(var w in s&&(a.base=a.base||s,a.packaged=!0),a.basePath=a.base,a.workerPath=a.workerPath||a.base,a.modePath=a.modePath||a.base,a.themePath=a.themePath||a.base,delete a.base,a)void 0!==a[w]&&r.set(w,a[w])}}i.exports=function(t){r.init=a,r.$require=e,t.require=e,t.define=n.amdD},a(!0)})),ace.define("ace/range",["require","exports","module"],(function(e,t,n){"use strict";var i=function(){function e(e,t,n,i){this.start={row:e,column:t},this.end={row:n,column:i}}return e.prototype.isEqual=function(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column},e.prototype.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},e.prototype.contains=function(e,t){return 0==this.compare(e,t)},e.prototype.compareRange=function(e){var t,n=e.end,i=e.start;return 1==(t=this.compare(n.row,n.column))?1==(t=this.compare(i.row,i.column))?2:0==t?1:0:-1==t?-2:-1==(t=this.compare(i.row,i.column))?-1:1==t?42:0},e.prototype.comparePoint=function(e){return this.compare(e.row,e.column)},e.prototype.containsRange=function(e){return 0==this.comparePoint(e.start)&&0==this.comparePoint(e.end)},e.prototype.intersects=function(e){var t=this.compareRange(e);return-1==t||0==t||1==t},e.prototype.isEnd=function(e,t){return this.end.row==e&&this.end.column==t},e.prototype.isStart=function(e,t){return this.start.row==e&&this.start.column==t},e.prototype.setStart=function(e,t){"object"==typeof e?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)},e.prototype.setEnd=function(e,t){"object"==typeof e?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)},e.prototype.inside=function(e,t){return 0==this.compare(e,t)&&!this.isEnd(e,t)&&!this.isStart(e,t)},e.prototype.insideStart=function(e,t){return 0==this.compare(e,t)&&!this.isEnd(e,t)},e.prototype.insideEnd=function(e,t){return 0==this.compare(e,t)&&!this.isStart(e,t)},e.prototype.compare=function(e,t){return this.isMultiLine()||e!==this.start.row?e<this.start.row?-1:e>this.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0:t<this.start.column?-1:t>this.end.column?1:0},e.prototype.compareStart=function(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},e.prototype.compareEnd=function(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)},e.prototype.compareInside=function(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},e.prototype.clipRows=function(t,n){if(this.end.row>n)var i={row:n+1,column:0};else this.end.row<t&&(i={row:t,column:0});if(this.start.row>n)var r={row:n+1,column:0};else this.start.row<t&&(r={row:t,column:0});return e.fromPoints(r||this.start,i||this.end)},e.prototype.extend=function(t,n){var i=this.compare(t,n);if(0==i)return this;if(-1==i)var r={row:t,column:n};else var o={row:t,column:n};return e.fromPoints(r||this.start,o||this.end)},e.prototype.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},e.prototype.isMultiLine=function(){return this.start.row!==this.end.row},e.prototype.clone=function(){return e.fromPoints(this.start,this.end)},e.prototype.collapseRows=function(){return 0==this.end.column?new e(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new e(this.start.row,0,this.end.row,0)},e.prototype.toScreenRange=function(t){var n=t.documentToScreenPosition(this.start),i=t.documentToScreenPosition(this.end);return new e(n.row,n.column,i.row,i.column)},e.prototype.moveBy=function(e,t){this.start.row+=e,this.start.column+=t,this.end.row+=e,this.end.column+=t},e}();i.fromPoints=function(e,t){return new i(e.row,e.column,t.row,t.column)},i.comparePoints=function(e,t){return e.row-t.row||e.column-t.column},t.Range=i})),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],(function(e,t,n){"use strict";for(var i=e("./oop"),r={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta",91:"MetaLeft",92:"MetaRight",93:"ContextMenu"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,super:8,meta:8,command:8,cmd:8,control:1},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete","-13":"NumpadEnter",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",59:";",61:"=",107:"+",109:"-",110:".",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",111:"/",106:"*"}},o={Command:224,Backspace:8,Tab:9,Return:13,Enter:13,Pause:19,Escape:27,PageUp:33,PageDown:34,End:35,Home:36,Insert:45,Delete:46,ArrowLeft:37,ArrowUp:38,ArrowRight:39,ArrowDown:40,Backquote:192,Minus:189,Equal:187,BracketLeft:219,Backslash:220,BracketRight:221,Semicolon:186,Quote:222,Comma:188,Period:190,Slash:191,Space:32,NumpadAdd:107,NumpadDecimal:110,NumpadSubtract:109,NumpadDivide:111,NumpadMultiply:106},a=0;a<10;a++)o["Digit"+a]=48+a,o["Numpad"+a]=96+a,r.PRINTABLE_KEYS[48+a]=""+a,r.FUNCTION_KEYS[96+a]="Numpad"+a;for(a=65;a<91;a++){var s=String.fromCharCode(a+32);o["Key"+s.toUpperCase()]=a,r.PRINTABLE_KEYS[a]=s}for(a=1;a<13;a++)o["F"+a]=111+a,r.FUNCTION_KEYS[111+a]="F"+a;var l={Shift:16,Control:17,Alt:18,Meta:224};for(var c in l)o[c]=o[c+"Left"]=o[c+"Right"]=l[c];for(var d in t.$codeToKeyCode=o,r.PRINTABLE_KEYS[173]="-",r.FUNCTION_KEYS){var u=r.FUNCTION_KEYS[d].toLowerCase();r[u]=parseInt(d,10)}for(var d in r.PRINTABLE_KEYS)u=r.PRINTABLE_KEYS[d].toLowerCase(),r[u]=parseInt(d,10);i.mixin(r,r.MODIFIER_KEYS),i.mixin(r,r.PRINTABLE_KEYS),i.mixin(r,r.FUNCTION_KEYS),r.enter=r.return,r.escape=r.esc,r.del=r.delete,function(){for(var e=["cmd","ctrl","alt","shift"],t=Math.pow(2,e.length);t--;)r.KEY_MODS[t]=e.filter((function(e){return t&r.KEY_MODS[e]})).join("-")+"-"}(),r.KEY_MODS[0]="",r.KEY_MODS[-1]="input-",i.mixin(t,r),t.default=t,t.keyCodeToString=function(e){var t=r[e];return"string"!=typeof t&&(t=String.fromCharCode(e)),t.toLowerCase()}})),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],(function(e,t,n){"use strict";var i,r=e("./keys"),o=e("./useragent"),a=null,s=0;function l(){return null==i&&function(){i=!1;try{document.createComment("").addEventListener("test",(function(){}),{get passive(){return i={passive:!1},!0}})}catch(e){}}(),i}function c(e,t,n){this.elem=e,this.type=t,this.callback=n}c.prototype.destroy=function(){u(this.elem,this.type,this.callback),this.elem=this.type=this.callback=void 0};var d=t.addListener=function(e,t,n,i){e.addEventListener(t,n,l()),i&&i.$toDestroy.push(new c(e,t,n))},u=t.removeListener=function(e,t,n){e.removeEventListener(t,n,l())};function h(e){return(e.ctrlKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.metaKey?8:0)}function p(){a=Object.create(null)}if(t.stopEvent=function(e){return t.stopPropagation(e),t.preventDefault(e),!1},t.stopPropagation=function(e){e.stopPropagation&&e.stopPropagation()},t.preventDefault=function(e){e.preventDefault&&e.preventDefault()},t.getButton=function(e){return"dblclick"==e.type?0:"contextmenu"==e.type||o.isMac&&e.ctrlKey&&!e.altKey&&!e.shiftKey?2:e.button},t.capture=function(e,t,n){var i=e&&e.ownerDocument||document;function r(e){t&&t(e),n&&n(e),u(i,"mousemove",t),u(i,"mouseup",r),u(i,"dragstart",r)}return d(i,"mousemove",t),d(i,"mouseup",r),d(i,"dragstart",r),r},t.addMouseWheelListener=function(e,t,n){d(e,"wheel",(function(e){var n=e.deltaX||0,i=e.deltaY||0;switch(e.deltaMode){case e.DOM_DELTA_PIXEL:e.wheelX=.15*n,e.wheelY=.15*i;break;case e.DOM_DELTA_LINE:e.wheelX=15*n,e.wheelY=15*i;break;case e.DOM_DELTA_PAGE:e.wheelX=150*n,e.wheelY=150*i}t(e)}),n)},t.addMultiMouseDownListener=function(e,n,i,r,a){var s,l,c,u=0,h={2:"dblclick",3:"tripleclick",4:"quadclick"};function p(e){if(0!==t.getButton(e)?u=0:e.detail>1?++u>4&&(u=1):u=1,o.isIE){var a=Math.abs(e.clientX-s)>5||Math.abs(e.clientY-l)>5;c&&!a||(u=1),c&&clearTimeout(c),c=setTimeout((function(){c=null}),n[u-1]||600),1==u&&(s=e.clientX,l=e.clientY)}if(e._clicks=u,i[r]("mousedown",e),u>4)u=0;else if(u>1)return i[r](h[u],e)}Array.isArray(e)||(e=[e]),e.forEach((function(e){d(e,"mousedown",p,a)}))},t.getModifierString=function(e){return r.KEY_MODS[h(e)]},t.addCommandKeyListener=function(e,n,i){var l=null;d(e,"keydown",(function(e){a[e.keyCode]=(a[e.keyCode]||0)+1;var t=function(e,t,n){var i=h(t);if(!n&&t.code&&(n=r.$codeToKeyCode[t.code]||n),!o.isMac&&a){if(t.getModifierState&&(t.getModifierState("OS")||t.getModifierState("Win"))&&(i|=8),a.altGr){if(!(3&~i))return;a.altGr=0}if(18===n||17===n){var l=t.location;17===n&&1===l?1==a[n]&&(s=t.timeStamp):18===n&&3===i&&2===l&&t.timeStamp-s<50&&(a.altGr=!0)}}if(n in r.MODIFIER_KEYS&&(n=-1),i||13!==n||3!==t.location||(e(t,i,-n),!t.defaultPrevented)){if(o.isChromeOS&&8&i){if(e(t,i,n),t.defaultPrevented)return;i&=-9}return!!(i||n in r.FUNCTION_KEYS||n in r.PRINTABLE_KEYS)&&e(t,i,n)}}(n,e,e.keyCode);return l=e.defaultPrevented,t}),i),d(e,"keypress",(function(e){l&&(e.ctrlKey||e.altKey||e.shiftKey||e.metaKey)&&(t.stopEvent(e),l=null)}),i),d(e,"keyup",(function(e){a[e.keyCode]=null}),i),a||(p(),d(window,"focus",p))},"object"==typeof window&&window.postMessage&&!o.isOldIE){var g=1;t.nextTick=function(e,n){n=n||window;var i="zero-timeout-message-"+g++,r=function(o){o.data==i&&(t.stopPropagation(o),u(n,"message",r),e())};d(n,"message",r),n.postMessage(i,"*")}}t.$idleBlocked=!1,t.onIdle=function(e,n){return setTimeout((function n(){t.$idleBlocked?setTimeout(n,100):e()}),n)},t.$idleBlockId=null,t.blockIdle=function(e){t.$idleBlockId&&clearTimeout(t.$idleBlockId),t.$idleBlocked=!0,t.$idleBlockId=setTimeout((function(){t.$idleBlocked=!1}),e||100)},t.nextFrame="object"==typeof window&&(window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame),t.nextFrame?t.nextFrame=t.nextFrame.bind(window):t.nextFrame=function(e){setTimeout(e,17)}})),ace.define("ace/clipboard",["require","exports","module"],(function(e,t,n){"use strict";var i;n.exports={lineMode:!1,pasteCancelled:function(){return!!(i&&i>Date.now()-50)||(i=!1)},cancel:function(){i=Date.now()}}})),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/config","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/clipboard","ace/lib/keys"],(function(e,t,n){"use strict";var i,r=e("../lib/event"),o=e("../config").nls,a=e("../lib/useragent"),s=e("../lib/dom"),l=e("../lib/lang"),c=e("../clipboard"),d=a.isChrome<18,u=a.isIE,h=a.isChrome>63,p=400,g=e("../lib/keys"),f=g.KEY_MODS,m=a.isIOS,y=m?/\s/:/\n/,v=a.isMobile;i=function(e,t){var n=s.createElement("textarea");n.className="ace_text-input",n.setAttribute("wrap","off"),n.setAttribute("autocorrect","off"),n.setAttribute("autocapitalize","off"),n.setAttribute("spellcheck","false"),n.style.opacity="0",e.insertBefore(n,e.firstChild);var i=!1,b=!1,w=!1,C=!1,x="";v||(n.style.fontSize="1px");var S=!1,_=!1,E="",k=0,$=0,M=0,T=Number.MAX_SAFE_INTEGER,A=Number.MIN_SAFE_INTEGER,L=0;try{var R=document.activeElement===n}catch(e){}this.setNumberOfExtraLines=function(e){T=Number.MAX_SAFE_INTEGER,A=Number.MIN_SAFE_INTEGER,L=e<0?0:e},this.setAriaLabel=function(){var e="";if(t.$textInputAriaLabel&&(e+="".concat(t.$textInputAriaLabel,", ")),t.session){var i=t.session.selection.cursor.row;e+=o("text-input.aria-label","Cursor at row $0",[i+1])}n.setAttribute("aria-label",e)},this.setAriaOptions=function(e){e.activeDescendant?(n.setAttribute("aria-haspopup","true"),n.setAttribute("aria-autocomplete",e.inline?"both":"list"),n.setAttribute("aria-activedescendant",e.activeDescendant)):(n.setAttribute("aria-haspopup","false"),n.setAttribute("aria-autocomplete","both"),n.removeAttribute("aria-activedescendant")),e.role&&n.setAttribute("role",e.role),e.setLabel&&(n.setAttribute("aria-roledescription",o("text-input.aria-roledescription","editor")),this.setAriaLabel())},this.setAriaOptions({role:"textbox"}),r.addListener(n,"blur",(function(e){_||(t.onBlur(e),R=!1)}),t),r.addListener(n,"focus",(function(e){if(!_){if(R=!0,a.isEdge)try{if(!document.hasFocus())return}catch(e){}t.onFocus(e),a.isEdge?setTimeout(I):I()}}),t),this.$focusScroll=!1,this.focus=function(){if(this.setAriaOptions({setLabel:t.renderer.enableKeyboardAccessibility}),x||h||"browser"==this.$focusScroll)return n.focus({preventScroll:!0});var e=n.style.top;n.style.position="fixed",n.style.top="0px";try{var i=0!=n.getBoundingClientRect().top}catch(e){return}var r=[];if(i)for(var o=n.parentElement;o&&1==o.nodeType;)r.push(o),o.setAttribute("ace_nocontext","true"),o=!o.parentElement&&o.getRootNode?o.getRootNode().host:o.parentElement;n.focus({preventScroll:!0}),i&&r.forEach((function(e){e.removeAttribute("ace_nocontext")})),setTimeout((function(){n.style.position="","0px"==n.style.top&&(n.style.top=e)}),0)},this.blur=function(){n.blur()},this.isFocused=function(){return R},t.on("beforeEndOperation",(function(){var e=t.curOp,i=e&&e.command&&e.command.name;if("insertstring"!=i){var r=i&&(e.docChanged||e.selectionChanged);w&&r&&(E=n.value="",V()),I()}})),t.on("changeSelection",this.setAriaLabel);var O=function(e,n){for(var i=n,r=1;r<=e-T&&r<2*L+1;r++)i+=t.session.getLine(e-r).length+1;return i},I=m?function(e){if(R&&(!i||e)&&!C){e||(e="");var r="\n ab"+e+"cde fg\n";r!=n.value&&(n.value=E=r);var o=4+(e.length||(t.selection.isEmpty()?0:1));4==k&&$==o||n.setSelectionRange(4,o),k=4,$=o}}:function(){if(!w&&!C&&(R||N)){w=!0;var e=0,i=0,r="";if(t.session){var o=t.selection,a=o.getRange(),s=o.cursor.row;s===A+1?A=(T=A+1)+2*L:s===T-1?T=(A=T-1)-2*L:(s<T-1||s>A+1)&&(T=s>L?s-L:0,A=s>L?s+L:2*L);for(var l=[],c=T;c<=A;c++)l.push(t.session.getLine(c));if(r=l.join("\n"),e=O(a.start.row,a.start.column),i=O(a.end.row,a.end.column),a.start.row<T){var d=t.session.getLine(T-1);e=a.start.row<T-1?0:e,i+=d.length+1,r=d+"\n"+r}else if(a.end.row>A){var u=t.session.getLine(A+1);i=a.end.row>A+1?u.length:a.end.column,i+=r.length+1,r=r+"\n"+u}else v&&s>0&&(r="\n"+r,i+=1,e+=1);r.length>p&&(e<p&&i<p?r=r.slice(0,p):(r="\n",e==i?e=i=0:(e=0,i=1)));var h=r+"\n\n";h!=E&&(n.value=E=h,k=$=h.length)}if(N&&(k=n.selectionStart,$=n.selectionEnd),$!=i||k!=e||n.selectionEnd!=$)try{n.setSelectionRange(e,i),k=e,$=i}catch(e){}w=!1}};this.resetSelection=I,R&&t.onFocus();var P=null;this.setInputHandler=function(e){P=e},this.getInputHandler=function(){return P};var N=!1,D=function(e,i){if(N&&(N=!1),b)return I(),e&&t.onPaste(e),b=!1,"";for(var r=n.selectionStart,o=n.selectionEnd,s=k,l=E.length-$,c=e,d=e.length-r,u=e.length-o,h=0;s>0&&E[h]==e[h];)h++,s--;for(c=c.slice(h),h=1;l>0&&E.length-h>k-1&&E[E.length-h]==e[e.length-h];)h++,l--;d-=h-1,u-=h-1;var p=c.length-h+1;if(p<0&&(s=-p,p=0),c=c.slice(0,p),!(i||c||d||s||l||u))return"";C=!0;var g=!1;return a.isAndroid&&". "==c&&(c=" ",g=!0),c&&!s&&!l&&!d&&!u||S?t.onTextInput(c):t.onTextInput(c,{extendLeft:s,extendRight:l,restoreStart:d,restoreEnd:u}),C=!1,E=e,k=r,$=o,M=u,g?"\n":c},z=function(e){if(w)return G();if(e&&e.inputType){if("historyUndo"==e.inputType)return t.execCommand("undo");if("historyRedo"==e.inputType)return t.execCommand("redo")}var i=n.value,r=D(i,!0);(i.length>500||y.test(r)||v&&k<1&&k==$)&&I()},F=function(e,t,n){var i=e.clipboardData||window.clipboardData;if(i&&!d){var r=u||n?"Text":"text/plain";try{return t?!1!==i.setData(r,t):i.getData(r)}catch(e){if(!n)return F(e,t,!0)}}},B=function(e,o){var a=t.getCopyText();if(!a)return r.preventDefault(e);F(e,a)?(m&&(I(a),i=a,setTimeout((function(){i=!1}),10)),o?t.onCut():t.onCopy(),r.preventDefault(e)):(i=!0,n.value=a,n.select(),setTimeout((function(){i=!1,I(),o?t.onCut():t.onCopy()})))},H=function(e){B(e,!0)},W=function(e){B(e,!1)},j=function(e){var i=F(e);c.pasteCancelled()||("string"==typeof i?(i&&t.onPaste(i,e),a.isIE&&setTimeout(I),r.preventDefault(e)):(n.value="",b=!0))};r.addCommandKeyListener(n,(function(e,n,i){if(!w)return t.onCommandKey(e,n,i)}),t),r.addListener(n,"select",(function(e){w||(i?i=!1:function(e){return 0===e.selectionStart&&e.selectionEnd>=E.length&&e.value===E&&E&&e.selectionEnd!==$}(n)?(t.selectAll(),I()):v&&n.selectionStart!=k&&I())}),t),r.addListener(n,"input",z,t),r.addListener(n,"cut",H,t),r.addListener(n,"copy",W,t),r.addListener(n,"paste",j,t),"oncut"in n&&"oncopy"in n&&"onpaste"in n||r.addListener(e,"keydown",(function(e){if((!a.isMac||e.metaKey)&&e.ctrlKey)switch(e.keyCode){case 67:W(e);break;case 86:j(e);break;case 88:H(e)}}),t);var G=function(){if(w&&t.onCompositionUpdate&&!t.$readOnly){if(S)return U();if(w.useTextareaForIME)t.onCompositionUpdate(n.value);else{var e=n.value;D(e),w.markerRange&&(w.context&&(w.markerRange.start.column=w.selectionStart=w.context.compositionStartOffset),w.markerRange.end.column=w.markerRange.start.column+$-w.selectionStart+M)}}},V=function(e){t.onCompositionEnd&&!t.$readOnly&&(w=!1,t.onCompositionEnd(),t.off("mousedown",U),e&&z())};function U(){_=!0,n.blur(),n.focus(),_=!1}var K,Y=l.delayedCall(G,50).schedule.bind(null,null);function q(){clearTimeout(K),K=setTimeout((function(){x&&(n.style.cssText=x,x=""),t.renderer.$isMousePressed=!1,t.renderer.$keepTextAreaAtCursor&&t.renderer.$moveTextAreaToCursor()}),0)}r.addListener(n,"compositionstart",(function(e){if(!w&&t.onCompositionStart&&!t.$readOnly&&(w={},!S)){e.data&&(w.useTextareaForIME=!1),setTimeout(G,0),t._signal("compositionStart"),t.on("mousedown",U);var i=t.getSelectionRange();i.end.row=i.start.row,i.end.column=i.start.column,w.markerRange=i,w.selectionStart=k,t.onCompositionStart(w),w.useTextareaForIME?(E=n.value="",k=0,$=0):(n.msGetInputContext&&(w.context=n.msGetInputContext()),n.getInputContext&&(w.context=n.getInputContext()))}}),t),r.addListener(n,"compositionupdate",G,t),r.addListener(n,"keyup",(function(e){27==e.keyCode&&n.value.length<n.selectionStart&&(w||(E=n.value),k=$=-1,I()),Y()}),t),r.addListener(n,"keydown",Y,t),r.addListener(n,"compositionend",V,t),this.getElement=function(){return n},this.setCommandMode=function(e){S=e,n.readOnly=!1},this.setReadOnly=function(e){S||(n.readOnly=e)},this.setCopyWithEmptySelection=function(e){},this.onContextMenu=function(e){N=!0,I(),t._emit("nativecontextmenu",{target:t,domEvent:e}),this.moveToMouse(e,!0)},this.moveToMouse=function(e,i){x||(x=n.style.cssText),n.style.cssText=(i?"z-index:100000;":"")+(a.isIE?"opacity:0.1;":"")+"text-indent: -"+(k+$)*t.renderer.characterWidth*.5+"px;";var o=t.container.getBoundingClientRect(),l=s.computedStyle(t.container),c=o.top+(parseInt(l.borderTopWidth)||0),d=o.left+(parseInt(l.borderLeftWidth)||0),u=o.bottom-c-n.clientHeight-2,h=function(e){s.translate(n,e.clientX-d-2,Math.min(e.clientY-c-2,u))};h(e),"mousedown"==e.type&&(t.renderer.$isMousePressed=!0,clearTimeout(K),a.isWin&&r.capture(t.container,h,q))},this.onContextMenuClose=q;var Q=function(e){t.textInput.onContextMenu(e),q()};r.addListener(n,"mouseup",Q,t),r.addListener(n,"mousedown",(function(e){e.preventDefault(),q()}),t),r.addListener(t.renderer.scroller,"contextmenu",Q,t),r.addListener(n,"contextmenu",Q,t),m&&function(e,t,n){var r=null,o=!1;n.addEventListener("keydown",(function(e){r&&clearTimeout(r),o=!0}),!0),n.addEventListener("keyup",(function(e){r=setTimeout((function(){o=!1}),100)}),!0);var a=function(e){if(document.activeElement===n&&!(o||w||t.$mouseHandler.isMousePressed||i)){var r=n.selectionStart,a=n.selectionEnd,s=null,l=0;if(0==r?s=g.up:1==r?s=g.home:a>$&&"\n"==E[a]?s=g.end:r<k&&" "==E[r-1]?(s=g.left,l=f.option):r<k||r==k&&$!=k&&r==a?s=g.left:a>$&&E.slice(0,a).split("\n").length>2?s=g.down:a>$&&" "==E[a-1]?(s=g.right,l=f.option):(a>$||a==$&&$!=k&&r==a)&&(s=g.right),r!==a&&(l|=f.shift),s){if(!t.onCommandKey({},l,s)&&t.commands){s=g.keyCodeToString(s);var c=t.commands.findKeyCommand(l,s);c&&t.execCommand(c)}k=r,$=a,I("")}}};document.addEventListener("selectionchange",a),t.on("destroy",(function(){document.removeEventListener("selectionchange",a)}))}(0,t,n),this.destroy=function(){n.parentElement&&n.parentElement.removeChild(n)}},t.TextInput=i,t.$setUserAgentForTests=function(e,t){v=e,m=t}})),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/useragent"],(function(e,t,n){"use strict";var i=e("../lib/useragent"),r=function(){function e(e){e.$clickSelection=null;var t=e.editor;t.setDefaultHandler("mousedown",this.onMouseDown.bind(e)),t.setDefaultHandler("dblclick",this.onDoubleClick.bind(e)),t.setDefaultHandler("tripleclick",this.onTripleClick.bind(e)),t.setDefaultHandler("quadclick",this.onQuadClick.bind(e)),t.setDefaultHandler("mousewheel",this.onMouseWheel.bind(e)),["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"].forEach((function(t){e[t]=this[t]}),this),e.selectByLines=this.extendSelectionBy.bind(e,"getLineRange"),e.selectByWords=this.extendSelectionBy.bind(e,"getWordRange")}return e.prototype.onMouseDown=function(e){var t=e.inSelection(),n=e.getDocumentPosition();this.mousedownEvent=e;var r=this.editor,o=e.getButton();return 0!==o?((r.getSelectionRange().isEmpty()||1==o)&&r.selection.moveToPosition(n),void(2==o&&(r.textInput.onContextMenu(e.domEvent),i.isMozilla||e.preventDefault()))):(this.mousedownEvent.time=Date.now(),!t||r.isFocused()||(r.focus(),!this.$focusTimeout||this.$clickSelection||r.inMultiSelectMode)?(this.captureMouse(e),this.startSelect(n,e.domEvent._clicks>1),e.preventDefault()):(this.setState("focusWait"),void this.captureMouse(e)))},e.prototype.startSelect=function(e,t){e=e||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var n=this.editor;this.mousedownEvent&&(this.mousedownEvent.getShiftKey()?n.selection.selectToPosition(e):t||n.selection.moveToPosition(e),t||this.select(),n.setStyle("ace_selecting"),this.setState("select"))},e.prototype.select=function(){var e,t=this.editor,n=t.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var i=this.$clickSelection.comparePoint(n);if(-1==i)e=this.$clickSelection.end;else if(1==i)e=this.$clickSelection.start;else{var r=o(this.$clickSelection,n);n=r.cursor,e=r.anchor}t.selection.setSelectionAnchor(e.row,e.column)}t.selection.selectToPosition(n),t.renderer.scrollCursorIntoView()},e.prototype.extendSelectionBy=function(e){var t,n=this.editor,i=n.renderer.screenToTextCoordinates(this.x,this.y),r=n.selection[e](i.row,i.column);if(this.$clickSelection){var a=this.$clickSelection.comparePoint(r.start),s=this.$clickSelection.comparePoint(r.end);if(-1==a&&s<=0)t=this.$clickSelection.end,r.end.row==i.row&&r.end.column==i.column||(i=r.start);else if(1==s&&a>=0)t=this.$clickSelection.start,r.start.row==i.row&&r.start.column==i.column||(i=r.end);else if(-1==a&&1==s)i=r.end,t=r.start;else{var l=o(this.$clickSelection,i);i=l.cursor,t=l.anchor}n.selection.setSelectionAnchor(t.row,t.column)}n.selection.selectToPosition(i),n.renderer.scrollCursorIntoView()},e.prototype.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting")},e.prototype.focusWait=function(){var e,t,n,i,r=(e=this.mousedownEvent.x,t=this.mousedownEvent.y,n=this.x,i=this.y,Math.sqrt(Math.pow(n-e,2)+Math.pow(i-t,2))),o=Date.now();(r>0||o-this.mousedownEvent.time>this.$focusTimeout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},e.prototype.onDoubleClick=function(e){var t=e.getDocumentPosition(),n=this.editor,i=n.session.getBracketRange(t);i?(i.isEmpty()&&(i.start.column--,i.end.column++),this.setState("select")):(i=n.selection.getWordRange(t.row,t.column),this.setState("selectByWords")),this.$clickSelection=i,this.select()},e.prototype.onTripleClick=function(e){var t=e.getDocumentPosition(),n=this.editor;this.setState("selectByLines");var i=n.getSelectionRange();i.isMultiLine()&&i.contains(t.row,t.column)?(this.$clickSelection=n.selection.getLineRange(i.start.row),this.$clickSelection.end=n.selection.getLineRange(i.end.row).end):this.$clickSelection=n.selection.getLineRange(t.row),this.select()},e.prototype.onQuadClick=function(e){var t=this.editor;t.selectAll(),this.$clickSelection=t.getSelectionRange(),this.setState("selectAll")},e.prototype.onMouseWheel=function(e){if(!e.getAccelKey()){e.getShiftKey()&&e.wheelY&&!e.wheelX&&(e.wheelX=e.wheelY,e.wheelY=0);var t=this.editor;this.$lastScroll||(this.$lastScroll={t:0,vx:0,vy:0,allowed:0});var n=this.$lastScroll,i=e.domEvent.timeStamp,r=i-n.t,o=r?e.wheelX/r:n.vx,a=r?e.wheelY/r:n.vy;r<550&&(o=(o+n.vx)/2,a=(a+n.vy)/2);var s=Math.abs(o/a),l=!1;return s>=1&&t.renderer.isScrollableBy(e.wheelX*e.speed,0)&&(l=!0),s<=1&&t.renderer.isScrollableBy(0,e.wheelY*e.speed)&&(l=!0),l?n.allowed=i:i-n.allowed<550&&(Math.abs(o)<=1.5*Math.abs(n.vx)&&Math.abs(a)<=1.5*Math.abs(n.vy)?(l=!0,n.allowed=i):n.allowed=0),n.t=i,n.vx=o,n.vy=a,l?(t.renderer.scrollBy(e.wheelX*e.speed,e.wheelY*e.speed),e.stop()):void 0}},e}();function o(e,t){if(e.start.row==e.end.row)var n=2*t.column-e.start.column-e.end.column;else if(e.start.row!=e.end.row-1||e.start.column||e.end.column)n=2*t.row-e.start.row-e.end.row;else n=t.column-4;return n<0?{cursor:e.start,anchor:e.end}:{cursor:e.end,anchor:e.start}}r.prototype.selectEnd=r.prototype.selectByLinesEnd,r.prototype.selectAllEnd=r.prototype.selectByLinesEnd,r.prototype.selectByWordsEnd=r.prototype.selectByLinesEnd,t.DefaultHandlers=r})),ace.define("ace/lib/scroll",["require","exports","module"],(function(e,t,n){t.preventParentScroll=function(e){e.stopPropagation();var t=e.currentTarget;t.scrollHeight>t.clientHeight||e.preventDefault()}})),ace.define("ace/tooltip",["require","exports","module","ace/lib/dom","ace/lib/event","ace/range","ace/lib/scroll"],(function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},a=e("./lib/dom"),s=(e("./lib/event"),e("./range").Range),l=e("./lib/scroll").preventParentScroll,c="ace_tooltip",d=function(){function e(e){this.isOpen=!1,this.$element=null,this.$parentNode=e}return e.prototype.$init=function(){return this.$element=a.createElement("div"),this.$element.className=c,this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},e.prototype.getElement=function(){return this.$element||this.$init()},e.prototype.setText=function(e){this.getElement().textContent=e},e.prototype.setHtml=function(e){this.getElement().innerHTML=e},e.prototype.setPosition=function(e,t){this.getElement().style.left=e+"px",this.getElement().style.top=t+"px"},e.prototype.setClassName=function(e){a.addCssClass(this.getElement(),e)},e.prototype.setTheme=function(e){this.$element.className=c+" "+(e.isDark?"ace_dark ":"")+(e.cssClass||"")},e.prototype.show=function(e,t,n){null!=e&&this.setText(e),null!=t&&null!=n&&this.setPosition(t,n),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},e.prototype.hide=function(e){this.isOpen&&(this.getElement().style.display="none",this.getElement().className=c,this.isOpen=!1)},e.prototype.getHeight=function(){return this.getElement().offsetHeight},e.prototype.getWidth=function(){return this.getElement().offsetWidth},e.prototype.destroy=function(){this.isOpen=!1,this.$element&&this.$element.parentNode&&this.$element.parentNode.removeChild(this.$element)},e}(),u=new(function(){function e(){this.popups=[]}return e.prototype.addPopup=function(e){this.popups.push(e),this.updatePopups()},e.prototype.removePopup=function(e){var t=this.popups.indexOf(e);-1!==t&&(this.popups.splice(t,1),this.updatePopups())},e.prototype.updatePopups=function(){var e,t,n,i;this.popups.sort((function(e,t){return t.priority-e.priority}));var r=[];try{for(var a=o(this.popups),s=a.next();!s.done;s=a.next()){var l=s.value,c=!0;try{for(var d=(n=void 0,o(r)),u=d.next();!u.done;u=d.next()){var h=u.value;if(this.doPopupsOverlap(h,l)){c=!1;break}}}catch(e){n={error:e}}finally{try{u&&!u.done&&(i=d.return)&&i.call(d)}finally{if(n)throw n.error}}c?r.push(l):l.hide()}}catch(t){e={error:t}}finally{try{s&&!s.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}},e.prototype.doPopupsOverlap=function(e,t){var n=e.getElement().getBoundingClientRect(),i=t.getElement().getBoundingClientRect();return n.left<i.right&&n.right>i.left&&n.top<i.bottom&&n.bottom>i.top},e}());t.popupManager=u,t.Tooltip=d;var h=function(e){function t(t){void 0===t&&(t=document.body);var n=e.call(this,t)||this;n.timeout=void 0,n.lastT=0,n.idleTime=350,n.lastEvent=void 0,n.onMouseOut=n.onMouseOut.bind(n),n.onMouseMove=n.onMouseMove.bind(n),n.waitForHover=n.waitForHover.bind(n),n.hide=n.hide.bind(n);var i=n.getElement();return i.style.whiteSpace="pre-wrap",i.style.pointerEvents="auto",i.addEventListener("mouseout",n.onMouseOut),i.tabIndex=-1,i.addEventListener("blur",function(){i.contains(document.activeElement)||this.hide()}.bind(n)),i.addEventListener("wheel",l),n}return r(t,e),t.prototype.addToEditor=function(e){e.on("mousemove",this.onMouseMove),e.on("mousedown",this.hide),e.renderer.getMouseEventTarget().addEventListener("mouseout",this.onMouseOut,!0)},t.prototype.removeFromEditor=function(e){e.off("mousemove",this.onMouseMove),e.off("mousedown",this.hide),e.renderer.getMouseEventTarget().removeEventListener("mouseout",this.onMouseOut,!0),this.timeout&&(clearTimeout(this.timeout),this.timeout=null)},t.prototype.onMouseMove=function(e,t){this.lastEvent=e,this.lastT=Date.now();var n=t.$mouseHandler.isMousePressed;if(this.isOpen){var i=this.lastEvent&&this.lastEvent.getDocumentPosition();this.range&&this.range.contains(i.row,i.column)&&!n&&!this.isOutsideOfText(this.lastEvent)||this.hide()}this.timeout||n||(this.lastEvent=e,this.timeout=setTimeout(this.waitForHover,this.idleTime))},t.prototype.waitForHover=function(){this.timeout&&clearTimeout(this.timeout);var e=Date.now()-this.lastT;this.idleTime-e>10?this.timeout=setTimeout(this.waitForHover,this.idleTime-e):(this.timeout=null,this.lastEvent&&!this.isOutsideOfText(this.lastEvent)&&this.$gatherData(this.lastEvent,this.lastEvent.editor))},t.prototype.isOutsideOfText=function(e){var t=e.editor,n=e.getDocumentPosition(),i=t.session.getLine(n.row);if(n.column==i.length){var r=t.renderer.pixelToScreenCoordinates(e.clientX,e.clientY),o=t.session.documentToScreenPosition(n.row,n.column);if(o.column!=r.column||o.row!=r.row)return!0}return!1},t.prototype.setDataProvider=function(e){this.$gatherData=e},t.prototype.showForRange=function(e,t,n,i){if(!(i&&i!=this.lastEvent||this.isOpen&&document.activeElement==this.getElement())){var r=e.renderer;this.isOpen||(u.addPopup(this),this.$registerCloseEvents(),this.setTheme(r.theme)),this.isOpen=!0,this.addMarker(t,e.session),this.range=s.fromPoints(t.start,t.end);var o=r.textToScreenCoordinates(t.start.row,t.start.column),a=r.scroller.getBoundingClientRect();o.pageX<a.left&&(o.pageX=a.left);var l=this.getElement();l.innerHTML="",l.appendChild(n),l.style.maxHeight="",l.style.display="block";var c=l.clientHeight,d=l.clientWidth,h=window.innerHeight-o.pageY-r.lineHeight,p=!0;o.pageY-c<0&&o.pageY<h&&(p=!1),l.style.maxHeight=(p?o.pageY:h)-10+"px",l.style.top=p?"":o.pageY+r.lineHeight+"px",l.style.bottom=p?window.innerHeight-o.pageY+"px":"",l.style.left=Math.min(o.pageX,window.innerWidth-d-10)+"px"}},t.prototype.addMarker=function(e,t){this.marker&&this.$markerSession.removeMarker(this.marker),this.$markerSession=t,this.marker=t&&t.addMarker(e,"ace_highlight-marker","text")},t.prototype.hide=function(e){(e||document.activeElement!=this.getElement())&&(e&&e.target&&("keydown"!=e.type||e.ctrlKey||e.metaKey)&&this.$element.contains(e.target)||(this.lastEvent=null,this.timeout&&clearTimeout(this.timeout),this.timeout=null,this.addMarker(null),this.isOpen&&(this.$removeCloseEvents(),this.getElement().style.display="none",this.isOpen=!1,u.removePopup(this))))},t.prototype.$registerCloseEvents=function(){window.addEventListener("keydown",this.hide,!0),window.addEventListener("wheel",this.hide,!0),window.addEventListener("mousedown",this.hide,!0)},t.prototype.$removeCloseEvents=function(){window.removeEventListener("keydown",this.hide,!0),window.removeEventListener("wheel",this.hide,!0),window.removeEventListener("mousedown",this.hide,!0)},t.prototype.onMouseOut=function(e){this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.lastEvent=null,this.isOpen&&e.relatedTarget&&!this.getElement().contains(e.relatedTarget)&&(e&&e.currentTarget.contains(e.relatedTarget)||e.relatedTarget.classList.contains("ace_content")||this.hide())},t}(d);t.HoverTooltip=h})),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/tooltip","ace/config"],(function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},a=e("../lib/dom"),s=e("../lib/event"),l=e("../tooltip").Tooltip,c=e("../config").nls;t.GUTTER_TOOLTIP_LEFT_OFFSET=5,t.GUTTER_TOOLTIP_TOP_OFFSET=3,t.GutterHandler=function(e){var t,n,i=e.editor,r=i.renderer.$gutterLayer,o=new d(i,!0);function l(e){e&&"keydown"===e.type&&(e.ctrlKey||e.metaKey)||(!e||"mouseout"!==e.type||e.relatedTarget&&!o.getElement().contains(e.relatedTarget))&&(t&&(t=clearTimeout(t)),o.isOpen&&(o.hideTooltip(),i.off("mousewheel",l),i.off("changeSession",l),window.removeEventListener("keydown",l,!0)))}function c(e){o.setPosition(e.x,e.y)}e.editor.setDefaultHandler("guttermousedown",(function(t){if(i.isFocused()&&0==t.getButton()&&"foldWidgets"!=r.getRegion(t)){var n=t.getDocumentPosition().row,o=i.session.selection;if(t.getShiftKey())o.selectTo(n,0);else{if(2==t.domEvent.detail)return i.selectAll(),t.preventDefault();e.$clickSelection=i.selection.getLineRange(n)}return e.setState("selectByLines"),e.captureMouse(t),t.preventDefault()}})),e.editor.setDefaultHandler("guttermousemove",(function(s){var d=s.domEvent.target||s.domEvent.srcElement;if(a.hasCssClass(d,"ace_fold-widget"))return l();o.isOpen&&e.$tooltipFollowsMouse&&c(s),n=s,t||(t=setTimeout((function(){t=null,n&&!e.isMousePressed&&function(){var t=n.getDocumentPosition().row;if(t==i.session.getLength()){var a=i.renderer.pixelToScreenCoordinates(0,n.y).row,s=n.$pos;if(a>i.session.documentToScreenRow(s.row,s.column))return l()}if(o.showTooltip(t),o.isOpen)if(i.on("mousewheel",l),i.on("changeSession",l),window.addEventListener("keydown",l,!0),e.$tooltipFollowsMouse)c(n);else{var d=n.getGutterRow(),u=r.$lines.get(d);if(u){var h=u.element.querySelector(".ace_gutter_annotation").getBoundingClientRect(),p=o.getElement().style;p.left=h.right-5+"px",p.top=h.bottom-3+"px"}else c(n)}}()}),50))})),s.addListener(i.renderer.$gutter,"mouseout",(function(e){n=null,o.isOpen&&(t=setTimeout((function(){t=null,l(e)}),50))}),i)};var d=function(e){function t(t,n){void 0===n&&(n=!1);var i=e.call(this,t.container)||this;i.editor=t,i.visibleTooltipRow;var r=i.getElement();return r.setAttribute("role","tooltip"),r.style.pointerEvents="auto",n&&(i.onMouseOut=i.onMouseOut.bind(i),r.addEventListener("mouseout",i.onMouseOut)),i}return r(t,e),t.prototype.onMouseOut=function(e){this.isOpen&&e.relatedTarget&&!this.getElement().contains(e.relatedTarget)&&(e&&e.currentTarget.contains(e.relatedTarget)||this.hideTooltip())},t.prototype.setPosition=function(e,t){var n=window.innerWidth||document.documentElement.clientWidth,i=window.innerHeight||document.documentElement.clientHeight,r=this.getWidth(),o=this.getHeight();(e+=15)+r>n&&(e-=e+r-n),(t+=15)+o>i&&(t-=20+o),l.prototype.setPosition.call(this,e,t)},Object.defineProperty(t,"annotationLabels",{get:function(){return{error:{singular:c("gutter-tooltip.aria-label.error.singular","error"),plural:c("gutter-tooltip.aria-label.error.plural","errors")},security:{singular:c("gutter-tooltip.aria-label.security.singular","security finding"),plural:c("gutter-tooltip.aria-label.security.plural","security findings")},warning:{singular:c("gutter-tooltip.aria-label.warning.singular","warning"),plural:c("gutter-tooltip.aria-label.warning.plural","warnings")},info:{singular:c("gutter-tooltip.aria-label.info.singular","information message"),plural:c("gutter-tooltip.aria-label.info.plural","information messages")},hint:{singular:c("gutter-tooltip.aria-label.hint.singular","suggestion"),plural:c("gutter-tooltip.aria-label.hint.plural","suggestions")}}},enumerable:!1,configurable:!0}),t.prototype.showTooltip=function(e){var n,i,r=this.editor.renderer.$gutterLayer,o=r.$annotations[e];i=o?{displayText:Array.from(o.displayText),type:Array.from(o.type)}:{displayText:[],type:[]};var s=r.session.getFoldLine(e);if(s&&r.$showFoldedAnnotations){for(var l,c={error:[],security:[],warning:[],info:[],hint:[]},d={error:1,security:2,warning:3,info:4,hint:5},u=e+1;u<=s.end.row;u++)if(r.$annotations[u])for(var h=0;h<r.$annotations[u].text.length;h++){var p=r.$annotations[u].type[h];c[p].push(r.$annotations[u].text[h]),(!l||d[p]<d[l])&&(l=p)}if(["error","security","warning"].includes(l)){var g="".concat(t.annotationsToSummaryString(c)," in folded code.");i.displayText.push(g),i.type.push(l+"_fold")}}if(0===i.displayText.length)return this.hideTooltip();var f={error:[],security:[],warning:[],info:[],hint:[]},m=r.$useSvgGutterIcons?"ace_icon_svg":"ace_icon";for(u=0;u<i.displayText.length;u++){var y=a.createElement("span"),v=a.createElement("span");(n=v.classList).add.apply(n,["ace_".concat(i.type[u]),m]),v.setAttribute("aria-label","".concat(t.annotationLabels[i.type[u].replace("_fold","")].singular)),v.setAttribute("role","img"),v.appendChild(a.createTextNode(" ")),y.appendChild(v),y.appendChild(a.createTextNode(i.displayText[u])),y.appendChild(a.createElement("br")),f[i.type[u].replace("_fold","")].push(y)}var b=this.getElement();a.removeChildren(b),f.error.forEach((function(e){return b.appendChild(e)})),f.security.forEach((function(e){return b.appendChild(e)})),f.warning.forEach((function(e){return b.appendChild(e)})),f.info.forEach((function(e){return b.appendChild(e)})),f.hint.forEach((function(e){return b.appendChild(e)})),b.setAttribute("aria-live","polite"),this.isOpen||(this.setTheme(this.editor.renderer.theme),this.setClassName("ace_gutter-tooltip")),this.show(),this.visibleTooltipRow=e,this.editor._signal("showGutterTooltip",this)},t.prototype.hideTooltip=function(){this.isOpen&&(this.$element.removeAttribute("aria-live"),this.hide(),this.visibleTooltipRow=void 0,this.editor._signal("hideGutterTooltip",this))},t.annotationsToSummaryString=function(e){var n,i,r=[];try{for(var a=o(["error","security","warning","info","hint"]),s=a.next();!s.done;s=a.next()){var l=s.value;if(e[l].length){var c=1===e[l].length?t.annotationLabels[l].singular:t.annotationLabels[l].plural;r.push("".concat(e[l].length," ").concat(c))}}}catch(e){n={error:e}}finally{try{s&&!s.done&&(i=a.return)&&i.call(a)}finally{if(n)throw n.error}}return r.join(", ")},t}(l);t.GutterTooltip=d})),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],(function(e,t,n){"use strict";var i=e("../lib/event"),r=e("../lib/useragent"),o=function(){function e(e,t){this.speed,this.wheelX,this.wheelY,this.domEvent=e,this.editor=t,this.x=this.clientX=e.clientX,this.y=this.clientY=e.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1}return e.prototype.stopPropagation=function(){i.stopPropagation(this.domEvent),this.propagationStopped=!0},e.prototype.preventDefault=function(){i.preventDefault(this.domEvent),this.defaultPrevented=!0},e.prototype.stop=function(){this.stopPropagation(),this.preventDefault()},e.prototype.getDocumentPosition=function(){return this.$pos||(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY)),this.$pos},e.prototype.getGutterRow=function(){var e=this.getDocumentPosition().row;return this.editor.session.documentToScreenRow(e,0)-this.editor.session.documentToScreenRow(this.editor.renderer.$gutterLayer.$lines.get(0).row,0)},e.prototype.inSelection=function(){if(null!==this.$inSelection)return this.$inSelection;var e=this.editor.getSelectionRange();if(e.isEmpty())this.$inSelection=!1;else{var t=this.getDocumentPosition();this.$inSelection=e.contains(t.row,t.column)}return this.$inSelection},e.prototype.getButton=function(){return i.getButton(this.domEvent)},e.prototype.getShiftKey=function(){return this.domEvent.shiftKey},e.prototype.getAccelKey=function(){return r.isMac?this.domEvent.metaKey:this.domEvent.ctrlKey},e}();t.MouseEvent=o})),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],(function(e,t,n){"use strict";var i=e("../lib/dom"),r=e("../lib/event"),o=e("../lib/useragent");function a(e){var t=e.editor,n=i.createElement("div");n.style.cssText="top:-100px;position:absolute;z-index:2147483647;opacity:0.5",n.textContent=" ",["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"].forEach((function(t){e[t]=this[t]}),this),t.on("mousedown",this.onMouseDown.bind(e));var a,l,c,d,u,h,p,g,f,m,y,v=t.container,b=0;function w(){var e=h;(function(e,n){var i=Date.now(),r=!n||e.row!=n.row,o=!n||e.column!=n.column;!m||r||o?(t.moveCursorToPosition(e),m=i,y={x:l,y:c}):s(y.x,y.y,l,c)>5?m=null:i-m>=200&&(t.renderer.scrollCursorIntoView(),m=null)})(h=t.renderer.screenToTextCoordinates(l,c),e),function(e,n){var i=Date.now(),r=t.renderer.layerConfig.lineHeight,o=t.renderer.layerConfig.characterWidth,a=t.renderer.scroller.getBoundingClientRect(),s={x:{left:l-a.left,right:a.right-l},y:{top:c-a.top,bottom:a.bottom-c}},d=Math.min(s.x.left,s.x.right),u=Math.min(s.y.top,s.y.bottom),h={row:e.row,column:e.column};d/o<=2&&(h.column+=s.x.left<s.x.right?-3:2),u/r<=1&&(h.row+=s.y.top<s.y.bottom?-1:1);var p=e.row!=h.row,g=e.column!=h.column,m=!n||e.row!=n.row;p||g&&!m?f?i-f>=200&&t.renderer.scrollCursorIntoView(h):f=i:f=null}(h,e)}function C(){u=t.selection.toOrientedRange(),a=t.session.addMarker(u,"ace_selection",t.getSelectionStyle()),t.clearSelection(),t.isFocused()&&t.renderer.$cursorLayer.setBlinking(!1),clearInterval(d),w(),d=setInterval(w,20),b=0,r.addListener(document,"mousemove",_)}function x(){clearInterval(d),t.session.removeMarker(a),a=null,t.selection.fromOrientedRange(u),t.isFocused()&&!g&&t.$resetCursorStyle(),u=null,h=null,b=0,f=null,m=null,r.removeListener(document,"mousemove",_)}this.onDragStart=function(e){if(this.cancelDrag||!v.draggable){var i=this;return setTimeout((function(){i.startSelect(),i.captureMouse(e)}),0),e.preventDefault()}u=t.getSelectionRange();var r=e.dataTransfer;r.effectAllowed=t.getReadOnly()?"copy":"copyMove",t.container.appendChild(n),r.setDragImage&&r.setDragImage(n,0,0),setTimeout((function(){t.container.removeChild(n)})),r.clearData(),r.setData("Text",t.session.getTextRange()),g=!0,this.setState("drag")},this.onDragEnd=function(e){if(v.draggable=!1,g=!1,this.setState(null),!t.getReadOnly()){var n=e.dataTransfer.dropEffect;p||"move"!=n||t.session.remove(t.getSelectionRange()),t.$resetCursorStyle()}this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle("")},this.onDragEnter=function(e){if(!t.getReadOnly()&&E(e.dataTransfer))return l=e.clientX,c=e.clientY,a||C(),b++,e.dataTransfer.dropEffect=p=k(e),r.preventDefault(e)},this.onDragOver=function(e){if(!t.getReadOnly()&&E(e.dataTransfer))return l=e.clientX,c=e.clientY,a||(C(),b++),null!==S&&(S=null),e.dataTransfer.dropEffect=p=k(e),r.preventDefault(e)},this.onDragLeave=function(e){if(--b<=0&&a)return x(),p=null,r.preventDefault(e)},this.onDrop=function(e){if(h){var n=e.dataTransfer;if(g)switch(p){case"move":u=u.contains(h.row,h.column)?{start:h,end:h}:t.moveText(u,h);break;case"copy":u=t.moveText(u,h,!0)}else{var i=n.getData("Text");u={start:h,end:t.session.insert(h,i)},t.focus(),p=null}return x(),r.preventDefault(e)}},r.addListener(v,"dragstart",this.onDragStart.bind(e),t),r.addListener(v,"dragend",this.onDragEnd.bind(e),t),r.addListener(v,"dragenter",this.onDragEnter.bind(e),t),r.addListener(v,"dragover",this.onDragOver.bind(e),t),r.addListener(v,"dragleave",this.onDragLeave.bind(e),t),r.addListener(v,"drop",this.onDrop.bind(e),t);var S=null;function _(){null==S&&(S=setTimeout((function(){null!=S&&a&&x()}),20))}function E(e){var t=e.types;return!t||Array.prototype.some.call(t,(function(e){return"text/plain"==e||"Text"==e}))}function k(e){var t=["copy","copymove","all","uninitialized"],n=o.isMac?e.altKey:e.ctrlKey,i="uninitialized";try{i=e.dataTransfer.effectAllowed.toLowerCase()}catch(e){}var r="none";return n&&t.indexOf(i)>=0?r="copy":["move","copymove","linkmove","all","uninitialized"].indexOf(i)>=0?r="move":t.indexOf(i)>=0&&(r="copy"),r}}function s(e,t,n,i){return Math.sqrt(Math.pow(n-e,2)+Math.pow(i-t,2))}(function(){this.dragWait=function(){Date.now()-this.mousedownEvent.time>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){this.editor.container.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(e){this.editor.$resetCursorStyle(),this.editor.unsetStyle("ace_dragging"),this.editor.renderer.setCursorStyle(""),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var e=this.editor;e.container.draggable=!0,e.renderer.$cursorLayer.setBlinking(!1),e.setStyle("ace_dragging");var t=o.isWin?"default":"move";e.renderer.setCursorStyle(t),this.setState("dragReady")},this.onMouseDrag=function(e){var t=this.editor.container;o.isIE&&"dragReady"==this.state&&s(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y)>3&&t.dragDrop(),"dragWait"===this.state&&s(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y)>0&&(t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))},this.onMouseDown=function(e){if(this.$dragEnabled){this.mousedownEvent=e;var t=this.editor,n=e.inSelection(),i=e.getButton();if(1===(e.domEvent.detail||1)&&0===i&&n){if(e.editor.inMultiSelectMode&&(e.getAccelKey()||e.getShiftKey()))return;this.mousedownEvent.time=Date.now();var r=e.domEvent.target||e.domEvent.srcElement;"unselectable"in r&&(r.unselectable="on"),t.getDragDelay()?(o.isWebKit&&(this.cancelDrag=!0,t.container.draggable=!0),this.setState("dragWait")):this.startDrag(),this.captureMouse(e,this.onMouseDrag.bind(this)),e.defaultPrevented=!0}}}}).call(a.prototype),t.DragdropHandler=a})),ace.define("ace/mouse/touch_handler",["require","exports","module","ace/mouse/mouse_event","ace/lib/event","ace/lib/dom"],(function(e,t,n){"use strict";var i=e("./mouse_event").MouseEvent,r=e("../lib/event"),o=e("../lib/dom");t.addTouchListeners=function(e,t){var n,a,s,l,c,d,u,h,p,g="scroll",f=0,m=0,y=0,v=0;function b(){if(t.getOption("enableMobileMenu")){p||(s=window.navigator&&window.navigator.clipboard,l=!1,c=function(e){return t.commands.canExecute(e,t)},d=function(e){var n,i,r=e.target.getAttribute("action");if("more"==r||!l)return l=!l,n=t.getCopyText(),i=t.session.getUndoManager().hasUndo(),void p.replaceChild(o.buildDom(l?["span",!n&&c("selectall")&&["span",{class:"ace_mobile-button",action:"selectall"},"Select All"],n&&c("copy")&&["span",{class:"ace_mobile-button",action:"copy"},"Copy"],n&&c("cut")&&["span",{class:"ace_mobile-button",action:"cut"},"Cut"],s&&c("paste")&&["span",{class:"ace_mobile-button",action:"paste"},"Paste"],i&&c("undo")&&["span",{class:"ace_mobile-button",action:"undo"},"Undo"],c("find")&&["span",{class:"ace_mobile-button",action:"find"},"Find"],c("openCommandPalette")&&["span",{class:"ace_mobile-button",action:"openCommandPalette"},"Palette"]]:["span"]),p.firstChild);"paste"==r?s.readText().then((function(e){t.execCommand(r,e)})):r&&("cut"!=r&&"copy"!=r||(s?s.writeText(t.getCopyText()):document.execCommand("copy")),t.execCommand(r)),p.firstChild.style.display="none",l=!1,"openCommandPalette"!=r&&t.focus()},p=o.buildDom(["div",{class:"ace_mobile-menu",ontouchstart:function(e){g="menu",e.stopPropagation(),e.preventDefault(),t.textInput.focus()},ontouchend:function(e){e.stopPropagation(),e.preventDefault(),d(e)},onclick:d},["span"],["span",{class:"ace_mobile-button",action:"more"},"..."]],t.container));var e=t.selection.cursor,n=t.renderer.textToScreenCoordinates(e.row,e.column),i=t.renderer.textToScreenCoordinates(0,0).pageX,r=t.renderer.scrollLeft,a=t.container.getBoundingClientRect();p.style.top=n.pageY-a.top-3+"px",n.pageX-a.left<a.width-70?(p.style.left="",p.style.right="10px"):(p.style.right="",p.style.left=i+r-a.left+"px"),p.style.display="",p.firstChild.style.display="none",t.on("input",w)}else p&&w();var s,l,c,d}function w(e){p&&(p.style.display="none"),t.off("input",w)}function C(){c=null,clearTimeout(c);var e=t.selection.getRange(),n=e.contains(u.row,u.column);!e.isEmpty()&&n||(t.selection.moveToPosition(u),t.selection.selectWord()),g="wait",b()}r.addListener(e,"contextmenu",(function(e){h&&t.textInput.getElement().focus()}),t),r.addListener(e,"touchstart",(function(e){var r=e.touches;if(c||r.length>1)return clearTimeout(c),c=null,s=-1,void(g="zoom");h=t.$mouseHandler.isMousePressed=!0;var o=t.renderer.layerConfig.lineHeight,d=t.renderer.layerConfig.lineHeight,p=e.timeStamp;l=p;var b=r[0],w=b.clientX,x=b.clientY;Math.abs(n-w)+Math.abs(a-x)>o&&(s=-1),n=e.clientX=w,a=e.clientY=x,y=v=0;var S=new i(e,t);if(u=S.getDocumentPosition(),p-s<500&&1==r.length&&!f)m++,e.preventDefault(),e.button=0,function(){c=null,clearTimeout(c),t.selection.moveToPosition(u);var e=m>=2?t.selection.getLineRange(u.row):t.session.getBracketRange(u);e&&!e.isEmpty()?t.selection.setRange(e):t.selection.selectWord(),g="wait"}();else{m=0;var _=t.selection.cursor,E=t.selection.isEmpty()?_:t.selection.anchor,k=t.renderer.$cursorLayer.getPixelPosition(_,!0),$=t.renderer.$cursorLayer.getPixelPosition(E,!0),M=t.renderer.scroller.getBoundingClientRect(),T=t.renderer.layerConfig.offset,A=t.renderer.scrollLeft,L=function(e,t){return(e/=d)*e+(t=t/o-.75)*t};if(e.clientX<M.left)return void(g="zoom");var R=L(e.clientX-M.left-k.left+A,e.clientY-M.top-k.top+T),O=L(e.clientX-M.left-$.left+A,e.clientY-M.top-$.top+T);R<3.5&&O<3.5&&(g=R>O?"cursor":"anchor"),g=O<3.5?"anchor":R<3.5?"cursor":"scroll",c=setTimeout(C,450)}s=p}),t),r.addListener(e,"touchend",(function(e){h=t.$mouseHandler.isMousePressed=!1,d&&clearInterval(d),"zoom"==g?(g="",f=0):c?(t.selection.moveToPosition(u),f=0,b()):"scroll"==g?(f+=60,d=setInterval((function(){f--<=0&&(clearInterval(d),d=null),Math.abs(y)<.01&&(y=0),Math.abs(v)<.01&&(v=0),f<20&&(y*=.9),f<20&&(v*=.9);var e=t.session.getScrollTop();t.renderer.scrollBy(10*y,10*v),e==t.session.getScrollTop()&&(f=0)}),10),w()):b(),clearTimeout(c),c=null}),t),r.addListener(e,"touchmove",(function(e){c&&(clearTimeout(c),c=null);var r=e.touches;if(!(r.length>1||"zoom"==g)){var o=r[0],s=n-o.clientX,d=a-o.clientY;if("wait"==g){if(!(s*s+d*d>4))return e.preventDefault();g="cursor"}n=o.clientX,a=o.clientY,e.clientX=o.clientX,e.clientY=o.clientY;var u=e.timeStamp,h=u-l;if(l=u,"scroll"==g){var p=new i(e,t);p.speed=1,p.wheelX=s,p.wheelY=d,10*Math.abs(s)<Math.abs(d)&&(s=0),10*Math.abs(d)<Math.abs(s)&&(d=0),0!=h&&(y=s/h,v=d/h),t._emit("mousewheel",p),p.propagationStopped||(y=v=0)}else{var f=new i(e,t).getDocumentPosition();"cursor"==g?t.selection.moveCursorToPosition(f):"anchor"==g&&t.selection.setSelectionAnchor(f.row,f.column),t.renderer.scrollCursorIntoView(f),e.preventDefault()}}}),t)}})),ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/mouse/touch_handler","ace/config"],(function(e,t,n){"use strict";var i=e("../lib/event"),r=e("../lib/useragent"),o=e("./default_handlers").DefaultHandlers,a=e("./default_gutter_handler").GutterHandler,s=e("./mouse_event").MouseEvent,l=e("./dragdrop_handler").DragdropHandler,c=e("./touch_handler").addTouchListeners,d=e("../config"),u=function(){function e(e){this.$dragDelay,this.$dragEnabled,this.$mouseMoved,this.mouseEvent,this.$focusTimeout;var t=this;this.editor=e,new o(this),new a(this),new l(this);var n=function(t){(!document.hasFocus||!document.hasFocus()||!e.isFocused()&&document.activeElement==(e.textInput&&e.textInput.getElement()))&&window.focus(),e.focus(),setTimeout((function(){e.isFocused()||e.focus()}))},s=e.renderer.getMouseEventTarget();i.addListener(s,"click",this.onMouseEvent.bind(this,"click"),e),i.addListener(s,"mousemove",this.onMouseMove.bind(this,"mousemove"),e),i.addMultiMouseDownListener([s,e.renderer.scrollBarV&&e.renderer.scrollBarV.inner,e.renderer.scrollBarH&&e.renderer.scrollBarH.inner,e.textInput&&e.textInput.getElement()].filter(Boolean),[400,300,250],this,"onMouseEvent",e),i.addMouseWheelListener(e.container,this.onMouseWheel.bind(this,"mousewheel"),e),c(e.container,e);var d=e.renderer.$gutter;i.addListener(d,"mousedown",this.onMouseEvent.bind(this,"guttermousedown"),e),i.addListener(d,"click",this.onMouseEvent.bind(this,"gutterclick"),e),i.addListener(d,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick"),e),i.addListener(d,"mousemove",this.onMouseEvent.bind(this,"guttermousemove"),e),i.addListener(s,"mousedown",n,e),i.addListener(d,"mousedown",n,e),r.isIE&&e.renderer.scrollBarV&&(i.addListener(e.renderer.scrollBarV.element,"mousedown",n,e),i.addListener(e.renderer.scrollBarH.element,"mousedown",n,e)),e.on("mousemove",(function(n){if(!t.state&&!t.$dragDelay&&t.$dragEnabled){var i=e.renderer.screenToTextCoordinates(n.x,n.y),r=e.session.selection.getRange(),o=e.renderer;!r.isEmpty()&&r.insideStart(i.row,i.column)?o.setCursorStyle("default"):o.setCursorStyle("")}}),e)}return e.prototype.onMouseEvent=function(e,t){this.editor.session&&this.editor._emit(e,new s(t,this.editor))},e.prototype.onMouseMove=function(e,t){var n=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;n&&n.length&&this.editor._emit(e,new s(t,this.editor))},e.prototype.onMouseWheel=function(e,t){var n=new s(t,this.editor);n.speed=2*this.$scrollSpeed,n.wheelX=t.wheelX,n.wheelY=t.wheelY,this.editor._emit(e,n)},e.prototype.setState=function(e){this.state=e},e.prototype.captureMouse=function(e,t){this.x=e.x,this.y=e.y,this.isMousePressed=!0;var n=this.editor,o=this.editor.renderer;o.$isMousePressed=!0;var a=this,l=function(e){if(e){if(r.isWebKit&&!e.which&&a.releaseMouse)return a.releaseMouse();a.x=e.clientX,a.y=e.clientY,t&&t(e),a.mouseEvent=new s(e,a.editor),a.$mouseMoved=!0}},c=function(e){n.off("beforeEndOperation",u),clearInterval(h),n.session&&d(),a[a.state+"End"]&&a[a.state+"End"](e),a.state="",a.isMousePressed=o.$isMousePressed=!1,o.$keepTextAreaAtCursor&&o.$moveTextAreaToCursor(),a.$onCaptureMouseMove=a.releaseMouse=null,e&&a.onMouseEvent("mouseup",e),n.endOperation()},d=function(){a[a.state]&&a[a.state](),a.$mouseMoved=!1};if(r.isOldIE&&"dblclick"==e.domEvent.type)return setTimeout((function(){c(e)}));var u=function(e){a.releaseMouse&&n.curOp.command.name&&n.curOp.selectionChanged&&(a[a.state+"End"]&&a[a.state+"End"](),a.state="",a.releaseMouse())};n.on("beforeEndOperation",u),n.startOperation({command:{name:"mouse"}}),a.$onCaptureMouseMove=l,a.releaseMouse=i.capture(this.editor.container,l,c);var h=setInterval(d,20)},e.prototype.cancelContextMenu=function(){var e=function(t){t&&t.domEvent&&"contextmenu"!=t.domEvent.type||(this.editor.off("nativecontextmenu",e),t&&t.domEvent&&i.stopEvent(t.domEvent))}.bind(this);setTimeout(e,10),this.editor.on("nativecontextmenu",e)},e.prototype.destroy=function(){this.releaseMouse&&this.releaseMouse()},e}();u.prototype.releaseMouse=null,d.defineOptions(u.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:r.isMac?150:0},dragEnabled:{initialValue:!0},focusTimeout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}}),t.MouseHandler=u})),ace.define("ace/mouse/fold_handler",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var i=e("../lib/dom");t.FoldHandler=function(e){e.on("click",(function(t){var n=t.getDocumentPosition(),r=e.session,o=r.getFoldAt(n.row,n.column,1);o&&(t.getAccelKey()?r.removeFold(o):r.expandFold(o),t.stop());var a=t.domEvent&&t.domEvent.target;a&&i.hasCssClass(a,"ace_inline_button")&&i.hasCssClass(a,"ace_toggle_wrap")&&(r.setOption("wrap",!r.getUseWrapMode()),e.renderer.scrollCursorIntoView())})),e.on("gutterclick",(function(t){if("foldWidgets"==e.renderer.$gutterLayer.getRegion(t)){var n=t.getDocumentPosition().row,i=e.session;i.foldWidgets&&i.foldWidgets[n]&&e.session.onFoldWidgetClick(n,t),e.isFocused()||e.focus(),t.stop()}})),e.on("gutterdblclick",(function(t){if("foldWidgets"==e.renderer.$gutterLayer.getRegion(t)){var n=t.getDocumentPosition().row,i=e.session,r=i.getParentFoldRangeData(n,!0),o=r.range||r.firstRange;if(o){n=o.start.row;var a=i.getFoldAt(n,i.getLine(n).length,1);a?i.removeFold(a):(i.addFold("...",o),e.renderer.scrollCursorIntoView({row:o.start.row,column:0}))}t.stop()}}))}})),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],(function(e,t,n){"use strict";var i=e("../lib/keys"),r=e("../lib/event"),o=function(){function e(e){this.$editor=e,this.$data={editor:e},this.$handlers=[],this.setDefaultHandler(e.commands)}return e.prototype.setDefaultHandler=function(e){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=e,this.addKeyboardHandler(e,0)},e.prototype.setKeyboardHandler=function(e){var t=this.$handlers;if(t[t.length-1]!=e){for(;t[t.length-1]&&t[t.length-1]!=this.$defaultHandler;)this.removeKeyboardHandler(t[t.length-1]);this.addKeyboardHandler(e,1)}},e.prototype.addKeyboardHandler=function(e,t){if(e){"function"!=typeof e||e.handleKeyboard||(e.handleKeyboard=e);var n=this.$handlers.indexOf(e);-1!=n&&this.$handlers.splice(n,1),null==t?this.$handlers.push(e):this.$handlers.splice(t,0,e),-1==n&&e.attach&&e.attach(this.$editor)}},e.prototype.removeKeyboardHandler=function(e){var t=this.$handlers.indexOf(e);return-1!=t&&(this.$handlers.splice(t,1),e.detach&&e.detach(this.$editor),!0)},e.prototype.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},e.prototype.getStatusText=function(){var e=this.$data,t=e.editor;return this.$handlers.map((function(n){return n.getStatusText&&n.getStatusText(t,e)||""})).filter(Boolean).join(" ")},e.prototype.$callKeyboardHandlers=function(e,t,n,i){for(var o,a=!1,s=this.$editor.commands,l=this.$handlers.length;l--&&!((o=this.$handlers[l].handleKeyboard(this.$data,e,t,n,i))&&o.command&&((a="null"==o.command||s.exec(o.command,this.$editor,o.args,i))&&i&&-1!=e&&1!=o.passEvent&&1!=o.command.passEvent&&r.stopEvent(i),a)););return a||-1!=e||(o={command:"insertstring"},a=s.exec("insertstring",this.$editor,t)),a&&this.$editor._signal&&this.$editor._signal("keyboardActivity",o),a},e.prototype.onCommandKey=function(e,t,n){var r=i.keyCodeToString(n);return this.$callKeyboardHandlers(t,r,n,e)},e.prototype.onTextInput=function(e){return this.$callKeyboardHandlers(-1,e)},e}();t.KeyBinding=o})),ace.define("ace/lib/bidiutil",["require","exports","module"],(function(e,t,n){"use strict";var i=0,r=0,o=!1,a=!1,s=!1,l=[[0,3,0,1,0,0,0],[0,3,0,1,2,2,0],[0,3,0,17,2,0,1],[0,3,5,5,4,1,0],[0,3,21,21,4,0,1],[0,3,5,5,4,2,0]],c=[[2,0,1,1,0,1,0],[2,0,1,1,0,2,0],[2,0,2,1,3,2,0],[2,0,2,33,3,1,1]],d=11,u=18,h=[u,u,u,u,u,u,u,u,u,6,5,6,8,5,u,u,u,u,u,u,u,u,u,u,u,u,u,u,5,5,5,6,8,4,4,d,d,d,4,4,4,4,4,10,9,10,9,9,2,2,2,2,2,2,2,2,2,2,9,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,4,4,4,u,u,u,u,u,u,5,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,u,9,4,d,d,d,d,4,4,4,4,0,4,4,u,4,4,d,d,2,2,4,0,4,4,4,2,0,4,4,4,4,4],p=[8,8,8,8,8,8,8,8,8,8,8,u,u,u,0,1,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,8,5,13,14,15,16,17,9,d,d,d,d,d,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,9,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,8];function g(e,t,n){if(!(r<e))if(1!=e||1!=i||a)for(var o,s,l,c,d=n.length,u=0;u<d;){if(t[u]>=e){for(o=u+1;o<d&&t[o]>=e;)o++;for(s=u,l=o-1;s<l;s++,l--)c=n[s],n[s]=n[l],n[l]=c;u=o}u++}else n.reverse()}function f(e,t,n,r){var l,c,h,p,g=t[r];switch(g){case 0:case 1:o=!1;case 4:case 3:return g;case 2:return o?3:2;case 7:return o=!0,1;case 8:return 4;case 9:return r<1||r+1>=t.length||2!=(l=n[r-1])&&3!=l||2!=(c=t[r+1])&&3!=c?4:(o&&(c=3),c==l?c:4);case 10:return 2==(l=r>0?n[r-1]:5)&&r+1<t.length&&2==t[r+1]?2:4;case d:if(r>0&&2==n[r-1])return 2;if(o)return 4;for(p=r+1,h=t.length;p<h&&t[p]==d;)p++;return p<h&&2==t[p]?2:4;case 12:for(h=t.length,p=r+1;p<h&&12==t[p];)p++;if(p<h){var f=e[r],m=f>=1425&&f<=2303||64286==f;if(l=t[p],m&&(1==l||7==l))return 1}return r<1||5==(l=t[r-1])?4:n[r-1];case 5:return o=!1,a=!0,i;case 6:return s=!0,4;case 13:case 14:case 16:case 17:case 15:o=!1;case u:return 4}}function m(e){var t=e.charCodeAt(0),n=t>>8;return 0==n?t>191?0:h[t]:5==n?/[\u0591-\u05f4]/.test(e)?1:0:6==n?/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(e)?12:/[\u0660-\u0669\u066b-\u066c]/.test(e)?3:1642==t?d:/[\u06f0-\u06f9]/.test(e)?2:7:32==n&&t<=8287?p[255&t]:254==n&&t>=65136?7:4}t.L=0,t.R=1,t.EN=2,t.ON_R=3,t.AN=4,t.R_H=5,t.B=6,t.RLE=7,t.DOT="·",t.doBidiReorder=function(e,n,d){if(e.length<2)return{};var h=e.split(""),p=new Array(h.length),y=new Array(h.length),v=[];i=d?1:0,function(e,t,n,d){var u=i?c:l,h=null,p=null,g=null,y=0,v=null,b=-1,w=null,C=null,x=[];if(!d)for(w=0,d=[];w<n;w++)d[w]=m(e[w]);for(r=i,o=!1,a=!1,s=!1,C=0;C<n;C++){if(h=y,x[C]=p=f(e,d,x,C),v=240&(y=u[h][p]),y&=15,t[C]=g=u[y][5],v>0)if(16==v){for(w=b;w<C;w++)t[w]=1;b=-1}else b=-1;if(u[y][6])-1==b&&(b=C);else if(b>-1){for(w=b;w<C;w++)t[w]=g;b=-1}5==d[C]&&(t[C]=0),r|=g}if(s)for(w=0;w<n;w++)if(6==d[w]){t[w]=i;for(var S=w-1;S>=0&&8==d[S];S--)t[S]=i}}(h,v,h.length,n);for(var b=0;b<p.length;p[b]=b,b++);for(g(2,v,p),g(1,v,p),b=0;b<p.length-1;b++)3===n[b]?v[b]=t.AN:1===v[b]&&(n[b]>7&&n[b]<13||4===n[b]||n[b]===u)?v[b]=t.ON_R:b>0&&"Ù„"===h[b-1]&&/\u0622|\u0623|\u0625|\u0627/.test(h[b])&&(v[b-1]=v[b]=t.R_H,b++);for(h[h.length-1]===t.DOT&&(v[h.length-1]=t.B),"‫"===h[0]&&(v[0]=t.RLE),b=0;b<p.length;b++)y[b]=v[p[b]];return{logicalFromVisual:p,bidiLevels:y}},t.hasBidiCharacters=function(e,t){for(var n=!1,i=0;i<e.length;i++)t[i]=m(e.charAt(i)),n||1!=t[i]&&7!=t[i]&&3!=t[i]||(n=!0);return n},t.getVisualFromLogicalIdx=function(e,t){for(var n=0;n<t.logicalFromVisual.length;n++)if(t.logicalFromVisual[n]==e)return n;return 0}})),ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang"],(function(e,t,n){"use strict";var i=e("./lib/bidiutil"),r=e("./lib/lang"),o=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\u202B]/,a=function(){function e(e){this.session=e,this.bidiMap={},this.currentRow=null,this.bidiUtil=i,this.charWidths=[],this.EOL="¬",this.showInvisibles=!0,this.isRtlDir=!1,this.$isRtl=!1,this.line="",this.wrapIndent=0,this.EOF="¶",this.RLE="‫",this.contentWidth=0,this.fontMetrics=null,this.rtlLineOffset=0,this.wrapOffset=0,this.isMoveLeftOperation=!1,this.seenBidi=o.test(e.getValue())}return e.prototype.isBidiRow=function(e,t,n){return!!this.seenBidi&&(e!==this.currentRow&&(this.currentRow=e,this.updateRowLine(t,n),this.updateBidiMap()),this.bidiMap.bidiLevels)},e.prototype.onChange=function(e){this.seenBidi?this.currentRow=null:"insert"==e.action&&o.test(e.lines.join("\n"))&&(this.seenBidi=!0,this.currentRow=null)},e.prototype.getDocumentRow=function(){var e=0,t=this.session.$screenRowCache;if(t.length){var n=this.session.$getRowCacheIndex(t,this.currentRow);n>=0&&(e=this.session.$docRowCache[n])}return e},e.prototype.getSplitIndex=function(){var e=0,t=this.session.$screenRowCache;if(t.length)for(var n,i=this.session.$getRowCacheIndex(t,this.currentRow);this.currentRow-e>0&&(n=this.session.$getRowCacheIndex(t,this.currentRow-e-1))===i;)i=n,e++;else e=this.currentRow;return e},e.prototype.updateRowLine=function(e,t){void 0===e&&(e=this.getDocumentRow());var n=e===this.session.getLength()-1?this.EOF:this.EOL;if(this.wrapIndent=0,this.line=this.session.getLine(e),this.isRtlDir=this.$isRtl||this.line.charAt(0)===this.RLE,this.session.$useWrapMode){var o=this.session.$wrapData[e];o&&(void 0===t&&(t=this.getSplitIndex()),t>0&&o.length?(this.wrapIndent=o.indent,this.wrapOffset=this.wrapIndent*this.charWidths[i.L],this.line=t<o.length?this.line.substring(o[t-1],o[t]):this.line.substring(o[o.length-1])):this.line=this.line.substring(0,o[t]),t==o.length&&(this.line+=this.showInvisibles?n:i.DOT))}else this.line+=this.showInvisibles?n:i.DOT;var a,s=this.session,l=0;this.line=this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g,(function(e,t){return"\t"===e||s.isFullWidth(e.charCodeAt(0))?(a="\t"===e?s.getScreenTabSize(t+l):2,l+=a-1,r.stringRepeat(i.DOT,a)):e})),this.isRtlDir&&(this.fontMetrics.$main.textContent=this.line.charAt(this.line.length-1)==i.DOT?this.line.substr(0,this.line.length-1):this.line,this.rtlLineOffset=this.contentWidth-this.fontMetrics.$main.getBoundingClientRect().width)},e.prototype.updateBidiMap=function(){var e=[];i.hasBidiCharacters(this.line,e)||this.isRtlDir?this.bidiMap=i.doBidiReorder(this.line,e,this.isRtlDir):this.bidiMap={}},e.prototype.markAsDirty=function(){this.currentRow=null},e.prototype.updateCharacterWidths=function(e){if(this.characterWidth!==e.$characterSize.width){this.fontMetrics=e;var t=this.characterWidth=e.$characterSize.width,n=e.$measureCharWidth("×”");this.charWidths[i.L]=this.charWidths[i.EN]=this.charWidths[i.ON_R]=t,this.charWidths[i.R]=this.charWidths[i.AN]=n,this.charWidths[i.R_H]=.45*n,this.charWidths[i.B]=this.charWidths[i.RLE]=0,this.currentRow=null}},e.prototype.setShowInvisibles=function(e){this.showInvisibles=e,this.currentRow=null},e.prototype.setEolChar=function(e){this.EOL=e},e.prototype.setContentWidth=function(e){this.contentWidth=e},e.prototype.isRtlLine=function(e){return!!this.$isRtl||(null!=e?this.session.getLine(e).charAt(0)==this.RLE:this.isRtlDir)},e.prototype.setRtlDirection=function(e,t){for(var n=e.getCursorPosition(),i=e.selection.getSelectionAnchor().row;i<=n.row;i++)t||e.session.getLine(i).charAt(0)!==e.session.$bidiHandler.RLE?t&&e.session.getLine(i).charAt(0)!==e.session.$bidiHandler.RLE&&e.session.doc.insert({column:0,row:i},e.session.$bidiHandler.RLE):e.session.doc.removeInLine(i,0,1)},e.prototype.getPosLeft=function(e){e-=this.wrapIndent;var t=this.line.charAt(0)===this.RLE?1:0,n=e>t?this.session.getOverwrite()?e:e-1:t,r=i.getVisualFromLogicalIdx(n,this.bidiMap),o=this.bidiMap.bidiLevels,a=0;!this.session.getOverwrite()&&e<=t&&o[r]%2!=0&&r++;for(var s=0;s<r;s++)a+=this.charWidths[o[s]];return!this.session.getOverwrite()&&e>t&&o[r]%2==0&&(a+=this.charWidths[o[r]]),this.wrapIndent&&(a+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset),this.isRtlDir&&(a+=this.rtlLineOffset),a},e.prototype.getSelections=function(e,t){var n,i=this.bidiMap,r=i.bidiLevels,o=[],a=0,s=Math.min(e,t)-this.wrapIndent,l=Math.max(e,t)-this.wrapIndent,c=!1,d=!1,u=0;this.wrapIndent&&(a+=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);for(var h,p=0;p<r.length;p++)h=i.logicalFromVisual[p],n=r[p],(c=h>=s&&h<l)&&!d?u=a:!c&&d&&o.push({left:u,width:a-u}),a+=this.charWidths[n],d=c;if(c&&p===r.length&&o.push({left:u,width:a-u}),this.isRtlDir)for(var g=0;g<o.length;g++)o[g].left+=this.rtlLineOffset;return o},e.prototype.offsetToCol=function(e){this.isRtlDir&&(e-=this.rtlLineOffset);var t=0,n=(e=Math.max(e,0),0),i=0,r=this.bidiMap.bidiLevels,o=this.charWidths[r[i]];for(this.wrapIndent&&(e-=this.isRtlDir?-1*this.wrapOffset:this.wrapOffset);e>n+o/2;){if(n+=o,i===r.length-1){o=0;break}o=this.charWidths[r[++i]]}return i>0&&r[i-1]%2!=0&&r[i]%2==0?(e<n&&i--,t=this.bidiMap.logicalFromVisual[i]):i>0&&r[i-1]%2==0&&r[i]%2!=0?t=1+(e>n?this.bidiMap.logicalFromVisual[i]:this.bidiMap.logicalFromVisual[i-1]):this.isRtlDir&&i===r.length-1&&0===o&&r[i-1]%2==0||!this.isRtlDir&&0===i&&r[i]%2!=0?t=1+this.bidiMap.logicalFromVisual[i]:(i>0&&r[i-1]%2!=0&&0!==o&&i--,t=this.bidiMap.logicalFromVisual[i]),0===t&&this.isRtlDir&&t++,t+this.wrapIndent},e}();t.BidiHandler=a})),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],(function(e,t,n){"use strict";var i=e("./lib/oop"),r=e("./lib/lang"),o=e("./lib/event_emitter").EventEmitter,a=e("./range").Range,s=function(){function e(e){this.session=e,this.doc=e.getDocument(),this.clearSelection(),this.cursor=this.lead=this.doc.createAnchor(0,0),this.anchor=this.doc.createAnchor(0,0),this.$silent=!1;var t=this;this.cursor.on("change",(function(e){t.$cursorChanged=!0,t.$silent||t._emit("changeCursor"),t.$isEmpty||t.$silent||t._emit("changeSelection"),t.$keepDesiredColumnOnChange||e.old.column==e.value.column||(t.$desiredColumn=null)})),this.anchor.on("change",(function(){t.$anchorChanged=!0,t.$isEmpty||t.$silent||t._emit("changeSelection")}))}return e.prototype.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},e.prototype.isMultiLine=function(){return!this.$isEmpty&&this.anchor.row!=this.cursor.row},e.prototype.getCursor=function(){return this.lead.getPosition()},e.prototype.setAnchor=function(e,t){this.$isEmpty=!1,this.anchor.setPosition(e,t)},e.prototype.getAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},e.prototype.getSelectionLead=function(){return this.lead.getPosition()},e.prototype.isBackwards=function(){var e=this.anchor,t=this.lead;return e.row>t.row||e.row==t.row&&e.column>t.column},e.prototype.getRange=function(){var e=this.anchor,t=this.lead;return this.$isEmpty?a.fromPoints(t,t):this.isBackwards()?a.fromPoints(t,e):a.fromPoints(e,t)},e.prototype.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},e.prototype.selectAll=function(){this.$setSelection(0,0,Number.MAX_VALUE,Number.MAX_VALUE)},e.prototype.setRange=function(e,t){var n=t?e.end:e.start,i=t?e.start:e.end;this.$setSelection(n.row,n.column,i.row,i.column)},e.prototype.$setSelection=function(e,t,n,i){if(!this.$silent){var r=this.$isEmpty,o=this.inMultiSelectMode;this.$silent=!0,this.$cursorChanged=this.$anchorChanged=!1,this.anchor.setPosition(e,t),this.cursor.setPosition(n,i),this.$isEmpty=!a.comparePoints(this.anchor,this.cursor),this.$silent=!1,this.$cursorChanged&&this._emit("changeCursor"),(this.$cursorChanged||this.$anchorChanged||r!=this.$isEmpty||o)&&this._emit("changeSelection")}},e.prototype.$moveSelection=function(e){var t=this.lead;this.$isEmpty&&this.setSelectionAnchor(t.row,t.column),e.call(this)},e.prototype.selectTo=function(e,t){this.$moveSelection((function(){this.moveCursorTo(e,t)}))},e.prototype.selectToPosition=function(e){this.$moveSelection((function(){this.moveCursorToPosition(e)}))},e.prototype.moveTo=function(e,t){this.clearSelection(),this.moveCursorTo(e,t)},e.prototype.moveToPosition=function(e){this.clearSelection(),this.moveCursorToPosition(e)},e.prototype.selectUp=function(){this.$moveSelection(this.moveCursorUp)},e.prototype.selectDown=function(){this.$moveSelection(this.moveCursorDown)},e.prototype.selectRight=function(){this.$moveSelection(this.moveCursorRight)},e.prototype.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},e.prototype.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},e.prototype.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},e.prototype.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},e.prototype.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},e.prototype.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},e.prototype.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},e.prototype.getWordRange=function(e,t){if(void 0===t){var n=e||this.lead;e=n.row,t=n.column}return this.session.getWordRange(e,t)},e.prototype.selectWord=function(){this.setSelectionRange(this.getWordRange())},e.prototype.selectAWord=function(){var e=this.getCursor(),t=this.session.getAWordRange(e.row,e.column);this.setSelectionRange(t)},e.prototype.getLineRange=function(e,t){var n,i="number"==typeof e?e:this.lead.row,r=this.session.getFoldLine(i);return r?(i=r.start.row,n=r.end.row):n=i,!0===t?new a(i,0,n,this.session.getLine(n).length):new a(i,0,n+1,0)},e.prototype.selectLine=function(){this.setSelectionRange(this.getLineRange())},e.prototype.moveCursorUp=function(){this.moveCursorBy(-1,0)},e.prototype.moveCursorDown=function(){this.moveCursorBy(1,0)},e.prototype.wouldMoveIntoSoftTab=function(e,t,n){var i=e.column,r=e.column+t;return n<0&&(i=e.column-t,r=e.column),this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(i,r).split(" ").length-1==t},e.prototype.moveCursorLeft=function(){var e,t=this.lead.getPosition();if(e=this.session.getFoldAt(t.row,t.column,-1))this.moveCursorTo(e.start.row,e.start.column);else if(0===t.column)t.row>0&&this.moveCursorTo(t.row-1,this.doc.getLine(t.row-1).length);else{var n=this.session.getTabSize();this.wouldMoveIntoSoftTab(t,n,-1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,-n):this.moveCursorBy(0,-1)}},e.prototype.moveCursorRight=function(){var e,t=this.lead.getPosition();if(e=this.session.getFoldAt(t.row,t.column,1))this.moveCursorTo(e.end.row,e.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0);else{var n=this.session.getTabSize();t=this.lead,this.wouldMoveIntoSoftTab(t,n,1)&&!this.session.getNavigateWithinSoftTabs()?this.moveCursorBy(0,n):this.moveCursorBy(0,1)}},e.prototype.moveCursorLineStart=function(){var e=this.lead.row,t=this.lead.column,n=this.session.documentToScreenRow(e,t),i=this.session.screenToDocumentPosition(n,0),r=this.session.getDisplayLine(e,null,i.row,i.column).match(/^\s*/);r[0].length==t||this.session.$useEmacsStyleLineStart||(i.column+=r[0].length),this.moveCursorToPosition(i)},e.prototype.moveCursorLineEnd=function(){var e=this.lead,t=this.session.getDocumentLastRowColumnPosition(e.row,e.column);if(this.lead.column==t.column){var n=this.session.getLine(t.row);if(t.column==n.length){var i=n.search(/\s+$/);i>0&&(t.column=i)}}this.moveCursorTo(t.row,t.column)},e.prototype.moveCursorFileEnd=function(){var e=this.doc.getLength()-1,t=this.doc.getLine(e).length;this.moveCursorTo(e,t)},e.prototype.moveCursorFileStart=function(){this.moveCursorTo(0,0)},e.prototype.moveCursorLongWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),i=n.substring(t);this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var r=this.session.getFoldAt(e,t,1);if(r)this.moveCursorTo(r.end.row,r.end.column);else{if(this.session.nonTokenRe.exec(i)&&(t+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,i=n.substring(t)),t>=n.length)return this.moveCursorTo(e,n.length),this.moveCursorRight(),void(e<this.doc.getLength()-1&&this.moveCursorWordRight());this.session.tokenRe.exec(i)&&(t+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(e,t)}},e.prototype.moveCursorLongWordLeft=function(){var e,t=this.lead.row,n=this.lead.column;if(e=this.session.getFoldAt(t,n,-1))this.moveCursorTo(e.start.row,e.start.column);else{var i=this.session.getFoldStringAt(t,n,-1);null==i&&(i=this.doc.getLine(t).substring(0,n));var o=r.stringReverse(i);if(this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0,this.session.nonTokenRe.exec(o)&&(n-=this.session.nonTokenRe.lastIndex,o=o.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0),n<=0)return this.moveCursorTo(t,0),this.moveCursorLeft(),void(t>0&&this.moveCursorWordLeft());this.session.tokenRe.exec(o)&&(n-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0),this.moveCursorTo(t,n)}},e.prototype.$shortWordEndIndex=function(e){var t,n=0,i=/\s/,r=this.session.tokenRe;if(r.lastIndex=0,this.session.tokenRe.exec(e))n=this.session.tokenRe.lastIndex;else{for(;(t=e[n])&&i.test(t);)n++;if(n<1)for(r.lastIndex=0;(t=e[n])&&!r.test(t);)if(r.lastIndex=0,n++,i.test(t)){if(n>2){n--;break}for(;(t=e[n])&&i.test(t);)n++;if(n>2)break}}return r.lastIndex=0,n},e.prototype.moveCursorShortWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),i=n.substring(t),r=this.session.getFoldAt(e,t,1);if(r)return this.moveCursorTo(r.end.row,r.end.column);if(t==n.length){var o=this.doc.getLength();do{e++,i=this.doc.getLine(e)}while(e<o&&/^\s*$/.test(i));/^\s+/.test(i)||(i=""),t=0}var a=this.$shortWordEndIndex(i);this.moveCursorTo(e,t+a)},e.prototype.moveCursorShortWordLeft=function(){var e,t=this.lead.row,n=this.lead.column;if(e=this.session.getFoldAt(t,n,-1))return this.moveCursorTo(e.start.row,e.start.column);var i=this.session.getLine(t).substring(0,n);if(0===n){do{t--,i=this.doc.getLine(t)}while(t>0&&/^\s*$/.test(i));n=i.length,/\s+$/.test(i)||(i="")}var o=r.stringReverse(i),a=this.$shortWordEndIndex(o);return this.moveCursorTo(t,n-a)},e.prototype.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},e.prototype.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},e.prototype.moveCursorBy=function(e,t){var n,i=this.session.documentToScreenPosition(this.lead.row,this.lead.column);if(0===t&&(0!==e&&(this.session.$bidiHandler.isBidiRow(i.row,this.lead.row)?(n=this.session.$bidiHandler.getPosLeft(i.column),i.column=Math.round(n/this.session.$bidiHandler.charWidths[0])):n=i.column*this.session.$bidiHandler.charWidths[0]),this.$desiredColumn?i.column=this.$desiredColumn:this.$desiredColumn=i.column),0!=e&&this.session.lineWidgets&&this.session.lineWidgets[this.lead.row]){var r=this.session.lineWidgets[this.lead.row];e<0?e-=r.rowsAbove||0:e>0&&(e+=r.rowCount-(r.rowsAbove||0))}var o=this.session.screenToDocumentPosition(i.row+e,i.column,n);0!==e&&0===t&&o.row===this.lead.row&&(o.column,this.lead.column),this.moveCursorTo(o.row,o.column+t,0===t)},e.prototype.moveCursorToPosition=function(e){this.moveCursorTo(e.row,e.column)},e.prototype.moveCursorTo=function(e,t,n){var i=this.session.getFoldAt(e,t,1);i&&(e=i.start.row,t=i.start.column),this.$keepDesiredColumnOnChange=!0;var r=this.session.getLine(e);/[\uDC00-\uDFFF]/.test(r.charAt(t))&&r.charAt(t-1)&&(this.lead.row==e&&this.lead.column==t+1?t-=1:t+=1),this.lead.setPosition(e,t),this.$keepDesiredColumnOnChange=!1,n||(this.$desiredColumn=null)},e.prototype.moveCursorToScreen=function(e,t,n){var i=this.session.screenToDocumentPosition(e,t);this.moveCursorTo(i.row,i.column,n)},e.prototype.detach=function(){this.lead.detach(),this.anchor.detach()},e.prototype.fromOrientedRange=function(e){this.setSelectionRange(e,e.cursor==e.start),this.$desiredColumn=e.desiredColumn||this.$desiredColumn},e.prototype.toOrientedRange=function(e){var t=this.getRange();return e?(e.start.column=t.start.column,e.start.row=t.start.row,e.end.column=t.end.column,e.end.row=t.end.row):e=t,e.cursor=this.isBackwards()?e.start:e.end,e.desiredColumn=this.$desiredColumn,e},e.prototype.getRangeOfMovements=function(e){var t=this.getCursor();try{e(this);var n=this.getCursor();return a.fromPoints(t,n)}catch(e){return a.fromPoints(t,t)}finally{this.moveCursorToPosition(t)}},e.prototype.toJSON=function(){if(this.rangeCount)var e=this.ranges.map((function(e){var t=e.clone();return t.isBackwards=e.cursor==e.start,t}));else(e=this.getRange()).isBackwards=this.isBackwards();return e},e.prototype.fromJSON=function(e){if(null==e.start){if(this.rangeList&&e.length>1){this.toSingleRange(e[0]);for(var t=e.length;t--;){var n=a.fromPoints(e[t].start,e[t].end);e[t].isBackwards&&(n.cursor=n.start),this.addRange(n,!0)}return}e=e[0]}this.rangeList&&this.toSingleRange(e),this.setSelectionRange(e,e.isBackwards)},e.prototype.isEqual=function(e){if((e.length||this.rangeCount)&&e.length!=this.rangeCount)return!1;if(!e.length||!this.ranges)return this.getRange().isEqual(e);for(var t=this.ranges.length;t--;)if(!this.ranges[t].isEqual(e[t]))return!1;return!0},e}();s.prototype.setSelectionAnchor=s.prototype.setAnchor,s.prototype.getSelectionAnchor=s.prototype.getAnchor,s.prototype.setSelectionRange=s.prototype.setRange,i.implement(s.prototype,o),t.Selection=s})),ace.define("ace/tokenizer",["require","exports","module","ace/lib/report_error"],(function(e,t,n){"use strict";var i=e("./lib/report_error").reportError,r=2e3,o=function(){function e(e){for(var t in this.splitRegex,this.states=e,this.regExps={},this.matchMappings={},this.states){for(var n=this.states[t],i=[],r=0,o=this.matchMappings[t]={defaultToken:"text"},a="g",s=[],l=0;l<n.length;l++){var c=n[l];if(c.defaultToken&&(o.defaultToken=c.defaultToken),c.caseInsensitive&&-1===a.indexOf("i")&&(a+="i"),c.unicode&&-1===a.indexOf("u")&&(a+="u"),null!=c.regex){c.regex instanceof RegExp&&(c.regex=c.regex.toString().slice(1,-1));var d=c.regex,u=new RegExp("(?:("+d+")|(.))").exec("a").length-2;Array.isArray(c.token)?1==c.token.length||1==u?c.token=c.token[0]:u-1!=c.token.length?(this.reportError("number of classes and regexp groups doesn't match",{rule:c,groupCount:u-1}),c.token=c.token[0]):(c.tokenArray=c.token,c.token=null,c.onMatch=this.$arrayTokens):"function"!=typeof c.token||c.onMatch||(c.onMatch=u>1?this.$applyToken:c.token),u>1&&(/\\\d/.test(c.regex)?d=c.regex.replace(/\\([0-9]+)/g,(function(e,t){return"\\"+(parseInt(t,10)+r+1)})):(u=1,d=this.removeCapturingGroups(c.regex)),c.splitRegex||"string"==typeof c.token||s.push(c)),o[r]=l,r+=u,i.push(d),c.onMatch||(c.onMatch=null)}}i.length||(o[0]=0,i.push("$")),s.forEach((function(e){e.splitRegex=this.createSplitterRegexp(e.regex,a)}),this),this.regExps[t]=new RegExp("("+i.join(")|(")+")|($)",a)}}return e.prototype.$setMaxTokenCount=function(e){r=0|e},e.prototype.$applyToken=function(e){var t=this.splitRegex.exec(e).slice(1),n=this.token.apply(this,t);if("string"==typeof n)return[{type:n,value:e}];for(var i=[],r=0,o=n.length;r<o;r++)t[r]&&(i[i.length]={type:n[r],value:t[r]});return i},e.prototype.$arrayTokens=function(e){if(!e)return[];var t=this.splitRegex.exec(e);if(!t)return"text";for(var n=[],i=this.tokenArray,r=0,o=i.length;r<o;r++)t[r+1]&&(n[n.length]={type:i[r],value:t[r+1]});return n},e.prototype.removeCapturingGroups=function(e){return e.replace(/\\.|\[(?:\\.|[^\\\]])*|\(\?[:=!<]|(\()/g,(function(e,t){return t?"(?:":e}))},e.prototype.createSplitterRegexp=function(e,t){if(-1!=e.indexOf("(?=")){var n=0,i=!1,r={};e.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,(function(e,t,o,a,s,l){return i?i="]"!=s:s?i=!0:a?(n==r.stack&&(r.end=l+1,r.stack=-1),n--):o&&(n++,1!=o.length&&(r.stack=n,r.start=l)),e})),null!=r.end&&/^\)*$/.test(e.substr(r.end))&&(e=e.substring(0,r.start)+e.substr(r.end))}return"^"!=e.charAt(0)&&(e="^"+e),"$"!=e.charAt(e.length-1)&&(e+="$"),new RegExp(e,(t||"").replace("g",""))},e.prototype.getLineTokens=function(e,t){if(t&&"string"!=typeof t){var n=t.slice(0);"#tmp"===(t=n[0])&&(n.shift(),t=n.shift())}else n=[];var i=t||"start",o=this.states[i];o||(i="start",o=this.states[i]);var a=this.matchMappings[i],s=this.regExps[i];s.lastIndex=0;for(var l,c=[],d=0,u=0,h={type:null,value:""};l=s.exec(e);){var p=a.defaultToken,g=null,f=l[0],m=s.lastIndex;if(m-f.length>d){var y=e.substring(d,m-f.length);h.type==p?h.value+=y:(h.type&&c.push(h),h={type:p,value:y})}for(var v=0;v<l.length-2;v++)if(void 0!==l[v+1]){p=(g=o[a[v]]).onMatch?g.onMatch(f,i,n,e):g.token,g.next&&(i="string"==typeof g.next?g.next:g.next(i,n),(o=this.states[i])||(this.reportError("state doesn't exist",i),i="start",o=this.states[i]),a=this.matchMappings[i],d=m,(s=this.regExps[i]).lastIndex=m),g.consumeLineEnd&&(d=m);break}if(f)if("string"==typeof p)g&&!1===g.merge||h.type!==p?(h.type&&c.push(h),h={type:p,value:f}):h.value+=f;else if(p)for(h.type&&c.push(h),h={type:null,value:""},v=0;v<p.length;v++)c.push(p[v]);if(d==e.length)break;if(d=m,u++>r){for(u>2*e.length&&this.reportError("infinite loop with in ace tokenizer",{startState:t,line:e});d<e.length;)h.type&&c.push(h),h={value:e.substring(d,d+=500),type:"overflow"};i="start",n=[];break}}return h.type&&c.push(h),n.length>1&&n[0]!==i&&n.unshift("#tmp",i),{tokens:c,state:n.length?n:i}},e}();o.prototype.reportError=i,t.Tokenizer=o})),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/deep_copy"],(function(e,t,n){"use strict";var i,r=e("../lib/deep_copy").deepCopy;(function(){this.addRules=function(e,t){if(t)for(var n in e){for(var i=e[n],r=0;r<i.length;r++){var o=i[r];(o.next||o.onMatch)&&("string"==typeof o.next&&0!==o.next.indexOf(t)&&(o.next=t+o.next),o.nextState&&0!==o.nextState.indexOf(t)&&(o.nextState=t+o.nextState))}this.$rules[t+n]=i}else for(var n in e)this.$rules[n]=e[n]},this.getRules=function(){return this.$rules},this.embedRules=function(e,t,n,i,o){var a="function"==typeof e?(new e).getRules():e;if(i)for(var s=0;s<i.length;s++)i[s]=t+i[s];else for(var l in i=[],a)i.push(t+l);if(this.addRules(a,t),n){var c=Array.prototype[o?"push":"unshift"];for(s=0;s<i.length;s++)c.apply(this.$rules[i[s]],r(n))}this.$embeds||(this.$embeds=[]),this.$embeds.push(t)},this.getEmbeds=function(){return this.$embeds};var e=function(e,t){return("start"!=e||t.length)&&t.unshift(this.nextState,e),this.nextState},t=function(e,t){return t.shift(),t.shift()||"start"};this.normalizeRules=function(){var n=0,i=this.$rules;Object.keys(i).forEach((function r(o){var a=i[o];a.processed=!0;for(var s=0;s<a.length;s++){var l=a[s],c=null;Array.isArray(l)&&(c=l,l={}),!l.regex&&l.start&&(l.regex=l.start,l.next||(l.next=[]),l.next.push({defaultToken:l.token},{token:l.token+".end",regex:l.end||l.start,next:"pop"}),l.token=l.token+".start",l.push=!0);var d=l.next||l.push;if(d&&Array.isArray(d)){var u=l.stateName;u||("string"!=typeof(u=l.token)&&(u=u[0]||""),i[u]&&(u+=n++)),i[u]=d,l.next=u,r(u)}else"pop"==d&&(l.next=t);if(l.push&&(l.nextState=l.next||l.push,l.next=e,delete l.push),l.rules)for(var h in l.rules)i[h]?i[h].push&&i[h].push.apply(i[h],l.rules[h]):i[h]=l.rules[h];var p="string"==typeof l?l:l.include;if(p&&("$self"===p&&(p="start"),c=Array.isArray(p)?p.map((function(e){return i[e]})):i[p]),c){var g=[s,1].concat(c);l.noEscape&&(g=g.filter((function(e){return!e.next}))),a.splice.apply(a,g),s--}l.keywordMap&&(l.token=this.createKeywordMapper(l.keywordMap,l.defaultToken||"text",l.caseInsensitive),delete l.defaultToken)}}),this)},this.createKeywordMapper=function(e,t,n,i){var r=Object.create(null);return this.$keywordList=[],Object.keys(e).forEach((function(t){for(var o=e[t].split(i||"|"),a=o.length;a--;){var s=o[a];this.$keywordList.push(s),n&&(s=s.toLowerCase()),r[s]=t}}),this),e=null,n?function(e){return r[e.toLowerCase()]||t}:function(e){return r[e]||t}},this.getKeywords=function(){return this.$keywords}}).call((i=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}}).prototype),t.TextHighlightRules=i})),ace.define("ace/mode/behaviour",["require","exports","module"],(function(e,t,n){"use strict";var i;(function(){this.add=function(e,t,n){switch(void 0){case this.$behaviours:this.$behaviours={};case this.$behaviours[e]:this.$behaviours[e]={}}this.$behaviours[e][t]=n},this.addBehaviours=function(e){for(var t in e)for(var n in e[t])this.add(t,n,e[t][n])},this.remove=function(e){this.$behaviours&&this.$behaviours[e]&&delete this.$behaviours[e]},this.inherit=function(e,t){if("function"==typeof e)var n=(new e).getBehaviours(t);else n=e.getBehaviours(t);this.addBehaviours(n)},this.getBehaviours=function(e){if(e){for(var t={},n=0;n<e.length;n++)this.$behaviours[e[n]]&&(t[e[n]]=this.$behaviours[e[n]]);return t}return this.$behaviours}}).call((i=function(){this.$behaviours={}}).prototype),t.Behaviour=i})),ace.define("ace/token_iterator",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var i=e("./range").Range,r=function(){function e(e,t,n){this.$session=e,this.$row=t,this.$rowTokens=e.getTokens(t);var i=e.getTokenAt(t,n);this.$tokenIndex=i?i.index:-1}return e.prototype.stepBackward=function(){for(this.$tokenIndex-=1;this.$tokenIndex<0;){if(this.$row-=1,this.$row<0)return this.$row=0,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=this.$rowTokens.length-1}return this.$rowTokens[this.$tokenIndex]},e.prototype.stepForward=function(){var e;for(this.$tokenIndex+=1;this.$tokenIndex>=this.$rowTokens.length;){if(this.$row+=1,e||(e=this.$session.getLength()),this.$row>=e)return this.$row=e-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},e.prototype.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},e.prototype.getCurrentTokenRow=function(){return this.$row},e.prototype.getCurrentTokenColumn=function(){var e=this.$rowTokens,t=this.$tokenIndex,n=e[t].start;if(void 0!==n)return n;for(n=0;t>0;)n+=e[t-=1].value.length;return n},e.prototype.getCurrentTokenPosition=function(){return{row:this.$row,column:this.getCurrentTokenColumn()}},e.prototype.getCurrentTokenRange=function(){var e=this.$rowTokens[this.$tokenIndex],t=this.getCurrentTokenColumn();return new i(this.$row,t,this.$row,t+e.value.length)},e}();t.TokenIterator=r})),ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"],(function(e,t,n){"use strict";var i,r,o=e("../../lib/oop"),a=e("../behaviour").Behaviour,s=e("../../token_iterator").TokenIterator,l=e("../../lib/lang"),c=["text","paren.rparen","rparen","paren","punctuation.operator"],d=["text","paren.rparen","rparen","paren","punctuation.operator","comment"],u={},h={'"':'"',"'":"'"},p=function(e){var t=-1;if(e.multiSelect&&(t=e.selection.index,u.rangeCount!=e.multiSelect.rangeCount&&(u={rangeCount:e.multiSelect.rangeCount})),u[t])return i=u[t];i=u[t]={autoInsertedBrackets:0,autoInsertedRow:-1,autoInsertedLineEnd:"",maybeInsertedBrackets:0,maybeInsertedRow:-1,maybeInsertedLineStart:"",maybeInsertedLineEnd:""}},g=function(e,t,n,i){var r=e.end.row-e.start.row;return{text:n+t+i,selection:[0,e.start.column+1,r,e.end.column+(r?0:1)]}};(r=function(e){e=e||{},this.add("braces","insertion",(function(t,n,o,a,s){var c=o.getCursorPosition(),d=a.doc.getLine(c.row);if("{"==s){p(o);var u=o.getSelectionRange(),h=a.doc.getTextRange(u),f=a.getTokenAt(c.row,c.column);if(""!==h&&"{"!==h&&o.getWrapBehavioursEnabled())return g(u,h,"{","}");if(f&&/(?:string)\.quasi|\.xml/.test(f.type)){if([/tag\-(?:open|name)/,/attribute\-name/].some((function(e){return e.test(f.type)}))||/(string)\.quasi/.test(f.type)&&"$"!==f.value[c.column-f.start-1])return;return r.recordAutoInsert(o,a,"}"),{text:"{}",selection:[1,1]}}if(r.isSaneInsertion(o,a))return/[\]\}\)]/.test(d[c.column])||o.inMultiSelectMode||e.braces?(r.recordAutoInsert(o,a,"}"),{text:"{}",selection:[1,1]}):(r.recordMaybeInsert(o,a,"{"),{text:"{",selection:[1,1]})}else if("}"==s){if(p(o),"}"==d.substring(c.column,c.column+1)&&null!==a.$findOpeningBracket("}",{column:c.column+1,row:c.row})&&r.isAutoInsertedClosing(c,d,s))return r.popAutoInsertedClosing(),{text:"",selection:[1,1]}}else{if("\n"==s||"\r\n"==s){p(o);var m="";if(r.isMaybeInsertedClosing(c,d)&&(m=l.stringRepeat("}",i.maybeInsertedBrackets),r.clearMaybeInsertedClosing()),"}"===d.substring(c.column,c.column+1)){var y=a.findMatchingBracket({row:c.row,column:c.column+1},"}");if(!y)return null;var v=this.$getIndent(a.getLine(y.row))}else{if(!m)return void r.clearMaybeInsertedClosing();v=this.$getIndent(d)}var b=v+a.getTabString();return{text:"\n"+b+"\n"+v+m,selection:[1,b.length,1,b.length]}}r.clearMaybeInsertedClosing()}})),this.add("braces","deletion",(function(e,t,n,r,o){var a=r.doc.getTextRange(o);if(!o.isMultiLine()&&"{"==a){if(p(n),"}"==r.doc.getLine(o.start.row).substring(o.end.column,o.end.column+1))return o.end.column++,o;i.maybeInsertedBrackets--}})),this.add("parens","insertion",(function(e,t,n,i,o){if("("==o){p(n);var a=n.getSelectionRange(),s=i.doc.getTextRange(a);if(""!==s&&n.getWrapBehavioursEnabled())return g(a,s,"(",")");if(r.isSaneInsertion(n,i))return r.recordAutoInsert(n,i,")"),{text:"()",selection:[1,1]}}else if(")"==o){p(n);var l=n.getCursorPosition(),c=i.doc.getLine(l.row);if(")"==c.substring(l.column,l.column+1)&&null!==i.$findOpeningBracket(")",{column:l.column+1,row:l.row})&&r.isAutoInsertedClosing(l,c,o))return r.popAutoInsertedClosing(),{text:"",selection:[1,1]}}})),this.add("parens","deletion",(function(e,t,n,i,r){var o=i.doc.getTextRange(r);if(!r.isMultiLine()&&"("==o&&(p(n),")"==i.doc.getLine(r.start.row).substring(r.start.column+1,r.start.column+2)))return r.end.column++,r})),this.add("brackets","insertion",(function(e,t,n,i,o){if("["==o){p(n);var a=n.getSelectionRange(),s=i.doc.getTextRange(a);if(""!==s&&n.getWrapBehavioursEnabled())return g(a,s,"[","]");if(r.isSaneInsertion(n,i))return r.recordAutoInsert(n,i,"]"),{text:"[]",selection:[1,1]}}else if("]"==o){p(n);var l=n.getCursorPosition(),c=i.doc.getLine(l.row);if("]"==c.substring(l.column,l.column+1)&&null!==i.$findOpeningBracket("]",{column:l.column+1,row:l.row})&&r.isAutoInsertedClosing(l,c,o))return r.popAutoInsertedClosing(),{text:"",selection:[1,1]}}})),this.add("brackets","deletion",(function(e,t,n,i,r){var o=i.doc.getTextRange(r);if(!r.isMultiLine()&&"["==o&&(p(n),"]"==i.doc.getLine(r.start.row).substring(r.start.column+1,r.start.column+2)))return r.end.column++,r})),this.add("string_dquotes","insertion",(function(e,t,n,i,r){var o=i.$mode.$quotes||h;if(1==r.length&&o[r]){if(this.lineCommentStart&&-1!=this.lineCommentStart.indexOf(r))return;p(n);var a=r,s=n.getSelectionRange(),l=i.doc.getTextRange(s);if(!(""===l||1==l.length&&o[l])&&n.getWrapBehavioursEnabled())return g(s,l,a,a);if(!l){var c=n.getCursorPosition(),d=i.doc.getLine(c.row),u=d.substring(c.column-1,c.column),f=d.substring(c.column,c.column+1),m=i.getTokenAt(c.row,c.column),y=i.getTokenAt(c.row,c.column+1);if("\\"==u&&m&&/escape/.test(m.type))return null;var v,b=m&&/string|escape/.test(m.type),w=!y||/string|escape/.test(y.type);if(f==a)(v=b!==w)&&/string\.end/.test(y.type)&&(v=!1);else{if(b&&!w)return null;if(b&&w)return null;var C=i.$mode.tokenRe;C.lastIndex=0;var x=C.test(u);C.lastIndex=0;var S=C.test(f),_=i.$mode.$pairQuotesAfter;if(!(_&&_[a]&&_[a].test(u))&&x||S)return null;if(f&&!/[\s;,.})\]\\]/.test(f))return null;var E=d[c.column-2];if(u==a&&(E==a||C.test(E)))return null;v=!0}return{text:v?a+a:"",selection:[1,1]}}}})),this.add("string_dquotes","deletion",(function(e,t,n,i,r){var o=i.$mode.$quotes||h,a=i.doc.getTextRange(r);if(!r.isMultiLine()&&o.hasOwnProperty(a)&&(p(n),i.doc.getLine(r.start.row).substring(r.start.column+1,r.start.column+2)==a))return r.end.column++,r})),!1!==e.closeDocComment&&this.add("doc comment end","insertion",(function(e,t,n,i,r){if("doc-start"===e&&("\n"===r||"\r\n"===r)&&n.selection.isEmpty()){var o=n.getCursorPosition();if(0===o.column)return;for(var a=i.doc.getLine(o.row),s=i.doc.getLine(o.row+1),l=i.getTokens(o.row),c=0,d=0;d<l.length;d++){c+=l[d].value.length;var u=l[d];if(c>=o.column){if(c===o.column){if(!/\.doc/.test(u.type))return;if(/\*\//.test(u.value)){var h=l[d+1];if(!h||!/\.doc/.test(h.type))return}}var p=o.column-(c-u.value.length),g=u.value.indexOf("*/"),f=u.value.indexOf("/**",g>-1?g+2:0);if(-1!==f&&p>f&&p<f+3)return;if(-1!==g&&-1!==f&&p>=g&&p<=f||!/\.doc/.test(u.type))return;break}}var m=this.$getIndent(a);if(/\s*\*/.test(s))return/^\s*\*/.test(a)?{text:r+m+"* ",selection:[1,2+m.length,1,2+m.length]}:{text:r+m+" * ",selection:[1,3+m.length,1,3+m.length]};if(/\/\*\*/.test(a.substring(0,o.column)))return{text:r+m+" * "+r+" "+m+"*/",selection:[1,4+m.length,1,4+m.length]}}}))}).isSaneInsertion=function(e,t){var n=e.getCursorPosition(),i=new s(t,n.row,n.column);if(!this.$matchTokenType(i.getCurrentToken()||"text",c)){if(/[)}\]]/.test(e.session.getLine(n.row)[n.column]))return!0;var r=new s(t,n.row,n.column+1);if(!this.$matchTokenType(r.getCurrentToken()||"text",c))return!1}return i.stepForward(),i.getCurrentTokenRow()!==n.row||this.$matchTokenType(i.getCurrentToken()||"text",d)},r.$matchTokenType=function(e,t){return t.indexOf(e.type||e)>-1},r.recordAutoInsert=function(e,t,n){var r=e.getCursorPosition(),o=t.doc.getLine(r.row);this.isAutoInsertedClosing(r,o,i.autoInsertedLineEnd[0])||(i.autoInsertedBrackets=0),i.autoInsertedRow=r.row,i.autoInsertedLineEnd=n+o.substr(r.column),i.autoInsertedBrackets++},r.recordMaybeInsert=function(e,t,n){var r=e.getCursorPosition(),o=t.doc.getLine(r.row);this.isMaybeInsertedClosing(r,o)||(i.maybeInsertedBrackets=0),i.maybeInsertedRow=r.row,i.maybeInsertedLineStart=o.substr(0,r.column)+n,i.maybeInsertedLineEnd=o.substr(r.column),i.maybeInsertedBrackets++},r.isAutoInsertedClosing=function(e,t,n){return i.autoInsertedBrackets>0&&e.row===i.autoInsertedRow&&n===i.autoInsertedLineEnd[0]&&t.substr(e.column)===i.autoInsertedLineEnd},r.isMaybeInsertedClosing=function(e,t){return i.maybeInsertedBrackets>0&&e.row===i.maybeInsertedRow&&t.substr(e.column)===i.maybeInsertedLineEnd&&t.substr(0,e.column)==i.maybeInsertedLineStart},r.popAutoInsertedClosing=function(){i.autoInsertedLineEnd=i.autoInsertedLineEnd.substr(1),i.autoInsertedBrackets--},r.clearMaybeInsertedClosing=function(){i&&(i.maybeInsertedBrackets=0,i.maybeInsertedRow=-1)},o.inherits(r,a),t.CstyleBehaviour=r})),ace.define("ace/unicode",["require","exports","module"],(function(e,t,n){"use strict";for(var i=[48,9,8,25,5,0,2,25,48,0,11,0,5,0,6,22,2,30,2,457,5,11,15,4,8,0,2,0,18,116,2,1,3,3,9,0,2,2,2,0,2,19,2,82,2,138,2,4,3,155,12,37,3,0,8,38,10,44,2,0,2,1,2,1,2,0,9,26,6,2,30,10,7,61,2,9,5,101,2,7,3,9,2,18,3,0,17,58,3,100,15,53,5,0,6,45,211,57,3,18,2,5,3,11,3,9,2,1,7,6,2,2,2,7,3,1,3,21,2,6,2,0,4,3,3,8,3,1,3,3,9,0,5,1,2,4,3,11,16,2,2,5,5,1,3,21,2,6,2,1,2,1,2,1,3,0,2,4,5,1,3,2,4,0,8,3,2,0,8,15,12,2,2,8,2,2,2,21,2,6,2,1,2,4,3,9,2,2,2,2,3,0,16,3,3,9,18,2,2,7,3,1,3,21,2,6,2,1,2,4,3,8,3,1,3,2,9,1,5,1,2,4,3,9,2,0,17,1,2,5,4,2,2,3,4,1,2,0,2,1,4,1,4,2,4,11,5,4,4,2,2,3,3,0,7,0,15,9,18,2,2,7,2,2,2,22,2,9,2,4,4,7,2,2,2,3,8,1,2,1,7,3,3,9,19,1,2,7,2,2,2,22,2,9,2,4,3,8,2,2,2,3,8,1,8,0,2,3,3,9,19,1,2,7,2,2,2,22,2,15,4,7,2,2,2,3,10,0,9,3,3,9,11,5,3,1,2,17,4,23,2,8,2,0,3,6,4,0,5,5,2,0,2,7,19,1,14,57,6,14,2,9,40,1,2,0,3,1,2,0,3,0,7,3,2,6,2,2,2,0,2,0,3,1,2,12,2,2,3,4,2,0,2,5,3,9,3,1,35,0,24,1,7,9,12,0,2,0,2,0,5,9,2,35,5,19,2,5,5,7,2,35,10,0,58,73,7,77,3,37,11,42,2,0,4,328,2,3,3,6,2,0,2,3,3,40,2,3,3,32,2,3,3,6,2,0,2,3,3,14,2,56,2,3,3,66,5,0,33,15,17,84,13,619,3,16,2,25,6,74,22,12,2,6,12,20,12,19,13,12,2,2,2,1,13,51,3,29,4,0,5,1,3,9,34,2,3,9,7,87,9,42,6,69,11,28,4,11,5,11,11,39,3,4,12,43,5,25,7,10,38,27,5,62,2,28,3,10,7,9,14,0,89,75,5,9,18,8,13,42,4,11,71,55,9,9,4,48,83,2,2,30,14,230,23,280,3,5,3,37,3,5,3,7,2,0,2,0,2,0,2,30,3,52,2,6,2,0,4,2,2,6,4,3,3,5,5,12,6,2,2,6,67,1,20,0,29,0,14,0,17,4,60,12,5,0,4,11,18,0,5,0,3,9,2,0,4,4,7,0,2,0,2,0,2,3,2,10,3,3,6,4,5,0,53,1,2684,46,2,46,2,132,7,6,15,37,11,53,10,0,17,22,10,6,2,6,2,6,2,6,2,6,2,6,2,6,2,6,2,31,48,0,470,1,36,5,2,4,6,1,5,85,3,1,3,2,2,89,2,3,6,40,4,93,18,23,57,15,513,6581,75,20939,53,1164,68,45,3,268,4,27,21,31,3,13,13,1,2,24,9,69,11,1,38,8,3,102,3,1,111,44,25,51,13,68,12,9,7,23,4,0,5,45,3,35,13,28,4,64,15,10,39,54,10,13,3,9,7,22,4,1,5,66,25,2,227,42,2,1,3,9,7,11171,13,22,5,48,8453,301,3,61,3,105,39,6,13,4,6,11,2,12,2,4,2,0,2,1,2,1,2,107,34,362,19,63,3,53,41,11,5,15,17,6,13,1,25,2,33,4,2,134,20,9,8,25,5,0,2,25,12,88,4,5,3,5,3,5,3,2],r=0,o=[],a=0;a<i.length;a+=2)o.push(r+=i[a]),i[a+1]&&o.push(45,r+=i[a+1]);t.wordChars=String.fromCharCode.apply(null,o)})),ace.define("ace/mode/text",["require","exports","module","ace/config","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour/cstyle","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"],(function(e,t,n){"use strict";var i,r=e("../config"),o=e("../tokenizer").Tokenizer,a=e("./text_highlight_rules").TextHighlightRules,s=e("./behaviour/cstyle").CstyleBehaviour,l=e("../unicode"),c=e("../lib/lang"),d=e("../token_iterator").TokenIterator,u=e("../range").Range;(function(){this.$defaultBehaviour=new s,this.tokenRe=new RegExp("^["+l.wordChars+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+l.wordChars+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules(this.$highlightRuleConfig),this.$tokenizer=new o(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(e,t,n,i){var r=t.doc,o=!0,a=!0,s=1/0,l=t.getTabSize(),d=!1;if(this.lineCommentStart){Array.isArray(this.lineCommentStart)?(f=this.lineCommentStart.map(c.escapeRegExp).join("|"),p=this.lineCommentStart[0]):(f=c.escapeRegExp(this.lineCommentStart),p=this.lineCommentStart),f=new RegExp("^(\\s*)(?:"+f+") ?"),d=t.getUseSoftTabs(),v=function(e,t){var n=e.match(f);if(n){var i=n[1].length,o=n[0].length;h(e,i,o)||" "!=n[0][o-1]||o--,r.removeInLine(t,i,o)}};var u=p+" ",h=(y=function(e,t){o&&!/\S/.test(e)||(h(e,s,s)?r.insertInLine({row:t,column:s},u):r.insertInLine({row:t,column:s},p))},b=function(e,t){return f.test(e)},function(e,t,n){for(var i=0;t--&&" "==e.charAt(t);)i++;if(i%l!=0)return!1;for(i=0;" "==e.charAt(n++);)i++;return l>2?i%l!=l-1:i%l==0})}else{if(!this.blockComment)return!1;var p=this.blockComment.start,g=this.blockComment.end,f=new RegExp("^(\\s*)(?:"+c.escapeRegExp(p)+")"),m=new RegExp("(?:"+c.escapeRegExp(g)+")\\s*$"),y=function(e,t){b(e,t)||o&&!/\S/.test(e)||(r.insertInLine({row:t,column:e.length},g),r.insertInLine({row:t,column:s},p))},v=function(e,t){var n;(n=e.match(m))&&r.removeInLine(t,e.length-n[0].length,e.length),(n=e.match(f))&&r.removeInLine(t,n[1].length,n[0].length)},b=function(e,n){if(f.test(e))return!0;for(var i=t.getTokens(n),r=0;r<i.length;r++)if("comment"===i[r].type)return!0}}function w(e){for(var t=n;t<=i;t++)e(r.getLine(t),t)}var C=1/0;w((function(e,t){var n=e.search(/\S/);-1!==n?(n<s&&(s=n),a&&!b(e,t)&&(a=!1)):C>e.length&&(C=e.length)})),s==1/0&&(s=C,o=!1,a=!1),d&&s%l!=0&&(s=Math.floor(s/l)*l),w(a?v:y)},this.toggleBlockComment=function(e,t,n,i){var r=this.blockComment;if(r){!r.start&&r[0]&&(r=r[0]);var o,a,s=(f=new d(t,i.row,i.column)).getCurrentToken(),l=(t.selection,t.selection.toOrientedRange());if(s&&/comment/.test(s.type)){for(var c,h;s&&/comment/.test(s.type);){if(-1!=(m=s.value.indexOf(r.start))){var p=f.getCurrentTokenRow(),g=f.getCurrentTokenColumn()+m;c=new u(p,g,p,g+r.start.length);break}s=f.stepBackward()}var f;for(s=(f=new d(t,i.row,i.column)).getCurrentToken();s&&/comment/.test(s.type);){var m;if(-1!=(m=s.value.indexOf(r.end))){p=f.getCurrentTokenRow(),g=f.getCurrentTokenColumn()+m,h=new u(p,g,p,g+r.end.length);break}s=f.stepForward()}h&&t.remove(h),c&&(t.remove(c),o=c.start.row,a=-r.start.length)}else a=r.start.length,o=n.start.row,t.insert(n.end,r.end),t.insert(n.start,r.start);l.start.row==o&&(l.start.column+=a),l.end.row==o&&(l.end.column+=a),t.selection.fromOrientedRange(l)}},this.getNextLineIndent=function(e,t,n){return this.$getIndent(t)},this.checkOutdent=function(e,t,n){return!1},this.autoOutdent=function(e,t,n){},this.$getIndent=function(e){return e.match(/^\s*/)[0]},this.createWorker=function(e){return null},this.createModeDelegates=function(e){for(var t in this.$embeds=[],this.$modes={},e)if(e[t]){var n=e[t],i=n.prototype.$id,o=r.$modes[i];o||(r.$modes[i]=o=new n),r.$modes[t]||(r.$modes[t]=o),this.$embeds.push(t),this.$modes[t]=o}var a=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"],s=function(e){var t,n,i;i=(t=l)[n=a[e]],t[a[e]]=function(){return this.$delegator(n,arguments,i)}},l=this;for(t=0;t<a.length;t++)s(t)},this.$delegator=function(e,t,n){var i=t[0]||"start";if("string"!=typeof i){if(Array.isArray(i[2])){var r=i[2][i[2].length-1];if(a=this.$modes[r])return a[e].apply(a,[i[1]].concat([].slice.call(t,1)))}i=i[0]||"start"}for(var o=0;o<this.$embeds.length;o++)if(this.$modes[this.$embeds[o]]){var a,s=i.split(this.$embeds[o]);if(!s[0]&&s[1])return t[0]=s[1],(a=this.$modes[this.$embeds[o]])[e].apply(a,t)}var l=n.apply(this,t);return n?l:void 0},this.transformAction=function(e,t,n,i,r){if(this.$behaviour){var o=this.$behaviour.getBehaviours();for(var a in o)if(o[a][t]){var s=o[a][t].apply(this,arguments);if(s)return s}}},this.getKeywords=function(e){if(!this.completionKeywords){var t=this.$tokenizer.rules,n=[];for(var i in t)for(var r=t[i],o=0,a=r.length;o<a;o++)if("string"==typeof r[o].token)/keyword|support|storage/.test(r[o].token)&&n.push(r[o].regex);else if("object"==typeof r[o].token)for(var s=0,l=r[o].token.length;s<l;s++)/keyword|support|storage/.test(r[o].token[s])&&(i=r[o].regex.match(/\(.+?\)/g)[s],n.push(i.substr(1,i.length-2)));this.completionKeywords=n}return e?n.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(e,t,n,i){return(this.$keywordList||this.$createKeywordList()).map((function(e){return{name:e,value:e,score:0,meta:"keyword"}}))},this.$id="ace/mode/text"}).call((i=function(){this.HighlightRules=a}).prototype),t.Mode=i})),ace.define("ace/line_widgets",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var i=e("./lib/dom"),r=function(){function e(e){this.session=e,this.session.widgetManager=this,this.session.getRowLength=this.getRowLength,this.session.$getWidgetScreenLength=this.$getWidgetScreenLength,this.updateOnChange=this.updateOnChange.bind(this),this.renderWidgets=this.renderWidgets.bind(this),this.measureWidgets=this.measureWidgets.bind(this),this.session._changedWidgets=[],this.$onChangeEditor=this.$onChangeEditor.bind(this),this.session.on("change",this.updateOnChange),this.session.on("changeFold",this.updateOnFold),this.session.on("changeEditor",this.$onChangeEditor)}return e.prototype.getRowLength=function(e){var t;return t=this.lineWidgets&&this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0,this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+1+t:1+t},e.prototype.$getWidgetScreenLength=function(){var e=0;return this.lineWidgets.forEach((function(t){t&&t.rowCount&&!t.hidden&&(e+=t.rowCount)})),e},e.prototype.$onChangeEditor=function(e){this.attach(e.editor)},e.prototype.attach=function(e){e&&e.widgetManager&&e.widgetManager!=this&&e.widgetManager.detach(),this.editor!=e&&(this.detach(),this.editor=e,e&&(e.widgetManager=this,e.renderer.on("beforeRender",this.measureWidgets),e.renderer.on("afterRender",this.renderWidgets)))},e.prototype.detach=function(e){var t=this.editor;if(t){this.editor=null,t.widgetManager=null,t.renderer.off("beforeRender",this.measureWidgets),t.renderer.off("afterRender",this.renderWidgets);var n=this.session.lineWidgets;n&&n.forEach((function(e){e&&e.el&&e.el.parentNode&&(e._inDocument=!1,e.el.parentNode.removeChild(e.el))}))}},e.prototype.updateOnFold=function(e,t){var n=t.lineWidgets;if(n&&e.action){for(var i=e.data,r=i.start.row,o=i.end.row,a="add"==e.action,s=r+1;s<o;s++)n[s]&&(n[s].hidden=a);n[o]&&(a?n[r]?n[o].hidden=a:n[r]=n[o]:(n[r]==n[o]&&(n[r]=void 0),n[o].hidden=a))}},e.prototype.updateOnChange=function(e){var t=this.session.lineWidgets;if(t){var n=e.start.row,i=e.end.row-n;if(0===i);else if("remove"==e.action){var r=t.splice(n+1,i);!t[n]&&r[r.length-1]&&(t[n]=r.pop()),r.forEach((function(e){e&&this.removeLineWidget(e)}),this),this.$updateRows()}else{var o=new Array(i);t[n]&&null!=t[n].column&&e.start.column>t[n].column&&n++,o.unshift(n,0),t.splice.apply(t,o),this.$updateRows()}}},e.prototype.$updateRows=function(){var e=this.session.lineWidgets;if(e){var t=!0;e.forEach((function(e,n){if(e)for(t=!1,e.row=n;e.$oldWidget;)e.$oldWidget.row=n,e=e.$oldWidget})),t&&(this.session.lineWidgets=null)}},e.prototype.$registerLineWidget=function(e){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength()));var t=this.session.lineWidgets[e.row];return t&&(e.$oldWidget=t,t.el&&t.el.parentNode&&(t.el.parentNode.removeChild(t.el),t._inDocument=!1)),this.session.lineWidgets[e.row]=e,e},e.prototype.addLineWidget=function(e){if(this.$registerLineWidget(e),e.session=this.session,!this.editor)return e;var t=this.editor.renderer;e.html&&!e.el&&(e.el=i.createElement("div"),e.el.innerHTML=e.html),e.text&&!e.el&&(e.el=i.createElement("div"),e.el.textContent=e.text),e.el&&(i.addCssClass(e.el,"ace_lineWidgetContainer"),e.className&&i.addCssClass(e.el,e.className),e.el.style.position="absolute",e.el.style.zIndex="5",t.container.appendChild(e.el),e._inDocument=!0,e.coverGutter||(e.el.style.zIndex="3"),null==e.pixelHeight&&(e.pixelHeight=e.el.offsetHeight)),null==e.rowCount&&(e.rowCount=e.pixelHeight/t.layerConfig.lineHeight);var n=this.session.getFoldAt(e.row,0);if(e.$fold=n,n){var r=this.session.lineWidgets;e.row!=n.end.row||r[n.start.row]?e.hidden=!0:r[n.start.row]=e}return this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows(),this.renderWidgets(null,t),this.onWidgetChanged(e),e},e.prototype.removeLineWidget=function(e){if(e._inDocument=!1,e.session=null,e.el&&e.el.parentNode&&e.el.parentNode.removeChild(e.el),e.editor&&e.editor.destroy)try{e.editor.destroy()}catch(e){}if(this.session.lineWidgets){var t=this.session.lineWidgets[e.row];if(t==e)this.session.lineWidgets[e.row]=e.$oldWidget,e.$oldWidget&&this.onWidgetChanged(e.$oldWidget);else for(;t;){if(t.$oldWidget==e){t.$oldWidget=e.$oldWidget;break}t=t.$oldWidget}}this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows()},e.prototype.getWidgetsAtRow=function(e){for(var t=this.session.lineWidgets,n=t&&t[e],i=[];n;)i.push(n),n=n.$oldWidget;return i},e.prototype.onWidgetChanged=function(e){this.session._changedWidgets.push(e),this.editor&&this.editor.renderer.updateFull()},e.prototype.measureWidgets=function(e,t){var n=this.session._changedWidgets,i=t.layerConfig;if(n&&n.length){for(var r=1/0,o=0;o<n.length;o++){var a=n[o];if(a&&a.el&&a.session==this.session){if(!a._inDocument){if(this.session.lineWidgets[a.row]!=a)continue;a._inDocument=!0,t.container.appendChild(a.el)}a.h=a.el.offsetHeight,a.fixedWidth||(a.w=a.el.offsetWidth,a.screenWidth=Math.ceil(a.w/i.characterWidth));var s=a.h/i.lineHeight;a.coverLine&&(s-=this.session.getRowLineCount(a.row))<0&&(s=0),a.rowCount!=s&&(a.rowCount=s,a.row<r&&(r=a.row))}}r!=1/0&&(this.session._emit("changeFold",{data:{start:{row:r}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]}},e.prototype.renderWidgets=function(e,t){var n=t.layerConfig,i=this.session.lineWidgets;if(i){for(var r=Math.min(this.firstRow,n.firstRow),o=Math.max(this.lastRow,n.lastRow,i.length);r>0&&!i[r];)r--;this.firstRow=n.firstRow,this.lastRow=n.lastRow,t.$cursorLayer.config=n;for(var a=r;a<=o;a++){var s=i[a];if(s&&s.el)if(s.hidden)s.el.style.top=-100-(s.pixelHeight||0)+"px";else{s._inDocument||(s._inDocument=!0,t.container.appendChild(s.el));var l=t.$cursorLayer.getPixelPosition({row:a,column:0},!0).top;s.coverLine||(l+=n.lineHeight*this.session.getRowLineCount(s.row)),s.el.style.top=l-n.offset+"px";var c=s.coverGutter?0:t.gutterWidth;s.fixedWidth||(c-=t.scrollLeft),s.el.style.left=c+"px",s.fullWidth&&s.screenWidth&&(s.el.style.minWidth=n.width+2*n.padding+"px"),s.fixedWidth?s.el.style.right=t.scrollBar.getWidth()+"px":s.el.style.right=""}}}},e}();t.LineWidgets=r})),ace.define("ace/apply_delta",["require","exports","module"],(function(e,t,n){"use strict";t.applyDelta=function(e,t,n){var i=t.start.row,r=t.start.column,o=e[i]||"";switch(t.action){case"insert":if(1===t.lines.length)e[i]=o.substring(0,r)+t.lines[0]+o.substring(r);else{var a=[i,1].concat(t.lines);e.splice.apply(e,a),e[i]=o.substring(0,r)+e[i],e[i+t.lines.length-1]+=o.substring(r)}break;case"remove":var s=t.end.column,l=t.end.row;i===l?e[i]=o.substring(0,r)+o.substring(s):e.splice(i,l-i+1,o.substring(0,r)+e[l].substring(s))}}})),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],(function(e,t,n){"use strict";var i=e("./lib/oop"),r=e("./lib/event_emitter").EventEmitter,o=function(){function e(e,t,n){this.$onChange=this.onChange.bind(this),this.attach(e),"number"!=typeof t?this.setPosition(t.row,t.column):this.setPosition(t,n)}return e.prototype.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},e.prototype.getDocument=function(){return this.document},e.prototype.onChange=function(e){if(!(e.start.row==e.end.row&&e.start.row!=this.row||e.start.row>this.row)){var t=function(e,t,n){var i="insert"==e.action,r=(i?1:-1)*(e.end.row-e.start.row),o=(i?1:-1)*(e.end.column-e.start.column),s=e.start,l=i?s:e.end;return a(t,s,n)?{row:t.row,column:t.column}:a(l,t,!n)?{row:t.row+r,column:t.column+(t.row==l.row?o:0)}:{row:s.row,column:s.column}}(e,{row:this.row,column:this.column},this.$insertRight);this.setPosition(t.row,t.column,!0)}},e.prototype.setPosition=function(e,t,n){var i;if(i=n?{row:e,column:t}:this.$clipPositionToDocument(e,t),this.row!=i.row||this.column!=i.column){var r={row:this.row,column:this.column};this.row=i.row,this.column=i.column,this._signal("change",{old:r,value:i})}},e.prototype.detach=function(){this.document.off("change",this.$onChange)},e.prototype.attach=function(e){this.document=e||this.document,this.document.on("change",this.$onChange)},e.prototype.$clipPositionToDocument=function(e,t){var n={};return e>=this.document.getLength()?(n.row=Math.max(0,this.document.getLength()-1),n.column=this.document.getLine(n.row).length):e<0?(n.row=0,n.column=0):(n.row=e,n.column=Math.min(this.document.getLine(n.row).length,Math.max(0,t))),t<0&&(n.column=0),n},e}();function a(e,t,n){var i=n?e.column<=t.column:e.column<t.column;return e.row<t.row||e.row==t.row&&i}o.prototype.$insertRight=!1,i.implement(o.prototype,r),t.Anchor=o})),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"],(function(e,t,n){"use strict";var i=e("./lib/oop"),r=e("./apply_delta").applyDelta,o=e("./lib/event_emitter").EventEmitter,a=e("./range").Range,s=e("./anchor").Anchor,l=function(){function e(e){this.$lines=[""],0===e.length?this.$lines=[""]:Array.isArray(e)?this.insertMergedLines({row:0,column:0},e):this.insert({row:0,column:0},e)}return e.prototype.setValue=function(e){var t=this.getLength()-1;this.remove(new a(0,0,t,this.getLine(t).length)),this.insert({row:0,column:0},e||"")},e.prototype.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},e.prototype.createAnchor=function(e,t){return new s(this,e,t)},e.prototype.$detectNewLine=function(e){var t=e.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=t?t[1]:"\n",this._signal("changeNewLineMode")},e.prototype.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return"\r\n";case"unix":return"\n";default:return this.$autoNewLine||"\n"}},e.prototype.setNewLineMode=function(e){this.$newLineMode!==e&&(this.$newLineMode=e,this._signal("changeNewLineMode"))},e.prototype.getNewLineMode=function(){return this.$newLineMode},e.prototype.isNewLine=function(e){return"\r\n"==e||"\r"==e||"\n"==e},e.prototype.getLine=function(e){return this.$lines[e]||""},e.prototype.getLines=function(e,t){return this.$lines.slice(e,t+1)},e.prototype.getAllLines=function(){return this.getLines(0,this.getLength())},e.prototype.getLength=function(){return this.$lines.length},e.prototype.getTextRange=function(e){return this.getLinesForRange(e).join(this.getNewLineCharacter())},e.prototype.getLinesForRange=function(e){var t;if(e.start.row===e.end.row)t=[this.getLine(e.start.row).substring(e.start.column,e.end.column)];else{(t=this.getLines(e.start.row,e.end.row))[0]=(t[0]||"").substring(e.start.column);var n=t.length-1;e.end.row-e.start.row==n&&(t[n]=t[n].substring(0,e.end.column))}return t},e.prototype.insertLines=function(e,t){return console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead."),this.insertFullLines(e,t)},e.prototype.removeLines=function(e,t){return console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead."),this.removeFullLines(e,t)},e.prototype.insertNewLine=function(e){return console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead."),this.insertMergedLines(e,["",""])},e.prototype.insert=function(e,t){return this.getLength()<=1&&this.$detectNewLine(t),this.insertMergedLines(e,this.$split(t))},e.prototype.insertInLine=function(e,t){var n=this.clippedPos(e.row,e.column),i=this.pos(e.row,e.column+t.length);return this.applyDelta({start:n,end:i,action:"insert",lines:[t]},!0),this.clonePos(i)},e.prototype.clippedPos=function(e,t){var n=this.getLength();void 0===e?e=n:e<0?e=0:e>=n&&(e=n-1,t=void 0);var i=this.getLine(e);return null==t&&(t=i.length),{row:e,column:t=Math.min(Math.max(t,0),i.length)}},e.prototype.clonePos=function(e){return{row:e.row,column:e.column}},e.prototype.pos=function(e,t){return{row:e,column:t}},e.prototype.$clipPosition=function(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):(e.row=Math.max(0,e.row),e.column=Math.min(Math.max(e.column,0),this.getLine(e.row).length)),e},e.prototype.insertFullLines=function(e,t){var n=0;(e=Math.min(Math.max(e,0),this.getLength()))<this.getLength()?(t=t.concat([""]),n=0):(t=[""].concat(t),e--,n=this.$lines[e].length),this.insertMergedLines({row:e,column:n},t)},e.prototype.insertMergedLines=function(e,t){var n=this.clippedPos(e.row,e.column),i={row:n.row+t.length-1,column:(1==t.length?n.column:0)+t[t.length-1].length};return this.applyDelta({start:n,end:i,action:"insert",lines:t}),this.clonePos(i)},e.prototype.remove=function(e){var t=this.clippedPos(e.start.row,e.start.column),n=this.clippedPos(e.end.row,e.end.column);return this.applyDelta({start:t,end:n,action:"remove",lines:this.getLinesForRange({start:t,end:n})}),this.clonePos(t)},e.prototype.removeInLine=function(e,t,n){var i=this.clippedPos(e,t),r=this.clippedPos(e,n);return this.applyDelta({start:i,end:r,action:"remove",lines:this.getLinesForRange({start:i,end:r})},!0),this.clonePos(i)},e.prototype.removeFullLines=function(e,t){e=Math.min(Math.max(0,e),this.getLength()-1);var n=(t=Math.min(Math.max(0,t),this.getLength()-1))==this.getLength()-1&&e>0,i=t<this.getLength()-1,r=n?e-1:e,o=n?this.getLine(r).length:0,s=i?t+1:t,l=i?0:this.getLine(s).length,c=new a(r,o,s,l),d=this.$lines.slice(e,t+1);return this.applyDelta({start:c.start,end:c.end,action:"remove",lines:this.getLinesForRange(c)}),d},e.prototype.removeNewLine=function(e){e<this.getLength()-1&&e>=0&&this.applyDelta({start:this.pos(e,this.getLine(e).length),end:this.pos(e+1,0),action:"remove",lines:["",""]})},e.prototype.replace=function(e,t){return e instanceof a||(e=a.fromPoints(e.start,e.end)),0===t.length&&e.isEmpty()?e.start:t==this.getTextRange(e)?e.end:(this.remove(e),t?this.insert(e.start,t):e.start)},e.prototype.applyDeltas=function(e){for(var t=0;t<e.length;t++)this.applyDelta(e[t])},e.prototype.revertDeltas=function(e){for(var t=e.length-1;t>=0;t--)this.revertDelta(e[t])},e.prototype.applyDelta=function(e,t){var n="insert"==e.action;(n?e.lines.length<=1&&!e.lines[0]:!a.comparePoints(e.start,e.end))||(n&&e.lines.length>2e4?this.$splitAndapplyLargeDelta(e,2e4):(r(this.$lines,e,t),this._signal("change",e)))},e.prototype.$safeApplyDelta=function(e){var t=this.$lines.length;("remove"==e.action&&e.start.row<t&&e.end.row<t||"insert"==e.action&&e.start.row<=t)&&this.applyDelta(e)},e.prototype.$splitAndapplyLargeDelta=function(e,t){for(var n=e.lines,i=n.length-t+1,r=e.start.row,o=e.start.column,a=0,s=0;a<i;a=s){s+=t-1;var l=n.slice(a,s);l.push(""),this.applyDelta({start:this.pos(r+a,o),end:this.pos(r+s,o=0),action:e.action,lines:l},!0)}e.lines=n.slice(a),e.start.row=r+a,e.start.column=o,this.applyDelta(e,!0)},e.prototype.revertDelta=function(e){this.$safeApplyDelta({start:this.clonePos(e.start),end:this.clonePos(e.end),action:"insert"==e.action?"remove":"insert",lines:e.lines.slice()})},e.prototype.indexToPosition=function(e,t){for(var n=this.$lines||this.getAllLines(),i=this.getNewLineCharacter().length,r=t||0,o=n.length;r<o;r++)if((e-=n[r].length+i)<0)return{row:r,column:e+n[r].length+i};return{row:o-1,column:e+n[o-1].length+i}},e.prototype.positionToIndex=function(e,t){for(var n=this.$lines||this.getAllLines(),i=this.getNewLineCharacter().length,r=0,o=Math.min(e.row,n.length),a=t||0;a<o;++a)r+=n[a].length+i;return r+e.column},e.prototype.$split=function(e){return e.split(/\r\n|\r|\n/)},e}();l.prototype.$autoNewLine="",l.prototype.$newLineMode="auto",i.implement(l.prototype,o),t.Document=l})),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],(function(e,t,n){"use strict";var i=e("./lib/oop"),r=e("./lib/event_emitter").EventEmitter,o=function(){function e(e,t){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=e;var n=this;this.$worker=function(){if(n.running){for(var e=new Date,t=n.currentLine,i=-1,r=n.doc,o=t;n.lines[t];)t++;var a=r.getLength(),s=0;for(n.running=!1;t<a;){n.$tokenizeRow(t),i=t;do{t++}while(n.lines[t]);if(++s%5==0&&new Date-e>20){n.running=setTimeout(n.$worker,20);break}}n.currentLine=t,-1==i&&(i=t),o<=i&&n.fireUpdateEvent(o,i)}}}return e.prototype.setTokenizer=function(e){this.tokenizer=e,this.lines=[],this.states=[],this.start(0)},e.prototype.setDocument=function(e){this.doc=e,this.lines=[],this.states=[],this.stop()},e.prototype.fireUpdateEvent=function(e,t){var n={first:e,last:t};this._signal("update",{data:n})},e.prototype.start=function(e){this.currentLine=Math.min(e||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},e.prototype.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},e.prototype.$updateOnChange=function(e){var t=e.start.row,n=e.end.row-t;if(0===n)this.lines[t]=null;else if("remove"==e.action)this.lines.splice(t,n+1,null),this.states.splice(t,n+1,null);else{var i=Array(n+1);i.unshift(t,1),this.lines.splice.apply(this.lines,i),this.states.splice.apply(this.states,i)}this.currentLine=Math.min(t,this.currentLine,this.doc.getLength()),this.stop()},e.prototype.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},e.prototype.getTokens=function(e){return this.lines[e]||this.$tokenizeRow(e)},e.prototype.getState=function(e){return this.currentLine==e&&this.$tokenizeRow(e),this.states[e]||"start"},e.prototype.$tokenizeRow=function(e){var t=this.doc.getLine(e),n=this.states[e-1],i=this.tokenizer.getLineTokens(t,n,e);return this.states[e]+""!=i.state+""?(this.states[e]=i.state,this.lines[e+1]=null,this.currentLine>e+1&&(this.currentLine=e+1)):this.currentLine==e&&(this.currentLine=e+1),this.lines[e]=i.tokens},e.prototype.cleanup=function(){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.removeAllListeners()},e}();i.implement(o.prototype,r),t.BackgroundTokenizer=o})),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/range"],(function(e,t,n){"use strict";var i=e("./lib/lang"),r=e("./range").Range,o=function(){function e(e,t,n){void 0===n&&(n="text"),this.setRegexp(e),this.clazz=t,this.type=n,this.docLen=0}return e.prototype.setRegexp=function(e){this.regExp+""!=e+""&&(this.regExp=e,this.cache=[])},e.prototype.update=function(e,t,n,o){if(this.regExp){for(var a=o.firstRow,s=o.lastRow,l={},c=n.$editor.$search,d=c.$isMultilineSearch(n.$editor.getLastSearchOptions()),u=a;u<=s;u++){var h=this.cache[u];if(null==h||n.getValue().length!=this.docLen){if(d){h=[];var p=c.$multiLineForward(n,this.regExp,u,s);if(p){var g=p.endRow<=s?p.endRow-1:s;g>u&&(u=g),h.push(new r(p.startRow,p.startCol,p.endRow,p.endCol))}h.length>this.MAX_RANGES&&(h=h.slice(0,this.MAX_RANGES))}else(h=i.getMatchOffsets(n.getLine(u),this.regExp)).length>this.MAX_RANGES&&(h=h.slice(0,this.MAX_RANGES)),h=h.map((function(e){return new r(u,e.offset,u,e.offset+e.length)}));this.cache[u]=h.length?h:""}if(0!==h.length)for(var f=h.length;f--;){var m=h[f].toScreenRange(n),y=m.toString();l[y]||(l[y]=!0,t.drawSingleLineMarker(e,m,this.clazz,o))}}this.docLen=n.getValue().length}},e}();o.prototype.MAX_RANGES=500,t.SearchHighlight=o})),ace.define("ace/undomanager",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var i=function(){function e(){this.$keepRedoStack,this.$maxRev=0,this.$fromUndo=!1,this.$undoDepth=1/0,this.reset()}return e.prototype.addSession=function(e){this.$session=e},e.prototype.add=function(e,t,n){if(!this.$fromUndo&&e!=this.$lastDelta){if(this.$keepRedoStack||(this.$redoStack.length=0),!1===t||!this.lastDeltas){this.lastDeltas=[];var i=this.$undoStack.length;i>this.$undoDepth-1&&this.$undoStack.splice(0,i-this.$undoDepth+1),this.$undoStack.push(this.lastDeltas),e.id=this.$rev=++this.$maxRev}"remove"!=e.action&&"insert"!=e.action||(this.$lastDelta=e),this.lastDeltas.push(e)}},e.prototype.addSelection=function(e,t){this.selections.push({value:e,rev:t||this.$rev})},e.prototype.startNewGroup=function(){return this.lastDeltas=null,this.$rev},e.prototype.markIgnored=function(e,t){null==t&&(t=this.$rev+1);for(var n=this.$undoStack,i=n.length;i--;){var r=n[i][0];if(r.id<=e)break;r.id<t&&(r.ignore=!0)}this.lastDeltas=null},e.prototype.getSelection=function(e,t){for(var n=this.selections,i=n.length;i--;){var r=n[i];if(r.rev<e)return t&&(r=n[i+1]),r}},e.prototype.getRevision=function(){return this.$rev},e.prototype.getDeltas=function(e,t){null==t&&(t=this.$rev+1);for(var n=this.$undoStack,i=null,r=0,o=n.length;o--;){var a=n[o][0];if(a.id<t&&!i&&(i=o+1),a.id<=e){r=o+1;break}}return n.slice(r,i)},e.prototype.getChangedRanges=function(e,t){null==t&&(t=this.$rev+1)},e.prototype.getChangedLines=function(e,t){null==t&&(t=this.$rev+1)},e.prototype.undo=function(e,t){this.lastDeltas=null;var n=this.$undoStack;if(function(e,t){for(var n=t;n--;){var i=e[n];if(i&&!i[0].ignore){for(;n<t-1;){var r=d(e[n],e[n+1]);e[n]=r[0],e[n+1]=r[1],n++}return!0}}}(n,n.length)){e||(e=this.$session),this.$redoStackBaseRev!==this.$rev&&this.$redoStack.length&&(this.$redoStack=[]),this.$fromUndo=!0;var i=n.pop(),r=null;return i&&(r=e.undoChanges(i,t),this.$redoStack.push(i),this.$syncRev()),this.$fromUndo=!1,r}},e.prototype.redo=function(e,t){if(this.lastDeltas=null,e||(e=this.$session),this.$fromUndo=!0,this.$redoStackBaseRev!=this.$rev){var n=this.getDeltas(this.$redoStackBaseRev,this.$rev+1);!function(e,t){for(var n=0;n<t.length;n++)for(var i=t[n],r=0;r<i.length;r++)f(e,i[r])}(this.$redoStack,n),this.$redoStackBaseRev=this.$rev,this.$redoStack.forEach((function(e){e[0].id=++this.$maxRev}),this)}var i=this.$redoStack.pop(),r=null;return i&&(r=e.redoChanges(i,t),this.$undoStack.push(i),this.$syncRev()),this.$fromUndo=!1,r},e.prototype.$syncRev=function(){var e=this.$undoStack,t=e[e.length-1],n=t&&t[0].id||0;this.$redoStackBaseRev=n,this.$rev=n},e.prototype.reset=function(){this.lastDeltas=null,this.$lastDelta=null,this.$undoStack=[],this.$redoStack=[],this.$rev=0,this.mark=0,this.$redoStackBaseRev=this.$rev,this.selections=[]},e.prototype.canUndo=function(){return this.$undoStack.length>0},e.prototype.canRedo=function(){return this.$redoStack.length>0},e.prototype.bookmark=function(e){null==e&&(e=this.$rev),this.mark=e},e.prototype.isAtBookmark=function(){return this.$rev===this.mark},e.prototype.toJSON=function(){return{$redoStack:this.$redoStack,$undoStack:this.$undoStack}},e.prototype.fromJSON=function(e){this.reset(),this.$undoStack=e.$undoStack,this.$redoStack=e.$redoStack},e.prototype.$prettyPrint=function(e){return e?s(e):s(this.$undoStack)+"\n---\n"+s(this.$redoStack)},e}();i.prototype.hasUndo=i.prototype.canUndo,i.prototype.hasRedo=i.prototype.canRedo,i.prototype.isClean=i.prototype.isAtBookmark,i.prototype.markClean=i.prototype.bookmark;var r=e("./range").Range,o=r.comparePoints;function a(e){return{row:e.row,column:e.column}}function s(e){if(e=e||this,Array.isArray(e))return e.map(s).join("\n");var t="";return e.action?(t="insert"==e.action?"+":"-",t+="["+e.lines+"]"):e.value&&(t=Array.isArray(e.value)?e.value.map(l).join("\n"):l(e.value)),e.start&&(t+=l(e)),(e.id||e.rev)&&(t+="\t("+(e.id||e.rev)+")"),t}function l(e){return e.start.row+":"+e.start.column+"=>"+e.end.row+":"+e.end.column}function c(e,t){var n="insert"==e.action,i="insert"==t.action;if(n&&i)if(o(t.start,e.end)>=0)h(t,e,-1);else{if(!(o(t.start,e.start)<=0))return null;h(e,t,1)}else if(n&&!i)if(o(t.start,e.end)>=0)h(t,e,-1);else{if(!(o(t.end,e.start)<=0))return null;h(e,t,-1)}else if(!n&&i)if(o(t.start,e.start)>=0)h(t,e,1);else{if(!(o(t.start,e.start)<=0))return null;h(e,t,1)}else if(!n&&!i)if(o(t.start,e.start)>=0)h(t,e,1);else{if(!(o(t.end,e.start)<=0))return null;h(e,t,-1)}return[t,e]}function d(e,t){for(var n=e.length;n--;)for(var i=0;i<t.length;i++)if(!c(e[n],t[i])){for(;n<e.length;){for(;i--;)c(t[i],e[n]);i=t.length,n++}return[e,t]}return e.selectionBefore=t.selectionBefore=e.selectionAfter=t.selectionAfter=null,[t,e]}function u(e,t){var n="insert"==e.action,i="insert"==t.action;if(n&&i)o(e.start,t.start)<0?h(t,e,1):h(e,t,1);else if(n&&!i)o(e.start,t.end)>=0?h(e,t,-1):(o(e.start,t.start)<=0||h(e,r.fromPoints(t.start,e.start),-1),h(t,e,1));else if(!n&&i)o(t.start,e.end)>=0?h(t,e,-1):(o(t.start,e.start)<=0||h(t,r.fromPoints(e.start,t.start),-1),h(e,t,1));else if(!n&&!i)if(o(t.start,e.end)>=0)h(t,e,-1);else{var a,s;if(!(o(t.end,e.start)<=0))return o(e.start,t.start)<0&&(a=e,e=g(e,t.start)),o(e.end,t.end)>0&&(s=g(e,t.end)),p(t.end,e.start,e.end,-1),s&&!a&&(e.lines=s.lines,e.start=s.start,e.end=s.end,s=e),[t,a,s].filter(Boolean);h(e,t,-1)}return[t,e]}function h(e,t,n){p(e.start,t.start,t.end,n),p(e.end,t.start,t.end,n)}function p(e,t,n,i){e.row==(1==i?t:n).row&&(e.column+=i*(n.column-t.column)),e.row+=i*(n.row-t.row)}function g(e,t){var n=e.lines,i=e.end;e.end=a(t);var r=e.end.row-e.start.row,o=n.splice(r,n.length),s=r?t.column:t.column-e.start.column;return n.push(o[0].substring(0,s)),o[0]=o[0].substr(s),{start:a(t),end:i,lines:o,action:e.action}}function f(e,t){t=function(e){return{start:a(e.start),end:a(e.end),action:e.action,lines:e.lines.slice()}}(t);for(var n=e.length;n--;){for(var i=e[n],r=0;r<i.length;r++){var o=u(i[r],t);t=o[0],2!=o.length&&(o[2]?(i.splice(r+1,1,o[1],o[2]),r++):o[1]||(i.splice(r,1),r--))}i.length||e.splice(n,1)}return e}r.comparePoints,t.UndoManager=i})),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var i=e("../range").Range,r=function(){function e(e,t){this.foldData=e,Array.isArray(t)?this.folds=t:t=this.folds=[t];var n=t[t.length-1];this.range=new i(t[0].start.row,t[0].start.column,n.end.row,n.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach((function(e){e.setFoldLine(this)}),this)}return e.prototype.shiftRow=function(e){this.start.row+=e,this.end.row+=e,this.folds.forEach((function(t){t.start.row+=e,t.end.row+=e}))},e.prototype.addFold=function(e){if(e.sameRow){if(e.start.row<this.startRow||e.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(e),this.folds.sort((function(e,t){return-e.range.compareEnd(t.start.row,t.start.column)})),this.range.compareEnd(e.start.row,e.start.column)>0?(this.end.row=e.end.row,this.end.column=e.end.column):this.range.compareStart(e.end.row,e.end.column)<0&&(this.start.row=e.start.row,this.start.column=e.start.column)}else if(e.start.row==this.end.row)this.folds.push(e),this.end.row=e.end.row,this.end.column=e.end.column;else{if(e.end.row!=this.start.row)throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");this.folds.unshift(e),this.start.row=e.start.row,this.start.column=e.start.column}e.foldLine=this},e.prototype.containsRow=function(e){return e>=this.start.row&&e<=this.end.row},e.prototype.walk=function(e,t,n){var i,r,o=0,a=this.folds,s=!0;null==t&&(t=this.end.row,n=this.end.column);for(var l=0;l<a.length;l++){if(-1==(r=(i=a[l]).range.compareStart(t,n)))return void e(null,t,n,o,s);if(!e(null,i.start.row,i.start.column,o,s)&&e(i.placeholder,i.start.row,i.start.column,o)||0===r)return;s=!i.sameRow,o=i.end.column}e(null,t,n,o,s)},e.prototype.getNextFoldTo=function(e,t){for(var n,i,r=0;r<this.folds.length;r++){if(-1==(i=(n=this.folds[r]).range.compareEnd(e,t)))return{fold:n,kind:"after"};if(0===i)return{fold:n,kind:"inside"}}return null},e.prototype.addRemoveChars=function(e,t,n){var i,r,o=this.getNextFoldTo(e,t);if(o)if(i=o.fold,"inside"==o.kind&&i.start.column!=t&&i.start.row!=e)window.console&&window.console.log(e,t,i);else if(i.start.row==e){var a=(r=this.folds).indexOf(i);for(0===a&&(this.start.column+=n);a<r.length;a++){if((i=r[a]).start.column+=n,!i.sameRow)return;i.end.column+=n}this.end.column+=n}},e.prototype.split=function(t,n){var i=this.getNextFoldTo(t,n);if(!i||"inside"==i.kind)return null;var r=i.fold,o=this.folds,a=this.foldData,s=o.indexOf(r),l=o[s-1];this.end.row=l.end.row,this.end.column=l.end.column;var c=new e(a,o=o.splice(s,o.length-s));return a.splice(a.indexOf(this)+1,0,c),c},e.prototype.merge=function(e){for(var t=e.folds,n=0;n<t.length;n++)this.addFold(t[n]);var i=this.foldData;i.splice(i.indexOf(e),1)},e.prototype.toString=function(){var e=[this.range.toString()+": ["];return this.folds.forEach((function(t){e.push(" "+t.toString())})),e.push("]"),e.join("\n")},e.prototype.idxToPosition=function(e){for(var t=0,n=0;n<this.folds.length;n++){var i=this.folds[n];if((e-=i.start.column-t)<0)return{row:i.start.row,column:i.start.column+e};if((e-=i.placeholder.length)<0)return i.start;t=i.end.column}return{row:this.end.row,column:this.end.column+e}},e}();t.FoldLine=r})),ace.define("ace/range_list",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var i=e("./range").Range.comparePoints,r=function(){function e(){this.ranges=[],this.$bias=1}return e.prototype.pointIndex=function(e,t,n){for(var r=this.ranges,o=n||0;o<r.length;o++){var a=r[o],s=i(e,a.end);if(!(s>0)){var l=i(e,a.start);return 0===s?t&&0!==l?-o-2:o:l>0||0===l&&!t?o:-o-1}}return-o-1},e.prototype.add=function(e){var t=!e.isEmpty(),n=this.pointIndex(e.start,t);n<0&&(n=-n-1);var i=this.pointIndex(e.end,t,n);return i<0?i=-i-1:i++,this.ranges.splice(n,i-n,e)},e.prototype.addList=function(e){for(var t=[],n=e.length;n--;)t.push.apply(t,this.add(e[n]));return t},e.prototype.substractPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges.splice(t,1)},e.prototype.merge=function(){for(var e,t=[],n=this.ranges,r=(n=n.sort((function(e,t){return i(e.start,t.start)})))[0],o=1;o<n.length;o++){e=r,r=n[o];var a=i(e.end,r.start);a<0||(0!=a||e.isEmpty()||r.isEmpty())&&(i(e.end,r.end)<0&&(e.end.row=r.end.row,e.end.column=r.end.column),n.splice(o,1),t.push(r),r=e,o--)}return this.ranges=n,t},e.prototype.contains=function(e,t){return this.pointIndex({row:e,column:t})>=0},e.prototype.containsPoint=function(e){return this.pointIndex(e)>=0},e.prototype.rangeAtPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges[t]},e.prototype.clipRows=function(e,t){var n=this.ranges;if(n[0].start.row>t||n[n.length-1].start.row<e)return[];var i=this.pointIndex({row:e,column:0});i<0&&(i=-i-1);var r=this.pointIndex({row:t,column:0},i);r<0&&(r=-r-1);for(var o=[],a=i;a<r;a++)o.push(n[a]);return o},e.prototype.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},e.prototype.attach=function(e){this.session&&this.detach(),this.session=e,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},e.prototype.detach=function(){this.session&&(this.session.removeListener("change",this.onChange),this.session=null)},e.prototype.$onChange=function(e){for(var t=e.start,n=e.end,i=t.row,r=n.row,o=this.ranges,a=0,s=o.length;a<s&&!((d=o[a]).end.row>=i);a++);if("insert"==e.action){for(var l=r-i,c=-t.column+n.column;a<s&&!((d=o[a]).start.row>i);a++)if(d.start.row==i&&d.start.column>=t.column&&(d.start.column==t.column&&this.$bias<=0||(d.start.column+=c,d.start.row+=l)),d.end.row==i&&d.end.column>=t.column){if(d.end.column==t.column&&this.$bias<0)continue;d.end.column==t.column&&c>0&&a<s-1&&d.end.column>d.start.column&&d.end.column==o[a+1].start.column&&(d.end.column-=c),d.end.column+=c,d.end.row+=l}}else for(l=i-r,c=t.column-n.column;a<s&&!((d=o[a]).start.row>r);a++)d.end.row<r&&(i<d.end.row||i==d.end.row&&t.column<d.end.column)?(d.end.row=i,d.end.column=t.column):d.end.row==r?d.end.column<=n.column?(l||d.end.column>t.column)&&(d.end.column=t.column,d.end.row=t.row):(d.end.column+=c,d.end.row+=l):d.end.row>r&&(d.end.row+=l),d.start.row<r&&(i<d.start.row||i==d.start.row&&t.column<d.start.column)?(d.start.row=i,d.start.column=t.column):d.start.row==r?d.start.column<=n.column?(l||d.start.column>t.column)&&(d.start.column=t.column,d.start.row=t.row):(d.start.column+=c,d.start.row+=l):d.start.row>r&&(d.start.row+=l);if(0!=l&&a<s)for(;a<s;a++){var d;(d=o[a]).start.row+=l,d.end.row+=l}},e}();r.prototype.comparePoints=i,t.RangeList=r})),ace.define("ace/edit_session/fold",["require","exports","module","ace/range_list"],(function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=function(e){function t(t,n){var i=e.call(this)||this;return i.foldLine=null,i.placeholder=n,i.range=t,i.start=t.start,i.end=t.end,i.sameRow=t.start.row==t.end.row,i.subFolds=i.ranges=[],i}return r(t,e),t.prototype.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},t.prototype.setFoldLine=function(e){this.foldLine=e,this.subFolds.forEach((function(t){t.setFoldLine(e)}))},t.prototype.clone=function(){var e=new t(this.range.clone(),this.placeholder);return this.subFolds.forEach((function(t){e.subFolds.push(t.clone())})),e.collapseChildren=this.collapseChildren,e},t.prototype.addSubFold=function(e){if(!this.range.isEqual(e)){var t,n;t=e,n=this.start,a(t.start,n),a(t.end,n);for(var i=e.start.row,r=e.start.column,o=0,s=-1;o<this.subFolds.length&&1==(s=this.subFolds[o].range.compare(i,r));o++);var l=this.subFolds[o],c=0;if(0==s){if(l.range.containsRange(e))return l.addSubFold(e);c=1}i=e.range.end.row,r=e.range.end.column;var d=o;for(s=-1;d<this.subFolds.length&&1==(s=this.subFolds[d].range.compare(i,r));d++);0==s&&d++;for(var u=this.subFolds.splice(o,d-o,e),h=0==s?u.length-1:u.length,p=c;p<h;p++)e.addSubFold(u[p]);return e.setFoldLine(this.foldLine),e}},t.prototype.restoreRange=function(e){return function(e,t){s(e.start,t),s(e.end,t)}(e,this.start)},t}(e("../range_list").RangeList);function a(e,t){e.row-=t.row,0==e.row&&(e.column-=t.column)}function s(e,t){0==e.row&&(e.column+=t.column),e.row+=t.row}t.Fold=o})),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator","ace/mouse/mouse_event"],(function(e,t,n){"use strict";var i=e("../range").Range,r=e("./fold_line").FoldLine,o=e("./fold").Fold,a=e("../token_iterator").TokenIterator,s=e("../mouse/mouse_event").MouseEvent;t.Folding=function(){this.getFoldAt=function(e,t,n){var i=this.getFoldLine(e);if(!i)return null;for(var r=i.folds,o=0;o<r.length;o++){var a=r[o].range;if(a.contains(e,t)){if(1==n&&a.isEnd(e,t)&&!a.isEmpty())continue;if(-1==n&&a.isStart(e,t)&&!a.isEmpty())continue;return r[o]}}},this.getFoldsInRange=function(e){var t=e.start,n=e.end,i=this.$foldData,r=[];t.column+=1,n.column-=1;for(var o=0;o<i.length;o++){var a=i[o].range.compareRange(e);if(2!=a){if(-2==a)break;for(var s=i[o].folds,l=0;l<s.length;l++){var c=s[l];if(-2==(a=c.range.compareRange(e)))break;if(2!=a){if(42==a)break;r.push(c)}}}}return t.column-=1,n.column+=1,r},this.getFoldsInRangeList=function(e){if(Array.isArray(e)){var t=[];e.forEach((function(e){t=t.concat(this.getFoldsInRange(e))}),this)}else t=this.getFoldsInRange(e);return t},this.getAllFolds=function(){for(var e=[],t=this.$foldData,n=0;n<t.length;n++)for(var i=0;i<t[n].folds.length;i++)e.push(t[n].folds[i]);return e},this.getFoldStringAt=function(e,t,n,i){if(!(i=i||this.getFoldLine(e)))return null;for(var r,o,a={end:{column:0}},s=0;s<i.folds.length;s++){var l=(o=i.folds[s]).range.compareEnd(e,t);if(-1==l){r=this.getLine(o.start.row).substring(a.end.column,o.start.column);break}if(0===l)return null;a=o}return r||(r=this.getLine(o.start.row).substring(a.end.column)),-1==n?r.substring(0,t-a.end.column):1==n?r.substring(t-a.end.column):r},this.getFoldLine=function(e,t){var n=this.$foldData,i=0;for(t&&(i=n.indexOf(t)),-1==i&&(i=0);i<n.length;i++){var r=n[i];if(r.start.row<=e&&r.end.row>=e)return r;if(r.end.row>e)return null}return null},this.getNextFoldLine=function(e,t){var n=this.$foldData,i=0;for(t&&(i=n.indexOf(t)),-1==i&&(i=0);i<n.length;i++){var r=n[i];if(r.end.row>=e)return r}return null},this.getFoldedRowCount=function(e,t){for(var n=this.$foldData,i=t-e+1,r=0;r<n.length;r++){var o=n[r],a=o.end.row,s=o.start.row;if(a>=t){s<t&&(s>=e?i-=t-s:i=0);break}a>=e&&(i-=s>=e?a-s:a-e+1)}return i},this.$addFoldLine=function(e){return this.$foldData.push(e),this.$foldData.sort((function(e,t){return e.start.row-t.start.row})),e},this.addFold=function(e,t){var n,i=this.$foldData,a=!1;e instanceof o?n=e:(n=new o(t,e)).collapseChildren=t.collapseChildren,this.$clipRangeToDocument(n.range);var s=n.start.row,l=n.start.column,c=n.end.row,d=n.end.column,u=this.getFoldAt(s,l,1),h=this.getFoldAt(c,d,-1);if(u&&h==u)return u.addSubFold(n);u&&!u.range.isStart(s,l)&&this.removeFold(u),h&&!h.range.isEnd(c,d)&&this.removeFold(h);var p=this.getFoldsInRange(n.range);p.length>0&&(this.removeFolds(p),n.collapseChildren||p.forEach((function(e){n.addSubFold(e)})));for(var g=0;g<i.length;g++){var f=i[g];if(c==f.start.row){f.addFold(n),a=!0;break}if(s==f.end.row){if(f.addFold(n),a=!0,!n.sameRow){var m=i[g+1];if(m&&m.start.row==c){f.merge(m);break}}break}if(c<=f.start.row)break}return a||(f=this.$addFoldLine(new r(this.$foldData,n))),this.$useWrapMode?this.$updateWrapData(f.start.row,f.start.row):this.$updateRowLengthCache(f.start.row,f.start.row),this.$modified=!0,this._signal("changeFold",{data:n,action:"add"}),n},this.addFolds=function(e){e.forEach((function(e){this.addFold(e)}),this)},this.removeFold=function(e){var t=e.foldLine,n=t.start.row,i=t.end.row,r=this.$foldData,o=t.folds;if(1==o.length)r.splice(r.indexOf(t),1);else if(t.range.isEnd(e.end.row,e.end.column))o.pop(),t.end.row=o[o.length-1].end.row,t.end.column=o[o.length-1].end.column;else if(t.range.isStart(e.start.row,e.start.column))o.shift(),t.start.row=o[0].start.row,t.start.column=o[0].start.column;else if(e.sameRow)o.splice(o.indexOf(e),1);else{var a=t.split(e.start.row,e.start.column);(o=a.folds).shift(),a.start.row=o[0].start.row,a.start.column=o[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(n,i):this.$updateRowLengthCache(n,i)),this.$modified=!0,this._signal("changeFold",{data:e,action:"remove"})},this.removeFolds=function(e){for(var t=[],n=0;n<e.length;n++)t.push(e[n]);t.forEach((function(e){this.removeFold(e)}),this),this.$modified=!0},this.expandFold=function(e){this.removeFold(e),e.subFolds.forEach((function(t){e.restoreRange(t),this.addFold(t)}),this),e.collapseChildren>0&&this.foldAll(e.start.row+1,e.end.row,e.collapseChildren-1),e.subFolds=[]},this.expandFolds=function(e){e.forEach((function(e){this.expandFold(e)}),this)},this.unfold=function(e,t){var n,r;if(null==e)n=new i(0,0,this.getLength(),0),null==t&&(t=!0);else if("number"==typeof e)n=new i(e,0,e,this.getLine(e).length);else if("row"in e)n=i.fromPoints(e,e);else{if(Array.isArray(e))return r=[],e.forEach((function(e){r=r.concat(this.unfold(e))}),this),r;n=e}for(var o=r=this.getFoldsInRangeList(n);1==r.length&&i.comparePoints(r[0].start,n.start)<0&&i.comparePoints(r[0].end,n.end)>0;)this.expandFolds(r),r=this.getFoldsInRangeList(n);if(0!=t?this.removeFolds(r):this.expandFolds(r),o.length)return o},this.isRowFolded=function(e,t){return!!this.getFoldLine(e,t)},this.getRowFoldEnd=function(e,t){var n=this.getFoldLine(e,t);return n?n.end.row:e},this.getRowFoldStart=function(e,t){var n=this.getFoldLine(e,t);return n?n.start.row:e},this.getFoldDisplayLine=function(e,t,n,i,r){null==i&&(i=e.start.row),null==r&&(r=0),null==t&&(t=e.end.row),null==n&&(n=this.getLine(t).length);var o=this.doc,a="";return e.walk((function(e,t,n,s){if(!(t<i)){if(t==i){if(n<r)return;s=Math.max(r,s)}a+=null!=e?e:o.getLine(t).substring(s,n)}}),t,n),a},this.getDisplayLine=function(e,t,n,i){var r,o=this.getFoldLine(e);return o?this.getFoldDisplayLine(o,e,t,n,i):(r=this.doc.getLine(e)).substring(i||0,t||r.length)},this.$cloneFoldData=function(){var e=[];return e=this.$foldData.map((function(t){var n=t.folds.map((function(e){return e.clone()}));return new r(e,n)}))},this.toggleFold=function(e){var t,n,i=this.selection.getRange();if(i.isEmpty()){var r=i.start;if(t=this.getFoldAt(r.row,r.column))return void this.expandFold(t);(n=this.findMatchingBracket(r))?1==i.comparePoint(n)?i.end=n:(i.start=n,i.start.column++,i.end.column--):(n=this.findMatchingBracket({row:r.row,column:r.column+1}))?(1==i.comparePoint(n)?i.end=n:i.start=n,i.start.column++):i=this.getCommentFoldRange(r.row,r.column)||i}else{var o=this.getFoldsInRange(i);if(e&&o.length)return void this.expandFolds(o);1==o.length&&(t=o[0])}if(t||(t=this.getFoldAt(i.start.row,i.start.column)),t&&t.range.toString()==i.toString())this.expandFold(t);else{var a="...";if(!i.isMultiLine()){if((a=this.getTextRange(i)).length<4)return;a=a.trim().substring(0,2)+".."}this.addFold(a,i)}},this.getCommentFoldRange=function(e,t,n){var r=new a(this,e,t),o=r.getCurrentToken(),s=o&&o.type;if(o&&/^comment|string/.test(s)){"comment"==(s=s.match(/comment|string/)[0])&&(s+="|doc-start|\\.doc");var l=new RegExp(s),c=new i;if(1!=n){do{o=r.stepBackward()}while(o&&l.test(o.type));o=r.stepForward()}c.start.row=r.getCurrentTokenRow(),c.start.column=r.getCurrentTokenColumn()+o.value.length,r=new a(this,e,t);var d=this.getState(r.$row);if(-1!=n){var u=-1;do{if(o=r.stepForward(),-1==u){var h=this.getState(r.$row);d.toString()!==h.toString()&&(u=r.$row)}else if(r.$row>u)break}while(o&&l.test(o.type));o=r.stepBackward()}else o=r.getCurrentToken();return c.end.row=r.getCurrentTokenRow(),c.end.column=r.getCurrentTokenColumn(),c}},this.foldAll=function(e,t,n,i){null==n&&(n=1e5);var r=this.foldWidgets;if(r){t=t||this.getLength();for(var o=e=e||0;o<t;o++)if(null==r[o]&&(r[o]=this.getFoldWidget(o)),"start"==r[o]&&(!i||i(o))){var a=this.getFoldWidgetRange(o);a&&a.isMultiLine()&&a.end.row<=t&&a.start.row>=e&&(o=a.end.row,a.collapseChildren=n,this.addFold("...",a))}}},this.foldToLevel=function(e){for(this.foldAll();e-- >0;)this.unfold(null,!1)},this.foldAllComments=function(){var e=this;this.foldAll(null,null,null,(function(t){for(var n=e.getTokens(t),i=0;i<n.length;i++){var r=n[i];if("text"!=r.type||!/^\s+$/.test(r.value))return!!/comment/.test(r.type)}}))},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(e){if(!this.$foldStyles[e])throw new Error("invalid fold style: "+e+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle!=e){this.$foldStyle=e,"manual"==e&&this.unfold();var t=this.$foldMode;this.$setFolding(null),this.$setFolding(t)}},this.$setFolding=function(e){this.$foldMode!=e&&(this.$foldMode=e,this.off("change",this.$updateFoldWidgets),this.off("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets),this._signal("changeAnnotation"),e&&"manual"!=this.$foldStyle?(this.foldWidgets=[],this.getFoldWidget=e.getFoldWidget.bind(e,this,this.$foldStyle),this.getFoldWidgetRange=e.getFoldWidgetRange.bind(e,this,this.$foldStyle),this.$updateFoldWidgets=this.updateFoldWidgets.bind(this),this.$tokenizerUpdateFoldWidgets=this.tokenizerUpdateFoldWidgets.bind(this),this.on("change",this.$updateFoldWidgets),this.on("tokenizerUpdate",this.$tokenizerUpdateFoldWidgets)):this.foldWidgets=null)},this.getParentFoldRangeData=function(e,t){var n=this.foldWidgets;if(!n||t&&n[e])return{};for(var i,r=e-1;r>=0;){var o=n[r];if(null==o&&(o=n[r]=this.getFoldWidget(r)),"start"==o){var a=this.getFoldWidgetRange(r);if(i||(i=a),a&&a.end.row>=e)break}r--}return{range:-1!==r&&a,firstRange:i}},this.onFoldWidgetClick=function(e,t){t instanceof s&&(t=t.domEvent);var n={children:t.shiftKey,all:t.ctrlKey||t.metaKey,siblings:t.altKey};if(!this.$toggleFoldWidget(e,n)){var i=t.target||t.srcElement;i&&/ace_fold-widget/.test(i.className)&&(i.className+=" ace_invalid")}},this.$toggleFoldWidget=function(e,t){if(this.getFoldWidget){var n=this.getFoldWidget(e),i=this.getLine(e),r="end"===n?-1:1,o=this.getFoldAt(e,-1===r?0:i.length,r);if(o)return t.children||t.all?this.removeFold(o):this.expandFold(o),o;var a=this.getFoldWidgetRange(e,!0);if(a&&!a.isMultiLine()&&(o=this.getFoldAt(a.start.row,a.start.column,1))&&a.isEqual(o.range))return this.removeFold(o),o;if(t.siblings){var s=this.getParentFoldRangeData(e);if(s.range)var l=s.range.start.row+1,c=s.range.end.row;this.foldAll(l,c,t.all?1e4:0)}else t.children?(c=a?a.end.row:this.getLength(),this.foldAll(e+1,c,t.all?1e4:0)):a&&(t.all&&(a.collapseChildren=1e4),this.addFold("...",a));return a}},this.toggleFoldWidget=function(e){var t=this.selection.getCursor().row;t=this.getRowFoldStart(t);var n=this.$toggleFoldWidget(t,{});if(!n){var i=this.getParentFoldRangeData(t,!0);if(n=i.range||i.firstRange){t=n.start.row;var r=this.getFoldAt(t,this.getLine(t).length,1);r?this.removeFold(r):this.addFold("...",n)}}},this.updateFoldWidgets=function(e){var t=e.start.row,n=e.end.row-t;if(0===n)this.foldWidgets[t]=null;else if("remove"==e.action)this.foldWidgets.splice(t,n+1,null);else{var i=Array(n+1);i.unshift(t,1),this.foldWidgets.splice.apply(this.foldWidgets,i)}},this.tokenizerUpdateFoldWidgets=function(e){var t=e.data;t.first!=t.last&&this.foldWidgets.length>t.first&&this.foldWidgets.splice(t.first,this.foldWidgets.length)}}})),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],(function(e,t,n){"use strict";var i=e("../token_iterator").TokenIterator,r=e("../range").Range;t.BracketMatch=function(){this.findMatchingBracket=function(e,t){if(0==e.column)return null;var n=t||this.getLine(e.row).charAt(e.column-1);if(""==n)return null;var i=n.match(/([\(\[\{])|([\)\]\}])/);return i?i[1]?this.$findClosingBracket(i[1],e):this.$findOpeningBracket(i[2],e):null},this.getBracketRange=function(e){var t,n=this.getLine(e.row),i=!0,o=n.charAt(e.column-1),a=o&&o.match(/([\(\[\{])|([\)\]\}])/);if(a||(o=n.charAt(e.column),e={row:e.row,column:e.column+1},a=o&&o.match(/([\(\[\{])|([\)\]\}])/),i=!1),!a)return null;if(a[1]){if(!(s=this.$findClosingBracket(a[1],e)))return null;t=r.fromPoints(e,s),i||(t.end.column++,t.start.column--),t.cursor=t.end}else{var s;if(!(s=this.$findOpeningBracket(a[2],e)))return null;t=r.fromPoints(s,e),i||(t.start.column++,t.end.column--),t.cursor=t.start}return t},this.getMatchingBracketRanges=function(e,t){var n=this.getLine(e.row),i=/([\(\[\{])|([\)\]\}])/,o=!t&&n.charAt(e.column-1),a=o&&o.match(i);if(a||(o=(void 0===t||t)&&n.charAt(e.column),e={row:e.row,column:e.column+1},a=o&&o.match(i)),!a)return null;var s=new r(e.row,e.column-1,e.row,e.column),l=a[1]?this.$findClosingBracket(a[1],e):this.$findOpeningBracket(a[2],e);return l?[s,new r(l.row,l.column,l.row,l.column+1)]:[s]},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{","<":">",">":"<"},this.$findOpeningBracket=function(e,t,n){var r=this.$brackets[e],o=1,a=new i(this,t.row,t.column),s=a.getCurrentToken();if(s||(s=a.stepForward()),s){n||(n=new RegExp("(\\.?"+s.type.replace(".","\\.").replace("rparen",".paren").replace(/\b(?:end)\b/,"(?:start|begin|end)").replace(/-close\b/,"-(close|open)")+")+"));for(var l=t.column-a.getCurrentTokenColumn()-2,c=s.value;;){for(;l>=0;){var d=c.charAt(l);if(d==r){if(0==(o-=1))return{row:a.getCurrentTokenRow(),column:l+a.getCurrentTokenColumn()}}else d==e&&(o+=1);l-=1}do{s=a.stepBackward()}while(s&&!n.test(s.type));if(null==s)break;l=(c=s.value).length-1}return null}},this.$findClosingBracket=function(e,t,n){var r=this.$brackets[e],o=1,a=new i(this,t.row,t.column),s=a.getCurrentToken();if(s||(s=a.stepForward()),s){n||(n=new RegExp("(\\.?"+s.type.replace(".","\\.").replace("lparen",".paren").replace(/\b(?:start|begin)\b/,"(?:start|begin|end)").replace(/-open\b/,"-(close|open)")+")+"));for(var l=t.column-a.getCurrentTokenColumn();;){for(var c=s.value,d=c.length;l<d;){var u=c.charAt(l);if(u==r){if(0==(o-=1))return{row:a.getCurrentTokenRow(),column:l+a.getCurrentTokenColumn()}}else u==e&&(o+=1);l+=1}do{s=a.stepForward()}while(s&&!n.test(s.type));if(null==s)break;l=0}return null}},this.getMatchingTags=function(e){var t=new i(this,e.row,e.column),n=this.$findTagName(t);if(n)return"<"===t.stepBackward().value?this.$findClosingTag(t,n):this.$findOpeningTag(t,n)},this.$findTagName=function(e){var t=e.getCurrentToken(),n=!1,i=!1;if(t&&-1===t.type.indexOf("tag-name"))do{(t=i?e.stepBackward():e.stepForward())&&("/>"===t.value?i=!0:-1!==t.type.indexOf("tag-name")&&(n=!0))}while(t&&!n);return t},this.$findClosingTag=function(e,t){var n,i=t.value,o=t.value,a=0,s=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);t=e.stepForward();var l=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+t.value.length),c=!1;do{if(-1!==(n=t).type.indexOf("tag-close")&&!c){var d=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);c=!0}if(t=e.stepForward())if(">"!==t.value||c||(d=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1),c=!0),-1!==t.type.indexOf("tag-name")){if(o===(i=t.value))if("<"===n.value)a++;else if("</"===n.value&&--a<0){e.stepBackward();var u=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+2);t=e.stepForward();var h=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+t.value.length);if(-1===t.type.indexOf("tag-close")&&(t=e.stepForward()),!t||">"!==t.value)return;var p=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1)}}else o===i&&"/>"===t.value&&--a<0&&(p=h=u=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+2),d=new r(l.end.row,l.end.column,l.end.row,l.end.column+1))}while(t&&a>=0);if(s&&d&&u&&p&&l&&h)return{openTag:new r(s.start.row,s.start.column,d.end.row,d.end.column),closeTag:new r(u.start.row,u.start.column,p.end.row,p.end.column),openTagName:l,closeTagName:h}},this.$findOpeningTag=function(e,t){var n=e.getCurrentToken(),i=t.value,o=0,a=e.getCurrentTokenRow(),s=e.getCurrentTokenColumn(),l=s+2,c=new r(a,s,a,l);e.stepForward();var d=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+t.value.length);if(-1===t.type.indexOf("tag-close")&&(t=e.stepForward()),t&&">"===t.value){var u=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);e.stepBackward(),e.stepBackward();do{if(t=n,a=e.getCurrentTokenRow(),l=(s=e.getCurrentTokenColumn())+t.value.length,n=e.stepBackward(),t)if(-1!==t.type.indexOf("tag-name")){if(i===t.value)if("<"===n.value){if(++o>0){var h=new r(a,s,a,l),p=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1);do{t=e.stepForward()}while(t&&">"!==t.value);var g=new r(e.getCurrentTokenRow(),e.getCurrentTokenColumn(),e.getCurrentTokenRow(),e.getCurrentTokenColumn()+1)}}else"</"===n.value&&o--}else if("/>"===t.value){for(var f=0,m=n;m;){if(-1!==m.type.indexOf("tag-name")&&m.value===i){o--;break}if("<"===m.value)break;m=e.stepBackward(),f++}for(var y=0;y<f;y++)e.stepForward()}}while(n&&o<=0);return p&&g&&c&&u&&h&&d?{openTag:new r(p.start.row,p.start.column,g.end.row,g.end.column),closeTag:new r(c.start.row,c.start.column,u.end.row,u.end.column),openTagName:h,closeTagName:d}:void 0}}}})),ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/bidihandler","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/line_widgets","ace/document","ace/background_tokenizer","ace/search_highlight","ace/undomanager","ace/edit_session/folding","ace/edit_session/bracket_match"],(function(e,t,n){"use strict";var i=e("./lib/oop"),r=e("./lib/lang"),o=e("./bidihandler").BidiHandler,a=e("./config"),s=e("./lib/event_emitter").EventEmitter,l=e("./selection").Selection,c=e("./mode/text").Mode,d=e("./range").Range,u=e("./line_widgets").LineWidgets,h=e("./document").Document,p=e("./background_tokenizer").BackgroundTokenizer,g=e("./search_highlight").SearchHighlight,f=e("./undomanager").UndoManager,m=function(){function e(t,n){this.doc,this.$breakpoints=[],this.$decorations=[],this.$frontMarkers={},this.$backMarkers={},this.$markerId=1,this.$undoSelect=!0,this.$editor=null,this.prevOp={},this.$foldData=[],this.id="session"+ ++e.$uid,this.$foldData.toString=function(){return this.join("\n")},this.bgTokenizer=new p((new c).getTokenizer(),this);var i=this;this.bgTokenizer.on("update",(function(e){i._signal("tokenizerUpdate",e)})),this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this),"object"==typeof t&&t.getLine||(t=new h(t)),this.setDocument(t),this.selection=new l(this),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.selection.on("changeCursor",this.$onSelectionChange),this.$bidiHandler=new o(this),a.resetOptions(this),this.setMode(n),a._signal("session",this),this.destroyed=!1,this.$initOperationListeners()}return e.prototype.$initOperationListeners=function(){var e=this;this.curOp=null,this.on("change",(function(){e.curOp||(e.startOperation(),e.curOp.selectionBefore=e.$lastSel),e.curOp.docChanged=!0}),!0),this.on("changeSelection",(function(){e.curOp||(e.startOperation(),e.curOp.selectionBefore=e.$lastSel),e.curOp.selectionChanged=!0}),!0),this.$operationResetTimer=r.delayedCall(this.endOperation.bind(this,!0))},e.prototype.startOperation=function(e){if(this.curOp){if(!e||this.curOp.command)return;this.prevOp=this.curOp}e||(e={}),this.$operationResetTimer.schedule(),this.curOp={command:e.command||{},args:e.args},this.curOp.selectionBefore=this.selection.toJSON(),this._signal("startOperation",e)},e.prototype.endOperation=function(e){if(this.curOp){if(e&&!1===e.returnValue)return this.curOp=null,void this._signal("endOperation",e);if(1==e&&this.curOp.command&&"mouse"==this.curOp.command.name)return;var t=this.selection.toJSON();this.curOp.selectionAfter=t,this.$lastSel=this.selection.toJSON(),this.getUndoManager().addSelection(t),this._signal("beforeEndOperation"),this.prevOp=this.curOp,this.curOp=null,this._signal("endOperation",e)}},e.prototype.setDocument=function(e){this.doc&&this.doc.off("change",this.$onChange),this.doc=e,e.on("change",this.$onChange,!0),this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},e.prototype.getDocument=function(){return this.doc},Object.defineProperty(e.prototype,"widgetManager",{get:function(){var e=new u(this);return this.widgetManager=e,this.$editor&&e.attach(this.$editor),e},set:function(e){Object.defineProperty(this,"widgetManager",{writable:!0,enumerable:!0,configurable:!0,value:e})},enumerable:!1,configurable:!0}),e.prototype.$resetRowCache=function(e){if(!e)return this.$docRowCache=[],void(this.$screenRowCache=[]);var t=this.$docRowCache.length,n=this.$getRowCacheIndex(this.$docRowCache,e)+1;t>n&&(this.$docRowCache.splice(n,t),this.$screenRowCache.splice(n,t))},e.prototype.$getRowCacheIndex=function(e,t){for(var n=0,i=e.length-1;n<=i;){var r=n+i>>1,o=e[r];if(t>o)n=r+1;else{if(!(t<o))return r;i=r-1}}return n-1},e.prototype.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.destroyed||this.bgTokenizer.start(0)},e.prototype.onChangeFold=function(e){var t=e.data;this.$resetRowCache(t.start.row)},e.prototype.onChange=function(e){this.$modified=!0,this.$bidiHandler.onChange(e),this.$resetRowCache(e.start.row);var t=this.$updateInternalDataOnChange(e);!this.$fromUndo&&this.$undoManager&&(t&&t.length&&(this.$undoManager.add({action:"removeFolds",folds:t},this.mergeUndoDeltas),this.mergeUndoDeltas=!0),this.$undoManager.add(e,this.mergeUndoDeltas),this.mergeUndoDeltas=!0,this.$informUndoManager.schedule()),this.bgTokenizer.$updateOnChange(e),this._signal("change",e)},e.prototype.onSelectionChange=function(){this._signal("changeSelection")},e.prototype.setValue=function(e){this.doc.setValue(e),this.selection.moveTo(0,0),this.$resetRowCache(0),this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},e.fromJSON=function(t){"string"==typeof t&&(t=JSON.parse(t));var n=new f;n.$undoStack=t.history.undo,n.$redoStack=t.history.redo,n.mark=t.history.mark,n.$rev=t.history.rev;var i=new e(t.value);return t.folds.forEach((function(e){i.addFold("...",d.fromPoints(e.start,e.end))})),i.setAnnotations(t.annotations),i.setBreakpoints(t.breakpoints),i.setMode(t.mode),i.setScrollLeft(t.scrollLeft),i.setScrollTop(t.scrollTop),i.setUndoManager(n),i.selection.fromJSON(t.selection),i},e.prototype.toJSON=function(){return{annotations:this.$annotations,breakpoints:this.$breakpoints,folds:this.getAllFolds().map((function(e){return e.range})),history:this.getUndoManager(),mode:this.$mode.$id,scrollLeft:this.$scrollLeft,scrollTop:this.$scrollTop,selection:this.selection.toJSON(),value:this.doc.getValue()}},e.prototype.toString=function(){return this.doc.getValue()},e.prototype.getSelection=function(){return this.selection},e.prototype.getState=function(e){return this.bgTokenizer.getState(e)},e.prototype.getTokens=function(e){return this.bgTokenizer.getTokens(e)},e.prototype.getTokenAt=function(e,t){var n,i=this.bgTokenizer.getTokens(e),r=0;if(null==t){var o=i.length-1;r=this.getLine(e).length}else for(o=0;o<i.length&&!((r+=i[o].value.length)>=t);o++);return(n=i[o])?(n.index=o,n.start=r-n.value.length,n):null},e.prototype.setUndoManager=function(e){if(this.$undoManager=e,this.$informUndoManager&&this.$informUndoManager.cancel(),e){var t=this;e.addSession(this),this.$syncInformUndoManager=function(){t.$informUndoManager.cancel(),t.mergeUndoDeltas=!1},this.$informUndoManager=r.delayedCall(this.$syncInformUndoManager)}else this.$syncInformUndoManager=function(){}},e.prototype.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},e.prototype.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},e.prototype.getTabString=function(){return this.getUseSoftTabs()?r.stringRepeat(" ",this.getTabSize()):"\t"},e.prototype.setUseSoftTabs=function(e){this.setOption("useSoftTabs",e)},e.prototype.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},e.prototype.setTabSize=function(e){this.setOption("tabSize",e)},e.prototype.getTabSize=function(){return this.$tabSize},e.prototype.isTabStop=function(e){return this.$useSoftTabs&&e.column%this.$tabSize==0},e.prototype.setNavigateWithinSoftTabs=function(e){this.setOption("navigateWithinSoftTabs",e)},e.prototype.getNavigateWithinSoftTabs=function(){return this.$navigateWithinSoftTabs},e.prototype.setOverwrite=function(e){this.setOption("overwrite",e)},e.prototype.getOverwrite=function(){return this.$overwrite},e.prototype.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},e.prototype.addGutterDecoration=function(e,t){this.$decorations[e]||(this.$decorations[e]=""),this.$decorations[e]+=" "+t,this._signal("changeBreakpoint",{})},e.prototype.removeGutterDecoration=function(e,t){this.$decorations[e]=(this.$decorations[e]||"").replace(" "+t,""),this._signal("changeBreakpoint",{})},e.prototype.getBreakpoints=function(){return this.$breakpoints},e.prototype.setBreakpoints=function(e){this.$breakpoints=[];for(var t=0;t<e.length;t++)this.$breakpoints[e[t]]="ace_breakpoint";this._signal("changeBreakpoint",{})},e.prototype.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},e.prototype.setBreakpoint=function(e,t){void 0===t&&(t="ace_breakpoint"),t?this.$breakpoints[e]=t:delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},e.prototype.clearBreakpoint=function(e){delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},e.prototype.addMarker=function(e,t,n,i){var r=this.$markerId++,o={range:e,type:n||"line",renderer:"function"==typeof n?n:null,clazz:t,inFront:!!i,id:r};return i?(this.$frontMarkers[r]=o,this._signal("changeFrontMarker")):(this.$backMarkers[r]=o,this._signal("changeBackMarker")),r},e.prototype.addDynamicMarker=function(e,t){if(e.update){var n=this.$markerId++;return e.id=n,e.inFront=!!t,t?(this.$frontMarkers[n]=e,this._signal("changeFrontMarker")):(this.$backMarkers[n]=e,this._signal("changeBackMarker")),e}},e.prototype.removeMarker=function(e){var t=this.$frontMarkers[e]||this.$backMarkers[e];t&&(delete(t.inFront?this.$frontMarkers:this.$backMarkers)[e],this._signal(t.inFront?"changeFrontMarker":"changeBackMarker"))},e.prototype.getMarkers=function(e){return e?this.$frontMarkers:this.$backMarkers},e.prototype.highlight=function(e){if(!this.$searchHighlight){var t=new g(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(t)}this.$searchHighlight.setRegexp(e)},e.prototype.highlightLines=function(e,t,n,i){"number"!=typeof t&&(n=t,t=e),n||(n="ace_step");var r=new d(e,0,t,1/0);return r.id=this.addMarker(r,n,"fullLine",i),r},e.prototype.setAnnotations=function(e){this.$annotations=e,this._signal("changeAnnotation",{})},e.prototype.getAnnotations=function(){return this.$annotations||[]},e.prototype.clearAnnotations=function(){this.setAnnotations([])},e.prototype.$detectNewLine=function(e){var t=e.match(/^.*?(\r?\n)/m);this.$autoNewLine=t?t[1]:"\n"},e.prototype.getWordRange=function(e,t){var n=this.getLine(e),i=!1;if(t>0&&(i=!!n.charAt(t-1).match(this.tokenRe)),i||(i=!!n.charAt(t).match(this.tokenRe)),i)var r=this.tokenRe;else r=/^\s+$/.test(n.slice(t-1,t+1))?/\s/:this.nonTokenRe;var o=t;if(o>0){do{o--}while(o>=0&&n.charAt(o).match(r));o++}for(var a=t;a<n.length&&n.charAt(a).match(r);)a++;return new d(e,o,e,a)},e.prototype.getAWordRange=function(e,t){for(var n=this.getWordRange(e,t),i=this.getLine(n.end.row);i.charAt(n.end.column).match(/[ \t]/);)n.end.column+=1;return n},e.prototype.setNewLineMode=function(e){this.doc.setNewLineMode(e)},e.prototype.getNewLineMode=function(){return this.doc.getNewLineMode()},e.prototype.setUseWorker=function(e){this.setOption("useWorker",e)},e.prototype.getUseWorker=function(){return this.$useWorker},e.prototype.onReloadTokenizer=function(e){var t=e.data;this.bgTokenizer.start(t.first),this._signal("tokenizerUpdate",e)},e.prototype.setMode=function(e,t){if(e&&"object"==typeof e){if(e.getTokenizer)return this.$onChangeMode(e);var n=e,i=n.path}else i=e||"ace/mode/text";if(this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new c),this.$modes[i]&&!n)return this.$onChangeMode(this.$modes[i]),void(t&&t());this.$modeId=i,a.loadModule(["mode",i],function(e){if(!this.destroyed){if(this.$modeId!==i)return t&&t();this.$modes[i]&&!n?this.$onChangeMode(this.$modes[i]):e&&e.Mode&&(e=new e.Mode(n),n||(this.$modes[i]=e,e.$id=i),this.$onChangeMode(e)),t&&t()}}.bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},e.prototype.$onChangeMode=function(e,t){if(t||(this.$modeId=e.$id),this.$mode!==e){var n=this.$mode;this.$mode=e,this.$stopWorker(),this.$useWorker&&this.$startWorker();var i=e.getTokenizer();if(void 0!==i.on){var r=this.onReloadTokenizer.bind(this);i.on("update",r)}this.bgTokenizer.setTokenizer(i),this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=e.tokenRe,this.nonTokenRe=e.nonTokenRe,t||(e.attachToSession&&e.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(e.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode",{oldMode:n,mode:e}))}},e.prototype.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},e.prototype.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(e){a.warn("Could not load worker",e),this.$worker=null}},e.prototype.getMode=function(){return this.$mode},e.prototype.setScrollTop=function(e){this.$scrollTop===e||isNaN(e)||(this.$scrollTop=e,this._signal("changeScrollTop",e))},e.prototype.getScrollTop=function(){return this.$scrollTop},e.prototype.setScrollLeft=function(e){this.$scrollLeft===e||isNaN(e)||(this.$scrollLeft=e,this._signal("changeScrollLeft",e))},e.prototype.getScrollLeft=function(){return this.$scrollLeft},e.prototype.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},e.prototype.getLineWidgetMaxWidth=function(){if(null!=this.lineWidgetsWidth)return this.lineWidgetsWidth;var e=0;return this.lineWidgets.forEach((function(t){t&&t.screenWidth>e&&(e=t.screenWidth)})),this.lineWidgetWidth=e},e.prototype.$computeWidth=function(e){if(this.$modified||e){if(this.$modified=!1,this.$useWrapMode)return this.screenWidth=this.$wrapLimit;for(var t=this.doc.getAllLines(),n=this.$rowLengthCache,i=0,r=0,o=this.$foldData[r],a=o?o.start.row:1/0,s=t.length,l=0;l<s;l++){if(l>a){if((l=o.end.row+1)>=s)break;a=(o=this.$foldData[r++])?o.start.row:1/0}null==n[l]&&(n[l]=this.$getStringScreenWidth(t[l])[0]),n[l]>i&&(i=n[l])}this.screenWidth=i}},e.prototype.getLine=function(e){return this.doc.getLine(e)},e.prototype.getLines=function(e,t){return this.doc.getLines(e,t)},e.prototype.getLength=function(){return this.doc.getLength()},e.prototype.getTextRange=function(e){return this.doc.getTextRange(e||this.selection.getRange())},e.prototype.insert=function(e,t){return this.doc.insert(e,t)},e.prototype.remove=function(e){return this.doc.remove(e)},e.prototype.removeFullLines=function(e,t){return this.doc.removeFullLines(e,t)},e.prototype.undoChanges=function(e,t){if(e.length){this.$fromUndo=!0;for(var n=e.length-1;-1!=n;n--){var i=e[n];"insert"==i.action||"remove"==i.action?this.doc.revertDelta(i):i.folds&&this.addFolds(i.folds)}!t&&this.$undoSelect&&(e.selectionBefore?this.selection.fromJSON(e.selectionBefore):this.selection.setRange(this.$getUndoSelection(e,!0))),this.$fromUndo=!1}},e.prototype.redoChanges=function(e,t){if(e.length){this.$fromUndo=!0;for(var n=0;n<e.length;n++){var i=e[n];"insert"!=i.action&&"remove"!=i.action||this.doc.$safeApplyDelta(i)}!t&&this.$undoSelect&&(e.selectionAfter?this.selection.fromJSON(e.selectionAfter):this.selection.setRange(this.$getUndoSelection(e,!1))),this.$fromUndo=!1}},e.prototype.setUndoSelect=function(e){this.$undoSelect=e},e.prototype.$getUndoSelection=function(e,t){function n(e){return t?"insert"!==e.action:"insert"===e.action}for(var i,r,o=0;o<e.length;o++){var a=e[o];a.start&&(i?n(a)?(r=a.start,-1==i.compare(r.row,r.column)&&i.setStart(r),r=a.end,1==i.compare(r.row,r.column)&&i.setEnd(r)):(r=a.start,-1==i.compare(r.row,r.column)&&(i=d.fromPoints(a.start,a.start))):i=n(a)?d.fromPoints(a.start,a.end):d.fromPoints(a.start,a.start))}return i},e.prototype.replace=function(e,t){return this.doc.replace(e,t)},e.prototype.moveText=function(e,t,n){var i=this.getTextRange(e),r=this.getFoldsInRange(e),o=d.fromPoints(t,t);if(!n){this.remove(e);var a=e.start.row-e.end.row;(c=a?-e.end.column:e.start.column-e.end.column)&&(o.start.row==e.end.row&&o.start.column>e.end.column&&(o.start.column+=c),o.end.row==e.end.row&&o.end.column>e.end.column&&(o.end.column+=c)),a&&o.start.row>=e.end.row&&(o.start.row+=a,o.end.row+=a)}if(o.end=this.insert(o.start,i),r.length){var s=e.start,l=o.start,c=(a=l.row-s.row,l.column-s.column);this.addFolds(r.map((function(e){return(e=e.clone()).start.row==s.row&&(e.start.column+=c),e.end.row==s.row&&(e.end.column+=c),e.start.row+=a,e.end.row+=a,e})))}return o},e.prototype.indentRows=function(e,t,n){n=n.replace(/\t/g,this.getTabString());for(var i=e;i<=t;i++)this.doc.insertInLine({row:i,column:0},n)},e.prototype.outdentRows=function(e){for(var t=e.collapseRows(),n=new d(0,0,0,0),i=this.getTabSize(),r=t.start.row;r<=t.end.row;++r){var o=this.getLine(r);n.start.row=r,n.end.row=r;for(var a=0;a<i&&" "==o.charAt(a);++a);a<i&&"\t"==o.charAt(a)?(n.start.column=a,n.end.column=a+1):(n.start.column=0,n.end.column=a),this.remove(n)}},e.prototype.$moveLines=function(e,t,n){if(e=this.getRowFoldStart(e),t=this.getRowFoldEnd(t),n<0){if((r=this.getRowFoldStart(e+n))<0)return 0;var i=r-e}else if(n>0){var r;if((r=this.getRowFoldEnd(t+n))>this.doc.getLength()-1)return 0;i=r-t}else e=this.$clipRowToDocument(e),i=(t=this.$clipRowToDocument(t))-e+1;var o=new d(e,0,t,Number.MAX_VALUE),a=this.getFoldsInRange(o).map((function(e){return(e=e.clone()).start.row+=i,e.end.row+=i,e})),s=0==n?this.doc.getLines(e,t):this.doc.removeFullLines(e,t);return this.doc.insertFullLines(e+i,s),a.length&&this.addFolds(a),i},e.prototype.moveLinesUp=function(e,t){return this.$moveLines(e,t,-1)},e.prototype.moveLinesDown=function(e,t){return this.$moveLines(e,t,1)},e.prototype.duplicateLines=function(e,t){return this.$moveLines(e,t,0)},e.prototype.$clipRowToDocument=function(e){return Math.max(0,Math.min(e,this.doc.getLength()-1))},e.prototype.$clipColumnToRow=function(e,t){return t<0?0:Math.min(this.doc.getLine(e).length,t)},e.prototype.$clipPositionToDocument=function(e,t){if(t=Math.max(0,t),e<0)e=0,t=0;else{var n=this.doc.getLength();e>=n?(e=n-1,t=this.doc.getLine(n-1).length):t=Math.min(this.doc.getLine(e).length,t)}return{row:e,column:t}},e.prototype.$clipRangeToDocument=function(e){e.start.row<0?(e.start.row=0,e.start.column=0):e.start.column=this.$clipColumnToRow(e.start.row,e.start.column);var t=this.doc.getLength()-1;return e.end.row>t?(e.end.row=t,e.end.column=this.doc.getLine(t).length):e.end.column=this.$clipColumnToRow(e.end.row,e.end.column),e},e.prototype.setUseWrapMode=function(e){if(e!=this.$useWrapMode){if(this.$useWrapMode=e,this.$modified=!0,this.$resetRowCache(0),e){var t=this.getLength();this.$wrapData=Array(t),this.$updateWrapData(0,t-1)}this._signal("changeWrapMode")}},e.prototype.getUseWrapMode=function(){return this.$useWrapMode},e.prototype.setWrapLimitRange=function(e,t){this.$wrapLimitRange.min===e&&this.$wrapLimitRange.max===t||(this.$wrapLimitRange={min:e,max:t},this.$modified=!0,this.$bidiHandler.markAsDirty(),this.$useWrapMode&&this._signal("changeWrapMode"))},e.prototype.adjustWrapLimit=function(e,t){var n=this.$wrapLimitRange;n.max<0&&(n={min:t,max:t});var i=this.$constrainWrapLimit(e,n.min,n.max);return i!=this.$wrapLimit&&i>1&&(this.$wrapLimit=i,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0)},e.prototype.$constrainWrapLimit=function(e,t,n){return t&&(e=Math.max(t,e)),n&&(e=Math.min(n,e)),e},e.prototype.getWrapLimit=function(){return this.$wrapLimit},e.prototype.setWrapLimit=function(e){this.setWrapLimitRange(e,e)},e.prototype.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},e.prototype.$updateInternalDataOnChange=function(e){var t=this.$useWrapMode,n=e.action,i=e.start,r=e.end,o=i.row,a=r.row,s=a-o,l=null;if(this.$updating=!0,0!=s)if("remove"===n){this[t?"$wrapData":"$rowLengthCache"].splice(o,s);var c=this.$foldData;l=this.getFoldsInRange(e),this.removeFolds(l);var d=0;if(f=this.getFoldLine(r.row)){f.addRemoveChars(r.row,r.column,i.column-r.column),f.shiftRow(-s);var u=this.getFoldLine(o);u&&u!==f&&(u.merge(f),f=u),d=c.indexOf(f)+1}for(;d<c.length;d++)(f=c[d]).start.row>=r.row&&f.shiftRow(-s);a=o}else{var h=Array(s);h.unshift(o,0);var p=t?this.$wrapData:this.$rowLengthCache;if(p.splice.apply(p,h),c=this.$foldData,d=0,f=this.getFoldLine(o)){var g=f.range.compareInside(i.row,i.column);0==g?(f=f.split(i.row,i.column))&&(f.shiftRow(s),f.addRemoveChars(a,0,r.column-i.column)):-1==g&&(f.addRemoveChars(o,0,r.column-i.column),f.shiftRow(s)),d=c.indexOf(f)+1}for(;d<c.length;d++){var f;(f=c[d]).start.row>=o&&f.shiftRow(s)}}else s=Math.abs(e.start.column-e.end.column),"remove"===n&&(l=this.getFoldsInRange(e),this.removeFolds(l),s=-s),(f=this.getFoldLine(o))&&f.addRemoveChars(o,i.column,s);return t&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,t?this.$updateWrapData(o,a):this.$updateRowLengthCache(o,a),l},e.prototype.$updateRowLengthCache=function(e,t){this.$rowLengthCache[e]=null,this.$rowLengthCache[t]=null},e.prototype.$updateWrapData=function(e,t){var n,i,r=this.doc.getAllLines(),o=this.getTabSize(),a=this.$wrapData,s=this.$wrapLimit,l=e;for(t=Math.min(t,r.length-1);l<=t;)(i=this.getFoldLine(l,i))?(n=[],i.walk(function(e,t,i,o){var a;if(null!=e){(a=this.$getDisplayTokens(e,n.length))[0]=b;for(var s=1;s<a.length;s++)a[s]=w}else a=this.$getDisplayTokens(r[t].substring(o,i),n.length);n=n.concat(a)}.bind(this),i.end.row,r[i.end.row].length+1),a[i.start.row]=this.$computeWrapSplits(n,s,o),l=i.end.row+1):(n=this.$getDisplayTokens(r[l]),a[l]=this.$computeWrapSplits(n,s,o),l++)},e.prototype.$computeWrapSplits=function(e,t,n){if(0==e.length)return[];var i=[],r=e.length,o=0,a=0,s=this.$wrapAsCode,l=this.$indentedSoftWrap,c=t<=Math.max(2*n,8)||!1===l?0:Math.floor(t/2);function d(t){for(var r=t-o,d=o;d<t;d++){var h=e[d];12!==h&&2!==h||(r-=1)}i.length||(u=function(){var t=0;if(0===c)return t;if(l)for(var i=0;i<e.length;i++){var r=e[i];if(r==x)t+=1;else{if(r!=S){if(r==_)continue;break}t+=n}}return s&&!1!==l&&(t+=n),Math.min(t,c)}(),i.indent=u),a+=r,i.push(a),o=t}for(var u=0;r-o>t-u;){var h=o+t-u;if(e[h-1]>=x&&e[h]>=x)d(h);else if(e[h]!=b&&e[h]!=w){for(var p=Math.max(h-(t-(t>>2)),o-1);h>p&&e[h]<b;)h--;if(s){for(;h>p&&e[h]<b;)h--;for(;h>p&&e[h]==C;)h--}else for(;h>p&&e[h]<x;)h--;h>p?d(++h):(e[h=o+t]==v&&h--,d(h-u))}else{for(;h!=o-1&&e[h]!=b;h--);if(h>o){d(h);continue}for(h=o+t;h<e.length&&e[h]==w;h++);if(h==e.length)break;d(h)}}return i},e.prototype.$getDisplayTokens=function(e,t){var n,i=[];t=t||0;for(var r=0;r<e.length;r++){var o=e.charCodeAt(r);if(9==o){n=this.getScreenTabSize(i.length+t),i.push(S);for(var a=1;a<n;a++)i.push(_)}else 32==o?i.push(x):o>39&&o<48||o>57&&o<64?i.push(C):o>=4352&&E(o)?i.push(y,v):i.push(y)}return i},e.prototype.$getStringScreenWidth=function(e,t,n){if(0==t)return[0,0];var i,r;for(null==t&&(t=1/0),n=n||0,r=0;r<e.length&&(9==(i=e.charCodeAt(r))?n+=this.getScreenTabSize(n):i>=4352&&E(i)?n+=2:n+=1,!(n>t));r++);return[n,r]},e.prototype.getRowLength=function(e){var t=1;return this.lineWidgets&&(t+=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0),this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+t:t},e.prototype.getRowLineCount=function(e){return this.$useWrapMode&&this.$wrapData[e]?this.$wrapData[e].length+1:1},e.prototype.getRowWrapIndent=function(e){if(this.$useWrapMode){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE),n=this.$wrapData[t.row];return n.length&&n[0]<t.column?n.indent:0}return 0},e.prototype.getScreenLastRowColumn=function(e){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE);return this.documentToScreenColumn(t.row,t.column)},e.prototype.getDocumentLastRowColumn=function(e,t){var n=this.documentToScreenRow(e,t);return this.getScreenLastRowColumn(n)},e.prototype.getDocumentLastRowColumnPosition=function(e,t){var n=this.documentToScreenRow(e,t);return this.screenToDocumentPosition(n,Number.MAX_VALUE/10)},e.prototype.getRowSplitData=function(e){return this.$useWrapMode?this.$wrapData[e]:void 0},e.prototype.getScreenTabSize=function(e){return this.$tabSize-(e%this.$tabSize|0)},e.prototype.screenToDocumentRow=function(e,t){return this.screenToDocumentPosition(e,t).row},e.prototype.screenToDocumentColumn=function(e,t){return this.screenToDocumentPosition(e,t).column},e.prototype.screenToDocumentPosition=function(e,t,n){if(e<0)return{row:0,column:0};var i,r,o=0,a=0,s=0,l=0,c=this.$screenRowCache,d=this.$getRowCacheIndex(c,e),u=c.length;if(u&&d>=0){s=c[d],o=this.$docRowCache[d];var h=e>c[u-1]}else h=!u;for(var p=this.getLength()-1,g=this.getNextFoldLine(o),f=g?g.start.row:1/0;s<=e&&!(s+(l=this.getRowLength(o))>e||o>=p);)s+=l,++o>f&&(o=g.end.row+1,f=(g=this.getNextFoldLine(o,g))?g.start.row:1/0),h&&(this.$docRowCache.push(o),this.$screenRowCache.push(s));if(g&&g.start.row<=o)i=this.getFoldDisplayLine(g),o=g.start.row;else{if(s+l<=e||o>p)return{row:p,column:this.getLine(p).length};i=this.getLine(o),g=null}var m=0,y=Math.floor(e-s);if(this.$useWrapMode){var v=this.$wrapData[o];v&&(r=v[y],y>0&&v.length&&(m=v.indent,a=v[y-1]||v[v.length-1],i=i.substring(a)))}return void 0!==n&&this.$bidiHandler.isBidiRow(s+y,o,y)&&(t=this.$bidiHandler.offsetToCol(n)),a+=this.$getStringScreenWidth(i,t-m)[1],this.$useWrapMode&&a>=r&&(a=r-1),g?g.idxToPosition(a):{row:o,column:a}},e.prototype.documentToScreenPosition=function(e,t){if(void 0===t)var n=this.$clipPositionToDocument(e.row,e.column);else n=this.$clipPositionToDocument(e,t);e=n.row,t=n.column;var i,r=0,o=null;(i=this.getFoldAt(e,t,1))&&(e=i.start.row,t=i.start.column);var a,s=0,l=this.$docRowCache,c=this.$getRowCacheIndex(l,e),d=l.length;if(d&&c>=0){s=l[c],r=this.$screenRowCache[c];var u=e>l[d-1]}else u=!d;for(var h=this.getNextFoldLine(s),p=h?h.start.row:1/0;s<e;){if(s>=p){if((a=h.end.row+1)>e)break;p=(h=this.getNextFoldLine(a,h))?h.start.row:1/0}else a=s+1;r+=this.getRowLength(s),s=a,u&&(this.$docRowCache.push(s),this.$screenRowCache.push(r))}var g="";h&&s>=p?(g=this.getFoldDisplayLine(h,e,t),o=h.start.row):(g=this.getLine(e).substring(0,t),o=e);var f=0;if(this.$useWrapMode){var m=this.$wrapData[o];if(m){for(var y=0;g.length>=m[y];)r++,y++;g=g.substring(m[y-1]||0,g.length),f=y>0?m.indent:0}}return this.lineWidgets&&this.lineWidgets[s]&&this.lineWidgets[s].rowsAbove&&(r+=this.lineWidgets[s].rowsAbove),{row:r,column:f+this.$getStringScreenWidth(g)[0]}},e.prototype.documentToScreenColumn=function(e,t){return this.documentToScreenPosition(e,t).column},e.prototype.documentToScreenRow=function(e,t){return this.documentToScreenPosition(e,t).row},e.prototype.getScreenLength=function(){var e=0,t=null;if(this.$useWrapMode)for(var n=this.$wrapData.length,i=0,r=(s=0,(t=this.$foldData[s++])?t.start.row:1/0);i<n;){var o=this.$wrapData[i];e+=o?o.length+1:1,++i>r&&(i=t.end.row+1,r=(t=this.$foldData[s++])?t.start.row:1/0)}else{e=this.getLength();for(var a=this.$foldData,s=0;s<a.length;s++)e-=(t=a[s]).end.row-t.start.row}return this.lineWidgets&&(e+=this.$getWidgetScreenLength()),e},e.prototype.$setFontMetrics=function(e){this.$enableVarChar&&(this.$getStringScreenWidth=function(t,n,i){if(0===n)return[0,0];var r,o;for(n||(n=1/0),i=i||0,o=0;o<t.length&&!((i+="\t"===(r=t.charAt(o))?this.getScreenTabSize(i):e.getCharacterWidth(r))>n);o++);return[i,o]})},e.prototype.getPrecedingCharacter=function(){var e=this.selection.getCursor();return 0===e.column?0===e.row?"":this.doc.getNewLineCharacter():this.getLine(e.row)[e.column-1]},e.prototype.destroy=function(){this.destroyed||(this.bgTokenizer.setDocument(null),this.bgTokenizer.cleanup(),this.destroyed=!0),this.endOperation(),this.$stopWorker(),this.removeAllListeners(),this.doc&&this.doc.off("change",this.$onChange),this.selection&&(this.selection.off("changeCursor",this.$onSelectionChange),this.selection.off("changeSelection",this.$onSelectionChange)),this.selection.detach()},e}();m.$uid=0,m.prototype.$modes=a.$modes,m.prototype.getValue=m.prototype.toString,m.prototype.$defaultUndoManager={undo:function(){},redo:function(){},hasUndo:function(){},hasRedo:function(){},reset:function(){},add:function(){},addSelection:function(){},startNewGroup:function(){},addSession:function(){}},m.prototype.$overwrite=!1,m.prototype.$mode=null,m.prototype.$modeId=null,m.prototype.$scrollTop=0,m.prototype.$scrollLeft=0,m.prototype.$wrapLimit=80,m.prototype.$useWrapMode=!1,m.prototype.$wrapLimitRange={min:null,max:null},m.prototype.lineWidgets=null,m.prototype.isFullWidth=E,i.implement(m.prototype,s);var y=1,v=2,b=3,w=4,C=9,x=10,S=11,_=12;function E(e){return!(e<4352)&&(e>=4352&&e<=4447||e>=4515&&e<=4519||e>=4602&&e<=4607||e>=9001&&e<=9002||e>=11904&&e<=11929||e>=11931&&e<=12019||e>=12032&&e<=12245||e>=12272&&e<=12283||e>=12288&&e<=12350||e>=12353&&e<=12438||e>=12441&&e<=12543||e>=12549&&e<=12589||e>=12593&&e<=12686||e>=12688&&e<=12730||e>=12736&&e<=12771||e>=12784&&e<=12830||e>=12832&&e<=12871||e>=12880&&e<=13054||e>=13056&&e<=19903||e>=19968&&e<=42124||e>=42128&&e<=42182||e>=43360&&e<=43388||e>=44032&&e<=55203||e>=55216&&e<=55238||e>=55243&&e<=55291||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65106||e>=65108&&e<=65126||e>=65128&&e<=65131||e>=65281&&e<=65376||e>=65504&&e<=65510)}e("./edit_session/folding").Folding.call(m.prototype),e("./edit_session/bracket_match").BracketMatch.call(m.prototype),a.defineOptions(m.prototype,"session",{wrap:{set:function(e){if(e&&"off"!=e?"free"==e?e=!0:"printMargin"==e?e=-1:"string"==typeof e&&(e=parseInt(e,10)||!1):e=!1,this.$wrap!=e)if(this.$wrap=e,e){var t="number"==typeof e?e:null;this.setWrapLimitRange(t,t),this.setUseWrapMode(!0)}else this.setUseWrapMode(!1)},get:function(){return this.getUseWrapMode()?-1==this.$wrap?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(e){(e="auto"==e?"text"!=this.$mode.type:"text"!=e)!=this.$wrapAsCode&&(this.$wrapAsCode=e,this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0)))},initialValue:"auto"},indentedSoftWrap:{set:function(){this.$useWrapMode&&(this.$useWrapMode=!1,this.setUseWrapMode(!0))},initialValue:!0},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(e){this.$useWorker=e,this.$stopWorker(),e&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(e){(e=parseInt(e))>0&&this.$tabSize!==e&&(this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=e,this._signal("changeTabSize"))},initialValue:4,handlesSet:!0},navigateWithinSoftTabs:{initialValue:!1},foldStyle:{set:function(e){this.setFoldStyle(e)},handlesSet:!0},overwrite:{set:function(e){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(e){this.doc.setNewLineMode(e)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(e){this.setMode(e)},get:function(){return this.$modeId},handlesSet:!0}}),t.EditSession=m})),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],(function(e,t,n){"use strict";var i=e("./lib/lang"),r=e("./lib/oop"),o=e("./range").Range,a=function(){function e(){this.$options={}}return e.prototype.set=function(e){return r.mixin(this.$options,e),this},e.prototype.getOptions=function(){return i.copyObject(this.$options)},e.prototype.setOptions=function(e){this.$options=e},e.prototype.find=function(e){var t=this.$options,n=this.$matchIterator(e,t);if(!n)return!1;var i=null;return n.forEach((function(e,n,r,a){return i=new o(e,n,r,a),!(n==a&&t.start&&t.start.start&&0!=t.skipCurrent&&i.isEqual(t.start)&&(i=null,1))})),i},e.prototype.findAll=function(e){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var n=t.range,r=n?e.getLines(n.start.row,n.end.row):e.doc.getAllLines(),a=[],s=t.re;if(t.$isMultiLine){var l,c=s.length,d=r.length-c;e:for(var u=s.offset||0;u<=d;u++){for(var h=0;h<c;h++)if(-1==r[u+h].search(s[h]))continue e;var p=r[u],g=r[u+c-1],f=p.length-p.match(s[0])[0].length,m=g.match(s[c-1])[0].length;l&&l.end.row===u&&l.end.column>f||(a.push(l=new o(u,f,u+c-1,m)),c>2&&(u=u+c-2))}}else for(var y,v=0;v<r.length;v++)if(this.$isMultilineSearch(t)){var b=r.length-1;if(y=this.$multiLineForward(e,s,v,b)){var w=y.endRow<=b?y.endRow-1:b;w>v&&(v=w),a.push(new o(y.startRow,y.startCol,y.endRow,y.endCol))}}else for(y=i.getMatchOffsets(r[v],s),h=0;h<y.length;h++){var C=y[h];a.push(new o(v,C.offset,v,C.offset+C.length))}if(n){var x=n.start.column,S=n.end.column;for(v=0,h=a.length-1;v<h&&a[v].start.column<x&&0==a[v].start.row;)v++;for(var _=n.end.row-n.start.row;v<h&&a[h].end.column>S&&a[h].end.row==_;)h--;for(a=a.slice(v,h+1),v=0,h=a.length;v<h;v++)a[v].start.row+=n.start.row,a[v].end.row+=n.start.row}return a},e.prototype.parseReplaceString=function(e){for(var t="",n=0,i=e.length;n<i;n++){var r=e.charCodeAt(n);if(92!==r){if(36===r){if(++n>=i){t+="$";break}var o=e.charCodeAt(n);if(36===o){t+="$$";continue}if(48===o||38===o){t+="$&";continue}if(49<=o&&o<=57){t+="$"+e[n];continue}}t+=e[n]}else{if(++n>=i){t+="\\";break}switch(e.charCodeAt(n)){case 92:t+="\\";break;case 110:t+="\n";break;case 116:t+="\t"}}}return t||e},e.prototype.replace=function(e,t){var n=this.$options,i=this.$assembleRegExp(n);if(n.$isMultiLine)return t;if(i){var r=this.$isMultilineSearch(n);r&&(e=e.replace(/\r\n|\r|\n/g,"\n"));var o=i.exec(e);if(!o||!r&&o[0].length!=e.length)return null;if(t=n.regExp?this.parseReplaceString(t):t.replace(/\$/g,"$$$$"),t=e.replace(i,t),n.preserveCase){t=t.split("");for(var a=Math.min(e.length,e.length);a--;){var s=e[a];s&&s.toLowerCase()!=s?t[a]=t[a].toUpperCase():t[a]=t[a].toLowerCase()}t=t.join("")}return t}},e.prototype.$assembleRegExp=function(e,t){if(e.needle instanceof RegExp)return e.re=e.needle;var n=e.needle;if(!e.needle)return e.re=!1;e.regExp||(n=i.escapeRegExp(n));var r=e.caseSensitive?"gm":"gmi";try{new RegExp(n,"u"),e.$supportsUnicodeFlag=!0,r+="u"}catch(t){e.$supportsUnicodeFlag=!1}if(e.wholeWord&&(n=function(e,t){var n=i.supportsLookbehind();function r(e,i){return void 0===i&&(i=!0),(n&&t.$supportsUnicodeFlag?new RegExp("[\\p{L}\\p{N}_]","u"):new RegExp("\\w")).test(e)||t.regExp?n&&t.$supportsUnicodeFlag?i?"(?<=^|[^\\p{L}\\p{N}_])":"(?=[^\\p{L}\\p{N}_]|$)":"\\b":""}var o=Array.from(e),a=o[0],s=o[o.length-1];return r(a)+e+r(s,!1)}(n,e)),e.$isMultiLine=!t&&/[\n\r]/.test(n),e.$isMultiLine)return e.re=this.$assembleMultilineRegExp(n,r);try{var o=new RegExp(n,r)}catch(e){o=!1}return e.re=o},e.prototype.$assembleMultilineRegExp=function(e,t){for(var n=e.replace(/\r\n|\r|\n/g,"$\n^").split("\n"),i=[],r=0;r<n.length;r++)try{i.push(new RegExp(n[r],t))}catch(e){return!1}return i},e.prototype.$isMultilineSearch=function(e){return e.re&&/\\r\\n|\\r|\\n/.test(e.re.source)&&e.regExp&&!e.$isMultiLine},e.prototype.$multiLineForward=function(e,t,n,i){for(var r,o=l(e,n),a=n;a<=i;){for(var s=0;s<o&&!(a>i);s++){var c=e.getLine(a++);r=null==r?c:r+"\n"+c}var d=t.exec(r);if(t.lastIndex=0,d){var u=r.slice(0,d.index).split("\n"),h=d[0].split("\n"),p=n+u.length-1,g=u[u.length-1].length;return{startRow:p,startCol:g,endRow:p+h.length-1,endCol:1==h.length?g+h[0].length:h[h.length-1].length}}}return null},e.prototype.$multiLineBackward=function(e,t,n,i,r){for(var o,a=l(e,i),c=e.getLine(i).length-n,d=i;d>=r;){for(var u=0;u<a&&d>=r;u++){var h=e.getLine(d--);o=null==o?h:h+"\n"+o}var p=s(o,t,c);if(p){var g=o.slice(0,p.index).split("\n"),f=p[0].split("\n"),m=d+g.length,y=g[g.length-1].length;return{startRow:m,startCol:y,endRow:m+f.length-1,endCol:1==f.length?y+f[0].length:f[f.length-1].length}}}return null},e.prototype.$matchIterator=function(e,t){var n=this.$assembleRegExp(t);if(!n)return!1;var r=this.$isMultilineSearch(t),o=this.$multiLineForward,a=this.$multiLineBackward,s=1==t.backwards,l=0!=t.skipCurrent,c=n.unicode,d=t.range,u=t.start;u||(u=d?d[s?"end":"start"]:e.selection.getRange()),u.start&&(u=u[l!=s?"end":"start"]);var h=d?d.start.row:0,p=d?d.end.row:e.getLength()-1;if(s)var g=function(e){var n=u.row;if(!m(n,u.column,e)){for(n--;n>=h;n--)if(m(n,Number.MAX_VALUE,e))return;if(0!=t.wrap)for(n=p,h=u.row;n>=h;n--)if(m(n,Number.MAX_VALUE,e))return}};else g=function(e){var n=u.row;if(!m(n,u.column,e)){for(n+=1;n<=p;n++)if(m(n,0,e))return;if(0!=t.wrap)for(n=h,p=u.row;n<=p;n++)if(m(n,0,e))return}};if(t.$isMultiLine)var f=n.length,m=function(t,i,r){var o=s?t-f+1:t;if(!(o<0||o+f>e.getLength())){var a=e.getLine(o),l=a.search(n[0]);if(!(!s&&l<i||-1===l)){for(var c=1;c<f;c++)if(-1==(a=e.getLine(o+c)).search(n[c]))return;var d=a.match(n[f-1])[0].length;if(!(s&&d>i))return!!r(o,l,o+f-1,d)||void 0}}};else m=s?function(t,o,s){if(r){var l=a(e,n,o,t,h);if(!l)return!1;if(s(l.startRow,l.startCol,l.endRow,l.endCol))return!0}else{var d,u=e.getLine(t),p=[],g=0;for(n.lastIndex=0;d=n.exec(u);){var f=d[0].length;if(g=d.index,!f){if(g>=u.length)break;n.lastIndex=g+=i.skipEmptyMatch(u,g,c)}if(d.index+f>o)break;p.push(d.index,f)}for(var m=p.length-1;m>=0;m-=2){var y=p[m-1];if(s(t,y,t,y+(f=p[m])))return!0}}}:function(t,a,s){if(n.lastIndex=a,r){var l=o(e,n,t,p);if(l){var d=l.endRow<=p?l.endRow-1:p;d>t&&(t=d)}if(!l)return!1;if(s(l.startRow,l.startCol,l.endRow,l.endCol))return!0}else for(var u,h,g=e.getLine(t);h=n.exec(g);){var f=h[0].length;if(s(t,u=h.index,t,u+f))return!0;if(!f&&(n.lastIndex=u+=i.skipEmptyMatch(g,u,c),u>=g.length))return!1}};return{forEach:g}},e}();function s(e,t,n){for(var i=null,r=0;r<=e.length;){t.lastIndex=r;var o=t.exec(e);if(!o)break;var a=o.index+o[0].length;if(a>e.length-n)break;(!i||a>i.index+i[0].length)&&(i=o),r=o.index+1}return i}function l(e,t){var n={row:t,column:0},i=e.doc.positionToIndex(n)+5e3;return e.doc.indexToPosition(i).row+1}t.Search=a})),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],(function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../lib/keys"),a=e("../lib/useragent"),s=o.KEY_MODS,l=function(){function e(e,t){this.$init(e,t,!1)}return e.prototype.$init=function(e,t,n){this.platform=t||(a.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={},this.addCommands(e),this.$singleCommand=n},e.prototype.addCommand=function(e){this.commands[e.name]&&this.removeCommand(e),this.commands[e.name]=e,e.bindKey&&this._buildKeyHash(e)},e.prototype.removeCommand=function(e,t){var n=e&&("string"==typeof e?e:e.name);e=this.commands[n],t||delete this.commands[n];var i=this.commandKeyBinding;for(var r in i){var o=i[r];if(o==e)delete i[r];else if(Array.isArray(o)){var a=o.indexOf(e);-1!=a&&(o.splice(a,1),1==o.length&&(i[r]=o[0]))}}},e.prototype.bindKey=function(e,t,n){if("object"==typeof e&&e&&(null==n&&(n=e.position),e=e[this.platform]),e)return"function"==typeof t?this.addCommand({exec:t,bindKey:e,name:t.name||e}):void e.split("|").forEach((function(e){var i="";if(-1!=e.indexOf(" ")){var r=e.split(/\s+/);e=r.pop(),r.forEach((function(e){var t=this.parseKeys(e),n=s[t.hashId]+t.key;i+=(i?" ":"")+n,this._addCommandToBinding(i,"chainKeys")}),this),i+=" "}var o=this.parseKeys(e),a=s[o.hashId]+o.key;this._addCommandToBinding(i+a,t,n)}),this)},e.prototype._addCommandToBinding=function(e,t,n){var i,r=this.commandKeyBinding;if(t)if(!r[e]||this.$singleCommand)r[e]=t;else{Array.isArray(r[e])?-1!=(i=r[e].indexOf(t))&&r[e].splice(i,1):r[e]=[r[e]],"number"!=typeof n&&(n=c(t));var o=r[e];for(i=0;i<o.length&&!(c(o[i])>n);i++);o.splice(i,0,t)}else delete r[e]},e.prototype.addCommands=function(e){e&&Object.keys(e).forEach((function(t){var n=e[t];if(n){if("string"==typeof n)return this.bindKey(n,t);"function"==typeof n&&(n={exec:n}),"object"==typeof n&&(n.name||(n.name=t),this.addCommand(n))}}),this)},e.prototype.removeCommands=function(e){Object.keys(e).forEach((function(t){this.removeCommand(e[t])}),this)},e.prototype.bindKeys=function(e){Object.keys(e).forEach((function(t){this.bindKey(t,e[t])}),this)},e.prototype._buildKeyHash=function(e){this.bindKey(e.bindKey,e)},e.prototype.parseKeys=function(e){var t=e.toLowerCase().split(/[\-\+]([\-\+])?/).filter((function(e){return e})),n=t.pop(),i=o[n];if(o.FUNCTION_KEYS[i])n=o.FUNCTION_KEYS[i].toLowerCase();else{if(!t.length)return{key:n,hashId:-1};if(1==t.length&&"shift"==t[0])return{key:n.toUpperCase(),hashId:-1}}for(var r=0,a=t.length;a--;){var s=o.KEY_MODS[t[a]];if(null==s)return"undefined"!=typeof console&&console.error("invalid modifier "+t[a]+" in "+e),!1;r|=s}return{key:n,hashId:r}},e.prototype.findKeyCommand=function(e,t){var n=s[e]+t;return this.commandKeyBinding[n]},e.prototype.handleKeyboard=function(e,t,n,i){if(!(i<0)){var r=s[t]+n,o=this.commandKeyBinding[r];return e.$keyChain&&(e.$keyChain+=" "+r,o=this.commandKeyBinding[e.$keyChain]||o),!o||"chainKeys"!=o&&"chainKeys"!=o[o.length-1]?(e.$keyChain&&(t&&4!=t||1!=n.length?(-1==t||i>0)&&(e.$keyChain=""):e.$keyChain=e.$keyChain.slice(0,-r.length-1)),{command:o}):(e.$keyChain=e.$keyChain||r,{command:"null"})}},e.prototype.getStatusText=function(e,t){return t.$keyChain||""},e}();function c(e){return"object"==typeof e&&e.bindKey&&e.bindKey.position||(e.isDefault?-100:0)}var d=function(e){function t(t,n){var i=e.call(this,t,n)||this;return i.$singleCommand=!0,i}return r(t,e),t}(l);d.call=function(e,t,n){l.prototype.$init.call(e,t,n,!0)},l.call=function(e,t,n){l.prototype.$init.call(e,t,n,!1)},t.HashHandler=d,t.MultiHashHandler=l})),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],(function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("../lib/oop"),a=e("../keyboard/hash_handler").MultiHashHandler,s=e("../lib/event_emitter").EventEmitter,l=function(e){function t(t,n){var i=e.call(this,n,t)||this;return i.byName=i.commands,i.setDefaultHandler("exec",(function(e){return e.args?e.command.exec(e.editor,e.args,e.event,!1):e.command.exec(e.editor,{},e.event,!0)})),i}return r(t,e),t.prototype.exec=function(e,t,n){if(Array.isArray(e)){for(var i=e.length;i--;)if(this.exec(e[i],t,n))return!0;return!1}"string"==typeof e&&(e=this.commands[e]);var r={editor:t,command:e,args:n};return this.canExecute(e,t)?(r.returnValue=this._emit("exec",r),this._signal("afterExec",r),!1!==r.returnValue):(this._signal("commandUnavailable",r),!1)},t.prototype.canExecute=function(e,t){return"string"==typeof e&&(e=this.commands[e]),!(!e||t&&t.$readOnly&&!e.readOnly||0!=this.$checkCommandState&&e.isAvailable&&!e.isAvailable(t))},t.prototype.toggleRecording=function(e){if(!this.$inReplay)return e&&e._emit("changeStatus"),this.recording?(this.macro.pop(),this.off("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=function(e){this.macro.push([e.command,e.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},t.prototype.replay=function(e){if(!this.$inReplay&&this.macro){if(this.recording)return this.toggleRecording(e);try{this.$inReplay=!0,this.macro.forEach((function(t){"string"==typeof t?this.exec(t,e):this.exec(t[0],e,t[1])}),this)}finally{this.$inReplay=!1}}},t.prototype.trimMacro=function(e){return e.map((function(e){return"string"!=typeof e[0]&&(e[0]=e[0].name),e[1]||(e=e[0]),e}))},t}(a);o.implement(l.prototype,s),t.CommandManager=l})),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],(function(e,t,n){"use strict";var i=e("../lib/lang"),r=e("../config"),o=e("../range").Range;function a(e,t){return{win:e,mac:t}}t.commands=[{name:"showSettingsMenu",description:"Show settings menu",bindKey:a("Ctrl-,","Command-,"),exec:function(e){r.loadModule("ace/ext/settings_menu",(function(t){t.init(e),e.showSettingsMenu()}))},readOnly:!0},{name:"goToNextError",description:"Go to next error",bindKey:a("Alt-E","F4"),exec:function(e){r.loadModule("ace/ext/error_marker",(function(t){t.showErrorMarker(e,1)}))},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",description:"Go to previous error",bindKey:a("Alt-Shift-E","Shift-F4"),exec:function(e){r.loadModule("ace/ext/error_marker",(function(t){t.showErrorMarker(e,-1)}))},scrollIntoView:"animate",readOnly:!0},{name:"selectall",description:"Select all",bindKey:a("Ctrl-A","Command-A"),exec:function(e){e.selectAll()},readOnly:!0},{name:"centerselection",description:"Center selection",bindKey:a(null,"Ctrl-L"),exec:function(e){e.centerSelection()},readOnly:!0},{name:"gotoline",description:"Go to line...",bindKey:a("Ctrl-L","Command-L"),exec:function(e,t){"number"!=typeof t||isNaN(t)||e.gotoLine(t),e.prompt({$type:"gotoLine"})},readOnly:!0},{name:"fold",bindKey:a("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(e){e.session.toggleFold(!1)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:a("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(e){e.session.toggleFold(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",description:"Toggle fold widget",bindKey:a("F2","F2"),exec:function(e){e.session.toggleFoldWidget()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",description:"Toggle parent fold widget",bindKey:a("Alt-F2","Alt-F2"),exec:function(e){e.session.toggleFoldWidget(!0)},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"foldall",description:"Fold all",bindKey:a(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldAllComments",description:"Fold all comments",bindKey:a(null,"Ctrl-Command-Option-0"),exec:function(e){e.session.foldAllComments()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",description:"Fold other",bindKey:a("Alt-0","Command-Option-0"),exec:function(e){e.session.foldAll(),e.session.unfold(e.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",description:"Unfold all",bindKey:a("Alt-Shift-0","Command-Option-Shift-0"),exec:function(e){e.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",description:"Find next",bindKey:a("Ctrl-K","Command-G"),exec:function(e){e.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",description:"Find previous",bindKey:a("Ctrl-Shift-K","Command-Shift-G"),exec:function(e){e.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",description:"Select or find next",bindKey:a("Alt-K","Ctrl-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findNext()},readOnly:!0},{name:"selectOrFindPrevious",description:"Select or find previous",bindKey:a("Alt-Shift-K","Ctrl-Shift-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findPrevious()},readOnly:!0},{name:"find",description:"Find",bindKey:a("Ctrl-F","Command-F"),exec:function(e){r.loadModule("ace/ext/searchbox",(function(t){t.Search(e)}))},readOnly:!0},{name:"overwrite",description:"Overwrite",bindKey:"Insert",exec:function(e){e.toggleOverwrite()},readOnly:!0},{name:"selecttostart",description:"Select to start",bindKey:a("Ctrl-Shift-Home","Command-Shift-Home|Command-Shift-Up"),exec:function(e){e.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",description:"Go to start",bindKey:a("Ctrl-Home","Command-Home|Command-Up"),exec:function(e){e.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",description:"Select up",bindKey:a("Shift-Up","Shift-Up|Ctrl-Shift-P"),exec:function(e){e.getSelection().selectUp()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golineup",description:"Go line up",bindKey:a("Up","Up|Ctrl-P"),exec:function(e,t){e.navigateUp(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttoend",description:"Select to end",bindKey:a("Ctrl-Shift-End","Command-Shift-End|Command-Shift-Down"),exec:function(e){e.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",description:"Go to end",bindKey:a("Ctrl-End","Command-End|Command-Down"),exec:function(e){e.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",description:"Select down",bindKey:a("Shift-Down","Shift-Down|Ctrl-Shift-N"),exec:function(e){e.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",description:"Go line down",bindKey:a("Down","Down|Ctrl-N"),exec:function(e,t){e.navigateDown(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",description:"Select word left",bindKey:a("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(e){e.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",description:"Go to word left",bindKey:a("Ctrl-Left","Option-Left"),exec:function(e){e.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",description:"Select to line start",bindKey:a("Alt-Shift-Left","Command-Shift-Left|Ctrl-Shift-A"),exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",description:"Go to line start",bindKey:a("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(e){e.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",description:"Select left",bindKey:a("Shift-Left","Shift-Left|Ctrl-Shift-B"),exec:function(e){e.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",description:"Go to left",bindKey:a("Left","Left|Ctrl-B"),exec:function(e,t){e.navigateLeft(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",description:"Select word right",bindKey:a("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(e){e.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",description:"Go to word right",bindKey:a("Ctrl-Right","Option-Right"),exec:function(e){e.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",description:"Select to line end",bindKey:a("Alt-Shift-Right","Command-Shift-Right|Shift-End|Ctrl-Shift-E"),exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",description:"Go to line end",bindKey:a("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(e){e.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",description:"Select right",bindKey:a("Shift-Right","Shift-Right"),exec:function(e){e.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",description:"Go to right",bindKey:a("Right","Right|Ctrl-F"),exec:function(e,t){e.navigateRight(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",description:"Select page down",bindKey:"Shift-PageDown",exec:function(e){e.selectPageDown()},readOnly:!0},{name:"pagedown",description:"Page down",bindKey:a(null,"Option-PageDown"),exec:function(e){e.scrollPageDown()},readOnly:!0},{name:"gotopagedown",description:"Go to page down",bindKey:a("PageDown","PageDown|Ctrl-V"),exec:function(e){e.gotoPageDown()},readOnly:!0},{name:"selectpageup",description:"Select page up",bindKey:"Shift-PageUp",exec:function(e){e.selectPageUp()},readOnly:!0},{name:"pageup",description:"Page up",bindKey:a(null,"Option-PageUp"),exec:function(e){e.scrollPageUp()},readOnly:!0},{name:"gotopageup",description:"Go to page up",bindKey:"PageUp",exec:function(e){e.gotoPageUp()},readOnly:!0},{name:"scrollup",description:"Scroll up",bindKey:a("Ctrl-Up",null),exec:function(e){e.renderer.scrollBy(0,-2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",description:"Scroll down",bindKey:a("Ctrl-Down",null),exec:function(e){e.renderer.scrollBy(0,2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",description:"Select line start",bindKey:"Shift-Home",exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",description:"Select line end",bindKey:"Shift-End",exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",description:"Toggle recording",bindKey:a("Ctrl-Alt-E","Command-Option-E"),exec:function(e){e.commands.toggleRecording(e)},readOnly:!0},{name:"replaymacro",description:"Replay macro",bindKey:a("Ctrl-Shift-E","Command-Shift-E"),exec:function(e){e.commands.replay(e)},readOnly:!0},{name:"jumptomatching",description:"Jump to matching",bindKey:a("Ctrl-\\|Ctrl-P","Command-\\"),exec:function(e){e.jumpToMatching()},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"selecttomatching",description:"Select to matching",bindKey:a("Ctrl-Shift-\\|Ctrl-Shift-P","Command-Shift-\\"),exec:function(e){e.jumpToMatching(!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"expandToMatching",description:"Expand to matching",bindKey:a("Ctrl-Shift-M","Ctrl-Shift-M"),exec:function(e){e.jumpToMatching(!0,!0)},multiSelectAction:"forEach",scrollIntoView:"animate",readOnly:!0},{name:"passKeysToBrowser",description:"Pass keys to browser",bindKey:a(null,null),exec:function(){},passEvent:!0,readOnly:!0},{name:"copy",description:"Copy",exec:function(e){},readOnly:!0},{name:"cut",description:"Cut",exec:function(e){var t=e.$copyWithEmptySelection&&e.selection.isEmpty()?e.selection.getLineRange():e.selection.getRange();e._emit("cut",t),t.isEmpty()||e.session.remove(t),e.clearSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"paste",description:"Paste",exec:function(e,t){e.$handlePaste(t)},scrollIntoView:"cursor"},{name:"removeline",description:"Remove line",bindKey:a("Ctrl-D","Command-D"),exec:function(e){e.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",description:"Duplicate selection",bindKey:a("Ctrl-Shift-D","Command-Shift-D"),exec:function(e){e.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",description:"Sort lines",bindKey:a("Ctrl-Alt-S","Command-Alt-S"),exec:function(e){e.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",description:"Toggle comment",bindKey:a("Ctrl-/","Command-/"),exec:function(e){e.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",description:"Toggle block comment",bindKey:a("Ctrl-Shift-/","Command-Shift-/"),exec:function(e){e.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",description:"Modify number up",bindKey:a("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(e){e.modifyNumber(1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"modifyNumberDown",description:"Modify number down",bindKey:a("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(e){e.modifyNumber(-1)},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"replace",description:"Replace",bindKey:a("Ctrl-H","Command-Option-F"),exec:function(e){r.loadModule("ace/ext/searchbox",(function(t){t.Search(e,!0)}))}},{name:"undo",description:"Undo",bindKey:a("Ctrl-Z","Command-Z"),exec:function(e){e.undo()}},{name:"redo",description:"Redo",bindKey:a("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(e){e.redo()}},{name:"copylinesup",description:"Copy lines up",bindKey:a("Alt-Shift-Up","Command-Option-Up"),exec:function(e){e.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",description:"Move lines up",bindKey:a("Alt-Up","Option-Up"),exec:function(e){e.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",description:"Copy lines down",bindKey:a("Alt-Shift-Down","Command-Option-Down"),exec:function(e){e.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",description:"Move lines down",bindKey:a("Alt-Down","Option-Down"),exec:function(e){e.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",description:"Delete",bindKey:a("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(e){e.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",description:"Backspace",bindKey:a("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(e){e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",description:"Cut or delete",bindKey:a("Shift-Delete",null),exec:function(e){if(!e.selection.isEmpty())return!1;e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",description:"Remove to line start",bindKey:a("Alt-Backspace","Command-Backspace"),exec:function(e){e.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",description:"Remove to line end",bindKey:a("Alt-Delete","Ctrl-K|Command-Delete"),exec:function(e){e.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestarthard",description:"Remove to line start hard",bindKey:a("Ctrl-Shift-Backspace",null),exec:function(e){var t=e.selection.getRange();t.start.column=0,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineendhard",description:"Remove to line end hard",bindKey:a("Ctrl-Shift-Delete",null),exec:function(e){var t=e.selection.getRange();t.end.column=Number.MAX_VALUE,e.session.remove(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",description:"Remove word left",bindKey:a("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(e){e.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",description:"Remove word right",bindKey:a("Ctrl-Delete","Alt-Delete"),exec:function(e){e.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",description:"Outdent",bindKey:a("Shift-Tab","Shift-Tab"),exec:function(e){e.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",description:"Indent",bindKey:a("Tab","Tab"),exec:function(e){e.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",description:"Block outdent",bindKey:a("Ctrl-[","Ctrl-["),exec:function(e){e.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",description:"Block indent",bindKey:a("Ctrl-]","Ctrl-]"),exec:function(e){e.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",description:"Insert string",exec:function(e,t){e.insert(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",description:"Insert text",exec:function(e,t){e.insert(i.stringRepeat(t.text||"",t.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",description:"Split line",bindKey:a(null,"Ctrl-O"),exec:function(e){e.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",description:"Transpose letters",bindKey:a("Alt-Shift-X","Ctrl-T"),exec:function(e){e.transposeLetters()},multiSelectAction:function(e){e.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",description:"To uppercase",bindKey:a("Ctrl-U","Ctrl-U"),exec:function(e){e.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",description:"To lowercase",bindKey:a("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(e){e.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"autoindent",description:"Auto Indent",bindKey:a(null,null),exec:function(e){e.autoIndent()},scrollIntoView:"animate"},{name:"expandtoline",description:"Expand to line",bindKey:a("Ctrl-Shift-L","Command-Shift-L"),exec:function(e){var t=e.selection.getRange();t.start.column=t.end.column=0,t.end.row++,e.selection.setRange(t,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"openlink",bindKey:a("Ctrl+F3","F3"),exec:function(e){e.openLink()}},{name:"joinlines",description:"Join lines",bindKey:a(null,null),exec:function(e){for(var t=e.selection.isBackwards(),n=t?e.selection.getSelectionLead():e.selection.getSelectionAnchor(),r=t?e.selection.getSelectionAnchor():e.selection.getSelectionLead(),a=e.session.doc.getLine(n.row).length,s=e.session.doc.getTextRange(e.selection.getRange()).replace(/\n\s*/," ").length,l=e.session.doc.getLine(n.row),c=n.row+1;c<=r.row+1;c++){var d=i.stringTrimLeft(i.stringTrimRight(e.session.doc.getLine(c)));0!==d.length&&(d=" "+d),l+=d}r.row+1<e.session.doc.getLength()-1&&(l+=e.session.doc.getNewLineCharacter()),e.clearSelection(),e.session.doc.replace(new o(n.row,0,r.row+2,0),l),s>0?(e.selection.moveCursorTo(n.row,n.column),e.selection.selectTo(n.row,n.column+s)):(a=e.session.doc.getLine(n.row).length>a?a+1:a,e.selection.moveCursorTo(n.row,a))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",description:"Invert selection",bindKey:a(null,null),exec:function(e){var t=e.session.doc.getLength()-1,n=e.session.doc.getLine(t).length,i=e.selection.rangeList.ranges,r=[];i.length<1&&(i=[e.selection.getRange()]);for(var a=0;a<i.length;a++)a==i.length-1&&(i[a].end.row===t&&i[a].end.column===n||r.push(new o(i[a].end.row,i[a].end.column,t,n))),0===a?0===i[a].start.row&&0===i[a].start.column||r.push(new o(0,0,i[a].start.row,i[a].start.column)):r.push(new o(i[a-1].end.row,i[a-1].end.column,i[a].start.row,i[a].start.column));for(e.exitMultiSelectMode(),e.clearSelection(),a=0;a<r.length;a++)e.selection.addRange(r[a],!1)},readOnly:!0,scrollIntoView:"none"},{name:"addLineAfter",description:"Add new line after the current line",exec:function(e){e.selection.clearSelection(),e.navigateLineEnd(),e.insert("\n")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"addLineBefore",description:"Add new line before the current line",exec:function(e){e.selection.clearSelection();var t=e.getCursorPosition();e.selection.moveTo(t.row-1,Number.MAX_VALUE),e.insert("\n"),0===t.row&&e.navigateUp()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"openCommandPallete",exec:function(e){console.warn("This is an obsolete command. Please use `openCommandPalette` instead."),e.prompt({$type:"commands"})},readOnly:!0},{name:"openCommandPalette",description:"Open command palette",bindKey:a("F1","F1"),exec:function(e){e.prompt({$type:"commands"})},readOnly:!0},{name:"modeSelect",description:"Change language mode...",bindKey:a(null,null),exec:function(e){e.prompt({$type:"modes"})},readOnly:!0}];for(var s=1;s<9;s++)t.commands.push({name:"foldToLevel"+s,description:"Fold To Level "+s,level:s,exec:function(e){e.session.foldToLevel(this.level)},scrollIntoView:"center",readOnly:!0})})),ace.define("ace/keyboard/gutter_handler",["require","exports","module","ace/lib/keys","ace/mouse/default_gutter_handler"],(function(e,t,n){"use strict";var i=e("../lib/keys"),r=e("../mouse/default_gutter_handler").GutterTooltip,o=function(){function e(e){this.editor=e,this.gutterLayer=e.renderer.$gutterLayer,this.element=e.renderer.$gutter,this.lines=e.renderer.$gutterLayer.$lines,this.activeRowIndex=null,this.activeLane=null,this.annotationTooltip=new r(this.editor)}return e.prototype.addListener=function(){this.element.addEventListener("keydown",this.$onGutterKeyDown.bind(this)),this.element.addEventListener("focusout",this.$blurGutter.bind(this)),this.editor.on("mousewheel",this.$blurGutter.bind(this))},e.prototype.removeListener=function(){this.element.removeEventListener("keydown",this.$onGutterKeyDown.bind(this)),this.element.removeEventListener("focusout",this.$blurGutter.bind(this)),this.editor.off("mousewheel",this.$blurGutter.bind(this))},e.prototype.$onGutterKeyDown=function(e){if(this.annotationTooltip.isOpen)return e.preventDefault(),void(e.keyCode===i.escape&&this.annotationTooltip.hideTooltip());if(e.target===this.element){if(e.keyCode!=i.enter)return;e.preventDefault();var t=this.editor.getCursorPosition().row;return this.editor.isRowVisible(t)||this.editor.scrollToLine(t,!0,!0),void setTimeout(function(){var e=this.$rowToRowIndex(this.gutterLayer.$cursorCell.row),t=this.$findNearestFoldWidget(e),n=this.$findNearestAnnotation(e);if(null!==t||null!==n)return null===t&&null!==n?(this.activeRowIndex=n,this.activeLane="annotation",void this.$focusAnnotation(this.activeRowIndex)):null!==t&&null===n?(this.activeRowIndex=t,this.activeLane="fold",void this.$focusFoldWidget(this.activeRowIndex)):Math.abs(n-e)<Math.abs(t-e)?(this.activeRowIndex=n,this.activeLane="annotation",void this.$focusAnnotation(this.activeRowIndex)):(this.activeRowIndex=t,this.activeLane="fold",void this.$focusFoldWidget(this.activeRowIndex))}.bind(this),10)}this.$handleGutterKeyboardInteraction(e),setTimeout(function(){this.editor._signal("gutterkeydown",new a(e,this))}.bind(this),10)},e.prototype.$handleGutterKeyboardInteraction=function(e){if(e.keyCode!==i.tab){if(e.keyCode===i.escape)return e.preventDefault(),this.$blurGutter(),this.element.focus(),void(this.lane=null);if(e.keyCode!==i.up)if(e.keyCode!==i.down){if(e.keyCode===i.left)return e.preventDefault(),void this.$switchLane("annotation");if(e.keyCode===i.right)return e.preventDefault(),void this.$switchLane("fold");if(e.keyCode!==i.enter&&e.keyCode!==i.space);else switch(e.preventDefault(),this.activeLane){case"fold":if("start"===this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)]){var t=this.$rowIndexToRow(this.activeRowIndex);this.editor.session.onFoldWidgetClick(this.$rowIndexToRow(this.activeRowIndex),e),setTimeout(function(){this.$rowIndexToRow(this.activeRowIndex)!==t&&(this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=this.$rowToRowIndex(t),this.$focusFoldWidget(this.activeRowIndex))}.bind(this),10);break}if("end"===this.gutterLayer.session.foldWidgets[this.$rowIndexToRow(this.activeRowIndex)])break;return;case"annotation":var n=this.lines.cells[this.activeRowIndex].element.childNodes[2].getBoundingClientRect(),r=this.annotationTooltip.getElement().style;r.left=n.right+"px",r.top=n.bottom+"px",this.annotationTooltip.showTooltip(this.$rowIndexToRow(this.activeRowIndex))}}else switch(e.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetDown();break;case"annotation":this.$moveAnnotationDown()}else switch(e.preventDefault(),this.activeLane){case"fold":this.$moveFoldWidgetUp();break;case"annotation":this.$moveAnnotationUp()}}else e.preventDefault()},e.prototype.$blurGutter=function(){if(null!==this.activeRowIndex)switch(this.activeLane){case"fold":this.$blurFoldWidget(this.activeRowIndex);break;case"annotation":this.$blurAnnotation(this.activeRowIndex)}this.annotationTooltip.isOpen&&this.annotationTooltip.hideTooltip()},e.prototype.$isFoldWidgetVisible=function(e){var t=this.editor.isRowFullyVisible(this.$rowIndexToRow(e)),n="none"!==this.$getFoldWidget(e).style.display;return t&&n},e.prototype.$isAnnotationVisible=function(e){var t=this.editor.isRowFullyVisible(this.$rowIndexToRow(e)),n="none"!==this.$getAnnotation(e).style.display;return t&&n},e.prototype.$getFoldWidget=function(e){return this.lines.get(e).element.childNodes[1]},e.prototype.$getAnnotation=function(e){return this.lines.get(e).element.childNodes[2]},e.prototype.$findNearestFoldWidget=function(e){if(this.$isFoldWidgetVisible(e))return e;for(var t=0;e-t>0||e+t<this.lines.getLength()-1;){if(e-++t>=0&&this.$isFoldWidgetVisible(e-t))return e-t;if(e+t<=this.lines.getLength()-1&&this.$isFoldWidgetVisible(e+t))return e+t}return null},e.prototype.$findNearestAnnotation=function(e){if(this.$isAnnotationVisible(e))return e;for(var t=0;e-t>0||e+t<this.lines.getLength()-1;){if(e-++t>=0&&this.$isAnnotationVisible(e-t))return e-t;if(e+t<=this.lines.getLength()-1&&this.$isAnnotationVisible(e+t))return e+t}return null},e.prototype.$focusFoldWidget=function(e){if(null!=e){var t=this.$getFoldWidget(e);t.classList.add(this.editor.renderer.keyboardFocusClassName),t.focus()}},e.prototype.$focusAnnotation=function(e){if(null!=e){var t=this.$getAnnotation(e);t.classList.add(this.editor.renderer.keyboardFocusClassName),t.focus()}},e.prototype.$blurFoldWidget=function(e){var t=this.$getFoldWidget(e);t.classList.remove(this.editor.renderer.keyboardFocusClassName),t.blur()},e.prototype.$blurAnnotation=function(e){var t=this.$getAnnotation(e);t.classList.remove(this.editor.renderer.keyboardFocusClassName),t.blur()},e.prototype.$moveFoldWidgetUp=function(){for(var e=this.activeRowIndex;e>0;)if(e--,this.$isFoldWidgetVisible(e))return this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=e,void this.$focusFoldWidget(this.activeRowIndex)},e.prototype.$moveFoldWidgetDown=function(){for(var e=this.activeRowIndex;e<this.lines.getLength()-1;)if(e++,this.$isFoldWidgetVisible(e))return this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=e,void this.$focusFoldWidget(this.activeRowIndex)},e.prototype.$moveAnnotationUp=function(){for(var e=this.activeRowIndex;e>0;)if(e--,this.$isAnnotationVisible(e))return this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=e,void this.$focusAnnotation(this.activeRowIndex)},e.prototype.$moveAnnotationDown=function(){for(var e=this.activeRowIndex;e<this.lines.getLength()-1;)if(e++,this.$isAnnotationVisible(e))return this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=e,void this.$focusAnnotation(this.activeRowIndex)},e.prototype.$switchLane=function(e){switch(e){case"annotation":if("annotation"===this.activeLane)break;var t=this.$findNearestAnnotation(this.activeRowIndex);if(null==t)break;this.activeLane="annotation",this.$blurFoldWidget(this.activeRowIndex),this.activeRowIndex=t,this.$focusAnnotation(this.activeRowIndex);break;case"fold":if("fold"===this.activeLane)break;var n=this.$findNearestFoldWidget(this.activeRowIndex);if(null==n)break;this.activeLane="fold",this.$blurAnnotation(this.activeRowIndex),this.activeRowIndex=n,this.$focusFoldWidget(this.activeRowIndex)}},e.prototype.$rowIndexToRow=function(e){var t=this.lines.get(e);return t?t.row:null},e.prototype.$rowToRowIndex=function(e){for(var t=0;t<this.lines.getLength();t++)if(this.lines.get(t).row==e)return t;return null},e}();t.GutterKeyboardHandler=o;var a=function(){function e(e,t){this.gutterKeyboardHandler=t,this.domEvent=e}return e.prototype.getKey=function(){return i.keyCodeToString(this.domEvent.keyCode)},e.prototype.getRow=function(){return this.gutterKeyboardHandler.$rowIndexToRow(this.gutterKeyboardHandler.activeRowIndex)},e.prototype.isInAnnotationLane=function(){return"annotation"===this.gutterKeyboardHandler.activeLane},e.prototype.isInFoldLane=function(){return"fold"===this.gutterKeyboardHandler.activeLane},e}();t.GutterKeyboardEvent=a})),ace.define("ace/editor",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator","ace/keyboard/gutter_handler","ace/config","ace/clipboard","ace/lib/keys","ace/lib/event","ace/tooltip"],(function(e,t,n){"use strict";var i=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},r=e("./lib/oop"),o=e("./lib/dom"),a=e("./lib/lang"),s=e("./lib/useragent"),l=e("./keyboard/textinput").TextInput,c=e("./mouse/mouse_handler").MouseHandler,d=e("./mouse/fold_handler").FoldHandler,u=e("./keyboard/keybinding").KeyBinding,h=e("./edit_session").EditSession,p=e("./search").Search,g=e("./range").Range,f=e("./lib/event_emitter").EventEmitter,m=e("./commands/command_manager").CommandManager,y=e("./commands/default_commands").commands,v=e("./config"),b=e("./token_iterator").TokenIterator,w=e("./keyboard/gutter_handler").GutterKeyboardHandler,C=e("./config").nls,x=e("./clipboard"),S=e("./lib/keys"),_=e("./lib/event"),E=e("./tooltip").HoverTooltip,k=function(){function e(t,n,i){this.session,this.$toDestroy=[];var r=t.getContainerElement();this.container=r,this.renderer=t,this.id="editor"+ ++e.$uid,this.commands=new m(s.isMac?"mac":"win",y),"object"==typeof document&&(this.textInput=new l(t.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.$mouseHandler=new c(this),new d(this)),this.keyBinding=new u(this),this.$search=(new p).set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=a.delayedCall(function(){this._signal("input",{}),this.session&&!this.session.destroyed&&this.session.bgTokenizer.scheduleStart()}.bind(this)),this.on("change",(function(e,t){t._$emitInputEvent.schedule(31)})),this.setSession(n||i&&i.session||new h("")),v.resetOptions(this),i&&this.setOptions(i),v._signal("editor",this)}return e.prototype.$initOperationListeners=function(){this.commands.on("exec",this.startOperation.bind(this),!0),this.commands.on("afterExec",this.endOperation.bind(this),!0)},e.prototype.startOperation=function(e){this.session.startOperation(e)},e.prototype.endOperation=function(e){this.session.endOperation(e)},e.prototype.onStartOperation=function(e){this.curOp=this.session.curOp,this.curOp.scrollTop=this.renderer.scrollTop,this.prevOp=this.session.prevOp,e||(this.previousCommand=null)},e.prototype.onEndOperation=function(e){if(this.curOp&&this.session){if(e&&!1===e.returnValue)return void(this.curOp=null);if(this._signal("beforeEndOperation"),!this.curOp)return;var t=this.curOp.command,n=t&&t.scrollIntoView;if(n){switch(n){case"center-animate":n="animate";case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var i=this.selection.getRange(),r=this.renderer.layerConfig;(i.start.row>=r.lastRow||i.end.row<=r.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead)}"animate"==n&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.$lastSel=this.session.selection.toJSON(),this.prevOp=this.curOp,this.curOp=null}},e.prototype.$historyTracker=function(e){if(this.$mergeUndoDeltas){var t=this.prevOp,n=this.$mergeableCommands,i=t.command&&e.command.name==t.command.name;if("insertstring"==e.command.name){var r=e.args;void 0===this.mergeNextCommand&&(this.mergeNextCommand=!0),i=i&&this.mergeNextCommand&&(!/\s/.test(r)||/\s/.test(t.args)),this.mergeNextCommand=!0}else i=i&&-1!==n.indexOf(e.command.name);"always"!=this.$mergeUndoDeltas&&Date.now()-this.sequenceStartTime>2e3&&(i=!1),i?this.session.mergeUndoDeltas=!0:-1!==n.indexOf(e.command.name)&&(this.sequenceStartTime=Date.now())}},e.prototype.setKeyboardHandler=function(e,t){if(e&&"string"==typeof e&&"ace"!=e){this.$keybindingId=e;var n=this;v.loadModule(["keybinding",e],(function(i){n.$keybindingId==e&&n.keyBinding.setKeyboardHandler(i&&i.handler),t&&t()}))}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(e),t&&t()},e.prototype.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},e.prototype.setSession=function(e){if(this.session!=e){this.curOp&&this.endOperation(),this.curOp={};var t=this.session;if(t){this.session.off("change",this.$onDocumentChange),this.session.off("changeMode",this.$onChangeMode),this.session.off("tokenizerUpdate",this.$onTokenizerUpdate),this.session.off("changeTabSize",this.$onChangeTabSize),this.session.off("changeWrapLimit",this.$onChangeWrapLimit),this.session.off("changeWrapMode",this.$onChangeWrapMode),this.session.off("changeFold",this.$onChangeFold),this.session.off("changeFrontMarker",this.$onChangeFrontMarker),this.session.off("changeBackMarker",this.$onChangeBackMarker),this.session.off("changeBreakpoint",this.$onChangeBreakpoint),this.session.off("changeAnnotation",this.$onChangeAnnotation),this.session.off("changeOverwrite",this.$onCursorChange),this.session.off("changeScrollTop",this.$onScrollTopChange),this.session.off("changeScrollLeft",this.$onScrollLeftChange),this.session.off("startOperation",this.$onStartOperation),this.session.off("endOperation",this.$onEndOperation);var n=this.session.getSelection();n.off("changeCursor",this.$onCursorChange),n.off("changeSelection",this.$onSelectionChange)}this.session=e,e?(this.$onDocumentChange=this.onDocumentChange.bind(this),e.on("change",this.$onDocumentChange),this.renderer.setSession(e),this.$onChangeMode=this.onChangeMode.bind(this),e.on("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),e.on("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),e.on("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),e.on("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),e.on("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),e.on("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.on("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.on("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.on("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.on("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.on("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.on("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.on("changeScrollLeft",this.$onScrollLeftChange),this.selection=e.getSelection(),this.selection.on("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.on("changeSelection",this.$onSelectionChange),this.$onStartOperation=this.onStartOperation.bind(this),this.session.on("startOperation",this.$onStartOperation),this.$onEndOperation=this.onEndOperation.bind(this),this.session.on("endOperation",this.$onEndOperation),this.onChangeMode(),this.onCursorChange(),this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(e)),this._signal("changeSession",{session:e,oldSession:t}),this.curOp=null,t&&t._signal("changeEditor",{oldEditor:this}),t&&(t.$editor=null),e&&e._signal("changeEditor",{editor:this}),e&&(e.$editor=this),e&&!e.destroyed&&e.bgTokenizer.scheduleStart()}},e.prototype.getSession=function(){return this.session},e.prototype.setValue=function(e,t){return this.session.doc.setValue(e),t?1==t?this.navigateFileEnd():-1==t&&this.navigateFileStart():this.selectAll(),e},e.prototype.getValue=function(){return this.session.getValue()},e.prototype.getSelection=function(){return this.selection},e.prototype.resize=function(e){this.renderer.onResize(e)},e.prototype.setTheme=function(e,t){this.renderer.setTheme(e,t)},e.prototype.getTheme=function(){return this.renderer.getTheme()},e.prototype.setStyle=function(e){this.renderer.setStyle(e)},e.prototype.unsetStyle=function(e){this.renderer.unsetStyle(e)},e.prototype.getFontSize=function(){return this.getOption("fontSize")||o.computedStyle(this.container).fontSize},e.prototype.setFontSize=function(e){this.setOption("fontSize",e)},e.prototype.$highlightBrackets=function(){if(!this.$highlightPending){var e=this;this.$highlightPending=!0,setTimeout((function(){e.$highlightPending=!1;var t=e.session;if(t&&!t.destroyed){t.$bracketHighlight&&(t.$bracketHighlight.markerIds.forEach((function(e){t.removeMarker(e)})),t.$bracketHighlight=null);var n=e.getCursorPosition(),i=e.getKeyboardHandler(),r=i&&i.$getDirectionForHighlight&&i.$getDirectionForHighlight(e),o=t.getMatchingBracketRanges(n,r);if(!o){var a=new b(t,n.row,n.column).getCurrentToken();if(a&&/\b(?:tag-open|tag-name)/.test(a.type)){var s=t.getMatchingTags(n);s&&(o=[s.openTagName.isEmpty()?s.openTag:s.openTagName,s.closeTagName.isEmpty()?s.closeTag:s.closeTagName])}}if(!o&&t.$mode.getMatching&&(o=t.$mode.getMatching(e.session)),o){var l="ace_bracket";Array.isArray(o)?1==o.length&&(l="ace_error_bracket"):o=[o],2==o.length&&(0==g.comparePoints(o[0].end,o[1].start)?o=[g.fromPoints(o[0].start,o[1].end)]:0==g.comparePoints(o[0].start,o[1].end)&&(o=[g.fromPoints(o[1].start,o[0].end)])),t.$bracketHighlight={ranges:o,markerIds:o.map((function(e){return t.addMarker(e,l,"text")}))},e.getHighlightIndentGuides()&&e.renderer.$textLayer.$highlightIndentGuide()}else e.getHighlightIndentGuides()&&e.renderer.$textLayer.$highlightIndentGuide()}}),50)}},e.prototype.focus=function(){this.textInput.focus()},e.prototype.isFocused=function(){return this.textInput.isFocused()},e.prototype.blur=function(){this.textInput.blur()},e.prototype.onFocus=function(e){this.$isFocused||(this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus",e))},e.prototype.onBlur=function(e){this.$isFocused&&(this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur",e))},e.prototype.$cursorChange=function(){this.renderer.updateCursor(),this.$highlightBrackets(),this.$updateHighlightActiveLine()},e.prototype.onDocumentChange=function(e){var t=this.session.$useWrapMode,n=e.start.row==e.end.row?e.end.row:1/0;this.renderer.updateLines(e.start.row,n,t),this._signal("change",e),this.$cursorChange()},e.prototype.onTokenizerUpdate=function(e){var t=e.data;this.renderer.updateLines(t.first,t.last)},e.prototype.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},e.prototype.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},e.prototype.onCursorChange=function(){this.$cursorChange(),this._signal("changeSelection")},e.prototype.$updateHighlightActiveLine=function(){var e,t=this.getSession();if(this.$highlightActiveLine&&("line"==this.$selectionStyle&&this.selection.isMultiLine()||(e=this.getCursorPosition()),this.renderer.theme&&this.renderer.theme.$selectionColorConflict&&!this.selection.isEmpty()&&(e=!1),!this.renderer.$maxLines||1!==this.session.getLength()||this.renderer.$minLines>1||(e=!1)),t.$highlightLineMarker&&!e)t.removeMarker(t.$highlightLineMarker.id),t.$highlightLineMarker=null;else if(!t.$highlightLineMarker&&e){var n=new g(e.row,e.column,e.row,1/0);n.id=t.addMarker(n,"ace_active-line","screenLine"),t.$highlightLineMarker=n}else e&&(t.$highlightLineMarker.start.row=e.row,t.$highlightLineMarker.end.row=e.row,t.$highlightLineMarker.start.column=e.column,t._signal("changeBackMarker"))},e.prototype.onSelectionChange=function(e){var t=this.session;if(t.$selectionMarker&&t.removeMarker(t.$selectionMarker),t.$selectionMarker=null,this.selection.isEmpty())this.$updateHighlightActiveLine();else{var n=this.selection.getRange(),i=this.getSelectionStyle();t.$selectionMarker=t.addMarker(n,"ace_selection",i)}var r=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(r),this._signal("changeSelection")},e.prototype.$getSelectionHighLightRegexp=function(){var e=this.session,t=this.getSelectionRange();if(!t.isEmpty()&&!t.isMultiLine()){var n=t.start.column,i=t.end.column,r=e.getLine(t.start.row),o=r.substring(n,i);if(!(o.length>5e3)&&/[\w\d]/.test(o)){var a=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:o}),s=r.substring(n-1,i+1);if(a.test(s))return a}}},e.prototype.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},e.prototype.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},e.prototype.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},e.prototype.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},e.prototype.onChangeMode=function(e){this.renderer.updateText(),this._emit("changeMode",e)},e.prototype.onChangeWrapLimit=function(){this.renderer.updateFull()},e.prototype.onChangeWrapMode=function(){this.renderer.onResize(!0)},e.prototype.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},e.prototype.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},e.prototype.getCopyText=function(){var e=this.getSelectedText(),t=this.session.doc.getNewLineCharacter(),n=!1;if(!e&&this.$copyWithEmptySelection){n=!0;for(var i=this.selection.getAllRanges(),r=0;r<i.length;r++){var o=i[r];r&&i[r-1].start.row==o.start.row||(e+=this.session.getLine(o.start.row)+t)}}var a={text:e};return this._signal("copy",a),x.lineMode=!!n&&a.text,a.text},e.prototype.onCopy=function(){this.commands.exec("copy",this)},e.prototype.onCut=function(){this.commands.exec("cut",this)},e.prototype.onPaste=function(e,t){var n={text:e,event:t};this.commands.exec("paste",this,n)},e.prototype.$handlePaste=function(e){"string"==typeof e&&(e={text:e}),this._signal("paste",e);var t=e.text,n=t===x.lineMode,i=this.session;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)n?i.insert({row:this.selection.lead.row,column:0},t):this.insert(t);else if(n)this.selection.rangeList.ranges.forEach((function(e){i.insert({row:e.start.row,column:0},t)}));else{var r=t.split(/\r\n|\r|\n/),o=this.selection.rangeList.ranges,a=!(2!=r.length||r[0]&&r[1]);if(r.length!=o.length||a)return this.commands.exec("insertstring",this,t);for(var s=o.length;s--;){var l=o[s];l.isEmpty()||i.remove(l),i.insert(l.start,r[s])}}},e.prototype.execCommand=function(e,t){return this.commands.exec(e,this,t)},e.prototype.insert=function(e,t){var n=this.session,i=n.getMode(),r=this.getCursorPosition();if(this.getBehavioursEnabled()&&!t){var o=i.transformAction(n.getState(r.row),"insertion",this,n,e);o&&(e!==o.text&&(this.inVirtualSelectionMode||(this.session.mergeUndoDeltas=!1,this.mergeNextCommand=!1)),e=o.text)}if("\t"==e&&(e=this.session.getTabString()),this.selection.isEmpty())this.session.getOverwrite()&&-1==e.indexOf("\n")&&((a=g.fromPoints(r,r)).end.column+=e.length,this.session.remove(a));else{var a=this.getSelectionRange();r=this.session.remove(a),this.clearSelection()}if("\n"==e||"\r\n"==e){var s=n.getLine(r.row);if(r.column>s.search(/\S|$/)){var l=s.substr(r.column).search(/\S|$/);n.doc.removeInLine(r.row,r.column,r.column+l)}}this.clearSelection();var c=r.column,d=n.getState(r.row),u=(s=n.getLine(r.row),i.checkOutdent(d,s,e));if(n.insert(r,e),o&&o.selection&&(2==o.selection.length?this.selection.setSelectionRange(new g(r.row,c+o.selection[0],r.row,c+o.selection[1])):this.selection.setSelectionRange(new g(r.row+o.selection[0],o.selection[1],r.row+o.selection[2],o.selection[3]))),this.$enableAutoIndent){if(n.getDocument().isNewLine(e)){var h=i.getNextLineIndent(d,s.slice(0,r.column),n.getTabString());n.insert({row:r.row+1,column:0},h)}u&&i.autoOutdent(d,n,r.row)}},e.prototype.autoIndent=function(){for(var e=this.session,t=e.getMode(),n=this.selection.isEmpty()?[new g(0,0,e.doc.getLength()-1,0)]:this.selection.getAllRanges(),i="",r="",o="",a=e.getTabString(),s=0;s<n.length;s++)for(var l=n[s].start.row,c=n[s].end.row,d=l;d<=c;d++){d>0&&(i=e.getState(d-1),r=e.getLine(d-1),o=t.getNextLineIndent(i,r,a));var u=e.getLine(d),h=t.$getIndent(u);if(o!==h){if(h.length>0){var p=new g(d,0,d,h.length);e.remove(p)}o.length>0&&e.insert({row:d,column:0},o)}t.autoOutdent(i,e,d)}},e.prototype.onTextInput=function(e,t){if(!t)return this.keyBinding.onTextInput(e);this.startOperation({command:{name:"insertstring"}});var n=this.applyComposition.bind(this,e,t);this.selection.rangeCount?this.forEachSelection(n):n(),this.endOperation()},e.prototype.applyComposition=function(e,t){var n;(t.extendLeft||t.extendRight)&&((n=this.selection.getRange()).start.column-=t.extendLeft,n.end.column+=t.extendRight,n.start.column<0&&(n.start.row--,n.start.column+=this.session.getLine(n.start.row).length+1),this.selection.setRange(n),e||n.isEmpty()||this.remove()),!e&&this.selection.isEmpty()||this.insert(e,!0),(t.restoreStart||t.restoreEnd)&&((n=this.selection.getRange()).start.column-=t.restoreStart,n.end.column-=t.restoreEnd,this.selection.setRange(n))},e.prototype.onCommandKey=function(e,t,n){return this.keyBinding.onCommandKey(e,t,n)},e.prototype.setOverwrite=function(e){this.session.setOverwrite(e)},e.prototype.getOverwrite=function(){return this.session.getOverwrite()},e.prototype.toggleOverwrite=function(){this.session.toggleOverwrite()},e.prototype.setScrollSpeed=function(e){this.setOption("scrollSpeed",e)},e.prototype.getScrollSpeed=function(){return this.getOption("scrollSpeed")},e.prototype.setDragDelay=function(e){this.setOption("dragDelay",e)},e.prototype.getDragDelay=function(){return this.getOption("dragDelay")},e.prototype.setSelectionStyle=function(e){this.setOption("selectionStyle",e)},e.prototype.getSelectionStyle=function(){return this.getOption("selectionStyle")},e.prototype.setHighlightActiveLine=function(e){this.setOption("highlightActiveLine",e)},e.prototype.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},e.prototype.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},e.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},e.prototype.setHighlightSelectedWord=function(e){this.setOption("highlightSelectedWord",e)},e.prototype.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},e.prototype.setAnimatedScroll=function(e){this.renderer.setAnimatedScroll(e)},e.prototype.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},e.prototype.setShowInvisibles=function(e){this.renderer.setShowInvisibles(e)},e.prototype.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},e.prototype.setDisplayIndentGuides=function(e){this.renderer.setDisplayIndentGuides(e)},e.prototype.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},e.prototype.setHighlightIndentGuides=function(e){this.renderer.setHighlightIndentGuides(e)},e.prototype.getHighlightIndentGuides=function(){return this.renderer.getHighlightIndentGuides()},e.prototype.setShowPrintMargin=function(e){this.renderer.setShowPrintMargin(e)},e.prototype.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},e.prototype.setPrintMarginColumn=function(e){this.renderer.setPrintMarginColumn(e)},e.prototype.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},e.prototype.setReadOnly=function(e){this.setOption("readOnly",e)},e.prototype.getReadOnly=function(){return this.getOption("readOnly")},e.prototype.setBehavioursEnabled=function(e){this.setOption("behavioursEnabled",e)},e.prototype.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},e.prototype.setWrapBehavioursEnabled=function(e){this.setOption("wrapBehavioursEnabled",e)},e.prototype.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},e.prototype.setShowFoldWidgets=function(e){this.setOption("showFoldWidgets",e)},e.prototype.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},e.prototype.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},e.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},e.prototype.remove=function(e){this.selection.isEmpty()&&("left"==e?this.selection.selectLeft():this.selection.selectRight());var t=this.getSelectionRange();if(this.getBehavioursEnabled()){var n=this.session,i=n.getState(t.start.row),r=n.getMode().transformAction(i,"deletion",this,n,t);if(0===t.end.column){var o=n.getTextRange(t);if("\n"==o[o.length-1]){var a=n.getLine(t.end.row);/^\s+$/.test(a)&&(t.end.column=a.length)}}r&&(t=r)}this.session.remove(t),this.clearSelection()},e.prototype.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},e.prototype.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},e.prototype.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.selection.isEmpty()&&this.selection.selectLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},e.prototype.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var e=this.getSelectionRange();e.start.column==e.end.column&&e.start.row==e.end.row&&(e.end.column=0,e.end.row++),this.session.remove(e),this.clearSelection()},e.prototype.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var e=this.getCursorPosition();this.insert("\n"),this.moveCursorToPosition(e)},e.prototype.setGhostText=function(e,t){this.renderer.setGhostText(e,t)},e.prototype.removeGhostText=function(){this.renderer.removeGhostText()},e.prototype.transposeLetters=function(){if(this.selection.isEmpty()){var e=this.getCursorPosition(),t=e.column;if(0!==t){var n,i,r=this.session.getLine(e.row);t<r.length?(n=r.charAt(t)+r.charAt(t-1),i=new g(e.row,t-1,e.row,t+1)):(n=r.charAt(t-1)+r.charAt(t-2),i=new g(e.row,t-2,e.row,t)),this.session.replace(i,n),this.session.selection.moveToPosition(i.end)}}},e.prototype.toLowerCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toLowerCase()),this.selection.setSelectionRange(e)},e.prototype.toUpperCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toUpperCase()),this.selection.setSelectionRange(e)},e.prototype.indent=function(){var e=this.session,t=this.getSelectionRange();if(!(t.start.row<t.end.row)){if(t.start.column<t.end.column){var n=e.getTextRange(t);if(!/^\s+$/.test(n))return d=this.$getSelectedRows(),void e.indentRows(d.first,d.last,"\t")}var i=e.getLine(t.start.row),r=t.start,o=e.getTabSize(),s=e.documentToScreenColumn(r.row,r.column);if(this.session.getUseSoftTabs())var l=o-s%o,c=a.stringRepeat(" ",l);else{for(l=s%o;" "==i[t.start.column-1]&&l;)t.start.column--,l--;this.selection.setSelectionRange(t),c="\t"}return this.insert(c)}var d=this.$getSelectedRows();e.indentRows(d.first,d.last,"\t")},e.prototype.blockIndent=function(){var e=this.$getSelectedRows();this.session.indentRows(e.first,e.last,"\t")},e.prototype.blockOutdent=function(){var e=this.session.getSelection();this.session.outdentRows(e.getRange())},e.prototype.sortLines=function(){for(var e=this.$getSelectedRows(),t=this.session,n=[],i=e.first;i<=e.last;i++)n.push(t.getLine(i));n.sort((function(e,t){return e.toLowerCase()<t.toLowerCase()?-1:e.toLowerCase()>t.toLowerCase()?1:0}));var r=new g(0,0,0,0);for(i=e.first;i<=e.last;i++){var o=t.getLine(i);r.start.row=i,r.end.row=i,r.end.column=o.length,t.replace(r,n[i-e.first])}},e.prototype.toggleCommentLines=function(){var e=this.session.getState(this.getCursorPosition().row),t=this.$getSelectedRows();this.session.getMode().toggleCommentLines(e,this.session,t.first,t.last)},e.prototype.toggleBlockComment=function(){var e=this.getCursorPosition(),t=this.session.getState(e.row),n=this.getSelectionRange();this.session.getMode().toggleBlockComment(t,this.session,n,e)},e.prototype.getNumberAt=function(e,t){var n=/[\-]?[0-9]+(?:\.[0-9]+)?/g;n.lastIndex=0;for(var i=this.session.getLine(e);n.lastIndex<t;){var r=n.exec(i);if(r.index<=t&&r.index+r[0].length>=t)return{value:r[0],start:r.index,end:r.index+r[0].length}}return null},e.prototype.modifyNumber=function(e){var t=this.selection.getCursor().row,n=this.selection.getCursor().column,i=new g(t,n-1,t,n),r=this.session.getTextRange(i);if(!isNaN(parseFloat(r))&&isFinite(r)){var o=this.getNumberAt(t,n);if(o){var a=o.value.indexOf(".")>=0?o.start+o.value.indexOf(".")+1:o.end,s=o.start+o.value.length-a,l=parseFloat(o.value);l*=Math.pow(10,s),a!==o.end&&n<a?e*=Math.pow(10,o.end-n-1):e*=Math.pow(10,o.end-n),l+=e;var c=(l/=Math.pow(10,s)).toFixed(s),d=new g(t,o.start,t,o.end);this.session.replace(d,c),this.moveCursorTo(t,Math.max(o.start+1,n+c.length-o.value.length))}}else this.toggleWord()},e.prototype.toggleWord=function(){var e=this.selection.getCursor().row,t=this.selection.getCursor().column;this.selection.selectWord();var n=this.getSelectedText(),i=this.selection.getWordRange().start.column,r=n.replace(/([a-z]+|[A-Z]+)(?=[A-Z_]|$)/g,"$1 ").split(/\s/),o=t-i-1;o<0&&(o=0);var s=0,l=0,c=this;n.match(/[A-Za-z0-9_]+/)&&r.forEach((function(t,r){l=s+t.length,o>=s&&o<=l&&(n=t,c.selection.clearSelection(),c.moveCursorTo(e,s+i),c.selection.selectTo(e,l+i)),s=l}));for(var d,u=this.$toggleWordPairs,h=0;h<u.length;h++)for(var p=u[h],g=0;g<=1;g++){var f=+!g,m=n.match(new RegExp("^\\s?_?("+a.escapeRegExp(p[g])+")\\s?$","i"));m&&n.match(new RegExp("([_]|^|\\s)("+a.escapeRegExp(m[1])+")($|\\s)","g"))&&(d=n.replace(new RegExp(a.escapeRegExp(p[g]),"i"),(function(e){var t=p[f];return e.toUpperCase()==e?t=t.toUpperCase():e.charAt(0).toUpperCase()==e.charAt(0)&&(t=t.substr(0,0)+p[f].charAt(0).toUpperCase()+t.substr(1)),t})),this.insert(d),d="")}},e.prototype.findLinkAt=function(e,t){var n,r,o=this.session.getLine(e).split(/((?:https?|ftp):\/\/[\S]+)/),a=t;a<0&&(a=0);var s,l=0,c=0;try{for(var d=i(o),u=d.next();!u.done;u=d.next()){var h=u.value;if(c=l+h.length,a>=l&&a<=c&&h.match(/((?:https?|ftp):\/\/[\S]+)/)){s=h.replace(/[\s:.,'";}\]]+$/,"");break}l=c}}catch(e){n={error:e}}finally{try{u&&!u.done&&(r=d.return)&&r.call(d)}finally{if(n)throw n.error}}return s},e.prototype.openLink=function(){var e=this.selection.getCursor(),t=this.findLinkAt(e.row,e.column);return t&&window.open(t,"_blank"),null!=t},e.prototype.removeLines=function(){var e=this.$getSelectedRows();this.session.removeFullLines(e.first,e.last),this.clearSelection()},e.prototype.duplicateSelection=function(){var e=this.selection,t=this.session,n=e.getRange(),i=e.isBackwards();if(n.isEmpty()){var r=n.start.row;t.duplicateLines(r,r)}else{var o=i?n.start:n.end,a=t.insert(o,t.getTextRange(n));n.start=o,n.end=a,e.setSelectionRange(n,i)}},e.prototype.moveLinesDown=function(){this.$moveLines(1,!1)},e.prototype.moveLinesUp=function(){this.$moveLines(-1,!1)},e.prototype.moveText=function(e,t,n){return this.session.moveText(e,t,n)},e.prototype.copyLinesUp=function(){this.$moveLines(-1,!0)},e.prototype.copyLinesDown=function(){this.$moveLines(1,!0)},e.prototype.$moveLines=function(e,t){var n,i,r=this.selection;if(!r.inMultiSelectMode||this.inVirtualSelectionMode){var o=r.toOrientedRange();n=this.$getSelectedRows(o),i=this.session.$moveLines(n.first,n.last,t?0:e),t&&-1==e&&(i=0),o.moveBy(i,0),r.fromOrientedRange(o)}else{var a=r.rangeList.ranges;r.rangeList.detach(this.session),this.inVirtualSelectionMode=!0;for(var s=0,l=0,c=a.length,d=0;d<c;d++){var u=d;a[d].moveBy(s,0);for(var h=(n=this.$getSelectedRows(a[d])).first,p=n.last;++d<c;){l&&a[d].moveBy(l,0);var g=this.$getSelectedRows(a[d]);if(t&&g.first!=p)break;if(!t&&g.first>p+1)break;p=g.last}for(d--,s=this.session.$moveLines(h,p,t?0:e),t&&-1==e&&(u=d+1);u<=d;)a[u].moveBy(s,0),u++;t||(s=0),l+=s}r.fromOrientedRange(r.ranges[0]),r.rangeList.attach(this.session),this.inVirtualSelectionMode=!1}},e.prototype.$getSelectedRows=function(e){return e=(e||this.getSelectionRange()).collapseRows(),{first:this.session.getRowFoldStart(e.start.row),last:this.session.getRowFoldEnd(e.end.row)}},e.prototype.onCompositionStart=function(e){this.renderer.showComposition(e)},e.prototype.onCompositionUpdate=function(e){this.renderer.setCompositionText(e)},e.prototype.onCompositionEnd=function(){this.renderer.hideComposition()},e.prototype.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},e.prototype.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},e.prototype.isRowVisible=function(e){return e>=this.getFirstVisibleRow()&&e<=this.getLastVisibleRow()},e.prototype.isRowFullyVisible=function(e){return e>=this.renderer.getFirstFullyVisibleRow()&&e<=this.renderer.getLastFullyVisibleRow()},e.prototype.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},e.prototype.$moveByPage=function(e,t){var n=this.renderer,i=this.renderer.layerConfig,r=e*Math.floor(i.height/i.lineHeight);!0===t?this.selection.$moveSelection((function(){this.moveCursorBy(r,0)})):!1===t&&(this.selection.moveCursorBy(r,0),this.selection.clearSelection());var o=n.scrollTop;n.scrollBy(0,r*i.lineHeight),null!=t&&n.scrollCursorIntoView(null,.5),n.animateScrolling(o)},e.prototype.selectPageDown=function(){this.$moveByPage(1,!0)},e.prototype.selectPageUp=function(){this.$moveByPage(-1,!0)},e.prototype.gotoPageDown=function(){this.$moveByPage(1,!1)},e.prototype.gotoPageUp=function(){this.$moveByPage(-1,!1)},e.prototype.scrollPageDown=function(){this.$moveByPage(1)},e.prototype.scrollPageUp=function(){this.$moveByPage(-1)},e.prototype.scrollToRow=function(e){this.renderer.scrollToRow(e)},e.prototype.scrollToLine=function(e,t,n,i){this.renderer.scrollToLine(e,t,n,i)},e.prototype.centerSelection=function(){var e=this.getSelectionRange(),t={row:Math.floor(e.start.row+(e.end.row-e.start.row)/2),column:Math.floor(e.start.column+(e.end.column-e.start.column)/2)};this.renderer.alignCursor(t,.5)},e.prototype.getCursorPosition=function(){return this.selection.getCursor()},e.prototype.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},e.prototype.getSelectionRange=function(){return this.selection.getRange()},e.prototype.selectAll=function(){this.selection.selectAll()},e.prototype.clearSelection=function(){this.selection.clearSelection()},e.prototype.moveCursorTo=function(e,t){this.selection.moveCursorTo(e,t)},e.prototype.moveCursorToPosition=function(e){this.selection.moveCursorToPosition(e)},e.prototype.jumpToMatching=function(e,t){var n=this.getCursorPosition(),i=new b(this.session,n.row,n.column),r=i.getCurrentToken(),o=0;r&&-1!==r.type.indexOf("tag-name")&&(r=i.stepBackward());var a=r||i.stepForward();if(a){var s,l,c=!1,d={},u=n.column-a.start,h={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(a.value.match(/[{}()\[\]]/g)){for(;u<a.value.length&&!c;u++)if(h[a.value[u]])switch(l=h[a.value[u]]+"."+a.type.replace("rparen","lparen"),isNaN(d[l])&&(d[l]=0),a.value[u]){case"(":case"[":case"{":d[l]++;break;case")":case"]":case"}":d[l]--,-1===d[l]&&(s="bracket",c=!0)}}else-1!==a.type.indexOf("tag-name")&&(isNaN(d[a.value])&&(d[a.value]=0),"<"===r.value&&o>1?d[a.value]++:"</"===r.value&&d[a.value]--,-1===d[a.value]&&(s="tag",c=!0));c||(r=a,o++,a=i.stepForward(),u=0)}while(a&&!c);if(s){var p,f;if("bracket"===s)(p=this.session.getBracketRange(n))||(f=(p=new g(i.getCurrentTokenRow(),i.getCurrentTokenColumn()+u-1,i.getCurrentTokenRow(),i.getCurrentTokenColumn()+u-1)).start,(t||f.row===n.row&&Math.abs(f.column-n.column)<2)&&(p=this.session.getBracketRange(f)));else if("tag"===s){if(!a||-1===a.type.indexOf("tag-name"))return;if(0===(p=new g(i.getCurrentTokenRow(),i.getCurrentTokenColumn()-2,i.getCurrentTokenRow(),i.getCurrentTokenColumn()-2)).compare(n.row,n.column)){var m=this.session.getMatchingTags(n);m&&(m.openTag.contains(n.row,n.column)?f=(p=m.closeTag).start:(p=m.openTag,f=m.closeTag.start.row===n.row&&m.closeTag.start.column===n.column?p.end:p.start))}f=f||p.start}(f=p&&p.cursor||f)&&(e?p&&t?this.selection.setRange(p):p&&p.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(f.row,f.column):this.selection.moveTo(f.row,f.column))}}},e.prototype.gotoLine=function(e,t,n){this.selection.clearSelection(),this.session.unfold({row:e-1,column:t||0}),this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(e-1,t||0),this.isRowFullyVisible(e-1)||this.scrollToLine(e-1,!0,n)},e.prototype.navigateTo=function(e,t){this.selection.moveTo(e,t)},e.prototype.navigateUp=function(e){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(-e||-1,0)},e.prototype.navigateDown=function(e){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(e||1,0)},e.prototype.navigateLeft=function(e){if(this.selection.isEmpty())for(e=e||1;e--;)this.selection.moveCursorLeft();else{var t=this.getSelectionRange().start;this.moveCursorToPosition(t)}this.clearSelection()},e.prototype.navigateRight=function(e){if(this.selection.isEmpty())for(e=e||1;e--;)this.selection.moveCursorRight();else{var t=this.getSelectionRange().end;this.moveCursorToPosition(t)}this.clearSelection()},e.prototype.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},e.prototype.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},e.prototype.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},e.prototype.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},e.prototype.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},e.prototype.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},e.prototype.replace=function(e,t){t&&this.$search.set(t);var n=this.$search.find(this.session),i=0;return n?(this.$tryReplace(n,e)&&(i=1),this.selection.setSelectionRange(n),this.renderer.scrollSelectionIntoView(n.start,n.end),i):i},e.prototype.replaceAll=function(e,t){t&&this.$search.set(t);var n=this.$search.findAll(this.session),i=0;if(!n.length)return i;var r=this.getSelectionRange();this.selection.moveTo(0,0);for(var o=n.length-1;o>=0;--o)this.$tryReplace(n[o],e)&&i++;return this.selection.setSelectionRange(r),i},e.prototype.$tryReplace=function(e,t){var n=this.session.getTextRange(e);return null!==(t=this.$search.replace(n,t))?(e.end=this.session.replace(e,t),e):null},e.prototype.getLastSearchOptions=function(){return this.$search.getOptions()},e.prototype.find=function(e,t,n){t||(t={}),"string"==typeof e||e instanceof RegExp?t.needle=e:"object"==typeof e&&r.mixin(t,e);var i=this.selection.getRange();null==t.needle&&((e=this.session.getTextRange(i)||this.$search.$options.needle)||(i=this.session.getWordRange(i.start.row,i.start.column),e=this.session.getTextRange(i)),this.$search.set({needle:e})),this.$search.set(t),t.start||this.$search.set({start:i});var o=this.$search.find(this.session);return t.preventScroll?o:o?(this.revealRange(o,n),o):(t.backwards?i.start=i.end:i.end=i.start,void this.selection.setRange(i))},e.prototype.findNext=function(e,t){this.find({skipCurrent:!0,backwards:!1},e,t)},e.prototype.findPrevious=function(e,t){this.find(e,{skipCurrent:!0,backwards:!0},t)},e.prototype.revealRange=function(e,t){this.session.unfold(e),this.selection.setSelectionRange(e);var n=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(e.start,e.end,.5),!1!==t&&this.renderer.animateScrolling(n)},e.prototype.undo=function(){this.session.getUndoManager().undo(this.session),this.renderer.scrollCursorIntoView(null,.5)},e.prototype.redo=function(){this.session.getUndoManager().redo(this.session),this.renderer.scrollCursorIntoView(null,.5)},e.prototype.destroy=function(){this.$toDestroy&&(this.$toDestroy.forEach((function(e){e.destroy()})),this.$toDestroy=null),this.$mouseHandler&&this.$mouseHandler.destroy(),this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy(),this._$emitInputEvent&&this._$emitInputEvent.cancel(),this.removeAllListeners()},e.prototype.setAutoScrollEditorIntoView=function(e){if(e){var t,n=this,i=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var r=this.$scrollAnchor;r.style.cssText="position:absolute",this.container.insertBefore(r,this.container.firstChild);var o=this.on("changeSelection",(function(){i=!0})),a=this.renderer.on("beforeRender",(function(){i&&(t=n.renderer.container.getBoundingClientRect())})),s=this.renderer.on("afterRender",(function(){if(i&&t&&(n.isFocused()||n.searchBox&&n.searchBox.isFocused())){var e=n.renderer,o=e.$cursorLayer.$pixelPos,a=e.layerConfig,s=o.top-a.offset;null!=(i=o.top>=0&&s+t.top<0||!(o.top<a.height&&o.top+t.top+a.lineHeight>window.innerHeight)&&null)&&(r.style.top=s+"px",r.style.left=o.left+"px",r.style.height=a.lineHeight+"px",r.scrollIntoView(i)),i=t=null}}));this.setAutoScrollEditorIntoView=function(e){e||(delete this.setAutoScrollEditorIntoView,this.off("changeSelection",o),this.renderer.off("afterRender",s),this.renderer.off("beforeRender",a))}}},e.prototype.$resetCursorStyle=function(){var e=this.$cursorStyle||"ace",t=this.renderer.$cursorLayer;t&&(t.setSmoothBlinking(/smooth/.test(e)),t.isBlinking=!this.$readOnly&&"wide"!=e,o.setCssClass(t.element,"ace_slim-cursors",/slim/.test(e)))},e.prototype.prompt=function(e,t,n){var i=this;v.loadModule("ace/ext/prompt",(function(r){r.prompt(i,e,t,n)}))},e}();k.$uid=0,k.prototype.curOp=null,k.prototype.prevOp={},k.prototype.$mergeableCommands=["backspace","del","insertstring"],k.prototype.$toggleWordPairs=[["first","last"],["true","false"],["yes","no"],["width","height"],["top","bottom"],["right","left"],["on","off"],["x","y"],["get","set"],["max","min"],["horizontal","vertical"],["show","hide"],["add","remove"],["up","down"],["before","after"],["even","odd"],["in","out"],["inside","outside"],["next","previous"],["increase","decrease"],["attach","detach"],["&&","||"],["==","!="]],r.implement(k.prototype,f),v.defineOptions(k.prototype,"editor",{selectionStyle:{set:function(e){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:e})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(e){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(e){var t=this;this.textInput.setReadOnly(e),this.$resetCursorStyle(),this.$readOnlyCallback||(this.$readOnlyCallback=function(e){var n=!1;if(e&&"keydown"==e.type){if(!(n=e&&e.key&&1==e.key.length&&!e.ctrlKey&&!e.metaKey))return}else e&&"exec"!==e.type&&(n=!0);if(n){t.hoverTooltip||(t.hoverTooltip=new E);var i=o.createElement("div");i.textContent=C("editor.tooltip.disable-editing","Editing is disabled"),t.hoverTooltip.isOpen||t.hoverTooltip.showForRange(t,t.getSelectionRange(),i)}else t.hoverTooltip&&t.hoverTooltip.isOpen&&t.hoverTooltip.hide()});var n=this.textInput.getElement();e?(_.addListener(n,"keydown",this.$readOnlyCallback,this),this.commands.on("exec",this.$readOnlyCallback),this.commands.on("commandUnavailable",this.$readOnlyCallback)):(_.removeListener(n,"keydown",this.$readOnlyCallback),this.commands.off("exec",this.$readOnlyCallback),this.commands.off("commandUnavailable",this.$readOnlyCallback),this.hoverTooltip&&(this.hoverTooltip.destroy(),this.hoverTooltip=null))},initialValue:!1},copyWithEmptySelection:{set:function(e){this.textInput.setCopyWithEmptySelection(e)},initialValue:!1},cursorStyle:{set:function(e){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},enableAutoIndent:{initialValue:!0},autoScrollEditorIntoView:{set:function(e){this.setAutoScrollEditorIntoView(e)}},keyboardHandler:{set:function(e){this.setKeyboardHandler(e)},get:function(){return this.$keybindingId},handlesSet:!0},value:{set:function(e){this.session.setValue(e)},get:function(){return this.getValue()},handlesSet:!0,hidden:!0},session:{set:function(e){this.setSession(e)},get:function(){return this.session},handlesSet:!0,hidden:!0},showLineNumbers:{set:function(e){this.renderer.$gutterLayer.setShowLineNumbers(e),this.renderer.$loop.schedule(this.renderer.CHANGE_GUTTER),e&&this.$relativeLineNumbers?$.attach(this):$.detach(this)},initialValue:!0},relativeLineNumbers:{set:function(e){this.$showLineNumbers&&e?$.attach(this):$.detach(this)}},placeholder:{set:function(e){this.$updatePlaceholder||(this.$updatePlaceholder=function(){var e=this.session&&(this.renderer.$composition||this.session.getLength()>1||this.session.getLine(0).length>0);if(e&&this.renderer.placeholderNode)this.renderer.off("afterRender",this.$updatePlaceholder),o.removeCssClass(this.container,"ace_hasPlaceholder"),this.renderer.placeholderNode.remove(),this.renderer.placeholderNode=null;else if(e||this.renderer.placeholderNode)!e&&this.renderer.placeholderNode&&(this.renderer.placeholderNode.textContent=this.$placeholder||"");else{this.renderer.on("afterRender",this.$updatePlaceholder),o.addCssClass(this.container,"ace_hasPlaceholder");var t=o.createElement("div");t.className="ace_placeholder",t.textContent=this.$placeholder||"",this.renderer.placeholderNode=t,this.renderer.content.appendChild(this.renderer.placeholderNode)}}.bind(this),this.on("input",this.$updatePlaceholder)),this.$updatePlaceholder()}},enableKeyboardAccessibility:{set:function(e){var t,n={name:"blurTextInput",description:"Set focus to the editor content div to allow tabbing through the page",bindKey:"Esc",exec:function(e){e.blur(),e.renderer.scroller.focus()},readOnly:!0},i=function(e){if(e.target==this.renderer.scroller&&e.keyCode===S.enter){e.preventDefault();var t=this.getCursorPosition().row;this.isRowVisible(t)||this.scrollToLine(t,!0,!0),this.focus()}};e?(this.renderer.enableKeyboardAccessibility=!0,this.renderer.keyboardFocusClassName="ace_keyboard-focus",this.textInput.getElement().setAttribute("tabindex",-1),this.textInput.setNumberOfExtraLines(s.isWin?3:0),this.renderer.scroller.setAttribute("tabindex",0),this.renderer.scroller.setAttribute("role","group"),this.renderer.scroller.setAttribute("aria-roledescription",C("editor.scroller.aria-roledescription","editor")),this.renderer.scroller.classList.add(this.renderer.keyboardFocusClassName),this.renderer.scroller.setAttribute("aria-label",C("editor.scroller.aria-label","Editor content, press Enter to start editing, press Escape to exit")),this.renderer.scroller.addEventListener("keyup",i.bind(this)),this.commands.addCommand(n),this.renderer.$gutter.setAttribute("tabindex",0),this.renderer.$gutter.setAttribute("aria-hidden",!1),this.renderer.$gutter.setAttribute("role","group"),this.renderer.$gutter.setAttribute("aria-roledescription",C("editor.gutter.aria-roledescription","editor gutter")),this.renderer.$gutter.setAttribute("aria-label",C("editor.gutter.aria-label","Editor gutter, press Enter to interact with controls using arrow keys, press Escape to exit")),this.renderer.$gutter.classList.add(this.renderer.keyboardFocusClassName),this.renderer.content.setAttribute("aria-hidden",!0),t||(t=new w(this)),t.addListener(),this.textInput.setAriaOptions({setLabel:!0})):(this.renderer.enableKeyboardAccessibility=!1,this.textInput.getElement().setAttribute("tabindex",0),this.textInput.setNumberOfExtraLines(0),this.renderer.scroller.setAttribute("tabindex",-1),this.renderer.scroller.removeAttribute("role"),this.renderer.scroller.removeAttribute("aria-roledescription"),this.renderer.scroller.classList.remove(this.renderer.keyboardFocusClassName),this.renderer.scroller.removeAttribute("aria-label"),this.renderer.scroller.removeEventListener("keyup",i.bind(this)),this.commands.removeCommand(n),this.renderer.content.removeAttribute("aria-hidden"),this.renderer.$gutter.setAttribute("tabindex",-1),this.renderer.$gutter.setAttribute("aria-hidden",!0),this.renderer.$gutter.removeAttribute("role"),this.renderer.$gutter.removeAttribute("aria-roledescription"),this.renderer.$gutter.removeAttribute("aria-label"),this.renderer.$gutter.classList.remove(this.renderer.keyboardFocusClassName),t&&t.removeListener())},initialValue:!1},textInputAriaLabel:{set:function(e){this.$textInputAriaLabel=e},initialValue:""},enableMobileMenu:{set:function(e){this.$enableMobileMenu=e},initialValue:!0},customScrollbar:"renderer",hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",displayIndentGuides:"renderer",highlightIndentGuides:"renderer",showGutter:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",hasCssTransforms:"renderer",maxPixelHeight:"renderer",useTextareaForIME:"renderer",useResizeObserver:"renderer",useSvgGutterIcons:"renderer",showFoldedAnnotations:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimeout:"$mouseHandler",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",navigateWithinSoftTabs:"session",tabSize:"session",wrap:"session",indentedSoftWrap:"session",foldStyle:"session",mode:"session"});var $={getText:function(e,t){return(Math.abs(e.selection.lead.row-t)||t+1+(t<9?"·":""))+""},getWidth:function(e,t,n){return Math.max(t.toString().length,(n.lastRow+1).toString().length,2)*n.characterWidth},update:function(e,t){t.renderer.$loop.schedule(t.renderer.CHANGE_GUTTER)},attach:function(e){e.renderer.$gutterLayer.$renderer=this,e.on("changeSelection",this.update),this.update(null,e)},detach:function(e){e.renderer.$gutterLayer.$renderer==this&&(e.renderer.$gutterLayer.$renderer=null),e.off("changeSelection",this.update),this.update(null,e)}};t.Editor=k})),ace.define("ace/layer/lines",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var i=e("../lib/dom"),r=function(){function e(e,t){this.element=e,this.canvasHeight=t||5e5,this.element.style.height=2*this.canvasHeight+"px",this.cells=[],this.cellCache=[],this.$offsetCoefficient=0}return e.prototype.moveContainer=function(e){i.translate(this.element,0,-e.firstRowScreen*e.lineHeight%this.canvasHeight-e.offset*this.$offsetCoefficient)},e.prototype.pageChanged=function(e,t){return Math.floor(e.firstRowScreen*e.lineHeight/this.canvasHeight)!==Math.floor(t.firstRowScreen*t.lineHeight/this.canvasHeight)},e.prototype.computeLineTop=function(e,t,n){var i=t.firstRowScreen*t.lineHeight,r=Math.floor(i/this.canvasHeight);return n.documentToScreenRow(e,0)*t.lineHeight-r*this.canvasHeight},e.prototype.computeLineHeight=function(e,t,n){return t.lineHeight*n.getRowLineCount(e)},e.prototype.getLength=function(){return this.cells.length},e.prototype.get=function(e){return this.cells[e]},e.prototype.shift=function(){this.$cacheCell(this.cells.shift())},e.prototype.pop=function(){this.$cacheCell(this.cells.pop())},e.prototype.push=function(e){if(Array.isArray(e)){this.cells.push.apply(this.cells,e);for(var t=i.createFragment(this.element),n=0;n<e.length;n++)t.appendChild(e[n].element);this.element.appendChild(t)}else this.cells.push(e),this.element.appendChild(e.element)},e.prototype.unshift=function(e){if(Array.isArray(e)){this.cells.unshift.apply(this.cells,e);for(var t=i.createFragment(this.element),n=0;n<e.length;n++)t.appendChild(e[n].element);this.element.firstChild?this.element.insertBefore(t,this.element.firstChild):this.element.appendChild(t)}else this.cells.unshift(e),this.element.insertAdjacentElement("afterbegin",e.element)},e.prototype.last=function(){return this.cells.length?this.cells[this.cells.length-1]:null},e.prototype.$cacheCell=function(e){e&&(e.element.remove(),this.cellCache.push(e))},e.prototype.createCell=function(e,t,n,r){var o=this.cellCache.pop();if(!o){var a=i.createElement("div");r&&r(a),this.element.appendChild(a),o={element:a,text:"",row:e}}return o.row=e,o},e}();t.Lines=r})),ace.define("ace/layer/gutter",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/layer/lines","ace/config"],(function(e,t,n){"use strict";var i=e("../lib/dom"),r=e("../lib/oop"),o=e("../lib/lang"),a=e("../lib/event_emitter").EventEmitter,s=e("./lines").Lines,l=e("../config").nls,c=function(){function e(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_gutter-layer",e.appendChild(this.element),this.setShowFoldWidgets(this.$showFoldWidgets),this.gutterWidth=0,this.$annotations=[],this.$updateAnnotations=this.$updateAnnotations.bind(this),this.$lines=new s(this.element),this.$lines.$offsetCoefficient=1}return e.prototype.setSession=function(e){this.session&&this.session.off("change",this.$updateAnnotations),this.session=e,e&&e.on("change",this.$updateAnnotations)},e.prototype.addGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(e,t)},e.prototype.removeGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(e,t)},e.prototype.setAnnotations=function(e){this.$annotations=[];for(var t=0;t<e.length;t++){var n=e[t],i=n.row,r=this.$annotations[i];r||(r=this.$annotations[i]={text:[],type:[],displayText:[]});var a=n.text,s=n.text,l=n.type;a=a?o.escapeHTML(a):n.html||"",s=s||n.html||"",-1===r.text.indexOf(a)&&(r.text.push(a),r.type.push(l),r.displayText.push(s));var c=n.className;c?r.className=c:"error"===l?r.className=" ace_error":"security"!==l||/\bace_error\b/.test(r.className)?"warning"!==l||/\bace_(error|security)\b/.test(r.className)?"info"!==l||r.className?"hint"!==l||r.className||(r.className=" ace_hint"):r.className=" ace_info":r.className=" ace_warning":r.className=" ace_security"}},e.prototype.$updateAnnotations=function(e){if(this.$annotations.length){var t=e.start.row,n=e.end.row-t;if(0===n);else if("remove"==e.action)this.$annotations.splice(t,n+1,null);else{var i=new Array(n+1);i.unshift(t,1),this.$annotations.splice.apply(this.$annotations,i)}}},e.prototype.update=function(e){this.config=e;var t=this.session,n=e.firstRow,i=Math.min(e.lastRow+e.gutterOffset,t.getLength()-1);this.oldLastRow=i,this.config=e,this.$lines.moveContainer(e),this.$updateCursorRow();for(var r=t.getNextFoldLine(n),o=r?r.start.row:1/0,a=null,s=-1,l=n;;){if(l>o&&(l=r.end.row+1,o=(r=t.getNextFoldLine(l,r))?r.start.row:1/0),l>i){for(;this.$lines.getLength()>s+1;)this.$lines.pop();break}(a=this.$lines.get(++s))?a.row=l:(a=this.$lines.createCell(l,e,this.session,d),this.$lines.push(a)),this.$renderCell(a,e,r,l),l++}this._signal("afterRender"),this.$updateGutterWidth(e)},e.prototype.$updateGutterWidth=function(e){var t=this.session,n=t.gutterRenderer||this.$renderer,i=t.$firstLineNumber,r=this.$lines.last()?this.$lines.last().text:"";(this.$fixedWidth||t.$useWrapMode)&&(r=t.getLength()+i-1);var o=n?n.getWidth(t,r,e):r.toString().length*e.characterWidth,a=this.$padding||this.$computePadding();(o+=a.left+a.right)===this.gutterWidth||isNaN(o)||(this.gutterWidth=o,this.element.parentNode.style.width=this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._signal("changeGutterWidth",o))},e.prototype.$updateCursorRow=function(){if(this.$highlightGutterLine){var e=this.session.selection.getCursor();this.$cursorRow!==e.row&&(this.$cursorRow=e.row)}},e.prototype.updateLineHighlight=function(){if(this.$highlightGutterLine){var e=this.session.selection.cursor.row;if(this.$cursorRow=e,!this.$cursorCell||this.$cursorCell.row!=e){this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ",""));var t=this.$lines.cells;this.$cursorCell=null;for(var n=0;n<t.length;n++){var i=t[n];if(i.row>=this.$cursorRow){if(i.row>this.$cursorRow){var r=this.session.getFoldLine(this.$cursorRow);if(!(n>0&&r&&r.start.row==t[n-1].row))break;i=t[n-1]}i.element.className="ace_gutter-active-line "+i.element.className,this.$cursorCell=i;break}}}}},e.prototype.scrollLines=function(e){var t=this.config;if(this.config=e,this.$updateCursorRow(),this.$lines.pageChanged(t,e))return this.update(e);this.$lines.moveContainer(e);var n=Math.min(e.lastRow+e.gutterOffset,this.session.getLength()-1),i=this.oldLastRow;if(this.oldLastRow=n,!t||i<e.firstRow)return this.update(e);if(n<t.firstRow)return this.update(e);if(t.firstRow<e.firstRow)for(var r=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);r>0;r--)this.$lines.shift();if(i>n)for(r=this.session.getFoldedRowCount(n+1,i);r>0;r--)this.$lines.pop();e.firstRow<t.firstRow&&this.$lines.unshift(this.$renderLines(e,e.firstRow,t.firstRow-1)),n>i&&this.$lines.push(this.$renderLines(e,i+1,n)),this.updateLineHighlight(),this._signal("afterRender"),this.$updateGutterWidth(e)},e.prototype.$renderLines=function(e,t,n){for(var i=[],r=t,o=this.session.getNextFoldLine(r),a=o?o.start.row:1/0;r>a&&(r=o.end.row+1,a=(o=this.session.getNextFoldLine(r,o))?o.start.row:1/0),!(r>n);){var s=this.$lines.createCell(r,e,this.session,d);this.$renderCell(s,e,o,r),i.push(s),r++}return i},e.prototype.$renderCell=function(e,t,n,r){var o=e.element,a=this.session,s=o.childNodes[0],c=o.childNodes[1],d=o.childNodes[2],u=d.firstChild,h=a.$firstLineNumber,p=a.$breakpoints,g=a.$decorations,f=a.gutterRenderer||this.$renderer,m=this.$showFoldWidgets&&a.foldWidgets,y=n?n.start.row:Number.MAX_VALUE,v=t.lineHeight+"px",b=this.$useSvgGutterIcons?"ace_gutter-cell_svg-icons ":"ace_gutter-cell ",w=this.$useSvgGutterIcons?"ace_icon_svg":"ace_icon",C=(f?f.getText(a,r):r+h).toString();if(this.$highlightGutterLine&&(r==this.$cursorRow||n&&r<this.$cursorRow&&r>=y&&this.$cursorRow<=n.end.row)&&(b+="ace_gutter-active-line ",this.$cursorCell!=e&&(this.$cursorCell&&(this.$cursorCell.element.className=this.$cursorCell.element.className.replace("ace_gutter-active-line ","")),this.$cursorCell=e)),p[r]&&(b+=p[r]),g[r]&&(b+=g[r]),this.$annotations[r]&&r!==y&&(b+=this.$annotations[r].className),m){var x=m[r];null==x&&(x=m[r]=a.getFoldWidget(r))}if(x){var S="ace_fold-widget ace_"+x,_="start"==x&&r==y&&r<n.end.row;if(_){S+=" ace_closed";for(var E="",k=!1,$=r+1;$<=n.end.row;$++)if(this.$annotations[$]){if(" ace_error"===this.$annotations[$].className){k=!0,E=" ace_error_fold";break}" ace_security"===this.$annotations[$].className?(k=!0,E=" ace_security_fold"):" ace_warning"===this.$annotations[$].className&&" ace_security_fold"!==E&&(k=!0,E=" ace_warning_fold")}b+=E}else S+=" ace_open";c.className!=S&&(c.className=S),i.setStyle(c.style,"height",v),i.setStyle(c.style,"display","inline-block"),c.setAttribute("role","button"),c.setAttribute("tabindex","-1");var M=a.getFoldWidgetRange(r);M?c.setAttribute("aria-label",l("gutter.code-folding.range.aria-label","Toggle code folding, rows $0 through $1",[M.start.row+1,M.end.row+1])):n?c.setAttribute("aria-label",l("gutter.code-folding.closed.aria-label","Toggle code folding, rows $0 through $1",[n.start.row+1,n.end.row+1])):c.setAttribute("aria-label",l("gutter.code-folding.open.aria-label","Toggle code folding, row $0",[r+1])),_?(c.setAttribute("aria-expanded","false"),c.setAttribute("title",l("gutter.code-folding.closed.title","Unfold code"))):(c.setAttribute("aria-expanded","true"),c.setAttribute("title",l("gutter.code-folding.open.title","Fold code")))}else c&&(i.setStyle(c.style,"display","none"),c.setAttribute("tabindex","0"),c.removeAttribute("role"),c.removeAttribute("aria-label"));if(k&&this.$showFoldedAnnotations){switch(d.className="ace_gutter_annotation",u.className=w,u.className+=E,i.setStyle(u.style,"height",v),i.setStyle(d.style,"display","block"),i.setStyle(d.style,"height",v),E){case" ace_error_fold":T=l("gutter.annotation.aria-label.error","Error, read annotations row $0",[C]);break;case" ace_security_fold":T=l("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[C]);break;case" ace_warning_fold":T=l("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[C])}d.setAttribute("aria-label",T),d.setAttribute("tabindex","-1"),d.setAttribute("role","button")}else if(this.$annotations[r]){var T;switch(d.className="ace_gutter_annotation",u.className=w,this.$useSvgGutterIcons?u.className+=this.$annotations[r].className:o.classList.add(this.$annotations[r].className.replace(" ","")),i.setStyle(u.style,"height",v),i.setStyle(d.style,"display","block"),i.setStyle(d.style,"height",v),this.$annotations[r].className){case" ace_error":T=l("gutter.annotation.aria-label.error","Error, read annotations row $0",[C]);break;case" ace_security":T=l("gutter.annotation.aria-label.security","Security finding, read annotations row $0",[C]);break;case" ace_warning":T=l("gutter.annotation.aria-label.warning","Warning, read annotations row $0",[C]);break;case" ace_info":T=l("gutter.annotation.aria-label.info","Info, read annotations row $0",[C]);break;case" ace_hint":T=l("gutter.annotation.aria-label.hint","Suggestion, read annotations row $0",[C])}d.setAttribute("aria-label",T),d.setAttribute("tabindex","-1"),d.setAttribute("role","button")}else i.setStyle(d.style,"display","none"),d.removeAttribute("aria-label"),d.removeAttribute("role"),d.setAttribute("tabindex","0");return C!==s.data&&(s.data=C),o.className!=b&&(o.className=b),i.setStyle(e.element.style,"height",this.$lines.computeLineHeight(r,t,a)+"px"),i.setStyle(e.element.style,"top",this.$lines.computeLineTop(r,t,a)+"px"),e.text=C,"none"===d.style.display&&"none"===c.style.display?e.element.setAttribute("aria-hidden",!0):e.element.setAttribute("aria-hidden",!1),e},e.prototype.setHighlightGutterLine=function(e){this.$highlightGutterLine=e},e.prototype.setShowLineNumbers=function(e){this.$renderer=!e&&{getWidth:function(){return 0},getText:function(){return""}}},e.prototype.getShowLineNumbers=function(){return this.$showLineNumbers},e.prototype.setShowFoldWidgets=function(e){e?i.addCssClass(this.element,"ace_folding-enabled"):i.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=e,this.$padding=null},e.prototype.getShowFoldWidgets=function(){return this.$showFoldWidgets},e.prototype.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var e=i.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=(parseInt(e.borderLeftWidth)||0)+(parseInt(e.paddingLeft)||0)+1,this.$padding.right=(parseInt(e.borderRightWidth)||0)+(parseInt(e.paddingRight)||0),this.$padding},e.prototype.getRegion=function(e){var t=this.$padding||this.$computePadding(),n=this.element.getBoundingClientRect();return e.x<t.left+n.left?"markers":this.$showFoldWidgets&&e.x>n.right-t.right?"foldWidgets":void 0},e}();function d(e){var t=document.createTextNode("");e.appendChild(t);var n=i.createElement("span");e.appendChild(n);var r=i.createElement("span");e.appendChild(r);var o=i.createElement("span");return r.appendChild(o),e}c.prototype.$fixedWidth=!1,c.prototype.$highlightGutterLine=!0,c.prototype.$renderer="",c.prototype.$showLineNumbers=!0,c.prototype.$showFoldWidgets=!0,r.implement(c.prototype,a),t.Gutter=c})),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],(function(e,t,n){"use strict";var i=e("../range").Range,r=e("../lib/dom"),o=function(){function e(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_marker-layer",e.appendChild(this.element)}return e.prototype.setPadding=function(e){this.$padding=e},e.prototype.setSession=function(e){this.session=e},e.prototype.setMarkers=function(e){this.markers=e},e.prototype.elt=function(e,t){var n=-1!=this.i&&this.element.childNodes[this.i];n?this.i++:(n=document.createElement("div"),this.element.appendChild(n),this.i=-1),n.style.cssText=t,n.className=e},e.prototype.update=function(e){if(e){var t;for(var n in this.config=e,this.i=0,this.markers){var i=this.markers[n];if(i.range){var r=i.range.clipRows(e.firstRow,e.lastRow);if(!r.isEmpty())if(r=r.toScreenRange(this.session),i.renderer){var o=this.$getTop(r.start.row,e),a=this.$padding+r.start.column*e.characterWidth;i.renderer(t,r,a,o,e)}else"fullLine"==i.type?this.drawFullLineMarker(t,r,i.clazz,e):"screenLine"==i.type?this.drawScreenLineMarker(t,r,i.clazz,e):r.isMultiLine()?"text"==i.type?this.drawTextMarker(t,r,i.clazz,e):this.drawMultiLineMarker(t,r,i.clazz,e):this.drawSingleLineMarker(t,r,i.clazz+" ace_start ace_br15",e)}else i.update(t,this,this.session,e)}if(-1!=this.i)for(;this.i<this.element.childElementCount;)this.element.removeChild(this.element.lastChild)}},e.prototype.$getTop=function(e,t){return(e-t.firstRowScreen)*t.lineHeight},e.prototype.drawTextMarker=function(e,t,n,r,o){for(var a=this.session,s=t.start.row,l=t.end.row,c=s,d=0,u=0,h=a.getScreenLastRowColumn(c),p=new i(c,t.start.column,c,u);c<=l;c++)p.start.row=p.end.row=c,p.start.column=c==s?t.start.column:a.getRowWrapIndent(c),p.end.column=h,d=u,u=h,h=c+1<l?a.getScreenLastRowColumn(c+1):c==l?0:t.end.column,this.drawSingleLineMarker(e,p,n+(c==s?" ace_start":"")+" ace_br"+((c==s||c==s+1&&t.start.column?1:0)|(d<u?2:0)|(u>h?4:0)|(c==l?8:0)),r,c==l?0:1,o)},e.prototype.drawMultiLineMarker=function(e,t,n,i,r){var o=this.$padding,a=i.lineHeight,s=this.$getTop(t.start.row,i),l=o+t.start.column*i.characterWidth;if(r=r||"",this.session.$bidiHandler.isBidiRow(t.start.row)?((c=t.clone()).end.row=c.start.row,c.end.column=this.session.getLine(c.start.row).length,this.drawBidiSingleLineMarker(e,c,n+" ace_br1 ace_start",i,null,r)):this.elt(n+" ace_br1 ace_start","height:"+a+"px;right:"+o+"px;top:"+s+"px;left:"+l+"px;"+(r||"")),this.session.$bidiHandler.isBidiRow(t.end.row)){var c;(c=t.clone()).start.row=c.end.row,c.start.column=0,this.drawBidiSingleLineMarker(e,c,n+" ace_br12",i,null,r)}else{s=this.$getTop(t.end.row,i);var d=t.end.column*i.characterWidth;this.elt(n+" ace_br12","height:"+a+"px;width:"+d+"px;top:"+s+"px;left:"+o+"px;"+(r||""))}if(!((a=(t.end.row-t.start.row-1)*i.lineHeight)<=0)){s=this.$getTop(t.start.row+1,i);var u=(t.start.column?1:0)|(t.end.column?0:8);this.elt(n+(u?" ace_br"+u:""),"height:"+a+"px;right:"+o+"px;top:"+s+"px;left:"+o+"px;"+(r||""))}},e.prototype.drawSingleLineMarker=function(e,t,n,i,r,o){if(this.session.$bidiHandler.isBidiRow(t.start.row))return this.drawBidiSingleLineMarker(e,t,n,i,r,o);var a=i.lineHeight,s=(t.end.column+(r||0)-t.start.column)*i.characterWidth,l=this.$getTop(t.start.row,i),c=this.$padding+t.start.column*i.characterWidth;this.elt(n,"height:"+a+"px;width:"+s+"px;top:"+l+"px;left:"+c+"px;"+(o||""))},e.prototype.drawBidiSingleLineMarker=function(e,t,n,i,r,o){var a=i.lineHeight,s=this.$getTop(t.start.row,i),l=this.$padding;this.session.$bidiHandler.getSelections(t.start.column,t.end.column).forEach((function(e){this.elt(n,"height:"+a+"px;width:"+(e.width+(r||0))+"px;top:"+s+"px;left:"+(l+e.left)+"px;"+(o||""))}),this)},e.prototype.drawFullLineMarker=function(e,t,n,i,r){var o=this.$getTop(t.start.row,i),a=i.lineHeight;t.start.row!=t.end.row&&(a+=this.$getTop(t.end.row,i)-o),this.elt(n,"height:"+a+"px;top:"+o+"px;left:0;right:0;"+(r||""))},e.prototype.drawScreenLineMarker=function(e,t,n,i,r){var o=this.$getTop(t.start.row,i),a=i.lineHeight;this.elt(n,"height:"+a+"px;top:"+o+"px;left:0;right:0;"+(r||""))},e}();o.prototype.$padding=0,t.Marker=o})),ace.define("ace/layer/text_util",["require","exports","module"],(function(e,t,n){var i=new Set(["text","rparen","lparen"]);t.isTextToken=function(e){return i.has(e)}})),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/layer/lines","ace/lib/event_emitter","ace/config","ace/layer/text_util"],(function(e,t,n){"use strict";var i=e("../lib/oop"),r=e("../lib/dom"),o=e("../lib/lang"),a=e("./lines").Lines,s=e("../lib/event_emitter").EventEmitter,l=e("../config").nls,c=e("./text_util").isTextToken,d=function(){function e(e){this.dom=r,this.element=this.dom.createElement("div"),this.element.className="ace_layer ace_text-layer",e.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this),this.$lines=new a(this.element)}return e.prototype.$updateEolChar=function(){var e=this.session.doc,t="\n"==e.getNewLineCharacter()&&"windows"!=e.getNewLineMode()?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=t)return this.EOL_CHAR=t,!0},e.prototype.setPadding=function(e){this.$padding=e,this.element.style.margin="0 "+e+"px"},e.prototype.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},e.prototype.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},e.prototype.$setFontMetrics=function(e){this.$fontMetrics=e,this.$fontMetrics.on("changeCharacterSize",function(e){this._signal("changeCharacterSize",e)}.bind(this)),this.$pollSizeChanges()},e.prototype.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},e.prototype.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},e.prototype.setSession=function(e){this.session=e,e&&this.$computeTabString()},e.prototype.setShowInvisibles=function(e){return this.showInvisibles!=e&&(this.showInvisibles=e,"string"==typeof e?(this.showSpaces=/tab/i.test(e),this.showTabs=/space/i.test(e),this.showEOL=/eol/i.test(e)):this.showSpaces=this.showTabs=this.showEOL=e,this.$computeTabString(),!0)},e.prototype.setDisplayIndentGuides=function(e){return this.displayIndentGuides!=e&&(this.displayIndentGuides=e,this.$computeTabString(),!0)},e.prototype.setHighlightIndentGuides=function(e){return this.$highlightIndentGuides!==e&&(this.$highlightIndentGuides=e,e)},e.prototype.$computeTabString=function(){var e=this.session.getTabSize();this.tabSize=e;for(var t=this.$tabStrings=[0],n=1;n<e+1;n++)this.showTabs?((i=this.dom.createElement("span")).className="ace_invisible ace_invisible_tab",i.textContent=o.stringRepeat(this.TAB_CHAR,n),t.push(i)):t.push(this.dom.createTextNode(o.stringRepeat(" ",n),this.element));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var i,r="ace_indent-guide",a=this.showSpaces?" ace_invisible ace_invisible_space":"",s=this.showSpaces?o.stringRepeat(this.SPACE_CHAR,this.tabSize):o.stringRepeat(" ",this.tabSize),l=this.showTabs?" ace_invisible ace_invisible_tab":"",c=this.showTabs?o.stringRepeat(this.TAB_CHAR,this.tabSize):s;(i=this.dom.createElement("span")).className=r+a,i.textContent=s,this.$tabStrings[" "]=i,(i=this.dom.createElement("span")).className=r+l,i.textContent=c,this.$tabStrings["\t"]=i}},e.prototype.updateLines=function(e,t,n){if(this.config.lastRow!=e.lastRow||this.config.firstRow!=e.firstRow)return this.update(e);this.config=e;for(var i=Math.max(t,e.firstRow),r=Math.min(n,e.lastRow),o=this.element.childNodes,a=0,s=e.firstRow;s<i;s++){if(l=this.session.getFoldLine(s)){if(l.containsRow(i)){i=l.start.row;break}s=l.end.row}a++}for(var l,c=!1,d=(s=i,(l=this.session.getNextFoldLine(s))?l.start.row:1/0);s>d&&(s=l.end.row+1,d=(l=this.session.getNextFoldLine(s,l))?l.start.row:1/0),!(s>r);){var u=o[a++];if(u){this.dom.removeChildren(u),this.$renderLine(u,s,s==d&&l),c&&(u.style.top=this.$lines.computeLineTop(s,e,this.session)+"px");var h=e.lineHeight*this.session.getRowLength(s)+"px";u.style.height!=h&&(c=!0,u.style.height=h)}s++}if(c)for(;a<this.$lines.cells.length;){var p=this.$lines.cells[a++];p.element.style.top=this.$lines.computeLineTop(p.row,e,this.session)+"px"}},e.prototype.scrollLines=function(e){var t=this.config;if(this.config=e,this.$lines.pageChanged(t,e))return this.update(e);this.$lines.moveContainer(e);var n=e.lastRow,i=t?t.lastRow:-1;if(!t||i<e.firstRow)return this.update(e);if(n<t.firstRow)return this.update(e);if(!t||t.lastRow<e.firstRow)return this.update(e);if(e.lastRow<t.firstRow)return this.update(e);if(t.firstRow<e.firstRow)for(var r=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);r>0;r--)this.$lines.shift();if(t.lastRow>e.lastRow)for(r=this.session.getFoldedRowCount(e.lastRow+1,t.lastRow);r>0;r--)this.$lines.pop();e.firstRow<t.firstRow&&this.$lines.unshift(this.$renderLinesFragment(e,e.firstRow,t.firstRow-1)),e.lastRow>t.lastRow&&this.$lines.push(this.$renderLinesFragment(e,t.lastRow+1,e.lastRow)),this.$highlightIndentGuide()},e.prototype.$renderLinesFragment=function(e,t,n){for(var i=[],o=t,a=this.session.getNextFoldLine(o),s=a?a.start.row:1/0;o>s&&(o=a.end.row+1,s=(a=this.session.getNextFoldLine(o,a))?a.start.row:1/0),!(o>n);){var l=this.$lines.createCell(o,e,this.session),c=l.element;this.dom.removeChildren(c),r.setStyle(c.style,"height",this.$lines.computeLineHeight(o,e,this.session)+"px"),r.setStyle(c.style,"top",this.$lines.computeLineTop(o,e,this.session)+"px"),this.$renderLine(c,o,o==s&&a),this.$useLineGroups()?c.className="ace_line_group":c.className="ace_line",i.push(l),o++}return i},e.prototype.update=function(e){this.$lines.moveContainer(e),this.config=e;for(var t=e.firstRow,n=e.lastRow,i=this.$lines;i.getLength();)i.pop();i.push(this.$renderLinesFragment(e,t,n))},e.prototype.$renderToken=function(e,t,n,i){for(var r,a=this,s=/(\t)|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\uFEFF\uFFF9-\uFFFC\u2066\u2067\u2068\u202A\u202B\u202D\u202E\u202C\u2069\u2060\u2061\u2062\u2063\u2064\u206A\u206B\u206B\u206C\u206D\u206E\u206F]+)|(\u3000)|([\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3001-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]|[\uD800-\uDBFF][\uDC00-\uDFFF])/g,d=this.dom.createFragment(this.element),u=0;r=s.exec(i);){var h=r[1],p=r[2],g=r[3],f=r[4],m=r[5];if(a.showSpaces||!p){var y=u!=r.index?i.slice(u,r.index):"";if(u=r.index+r[0].length,y&&d.appendChild(this.dom.createTextNode(y,this.element)),h){var v=a.session.getScreenTabSize(t+r.index);d.appendChild(a.$tabStrings[v].cloneNode(!0)),t+=v-1}else p?a.showSpaces?((w=this.dom.createElement("span")).className="ace_invisible ace_invisible_space",w.textContent=o.stringRepeat(a.SPACE_CHAR,p.length),d.appendChild(w)):d.appendChild(this.dom.createTextNode(p,this.element)):g?((w=this.dom.createElement("span")).className="ace_invisible ace_invisible_space ace_invalid",w.textContent=o.stringRepeat(a.SPACE_CHAR,g.length),d.appendChild(w)):f?(t+=1,(w=this.dom.createElement("span")).style.width=2*a.config.characterWidth+"px",w.className=a.showSpaces?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",w.textContent=a.showSpaces?a.SPACE_CHAR:f,d.appendChild(w)):m&&(t+=1,(w=this.dom.createElement("span")).style.width=2*a.config.characterWidth+"px",w.className="ace_cjk",w.textContent=m,d.appendChild(w))}}if(d.appendChild(this.dom.createTextNode(u?i.slice(u):i,this.element)),c(n.type))e.appendChild(d);else{var b="ace_"+n.type.replace(/\./g," ace_"),w=this.dom.createElement("span");"fold"==n.type&&(w.style.width=n.value.length*this.config.characterWidth+"px",w.setAttribute("title",l("inline-fold.closed.title","Unfold code"))),w.className=b,w.appendChild(d),e.appendChild(w)}return t+i.length},e.prototype.renderIndentGuide=function(e,t,n){var i=t.search(this.$indentGuideRe);if(i<=0||i>=n)return t;if(" "==t[0]){for(var r=(i-=i%this.tabSize)/this.tabSize,o=0;o<r;o++)e.appendChild(this.$tabStrings[" "].cloneNode(!0));return this.$highlightIndentGuide(),t.substr(i)}if("\t"==t[0]){for(o=0;o<i;o++)e.appendChild(this.$tabStrings["\t"].cloneNode(!0));return this.$highlightIndentGuide(),t.substr(i)}return this.$highlightIndentGuide(),t},e.prototype.$highlightIndentGuide=function(){if(this.$highlightIndentGuides&&this.displayIndentGuides){this.$highlightIndentGuideMarker={indentLevel:void 0,start:void 0,end:void 0,dir:void 0};var e=this.session.doc.$lines;if(e){var t=this.session.selection.getCursor(),n=/^\s*/.exec(this.session.doc.getLine(t.row))[0].length,i=Math.floor(n/this.tabSize);if(this.$highlightIndentGuideMarker={indentLevel:i,start:t.row},this.session.$bracketHighlight)for(var r=this.session.$bracketHighlight.ranges,o=0;o<r.length;o++)if(t.row!==r[o].start.row){this.$highlightIndentGuideMarker.end=r[o].start.row+1,t.row>r[o].start.row?this.$highlightIndentGuideMarker.dir=-1:this.$highlightIndentGuideMarker.dir=1;break}if(!this.$highlightIndentGuideMarker.end&&""!==e[t.row]&&t.column===e[t.row].length)for(this.$highlightIndentGuideMarker.dir=1,o=t.row+1;o<e.length;o++){var a=e[o],s=/^\s*/.exec(a)[0].length;if(""!==a&&(this.$highlightIndentGuideMarker.end=o,s<=n))break}this.$renderHighlightIndentGuide()}}},e.prototype.$clearActiveIndentGuide=function(){for(var e=this.element.querySelectorAll(".ace_indent-guide-active"),t=0;t<e.length;t++)e[t].classList.remove("ace_indent-guide-active")},e.prototype.$setIndentGuideActive=function(e,t){if(""!==this.session.doc.getLine(e.row)){var n=e.element;if(e.element.classList&&e.element.classList.contains("ace_line_group")){if(!(e.element.childNodes.length>0))return;n=e.element.childNodes[0]}var i=n.childNodes;if(i){var r=i[t-1];r&&r.classList&&r.classList.contains("ace_indent-guide")&&r.classList.add("ace_indent-guide-active")}}},e.prototype.$renderHighlightIndentGuide=function(){if(this.$lines){var e=this.$lines.cells;this.$clearActiveIndentGuide();var t=this.$highlightIndentGuideMarker.indentLevel;if(0!==t)if(1===this.$highlightIndentGuideMarker.dir)for(var n=0;n<e.length;n++){var i=e[n];if(this.$highlightIndentGuideMarker.end&&i.row>=this.$highlightIndentGuideMarker.start+1){if(i.row>=this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(i,t)}}else for(n=e.length-1;n>=0;n--)if(i=e[n],this.$highlightIndentGuideMarker.end&&i.row<this.$highlightIndentGuideMarker.start){if(i.row<this.$highlightIndentGuideMarker.end)break;this.$setIndentGuideActive(i,t)}}},e.prototype.$createLineElement=function(e){var t=this.dom.createElement("div");return t.className="ace_line",t.style.height=this.config.lineHeight+"px",t},e.prototype.$renderWrappedLine=function(e,t,n){var i=0,r=0,a=n[0],s=0,l=this.$createLineElement();e.appendChild(l);for(var c=0;c<t.length;c++){var d=t[c],u=d.value;if(0==c&&this.displayIndentGuides){if(i=u.length,!(u=this.renderIndentGuide(l,u,a)))continue;i-=u.length}if(i+u.length<a)s=this.$renderToken(l,s,d,u),i+=u.length;else{for(;i+u.length>=a;)s=this.$renderToken(l,s,d,u.substring(0,a-i)),u=u.substring(a-i),i=a,l=this.$createLineElement(),e.appendChild(l),l.appendChild(this.dom.createTextNode(o.stringRepeat(" ",n.indent),this.element)),s=0,a=n[++r]||Number.MAX_VALUE;0!=u.length&&(i+=u.length,s=this.$renderToken(l,s,d,u))}}n[n.length-1]>this.MAX_LINE_LENGTH&&this.$renderOverflowMessage(l,s,null,"",!0)},e.prototype.$renderSimpleLine=function(e,t){for(var n=0,i=0;i<t.length;i++){var r=t[i],o=r.value;if(0!=i||!this.displayIndentGuides||(o=this.renderIndentGuide(e,o))){if(n+o.length>this.MAX_LINE_LENGTH)return this.$renderOverflowMessage(e,n,r,o);n=this.$renderToken(e,n,r,o)}}},e.prototype.$renderOverflowMessage=function(e,t,n,i,r){n&&this.$renderToken(e,t,n,i.slice(0,this.MAX_LINE_LENGTH-t));var o=this.dom.createElement("span");o.className="ace_inline_button ace_keyword ace_toggle_wrap",o.textContent=r?"<hide>":"<click to see more...>",e.appendChild(o)},e.prototype.$renderLine=function(e,t,n){if(n||0==n||(n=this.session.getFoldLine(t)),n)var i=this.$getFoldLineTokens(t,n);else i=this.session.getTokens(t);var r=e;if(i.length){var o=this.session.getRowSplitData(t);o&&o.length?(this.$renderWrappedLine(e,i,o),r=e.lastChild):(r=e,this.$useLineGroups()&&(r=this.$createLineElement(),e.appendChild(r)),this.$renderSimpleLine(r,i))}else this.$useLineGroups()&&(r=this.$createLineElement(),e.appendChild(r));if(this.showEOL&&r){n&&(t=n.end.row);var a=this.dom.createElement("span");a.className="ace_invisible ace_invisible_eol",a.textContent=t==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,r.appendChild(a)}},e.prototype.$getFoldLineTokens=function(e,t){var n=this.session,i=[],r=n.getTokens(e);return t.walk((function(e,t,o,a,s){null!=e?i.push({type:"fold",value:e}):(s&&(r=n.getTokens(t)),r.length&&function(e,t,n){for(var r=0,o=0;o+e[r].value.length<t;)if(o+=e[r].value.length,++r==e.length)return;for(o!=t&&((a=e[r].value.substring(t-o)).length>n-t&&(a=a.substring(0,n-t)),i.push({type:e[r].type,value:a}),o=t+a.length,r+=1);o<n&&r<e.length;){var a;(a=e[r].value).length+o>n?i.push({type:e[r].type,value:a.substring(0,n-o)}):i.push(e[r]),o+=a.length,r+=1}}(r,a,o))}),t.end.row,this.session.getLine(t.end.row).length),i},e.prototype.$useLineGroups=function(){return this.session.getUseWrapMode()},e}();d.prototype.EOF_CHAR="¶",d.prototype.EOL_CHAR_LF="¬",d.prototype.EOL_CHAR_CRLF="¤",d.prototype.EOL_CHAR=d.prototype.EOL_CHAR_LF,d.prototype.TAB_CHAR="—",d.prototype.SPACE_CHAR="·",d.prototype.$padding=0,d.prototype.MAX_LINE_LENGTH=1e4,d.prototype.showInvisibles=!1,d.prototype.showSpaces=!1,d.prototype.showTabs=!1,d.prototype.showEOL=!1,d.prototype.displayIndentGuides=!0,d.prototype.$highlightIndentGuides=!0,d.prototype.$tabStrings=[],d.prototype.destroy={},d.prototype.onChangeTabSize=d.prototype.$computeTabString,i.implement(d.prototype,s),t.Text=d})),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],(function(e,t,n){"use strict";var i=e("../lib/dom"),r=function(){function e(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_cursor-layer",e.appendChild(this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),i.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateOpacity.bind(this)}return e.prototype.$updateOpacity=function(e){for(var t=this.cursors,n=t.length;n--;)i.setStyle(t[n].style,"opacity",e?"":"0")},e.prototype.$startCssAnimation=function(){for(var e=this.cursors,t=e.length;t--;)e[t].style.animationDuration=this.blinkInterval+"ms";this.$isAnimating=!0,setTimeout(function(){this.$isAnimating&&i.addCssClass(this.element,"ace_animate-blinking")}.bind(this))},e.prototype.$stopCssAnimation=function(){this.$isAnimating=!1,i.removeCssClass(this.element,"ace_animate-blinking")},e.prototype.setPadding=function(e){this.$padding=e},e.prototype.setSession=function(e){this.session=e},e.prototype.setBlinking=function(e){e!=this.isBlinking&&(this.isBlinking=e,this.restartTimer())},e.prototype.setBlinkInterval=function(e){e!=this.blinkInterval&&(this.blinkInterval=e,this.restartTimer())},e.prototype.setSmoothBlinking=function(e){e!=this.smoothBlinking&&(this.smoothBlinking=e,i.setCssClass(this.element,"ace_smooth-blinking",e),this.$updateCursors(!0),this.restartTimer())},e.prototype.addCursor=function(){var e=i.createElement("div");return e.className="ace_cursor",this.element.appendChild(e),this.cursors.push(e),e},e.prototype.removeCursor=function(){if(this.cursors.length>1){var e=this.cursors.pop();return e.parentNode.removeChild(e),e}},e.prototype.hideCursor=function(){this.isVisible=!1,i.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},e.prototype.showCursor=function(){this.isVisible=!0,i.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},e.prototype.restartTimer=function(){var e=this.$updateCursors;if(clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.$stopCssAnimation(),this.smoothBlinking&&(this.$isSmoothBlinking=!1,i.removeCssClass(this.element,"ace_smooth-blinking")),e(!0),this.isBlinking&&this.blinkInterval&&this.isVisible)if(this.smoothBlinking&&(this.$isSmoothBlinking=!0,setTimeout(function(){this.$isSmoothBlinking&&i.addCssClass(this.element,"ace_smooth-blinking")}.bind(this))),i.HAS_CSS_ANIMATION)this.$startCssAnimation();else{var t=function(){this.timeoutId=setTimeout((function(){e(!1)}),.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval((function(){e(!0),t()}),this.blinkInterval),t()}else this.$stopCssAnimation()},e.prototype.getPixelPosition=function(e,t){if(!this.config||!this.session)return{left:0,top:0};e||(e=this.session.selection.getCursor());var n=this.session.documentToScreenPosition(e);return{left:this.$padding+(this.session.$bidiHandler.isBidiRow(n.row,e.row)?this.session.$bidiHandler.getPosLeft(n.column):n.column*this.config.characterWidth),top:(n.row-(t?this.config.firstRowScreen:0))*this.config.lineHeight}},e.prototype.isCursorInView=function(e,t){return e.top>=0&&e.top<t.maxHeight},e.prototype.update=function(e){this.config=e;var t=this.session.$selectionMarkers,n=0,r=0;void 0!==t&&0!==t.length||(t=[{cursor:null}]),n=0;for(var o=t.length;n<o;n++){var a=this.getPixelPosition(t[n].cursor,!0);if(!((a.top>e.height+e.offset||a.top<0)&&n>1)){var s=this.cursors[r++]||this.addCursor(),l=s.style;this.drawCursor?this.drawCursor(s,a,e,t[n],this.session):this.isCursorInView(a,e)?(i.setStyle(l,"display","block"),i.translate(s,a.left,a.top),i.setStyle(l,"width",Math.round(e.characterWidth)+"px"),i.setStyle(l,"height",e.lineHeight+"px")):i.setStyle(l,"display","none")}}for(;this.cursors.length>r;)this.removeCursor();var c=this.session.getOverwrite();this.$setOverwrite(c),this.$pixelPos=a,this.restartTimer()},e.prototype.$setOverwrite=function(e){e!=this.overwrite&&(this.overwrite=e,e?i.addCssClass(this.element,"ace_overwrite-cursors"):i.removeCssClass(this.element,"ace_overwrite-cursors"))},e.prototype.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)},e}();r.prototype.$padding=0,r.prototype.drawCursor=null,t.Cursor=r})),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],(function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./lib/oop"),a=e("./lib/dom"),s=e("./lib/event"),l=e("./lib/event_emitter").EventEmitter,c=32768,d=function(){function e(e,t){this.element=a.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+t,this.inner=a.createElement("div"),this.inner.className="ace_scrollbar-inner",this.inner.textContent=" ",this.element.appendChild(this.inner),e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addListener(this.element,"scroll",this.onScroll.bind(this)),s.addListener(this.element,"mousedown",s.preventDefault)}return e.prototype.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1},e}();o.implement(d.prototype,l);var u=function(e){function t(t,n){var i=e.call(this,t,"-v")||this;return i.scrollTop=0,i.scrollHeight=0,n.$scrollbarWidth=i.width=a.scrollbarWidth(t.ownerDocument),i.inner.style.width=i.element.style.width=(i.width||15)+5+"px",i.$minWidth=0,i}return r(t,e),t.prototype.onScroll=function(){if(!this.skipEvent){if(this.scrollTop=this.element.scrollTop,1!=this.coeff){var e=this.element.clientHeight/this.scrollHeight;this.scrollTop=this.scrollTop*(1-e)/(this.coeff-e)}this._emit("scroll",{data:this.scrollTop})}this.skipEvent=!1},t.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},t.prototype.setHeight=function(e){this.element.style.height=e+"px"},t.prototype.setScrollHeight=function(e){this.scrollHeight=e,e>c?(this.coeff=c/e,e=c):1!=this.coeff&&(this.coeff=1),this.inner.style.height=e+"px"},t.prototype.setScrollTop=function(e){this.scrollTop!=e&&(this.skipEvent=!0,this.scrollTop=e,this.element.scrollTop=e*this.coeff)},t}(d);u.prototype.setInnerHeight=u.prototype.setScrollHeight;var h=function(e){function t(t,n){var i=e.call(this,t,"-h")||this;return i.scrollLeft=0,i.height=n.$scrollbarWidth,i.inner.style.height=i.element.style.height=(i.height||15)+5+"px",i}return r(t,e),t.prototype.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},t.prototype.getHeight=function(){return this.isVisible?this.height:0},t.prototype.setWidth=function(e){this.element.style.width=e+"px"},t.prototype.setInnerWidth=function(e){this.inner.style.width=e+"px"},t.prototype.setScrollWidth=function(e){this.inner.style.width=e+"px"},t.prototype.setScrollLeft=function(e){this.scrollLeft!=e&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=e)},t}(d);t.ScrollBar=u,t.ScrollBarV=u,t.ScrollBarH=h,t.VScrollBar=u,t.HScrollBar=h})),ace.define("ace/scrollbar_custom",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],(function(e,t,n){"use strict";var i,r=this&&this.__extends||(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=e("./lib/oop"),a=e("./lib/dom"),s=e("./lib/event"),l=e("./lib/event_emitter").EventEmitter;a.importCssString(".ace_editor>.ace_sb-v div, .ace_editor>.ace_sb-h div{\n position: absolute;\n background: rgba(128, 128, 128, 0.6);\n -moz-box-sizing: border-box;\n box-sizing: border-box;\n border: 1px solid #bbb;\n border-radius: 2px;\n z-index: 8;\n}\n.ace_editor>.ace_sb-v, .ace_editor>.ace_sb-h {\n position: absolute;\n z-index: 6;\n background: none;\n overflow: hidden!important;\n}\n.ace_editor>.ace_sb-v {\n z-index: 6;\n right: 0;\n top: 0;\n width: 12px;\n}\n.ace_editor>.ace_sb-v div {\n z-index: 8;\n right: 0;\n width: 100%;\n}\n.ace_editor>.ace_sb-h {\n bottom: 0;\n left: 0;\n height: 12px;\n}\n.ace_editor>.ace_sb-h div {\n bottom: 0;\n height: 100%;\n}\n.ace_editor>.ace_sb_grabbed {\n z-index: 8;\n background: #000;\n}","ace_scrollbar.css",!1);var c=function(){function e(e,t){this.element=a.createElement("div"),this.element.className="ace_sb"+t,this.inner=a.createElement("div"),this.inner.className="",this.element.appendChild(this.inner),this.VScrollWidth=12,this.HScrollHeight=12,e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addMultiMouseDownListener(this.element,[500,300,300],this,"onMouseDown")}return e.prototype.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e,this.coeff=1},e}();o.implement(c.prototype,l);var d=function(e){function t(t,n){var i=e.call(this,t,"-v")||this;return i.scrollTop=0,i.scrollHeight=0,i.parent=t,i.width=i.VScrollWidth,i.renderer=n,i.inner.style.width=i.element.style.width=(i.width||15)+"px",i.$minWidth=0,i}return r(t,e),t.prototype.onMouseDown=function(e,t){if("mousedown"===e&&0===s.getButton(t)&&2!==t.detail){if(t.target===this.inner){var n=this,i=t.clientY,r=t.clientY,o=this.thumbTop;s.capture(this.inner,(function(e){i=e.clientY}),(function(){clearInterval(a)}));var a=setInterval((function(){if(void 0!==i){var e=n.scrollTopFromThumbTop(o+i-r);e!==n.scrollTop&&n._emit("scroll",{data:e})}}),20);return s.preventDefault(t)}var l=t.clientY-this.element.getBoundingClientRect().top-this.thumbHeight/2;return this._emit("scroll",{data:this.scrollTopFromThumbTop(l)}),s.preventDefault(t)}},t.prototype.getHeight=function(){return this.height},t.prototype.scrollTopFromThumbTop=function(e){var t=e*(this.pageHeight-this.viewHeight)/(this.slideHeight-this.thumbHeight);return(t|=0)<0?t=0:t>this.pageHeight-this.viewHeight&&(t=this.pageHeight-this.viewHeight),t},t.prototype.getWidth=function(){return Math.max(this.isVisible?this.width:0,this.$minWidth||0)},t.prototype.setHeight=function(e){this.height=Math.max(0,e),this.slideHeight=this.height,this.viewHeight=this.height,this.setScrollHeight(this.pageHeight,!0)},t.prototype.setScrollHeight=function(e,t){(this.pageHeight!==e||t)&&(this.pageHeight=e,this.thumbHeight=this.slideHeight*this.viewHeight/this.pageHeight,this.thumbHeight>this.slideHeight&&(this.thumbHeight=this.slideHeight),this.thumbHeight<15&&(this.thumbHeight=15),this.inner.style.height=this.thumbHeight+"px",this.scrollTop>this.pageHeight-this.viewHeight&&(this.scrollTop=this.pageHeight-this.viewHeight,this.scrollTop<0&&(this.scrollTop=0),this._emit("scroll",{data:this.scrollTop})))},t.prototype.setScrollTop=function(e){this.scrollTop=e,e<0&&(e=0),this.thumbTop=e*(this.slideHeight-this.thumbHeight)/(this.pageHeight-this.viewHeight),this.inner.style.top=this.thumbTop+"px"},t}(c);d.prototype.setInnerHeight=d.prototype.setScrollHeight;var u=function(e){function t(t,n){var i=e.call(this,t,"-h")||this;return i.scrollLeft=0,i.scrollWidth=0,i.height=i.HScrollHeight,i.inner.style.height=i.element.style.height=(i.height||12)+"px",i.renderer=n,i}return r(t,e),t.prototype.onMouseDown=function(e,t){if("mousedown"===e&&0===s.getButton(t)&&2!==t.detail){if(t.target===this.inner){var n=this,i=t.clientX,r=t.clientX,o=this.thumbLeft;s.capture(this.inner,(function(e){i=e.clientX}),(function(){clearInterval(a)}));var a=setInterval((function(){if(void 0!==i){var e=n.scrollLeftFromThumbLeft(o+i-r);e!==n.scrollLeft&&n._emit("scroll",{data:e})}}),20);return s.preventDefault(t)}var l=t.clientX-this.element.getBoundingClientRect().left-this.thumbWidth/2;return this._emit("scroll",{data:this.scrollLeftFromThumbLeft(l)}),s.preventDefault(t)}},t.prototype.getHeight=function(){return this.isVisible?this.height:0},t.prototype.scrollLeftFromThumbLeft=function(e){var t=e*(this.pageWidth-this.viewWidth)/(this.slideWidth-this.thumbWidth);return(t|=0)<0?t=0:t>this.pageWidth-this.viewWidth&&(t=this.pageWidth-this.viewWidth),t},t.prototype.setWidth=function(e){this.width=Math.max(0,e),this.element.style.width=this.width+"px",this.slideWidth=this.width,this.viewWidth=this.width,this.setScrollWidth(this.pageWidth,!0)},t.prototype.setScrollWidth=function(e,t){(this.pageWidth!==e||t)&&(this.pageWidth=e,this.thumbWidth=this.slideWidth*this.viewWidth/this.pageWidth,this.thumbWidth>this.slideWidth&&(this.thumbWidth=this.slideWidth),this.thumbWidth<15&&(this.thumbWidth=15),this.inner.style.width=this.thumbWidth+"px",this.scrollLeft>this.pageWidth-this.viewWidth&&(this.scrollLeft=this.pageWidth-this.viewWidth,this.scrollLeft<0&&(this.scrollLeft=0),this._emit("scroll",{data:this.scrollLeft})))},t.prototype.setScrollLeft=function(e){this.scrollLeft=e,e<0&&(e=0),this.thumbLeft=e*(this.slideWidth-this.thumbWidth)/(this.pageWidth-this.viewWidth),this.inner.style.left=this.thumbLeft+"px"},t}(c);u.prototype.setInnerWidth=u.prototype.setScrollWidth,t.ScrollBar=d,t.ScrollBarV=d,t.ScrollBarH=u,t.VScrollBar=d,t.HScrollBar=u})),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],(function(e,t,n){"use strict";var i=e("./lib/event"),r=function(){function e(e,t){this.onRender=e,this.pending=!1,this.changes=0,this.$recursionLimit=2,this.window=t||window;var n=this;this._flush=function(e){n.pending=!1;var t=n.changes;if(t&&(i.blockIdle(100),n.changes=0,n.onRender(t)),n.changes){if(n.$recursionLimit--<0)return;n.schedule()}else n.$recursionLimit=2}}return e.prototype.schedule=function(e){this.changes=this.changes|e,this.changes&&!this.pending&&(i.nextFrame(this._flush),this.pending=!0)},e.prototype.clear=function(e){var t=this.changes;return this.changes=0,t},e}();t.RenderLoop=r})),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/lib/useragent","ace/lib/event_emitter"],(function(e,t,n){var i=e("../lib/oop"),r=e("../lib/dom"),o=e("../lib/lang"),a=e("../lib/event"),s=e("../lib/useragent"),l=e("../lib/event_emitter").EventEmitter,c=512,d="function"==typeof ResizeObserver,u=200,h=function(){function e(e){this.el=r.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=r.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=r.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),e.appendChild(this.el),this.$measureNode.textContent=o.stringRepeat("X",c),this.$characterSize={width:0,height:0},d?this.$addObserver():this.checkForSizeChanges()}return e.prototype.$setMeasureNodeStyles=function(e,t){e.width=e.height="auto",e.left=e.top="0px",e.visibility="hidden",e.position="absolute",e.whiteSpace="pre",s.isIE<8?e["font-family"]="inherit":e.font="inherit",e.overflow=t?"hidden":"visible"},e.prototype.checkForSizeChanges=function(e){if(void 0===e&&(e=this.$measureSizes()),e&&(this.$characterSize.width!==e.width||this.$characterSize.height!==e.height)){this.$measureNode.style.fontWeight="bold";var t=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=e,this.charSizes=Object.create(null),this.allowBoldFonts=t&&t.width===e.width&&t.height===e.height,this._emit("changeCharacterSize",{data:e})}},e.prototype.$addObserver=function(){var e=this;this.$observer=new window.ResizeObserver((function(t){e.checkForSizeChanges()})),this.$observer.observe(this.$measureNode)},e.prototype.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer||this.$observer)return this.$pollSizeChangesTimer;var e=this;return this.$pollSizeChangesTimer=a.onIdle((function t(){e.checkForSizeChanges(),a.onIdle(t,500)}),500)},e.prototype.setPolling=function(e){e?this.$pollSizeChanges():this.$pollSizeChangesTimer&&(clearInterval(this.$pollSizeChangesTimer),this.$pollSizeChangesTimer=0)},e.prototype.$measureSizes=function(e){var t={height:(e||this.$measureNode).clientHeight,width:(e||this.$measureNode).clientWidth/c};return 0===t.width||0===t.height?null:t},e.prototype.$measureCharWidth=function(e){return this.$main.textContent=o.stringRepeat(e,c),this.$main.getBoundingClientRect().width/c},e.prototype.getCharacterWidth=function(e){var t=this.charSizes[e];return void 0===t&&(t=this.charSizes[e]=this.$measureCharWidth(e)/this.$characterSize.width),t},e.prototype.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$observer&&this.$observer.disconnect(),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)},e.prototype.$getZoom=function(e){return e&&e.parentElement?(Number(window.getComputedStyle(e).zoom)||1)*this.$getZoom(e.parentElement):1},e.prototype.$initTransformMeasureNodes=function(){var e=function(e,t){return["div",{style:"position: absolute;top:"+e+"px;left:"+t+"px;"}]};this.els=r.buildDom([e(0,0),e(u,0),e(0,u),e(u,u)],this.el)},e.prototype.transformCoordinates=function(e,t){function n(e,t,n){var i=e[1]*t[0]-e[0]*t[1];return[(-t[1]*n[0]+t[0]*n[1])/i,(+e[1]*n[0]-e[0]*n[1])/i]}function i(e,t){return[e[0]-t[0],e[1]-t[1]]}function r(e,t){return[e[0]+t[0],e[1]+t[1]]}function o(e,t){return[e*t[0],e*t[1]]}function a(e){var t=e.getBoundingClientRect();return[t.left,t.top]}e&&(e=o(1/this.$getZoom(this.el),e)),this.els||this.$initTransformMeasureNodes();var s=a(this.els[0]),l=a(this.els[1]),c=a(this.els[2]),d=a(this.els[3]),h=n(i(d,l),i(d,c),i(r(l,c),r(d,s))),p=o(1+h[0],i(l,s)),g=o(1+h[1],i(c,s));if(t){var f=t,m=h[0]*f[0]/u+h[1]*f[1]/u+1,y=r(o(f[0],p),o(f[1],g));return r(o(1/m/u,y),s)}var v=i(e,s),b=n(i(p,o(h[0],v)),i(g,o(h[1],v)),v);return o(u,b)},e}();h.prototype.$characterSize={width:0,height:0},i.implement(h.prototype,l),t.FontMetrics=h})),ace.define("ace/css/editor-css",["require","exports","module"],(function(e,t,n){n.exports='\n.ace_br1 {border-top-left-radius : 3px;}\n.ace_br2 {border-top-right-radius : 3px;}\n.ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}\n.ace_br4 {border-bottom-right-radius: 3px;}\n.ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}\n.ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}\n.ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}\n.ace_br8 {border-bottom-left-radius : 3px;}\n.ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}\n.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}\n.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\n\n\n.ace_editor {\n position: relative;\n overflow: hidden;\n padding: 0;\n font: 12px/normal \'Monaco\', \'Menlo\', \'Ubuntu Mono\', \'Consolas\', \'Source Code Pro\', \'source-code-pro\', monospace;\n direction: ltr;\n text-align: left;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n forced-color-adjust: none;\n}\n\n.ace_scroller {\n position: absolute;\n overflow: hidden;\n top: 0;\n bottom: 0;\n background-color: inherit;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n cursor: text;\n}\n\n.ace_content {\n position: absolute;\n box-sizing: border-box;\n min-width: 100%;\n contain: style size layout;\n font-variant-ligatures: no-common-ligatures;\n}\n.ace_invisible {\n font-variant-ligatures: none;\n}\n\n.ace_keyboard-focus:focus {\n box-shadow: inset 0 0 0 2px #5E9ED6;\n outline: none;\n}\n\n.ace_dragging .ace_scroller:before{\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n content: \'\';\n background: rgba(250, 250, 250, 0.01);\n z-index: 1000;\n}\n.ace_dragging.ace_dark .ace_scroller:before{\n background: rgba(0, 0, 0, 0.01);\n}\n\n.ace_gutter {\n position: absolute;\n overflow : hidden;\n width: auto;\n top: 0;\n bottom: 0;\n left: 0;\n cursor: default;\n z-index: 4;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n contain: style size layout;\n}\n\n.ace_gutter-active-line {\n position: absolute;\n left: 0;\n right: 0;\n}\n\n.ace_scroller.ace_scroll-left:after {\n content: "";\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;\n pointer-events: none;\n}\n\n.ace_gutter-cell, .ace_gutter-cell_svg-icons {\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n padding-left: 19px;\n padding-right: 6px;\n background-repeat: no-repeat;\n}\n\n.ace_gutter-cell_svg-icons .ace_gutter_annotation {\n margin-left: -14px;\n float: left;\n}\n\n.ace_gutter-cell .ace_gutter_annotation {\n margin-left: -19px;\n float: left;\n}\n\n.ace_gutter-cell.ace_error, .ace_icon.ace_error, .ace_icon.ace_error_fold, .ace_gutter-cell.ace_security, .ace_icon.ace_security, .ace_icon.ace_security_fold {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");\n background-repeat: no-repeat;\n background-position: 2px center;\n}\n\n.ace_gutter-cell.ace_warning, .ace_icon.ace_warning, .ace_icon.ace_warning_fold {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");\n background-repeat: no-repeat;\n background-position: 2px center;\n}\n\n.ace_gutter-cell.ace_info, .ace_icon.ace_info, .ace_gutter-cell.ace_hint, .ace_icon.ace_hint {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");\n background-repeat: no-repeat;\n background-position: 2px center;\n}\n\n.ace_dark .ace_gutter-cell.ace_info, .ace_dark .ace_icon.ace_info, .ace_dark .ace_gutter-cell.ace_hint, .ace_dark .ace_icon.ace_hint {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");\n}\n\n.ace_icon_svg.ace_error {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJyZWQiIHNoYXBlLXJlbmRlcmluZz0iZ2VvbWV0cmljUHJlY2lzaW9uIj4KPGNpcmNsZSBmaWxsPSJub25lIiBjeD0iOCIgY3k9IjgiIHI9IjciIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPGxpbmUgeDE9IjExIiB5MT0iNSIgeDI9IjUiIHkyPSIxMSIvPgo8bGluZSB4MT0iMTEiIHkxPSIxMSIgeDI9IjUiIHkyPSI1Ii8+CjwvZz4KPC9zdmc+");\n background-color: crimson;\n}\n.ace_icon_svg.ace_security {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0iZGFya29yYW5nZSIgZmlsbD0ibm9uZSIgc2hhcGUtcmVuZGVyaW5nPSJnZW9tZXRyaWNQcmVjaXNpb24iPgogICAgICAgIDxwYXRoIGNsYXNzPSJzdHJva2UtbGluZWpvaW4tcm91bmQiIGQ9Ik04IDE0LjgzMDdDOCAxNC44MzA3IDIgMTIuOTA0NyAyIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOEM3Ljk4OTk5IDEuMzQ5MTggMTAuNjkgMy4yNjU0OCAxNCAzLjI2NTQ4VjguMDg5OTJDMTQgMTIuOTA0NyA4IDE0LjgzMDcgOCAxNC44MzA3WiIvPgogICAgICAgIDxwYXRoIGQ9Ik0yIDguMDg5OTJWMy4yNjU0OEM1LjMxIDMuMjY1NDggNy45ODk5OSAxLjM0OTE4IDcuOTg5OTkgMS4zNDkxOCIvPgogICAgICAgIDxwYXRoIGQ9Ik0xMy45OSA4LjA4OTkyVjMuMjY1NDhDMTAuNjggMy4yNjU0OCA4IDEuMzQ5MTggOCAxLjM0OTE4Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggNFY5Ii8+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTggMTBWMTIiLz4KICAgIDwvZz4KPC9zdmc+");\n background-color: crimson;\n}\n.ace_icon_svg.ace_warning {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJkYXJrb3JhbmdlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+Cjxwb2x5Z29uIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGZpbGw9Im5vbmUiIHBvaW50cz0iOCAxIDE1IDE1IDEgMTUgOCAxIi8+CjxyZWN0IHg9IjgiIHk9IjEyIiB3aWR0aD0iMC4wMSIgaGVpZ2h0PSIwLjAxIi8+CjxsaW5lIHgxPSI4IiB5MT0iNiIgeDI9IjgiIHkyPSIxMCIvPgo8L2c+Cjwvc3ZnPg==");\n background-color: darkorange;\n}\n.ace_icon_svg.ace_info {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiI+CjxnIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJibHVlIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CjxjaXJjbGUgZmlsbD0ibm9uZSIgY3g9IjgiIGN5PSI4IiByPSI3IiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+Cjxwb2x5bGluZSBwb2ludHM9IjggMTEgOCA4Ii8+Cjxwb2x5bGluZSBwb2ludHM9IjkgOCA2IDgiLz4KPGxpbmUgeDE9IjEwIiB5MT0iMTEiIHgyPSI2IiB5Mj0iMTEiLz4KPHJlY3QgeD0iOCIgeT0iNSIgd2lkdGg9IjAuMDEiIGhlaWdodD0iMC4wMSIvPgo8L2c+Cjwvc3ZnPg==");\n background-color: royalblue;\n}\n.ace_icon_svg.ace_hint {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjAgMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CiAgICA8ZyBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZT0ic2lsdmVyIiBmaWxsPSJub25lIiBzaGFwZS1yZW5kZXJpbmc9Imdlb21ldHJpY1ByZWNpc2lvbiI+CiAgICAgICAgPHBhdGggY2xhc3M9InN0cm9rZS1saW5lam9pbi1yb3VuZCIgZD0iTTYgMTRIMTAiLz4KICAgICAgICA8cGF0aCBkPSJNOCAxMUg5QzkgOS40NzAwMiAxMiA4LjU0MDAyIDEyIDUuNzYwMDJDMTIuMDIgNC40MDAwMiAxMS4zOSAzLjM2MDAyIDEwLjQzIDIuNjcwMDJDOSAxLjY0MDAyIDcuMDAwMDEgMS42NDAwMiA1LjU3MDAxIDIuNjcwMDJDNC42MTAwMSAzLjM2MDAyIDMuOTggNC40MDAwMiA0IDUuNzYwMDJDNCA4LjU0MDAyIDcuMDAwMDEgOS40NzAwMiA3LjAwMDAxIDExSDhaIi8+CiAgICA8L2c+Cjwvc3ZnPg==");\n background-color: silver;\n}\n\n.ace_icon_svg.ace_error_fold {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSI+CiAgPHBhdGggZD0ibSAxOC45Mjk4NTEsNy44Mjk4MDc2IGMgMC4xNDYzNTMsNi4zMzc0NjA0IC02LjMyMzE0Nyw3Ljc3Nzg0NDQgLTcuNDc3OTEyLDcuNzc3ODQ0NCAtMi4xMDcyNzI2LC0wLjEyODc1IDUuMTE3Njc4LDAuMzU2MjQ5IDUuMDUxNjk4LC03Ljg3MDA2MTggLTAuNjA0NjcyLC04LjAwMzk3MzQ5IC03LjA3NzI3MDYsLTcuNTYzMTE4OSAtNC44NTczLC03LjQzMDM5NTU2IDEuNjA2LC0wLjExNTE0MjI1IDYuODk3NDg1LDEuMjYyNTQ1OTYgNy4yODM1MTQsNy41MjI2MTI5NiB6IiBmaWxsPSJjcmltc29uIiBzdHJva2Utd2lkdGg9IjIiLz4KICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0ibSA4LjExNDc1NjIsMi4wNTI5ODI4IGMgMy4zNDkxNjk4LDAgNi4wNjQxMzI4LDIuNjc2ODYyNyA2LjA2NDEzMjgsNS45Nzg5NTMgMCwzLjMwMjExMjIgLTIuNzE0OTYzLDUuOTc4OTIwMiAtNi4wNjQxMzI4LDUuOTc4OTIwMiAtMy4zNDkxNDczLDAgLTYuMDY0MTc3MiwtMi42NzY4MDggLTYuMDY0MTc3MiwtNS45Nzg5MjAyIDAuMDA1MzksLTMuMjk5ODg2MSAyLjcxNzI2NTYsLTUuOTczNjQwOCA2LjA2NDE3NzIsLTUuOTc4OTUzIHogbSAwLC0xLjczNTgyNzE5IGMgLTQuMzIxNDgzNiwwIC03LjgyNDc0MDM4LDMuNDU0MDE4NDkgLTcuODI0NzQwMzgsNy43MTQ3ODAxOSAwLDQuMjYwNzI4MiAzLjUwMzI1Njc4LDcuNzE0NzQ1MiA3LjgyNDc0MDM4LDcuNzE0NzQ1MiA0LjMyMTQ0OTgsMCA3LjgyNDY5OTgsLTMuNDU0MDE3IDcuODI0Njk5OCwtNy43MTQ3NDUyIDAsLTIuMDQ2MDkxNCAtMC44MjQzOTIsLTQuMDA4MzY3MiAtMi4yOTE3NTYsLTUuNDU1MTc0NiBDIDEyLjE4MDIyNSwxLjEyOTk2NDggMTAuMTkwMDEzLDAuMzE3MTU1NjEgOC4xMTQ3NTYyLDAuMzE3MTU1NjEgWiBNIDYuOTM3NDU2Myw4LjI0MDU5ODUgNC42NzE4Njg1LDEwLjQ4NTg1MiA2LjAwODY4MTQsMTEuODc2NzI4IDguMzE3MDAzNSw5LjYwMDc5MTEgMTAuNjI1MzM3LDExLjg3NjcyOCAxMS45NjIxMzgsMTAuNDg1ODUyIDkuNjk2NTUwOCw4LjI0MDU5ODUgMTEuOTYyMTM4LDYuMDA2ODA2NiAxMC41NzMyNDYsNC42Mzc0MzM1IDguMzE3MDAzNSw2Ljg3MzQyOTcgNi4wNjA3NjA3LDQuNjM3NDMzNSA0LjY3MTg2ODUsNi4wMDY4MDY2IFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");\n background-color: crimson;\n}\n.ace_icon_svg.ace_security_fold {\n -webkit-mask-image: url("data:image/svg+xml;base64,CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB2aWV3Qm94PSIwIDAgMTcgMTQiIGZpbGw9Im5vbmUiPgogICAgPHBhdGggZD0iTTEwLjAwMDEgMTMuNjk5MkMxMC4wMDAxIDEzLjY5OTIgMTEuOTI0MSAxMy40NzYzIDEzIDEyLjY5OTJDMTQuNDEzOSAxMS42NzgxIDE2IDEwLjUgMTYuMTI1MSA2LjgxMTI2VjIuNTg5ODdDMTYuMTI1MSAyLjU0NzY4IDE2LjEyMjEgMi41MDYxOSAxNi4xMTY0IDIuNDY1NTlWMS43MTQ4NUgxNS4yNDE0TDE1LjIzMDcgMS43MTQ4NEwxNC42MjUxIDEuNjk5MjJWNi44MTEyM0MxNC42MjUxIDguNTEwNjEgMTQuNjI1MSA5LjQ2NDYxIDEyLjc4MjQgMTEuNzIxQzEyLjE1ODYgMTIuNDg0OCAxMC4wMDAxIDEzLjY5OTIgMTAuMDAwMSAxMy42OTkyWiIgZmlsbD0iY3JpbXNvbiIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgICA8cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTcuMzM2MDkgMC4zNjc0NzVDNy4wMzIxNCAwLjE1MjY1MiA2LjYyNTQ4IDAuMTUzNjE0IDYuMzIyNTMgMC4zNjk5OTdMNi4zMDg2OSAwLjM3OTU1NEM2LjI5NTUzIDAuMzg4NTg4IDYuMjczODggMC40MDMyNjYgNi4yNDQxNyAwLjQyMjc4OUM2LjE4NDcxIDAuNDYxODYgNi4wOTMyMSAwLjUyMDE3MSA1Ljk3MzEzIDAuNTkxMzczQzUuNzMyNTEgMC43MzQwNTkgNS4zNzk5IDAuOTI2ODY0IDQuOTQyNzkgMS4xMjAwOUM0LjA2MTQ0IDEuNTA5NyAyLjg3NTQxIDEuODgzNzcgMS41ODk4NCAxLjg4Mzc3SDAuNzE0ODQ0VjIuNzU4NzdWNi45ODAxNUMwLjcxNDg0NCA5LjQ5Mzc0IDIuMjg4NjYgMTEuMTk3MyAzLjcwMjU0IDEyLjIxODVDNC40MTg0NSAxMi43MzU1IDUuMTI4NzQgMTMuMTA1MyA1LjY1NzMzIDEzLjM0NTdDNS45MjI4NCAxMy40NjY0IDYuMTQ1NjYgMTMuNTU1OSA2LjMwNDY1IDEzLjYxNjFDNi4zODQyMyAxMy42NDYyIDYuNDQ4MDUgMTMuNjY5IDYuNDkzNDkgMTMuNjg0OEM2LjUxNjIyIDEzLjY5MjcgNi41MzQzOCAxMy42OTg5IDYuNTQ3NjQgMTMuNzAzM0w2LjU2MzgyIDEzLjcwODdMNi41NjkwOCAxMy43MTA0TDYuNTcwOTkgMTMuNzExTDYuODM5ODQgMTMuNzUzM0w2LjU3MjQyIDEzLjcxMTVDNi43NDYzMyAxMy43NjczIDYuOTMzMzUgMTMuNzY3MyA3LjEwNzI3IDEzLjcxMTVMNy4xMDg3IDEzLjcxMUw3LjExMDYxIDEzLjcxMDRMNy4xMTU4NyAxMy43MDg3TDcuMTMyMDUgMTMuNzAzM0M3LjE0NTMxIDEzLjY5ODkgNy4xNjM0NiAxMy42OTI3IDcuMTg2MTkgMTMuNjg0OEM3LjIzMTY0IDEzLjY2OSA3LjI5NTQ2IDEzLjY0NjIgNy4zNzUwMyAxMy42MTYxQzcuNTM0MDMgMTMuNTU1OSA3Ljc1Njg1IDEzLjQ2NjQgOC4wMjIzNiAxMy4zNDU3QzguNTUwOTUgMTMuMTA1MyA5LjI2MTIzIDEyLjczNTUgOS45NzcxNSAxMi4yMTg1QzExLjM5MSAxMS4xOTczIDEyLjk2NDggOS40OTM3NyAxMi45NjQ4IDYuOTgwMThWMi43NTg4QzEyLjk2NDggMi43MTY2IDEyLjk2MTkgMi42NzUxMSAxMi45NTYxIDIuNjM0NTFWMS44ODM3N0gxMi4wODExQzEyLjA3NzUgMS44ODM3NyAxMi4wNzQgMS44ODM3NyAxMi4wNzA0IDEuODgzNzdDMTAuNzk3OSAxLjg4MDA0IDkuNjE5NjIgMS41MTEwMiA4LjczODk0IDEuMTI0ODZDOC43MzUzNCAxLjEyMzI3IDguNzMxNzQgMS4xMjE2OCA4LjcyODE0IDEuMTIwMDlDOC4yOTEwMyAwLjkyNjg2NCA3LjkzODQyIDAuNzM0MDU5IDcuNjk3NzkgMC41OTEzNzNDNy41Nzc3MiAwLjUyMDE3MSA3LjQ4NjIyIDAuNDYxODYgNy40MjY3NiAwLjQyMjc4OUM3LjM5NzA1IDAuNDAzMjY2IDcuMzc1MzkgMC4zODg1ODggNy4zNjIyNCAwLjM3OTU1NEw3LjM0ODk2IDAuMzcwMzVDNy4zNDg5NiAwLjM3MDM1IDcuMzQ4NDcgMC4zNzAwMiA3LjM0NTYzIDAuMzc0MDU0TDcuMzM3NzkgMC4zNjg2NTlMNy4zMzYwOSAwLjM2NzQ3NVpNOC4wMzQ3MSAyLjcyNjkxQzguODYwNCAzLjA5MDYzIDkuOTYwNjYgMy40NjMwOSAxMS4yMDYxIDMuNTg5MDdWNi45ODAxNUgxMS4yMTQ4QzExLjIxNDggOC42Nzk1MyAxMC4xNjM3IDkuOTI1MDcgOC45NTI1NCAxMC43OTk4QzguMzU1OTUgMTEuMjMwNiA3Ljc1Mzc0IDExLjU0NTQgNy4yOTc5NiAxMS43NTI3QzcuMTE2NzEgMTEuODM1MSA2Ljk2MDYyIDExLjg5OTYgNi44Mzk4NCAxMS45NDY5QzYuNzE5MDYgMTEuODk5NiA2LjU2Mjk3IDExLjgzNTEgNi4zODE3MyAxMS43NTI3QzUuOTI1OTUgMTEuNTQ1NCA1LjMyMzczIDExLjIzMDYgNC43MjcxNSAxMC43OTk4QzMuNTE2MDMgOS45MjUwNyAyLjQ2NDg0IDguNjc5NTUgMi40NjQ4NCA2Ljk4MDE4VjMuNTg5MDlDMy43MTczOCAzLjQ2MjM5IDQuODIzMDggMy4wODYzOSA1LjY1MDMzIDIuNzIwNzFDNi4xNDIyOCAyLjUwMzI0IDYuNTQ0ODUgMi4yODUzNyA2LjgzMjU0IDIuMTE2MjRDNy4xMjE4MSAyLjI4NTM1IDcuNTI3IDIuNTAzNTIgOC4wMjE5NiAyLjcyMTMxQzguMDI2MiAyLjcyMzE3IDguMDMwNDUgMi43MjUwNCA4LjAzNDcxIDIuNzI2OTFaTTUuOTY0ODQgMy40MDE0N1Y3Ljc3NjQ3SDcuNzE0ODRWMy40MDE0N0g1Ljk2NDg0Wk01Ljk2NDg0IDEwLjQwMTVWOC42NTE0N0g3LjcxNDg0VjEwLjQwMTVINS45NjQ4NFoiIGZpbGw9ImNyaW1zb24iIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");\n background-color: crimson;\n}\n.ace_icon_svg.ace_warning_fold {\n -webkit-mask-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAyMCAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xNC43NzY5IDE0LjczMzdMOC42NTE5MiAyLjQ4MzY5QzguMzI5NDYgMS44Mzg3NyA3LjQwOTEzIDEuODM4NzcgNy4wODY2NyAyLjQ4MzY5TDAuOTYxNjY5IDE0LjczMzdDMC42NzA3NzUgMTUuMzE1NSAxLjA5MzgzIDE2IDEuNzQ0MjkgMTZIMTMuOTk0M0MxNC42NDQ4IDE2IDE1LjA2NzggMTUuMzE1NSAxNC43NzY5IDE0LjczMzdaTTMuMTYwMDcgMTQuMjVMNy44NjkyOSA0LjgzMTU2TDEyLjU3ODUgMTQuMjVIMy4xNjAwN1pNOC43NDQyOSAxMS42MjVWMTMuMzc1SDYuOTk0MjlWMTEuNjI1SDguNzQ0MjlaTTYuOTk0MjkgMTAuNzVWNy4yNUg4Ljc0NDI5VjEwLjc1SDYuOTk0MjlaIiBmaWxsPSIjRUM3MjExIi8+CjxwYXRoIGQ9Ik0xMS4xOTkxIDIuOTUyMzhDMTAuODgwOSAyLjMxNDY3IDEwLjM1MzcgMS44MDUyNiA5LjcwNTUgMS41MDlMMTEuMDQxIDEuMDY5NzhDMTEuNjg4MyAwLjk0OTgxNCAxMi4zMzcgMS4yNzI2MyAxMi42MzE3IDEuODYxNDFMMTcuNjEzNiAxMS44MTYxQzE4LjM1MjcgMTMuMjkyOSAxNy41OTM4IDE1LjA4MDQgMTYuMDE4IDE1LjU3NDVDMTYuNDA0NCAxNC40NTA3IDE2LjMyMzEgMTMuMjE4OCAxNS43OTI0IDEyLjE1NTVMMTEuMTk5MSAyLjk1MjM4WiIgZmlsbD0iI0VDNzIxMSIvPgo8L3N2Zz4=");\n background-color: darkorange;\n}\n\n.ace_scrollbar {\n contain: strict;\n position: absolute;\n right: 0;\n bottom: 0;\n z-index: 6;\n}\n\n.ace_scrollbar-inner {\n position: absolute;\n cursor: text;\n left: 0;\n top: 0;\n}\n\n.ace_scrollbar-v{\n overflow-x: hidden;\n overflow-y: scroll;\n top: 0;\n}\n\n.ace_scrollbar-h {\n overflow-x: scroll;\n overflow-y: hidden;\n left: 0;\n}\n\n.ace_print-margin {\n position: absolute;\n height: 100%;\n}\n\n.ace_text-input {\n position: absolute;\n z-index: 0;\n width: 0.5em;\n height: 1em;\n opacity: 0;\n background: transparent;\n -moz-appearance: none;\n appearance: none;\n border: none;\n resize: none;\n outline: none;\n overflow: hidden;\n font: inherit;\n padding: 0 1px;\n margin: 0 -1px;\n contain: strict;\n -ms-user-select: text;\n -moz-user-select: text;\n -webkit-user-select: text;\n user-select: text;\n /*with `pre-line` chrome inserts instead of space*/\n white-space: pre!important;\n}\n.ace_text-input.ace_composition {\n background: transparent;\n color: inherit;\n z-index: 1000;\n opacity: 1;\n}\n.ace_composition_placeholder { color: transparent }\n.ace_composition_marker { \n border-bottom: 1px solid;\n position: absolute;\n border-radius: 0;\n margin-top: 1px;\n}\n\n[ace_nocontext=true] {\n transform: none!important;\n filter: none!important;\n clip-path: none!important;\n mask : none!important;\n contain: none!important;\n perspective: none!important;\n mix-blend-mode: initial!important;\n z-index: auto;\n}\n\n.ace_layer {\n z-index: 1;\n position: absolute;\n overflow: hidden;\n /* workaround for chrome bug https://github.com/ajaxorg/ace/issues/2312*/\n word-wrap: normal;\n white-space: pre;\n height: 100%;\n width: 100%;\n box-sizing: border-box;\n /* setting pointer-events: auto; on node under the mouse, which changes\n during scroll, will break mouse wheel scrolling in Safari */\n pointer-events: none;\n}\n\n.ace_gutter-layer {\n position: relative;\n width: auto;\n text-align: right;\n pointer-events: auto;\n height: 1000000px;\n contain: style size layout;\n}\n\n.ace_text-layer {\n font: inherit !important;\n position: absolute;\n height: 1000000px;\n width: 1000000px;\n contain: style size layout;\n}\n\n.ace_text-layer > .ace_line, .ace_text-layer > .ace_line_group {\n contain: style size layout;\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n}\n\n.ace_hidpi .ace_text-layer,\n.ace_hidpi .ace_gutter-layer,\n.ace_hidpi .ace_content,\n.ace_hidpi .ace_gutter {\n contain: strict;\n}\n.ace_hidpi .ace_text-layer > .ace_line, \n.ace_hidpi .ace_text-layer > .ace_line_group {\n contain: strict;\n}\n\n.ace_cjk {\n display: inline-block;\n text-align: center;\n}\n\n.ace_cursor-layer {\n z-index: 4;\n}\n\n.ace_cursor {\n z-index: 4;\n position: absolute;\n box-sizing: border-box;\n border-left: 2px solid;\n /* workaround for smooth cursor repaintng whole screen in chrome */\n transform: translatez(0);\n}\n\n.ace_multiselect .ace_cursor {\n border-left-width: 1px;\n}\n\n.ace_slim-cursors .ace_cursor {\n border-left-width: 1px;\n}\n\n.ace_overwrite-cursors .ace_cursor {\n border-left-width: 0;\n border-bottom: 1px solid;\n}\n\n.ace_hidden-cursors .ace_cursor {\n opacity: 0.2;\n}\n\n.ace_hasPlaceholder .ace_hidden-cursors .ace_cursor {\n opacity: 0;\n}\n\n.ace_smooth-blinking .ace_cursor {\n transition: opacity 0.18s;\n}\n\n.ace_animate-blinking .ace_cursor {\n animation-duration: 1000ms;\n animation-timing-function: step-end;\n animation-name: blink-ace-animate;\n animation-iteration-count: infinite;\n}\n\n.ace_animate-blinking.ace_smooth-blinking .ace_cursor {\n animation-duration: 1000ms;\n animation-timing-function: ease-in-out;\n animation-name: blink-ace-animate-smooth;\n}\n \n@keyframes blink-ace-animate {\n from, to { opacity: 1; }\n 60% { opacity: 0; }\n}\n\n@keyframes blink-ace-animate-smooth {\n from, to { opacity: 1; }\n 45% { opacity: 1; }\n 60% { opacity: 0; }\n 85% { opacity: 0; }\n}\n\n.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {\n position: absolute;\n z-index: 3;\n}\n\n.ace_marker-layer .ace_selection {\n position: absolute;\n z-index: 5;\n}\n\n.ace_marker-layer .ace_bracket {\n position: absolute;\n z-index: 6;\n}\n\n.ace_marker-layer .ace_error_bracket {\n position: absolute;\n border-bottom: 1px solid #DE5555;\n border-radius: 0;\n}\n\n.ace_marker-layer .ace_active-line {\n position: absolute;\n z-index: 2;\n}\n\n.ace_marker-layer .ace_selected-word {\n position: absolute;\n z-index: 4;\n box-sizing: border-box;\n}\n\n.ace_line .ace_fold {\n box-sizing: border-box;\n\n display: inline-block;\n height: 11px;\n margin-top: -2px;\n vertical-align: middle;\n\n background-image:\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");\n background-repeat: no-repeat, repeat-x;\n background-position: center center, top left;\n color: transparent;\n\n border: 1px solid black;\n border-radius: 2px;\n\n cursor: pointer;\n pointer-events: auto;\n}\n\n.ace_dark .ace_fold {\n}\n\n.ace_fold:hover{\n background-image:\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");\n}\n\n.ace_tooltip {\n background-color: #f5f5f5;\n border: 1px solid gray;\n border-radius: 1px;\n box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);\n color: black;\n padding: 3px 4px;\n position: fixed;\n z-index: 999999;\n box-sizing: border-box;\n cursor: default;\n white-space: pre-wrap;\n word-wrap: break-word;\n line-height: normal;\n font-style: normal;\n font-weight: normal;\n letter-spacing: normal;\n pointer-events: none;\n overflow: auto;\n max-width: min(33em, 66vw);\n overscroll-behavior: contain;\n}\n.ace_tooltip pre {\n white-space: pre-wrap;\n}\n\n.ace_tooltip.ace_dark {\n background-color: #636363;\n color: #fff;\n}\n\n.ace_tooltip:focus {\n outline: 1px solid #5E9ED6;\n}\n\n.ace_icon {\n display: inline-block;\n width: 18px;\n vertical-align: top;\n}\n\n.ace_icon_svg {\n display: inline-block;\n width: 12px;\n vertical-align: top;\n -webkit-mask-repeat: no-repeat;\n -webkit-mask-size: 12px;\n -webkit-mask-position: center;\n}\n\n.ace_folding-enabled > .ace_gutter-cell, .ace_folding-enabled > .ace_gutter-cell_svg-icons {\n padding-right: 13px;\n}\n\n.ace_fold-widget {\n box-sizing: border-box;\n\n margin: 0 -12px 0 1px;\n display: none;\n width: 11px;\n vertical-align: top;\n\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");\n background-repeat: no-repeat;\n background-position: center;\n\n border-radius: 3px;\n \n border: 1px solid transparent;\n cursor: pointer;\n}\n\n.ace_folding-enabled .ace_fold-widget {\n display: inline-block; \n}\n\n.ace_fold-widget.ace_end {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");\n}\n\n.ace_fold-widget.ace_closed {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");\n}\n\n.ace_fold-widget:hover {\n border: 1px solid rgba(0, 0, 0, 0.3);\n background-color: rgba(255, 255, 255, 0.2);\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);\n}\n\n.ace_fold-widget:active {\n border: 1px solid rgba(0, 0, 0, 0.4);\n background-color: rgba(0, 0, 0, 0.05);\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);\n}\n/**\n * Dark version for fold widgets\n */\n.ace_dark .ace_fold-widget {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");\n}\n.ace_dark .ace_fold-widget.ace_end {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");\n}\n.ace_dark .ace_fold-widget.ace_closed {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");\n}\n.ace_dark .ace_fold-widget:hover {\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\n background-color: rgba(255, 255, 255, 0.1);\n}\n.ace_dark .ace_fold-widget:active {\n box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\n}\n\n.ace_inline_button {\n border: 1px solid lightgray;\n display: inline-block;\n margin: -1px 8px;\n padding: 0 5px;\n pointer-events: auto;\n cursor: pointer;\n}\n.ace_inline_button:hover {\n border-color: gray;\n background: rgba(200,200,200,0.2);\n display: inline-block;\n pointer-events: auto;\n}\n\n.ace_fold-widget.ace_invalid {\n background-color: #FFB4B4;\n border-color: #DE5555;\n}\n\n.ace_fade-fold-widgets .ace_fold-widget {\n transition: opacity 0.4s ease 0.05s;\n opacity: 0;\n}\n\n.ace_fade-fold-widgets:hover .ace_fold-widget {\n transition: opacity 0.05s ease 0.05s;\n opacity:1;\n}\n\n.ace_underline {\n text-decoration: underline;\n}\n\n.ace_bold {\n font-weight: bold;\n}\n\n.ace_nobold .ace_bold {\n font-weight: normal;\n}\n\n.ace_italic {\n font-style: italic;\n}\n\n\n.ace_error-marker {\n background-color: rgba(255, 0, 0,0.2);\n position: absolute;\n z-index: 9;\n}\n\n.ace_highlight-marker {\n background-color: rgba(255, 255, 0,0.2);\n position: absolute;\n z-index: 8;\n}\n\n.ace_mobile-menu {\n position: absolute;\n line-height: 1.5;\n border-radius: 4px;\n -ms-user-select: none;\n -moz-user-select: none;\n -webkit-user-select: none;\n user-select: none;\n background: white;\n box-shadow: 1px 3px 2px grey;\n border: 1px solid #dcdcdc;\n color: black;\n}\n.ace_dark > .ace_mobile-menu {\n background: #333;\n color: #ccc;\n box-shadow: 1px 3px 2px grey;\n border: 1px solid #444;\n\n}\n.ace_mobile-button {\n padding: 2px;\n cursor: pointer;\n overflow: hidden;\n}\n.ace_mobile-button:hover {\n background-color: #eee;\n opacity:1;\n}\n.ace_mobile-button:active {\n background-color: #ddd;\n}\n\n.ace_placeholder {\n position: relative;\n font-family: arial;\n transform: scale(0.9);\n transform-origin: left;\n white-space: pre;\n opacity: 0.7;\n margin: 0 10px;\n z-index: 1;\n}\n\n.ace_ghost_text {\n opacity: 0.5;\n font-style: italic;\n}\n\n.ace_ghost_text_container > div {\n white-space: pre;\n}\n\n.ghost_text_line_wrapped::after {\n content: "↩";\n position: absolute;\n}\n\n.ace_lineWidgetContainer.ace_ghost_text {\n margin: 0px 4px\n}\n\n.ace_screenreader-only {\n position:absolute;\n left:-10000px;\n top:auto;\n width:1px;\n height:1px;\n overflow:hidden;\n}\n\n.ace_hidden_token {\n display: none;\n}'})),ace.define("ace/layer/decorators",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event_emitter"],(function(e,t,n){"use strict";var i=e("../lib/dom"),r=e("../lib/oop"),o=e("../lib/event_emitter").EventEmitter,a=function(){function e(e,t){this.canvas=i.createElement("canvas"),this.renderer=t,this.pixelRatio=1,this.maxHeight=t.layerConfig.maxHeight,this.lineHeight=t.layerConfig.lineHeight,this.canvasHeight=e.parent.scrollHeight,this.heightRatio=this.canvasHeight/this.maxHeight,this.canvasWidth=e.width,this.minDecorationHeight=2*this.pixelRatio|0,this.halfMinDecorationHeight=this.minDecorationHeight/2|0,this.canvas.width=this.canvasWidth,this.canvas.height=this.canvasHeight,this.canvas.style.top="0px",this.canvas.style.right="0px",this.canvas.style.zIndex="7px",this.canvas.style.position="absolute",this.colors={},this.colors.dark={error:"rgba(255, 18, 18, 1)",warning:"rgba(18, 136, 18, 1)",info:"rgba(18, 18, 136, 1)"},this.colors.light={error:"rgb(255,51,51)",warning:"rgb(32,133,72)",info:"rgb(35,68,138)"},e.element.appendChild(this.canvas)}return e.prototype.$updateDecorators=function(e){var t=!0===this.renderer.theme.isDark?this.colors.dark:this.colors.light;e&&(this.maxHeight=e.maxHeight,this.lineHeight=e.lineHeight,this.canvasHeight=e.height,(e.lastRow+1)*this.lineHeight<this.canvasHeight?this.heightRatio=1:this.heightRatio=this.canvasHeight/this.maxHeight);var n=this.canvas.getContext("2d"),i=this.renderer.session.$annotations;if(n.clearRect(0,0,this.canvas.width,this.canvas.height),i){var r={info:1,warning:2,error:3};i.forEach((function(e){e.priority=r[e.type]||null})),i=i.sort((function(e,t){return e.priority<t.priority?-1:e.priority>t.priority?1:0}));for(var o=this.renderer.session.$foldData,a=0;a<i.length;a++){var s=i[a].row,l=this.compensateFoldRows(s,o),c=Math.round((s-l)*this.lineHeight*this.heightRatio),d=Math.round((s-l)*this.lineHeight*this.heightRatio),u=Math.round(((s-l)*this.lineHeight+this.lineHeight)*this.heightRatio);if(u-d<this.minDecorationHeight){var h=(d+u)/2|0;h<this.halfMinDecorationHeight?h=this.halfMinDecorationHeight:h+this.halfMinDecorationHeight>this.canvasHeight&&(h=this.canvasHeight-this.halfMinDecorationHeight),d=Math.round(h-this.halfMinDecorationHeight),u=Math.round(h+this.halfMinDecorationHeight)}n.fillStyle=t[i[a].type]||null,n.fillRect(0,c,this.canvasWidth,u-d)}}var p=this.renderer.session.selection.getCursor();p&&(l=this.compensateFoldRows(p.row,o),c=Math.round((p.row-l)*this.lineHeight*this.heightRatio),n.fillStyle="rgba(0, 0, 0, 0.5)",n.fillRect(0,c,this.canvasWidth,2))},e.prototype.compensateFoldRows=function(e,t){var n=0;if(t&&t.length>0)for(var i=0;i<t.length;i++)e>t[i].start.row&&e<t[i].end.row?n+=e-t[i].start.row:e>=t[i].end.row&&(n+=t[i].end.row-t[i].start.row);return n},e}();r.implement(a.prototype,o),t.Decorator=a})),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/config","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/scrollbar_custom","ace/scrollbar_custom","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter","ace/css/editor-css","ace/layer/decorators","ace/lib/useragent","ace/layer/text_util"],(function(e,t,n){"use strict";var i=e("./lib/oop"),r=e("./lib/dom"),o=e("./lib/lang"),a=e("./config"),s=e("./layer/gutter").Gutter,l=e("./layer/marker").Marker,c=e("./layer/text").Text,d=e("./layer/cursor").Cursor,u=e("./scrollbar").HScrollBar,h=e("./scrollbar").VScrollBar,p=e("./scrollbar_custom").HScrollBar,g=e("./scrollbar_custom").VScrollBar,f=e("./renderloop").RenderLoop,m=e("./layer/font_metrics").FontMetrics,y=e("./lib/event_emitter").EventEmitter,v=e("./css/editor-css"),b=e("./layer/decorators").Decorator,w=e("./lib/useragent"),C=e("./layer/text_util").isTextToken;r.importCssString(v,"ace_editor.css",!1);var x=function(){function e(e,t){var n=this;this.container=e||r.createElement("div"),r.addCssClass(this.container,"ace_editor"),r.HI_DPI&&r.addCssClass(this.container,"ace_hidpi"),this.setTheme(t),null==a.get("useStrictCSP")&&a.set("useStrictCSP",!1),this.$gutter=r.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.$gutter.setAttribute("aria-hidden","true"),this.scroller=r.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=r.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new s(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new l(this.content);var i=this.$textLayer=new c(this.content);this.canvas=i.element,this.$markerFront=new l(this.content),this.$cursorLayer=new d(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new h(this.container,this),this.scrollBarH=new u(this.container,this),this.scrollBarV.on("scroll",(function(e){n.$scrollAnimation||n.session.setScrollTop(e.data-n.scrollMargin.top)})),this.scrollBarH.on("scroll",(function(e){n.$scrollAnimation||n.session.setScrollLeft(e.data-n.scrollMargin.left)})),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new m(this.container),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.on("changeCharacterSize",(function(e){n.updateCharacterSize(),n.onResize(!0,n.gutterWidth,n.$size.width,n.$size.height),n._signal("changeCharacterSize",e)})),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.margin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$keepTextAreaAtCursor=!w.isIOS,this.$loop=new f(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),this.$addResizeObserver(),a.resetOptions(this),a._signal("renderer",this)}return e.prototype.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin(),r.setStyle(this.scroller.style,"line-height",this.lineHeight+"px")},e.prototype.setSession=function(e){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=e,e&&this.scrollMargin.top&&e.getScrollTop()<=0&&e.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(e),this.$markerBack.setSession(e),this.$markerFront.setSession(e),this.$gutterLayer.setSession(e),this.$textLayer.setSession(e),e&&(this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode))},e.prototype.updateLines=function(e,t,n){if(void 0===t&&(t=1/0),this.$changedLines?(this.$changedLines.firstRow>e&&(this.$changedLines.firstRow=e),this.$changedLines.lastRow<t&&(this.$changedLines.lastRow=t)):this.$changedLines={firstRow:e,lastRow:t},this.$changedLines.lastRow<this.layerConfig.firstRow){if(!n)return;this.$changedLines.lastRow=this.layerConfig.lastRow}this.$changedLines.firstRow>this.layerConfig.lastRow||this.$loop.schedule(this.CHANGE_LINES)},e.prototype.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar(),this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR)},e.prototype.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},e.prototype.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},e.prototype.updateFull=function(e){e?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},e.prototype.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},e.prototype.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},e.prototype.onResize=function(e,t,n,i){if(!(this.resizing>2)){this.resizing>0?this.resizing++:this.resizing=e?1:0;var r=this.container;i||(i=r.clientHeight||r.scrollHeight),!i&&this.$maxLines&&this.lineHeight>1&&(r.style.height&&"0px"!=r.style.height||(r.style.height="1px",i=r.clientHeight||r.scrollHeight)),n||(n=r.clientWidth||r.scrollWidth);var o=this.$updateCachedSize(e,t,n,i);if(this.$resizeTimer&&this.$resizeTimer.cancel(),!this.$size.scrollerHeight||!n&&!i)return this.resizing=0;e&&(this.$gutterLayer.$padding=null),e?this.$renderChanges(o|this.$changes,!0):this.$loop.schedule(o|this.$changes),this.resizing&&(this.resizing=0),this.scrollBarH.scrollLeft=this.scrollBarV.scrollTop=null,this.$customScrollbar&&this.$updateCustomScrollbar(!0)}},e.prototype.$updateCachedSize=function(e,t,n,i){i-=this.$extraHeight||0;var o=0,a=this.$size,s={width:a.width,height:a.height,scrollerHeight:a.scrollerHeight,scrollerWidth:a.scrollerWidth};if(i&&(e||a.height!=i)&&(a.height=i,o|=this.CHANGE_SIZE,a.scrollerHeight=a.height,this.$horizScroll&&(a.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.setHeight(a.scrollerHeight),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",o|=this.CHANGE_SCROLL),n&&(e||a.width!=n)){o|=this.CHANGE_SIZE,a.width=n,null==t&&(t=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=t,r.setStyle(this.scrollBarH.element.style,"left",t+"px"),r.setStyle(this.scroller.style,"left",t+this.margin.left+"px"),a.scrollerWidth=Math.max(0,n-t-this.scrollBarV.getWidth()-this.margin.h),r.setStyle(this.$gutter.style,"left",this.margin.left+"px");var l=this.scrollBarV.getWidth()+"px";r.setStyle(this.scrollBarH.element.style,"right",l),r.setStyle(this.scroller.style,"right",l),r.setStyle(this.scroller.style,"bottom",this.scrollBarH.getHeight()),this.scrollBarH.setWidth(a.scrollerWidth),(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||e)&&(o|=this.CHANGE_FULL)}return a.$dirty=!n||!i,o&&this._signal("resize",s),o},e.prototype.onGutterResize=function(e){var t=this.$showGutter?e:0;t!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,t,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()||this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):this.$computeLayerConfig()},e.prototype.adjustWrapLimit=function(){var e=this.$size.scrollerWidth-2*this.$padding,t=Math.floor(e/this.characterWidth);return this.session.adjustWrapLimit(t,this.$showPrintMargin&&this.$printMarginColumn)},e.prototype.setAnimatedScroll=function(e){this.setOption("animatedScroll",e)},e.prototype.getAnimatedScroll=function(){return this.$animatedScroll},e.prototype.setShowInvisibles=function(e){this.setOption("showInvisibles",e),this.session.$bidiHandler.setShowInvisibles(e)},e.prototype.getShowInvisibles=function(){return this.getOption("showInvisibles")},e.prototype.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},e.prototype.setDisplayIndentGuides=function(e){this.setOption("displayIndentGuides",e)},e.prototype.getHighlightIndentGuides=function(){return this.getOption("highlightIndentGuides")},e.prototype.setHighlightIndentGuides=function(e){this.setOption("highlightIndentGuides",e)},e.prototype.setShowPrintMargin=function(e){this.setOption("showPrintMargin",e)},e.prototype.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},e.prototype.setPrintMarginColumn=function(e){this.setOption("printMarginColumn",e)},e.prototype.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},e.prototype.getShowGutter=function(){return this.getOption("showGutter")},e.prototype.setShowGutter=function(e){return this.setOption("showGutter",e)},e.prototype.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},e.prototype.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},e.prototype.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},e.prototype.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},e.prototype.$updatePrintMargin=function(){if(this.$showPrintMargin||this.$printMarginEl){if(!this.$printMarginEl){var e=r.createElement("div");e.className="ace_layer ace_print-margin-layer",this.$printMarginEl=r.createElement("div"),this.$printMarginEl.className="ace_print-margin",e.appendChild(this.$printMarginEl),this.content.insertBefore(e,this.content.firstChild)}var t=this.$printMarginEl.style;t.left=Math.round(this.characterWidth*this.$printMarginColumn+this.$padding)+"px",t.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&-1==this.session.$wrap&&this.adjustWrapLimit()}},e.prototype.getContainerElement=function(){return this.container},e.prototype.getMouseEventTarget=function(){return this.scroller},e.prototype.getTextAreaContainer=function(){return this.container},e.prototype.$moveTextAreaToCursor=function(){if(!this.$isMousePressed){var e=this.textarea.style,t=this.$composition;if(this.$keepTextAreaAtCursor||t){var n=this.$cursorLayer.$pixelPos;if(n){t&&t.markerRange&&(n=this.$cursorLayer.getPixelPosition(t.markerRange.start,!0));var i=this.layerConfig,o=n.top,a=n.left;o-=i.offset;var s=t&&t.useTextareaForIME||w.isMobile?this.lineHeight:1;if(o<0||o>i.height-s)r.translate(this.textarea,0,0);else{var l=1,c=this.$size.height-s;if(t)if(t.useTextareaForIME){var d=this.textarea.value;l=this.characterWidth*this.session.$getStringScreenWidth(d)[0]}else o+=this.lineHeight+2;else o+=this.lineHeight;(a-=this.scrollLeft)>this.$size.scrollerWidth-l&&(a=this.$size.scrollerWidth-l),a+=this.gutterWidth+this.margin.left,r.setStyle(e,"height",s+"px"),r.setStyle(e,"width",l+"px"),r.translate(this.textarea,Math.min(a,this.$size.scrollerWidth-l),Math.min(o,c))}}}else r.translate(this.textarea,-100,0)}},e.prototype.getFirstVisibleRow=function(){return this.layerConfig.firstRow},e.prototype.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(0===this.layerConfig.offset?0:1)},e.prototype.getLastFullyVisibleRow=function(){var e=this.layerConfig,t=e.lastRow;return this.session.documentToScreenRow(t,0)*e.lineHeight-this.session.getScrollTop()>e.height-e.lineHeight?t-1:t},e.prototype.getLastVisibleRow=function(){return this.layerConfig.lastRow},e.prototype.setPadding=function(e){this.$padding=e,this.$textLayer.setPadding(e),this.$cursorLayer.setPadding(e),this.$markerFront.setPadding(e),this.$markerBack.setPadding(e),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},e.prototype.setScrollMargin=function(e,t,n,i){var r=this.scrollMargin;r.top=0|e,r.bottom=0|t,r.right=0|i,r.left=0|n,r.v=r.top+r.bottom,r.h=r.left+r.right,r.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-r.top),this.updateFull()},e.prototype.setMargin=function(e,t,n,i){var r=this.margin;r.top=0|e,r.bottom=0|t,r.right=0|i,r.left=0|n,r.v=r.top+r.bottom,r.h=r.left+r.right,this.$updateCachedSize(!0,this.gutterWidth,this.$size.width,this.$size.height),this.updateFull()},e.prototype.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},e.prototype.setHScrollBarAlwaysVisible=function(e){this.setOption("hScrollBarAlwaysVisible",e)},e.prototype.getVScrollBarAlwaysVisible=function(){return this.$vScrollBarAlwaysVisible},e.prototype.setVScrollBarAlwaysVisible=function(e){this.setOption("vScrollBarAlwaysVisible",e)},e.prototype.$updateScrollBarV=function(){var e=this.layerConfig.maxHeight,t=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(e-=(t-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>e-t&&(e=this.scrollTop+t,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(e+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},e.prototype.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},e.prototype.freeze=function(){this.$frozen=!0},e.prototype.unfreeze=function(){this.$frozen=!1},e.prototype.$renderChanges=function(e,t){if(this.$changes&&(e|=this.$changes,this.$changes=0),this.session&&this.container.offsetWidth&&!this.$frozen&&(e||t)){if(this.$size.$dirty)return this.$changes|=e,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender",e),this.session&&this.session.$bidiHandler&&this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);var n=this.layerConfig;if(e&this.CHANGE_FULL||e&this.CHANGE_SIZE||e&this.CHANGE_TEXT||e&this.CHANGE_LINES||e&this.CHANGE_SCROLL||e&this.CHANGE_H_SCROLL){if(e|=this.$computeLayerConfig()|this.$loop.clear(),n.firstRow!=this.layerConfig.firstRow&&n.firstRowScreen==this.layerConfig.firstRowScreen){var i=this.scrollTop+(n.firstRow-Math.max(this.layerConfig.firstRow,0))*this.lineHeight;i>0&&(this.scrollTop=i,e|=this.CHANGE_SCROLL,e|=this.$computeLayerConfig()|this.$loop.clear())}n=this.layerConfig,this.$updateScrollBarV(),e&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),r.translate(this.content,-this.scrollLeft,-n.offset);var o=n.width+2*this.$padding+"px",a=n.minHeight+"px";r.setStyle(this.content.style,"width",o),r.setStyle(this.content.style,"height",a)}if(e&this.CHANGE_H_SCROLL&&(r.translate(this.content,-this.scrollLeft,-n.offset),this.scroller.className=this.scrollLeft<=0?"ace_scroller ":"ace_scroller ace_scroll-left ",this.enableKeyboardAccessibility&&(this.scroller.className+=this.keyboardFocusClassName)),e&this.CHANGE_FULL)return this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),void this._signal("afterRender",e);if(e&this.CHANGE_SCROLL)return this.$changedLines=null,e&this.CHANGE_TEXT||e&this.CHANGE_LINES?this.$textLayer.update(n):this.$textLayer.scrollLines(n),this.$showGutter&&(e&this.CHANGE_GUTTER||e&this.CHANGE_LINES?this.$gutterLayer.update(n):this.$gutterLayer.scrollLines(n)),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),void this._signal("afterRender",e);e&this.CHANGE_TEXT?(this.$changedLines=null,this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)):e&this.CHANGE_LINES?((this.$updateLines()||e&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)):e&this.CHANGE_TEXT||e&this.CHANGE_GUTTER?(this.$showGutter&&this.$gutterLayer.update(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)):e&this.CHANGE_CURSOR&&(this.$highlightGutterLine&&this.$gutterLayer.updateLineHighlight(n),this.$customScrollbar&&this.$scrollDecorator.$updateDecorators(n)),e&this.CHANGE_CURSOR&&(this.$cursorLayer.update(n),this.$moveTextAreaToCursor()),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(n),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(n),this._signal("afterRender",e)}else this.$changes|=e},e.prototype.$autosize=function(){var e=this.session.getScreenLength()*this.lineHeight,t=this.$maxLines*this.lineHeight,n=Math.min(t,Math.max((this.$minLines||1)*this.lineHeight,e))+this.scrollMargin.v+(this.$extraHeight||0);this.$horizScroll&&(n+=this.scrollBarH.getHeight()),this.$maxPixelHeight&&n>this.$maxPixelHeight&&(n=this.$maxPixelHeight);var i=!(n<=2*this.lineHeight)&&e>t;if(n!=this.desiredHeight||this.$size.height!=this.desiredHeight||i!=this.$vScroll){i!=this.$vScroll&&(this.$vScroll=i,this.scrollBarV.setVisible(i));var r=this.container.clientWidth;this.container.style.height=n+"px",this.$updateCachedSize(!0,this.$gutterWidth,r,n),this.desiredHeight=n,this._signal("autosize")}},e.prototype.$computeLayerConfig=function(){var e=this.session,t=this.$size,n=t.height<=2*this.lineHeight,i=this.session.getScreenLength()*this.lineHeight,r=this.$getLongestLine(),o=!n&&(this.$hScrollBarAlwaysVisible||t.scrollerWidth-r-2*this.$padding<0),a=this.$horizScroll!==o;a&&(this.$horizScroll=o,this.scrollBarH.setVisible(o));var s=this.$vScroll;this.$maxLines&&this.lineHeight>1&&(this.$autosize(),n=t.height<=2*this.lineHeight);var l=t.scrollerHeight+this.lineHeight,c=!this.$maxLines&&this.$scrollPastEnd?(t.scrollerHeight-this.lineHeight)*this.$scrollPastEnd:0;i+=c;var d=this.scrollMargin;this.session.setScrollTop(Math.max(-d.top,Math.min(this.scrollTop,i-t.scrollerHeight+d.bottom))),this.session.setScrollLeft(Math.max(-d.left,Math.min(this.scrollLeft,r+2*this.$padding-t.scrollerWidth+d.right)));var u=!n&&(this.$vScrollBarAlwaysVisible||t.scrollerHeight-i+c<0||this.scrollTop>d.top),h=s!==u;h&&(this.$vScroll=u,this.scrollBarV.setVisible(u));var p,g,f=this.scrollTop%this.lineHeight,m=Math.ceil(l/this.lineHeight)-1,y=Math.max(0,Math.round((this.scrollTop-f)/this.lineHeight)),v=y+m,b=this.lineHeight;y=e.screenToDocumentRow(y,0);var w=e.getFoldLine(y);w&&(y=w.start.row),p=e.documentToScreenRow(y,0),g=e.getRowLength(y)*b,v=Math.min(e.screenToDocumentRow(v,0),e.getLength()-1),l=t.scrollerHeight+e.getRowLength(v)*b+g,f=this.scrollTop-p*b;var C=0;return(this.layerConfig.width!=r||a)&&(C=this.CHANGE_H_SCROLL),(a||h)&&(C|=this.$updateCachedSize(!0,this.gutterWidth,t.width,t.height),this._signal("scrollbarVisibilityChanged"),h&&(r=this.$getLongestLine())),this.layerConfig={width:r,padding:this.$padding,firstRow:y,firstRowScreen:p,lastRow:v,lineHeight:b,characterWidth:this.characterWidth,minHeight:l,maxHeight:i,offset:f,gutterOffset:b?Math.max(0,Math.ceil((f+t.height-t.scrollerHeight)/b)):0,height:this.$size.scrollerHeight},this.session.$bidiHandler&&this.session.$bidiHandler.setContentWidth(r-this.$padding),C},e.prototype.$updateLines=function(){if(this.$changedLines){var e=this.$changedLines.firstRow,t=this.$changedLines.lastRow;this.$changedLines=null;var n=this.layerConfig;if(!(e>n.lastRow+1||t<n.firstRow))return t===1/0?(this.$showGutter&&this.$gutterLayer.update(n),void this.$textLayer.update(n)):(this.$textLayer.updateLines(n,e,t),!0)}},e.prototype.$getLongestLine=function(){var e=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(e+=1),this.$textLayer&&e>this.$textLayer.MAX_LINE_LENGTH&&(e=this.$textLayer.MAX_LINE_LENGTH+30),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(e*this.characterWidth))},e.prototype.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},e.prototype.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},e.prototype.addGutterDecoration=function(e,t){this.$gutterLayer.addGutterDecoration(e,t)},e.prototype.removeGutterDecoration=function(e,t){this.$gutterLayer.removeGutterDecoration(e,t)},e.prototype.updateBreakpoints=function(e){this._rows=e,this.$loop.schedule(this.CHANGE_GUTTER)},e.prototype.setAnnotations=function(e){this.$gutterLayer.setAnnotations(e),this.$loop.schedule(this.CHANGE_GUTTER)},e.prototype.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},e.prototype.hideCursor=function(){this.$cursorLayer.hideCursor()},e.prototype.showCursor=function(){this.$cursorLayer.showCursor()},e.prototype.scrollSelectionIntoView=function(e,t,n){this.scrollCursorIntoView(e,n),this.scrollCursorIntoView(t,n)},e.prototype.scrollCursorIntoView=function(e,t,n){if(0!==this.$size.scrollerHeight){var i=this.$cursorLayer.getPixelPosition(e),r=i.left,o=i.top,a=n&&n.top||0,s=n&&n.bottom||0;this.$scrollAnimation&&(this.$stopAnimation=!0);var l=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;l+a>o?(t&&l+a>o+this.lineHeight&&(o-=t*this.$size.scrollerHeight),0===o&&(o=-this.scrollMargin.top),this.session.setScrollTop(o)):l+this.$size.scrollerHeight-s<o+this.lineHeight&&(t&&l+this.$size.scrollerHeight-s<o-this.lineHeight&&(o+=t*this.$size.scrollerHeight),this.session.setScrollTop(o+this.lineHeight+s-this.$size.scrollerHeight));var c=this.scrollLeft,d=2*this.layerConfig.characterWidth;r-d<c?((r-=d)<this.$padding+d&&(r=-this.scrollMargin.left),this.session.setScrollLeft(r)):(r+=d,c+this.$size.scrollerWidth<r+this.characterWidth?this.session.setScrollLeft(Math.round(r+this.characterWidth-this.$size.scrollerWidth)):c<=this.$padding&&r-c<this.characterWidth&&this.session.setScrollLeft(0))}},e.prototype.getScrollTop=function(){return this.session.getScrollTop()},e.prototype.getScrollLeft=function(){return this.session.getScrollLeft()},e.prototype.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},e.prototype.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},e.prototype.scrollToRow=function(e){this.session.setScrollTop(e*this.lineHeight)},e.prototype.alignCursor=function(e,t){"number"==typeof e&&(e={row:e,column:0});var n=this.$cursorLayer.getPixelPosition(e),i=this.$size.scrollerHeight-this.lineHeight,r=n.top-i*(t||0);return this.session.setScrollTop(r),r},e.prototype.$calcSteps=function(e,t){var n,i,r=0,o=this.STEPS,a=[];for(r=0;r<o;++r)a.push((n=r/this.STEPS,i=e,(t-e)*(Math.pow(n-1,3)+1)+i));return a},e.prototype.scrollToLine=function(e,t,n,i){var r=this.$cursorLayer.getPixelPosition({row:e,column:0}).top;t&&(r-=this.$size.scrollerHeight/2);var o=this.scrollTop;this.session.setScrollTop(r),!1!==n&&this.animateScrolling(o,i)},e.prototype.animateScrolling=function(e,t){var n=this.scrollTop;if(this.$animatedScroll){var i=this;if(e!=n){if(this.$scrollAnimation){var r=this.$scrollAnimation.steps;if(r.length&&(e=r[0])==n)return}var o=i.$calcSteps(e,n);this.$scrollAnimation={from:e,to:n,steps:o},clearInterval(this.$timer),i.session.setScrollTop(o.shift()),i.session.$scrollTop=n,this.$timer=setInterval((function(){if(!i.$stopAnimation)return i.session?void(o.length?(i.session.setScrollTop(o.shift()),i.session.$scrollTop=n):null!=n?(i.session.$scrollTop=-1,i.session.setScrollTop(n),n=null):a()):clearInterval(i.$timer);a()}),10)}}function a(){i.$timer=clearInterval(i.$timer),i.$scrollAnimation=null,i.$stopAnimation=!1,t&&t()}},e.prototype.scrollToY=function(e){this.scrollTop!==e&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=e)},e.prototype.scrollToX=function(e){this.scrollLeft!==e&&(this.scrollLeft=e),this.$loop.schedule(this.CHANGE_H_SCROLL)},e.prototype.scrollTo=function(e,t){this.session.setScrollTop(t),this.session.setScrollLeft(e)},e.prototype.scrollBy=function(e,t){t&&this.session.setScrollTop(this.session.getScrollTop()+t),e&&this.session.setScrollLeft(this.session.getScrollLeft()+e)},e.prototype.isScrollableBy=function(e,t){return t<0&&this.session.getScrollTop()>=1-this.scrollMargin.top||t>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom||e<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left||e>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right||void 0},e.prototype.pixelToScreenCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var i=this.$fontMetrics.transformCoordinates([e,t]);e=i[1]-this.gutterWidth-this.margin.left,t=i[0]}else n=this.scroller.getBoundingClientRect();var r=e+this.scrollLeft-n.left-this.$padding,o=r/this.characterWidth,a=Math.floor((t+this.scrollTop-n.top)/this.lineHeight),s=this.$blockCursor?Math.floor(o):Math.round(o);return{row:a,column:s,side:o-s>0?1:-1,offsetX:r}},e.prototype.screenToTextCoordinates=function(e,t){var n;if(this.$hasCssTransforms){n={top:0,left:0};var i=this.$fontMetrics.transformCoordinates([e,t]);e=i[1]-this.gutterWidth-this.margin.left,t=i[0]}else n=this.scroller.getBoundingClientRect();var r=e+this.scrollLeft-n.left-this.$padding,o=r/this.characterWidth,a=this.$blockCursor?Math.floor(o):Math.round(o),s=Math.floor((t+this.scrollTop-n.top)/this.lineHeight);return this.session.screenToDocumentPosition(s,Math.max(a,0),r)},e.prototype.textToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),i=this.session.documentToScreenPosition(e,t),r=this.$padding+(this.session.$bidiHandler.isBidiRow(i.row,e)?this.session.$bidiHandler.getPosLeft(i.column):Math.round(i.column*this.characterWidth)),o=i.row*this.lineHeight;return{pageX:n.left+r-this.scrollLeft,pageY:n.top+o-this.scrollTop}},e.prototype.visualizeFocus=function(){r.addCssClass(this.container,"ace_focus")},e.prototype.visualizeBlur=function(){r.removeCssClass(this.container,"ace_focus")},e.prototype.showComposition=function(e){this.$composition=e,e.cssText||(e.cssText=this.textarea.style.cssText),null==e.useTextareaForIME&&(e.useTextareaForIME=this.$useTextareaForIME),this.$useTextareaForIME?(r.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor(),this.$cursorLayer.element.style.display="none"):e.markerId=this.session.addMarker(e.markerRange,"ace_composition_marker","text")},e.prototype.setCompositionText=function(e){var t=this.session.selection.cursor;this.addToken(e,"composition_placeholder",t.row,t.column),this.$moveTextAreaToCursor()},e.prototype.hideComposition=function(){if(this.$composition){this.$composition.markerId&&this.session.removeMarker(this.$composition.markerId),r.removeCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText=this.$composition.cssText;var e=this.session.selection.cursor;this.removeExtraToken(e.row,e.column),this.$composition=null,this.$cursorLayer.element.style.display=""}},e.prototype.setGhostText=function(e,t){var n=this.session.selection.cursor,i=t||{row:n.row,column:n.column};this.removeGhostText();var o=this.$calculateWrappedTextChunks(e,i);this.addToken(o[0].text,"ghost_text",i.row,i.column),this.$ghostText={text:e,position:{row:i.row,column:i.column}};var a=r.createElement("div");if(o.length>1){var s,l=this.hideTokensAfterPosition(i.row,i.column);o.slice(1).forEach((function(e){var t=r.createElement("div"),n=r.createElement("span");n.className="ace_ghost_text",e.wrapped&&(t.className="ghost_text_line_wrapped"),0===e.text.length&&(e.text=" "),n.appendChild(r.createTextNode(e.text)),t.appendChild(n),a.appendChild(t),s=t})),l.forEach((function(e){var t=r.createElement("span");C(e.type)||(t.className="ace_"+e.type.replace(/\./g," ace_")),t.appendChild(r.createTextNode(e.value)),s.appendChild(t)})),this.$ghostTextWidget={el:a,row:i.row,column:i.column,className:"ace_ghost_text_container"},this.session.widgetManager.addLineWidget(this.$ghostTextWidget);var c=this.$cursorLayer.getPixelPosition(i,!0),d=this.container.getBoundingClientRect().height,u=o.length*this.lineHeight;if(u<d-c.top)return;u<d?this.scrollBy(0,(o.length-1)*this.lineHeight):this.scrollToRow(i.row)}},e.prototype.$calculateWrappedTextChunks=function(e,t){var n=this.$size.scrollerWidth-2*this.$padding,i=Math.floor(n/this.characterWidth)-2;i=i<=0?60:i;for(var r=e.split(/\r?\n/),o=[],a=0;a<r.length;a++){var s=this.session.$getDisplayTokens(r[a],t.column),l=this.session.$computeWrapSplits(s,i,this.session.$tabSize);if(l.length>0){var c=0;l.push(r[a].length);for(var d=0;d<l.length;d++){var u=r[a].slice(c,l[d]);o.push({text:u,wrapped:!0}),c=l[d]}}else o.push({text:r[a],wrapped:!1})}return o},e.prototype.removeGhostText=function(){if(this.$ghostText){var e=this.$ghostText.position;this.removeExtraToken(e.row,e.column),this.$ghostTextWidget&&(this.session.widgetManager.removeLineWidget(this.$ghostTextWidget),this.$ghostTextWidget=null),this.$ghostText=null}},e.prototype.addToken=function(e,t,n,i){var r=this.session;r.bgTokenizer.lines[n]=null;var o={type:t,value:e},a=r.getTokens(n);if(null!=i&&a.length)for(var s=0,l=0;l<a.length;l++){var c=a[l];if(i<=(s+=c.value.length)){var d=c.value.length-(s-i),u=c.value.slice(0,d),h=c.value.slice(d);a.splice(l,1,{type:c.type,value:u},o,{type:c.type,value:h});break}}else a.push(o);this.updateLines(n,n)},e.prototype.hideTokensAfterPosition=function(e,t){for(var n=this.session.getTokens(e),i=0,r=!1,o=[],a=0;a<n.length;a++){var s=n[a];i+=s.value.length,"ghost_text"!==s.type&&(r?(o.push({type:s.type,value:s.value}),s.type="hidden_token"):i===t&&(r=!0))}return this.updateLines(e,e),o},e.prototype.removeExtraToken=function(e,t){this.session.bgTokenizer.lines[e]=null,this.updateLines(e,e)},e.prototype.setTheme=function(e,t){var n=this;if(this.$themeId=e,n._dispatchEvent("themeChange",{theme:e}),e&&"string"!=typeof e)o(e);else{var i=e||this.$options.theme.initialValue;a.loadModule(["theme",i],o)}function o(i){if(n.$themeId!=e)return t&&t();if(!i||!i.cssClass)throw new Error("couldn't load module "+e+" or it didn't call define");i.$id&&(n.$themeId=i.$id),r.importCssString(i.cssText,i.cssClass,n.container),n.theme&&r.removeCssClass(n.container,n.theme.cssClass);var o="padding"in i?i.padding:"padding"in(n.theme||{})?4:n.$padding;n.$padding&&o!=n.$padding&&n.setPadding(o),n.$theme=i.cssClass,n.theme=i,r.addCssClass(n.container,i.cssClass),r.setCssClass(n.container,"ace_dark",i.isDark),n.$size&&(n.$size.width=0,n.$updateSizeAsync()),n._dispatchEvent("themeLoaded",{theme:i}),t&&t(),w.isSafari&&n.scroller&&(n.scroller.style.background="red",n.scroller.style.background="")}},e.prototype.getTheme=function(){return this.$themeId},e.prototype.setStyle=function(e,t){r.setCssClass(this.container,e,!1!==t)},e.prototype.unsetStyle=function(e){r.removeCssClass(this.container,e)},e.prototype.setCursorStyle=function(e){r.setStyle(this.scroller.style,"cursor",e)},e.prototype.setMouseCursor=function(e){r.setStyle(this.scroller.style,"cursor",e)},e.prototype.attachToShadowRoot=function(){r.importCssString(v,"ace_editor.css",this.container)},e.prototype.destroy=function(){this.freeze(),this.$fontMetrics.destroy(),this.$cursorLayer.destroy(),this.removeAllListeners(),this.container.textContent="",this.setOption("useResizeObserver",!1)},e.prototype.$updateCustomScrollbar=function(e){var t=this;this.$horizScroll=this.$vScroll=null,this.scrollBarV.element.remove(),this.scrollBarH.element.remove(),this.$scrollDecorator&&delete this.$scrollDecorator,!0===e?(this.scrollBarV=new g(this.container,this),this.scrollBarH=new p(this.container,this),this.scrollBarV.setHeight(this.$size.scrollerHeight),this.scrollBarH.setWidth(this.$size.scrollerWidth),this.scrollBarV.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollTop(e.data-t.scrollMargin.top)})),this.scrollBarH.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollLeft(e.data-t.scrollMargin.left)})),this.$scrollDecorator=new b(this.scrollBarV,this),this.$scrollDecorator.$updateDecorators()):(this.scrollBarV=new h(this.container,this),this.scrollBarH=new u(this.container,this),this.scrollBarV.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollTop(e.data-t.scrollMargin.top)})),this.scrollBarH.addEventListener("scroll",(function(e){t.$scrollAnimation||t.session.setScrollLeft(e.data-t.scrollMargin.left)})))},e.prototype.$addResizeObserver=function(){if(window.ResizeObserver&&!this.$resizeObserver){var e=this;this.$resizeTimer=o.delayedCall((function(){e.destroyed||e.onResize()}),50),this.$resizeObserver=new window.ResizeObserver((function(t){var n=t[0].contentRect.width,i=t[0].contentRect.height;Math.abs(e.$size.width-n)>1||Math.abs(e.$size.height-i)>1?e.$resizeTimer.delay():e.$resizeTimer.cancel()})),this.$resizeObserver.observe(this.container)}},e}();x.prototype.CHANGE_CURSOR=1,x.prototype.CHANGE_MARKER=2,x.prototype.CHANGE_GUTTER=4,x.prototype.CHANGE_SCROLL=8,x.prototype.CHANGE_LINES=16,x.prototype.CHANGE_TEXT=32,x.prototype.CHANGE_SIZE=64,x.prototype.CHANGE_MARKER_BACK=128,x.prototype.CHANGE_MARKER_FRONT=256,x.prototype.CHANGE_FULL=512,x.prototype.CHANGE_H_SCROLL=1024,x.prototype.$changes=0,x.prototype.$padding=null,x.prototype.$frozen=!1,x.prototype.STEPS=8,i.implement(x.prototype,y),a.defineOptions(x.prototype,"renderer",{useResizeObserver:{set:function(e){!e&&this.$resizeObserver?(this.$resizeObserver.disconnect(),this.$resizeTimer.cancel(),this.$resizeTimer=this.$resizeObserver=null):e&&!this.$resizeObserver&&this.$addResizeObserver()}},animatedScroll:{initialValue:!1},showInvisibles:{set:function(e){this.$textLayer.setShowInvisibles(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(e){"number"==typeof e&&(this.$printMarginColumn=e),this.$showPrintMargin=!!e,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(e){this.$gutter.style.display=e?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},useSvgGutterIcons:{set:function(e){this.$gutterLayer.$useSvgGutterIcons=e},initialValue:!1},showFoldedAnnotations:{set:function(e){this.$gutterLayer.$showFoldedAnnotations=e},initialValue:!1},fadeFoldWidgets:{set:function(e){r.setCssClass(this.$gutter,"ace_fade-fold-widgets",e)},initialValue:!1},showFoldWidgets:{set:function(e){this.$gutterLayer.setShowFoldWidgets(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(e){this.$textLayer.setDisplayIndentGuides(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightIndentGuides:{set:function(e){1==this.$textLayer.setHighlightIndentGuides(e)?this.$textLayer.$highlightIndentGuide():this.$textLayer.$clearActiveIndentGuide(this.$textLayer.$lines.cells)},initialValue:!0},highlightGutterLine:{set:function(e){this.$gutterLayer.setHighlightGutterLine(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},hScrollBarAlwaysVisible:{set:function(e){this.$hScrollBarAlwaysVisible&&this.$horizScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(e){this.$vScrollBarAlwaysVisible&&this.$vScroll||this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(e){"number"==typeof e&&(e+="px"),this.container.style.fontSize=e,this.updateFontSize()},initialValue:12},fontFamily:{set:function(e){this.container.style.fontFamily=e,this.updateFontSize()}},maxLines:{set:function(e){this.updateFull()}},minLines:{set:function(e){this.$minLines<562949953421311||(this.$minLines=0),this.updateFull()}},maxPixelHeight:{set:function(e){this.updateFull()},initialValue:0},scrollPastEnd:{set:function(e){e=+e||0,this.$scrollPastEnd!=e&&(this.$scrollPastEnd=e,this.$loop.schedule(this.CHANGE_SCROLL))},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(e){this.$gutterLayer.$fixedWidth=!!e,this.$loop.schedule(this.CHANGE_GUTTER)}},customScrollbar:{set:function(e){this.$updateCustomScrollbar(e)},initialValue:!1},theme:{set:function(e){this.setTheme(e)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0},hasCssTransforms:{},useTextareaForIME:{initialValue:!w.isMobile&&!w.isIE}}),t.VirtualRenderer=x})),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],(function(e,t,n){"use strict";var i=e("../lib/oop"),r=e("../lib/net"),o=e("../lib/event_emitter").EventEmitter,a=e("../config");function s(e){if("undefined"==typeof Worker)return{postMessage:function(){},terminate:function(){}};if(a.get("loadWorkerFromBlob")){var t=function(e){var t="importScripts('"+r.qualifyURL(e)+"');";try{return new Blob([t],{type:"application/javascript"})}catch(e){var n=new(window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder);return n.append(t),n.getBlob("application/javascript")}}(e),n=(window.URL||window.webkitURL).createObjectURL(t);return new Worker(n)}return new Worker(e)}var l=function(e){e.postMessage||(e=this.$createWorkerFromOldConfig.apply(this,arguments)),this.$worker=e,this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.onMessage=this.onMessage.bind(this),this.callbackId=1,this.callbacks={},this.$worker.onmessage=this.onMessage};(function(){i.implement(this,o),this.$createWorkerFromOldConfig=function(t,n,i,r,o){if(e.nameToUrl&&!e.toUrl&&(e.toUrl=e.nameToUrl),a.get("packaged")||!e.toUrl)r=r||a.moduleUrl(n,"worker");else{var l=this.$normalizePath;r=r||l(e.toUrl("ace/worker/worker.js",null,"_"));var c={};t.forEach((function(t){c[t]=l(e.toUrl(t,null,"_").replace(/(\.js)?(\?.*)?$/,""))}))}return this.$worker=s(r),o&&this.send("importScripts",o),this.$worker.postMessage({init:!0,tlns:c,module:n,classname:i}),this.$worker},this.onMessage=function(e){var t=e.data;switch(t.type){case"event":this._signal(t.name,{data:t.data});break;case"call":var n=this.callbacks[t.id];n&&(n(t.data),delete this.callbacks[t.id]);break;case"error":this.reportError(t.data);break;case"log":window.console&&console.log&&console.log.apply(console,t.data)}},this.reportError=function(e){window.console&&console.error&&console.error(e)},this.$normalizePath=function(e){return r.qualifyURL(e)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker.onerror=function(e){e.preventDefault()},this.$worker=null,this.$doc&&this.$doc.off("change",this.changeListener),this.$doc=null},this.send=function(e,t){this.$worker.postMessage({command:e,args:t})},this.call=function(e,t,n){if(n){var i=this.callbackId++;this.callbacks[i]=n,t.push(i)}this.send(e,t)},this.emit=function(e,t){try{t.data&&t.data.err&&(t.data.err={message:t.data.err.message,stack:t.data.err.stack,code:t.data.err.code}),this.$worker&&this.$worker.postMessage({event:e,data:{data:t.data}})}catch(e){console.error(e.stack)}},this.attachToDocument=function(e){this.$doc&&this.terminate(),this.$doc=e,this.call("setValue",[e.getValue()]),e.on("change",this.changeListener,!0)},this.changeListener=function(e){this.deltaQueue||(this.deltaQueue=[],setTimeout(this.$sendDeltaQueue,0)),"insert"==e.action?this.deltaQueue.push(e.start,e.lines):this.deltaQueue.push(e.start,e.end)},this.$sendDeltaQueue=function(){var e=this.deltaQueue;e&&(this.deltaQueue=null,e.length>50&&e.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:e}))}}).call(l.prototype),t.UIWorkerClient=function(e,t,n){var i=null,r=!1,s=Object.create(o),c=[],d=new l({messageBuffer:c,terminate:function(){},postMessage:function(e){c.push(e),i&&(r?setTimeout(u):u())}});d.setEmitSync=function(e){r=e};var u=function(){var e=c.shift();e.command?i[e.command].apply(i,e.args):e.event&&s._signal(e.event,e.data)};return s.postMessage=function(e){d.onMessage({data:e})},s.callback=function(e,t){this.postMessage({type:"call",id:t,data:e})},s.emit=function(e,t){this.postMessage({type:"event",name:e,data:t})},a.loadModule(["worker",t],(function(e){for(i=new e[n](s);c.length;)u()})),d},t.WorkerClient=l,t.createWorker=s})),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],(function(e,t,n){"use strict";var i=e("./range").Range,r=e("./lib/event_emitter").EventEmitter,o=e("./lib/oop"),a=function(){function e(e,t,n,i,r,o){var a=this;this.length=t,this.session=e,this.doc=e.getDocument(),this.mainClass=r,this.othersClass=o,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate,!0),this.$others=i,this.$onCursorChange=function(){setTimeout((function(){a.onCursorChange()}))},this.$pos=n;var s=e.getUndoManager().$undoStack||e.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=s.length,this.setup(),e.selection.on("changeCursor",this.$onCursorChange)}return e.prototype.setup=function(){var e=this,t=this.doc,n=this.session;this.selectionBefore=n.selection.toJSON(),n.selection.inMultiSelectMode&&n.selection.toSingleRange(),this.pos=t.createAnchor(this.$pos.row,this.$pos.column);var r=this.pos;r.$insertRight=!0,r.detach(),r.markerId=n.addMarker(new i(r.row,r.column,r.row,r.column+this.length),this.mainClass,null,!1),this.others=[],this.$others.forEach((function(n){var i=t.createAnchor(n.row,n.column);i.$insertRight=!0,i.detach(),e.others.push(i)})),n.setUndoSelect(!1)},e.prototype.showOtherMarkers=function(){if(!this.othersActive){var e=this.session,t=this;this.othersActive=!0,this.others.forEach((function(n){n.markerId=e.addMarker(new i(n.row,n.column,n.row,n.column+t.length),t.othersClass,null,!1)}))}},e.prototype.hideOtherMarkers=function(){if(this.othersActive){this.othersActive=!1;for(var e=0;e<this.others.length;e++)this.session.removeMarker(this.others[e].markerId)}},e.prototype.onUpdate=function(e){if(this.$updating)return this.updateAnchors(e);var t=e;if(t.start.row===t.end.row&&t.start.row===this.pos.row){this.$updating=!0;var n="insert"===e.action?t.end.column-t.start.column:t.start.column-t.end.column,r=t.start.column>=this.pos.column&&t.start.column<=this.pos.column+this.length+1,o=t.start.column-this.pos.column;if(this.updateAnchors(e),r&&(this.length+=n),r&&!this.session.$fromUndo)if("insert"===e.action)for(var a=this.others.length-1;a>=0;a--){var s={row:(l=this.others[a]).row,column:l.column+o};this.doc.insertMergedLines(s,e.lines)}else if("remove"===e.action)for(a=this.others.length-1;a>=0;a--){var l;s={row:(l=this.others[a]).row,column:l.column+o},this.doc.remove(new i(s.row,s.column,s.row,s.column-n))}this.$updating=!1,this.updateMarkers()}},e.prototype.updateAnchors=function(e){this.pos.onChange(e);for(var t=this.others.length;t--;)this.others[t].onChange(e);this.updateMarkers()},e.prototype.updateMarkers=function(){if(!this.$updating){var e=this,t=this.session,n=function(n,r){t.removeMarker(n.markerId),n.markerId=t.addMarker(new i(n.row,n.column,n.row,n.column+e.length),r,null,!1)};n(this.pos,this.mainClass);for(var r=this.others.length;r--;)n(this.others[r],this.othersClass)}},e.prototype.onCursorChange=function(e){if(!this.$updating&&this.session){var t=this.session.selection.getCursor();t.row===this.pos.row&&t.column>=this.pos.column&&t.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",e)):(this.hideOtherMarkers(),this._emit("cursorLeave",e))}},e.prototype.detach=function(){this.session.removeMarker(this.pos&&this.pos.markerId),this.hideOtherMarkers(),this.doc.off("change",this.$onUpdate),this.session.selection.off("changeCursor",this.$onCursorChange),this.session.setUndoSelect(!0),this.session=null},e.prototype.cancel=function(){if(-1!==this.$undoStackDepth){for(var e=this.session.getUndoManager(),t=(e.$undoStack||e.$undostack).length-this.$undoStackDepth,n=0;n<t;n++)e.undo(this.session,!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}},e}();o.implement(a.prototype,r),t.PlaceHolder=a})),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],(function(e,t,n){var i=e("../lib/event"),r=e("../lib/useragent");function o(e,t){return e.row==t.row&&e.column==t.column}t.onMouseDown=function(e){var t=e.domEvent,n=t.altKey,a=t.shiftKey,s=t.ctrlKey,l=e.getAccelKey(),c=e.getButton();if(s&&r.isMac&&(c=t.button),e.editor.inMultiSelectMode&&2==c)e.editor.textInput.onContextMenu(e.domEvent);else if(s||n||l){if(0===c){var d,u=e.editor,h=u.selection,p=u.inMultiSelectMode,g=e.getDocumentPosition(),f=h.getCursor(),m=e.inSelection()||h.isEmpty()&&o(g,f),y=e.x,v=e.y,b=u.session,w=u.renderer.pixelToScreenCoordinates(y,v),C=w;if(u.$mouseHandler.$enableJumpToDef)s&&n||l&&n?d=a?"block":"add":n&&u.$blockSelectEnabled&&(d="block");else if(l&&!n){if(d="add",!p&&a)return}else n&&u.$blockSelectEnabled&&(d="block");if(d&&r.isMac&&t.ctrlKey&&u.$mouseHandler.cancelContextMenu(),"add"==d){if(!p&&m)return;if(!p){var x=h.toOrientedRange();u.addSelectionMarker(x)}var S=h.rangeList.rangeAtPoint(g);u.inVirtualSelectionMode=!0,a&&(S=null,x=h.ranges[0]||x,u.removeSelectionMarker(x)),u.once("mouseup",(function(){var e=h.toOrientedRange();S&&e.isEmpty()&&o(S.cursor,e.cursor)?h.substractPoint(e.cursor):(a?h.substractPoint(x.cursor):x&&(u.removeSelectionMarker(x),h.addRange(x)),h.addRange(e)),u.inVirtualSelectionMode=!1}))}else if("block"==d){var _;e.stop(),u.inVirtualSelectionMode=!0;var E=[],k=function(){var e=u.renderer.pixelToScreenCoordinates(y,v),t=b.screenToDocumentPosition(e.row,e.column,e.offsetX);o(C,e)&&o(t,h.lead)||(C=e,u.selection.moveToPosition(t),u.renderer.scrollCursorIntoView(),u.removeSelectionMarkers(E),E=h.rectangularRangeBlock(C,w),u.$mouseHandler.$clickSelection&&1==E.length&&E[0].isEmpty()&&(E[0]=u.$mouseHandler.$clickSelection.clone()),E.forEach(u.addSelectionMarker,u),u.updateSelectionMarkers())};p&&!l?h.toSingleRange():!p&&l&&(_=h.toOrientedRange(),u.addSelectionMarker(_)),a?w=b.documentToScreenPosition(h.lead):h.moveToPosition(g),C={row:-1,column:-1};var $=k;i.capture(u.container,(function(e){y=e.clientX,v=e.clientY}),(function(e){k(),clearInterval(M),u.removeSelectionMarkers(E),E.length||(E=[h.toOrientedRange()]),_&&(u.removeSelectionMarker(_),h.toSingleRange(_));for(var t=0;t<E.length;t++)h.addRange(E[t]);u.inVirtualSelectionMode=!1,u.$mouseHandler.$clickSelection=null}));var M=setInterval((function(){$()}),20);return e.preventDefault()}}}else 0===c&&e.editor.inMultiSelectMode&&e.editor.exitMultiSelectMode()}})),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],(function(e,t,n){t.defaultCommands=[{name:"addCursorAbove",description:"Add cursor above",exec:function(e){e.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelow",description:"Add cursor below",exec:function(e){e.selectMoreLines(1)},bindKey:{win:"Ctrl-Alt-Down",mac:"Ctrl-Alt-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorAboveSkipCurrent",description:"Add cursor above (skip current)",exec:function(e){e.selectMoreLines(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Up",mac:"Ctrl-Alt-Shift-Up"},scrollIntoView:"cursor",readOnly:!0},{name:"addCursorBelowSkipCurrent",description:"Add cursor below (skip current)",exec:function(e){e.selectMoreLines(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Down",mac:"Ctrl-Alt-Shift-Down"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreBefore",description:"Select more before",exec:function(e){e.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectMoreAfter",description:"Select more after",exec:function(e){e.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextBefore",description:"Select next before",exec:function(e){e.selectMore(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Left",mac:"Ctrl-Alt-Shift-Left"},scrollIntoView:"cursor",readOnly:!0},{name:"selectNextAfter",description:"Select next after",exec:function(e){e.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},scrollIntoView:"cursor",readOnly:!0},{name:"toggleSplitSelectionIntoLines",description:"Split selection into lines",exec:function(e){e.multiSelect.rangeCount>1?e.multiSelect.joinSelections():e.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readOnly:!0},{name:"splitSelectionIntoLines",description:"Split into lines",exec:function(e){e.multiSelect.splitIntoLines()},readOnly:!0},{name:"alignCursors",description:"Align cursors",exec:function(e){e.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"},scrollIntoView:"cursor"},{name:"findAll",description:"Find all",exec:function(e){e.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},scrollIntoView:"cursor",readOnly:!0}],t.multiSelectCommands=[{name:"singleSelection",description:"Single selection",bindKey:"esc",exec:function(e){e.exitMultiSelectMode()},scrollIntoView:"cursor",readOnly:!0,isAvailable:function(e){return e&&e.inMultiSelectMode}}];var i=e("../keyboard/hash_handler").HashHandler;t.keyboardHandler=new i(t.multiSelectCommands)})),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],(function(e,t,n){var i=e("./range_list").RangeList,r=e("./range").Range,o=e("./selection").Selection,a=e("./mouse/multi_select_handler").onMouseDown,s=e("./lib/event"),l=e("./lib/lang"),c=e("./commands/multi_select_commands");t.commands=c.defaultCommands.concat(c.multiSelectCommands);var d=new(0,e("./search").Search),u=e("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(u.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(e,t){if(e){if(!this.inMultiSelectMode&&0===this.rangeCount){var n=this.toOrientedRange();if(this.rangeList.add(n),this.rangeList.add(e),2!=this.rangeList.ranges.length)return this.rangeList.removeAll(),t||this.fromOrientedRange(e);this.rangeList.removeAll(),this.rangeList.add(n),this.$onAddRange(n)}e.cursor||(e.cursor=e.end);var i=this.rangeList.add(e);return this.$onAddRange(e),i.length&&this.$onRemoveRange(i),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),t||this.fromOrientedRange(e)}},this.toSingleRange=function(e){e=e||this.ranges[0];var t=this.rangeList.removeAll();t.length&&this.$onRemoveRange(t),e&&this.fromOrientedRange(e)},this.substractPoint=function(e){var t=this.rangeList.substractPoint(e);if(t)return this.$onRemoveRange(t),t[0]},this.mergeOverlappingRanges=function(){var e=this.rangeList.merge();e.length&&this.$onRemoveRange(e)},this.$onAddRange=function(e){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(e),this._signal("addRange",{range:e})},this.$onRemoveRange=function(e){if(this.rangeCount=this.rangeList.ranges.length,1==this.rangeCount&&this.inMultiSelectMode){var t=this.rangeList.ranges.pop();e.push(t),this.rangeCount=0}for(var n=e.length;n--;){var i=this.ranges.indexOf(e[n]);this.ranges.splice(i,1)}this._signal("removeRange",{ranges:e}),0===this.rangeCount&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),(t=t||this.ranges[0])&&!t.isEqual(this.getRange())&&this.fromOrientedRange(t)},this.$initRangeList=function(){this.rangeList||(this.rangeList=new i,this.ranges=[],this.rangeCount=0)},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){for(var e=this.ranges.length?this.ranges:[this.getRange()],t=[],n=0;n<e.length;n++){var i=e[n],o=i.start.row,a=i.end.row;if(o===a)t.push(i.clone());else{for(t.push(new r(o,i.start.column,o,this.session.getLine(o).length));++o<a;)t.push(this.getLineRange(o,!0));t.push(new r(a,0,a,i.end.column))}0!=n||this.isBackwards()||(t=t.reverse())}for(this.toSingleRange(),n=t.length;n--;)this.addRange(t[n])},this.joinSelections=function(){var e=this.rangeList.ranges,t=e[e.length-1],n=r.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)},this.toggleBlockSelection=function(){if(this.rangeCount>1){var e=this.rangeList.ranges,t=e[e.length-1],n=r.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var i=this.session.documentToScreenPosition(this.cursor),o=this.session.documentToScreenPosition(this.anchor);this.rectangularRangeBlock(i,o).forEach(this.addRange,this)}},this.rectangularRangeBlock=function(e,t,n){var i=[],o=e.column<t.column;if(o)var a=e.column,s=t.column,l=e.offsetX,c=t.offsetX;else a=t.column,s=e.column,l=t.offsetX,c=e.offsetX;var d,u,h,p=e.row<t.row;if(p)var g=e.row,f=t.row;else g=t.row,f=e.row;a<0&&(a=0),g<0&&(g=0),g==f&&(n=!0);for(var m=g;m<=f;m++){var y=r.fromPoints(this.session.screenToDocumentPosition(m,a,l),this.session.screenToDocumentPosition(m,s,c));if(y.isEmpty()){if(d&&(h=d,(u=y.end).row==h.row&&u.column==h.column))break;d=y.end}y.cursor=o?y.start:y.end,i.push(y)}if(p&&i.reverse(),!n){for(var v=i.length-1;i[v].isEmpty()&&v>0;)v--;if(v>0)for(var b=0;i[b].isEmpty();)b++;for(var w=v;w>=b;w--)i[w].isEmpty()&&i.splice(w,1)}return i}}.call(o.prototype);var h=e("./editor").Editor;function p(e){e.$multiselectOnSessionChange||(e.$onAddRange=e.$onAddRange.bind(e),e.$onRemoveRange=e.$onRemoveRange.bind(e),e.$onMultiSelect=e.$onMultiSelect.bind(e),e.$onSingleSelect=e.$onSingleSelect.bind(e),e.$multiselectOnSessionChange=t.onSessionChange.bind(e),e.$checkMultiselectChange=e.$checkMultiselectChange.bind(e),e.$multiselectOnSessionChange(e),e.on("changeSession",e.$multiselectOnSessionChange),e.on("mousedown",a),e.commands.addCommands(c.defaultCommands),function(e){if(e.textInput){var t=e.textInput.getElement(),n=!1;s.addListener(t,"keydown",(function(t){var r=18==t.keyCode&&!(t.ctrlKey||t.shiftKey||t.metaKey);e.$blockSelectEnabled&&r?n||(e.renderer.setMouseCursor("crosshair"),n=!0):n&&i()}),e),s.addListener(t,"keyup",i,e),s.addListener(t,"blur",i,e)}function i(t){n&&(e.renderer.setMouseCursor(""),n=!1)}}(e))}(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(e){e.cursor||(e.cursor=e.end);var t=this.getSelectionStyle();return e.marker=this.session.addMarker(e,"ace_selection",t),this.session.$selectionMarkers.push(e),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,e},this.removeSelectionMarker=function(e){if(e.marker){this.session.removeMarker(e.marker);var t=this.session.$selectionMarkers.indexOf(e);-1!=t&&this.session.$selectionMarkers.splice(t,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length}},this.removeSelectionMarkers=function(e){for(var t=this.session.$selectionMarkers,n=e.length;n--;){var i=e[n];if(i.marker){this.session.removeMarker(i.marker);var r=t.indexOf(i);-1!=r&&t.splice(r,1)}}this.session.selectionMarkerCount=t.length},this.$onAddRange=function(e){this.addSelectionMarker(e.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(e){this.removeSelectionMarkers(e.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(e){this.inMultiSelectMode||(this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(c.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers())},this.$onSingleSelect=function(e){this.session.multiSelect.inVirtualMode||(this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(c.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection"))},this.$onMultiSelectExec=function(e){var t=e.command,n=e.editor;if(n.multiSelect){if(t.multiSelectAction)"forEach"==t.multiSelectAction?i=n.forEachSelection(t,e.args):"forEachLine"==t.multiSelectAction?i=n.forEachSelection(t,e.args,!0):"single"==t.multiSelectAction?(n.exitMultiSelectMode(),i=t.exec(n,e.args||{})):i=t.multiSelectAction(n,e.args||{});else{var i=t.exec(n,e.args||{});n.multiSelect.addRange(n.multiSelect.toOrientedRange()),n.multiSelect.mergeOverlappingRanges()}return i}},this.forEachSelection=function(e,t,n){if(!this.inVirtualSelectionMode){var i,r=n&&n.keepOrder,a=1==n||n&&n.$byLines,s=this.session,l=this.selection,c=l.rangeList,d=(r?l:c).ranges;if(!d.length)return e.exec?e.exec(this,t||{}):e(this,t||{});var u=l._eventRegistry;l._eventRegistry={};var h=new o(s);this.inVirtualSelectionMode=!0;for(var p=d.length;p--;){if(a)for(;p>0&&d[p].start.row==d[p-1].end.row;)p--;h.fromOrientedRange(d[p]),h.index=p,this.selection=s.selection=h;var g=e.exec?e.exec(this,t||{}):e(this,t||{});i||void 0===g||(i=g),h.toOrientedRange(d[p])}h.detach(),this.selection=s.selection=l,this.inVirtualSelectionMode=!1,l._eventRegistry=u,l.mergeOverlappingRanges(),l.ranges[0]&&l.fromOrientedRange(l.ranges[0]);var f=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),f&&f.from==f.to&&this.renderer.animateScrolling(f.from),i}},this.exitMultiSelectMode=function(){this.inMultiSelectMode&&!this.inVirtualSelectionMode&&this.multiSelect.toSingleRange()},this.getSelectedText=function(){var e="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){for(var t=this.multiSelect.rangeList.ranges,n=[],i=0;i<t.length;i++)n.push(this.session.getTextRange(t[i]));var r=this.session.getDocument().getNewLineCharacter();(e=n.join(r)).length==(n.length-1)*r.length&&(e="")}else this.selection.isEmpty()||(e=this.session.getTextRange(this.getSelectionRange()));return e},this.$checkMultiselectChange=function(e,t){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var n=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&t==this.multiSelect.anchor)return;var i=t==this.multiSelect.anchor?n.cursor==n.start?n.end:n.start:n.cursor;i.row!=t.row||this.session.$clipPositionToDocument(i.row,i.column).column!=t.column?this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange()):this.multiSelect.mergeOverlappingRanges()}},this.findAll=function(e,t,n){if((t=t||{}).needle=e||t.needle,null==t.needle){var i=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();t.needle=this.session.getTextRange(i)}this.$search.set(t);var r=this.$search.findAll(this.session);if(!r.length)return 0;var o=this.multiSelect;n||o.toSingleRange(r[0]);for(var a=r.length;a--;)o.addRange(r[a],!0);return i&&o.rangeList.rangeAtPoint(i.start)&&o.addRange(i,!0),r.length},this.selectMoreLines=function(e,t){var n=this.selection.toOrientedRange(),i=n.cursor==n.end,o=this.session.documentToScreenPosition(n.cursor);this.selection.$desiredColumn&&(o.column=this.selection.$desiredColumn);var a,s=this.session.screenToDocumentPosition(o.row+e,o.column);if(n.isEmpty())c=s;else var l=this.session.documentToScreenPosition(i?n.end:n.start),c=this.session.screenToDocumentPosition(l.row+e,l.column);if(i?(a=r.fromPoints(s,c)).cursor=a.start:(a=r.fromPoints(c,s)).cursor=a.end,a.desiredColumn=o.column,this.selection.inMultiSelectMode){if(t)var d=n.cursor}else this.selection.addRange(n);this.selection.addRange(a),d&&this.selection.substractPoint(d)},this.transposeSelections=function(e){for(var t=this.session,n=t.multiSelect,i=n.ranges,r=i.length;r--;)if((s=i[r]).isEmpty()){var o=t.getWordRange(s.start.row,s.start.column);s.start.row=o.start.row,s.start.column=o.start.column,s.end.row=o.end.row,s.end.column=o.end.column}n.mergeOverlappingRanges();var a=[];for(r=i.length;r--;){var s=i[r];a.unshift(t.getTextRange(s))}for(e<0?a.unshift(a.pop()):a.push(a.shift()),r=i.length;r--;){var l=(s=i[r]).clone();t.replace(s,a[r]),s.start.row=l.start.row,s.start.column=l.start.column}n.fromOrientedRange(n.ranges[0])},this.selectMore=function(e,t,n){var i=this.session,r=i.multiSelect.toOrientedRange();if(!r.isEmpty()||((r=i.getWordRange(r.start.row,r.start.column)).cursor=-1==e?r.start:r.end,this.multiSelect.addRange(r),!n)){var o=i.getTextRange(r),a=function(e,t,n){return d.$options.wrap=!0,d.$options.needle=t,d.$options.backwards=-1==n,d.find(e)}(i,o,e);a&&(a.cursor=-1==e?a.start:a.end,this.session.unfold(a),this.multiSelect.addRange(a),this.renderer.scrollCursorIntoView(null,.5)),t&&this.multiSelect.substractPoint(r.cursor)}},this.alignCursors=function(){var e=this.session,t=e.multiSelect,n=t.ranges,i=-1,o=n.filter((function(e){if(e.cursor.row==i)return!0;i=e.cursor.row}));if(n.length&&o.length!=n.length-1){o.forEach((function(e){t.substractPoint(e.cursor)}));var a=0,s=1/0,c=n.map((function(t){var n=t.cursor,i=e.getLine(n.row).substr(n.column).search(/\S/g);return-1==i&&(i=0),n.column>a&&(a=n.column),i<s&&(s=i),i}));n.forEach((function(t,n){var i=t.cursor,o=a-i.column,d=c[n]-s;o>d?e.insert(i,l.stringRepeat(" ",o-d)):e.remove(new r(i.row,i.column,i.row,i.column-o+d)),t.start.column=t.end.column=a,t.start.row=t.end.row=i.row,t.cursor=t.end})),t.fromOrientedRange(n[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}else{var d=this.selection.getRange(),u=d.start.row,h=d.end.row,p=u==h;if(p){var g,f=this.session.getLength();do{g=this.session.getLine(h)}while(/[=:]/.test(g)&&++h<f);do{g=this.session.getLine(u)}while(/[=:]/.test(g)&&--u>0);u<0&&(u=0),h>=f&&(h=f-1)}var m=this.session.removeFullLines(u,h);m=this.$reAlignText(m,p),this.session.insert({row:u,column:0},m.join("\n")+"\n"),p||(d.start.column=0,d.end.column=m[m.length-1].length),this.selection.setRange(d)}},this.$reAlignText=function(e,t){var n,i,r,o=!0,a=!0;return e.map((function(e){var t=e.match(/(\s*)(.*?)(\s*)([=:].*)/);return t?null==n?(n=t[1].length,i=t[2].length,r=t[3].length,t):(n+i+r!=t[1].length+t[2].length+t[3].length&&(a=!1),n!=t[1].length&&(o=!1),n>t[1].length&&(n=t[1].length),i<t[2].length&&(i=t[2].length),r>t[3].length&&(r=t[3].length),t):[e]})).map(t?c:o?a?function(e){return e[2]?s(n+i-e[2].length)+e[2]+s(r)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}:c:function(e){return e[2]?s(n)+e[2]+s(r)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]});function s(e){return l.stringRepeat(" ",e)}function c(e){return e[2]?s(n)+e[2]+s(i-e[2].length+r)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}}}).call(h.prototype),t.onSessionChange=function(e){var t=e.session;t&&!t.multiSelect&&(t.$selectionMarkers=[],t.selection.$initRangeList(),t.multiSelect=t.selection),this.multiSelect=t&&t.multiSelect;var n=e.oldSession;n&&(n.multiSelect.off("addRange",this.$onAddRange),n.multiSelect.off("removeRange",this.$onRemoveRange),n.multiSelect.off("multiSelect",this.$onMultiSelect),n.multiSelect.off("singleSelect",this.$onSingleSelect),n.multiSelect.lead.off("change",this.$checkMultiselectChange),n.multiSelect.anchor.off("change",this.$checkMultiselectChange)),t&&(t.multiSelect.on("addRange",this.$onAddRange),t.multiSelect.on("removeRange",this.$onRemoveRange),t.multiSelect.on("multiSelect",this.$onMultiSelect),t.multiSelect.on("singleSelect",this.$onSingleSelect),t.multiSelect.lead.on("change",this.$checkMultiselectChange),t.multiSelect.anchor.on("change",this.$checkMultiselectChange)),t&&this.inMultiSelectMode!=t.selection.inMultiSelectMode&&(t.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())},t.MultiSelect=p,e("./config").defineOptions(h.prototype,"editor",{enableMultiselect:{set:function(e){p(this),e?this.on("mousedown",a):this.off("mousedown",a)},value:!0},enableBlockSelect:{set:function(e){this.$blockSelectEnabled=e},value:!0}})})),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var i=e("../../range").Range,r=t.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(e,t,n){var i=e.getLine(n);return this.foldingStartMarker.test(i)?"start":"markbeginend"==t&&this.foldingStopMarker&&this.foldingStopMarker.test(i)?"end":""},this.getFoldWidgetRange=function(e,t,n){return null},this.indentationBlock=function(e,t,n){var r=/\S/,o=e.getLine(t),a=o.search(r);if(-1!=a){for(var s=n||o.length,l=e.getLength(),c=t,d=t;++t<l;){var u=e.getLine(t).search(r);if(-1!=u){if(u<=a){var h=e.getTokenAt(t,0);if(!h||"string"!==h.type)break}d=t}}if(d>c){var p=e.getLine(d).length;return new i(c,s,d,p)}}},this.openingBracketBlock=function(e,t,n,r,o){var a={row:n,column:r+1},s=e.$findClosingBracket(t,a,o);if(s){var l=e.foldWidgets[s.row];return null==l&&(l=e.getFoldWidget(s.row)),"start"==l&&s.row>a.row&&(s.row--,s.column=e.getLine(s.row).length),i.fromPoints(a,s)}},this.closingBracketBlock=function(e,t,n,r,o){var a={row:n,column:r},s=e.$findOpeningBracket(t,a);if(s)return s.column++,a.column--,i.fromPoints(s,a)}}).call(r.prototype)})),ace.define("ace/ext/error_marker",["require","exports","module","ace/lib/dom","ace/range","ace/config"],(function(e,t,n){"use strict";var i=e("../lib/dom"),r=e("../range").Range,o=e("../config").nls;t.showErrorMarker=function(e,t){var n=e.session,a=e.getCursorPosition(),s=a.row,l=n.widgetManager.getWidgetsAtRow(s).filter((function(e){return"errorMarker"==e.type}))[0];l?l.destroy():s-=t;var c,d=function(e,t,n){var i=e.getAnnotations().sort(r.comparePoints);if(i.length){var o=function(e,t,n){for(var i=0,r=e.length-1;i<=r;){var o=i+r>>1,a=n(t,e[o]);if(a>0)i=o+1;else{if(!(a<0))return o;r=o-1}}return-(i+1)}(i,{row:t,column:-1},r.comparePoints);o<0&&(o=-o-1),o>=i.length?o=n>0?0:i.length-1:0===o&&n<0&&(o=i.length-1);var a=i[o];if(a&&n){if(a.row===t){do{a=i[o+=n]}while(a&&a.row===t);if(!a)return i.slice()}var s=[];t=a.row;do{s[n<0?"unshift":"push"](a),a=i[o+=n]}while(a&&a.row==t);return s.length&&s}}}(n,s,t);if(d){var u=d[0];a.column=(u.pos&&"number"!=typeof u.column?u.pos.sc:u.column)||0,a.row=u.row,c=e.renderer.$gutterLayer.$annotations[a.row]}else{if(l)return;c={displayText:[o("error-marker.good-state","Looks good!")],className:"ace_ok"}}e.session.unfold(a.row),e.selection.moveToPosition(a);var h={row:a.row,fixedWidth:!0,coverGutter:!0,el:i.createElement("div"),type:"errorMarker"},p=h.el.appendChild(i.createElement("div")),g=h.el.appendChild(i.createElement("div"));g.className="error_widget_arrow "+c.className;var f=e.renderer.$cursorLayer.getPixelPosition(a).left;g.style.left=f+e.renderer.gutterWidth-5+"px",h.el.className="error_widget_wrapper",p.className="error_widget "+c.className,c.displayText.forEach((function(e,t){p.appendChild(i.createTextNode(e)),t<c.displayText.length-1&&p.appendChild(i.createElement("br"))})),p.appendChild(i.createElement("div"));var m=function(e,t,n){if(0===t&&("esc"===n||"return"===n))return h.destroy(),{command:"null"}};h.destroy=function(){e.$mouseHandler.isMousePressed||(e.keyBinding.removeKeyboardHandler(m),n.widgetManager.removeLineWidget(h),e.off("changeSelection",h.destroy),e.off("changeSession",h.destroy),e.off("mouseup",h.destroy),e.off("change",h.destroy))},e.keyBinding.addKeyboardHandler(m),e.on("changeSelection",h.destroy),e.on("changeSession",h.destroy),e.on("mouseup",h.destroy),e.on("change",h.destroy),e.session.widgetManager.addLineWidget(h),h.el.onmousedown=e.focus.bind(e),e.renderer.scrollCursorIntoView(null,.5,{bottom:h.el.offsetHeight})},i.importCssString("\n .error_widget_wrapper {\n background: inherit;\n color: inherit;\n border:none\n }\n .error_widget {\n border-top: solid 2px;\n border-bottom: solid 2px;\n margin: 5px 0;\n padding: 10px 40px;\n white-space: pre-wrap;\n }\n .error_widget.ace_error, .error_widget_arrow.ace_error{\n border-color: #ff5a5a\n }\n .error_widget.ace_warning, .error_widget_arrow.ace_warning{\n border-color: #F1D817\n }\n .error_widget.ace_info, .error_widget_arrow.ace_info{\n border-color: #5a5a5a\n }\n .error_widget.ace_ok, .error_widget_arrow.ace_ok{\n border-color: #5aaa5a\n }\n .error_widget_arrow {\n position: absolute;\n border: solid 5px;\n border-top-color: transparent!important;\n border-right-color: transparent!important;\n border-left-color: transparent!important;\n top: -5px;\n }\n","error_marker.css",!1)})),ace.define("ace/ace",["require","exports","module","ace/lib/dom","ace/range","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config","ace/loader_build"],(function(e,t,n){"use strict";e("./loader_build")(t);var i=e("./lib/dom"),r=e("./range").Range,o=e("./editor").Editor,a=e("./edit_session").EditSession,s=e("./undomanager").UndoManager,l=e("./virtual_renderer").VirtualRenderer;e("./worker/worker_client"),e("./keyboard/hash_handler"),e("./placeholder"),e("./multi_select"),e("./mode/folding/fold_mode"),e("./theme/textmate"),e("./ext/error_marker"),t.config=e("./config"),t.edit=function(e,n){if("string"==typeof e){var r=e;if(!(e=document.getElementById(r)))throw new Error("ace.edit can't find div #"+r)}if(e&&e.env&&e.env.editor instanceof o)return e.env.editor;var a="";if(e&&/input|textarea/i.test(e.tagName)){var s=e;a=s.value,e=i.createElement("pre"),s.parentNode.replaceChild(e,s)}else e&&(a=e.textContent,e.innerHTML="");var c=t.createEditSession(a),d=new o(new l(e),c,n),u={document:c,editor:d,onResize:d.resize.bind(d,null)};return s&&(u.textarea=s),d.on("destroy",(function(){u.editor.container.env=null})),d.container.env=d.env=u,d},t.createEditSession=function(e,t){var n=new a(e,t);return n.setUndoManager(new s),n},t.Range=r,t.Editor=o,t.EditSession=a,t.UndoManager=s,t.VirtualRenderer=l;var c=t.config.version;t.version=c})),ace.require(["ace/ace"],(function(t){t&&(t.config.init(!0),t.define=ace.define);var n=function(){return this}();for(var i in n||"undefined"==typeof window||(n=window),n||"undefined"==typeof self||(n=self),n.ace||(n.ace=t),t)t.hasOwnProperty(i)&&(n.ace[i]=t[i]);n.ace.default=n.ace,e&&(e.exports=n.ace)}))},997:(e,t,n)=>{e=n.nmd(e),ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"],(function(e,t,n){"use strict";var i=e("../lib/oop"),r=(e("../lib/lang"),e("./text_highlight_rules").TextHighlightRules),o=t.supportType="align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|max-zoom|min-height|min-width|min-zoom|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|user-select|user-zoom|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index",a=t.supportFunction="rgb|rgba|url|attr|counter|counters",s=t.supportConstant="absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|flex-end|flex-start|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero|zoom",l=t.supportConstantColor="aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen",c=t.supportConstantFonts="arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace",d=t.numRe="\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))",u=t.pseudoElements="(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b",h=t.pseudoClasses="(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b",p=function(){var e=this.createKeywordMapper({"support.function":a,"support.constant":s,"support.type":o,"support.constant.color":l,"support.constant.fonts":c},"text",!0);this.$rules={start:[{include:["strings","url","comments"]},{token:"paren.lparen",regex:"\\{",next:"ruleset"},{token:"paren.rparen",regex:"\\}"},{token:"string",regex:"@(?!viewport)",next:"media"},{token:"keyword",regex:"#[a-z0-9-_]+"},{token:"keyword",regex:"%"},{token:"variable",regex:"\\.[a-z0-9-_]+"},{token:"string",regex:":[a-z0-9-_]+"},{token:"constant.numeric",regex:d},{token:"constant",regex:"[a-z0-9-_]+"},{caseInsensitive:!0}],media:[{include:["strings","url","comments"]},{token:"paren.lparen",regex:"\\{",next:"start"},{token:"paren.rparen",regex:"\\}",next:"start"},{token:"string",regex:";",next:"start"},{token:"keyword",regex:"(?:media|supports|document|charset|import|namespace|media|supports|document|page|font|keyframes|viewport|counter-style|font-feature-values|swash|ornaments|annotation|stylistic|styleset|character-variant)"}],comments:[{token:"comment",regex:"\\/\\*",push:[{token:"comment",regex:"\\*\\/",next:"pop"},{defaultToken:"comment"}]}],ruleset:[{regex:"-(webkit|ms|moz|o)-",token:"text"},{token:"punctuation.operator",regex:"[:;]"},{token:"paren.rparen",regex:"\\}",next:"start"},{include:["strings","url","comments"]},{token:["constant.numeric","keyword"],regex:"("+d+")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vmax|vmin|vm|vw|%)"},{token:"constant.numeric",regex:d},{token:"constant.numeric",regex:"#[a-f0-9]{6}"},{token:"constant.numeric",regex:"#[a-f0-9]{3}"},{token:["punctuation","entity.other.attribute-name.pseudo-element.css"],regex:u},{token:["punctuation","entity.other.attribute-name.pseudo-class.css"],regex:h},{include:"url"},{token:e,regex:"\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"},{token:"paren.lparen",regex:"\\{"},{caseInsensitive:!0}],url:[{token:"support.function",regex:"(?:url(:?-prefix)?|domain|regexp)\\(",push:[{token:"support.function",regex:"\\)",next:"pop"},{defaultToken:"string"}]}],strings:[{token:"string.start",regex:"'",push:[{token:"string.end",regex:"'|$",next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]},{token:"string.start",regex:'"',push:[{token:"string.end",regex:'"|$',next:"pop"},{include:"escapes"},{token:"constant.language.escape",regex:/\\$/,consumeLineEnd:!0},{defaultToken:"string"}]}],escapes:[{token:"constant.language.escape",regex:/\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/}]},this.normalizeRules()};i.inherits(p,r),t.CssHighlightRules=p})),ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"],(function(e,t,n){"use strict";var i=e("../range").Range,r=function(){};(function(){this.checkOutdent=function(e,t){return!!/^\s+$/.test(e)&&/^\s*\}/.test(t)},this.autoOutdent=function(e,t){var n=e.getLine(t).match(/^(\s*\})/);if(!n)return 0;var r=n[1].length,o=e.findMatchingBracket({row:t,column:r});if(!o||o.row==t)return 0;var a=this.$getIndent(e.getLine(o.row));e.replace(new i(t,0,t,r-1),a)},this.$getIndent=function(e){return e.match(/^\s*/)[0]}}).call(r.prototype),t.MatchingBraceOutdent=r})),ace.define("ace/mode/css_completions",["require","exports","module"],(function(e,t,n){"use strict";var i={background:{"#$0":1},"background-color":{"#$0":1,transparent:1,fixed:1},"background-image":{"url('/$0')":1},"background-repeat":{repeat:1,"repeat-x":1,"repeat-y":1,"no-repeat":1,inherit:1},"background-position":{bottom:2,center:2,left:2,right:2,top:2,inherit:2},"background-attachment":{scroll:1,fixed:1},"background-size":{cover:1,contain:1},"background-clip":{"border-box":1,"padding-box":1,"content-box":1},"background-origin":{"border-box":1,"padding-box":1,"content-box":1},border:{"solid $0":1,"dashed $0":1,"dotted $0":1,"#$0":1},"border-color":{"#$0":1},"border-style":{solid:2,dashed:2,dotted:2,double:2,groove:2,hidden:2,inherit:2,inset:2,none:2,outset:2,ridged:2},"border-collapse":{collapse:1,separate:1},bottom:{px:1,em:1,"%":1},clear:{left:1,right:1,both:1,none:1},color:{"#$0":1,"rgb(#$00,0,0)":1},cursor:{default:1,pointer:1,move:1,text:1,wait:1,help:1,progress:1,"n-resize":1,"ne-resize":1,"e-resize":1,"se-resize":1,"s-resize":1,"sw-resize":1,"w-resize":1,"nw-resize":1},display:{none:1,block:1,inline:1,"inline-block":1,"table-cell":1},"empty-cells":{show:1,hide:1},float:{left:1,right:1,none:1},"font-family":{Arial:2,"Comic Sans MS":2,Consolas:2,"Courier New":2,Courier:2,Georgia:2,Monospace:2,"Sans-Serif":2,"Segoe UI":2,Tahoma:2,"Times New Roman":2,"Trebuchet MS":2,Verdana:1},"font-size":{px:1,em:1,"%":1},"font-weight":{bold:1,normal:1},"font-style":{italic:1,normal:1},"font-variant":{normal:1,"small-caps":1},height:{px:1,em:1,"%":1},left:{px:1,em:1,"%":1},"letter-spacing":{normal:1},"line-height":{normal:1},"list-style-type":{none:1,disc:1,circle:1,square:1,decimal:1,"decimal-leading-zero":1,"lower-roman":1,"upper-roman":1,"lower-greek":1,"lower-latin":1,"upper-latin":1,georgian:1,"lower-alpha":1,"upper-alpha":1},margin:{px:1,em:1,"%":1},"margin-right":{px:1,em:1,"%":1},"margin-left":{px:1,em:1,"%":1},"margin-top":{px:1,em:1,"%":1},"margin-bottom":{px:1,em:1,"%":1},"max-height":{px:1,em:1,"%":1},"max-width":{px:1,em:1,"%":1},"min-height":{px:1,em:1,"%":1},"min-width":{px:1,em:1,"%":1},overflow:{hidden:1,visible:1,auto:1,scroll:1},"overflow-x":{hidden:1,visible:1,auto:1,scroll:1},"overflow-y":{hidden:1,visible:1,auto:1,scroll:1},padding:{px:1,em:1,"%":1},"padding-top":{px:1,em:1,"%":1},"padding-right":{px:1,em:1,"%":1},"padding-bottom":{px:1,em:1,"%":1},"padding-left":{px:1,em:1,"%":1},"page-break-after":{auto:1,always:1,avoid:1,left:1,right:1},"page-break-before":{auto:1,always:1,avoid:1,left:1,right:1},position:{absolute:1,relative:1,fixed:1,static:1},right:{px:1,em:1,"%":1},"table-layout":{fixed:1,auto:1},"text-decoration":{none:1,underline:1,"line-through":1,blink:1},"text-align":{left:1,right:1,center:1,justify:1},"text-transform":{capitalize:1,uppercase:1,lowercase:1,none:1},top:{px:1,em:1,"%":1},"vertical-align":{top:1,bottom:1},visibility:{hidden:1,visible:1},"white-space":{nowrap:1,normal:1,pre:1,"pre-line":1,"pre-wrap":1},width:{px:1,em:1,"%":1},"word-spacing":{normal:1},filter:{"alpha(opacity=$0100)":1},"text-shadow":{"$02px 2px 2px #777":1},"text-overflow":{"ellipsis-word":1,clip:1,ellipsis:1},"-moz-border-radius":1,"-moz-border-radius-topright":1,"-moz-border-radius-bottomright":1,"-moz-border-radius-topleft":1,"-moz-border-radius-bottomleft":1,"-webkit-border-radius":1,"-webkit-border-top-right-radius":1,"-webkit-border-top-left-radius":1,"-webkit-border-bottom-right-radius":1,"-webkit-border-bottom-left-radius":1,"-moz-box-shadow":1,"-webkit-box-shadow":1,transform:{"rotate($00deg)":1,"skew($00deg)":1},"-moz-transform":{"rotate($00deg)":1,"skew($00deg)":1},"-webkit-transform":{"rotate($00deg)":1,"skew($00deg)":1}},r=function(){};(function(){this.completionsDefined=!1,this.defineCompletions=function(){if(document){var e=document.createElement("c").style;for(var t in e)if("string"==typeof e[t]){var n=t.replace(/[A-Z]/g,(function(e){return"-"+e.toLowerCase()}));i.hasOwnProperty(n)||(i[n]=1)}}this.completionsDefined=!0},this.getCompletions=function(e,t,n,i){if(this.completionsDefined||this.defineCompletions(),"ruleset"===e||"ace/mode/scss"==t.$mode.$id){var r=t.getLine(n.row).substr(0,n.column),o=/\([^)]*$/.test(r);return o&&(r=r.substr(r.lastIndexOf("(")+1)),/:[^;]+$/.test(r)?(/([\w\-]+):[^:]*$/.test(r),this.getPropertyValueCompletions(e,t,n,i)):this.getPropertyCompletions(e,t,n,i,o)}return[]},this.getPropertyCompletions=function(e,t,n,r,o){return o=o||!1,Object.keys(i).map((function(e){return{caption:e,snippet:e+": $0"+(o?"":";"),meta:"property",score:1e6}}))},this.getPropertyValueCompletions=function(e,t,n,r){var o=t.getLine(n.row).substr(0,n.column),a=(/([\w\-]+):[^:]*$/.exec(o)||{})[1];if(!a)return[];var s=[];return a in i&&"object"==typeof i[a]&&(s=Object.keys(i[a])),s.map((function(e){return{caption:e,snippet:e,meta:"property value",score:1e6}}))}}).call(r.prototype),t.CssCompletions=r})),ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"],(function(e,t,n){"use strict";var i=e("../../lib/oop"),r=(e("../behaviour").Behaviour,e("./cstyle").CstyleBehaviour),o=e("../../token_iterator").TokenIterator,a=function(){this.inherit(r),this.add("colon","insertion",(function(e,t,n,i,r){if(":"===r&&n.selection.isEmpty()){var a=n.getCursorPosition(),s=new o(i,a.row,a.column),l=s.getCurrentToken();if(l&&l.value.match(/\s+/)&&(l=s.stepBackward()),l&&"support.type"===l.type){var c=i.doc.getLine(a.row);if(":"===c.substring(a.column,a.column+1))return{text:"",selection:[1,1]};if(/^(\s+[^;]|\s*$)/.test(c.substring(a.column)))return{text:":;",selection:[1,1]}}}})),this.add("colon","deletion",(function(e,t,n,i,r){var a=i.doc.getTextRange(r);if(!r.isMultiLine()&&":"===a){var s=n.getCursorPosition(),l=new o(i,s.row,s.column),c=l.getCurrentToken();if(c&&c.value.match(/\s+/)&&(c=l.stepBackward()),c&&"support.type"===c.type&&";"===i.doc.getLine(r.start.row).substring(r.end.column,r.end.column+1))return r.end.column++,r}})),this.add("semicolon","insertion",(function(e,t,n,i,r){if(";"===r&&n.selection.isEmpty()){var o=n.getCursorPosition();if(";"===i.doc.getLine(o.row).substring(o.column,o.column+1))return{text:"",selection:[1,1]}}})),this.add("!important","insertion",(function(e,t,n,i,r){if("!"===r&&n.selection.isEmpty()){var o=n.getCursorPosition(),a=i.doc.getLine(o.row);if(/^\s*(;|}|$)/.test(a.substring(o.column)))return{text:"!important",selection:[10,10]}}}))};i.inherits(a,r),t.CssBehaviour=a})),ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],(function(e,t,n){"use strict";var i=e("../../lib/oop"),r=e("../../range").Range,o=e("./fold_mode").FoldMode,a=t.FoldMode=function(e){e&&(this.foldingStartMarker=new RegExp(this.foldingStartMarker.source.replace(/\|[^|]*?$/,"|"+e.start)),this.foldingStopMarker=new RegExp(this.foldingStopMarker.source.replace(/\|[^|]*?$/,"|"+e.end)))};i.inherits(a,o),function(){this.foldingStartMarker=/([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/,this.foldingStopMarker=/^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/,this.singleLineBlockCommentRe=/^\s*(\/\*).*\*\/\s*$/,this.tripleStarBlockCommentRe=/^\s*(\/\*\*\*).*\*\/\s*$/,this.startRegionRe=/^\s*(\/\*|\/\/)#?region\b/,this._getFoldWidgetBase=this.getFoldWidget,this.getFoldWidget=function(e,t,n){var i=e.getLine(n);if(this.singleLineBlockCommentRe.test(i)&&!this.startRegionRe.test(i)&&!this.tripleStarBlockCommentRe.test(i))return"";var r=this._getFoldWidgetBase(e,t,n);return!r&&this.startRegionRe.test(i)?"start":r},this.getFoldWidgetRange=function(e,t,n,i){var r,o=e.getLine(n);if(this.startRegionRe.test(o))return this.getCommentRegionBlock(e,o,n);if(r=o.match(this.foldingStartMarker)){var a=r.index;if(r[1])return this.openingBracketBlock(e,r[1],n,a);var s=e.getCommentFoldRange(n,a+r[0].length,1);return s&&!s.isMultiLine()&&(i?s=this.getSectionRange(e,n):"all"!=t&&(s=null)),s}return"markbegin"!==t&&(r=o.match(this.foldingStopMarker))?(a=r.index+r[0].length,r[1]?this.closingBracketBlock(e,r[1],n,a):e.getCommentFoldRange(n,a,-1)):void 0},this.getSectionRange=function(e,t){for(var n=e.getLine(t),i=n.search(/\S/),o=t,a=n.length,s=t+=1,l=e.getLength();++t<l;){var c=(n=e.getLine(t)).search(/\S/);if(-1!==c){if(i>c)break;var d=this.getFoldWidgetRange(e,"all",t);if(d){if(d.start.row<=o)break;if(d.isMultiLine())t=d.end.row;else if(i==c)break}s=t}}return new r(o,a,s,e.getLine(s).length)},this.getCommentRegionBlock=function(e,t,n){for(var i=t.search(/\s*$/),o=e.getLength(),a=n,s=/^\s*(?:\/\*|\/\/|--)#?(end)?region\b/,l=1;++n<o;){t=e.getLine(n);var c=s.exec(t);if(c&&(c[1]?l--:l++,!l))break}if(n>a)return new r(a,i,n,t.length)}}.call(a.prototype)})),ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"],(function(e,t,n){"use strict";var i=e("../lib/oop"),r=e("./text").Mode,o=e("./css_highlight_rules").CssHighlightRules,a=e("./matching_brace_outdent").MatchingBraceOutdent,s=e("../worker/worker_client").WorkerClient,l=e("./css_completions").CssCompletions,c=e("./behaviour/css").CssBehaviour,d=e("./folding/cstyle").FoldMode,u=function(){this.HighlightRules=o,this.$outdent=new a,this.$behaviour=new c,this.$completer=new l,this.foldingRules=new d};i.inherits(u,r),function(){this.foldingRules="cStyle",this.blockComment={start:"/*",end:"*/"},this.getNextLineIndent=function(e,t,n){var i=this.$getIndent(t),r=this.getTokenizer().getLineTokens(t,e).tokens;return r.length&&"comment"==r[r.length-1].type||t.match(/^.*\{\s*$/)&&(i+=n),i},this.checkOutdent=function(e,t,n){return this.$outdent.checkOutdent(t,n)},this.autoOutdent=function(e,t,n){this.$outdent.autoOutdent(t,n)},this.getCompletions=function(e,t,n,i){return this.$completer.getCompletions(e,t,n,i)},this.createWorker=function(e){var t=new s(["ace"],"ace/mode/css_worker","Worker");return t.attachToDocument(e.getDocument()),t.on("annotate",(function(t){e.setAnnotations(t.data)})),t.on("terminate",(function(){e.clearAnnotations()})),t},this.$id="ace/mode/css",this.snippetFileId="ace/snippets/css"}.call(u.prototype),t.Mode=u})),ace.require(["ace/mode/css"],(function(t){e&&(e.exports=t)}))}},t={};function n(i){var r=t[i];if(void 0!==r)return r.exports;var o=t[i]={id:i,loaded:!1,exports:{}};return e[i].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}n.amdD=function(){throw new Error("define cannot be used indirect")},n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),(()=>{"use strict";const e=window.wp.blocks,t=JSON.parse('{"apiVersion":2,"name":"ap-block/posts","title":"Advanced Posts","description":"Elevate Your Posts Display with Advanced Layouts","category":"APBlock","keywords":["show posts","embed blog posts","custom posts"],"textdomain":"advanced-post-block","attributes":{"align":{"type":"string","default":"wide"},"layout":{"type":"string","default":"grid"},"subLayout":{"type":"string","default":"default"},"columns":{"type":"object","default":{"desktop":3,"tablet":2,"mobile":1}},"columnGap":{"type":"number","default":15},"rowGap":{"type":"number","default":15},"isContentEqualHight":{"type":"boolean","default":true},"sliderHeight":{"type":"string","default":"350px"},"content":{"type":"object","default":{"height":"auto"}},"postType":{"type":"string","default":"post"},"selectedTaxonomies":{"type":"object","default":{}},"selectedCategories":{"type":"array","default":[]},"selectedTags":{"type":"array","default":[]},"isPostsPerPageAll":{"type":"boolean","default":false},"postsPerPage":{"type":"number","default":12},"postsOrderBy":{"type":"string","default":"date"},"postsOrder":{"type":"string","default":"desc"},"postsOffset":{"type":"number","default":0},"postsInclude":{"type":"array","default":[]},"postsExclude":{"type":"array","default":[]},"isExcludeCurrent":{"type":"boolean","default":false},"isPagination":{"type":"boolean","default":false},"paginationCurrentPage":{"type":"number","default":1},"paginationPrevLabel":{"type":"string","default":"Prev"},"paginationNextLabel":{"type":"string","default":"Next"},"paginationColors":{"type":"object","default":{"color":"#fff","bg":"#4527a4"}},"paginationHovColors":{"type":"object","default":{"color":"#fff","bg":"#8344c5"}},"paginationPadding":{"type":"object","default":{"vertical":"8px","horizontal":"15px"}},"paginationSpacing":{"type":"string","default":"15px"},"contentAlign":{"type":"string","default":"left"},"contentBG":{"type":"object","default":{"color":"#f4f2fc"}},"contentPadding":{"type":"object","default":{"vertical":"20px","horizontal":"25px"}},"border":{"type":"object","default":{"radius":"5px"}},"sliderIsLoop":{"type":"boolean","default":true},"sliderIsTouchMove":{"type":"boolean","default":false},"sliderIsAutoplay":{"type":"boolean","default":true},"sliderAutoplayOptions":{"type":"object","default":{"delay":1.5}},"sliderSpeed":{"type":"number","default":1.5},"sliderEffect":{"type":"string","default":"slide"},"sliderIsPage":{"type":"boolean","default":true},"sliderIsPageClickable":{"type":"boolean","default":true},"sliderIsPageDynamic":{"type":"boolean","default":true},"sliderPageColor":{"type":"string","default":"#4527a4"},"sliderPageWidth":{"type":"string","default":"15px"},"sliderPageHeight":{"type":"string","default":"15px"},"sliderPageBorder":{"type":"object","default":{"radius":"50%"}},"sliderIsPrevNext":{"type":"boolean","default":true},"sliderPrevNextColor":{"type":"string","default":"#4527a4"},"tickerDirection":{"type":"string","default":"up"},"tickerSpeed":{"type":"string","default":"slow"},"tickerInterval":{"type":"number","default":2000},"tickerHeight":{"type":"string","default":"0px"},"tickerVisible":{"type":"number","default":3},"tickerIsMousePause":{"type":"boolean","default":true},"elementsSort":{"type":"array","default":["title","meta"]},"isFImg":{"type":"boolean","default":true},"fImgSize":{"type":"string","default":"full"},"fImgFitting":{"type":"string","default":"cover"},"isFImgLink":{"type":"boolean","default":false},"isTitle":{"type":"boolean","default":true},"isTitleLink":{"type":"boolean","default":true},"titleTypo":{"type":"object","default":{"fontFamily":"Roboto","fontSize":{"desktop":25,"tablet":22,"mobile":20},"googleFontLink":"https://fonts.googleapis.com/css2?family=Roboto&display=swap"}},"titleColor":{"type":"string","default":"#4527a4"},"titleMargin":{"type":"object","default":{"side":4,"bottom":"15px"}},"isMeta":{"type":"boolean","default":true},"isMetaAuthor":{"type":"boolean","default":true},"isMetaAuthorLink":{"type":"boolean","default":true},"metaAuthorIcon":{"type":"string","default":""},"isMetaDate":{"type":"boolean","default":true},"metaDateFormat":{"type":"string","default":"M j, Y"},"metaDateIcon":{"type":"string","default":""},"isMetaCategory":{"type":"boolean","default":true},"metaCategoryIn":{"type":"string","default":"content"},"metaCategoryIcon":{"type":"string","default":""},"metaTaxonomies":{"type":"object","default":{"selected":[]}},"isMetaReadTime":{"type":"boolean","default":false},"metaReadTimeIcon":{"type":"string","default":""},"isMetaReadTimeSec":{"type":"boolean","default":false},"metaReadTimeLabel":{"type":"string","default":"Min read"},"isMetaComment":{"type":"boolean","default":false},"metaCommentIcon":{"type":"string","default":""},"metaTypo":{"type":"object","default":{"fontSize":{"desktop":13,"tablet":13,"mobile":13},"textTransform":"uppercase"}},"metaTextColor":{"type":"string","default":"#333"},"metaLinkColor":{"type":"string","default":"#8344c5"},"metaIconColor":{"type":"string","default":"#4527a4"},"metaColorsOnImage":{"type":"object","default":{"color":"#fff","bg":"#8344c5"}},"metaMargin":{"type":"object","default":{"side":4,"bottom":"15px"}},"isExcerpt":{"type":"boolean","default":true},"isExcerptFromContent":{"type":"boolean","default":false},"isEllipsisOnExcerpt":{"type":"boolean","default":false},"excerptLength":{"type":"number","default":25},"excerptAlign":{"type":"string","default":"justify"},"excerptTypo":{"type":"object","default":{"fontSize":{"desktop":15,"tablet":15,"mobile":15}}},"excerptColor":{"type":"string","default":"#333"},"excerptMargin":{"type":"object","default":{"side":4,"bottom":"10px"}},"isReadMore":{"type":"boolean","default":true},"readMorePosition":{"type":"string","default":"auto"},"readMoreLabel":{"type":"string","default":"Read More"},"isLinkNewTab":{"type":"boolean","default":false},"readMoreAlign":{"type":"string","default":"left"},"readMoreTypo":{"type":"object","default":{"fontSize":{"desktop":14,"tablet":14,"mobile":14},"textTransform":"uppercase","fontWeight":600}},"readMoreColors":{"type":"object","default":{"color":"#fff","bg":"#8344c5"}},"readMoreHovColors":{"type":"object","default":{"color":"#fff","bg":"#4527a4"}},"readMorePadding":{"type":"object","default":{"vertical":"12px","horizontal":"35px"}},"readMoreBorder":{"type":"object","default":{"radius":"3px"}}},"supports":{"align":["wide","full"],"html":false},"example":{"attributes":{"preview":true,"columns":{"desktop":1,"tablet":1,"mobile":1}}},"editorScript":["file:./index.js","wp-api-request","wp-api","easyTicker"],"editorStyle":"file:./index.css","style":"file:./view.css","render":"file:./render.php","viewScript":["file:./view.js","wp-api","wp-util"]}');var i=n(609),r=n.n(i);const o=window.wp.data,a=window.wp.blockEditor,s=(e,t)=>{if(!e)return[];let n=[];const i=e.media_details.sizes;for(const e in i){const r=t.find((t=>t.slug===e));r&&n.push({label:r.name,value:i[e].source_url})}return n},l=()=>{setTimeout((()=>{const e=document.querySelectorAll(".bPlPanelBody:not(.itemPanelBody) > h2 > button");function t(){this.removeEventListener("click",t),e.forEach((e=>{"true"!==e.getAttribute("aria-expanded")||e.isEqualNode(this)||e.click()})),setTimeout((()=>{this.addEventListener("click",t)}),500)}e.forEach((e=>{e.addEventListener("click",t)}))}),500)},c=window.wp.i18n,d=window.wp.components;var u=Symbol.for("immer-nothing"),h=Symbol.for("immer-draftable"),p=Symbol.for("immer-state");function g(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var f=Object.getPrototypeOf;function m(e){return!!e&&!!e[p]}function y(e){return!!e&&(b(e)||Array.isArray(e)||!!e[h]||!!e.constructor?.[h]||_(e)||E(e))}var v=Object.prototype.constructor.toString();function b(e){if(!e||"object"!=typeof e)return!1;const t=f(e);if(null===t)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===v}function w(e,t){0===C(e)?Reflect.ownKeys(e).forEach((n=>{t(n,e[n],e)})):e.forEach(((n,i)=>t(i,n,e)))}function C(e){const t=e[p];return t?t.type_:Array.isArray(e)?1:_(e)?2:E(e)?3:0}function x(e,t){return 2===C(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function S(e,t,n){const i=C(e);2===i?e.set(t,n):3===i?e.add(n):e[t]=n}function _(e){return e instanceof Map}function E(e){return e instanceof Set}function k(e){return e.copy_||e.base_}function $(e,t){if(_(e))return new Map(e);if(E(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=b(e);if(!0===t||"class_only"===t&&!n){const t=Object.getOwnPropertyDescriptors(e);delete t[p];let n=Reflect.ownKeys(t);for(let i=0;i<n.length;i++){const r=n[i],o=t[r];!1===o.writable&&(o.writable=!0,o.configurable=!0),(o.get||o.set)&&(t[r]={configurable:!0,writable:!0,enumerable:o.enumerable,value:e[r]})}return Object.create(f(e),t)}{const t=f(e);if(null!==t&&n)return{...e};const i=Object.create(t);return Object.assign(i,e)}}function M(e,t=!1){return A(e)||m(e)||!y(e)||(C(e)>1&&(e.set=e.add=e.clear=e.delete=T),Object.freeze(e),t&&Object.entries(e).forEach((([e,t])=>M(t,!0)))),e}function T(){g(2)}function A(e){return Object.isFrozen(e)}var L,R={};function O(e){const t=R[e];return t||g(0),t}function I(){return L}function P(e,t){t&&(O("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function N(e){D(e),e.drafts_.forEach(F),e.drafts_=null}function D(e){e===L&&(L=e.parent_)}function z(e){return L={drafts_:[],parent_:L,immer_:e,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function F(e){const t=e[p];0===t.type_||1===t.type_?t.revoke_():t.revoked_=!0}function B(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return void 0!==e&&e!==n?(n[p].modified_&&(N(t),g(4)),y(e)&&(e=H(t,e),t.parent_||j(t,e)),t.patches_&&O("Patches").generateReplacementPatches_(n[p].base_,e,t.patches_,t.inversePatches_)):e=H(t,n,[]),N(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==u?e:void 0}function H(e,t,n){if(A(t))return t;const i=t[p];if(!i)return w(t,((r,o)=>W(e,i,t,r,o,n))),t;if(i.scope_!==e)return t;if(!i.modified_)return j(e,i.base_,!0),i.base_;if(!i.finalized_){i.finalized_=!0,i.scope_.unfinalizedDrafts_--;const t=i.copy_;let r=t,o=!1;3===i.type_&&(r=new Set(t),t.clear(),o=!0),w(r,((r,a)=>W(e,i,t,r,a,n,o))),j(e,t,!1),n&&e.patches_&&O("Patches").generatePatches_(i,n,e.patches_,e.inversePatches_)}return i.copy_}function W(e,t,n,i,r,o,a){if(m(r)){const a=H(e,r,o&&t&&3!==t.type_&&!x(t.assigned_,i)?o.concat(i):void 0);if(S(n,i,a),!m(a))return;e.canAutoFreeze_=!1}else a&&n.add(r);if(y(r)&&!A(r)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;H(e,r),t&&t.scope_.parent_||"symbol"==typeof i||!Object.prototype.propertyIsEnumerable.call(n,i)||j(e,r)}}function j(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&M(t,n)}var G={get(e,t){if(t===p)return e;const n=k(e);if(!x(n,t))return function(e,t,n){const i=K(t,n);return i?"value"in i?i.value:i.get?.call(e.draft_):void 0}(e,n,t);const i=n[t];return e.finalized_||!y(i)?i:i===U(e.base_,t)?(q(e),e.copy_[t]=Q(i,e)):i},has:(e,t)=>t in k(e),ownKeys:e=>Reflect.ownKeys(k(e)),set(e,t,n){const i=K(k(e),t);if(i?.set)return i.set.call(e.draft_,n),!0;if(!e.modified_){const i=U(k(e),t),a=i?.[p];if(a&&a.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(((r=n)===(o=i)?0!==r||1/r==1/o:r!=r&&o!=o)&&(void 0!==n||x(e.base_,t)))return!0;q(e),Y(e)}var r,o;return e.copy_[t]===n&&(void 0!==n||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==U(e.base_,t)||t in e.base_?(e.assigned_[t]=!1,q(e),Y(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0),getOwnPropertyDescriptor(e,t){const n=k(e),i=Reflect.getOwnPropertyDescriptor(n,t);return i?{writable:!0,configurable:1!==e.type_||"length"!==t,enumerable:i.enumerable,value:n[t]}:i},defineProperty(){g(11)},getPrototypeOf:e=>f(e.base_),setPrototypeOf(){g(12)}},V={};function U(e,t){const n=e[p];return(n?k(n):e)[t]}function K(e,t){if(!(t in e))return;let n=f(e);for(;n;){const e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=f(n)}}function Y(e){e.modified_||(e.modified_=!0,e.parent_&&Y(e.parent_))}function q(e){e.copy_||(e.copy_=$(e.base_,e.scope_.immer_.useStrictShallowCopy_))}function Q(e,t){const n=_(e)?O("MapSet").proxyMap_(e,t):E(e)?O("MapSet").proxySet_(e,t):function(e,t){const n=Array.isArray(e),i={type_:n?1:0,scope_:t?t.scope_:I(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let r=i,o=G;n&&(r=[i],o=V);const{revoke:a,proxy:s}=Proxy.revocable(r,o);return i.draft_=s,i.revoke_=a,s}(e,t);return(t?t.scope_:I()).drafts_.push(n),n}function X(e){if(!y(e)||A(e))return e;const t=e[p];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=$(e,t.scope_.immer_.useStrictShallowCopy_)}else n=$(e,!0);return w(n,((e,t)=>{S(n,e,X(t))})),t&&(t.finalized_=!1),n}w(G,((e,t)=>{V[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),V.deleteProperty=function(e,t){return V.set.call(this,e,t,void 0)},V.set=function(e,t,n){return G.set.call(this,e[0],t,n,e[0])};var Z=new class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){const n=t;t=e;const i=this;return function(e=n,...r){return i.produce(e,(e=>t.call(this,e,...r)))}}let i;if("function"!=typeof t&&g(6),void 0!==n&&"function"!=typeof n&&g(7),y(e)){const r=z(this),o=Q(e,void 0);let a=!0;try{i=t(o),a=!1}finally{a?N(r):D(r)}return P(r,n),B(i,r)}if(!e||"object"!=typeof e){if(i=t(e),void 0===i&&(i=e),i===u&&(i=void 0),this.autoFreeze_&&M(i,!0),n){const t=[],r=[];O("Patches").generateReplacementPatches_(e,i,t,r),n(t,r)}return i}g(1)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,i;return[this.produce(e,t,((e,t)=>{n=e,i=t})),n,i]},"boolean"==typeof e?.autoFreeze&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof e?.useStrictShallowCopy&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){y(e)||g(8),m(e)&&(e=function(e){return m(e)||g(10),X(e)}(e));const t=z(this),n=Q(e,void 0);return n[p].isManual_=!0,D(t),n}finishDraft(e,t){const n=e&&e[p];n&&n.isManual_||g(9);const{scope_:i}=n;return P(i,t),B(void 0,i)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const i=t[n];if(0===i.path.length&&"replace"===i.op){e=i.value;break}}n>-1&&(t=t.slice(n+1));const i=O("Patches").applyPatches_;return m(e)?i(e,t):this.produce(e,(e=>i(e,t)))}},J=Z.produce;Z.produceWithPatches.bind(Z),Z.setAutoFreeze.bind(Z),Z.setUseStrictShallowCopy.bind(Z),Z.applyPatches.bind(Z),Z.createDraft.bind(Z),Z.finishDraft.bind(Z);const ee=[{label:"Default",value:"initial"},{label:"Fixed",value:"fixed"},{label:"Scroll",value:"scroll"}],te=[{label:"Default",value:"initial"},{label:"Center Center",value:"center center"},{label:"Center Left",value:"center left"},{label:"Center Right",value:"center right"},{label:"Top Center",value:"center top"},{label:"Top Left",value:"left top"},{label:"Top Right",value:"left bottom"},{label:"Bottom Center",value:"right center"},{label:"Bottom Left",value:"right top"},{label:"Bottom Right",value:"right bottom"},{label:"Custom",value:"custom"}],ne=[{label:"Default",value:"initial"},{label:"Repeat",value:"repeat"},{label:"Repeat-X",value:"repeat-x"},{label:"Repeat-Y",value:"repeat-y"},{label:"No-Repeat",value:"no-repeat"}],ie=[{label:"Default",value:"initial"},{label:"Auto",value:"auto"},{label:"Cover",value:"cover"},{label:"Contain",value:"contain"},{label:"Custom",value:"custom"}],re=[{label:"px",value:"px"},{label:"%",value:"%"},{label:"em",value:"em"}],oe=[{title:(0,c.__)("Color"),name:"color"},{title:(0,c.__)("Gradient"),name:"gradient"},{title:(0,c.__)("Image"),name:"image"},{title:(0,c.__)("Video"),name:"video"}],ae=((0,o.withSelect)((e=>{const{getDeviceType:t}=e("core/editor");return{device:t()?.toLowerCase()}}))((({name:e="Background",value:t,onChange:n,isVideo:r=!1,device:o})=>{const{type:a="color",color:s="",gradient:l={},img:c={},video:u={}}=t||{},{position:h="center center",xPosition:p,yPosition:g,attachment:f,repeat:m="no-repeat",size:y="cover",customSize:v}=c?.[o]||{};return(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,{className:"mt10 mb10"},e),(0,i.createElement)(d.TabPanel,{className:"bPlTabPanel mini",activeClass:"activeTab",tabs:r?oe:oe.filter((e=>"video"!==e.name)),initialTabName:a,onSelect:e=>n({...t,type:e})},(r=>(0,i.createElement)(i.Fragment,null,"color"===r.name&&(0,i.createElement)(Hn,{className:"mt20",label:`${e} Color`,value:s,onChange:e=>n({...t,color:e})}),"gradient"===r.name&&(0,i.createElement)(vt,{value:l,onChange:e=>n({...t,gradient:e})}),"image"===r.name&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,{className:"mt10 mb10"},e," Image"),(0,i.createElement)(zn,{label:"Upload Image",value:t?.img,onChange:e=>n({...t,img:{...c,url:e.url}}),width:"100%",height:"100%"}),c?.url&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},"Position"),(0,i.createElement)(Me,null)),(0,i.createElement)(d.SelectControl,{value:h,options:te,onChange:e=>n({...t,img:{...c,[o]:{...c[o],position:e}}})}),"custom"===h&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelRow,{className:"mt15"},(0,i.createElement)(Pn,{className:""},"X Position"),(0,i.createElement)(Me,null)),(0,i.createElement)(d.__experimentalUnitControl,{units:re,value:p,min:-2e3,max:2e3,onChange:e=>n({...t,img:{...c,[o]:{...c[o],xPosition:e}}})}),(0,i.createElement)(d.PanelRow,{className:"mt15"},(0,i.createElement)(Pn,{className:""},"Y Position"),(0,i.createElement)(Me,null)),(0,i.createElement)(d.__experimentalUnitControl,{units:re,value:g,min:-2e3,max:2e3,onChange:e=>n({...t,img:{...c,[o]:{...c[o],yPosition:e}}})})),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},"Attachment"),(0,i.createElement)(Me,null)),(0,i.createElement)(d.SelectControl,{value:f,options:ee,onChange:e=>n({...t,img:{...c,[o]:{...c[o],attachment:e}}})}),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},"Repeat"),(0,i.createElement)(Me,null)),(0,i.createElement)(d.SelectControl,{value:m,options:ne,onChange:e=>n({...t,img:{...c,[o]:{...c[o],repeat:e}}})}),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},"Size"),(0,i.createElement)(Me,null)),(0,i.createElement)(d.SelectControl,{value:y,options:ie,onChange:e=>n({...t,img:{...c,[o]:{...c[o],size:e}}})}),"custom"===y&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelRow,{className:"mt15"},(0,i.createElement)(Pn,{className:""},"Width"),(0,i.createElement)(Me,null)),(0,i.createElement)(d.__experimentalUnitControl,{units:re,value:v,min:-2e3,max:2e3,onChange:e=>n({...t,img:{...c,[o]:{...c[o],customSize:e}}})})))),"video"===r.name&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,{className:"mt10 mb10"},e," Video"),(0,i.createElement)(zn,{loop:u?.loop,types:["video/mp4","video/3gpp","video/x-ms-wmv"],isVideo:!0,value:u,onChange:e=>n({...t,video:{...u,url:e.url}}),label:"Upload Video"}),(0,i.createElement)(d.__experimentalInputControl,{style:{marginTop:"10px"},label:"Inline Upload",labelPosition:"top",type:"text",value:u?.url,onChange:e=>n({...t,video:{...u,url:e}}),placeholder:"Insert your video link.."}),u?.url&&(0,i.createElement)(d.ToggleControl,{className:"mt10",label:"Loop",checked:u?.loop,value:u?.loop,onChange:e=>n({...t,video:{...u,loop:e}})}))))))})),(0,c.__)("Normal"),(0,c.__)("Hover"),[{label:"Solid",value:"solid"},{label:"Dashed",value:"dashed"},{label:"Dotted",value:"dotted"},{label:"Double",value:"double"},{label:"Groove",value:"groove"},{label:"Inset",value:"inset"},{label:"Outset",value:"outset"},{label:"Ridge",value:"ridge"}]),se=(e=0)=>({value:"px",label:"px",default:e}),le=(e=0)=>({value:"%",label:"%",default:e}),ce=(e=0)=>({value:"em",label:"em",default:e}),de=(e=0)=>({value:"rem",label:"rem",default:e}),ue=(e=0)=>({value:"vw",label:"vw",default:e}),he=(e=0)=>({value:"vh",label:"vh",default:e}),pe=[{value:"all",label:"All Sides"},{value:"top",label:"Top"},{value:"right",label:"Right"},{value:"bottom",label:"Bottom"},{value:"left",label:"Left"},{value:"topRight",label:"Top Right"},{value:"topBottom",label:"Top Bottom"},{value:"topLeft",label:"Top Left"},{value:"topRightBottom",label:"Top Right Bottom"},{value:"topRightLeft",label:"Top Right Left"},{value:"topBottomLeft",label:"Top Bottom Left"},{value:"rightBottom",label:"Right Bottom"},{value:"rightLeft",label:"Right Left"},{value:"rightBottomLeft",label:"Right Bottom Left"},{value:"bottomLeft",label:"Bottom Left"}],ge=[{name:"Daisy Bush to Fuchsia Blue",gradient:"linear-gradient(135deg, #4527a4, #8344c5)",slug:"daisy-bush-to-fuchsia-blue"},{name:"Reddish Orange to Yellowish Orange",gradient:"linear-gradient(135deg, #fe6601, #fbb040)",slug:"reddish-orange-to-yellowish-orange"},{name:"Tuft Bush to Carnation Pink",gradient:"linear-gradient(135deg, #fed1c7, #fe8dc6)",slug:"tuft-bush-to-carnation-pink"},{name:"Golden Fizz to Yellow Orange",gradient:"linear-gradient(135deg, #f9ed32, #fbb040)",slug:"golden-fizz-to-yellow-orange"},{name:"Light Electric Violet to Electric Violet",gradient:"linear-gradient(135deg, #e100ff, #7f00ff)",slug:"light-electric-violet-to-electric-violet"},{name:"Hot Pink to Violet Red",gradient:"linear-gradient(135deg, #ff7db8, #ee2a7b)",slug:"hot-pink-to-violet-red"},{name:"Spring Green to Azure Radiance",gradient:"linear-gradient(135deg, #00ff8f, #00a1ff)",slug:"spring-green-to-azure-radiance"}],fe=[{label:"Solid",value:"solid"},{label:"Gradient",value:"gradient"}],me=((0,c.__)("Default"),(0,c.__)("Auto"),(0,c.__)("Hidden"),(0,c.__)("Visible"),(0,c.__)("Scroll"),(0,c.__)("None"),(0,c.__)("Fade Up"),(0,c.__)("Fade Down"),(0,c.__)("Fade Left"),(0,c.__)("Fade Right"),(0,c.__)("Fade Up Left"),(0,c.__)("Fade Up Right"),(0,c.__)("Fade Down Left"),(0,c.__)("Fade Down Right"),(0,c.__)("Flip Left"),(0,c.__)("Flip Right"),(0,c.__)("Flip Up"),(0,c.__)("Flip Down"),(0,c.__)("Zoom In"),(0,c.__)("Zoom In Up"),(0,c.__)("Zoom In Down"),(0,c.__)("Zoom In Left"),(0,c.__)("Zoom In Right"),(0,c.__)("Zoom Out"),(0,c.__)("Zoom Out Up"),(0,c.__)("Zoom Out Down"),(0,c.__)("Zoom Out Right"),(0,c.__)("Zoom Out Left"),[{label:"Solid",value:"solid"},{label:"Gradient",value:"gradient"},{label:"Image",value:"image"}]),ye=[{label:"Initial",value:"initial"},{label:"Scroll",value:"scroll"},{label:"Fixed",value:"fixed"},{label:"Local",value:"local"}],ve=[{label:"No Repeat",value:"no-repeat"},{label:"Repeat",value:"repeat"},{label:"Repeat X",value:"repeat-x"},{label:"Repeat Y",value:"repeat-y"}],be=[{label:"Cover",value:"cover"},{label:"Auto",value:"auto"},{label:"Contain",value:"contain"}],we=d.__experimentalGradientPicker||d.GradientPicker,Ce=e=>{const{className:t="",label:n=(0,c.__)("Background"),value:r={},onChange:o,defaults:a={},isSolid:s=!0,isGradient:l=!0,isImage:u=!0}=e,h={type:"solid",color:"#000000b3",gradient:"linear-gradient(135deg, #4527a4, #8344c5)",image:{},position:"center center",attachment:"initial",repeat:"no-repeat",size:"cover",overlayColor:"#000000b3"},p=e=>a?.[e]||h[e],g=e=>r?.[e]||p(e),f=(e,t)=>o({...r,[e]:t}),m=e=>r?.[e]&&r?.[e]!==p(e)?(0,i.createElement)(d.Button,{icon:"image-rotate",className:"bPlResetVal",onClick:()=>(e=>o({...r,[e]:p(e)}))(e)}):null;return(0,i.createElement)(d.PanelRow,{className:`bPlDropdown ${t}`},(0,i.createElement)(Pn,{className:"mb5"},n),(0,i.createElement)(d.Dropdown,{className:"bPlDropdownContainer",contentClassName:"bPlDropdownPopover",popoverProps:{placement:"bottom-end"},renderToggle:({isOpen:e,onToggle:t})=>(0,i.createElement)(d.Button,{icon:"edit",onClick:t,"aria-expanded":e}),renderContent:()=>(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Type:")),(0,i.createElement)(Se,{value:g("type"),onChange:e=>f("type",e),options:me.filter((e=>{switch(e.value){case"solid":return s;case"gradient":return l;case"image":return u;default:return!0}}))})),"solid"===g("type")&&s&&(0,i.createElement)(Ee,{className:"mt20",label:(0,c.__)("Color:"),value:g("color"),onChange:e=>f("color",e),defaultColor:p("color")}),"gradient"===g("type")&&l&&(0,i.createElement)(we,{className:"mt20",value:g("gradient"),onChange:e=>f("gradient",e),gradients:ge}),"image"===g("type")&&u&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,{className:"mb5"},(0,c.__)("Image")),(0,i.createElement)(Dn,{types:["image"],value:g("image"),onChange:e=>f("image",e)}),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Position")),(0,i.createElement)(d.__experimentalAlignmentMatrixControl,{value:g("position"),onChange:e=>f("position",e)}),m("position")),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Attachment:")),(0,i.createElement)(d.SelectControl,{value:g("attachment"),onChange:e=>f("attachment",e),options:ye}),m("attachments")),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Repeat:")),(0,i.createElement)(d.SelectControl,{value:g("repeat"),onChange:e=>f("repeat",e),options:ve}),m("repeat")),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Size:")),(0,i.createElement)(d.SelectControl,{value:g("size"),onChange:e=>f("size",e),options:be}),m("size")),(0,i.createElement)(Ee,{className:"mt20",label:(0,c.__)("Overlay Color:"),value:g("overlayColor"),onChange:e=>f("overlayColor",e),defaultColor:p("overlayColor")})))}))},xe=e=>{const{className:t="",options:n=[],label:r="Button Group",value:o,onChange:a=()=>{},borderRadius:s="30px",height:l,paddingX:c="8px",paddingY:d="4px",fontSize:u="12px",fontWeight:h=400,activeBg:p,activeColor:g="#fff",inactiveColor:f="#000",hoverBg:m,hoverColor:y,style:v}=e,[b,w]=(0,i.useState)(0),C=n.length>0?n:[1,2],x=(0,i.useRef)(null),S=(0,i.useRef)(null),_=Math.floor(99999999*Math.random());return(0,i.useEffect)((()=>{const e=b>n.length-1?b-1:b,t=x.current,i=S.current;o&&C.forEach(((e,t)=>{e.value===o&&w(t)}));const r=t.querySelectorAll(`.bpl-button-group-${_}`),a=Array.from(r)[e],s=a.getBoundingClientRect().height.toFixed(2),l=a.getBoundingClientRect().width.toFixed(2),c=Number(l),d=Number(s);i.style.width=`${c||a.clientWidth}px`,i.style.height=`${d||a.clientHeight}px`,i.style.left=`${a.offsetLeft}px`}),[b,n,o]),(0,i.createElement)("div",{className:t,style:{marginBottom:"10px",...v}},(0,i.createElement)("style",null,`\n\t\t\t\t.bpl-buttonGroupHover-${_}.bpl-button-group-${_}:hover{\n\t\t\t\t\tbackground:${m};\n\t\t\t\t\tcolor:${y};\n\t\t\t\t\ttransition: background 0.3s ease-in-out;\n\t\t\t\t}\n\t\t\t`),(0,i.createElement)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between"}},r&&(0,i.createElement)("label",{style:{fontWeight:500}},r),(0,i.createElement)("div",{ref:x,style:{display:"flex",position:"relative",border:"1px solid #ccc",borderRadius:s}},C.map(((e,t)=>(0,i.createElement)("button",{style:{background:m?b===t?"transparent":"":"transparent",borderRadius:s,height:l,padding:`${d} ${c}`,fontSize:u,zIndex:20,cursor:"pointer",fontWeight:h,color:`${b!==t?f:g}`,border:"none"},key:t,onClick:n=>((e,t,n)=>{w(n),a(t.value)})(0,e,t),className:`${b!==t?`bpl-buttonGroupHover-${_}`:""} bpl-button-group-${_}`},n.length?e.label:`Button ${t+1}`))),(0,i.createElement)("div",{ref:S,style:{background:p||"#4527a4",transition:"left 0.2s ease-in-out",position:"absolute",top:0,left:0,zIndex:10,borderRadius:s}}))))},Se=e=>{const{className:t,label:n="",value:r,onChange:o,options:a,isIcon:s=!1,isTextIcon:l=!1,size:c="compact"}=e,u=({className:e=""})=>(0,i.createElement)(d.ButtonGroup,{className:`bPlBtnGroup ${e||null}`},Object.values(a).map((e=>{const{value:t,icon:n="",label:a="",def:u=""}=e,h=r===t;return(0,i.createElement)(d.Button,{key:t,label:a,showTooltip:!0,tooltipPosition:"top",icon:s?n:null,variant:h?"primary":"","aria-pressed":h,size:c,onClick:()=>o(t,u&&u)},l?n:s?"":a)})));return n?(0,i.createElement)(d.PanelRow,{className:t},(0,i.createElement)(Pn,{className:""},n),(0,i.createElement)(u,null)):(0,i.createElement)(u,{className:t})},_e=(0,o.withSelect)((e=>({themeColors:e("core/block-editor").getSettings().colors})))((({isOpen:e,onClose:t,onChange:n,themeColors:r})=>r.length?(0,i.createElement)("div",{className:"bPlThemeColors"},r.map((({color:t})=>(0,i.createElement)("div",{key:t,className:"bPlColorButtonContainer"},(0,i.createElement)("button",{className:"bPlColorButton","aria-expanded":e,style:{backgroundColor:t||"transparent"},onClick:()=>{n(t)}}))))):null)),Ee=e=>{const{className:t="",label:n=(0,c.__)("Color:"),value:r="",onChange:o,defaultColor:a,disableAlpha:s=!1}=e;return(0,i.createElement)(d.PanelRow,{className:t},(0,i.createElement)(Pn,{className:""},n),(0,i.createElement)(d.Dropdown,{className:"bPlDropdownContainer bPlColor",contentClassName:"bPlDropdownPopover",popoverProps:{placement:"top-end"},renderToggle:({isOpen:e,onToggle:t})=>(0,i.createElement)(i.Fragment,null,(0,i.createElement)("div",{className:"bPlColorButtonContainer"},(0,i.createElement)("button",{className:"bPlColorButton",onClick:t,"aria-expanded":e,style:{backgroundColor:r||"transparent"}})),a&&a!=r&&(0,i.createElement)(d.Button,{className:"bPlResetVal",icon:"image-rotate",label:(0,c.__)("Reset"),onClick:()=>o(a)})),renderContent:({isOpen:e,onClose:t})=>(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.ColorPicker,{color:r||"",disableAlpha:s,onChangeComplete:e=>o(`rgba(${e.rgb.r}, ${e.rgb.g}, ${e.rgb.b}, ${e.rgb.a})`)}),(0,i.createElement)(_e,{isOpen:e,onClose:t,onChange:o}))}))},ke=d.__experimentalGradientPicker||d.GradientPicker,$e=e=>{const{className:t="",label:n=(0,c.__)("Colors:"),value:r,onChange:o,defaults:a={}}=e,s={color:"#333",bgType:"solid",bg:"",gradient:"linear-gradient(135deg, #4527a4, #8344c5)"},l=e=>a?.[e]||s[e],u=e=>r?.[e]||l(e),h=(e,t)=>o({...r,[e]:t});return(0,i.createElement)(d.PanelRow,{className:`bPlDropdown ${t}`},(0,i.createElement)(Pn,{className:""},n," ",(0,i.createElement)(d.ColorIndicator,{colorValue:u("color")})," ",(0,i.createElement)(d.ColorIndicator,{colorValue:u("gradient"===u("bgType")?"gradient":"bg")})),(0,i.createElement)(d.Dropdown,{className:"bPlDropdownContainer",contentClassName:"bPlDropdownPopover",popoverProps:{placement:"bottom-end"},renderToggle:({isOpen:e,onToggle:t})=>(0,i.createElement)(d.Button,{icon:"edit",onClick:t,"aria-expanded":e}),renderContent:()=>(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Ee,{label:(0,c.__)("Color:"),value:u("color"),onChange:e=>h("color",e),defaultColor:l("color")}),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Background:")),(0,i.createElement)(Se,{value:u("bgType"),onChange:e=>h("bgType",e),options:fe,size:"small"})),"gradient"===u("bgType")?(0,i.createElement)(ke,{value:u("gradient"),onChange:e=>h("gradient",e),gradients:ge}):(0,i.createElement)(Ee,{label:(0,c.__)("Background Color:"),value:u("bg"),onChange:e=>h("bg",e),defaultColor:l("bg")}))}))};n(579),n(44),n(997),n(144);const Me=(0,window.wp.compose.compose)((0,o.withSelect)((e=>{const{getDeviceType:t}=e("core/editor");return{device:t()?.toLowerCase()}})),(0,o.withDispatch)((e=>({setDevice:t=>e("core/editor").setDeviceType(t)}))))((({style:e,className:t,position:n="horizontal",device:r,setDevice:o,onChange:a=()=>{}})=>(0,i.createElement)("div",{className:`bPlDeviceControl ${t}`,style:{display:"horizontal"===n?"flex":"grid",...e}},[{label:"Desktop",name:"desktop",icon:"dashicons-desktop"},{label:"Tablet",name:"tablet",icon:"dashicons-tablet"},{label:"Mobile",name:"mobile",icon:"dashicons-smartphone"}].map((({label:e,name:t,icon:n},s)=>(0,i.createElement)("button",{key:s,className:t===r?"active":"",onClick:()=>{o(e),a(e.toLowerCase())}},(0,i.createElement)("span",{className:`dashicons ${n} ${t===r?"active":""} `})))))));var Te=Symbol.for("immer-nothing"),Ae=Symbol.for("immer-draftable"),Le=Symbol.for("immer-state");function Re(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Oe=Object.getPrototypeOf;function Ie(e){return!!e&&!!e[Le]}function Pe(e){return!!e&&(De(e)||Array.isArray(e)||!!e[Ae]||!!e.constructor?.[Ae]||We(e)||je(e))}var Ne=Object.prototype.constructor.toString();function De(e){if(!e||"object"!=typeof e)return!1;const t=Oe(e);if(null===t)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===Ne}function ze(e,t){0===Fe(e)?Reflect.ownKeys(e).forEach((n=>{t(n,e[n],e)})):e.forEach(((n,i)=>t(i,n,e)))}function Fe(e){const t=e[Le];return t?t.type_:Array.isArray(e)?1:We(e)?2:je(e)?3:0}function Be(e,t){return 2===Fe(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function He(e,t,n){const i=Fe(e);2===i?e.set(t,n):3===i?e.add(n):e[t]=n}function We(e){return e instanceof Map}function je(e){return e instanceof Set}function Ge(e){return e.copy_||e.base_}function Ve(e,t){if(We(e))return new Map(e);if(je(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=De(e);if(!0===t||"class_only"===t&&!n){const t=Object.getOwnPropertyDescriptors(e);delete t[Le];let n=Reflect.ownKeys(t);for(let i=0;i<n.length;i++){const r=n[i],o=t[r];!1===o.writable&&(o.writable=!0,o.configurable=!0),(o.get||o.set)&&(t[r]={configurable:!0,writable:!0,enumerable:o.enumerable,value:e[r]})}return Object.create(Oe(e),t)}{const t=Oe(e);if(null!==t&&n)return{...e};const i=Object.create(t);return Object.assign(i,e)}}function Ue(e,t=!1){return Ye(e)||Ie(e)||!Pe(e)||(Fe(e)>1&&(e.set=e.add=e.clear=e.delete=Ke),Object.freeze(e),t&&Object.entries(e).forEach((([e,t])=>Ue(t,!0)))),e}function Ke(){Re(2)}function Ye(e){return Object.isFrozen(e)}var qe,Qe={};function Xe(e){const t=Qe[e];return t||Re(0),t}function Ze(){return qe}function Je(e,t){t&&(Xe("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function et(e){tt(e),e.drafts_.forEach(it),e.drafts_=null}function tt(e){e===qe&&(qe=e.parent_)}function nt(e){return qe={drafts_:[],parent_:qe,immer_:e,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function it(e){const t=e[Le];0===t.type_||1===t.type_?t.revoke_():t.revoked_=!0}function rt(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return void 0!==e&&e!==n?(n[Le].modified_&&(et(t),Re(4)),Pe(e)&&(e=ot(t,e),t.parent_||st(t,e)),t.patches_&&Xe("Patches").generateReplacementPatches_(n[Le].base_,e,t.patches_,t.inversePatches_)):e=ot(t,n,[]),et(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==Te?e:void 0}function ot(e,t,n){if(Ye(t))return t;const i=t[Le];if(!i)return ze(t,((r,o)=>at(e,i,t,r,o,n))),t;if(i.scope_!==e)return t;if(!i.modified_)return st(e,i.base_,!0),i.base_;if(!i.finalized_){i.finalized_=!0,i.scope_.unfinalizedDrafts_--;const t=i.copy_;let r=t,o=!1;3===i.type_&&(r=new Set(t),t.clear(),o=!0),ze(r,((r,a)=>at(e,i,t,r,a,n,o))),st(e,t,!1),n&&e.patches_&&Xe("Patches").generatePatches_(i,n,e.patches_,e.inversePatches_)}return i.copy_}function at(e,t,n,i,r,o,a){if(Ie(r)){const a=ot(e,r,o&&t&&3!==t.type_&&!Be(t.assigned_,i)?o.concat(i):void 0);if(He(n,i,a),!Ie(a))return;e.canAutoFreeze_=!1}else a&&n.add(r);if(Pe(r)&&!Ye(r)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;ot(e,r),t&&t.scope_.parent_||"symbol"==typeof i||!Object.prototype.propertyIsEnumerable.call(n,i)||st(e,r)}}function st(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Ue(t,n)}var lt={get(e,t){if(t===Le)return e;const n=Ge(e);if(!Be(n,t))return function(e,t,n){const i=ut(t,n);return i?"value"in i?i.value:i.get?.call(e.draft_):void 0}(e,n,t);const i=n[t];return e.finalized_||!Pe(i)?i:i===dt(e.base_,t)?(pt(e),e.copy_[t]=gt(i,e)):i},has:(e,t)=>t in Ge(e),ownKeys:e=>Reflect.ownKeys(Ge(e)),set(e,t,n){const i=ut(Ge(e),t);if(i?.set)return i.set.call(e.draft_,n),!0;if(!e.modified_){const i=dt(Ge(e),t),a=i?.[Le];if(a&&a.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(((r=n)===(o=i)?0!==r||1/r==1/o:r!=r&&o!=o)&&(void 0!==n||Be(e.base_,t)))return!0;pt(e),ht(e)}var r,o;return e.copy_[t]===n&&(void 0!==n||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==dt(e.base_,t)||t in e.base_?(e.assigned_[t]=!1,pt(e),ht(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0),getOwnPropertyDescriptor(e,t){const n=Ge(e),i=Reflect.getOwnPropertyDescriptor(n,t);return i?{writable:!0,configurable:1!==e.type_||"length"!==t,enumerable:i.enumerable,value:n[t]}:i},defineProperty(){Re(11)},getPrototypeOf:e=>Oe(e.base_),setPrototypeOf(){Re(12)}},ct={};function dt(e,t){const n=e[Le];return(n?Ge(n):e)[t]}function ut(e,t){if(!(t in e))return;let n=Oe(e);for(;n;){const e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=Oe(n)}}function ht(e){e.modified_||(e.modified_=!0,e.parent_&&ht(e.parent_))}function pt(e){e.copy_||(e.copy_=Ve(e.base_,e.scope_.immer_.useStrictShallowCopy_))}function gt(e,t){const n=We(e)?Xe("MapSet").proxyMap_(e,t):je(e)?Xe("MapSet").proxySet_(e,t):function(e,t){const n=Array.isArray(e),i={type_:n?1:0,scope_:t?t.scope_:Ze(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let r=i,o=lt;n&&(r=[i],o=ct);const{revoke:a,proxy:s}=Proxy.revocable(r,o);return i.draft_=s,i.revoke_=a,s}(e,t);return(t?t.scope_:Ze()).drafts_.push(n),n}function ft(e){if(!Pe(e)||Ye(e))return e;const t=e[Le];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=Ve(e,t.scope_.immer_.useStrictShallowCopy_)}else n=Ve(e,!0);return ze(n,((e,t)=>{He(n,e,ft(t))})),t&&(t.finalized_=!1),n}ze(lt,((e,t)=>{ct[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),ct.deleteProperty=function(e,t){return ct.set.call(this,e,t,void 0)},ct.set=function(e,t,n){return lt.set.call(this,e[0],t,n,e[0])};var mt=new class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){const n=t;t=e;const i=this;return function(e=n,...r){return i.produce(e,(e=>t.call(this,e,...r)))}}let i;if("function"!=typeof t&&Re(6),void 0!==n&&"function"!=typeof n&&Re(7),Pe(e)){const r=nt(this),o=gt(e,void 0);let a=!0;try{i=t(o),a=!1}finally{a?et(r):tt(r)}return Je(r,n),rt(i,r)}if(!e||"object"!=typeof e){if(i=t(e),void 0===i&&(i=e),i===Te&&(i=void 0),this.autoFreeze_&&Ue(i,!0),n){const t=[],r=[];Xe("Patches").generateReplacementPatches_(e,i,t,r),n(t,r)}return i}Re(1)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,i;return[this.produce(e,t,((e,t)=>{n=e,i=t})),n,i]},"boolean"==typeof e?.autoFreeze&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof e?.useStrictShallowCopy&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){Pe(e)||Re(8),Ie(e)&&(e=function(e){return Ie(e)||Re(10),ft(e)}(e));const t=nt(this),n=gt(e,void 0);return n[Le].isManual_=!0,tt(t),n}finishDraft(e,t){const n=e&&e[Le];n&&n.isManual_||Re(9);const{scope_:i}=n;return Je(i,t),rt(void 0,i)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const i=t[n];if(0===i.path.length&&"replace"===i.op){e=i.value;break}}n>-1&&(t=t.slice(n+1));const i=Xe("Patches").applyPatches_;return Ie(e)?i(e,t):this.produce(e,(e=>i(e,t)))}},yt=mt.produce;mt.produceWithPatches.bind(mt),mt.setAutoFreeze.bind(mt),mt.setUseStrictShallowCopy.bind(mt),mt.applyPatches.bind(mt),mt.createDraft.bind(mt),mt.finishDraft.bind(mt);const vt=e=>{const{value:t,onChange:n}=e,[r,o]=(0,i.useState)(t||{type:"linear",radialType:"ellipse",colors:[{color:"",position:0},{color:"",position:0}],centerPositions:{x:0,y:0},angel:90}),{type:a,radialType:s,colors:l,centerPositions:c,angel:u}=r,h=(e,t,i)=>{const a=yt(r.colors,(n=>{n[e][t]=i}));o({...r,colors:a}),n({...r,colors:a})};return(0,i.useEffect)((()=>{n(r)}),[r,t]),(0,i.createElement)(i.Fragment,null,(0,i.createElement)(xe,{label:"Gradient Type",value:a,onChange:e=>o({...r,type:e}),options:[{label:"Linear",value:"linear"},{label:"Radial",value:"radial"}]}),"radial"===a&&(0,i.createElement)(xe,{label:"Radial Type",value:s,onChange:e=>o({...r,radialType:e}),options:[{label:"Ellipse",value:"ellipse"},{label:"Circle",value:"circle"}]}),l?.map(((e,t)=>(0,i.createElement)("div",{key:t,style:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:"10px"}},(0,i.createElement)(Ee,{value:e.color,onChange:e=>h(t,"color",e),tooltip:"Color"}),(0,i.createElement)("div",{className:"advExtraMargin",style:{display:"flex",alignItems:"center",gap:"5px"}},(0,i.createElement)(d.Tooltip,{delay:300,text:"Position",placement:"top"},(0,i.createElement)(d.__experimentalNumberControl,{value:e.position,onChange:e=>h(t,"position",e),min:0,max:100})),l.length>2&&(0,i.createElement)(d.Dashicon,{style:{cursor:"pointer",color:"red"},onClick:()=>(e=>{const t=yt(r.colors,(t=>{t.splice(e,1)}));o({...r,colors:t}),n({...r,colors:t})})(t),icon:"trash"}))))),(0,i.createElement)("div",{style:{display:"flex",justifyContent:"center",margin:"10px 0"}},(0,i.createElement)(d.Button,{text:"Add Color",variant:"tertiary",style:{background:"#4527a4",color:"#fff"},icon:"plus",iconPosition:"right",onClick:()=>{const e=yt(r.colors,(e=>{e.push({color:"#f00",position:0})}));o({...r,colors:e}),n({...r,colors:e})}})),"radial"===a?(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.RangeControl,{label:"Center X Position",value:c?.x,onChange:e=>o({...r,centerPositions:{...c,x:e}}),min:0,max:100}),(0,i.createElement)(d.RangeControl,{label:"Center Y Position",value:c?.y,onChange:e=>o({...r,centerPositions:{...c,y:e}}),min:0,max:100})):(0,i.createElement)(d.RangeControl,{label:"Angle",value:u,onChange:e=>o({...r,angel:e}),min:0,max:360}))},bt="#4527a4",wt=(0,i.createElement)("svg",{xmlns:"https://www.w3.org/2000/svg",width:15,height:15,viewBox:"0 0 548.172 548.172"},(0,i.createElement)("path",{fill:bt,d:"M534.75 49.965c-8.945-8.945-19.694-13.422-32.261-13.422H45.681c-12.562 0-23.313 4.477-32.264 13.422C4.471 58.913 0 69.663 0 82.226v310.633c0 12.566 4.471 23.315 13.417 32.265 8.951 8.945 19.702 13.414 32.264 13.414h155.318c0 7.231-1.524 14.661-4.57 22.269-3.044 7.614-6.09 14.273-9.136 19.981-3.042 5.715-4.565 9.897-4.565 12.56 0 4.948 1.807 9.24 5.424 12.847 3.615 3.621 7.898 5.435 12.847 5.435h146.179c4.949 0 9.233-1.813 12.848-5.435 3.62-3.606 5.427-7.898 5.427-12.847 0-2.468-1.526-6.611-4.571-12.415-3.046-5.801-6.092-12.566-9.134-20.267-3.046-7.71-4.569-15.085-4.569-22.128h155.318c12.56 0 23.309-4.469 32.254-13.414 8.949-8.949 13.422-19.698 13.422-32.265V82.226c.003-12.563-4.474-23.313-13.423-32.261zm-23.123 269.803c0 2.475-.903 4.613-2.711 6.424-1.81 1.804-3.952 2.707-6.427 2.707H45.681c-2.473 0-4.615-.903-6.423-2.707-1.807-1.817-2.712-3.949-2.712-6.424V82.226c0-2.475.902-4.615 2.712-6.423 1.809-1.805 3.951-2.712 6.423-2.712h456.815c2.471 0 4.617.904 6.42 2.712 1.808 1.809 2.711 3.949 2.711 6.423v237.542z"})),Ct=(0,i.createElement)("svg",{xmlns:"https://www.w3.org/2000/svg",width:15,height:15,viewBox:"0 0 512 512"},(0,i.createElement)("path",{fill:bt,d:"M394.667 0H117.333C87.936 0 64 23.936 64 53.333v405.333C64 488.064 87.936 512 117.333 512h277.333C424.064 512 448 488.064 448 458.667V53.333C448 23.936 424.064 0 394.667 0zM256 480c-11.755 0-21.333-9.579-21.333-21.333s9.579-21.333 21.333-21.333 21.333 9.579 21.333 21.333S267.755 480 256 480zm149.333-64c0 5.888-4.779 10.667-10.667 10.667H117.333c-5.888 0-10.667-4.779-10.667-10.667V53.333c0-5.888 4.779-10.667 10.667-10.667h277.333c5.888 0 10.667 4.779 10.667 10.667V416z"})),xt=(0,i.createElement)("svg",{xmlns:"https://www.w3.org/2000/svg",width:15,height:15,viewBox:"0 0 503.604 503.604"},(0,i.createElement)("path",{fill:bt,d:"M337.324 0H167.192c-28.924 0-53.5 23.584-53.5 52.5v398.664c0 28.916 24.056 52.44 52.98 52.44l170.412-.184c28.92 0 52.58-23.528 52.58-52.448l.248-398.5C389.908 23.452 366.364 0 337.324 0zM227.68 31.476h49.36c4.336 0 7.868 3.52 7.868 7.868 0 4.348-3.532 7.868-7.868 7.868h-49.36a7.865 7.865 0 01-7.868-7.868 7.865 7.865 0 017.868-7.868zm-29.66 2.504c2.916-2.912 8.224-2.952 11.136 0a7.973 7.973 0 012.324 5.588c0 2.048-.864 4.088-2.324 5.548-1.452 1.46-3.504 2.32-5.548 2.32-2.084 0-4.088-.86-5.588-2.32-1.452-1.456-2.28-3.5-2.28-5.548-.004-2.088.828-4.132 2.28-5.588zm52.752 454.028c-12.984 0-23.544-10.568-23.544-23.548 0-12.984 10.56-23.548 23.544-23.548s23.544 10.564 23.544 23.548c0 12.98-10.564 23.548-23.544 23.548zm114.716-63.1H141.232V74.756h224.256v350.152z"})),St=(0,i.createElement)("svg",{xmlns:"https://www.w3.org/2000/svg",width:14,height:14,viewBox:"0 0 330 330"},(0,i.createElement)("path",{d:"M100.606 229.393c-5.857-5.857-15.355-5.857-21.213 0-5.858 5.857-5.858 15.355 0 21.213l75 75A14.954 14.954 0 00165 330a14.95 14.95 0 0010.606-4.394l75-75c5.858-5.857 5.858-15.355 0-21.213-5.857-5.857-15.355-5.857-21.213 0L180 278.787V51.212l49.394 49.394A14.95 14.95 0 00240 105a14.95 14.95 0 0010.606-4.394c5.858-5.857 5.858-15.355 0-21.213l-75-75c-5.857-5.858-15.355-5.858-21.213 0l-75 75c-5.858 5.857-5.858 15.355 0 21.213 5.857 5.857 15.355 5.857 21.213 0L150 51.212v227.574l-49.394-49.393z"})),_t=((0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 430.848 430.848"},(0,i.createElement)("path",{d:"M286.244,249.537l10.992-45.639c0.035-0.143,0.071-0.285,0.109-0.428c2.909-10.867,11.469-19.426,22.339-22.338 l33.347-8.936c-5.472-6.525-13.678-10.682-22.839-10.682h-9.837c-2.511-7.895-5.7-15.59-9.515-22.957l6.96-6.959 c11.622-11.623,11.622-30.535,0-42.156L296.76,68.4c-5.631-5.629-13.117-8.73-21.079-8.73c-7.961,0-15.447,3.102-21.078,8.732 l-6.96,6.959c-7.369-3.814-15.064-7.004-22.956-9.516V56.01c0-16.436-13.372-29.807-29.808-29.807h-29.758 c-16.436,0-29.808,13.371-29.808,29.807v9.836c-7.893,2.512-15.588,5.701-22.957,9.516l-6.96-6.961 c-5.631-5.629-13.117-8.73-21.078-8.73c-7.961,0-15.447,3.102-21.079,8.732L42.2,89.443c-11.622,11.621-11.622,30.533,0,42.156 l6.959,6.959c-3.815,7.367-7.004,15.063-9.515,22.957h-9.837C13.372,161.516,0,174.887,0,191.324v29.758 c0,16.436,13.372,29.807,29.808,29.807h9.837c2.511,7.895,5.7,15.588,9.515,22.957l-6.96,6.959 c-11.623,11.623-11.623,30.533,0,42.158l21.041,21.039c5.632,5.631,13.118,8.732,21.079,8.732s15.447-3.102,21.077-8.732 l6.96-6.959c7.366,3.815,15.061,7.002,22.957,9.514v9.838c0,16.436,13.372,29.809,29.808,29.809h25.809 c-2.388-5.691-3.644-11.852-3.645-18.209c-0.002-12.572,4.892-24.391,13.781-33.279L286.244,249.537z M180,286.201 c-44.112,0-80-35.887-80-79.998c0-44.113,35.888-80.002,80-80.002s80,35.889,80,80.002C260,250.314,224.112,286.201,180,286.201z"}),(0,i.createElement)("path",{d:"M425.267,218.734l-0.319-0.32c-0.939-0.941-2.189-1.428-3.541-1.469c-1.326,0-2.598,0.525-3.536,1.465l-21.596,21.596 c-3.304,3.305-7.699,5.125-12.375,5.125c-4.676,0-9.072-1.82-12.379-5.129c-3.307-3.305-5.128-7.701-5.128-12.377 c0.001-4.676,1.821-9.072,5.126-12.377l21.596-21.596c0.939-0.939,1.465-2.213,1.464-3.539c-0.001-1.328-0.53-2.6-1.47-3.537 l-0.314-0.313c-3.605-3.605-8.399-5.592-13.499-5.592c-1.665,0-3.325,0.219-4.936,0.65l-44.348,11.885 c-6.568,1.76-11.741,6.932-13.498,13.496c-0.011,0.041-0.021,0.08-0.031,0.121l-11.817,49.063l-87.667,87.666 c-6.528,6.527-10.122,15.207-10.121,24.44c0.002,9.232,3.598,17.91,10.126,24.439l2.088,2.088 c6.528,6.529,15.209,10.125,24.443,10.125h0c9.231,0,17.909-3.594,24.437-10.121l87.667-87.666l49.061-11.816 c0.041-0.01,0.082-0.022,0.122-0.031c6.563-1.758,11.735-6.928,13.497-13.496l11.883-44.352 C431.959,230.598,430.066,223.535,425.267,218.734z M257.26,368.406c-1.888,1.889-4.399,2.93-7.071,2.93 c-2.671,0-5.183-1.041-7.072-2.932c-1.887-1.885-2.928-4.397-2.928-7.068c-0.001-2.672,1.041-5.185,2.931-7.072 c1.886-1.887,4.398-2.928,7.069-2.928c2.672,0,5.184,1.041,7.072,2.93c1.887,1.885,2.928,4.396,2.928,7.068 C260.189,364.006,259.148,366.518,257.26,368.406z M316.194,305.935L274.82,347.31c-1.416,1.416-3.3,2.197-5.303,2.197 c-2.003,0-3.887-0.781-5.303-2.197c-1.417-1.416-2.197-3.299-2.197-5.303s0.78-3.887,2.197-5.303l41.374-41.375 c1.417-1.418,3.3-2.197,5.303-2.197s3.887,0.779,5.303,2.197c1.417,1.416,2.197,3.299,2.197,5.303S317.611,304.519,316.194,305.935 z"})),(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:30,height:30,viewBox:"0 0 448 512"},(0,i.createElement)("path",{d:"M96 0C43 0 0 43 0 96V416c0 53 43 96 96 96H384h32c17.7 0 32-14.3 32-32s-14.3-32-32-32V384c17.7 0 32-14.3 32-32V32c0-17.7-14.3-32-32-32H384 96zm0 384H352v64H96c-17.7 0-32-14.3-32-32s14.3-32 32-32zm32-240c0-8.8 7.2-16 16-16H336c8.8 0 16 7.2 16 16s-7.2 16-16 16H144c-8.8 0-16-7.2-16-16zm16 48H336c8.8 0 16 7.2 16 16s-7.2 16-16 16H144c-8.8 0-16-7.2-16-16s7.2-16 16-16z"}))),Et=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:30,height:30,viewBox:"0 0 512 512"},(0,i.createElement)("path",{d:"M256 48C141.1 48 48 141.1 48 256v40c0 13.3-10.7 24-24 24s-24-10.7-24-24V256C0 114.6 114.6 0 256 0S512 114.6 512 256V400.1c0 48.6-39.4 88-88.1 88L313.6 488c-8.3 14.3-23.8 24-41.6 24H240c-26.5 0-48-21.5-48-48s21.5-48 48-48h32c17.8 0 33.3 9.7 41.6 24l110.4 .1c22.1 0 40-17.9 40-40V256c0-114.9-93.1-208-208-208zM144 208h16c17.7 0 32 14.3 32 32V352c0 17.7-14.3 32-32 32H144c-35.3 0-64-28.7-64-64V272c0-35.3 28.7-64 64-64zm224 0c35.3 0 64 28.7 64 64v48c0 35.3-28.7 64-64 64H352c-17.7 0-32-14.3-32-32V240c0-17.7 14.3-32 32-32h16z"})),kt=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:30,height:30,viewBox:"0 0 576 512"},(0,i.createElement)("path",{d:"M316.9 18C311.6 7 300.4 0 288.1 0s-23.4 7-28.8 18L195 150.3 51.4 171.5c-12 1.8-22 10.2-25.7 21.7s-.7 24.2 7.9 32.7L137.8 329 113.2 474.7c-2 12 3 24.2 12.9 31.3s23 8 33.8 2.3l128.3-68.5 128.3 68.5c10.8 5.7 23.9 4.9 33.8-2.3s14.9-19.3 12.9-31.3L438.5 329 542.7 225.9c8.6-8.5 11.7-21.2 7.9-32.7s-13.7-19.9-25.7-21.7L381.2 150.3 316.9 18z"})),$t=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:30,height:30,viewBox:"0 0 448 512"},(0,i.createElement)("path",{d:"M438.6 278.6c12.5-12.5 12.5-32.8 0-45.3l-160-160c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L338.8 224 32 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l306.7 0L233.4 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l160-160z"})),Mt=((0,i.createElement)("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 448 512",height:"1em",width:"1em",xmlns:"http://www.w3.org/2000/svg"},(0,i.createElement)("path",{d:"M416 208H272V64c0-17.67-14.33-32-32-32h-32c-17.67 0-32 14.33-32 32v144H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h144v144c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32V304h144c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"})),(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:18,height:18,viewBox:"0 0 448 512"},(0,i.createElement)("path",{d:"M384 336H192c-8.8 0-16-7.2-16-16V64c0-8.8 7.2-16 16-16l140.1 0L400 115.9V320c0 8.8-7.2 16-16 16zM192 384H384c35.3 0 64-28.7 64-64V115.9c0-12.7-5.1-24.9-14.1-33.9L366.1 14.1c-9-9-21.2-14.1-33.9-14.1H192c-35.3 0-64 28.7-64 64V320c0 35.3 28.7 64 64 64zM64 128c-35.3 0-64 28.7-64 64V448c0 35.3 28.7 64 64 64H256c35.3 0 64-28.7 64-64V416H272v32c0 8.8-7.2 16-16 16H64c-8.8 0-16-7.2-16-16V192c0-8.8 7.2-16 16-16H96V128H64z"}))),Tt=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:18,height:18,viewBox:"0 0 384 512"},(0,i.createElement)("path",{d:"M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"})),At=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 320 512",width:16,height:16},(0,i.createElement)("path",{d:"M40 352l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40zm192 0l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40zM40 320c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0zM232 192l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40zM40 160c-22.1 0-40-17.9-40-40L0 72C0 49.9 17.9 32 40 32l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0zM232 32l48 0c22.1 0 40 17.9 40 40l0 48c0 22.1-17.9 40-40 40l-48 0c-22.1 0-40-17.9-40-40l0-48c0-22.1 17.9-40 40-40z"})),Lt=((0,i.createElement)("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 512 512",height:"1em",width:"1em",xmlns:"http://www.w3.org/2000/svg"},(0,i.createElement)("path",{d:"M80 368H16a16 16 0 0 0-16 16v64a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16v-64a16 16 0 0 0-16-16zm0-320H16A16 16 0 0 0 0 64v64a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16V64a16 16 0 0 0-16-16zm0 160H16a16 16 0 0 0-16 16v64a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16v-64a16 16 0 0 0-16-16zm416 176H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-320H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16V80a16 16 0 0 0-16-16zm0 160H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"})),({slug:e,docsLink:t})=>(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody bPlHelpPanel",title:(0,c.__)("Help"),initialOpen:!1},(0,i.createElement)("div",{className:"helpItems"},t&&(0,i.createElement)("a",{href:t,target:"_blank",rel:"noreferrer"},_t,(0,i.createElement)("p",null,(0,c.__)("Read Documentation"))),(0,i.createElement)("a",{href:"https://bplugins.com/support",target:"_blank",rel:"noreferrer"},Et,(0,i.createElement)("p",null,(0,c.__)("Contact Support"))),e&&(0,i.createElement)("a",{href:`https://wordpress.org/support/plugin/${e}/reviews/#new-post`,target:"_blank",rel:"noreferrer"},kt,(0,i.createElement)("p",null,(0,c.__)("Rate Plugin"))),(0,i.createElement)("a",{href:"https://bplugins.com/products",target:"_blank",rel:"noreferrer"},$t,(0,i.createElement)("p",null,(0,c.__)("Other Plugins"))))));function Rt(){return Rt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Rt.apply(null,arguments)}function Ot(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function It(e,t){if(e){if("string"==typeof e)return Ot(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ot(e,t):void 0}}function Pt(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,r,o,a,s=[],l=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(i=o.call(n)).done)&&(s.push(i.value),s.length!==t);l=!0);}catch(e){c=!0,r=e}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw r}}return s}}(e,t)||It(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Nt(e){return Nt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Nt(e)}function Dt(e){var t=function(e){if("object"!=Nt(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=Nt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==Nt(t)?t:t+""}function zt(e,t,n){return(t=Dt(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ft(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?Object(arguments[t]):{},i=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&i.push.apply(i,Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),i.forEach((function(t){zt(e,t,n[t])}))}return e}function Bt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ht(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,Dt(i.key),i)}}function Wt(e,t,n){return t&&Ht(e.prototype,t),n&&Ht(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function jt(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Gt(e,t){if(t&&("object"==Nt(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return jt(e)}function Vt(e){return Vt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Vt(e)}function Ut(e,t){return Ut=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Ut(e,t)}function Kt(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ut(e,t)}const Yt=window.ReactDOM;var qt=n(194),Qt=n.n(qt);var Xt=n(135),Zt=n.n(Xt),Jt=function(){function e(){Bt(this,e),zt(this,"refs",{})}return Wt(e,[{key:"add",value:function(e,t){this.refs[e]||(this.refs[e]=[]),this.refs[e].push(t)}},{key:"remove",value:function(e,t){var n=this.getIndex(e,t);-1!==n&&this.refs[e].splice(n,1)}},{key:"isActive",value:function(){return this.active}},{key:"getActive",value:function(){var e=this;return this.refs[this.active.collection].find((function(t){return t.node.sortableInfo.index==e.active.index}))}},{key:"getIndex",value:function(e,t){return this.refs[e].indexOf(t)}},{key:"getOrderedRefs",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.active.collection;return this.refs[e].sort(en)}}]),e}();function en(e,t){return e.node.sortableInfo.index-t.node.sortableInfo.index}function tn(e,t){return Object.keys(e).reduce((function(n,i){return-1===t.indexOf(i)&&(n[i]=e[i]),n}),{})}var nn={end:["touchend","touchcancel","mouseup"],move:["touchmove","mousemove"],start:["touchstart","mousedown"]},rn=function(){if("undefined"==typeof window||"undefined"==typeof document)return"";var e=window.getComputedStyle(document.documentElement,"")||["-moz-hidden-iframe"],t=(Array.prototype.slice.call(e).join("").match(/-(moz|webkit|ms)-/)||""===e.OLink&&["","o"])[1];return"ms"===t?"ms":t&&t.length?t[0].toUpperCase()+t.substr(1):""}();function on(e,t){Object.keys(t).forEach((function(n){e.style[n]=t[n]}))}function an(e,t){e.style["".concat(rn,"Transform")]=null==t?"":"translate3d(".concat(t.x,"px,").concat(t.y,"px,0)")}function sn(e,t){e.style["".concat(rn,"TransitionDuration")]=null==t?"":"".concat(t,"ms")}function ln(e,t){for(;e;){if(t(e))return e;e=e.parentNode}return null}function cn(e,t,n){return Math.max(e,Math.min(n,t))}function dn(e){return"px"===e.substr(-2)?parseFloat(e):0}function un(e,t){var n=t.displayName||t.name;return n?"".concat(e,"(").concat(n,")"):e}function hn(e,t){var n=e.getBoundingClientRect();return{top:n.top+t.top,left:n.left+t.left}}function pn(e){return e.touches&&e.touches.length?{x:e.touches[0].pageX,y:e.touches[0].pageY}:e.changedTouches&&e.changedTouches.length?{x:e.changedTouches[0].pageX,y:e.changedTouches[0].pageY}:{x:e.pageX,y:e.pageY}}function gn(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{left:0,top:0};if(e){var i={left:n.left+e.offsetLeft,top:n.top+e.offsetTop};return e.parentNode===t?i:gn(e.parentNode,t,i)}}function fn(e){var t=e.lockOffset,n=e.width,i=e.height,r=t,o=t,a="px";if("string"==typeof t){var s=/^[+-]?\d*(?:\.\d*)?(px|%)$/.exec(t);Qt()(null!==s,'lockOffset value should be a number or a string of a number followed by "px" or "%". Given %s',t),r=parseFloat(t),o=parseFloat(t),a=s[1]}return Qt()(isFinite(r)&&isFinite(o),"lockOffset value should be a finite. Given %s",t),"%"===a&&(r=r*n/100,o=o*i/100),{x:r,y:o}}function mn(e){return e instanceof HTMLElement?function(e){var t=window.getComputedStyle(e),n=/(auto|scroll)/;return["overflow","overflowX","overflowY"].find((function(e){return n.test(t[e])}))}(e)?e:mn(e.parentNode):null}var yn="BUTTON",vn="INPUT",bn="OPTION",wn="TEXTAREA",Cn="SELECT";function xn(e){return null!=e.sortableHandle}var Sn=function(){function e(t,n){Bt(this,e),this.container=t,this.onScrollCallback=n}return Wt(e,[{key:"clear",value:function(){null!=this.interval&&(clearInterval(this.interval),this.interval=null)}},{key:"update",value:function(e){var t=this,n=e.translate,i=e.minTranslate,r=e.maxTranslate,o=e.width,a=e.height,s={x:0,y:0},l={x:1,y:1},c=this.container,d=c.scrollTop,u=c.scrollLeft,h=c.scrollHeight,p=c.scrollWidth,g=0===d,f=h-d-c.clientHeight==0,m=0===u,y=p-u-c.clientWidth==0;n.y>=r.y-a/2&&!f?(s.y=1,l.y=10*Math.abs((r.y-a/2-n.y)/a)):n.x>=r.x-o/2&&!y?(s.x=1,l.x=10*Math.abs((r.x-o/2-n.x)/o)):n.y<=i.y+a/2&&!g?(s.y=-1,l.y=10*Math.abs((n.y-a/2-i.y)/a)):n.x<=i.x+o/2&&!m&&(s.x=-1,l.x=10*Math.abs((n.x-o/2-i.x)/o)),this.interval&&(this.clear(),this.isAutoScrolling=!1),0===s.x&&0===s.y||(this.interval=setInterval((function(){t.isAutoScrolling=!0;var e={left:l.x*s.x,top:l.y*s.y};t.container.scrollTop+=e.top,t.container.scrollLeft+=e.left,t.onScrollCallback(e)}),5))}}]),e}(),_n={axis:Zt().oneOf(["x","y","xy"]),contentWindow:Zt().any,disableAutoscroll:Zt().bool,distance:Zt().number,getContainer:Zt().func,getHelperDimensions:Zt().func,helperClass:Zt().string,helperContainer:Zt().oneOfType([Zt().func,"undefined"==typeof HTMLElement?Zt().any:Zt().instanceOf(HTMLElement)]),hideSortableGhost:Zt().bool,keyboardSortingTransitionDuration:Zt().number,lockAxis:Zt().string,lockOffset:Zt().oneOfType([Zt().number,Zt().string,Zt().arrayOf(Zt().oneOfType([Zt().number,Zt().string]))]),lockToContainerEdges:Zt().bool,onSortEnd:Zt().func,onSortMove:Zt().func,onSortOver:Zt().func,onSortStart:Zt().func,pressDelay:Zt().number,pressThreshold:Zt().number,keyCodes:Zt().shape({lift:Zt().arrayOf(Zt().number),drop:Zt().arrayOf(Zt().number),cancel:Zt().arrayOf(Zt().number),up:Zt().arrayOf(Zt().number),down:Zt().arrayOf(Zt().number)}),shouldCancelStart:Zt().func,transitionDuration:Zt().number,updateBeforeSortStart:Zt().func,useDragHandle:Zt().bool,useWindowAsScrollContainer:Zt().bool},En={lift:[32],drop:[32],cancel:[27],up:[38,37],down:[40,39]},kn={axis:"y",disableAutoscroll:!1,distance:0,getHelperDimensions:function(e){var t=e.node;return{height:t.offsetHeight,width:t.offsetWidth}},hideSortableGhost:!0,lockOffset:"50%",lockToContainerEdges:!1,pressDelay:0,pressThreshold:5,keyCodes:En,shouldCancelStart:function(e){return-1!==[vn,wn,Cn,bn,yn].indexOf(e.target.tagName)||!!ln(e.target,(function(e){return"true"===e.contentEditable}))},transitionDuration:300,useWindowAsScrollContainer:!1},$n=Object.keys(_n),Mn=(0,i.createContext)({manager:{}});function Tn(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{withRef:!1};return n=t=function(t){function n(e){var t;Bt(this,n),zt(jt(jt(t=Gt(this,Vt(n).call(this,e)))),"state",{}),zt(jt(jt(t)),"handleStart",(function(e){var n=t.props,i=n.distance,r=n.shouldCancelStart;if(2!==e.button&&!r(e)){t.touched=!0,t.position=pn(e);var o=ln(e.target,(function(e){return null!=e.sortableInfo}));if(o&&o.sortableInfo&&t.nodeIsChild(o)&&!t.state.sorting){var a=t.props.useDragHandle,s=o.sortableInfo,l=s.index,c=s.collection;if(s.disabled)return;if(a&&!ln(e.target,xn))return;t.manager.active={collection:c,index:l},function(e){return e.touches&&e.touches.length||e.changedTouches&&e.changedTouches.length}(e)||"A"!==e.target.tagName||e.preventDefault(),i||(0===t.props.pressDelay?t.handlePress(e):t.pressTimer=setTimeout((function(){return t.handlePress(e)}),t.props.pressDelay))}}})),zt(jt(jt(t)),"nodeIsChild",(function(e){return e.sortableInfo.manager===t.manager})),zt(jt(jt(t)),"handleMove",(function(e){var n=t.props,i=n.distance,r=n.pressThreshold;if(!t.state.sorting&&t.touched&&!t._awaitingUpdateBeforeSortStart){var o=pn(e),a={x:t.position.x-o.x,y:t.position.y-o.y},s=Math.abs(a.x)+Math.abs(a.y);t.delta=a,i||r&&!(s>=r)?i&&s>=i&&t.manager.isActive()&&t.handlePress(e):(clearTimeout(t.cancelTimer),t.cancelTimer=setTimeout(t.cancel,0))}})),zt(jt(jt(t)),"handleEnd",(function(){t.touched=!1,t.cancel()})),zt(jt(jt(t)),"cancel",(function(){var e=t.props.distance;t.state.sorting||(e||clearTimeout(t.pressTimer),t.manager.active=null)})),zt(jt(jt(t)),"handlePress",(function(e){try{var n=t.manager.getActive(),i=function(){if(n){var i=function(){var n,i,r,c,f,m,y,v=h.sortableInfo.index,b=(n=h,{bottom:dn((i=window.getComputedStyle(n)).marginBottom),left:dn(i.marginLeft),right:dn(i.marginRight),top:dn(i.marginTop)}),w=function(e){var t=window.getComputedStyle(e);return"grid"===t.display?{x:dn(t.gridColumnGap),y:dn(t.gridRowGap)}:{x:0,y:0}}(t.container),C=t.scrollContainer.getBoundingClientRect(),x=a({index:v,node:h,collection:p});if(t.node=h,t.margin=b,t.gridGap=w,t.width=x.width,t.height=x.height,t.marginOffset={x:t.margin.left+t.margin.right+t.gridGap.x,y:Math.max(t.margin.top,t.margin.bottom,t.gridGap.y)},t.boundingClientRect=h.getBoundingClientRect(),t.containerBoundingRect=C,t.index=v,t.newIndex=v,t.axis={x:o.indexOf("x")>=0,y:o.indexOf("y")>=0},t.offsetEdge=gn(h,t.container),t.initialOffset=pn(g?Ft({},e,{pageX:t.boundingClientRect.left,pageY:t.boundingClientRect.top}):e),t.initialScroll={left:t.scrollContainer.scrollLeft,top:t.scrollContainer.scrollTop},t.initialWindowScroll={left:window.pageXOffset,top:window.pageYOffset},t.helper=t.helperContainer.appendChild((c="input, textarea, select, canvas, [contenteditable]",f=(r=h).querySelectorAll(c),(y=(m=r.cloneNode(!0)).querySelectorAll(c),function(e){if(Array.isArray(e))return Ot(e)}(y)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(y)||It(y)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).forEach((function(e,t){"file"!==e.type&&(e.value=f[t].value),"radio"===e.type&&e.name&&(e.name="__sortableClone__".concat(e.name)),"CANVAS"===e.tagName&&f[t].width>0&&f[t].height>0&&e.getContext("2d").drawImage(f[t],0,0)})),m)),on(t.helper,{boxSizing:"border-box",height:"".concat(t.height,"px"),left:"".concat(t.boundingClientRect.left-b.left,"px"),pointerEvents:"none",position:"fixed",top:"".concat(t.boundingClientRect.top-b.top,"px"),width:"".concat(t.width,"px")}),g&&t.helper.focus(),l&&(t.sortableGhost=h,on(h,{opacity:0,visibility:"hidden"})),t.minTranslate={},t.maxTranslate={},g){var S=u?{top:0,left:0,width:t.contentWindow.innerWidth,height:t.contentWindow.innerHeight}:t.containerBoundingRect,_=S.top,E=S.left,k=S.width,$=_+S.height,M=E+k;t.axis.x&&(t.minTranslate.x=E-t.boundingClientRect.left,t.maxTranslate.x=M-(t.boundingClientRect.left+t.width)),t.axis.y&&(t.minTranslate.y=_-t.boundingClientRect.top,t.maxTranslate.y=$-(t.boundingClientRect.top+t.height))}else t.axis.x&&(t.minTranslate.x=(u?0:C.left)-t.boundingClientRect.left-t.width/2,t.maxTranslate.x=(u?t.contentWindow.innerWidth:C.left+C.width)-t.boundingClientRect.left-t.width/2),t.axis.y&&(t.minTranslate.y=(u?0:C.top)-t.boundingClientRect.top-t.height/2,t.maxTranslate.y=(u?t.contentWindow.innerHeight:C.top+C.height)-t.boundingClientRect.top-t.height/2);s&&s.split(" ").forEach((function(e){return t.helper.classList.add(e)})),t.listenerNode=e.touches?e.target:t.contentWindow,g?(t.listenerNode.addEventListener("wheel",t.handleKeyEnd,!0),t.listenerNode.addEventListener("mousedown",t.handleKeyEnd,!0),t.listenerNode.addEventListener("keydown",t.handleKeyDown)):(nn.move.forEach((function(e){return t.listenerNode.addEventListener(e,t.handleSortMove,!1)})),nn.end.forEach((function(e){return t.listenerNode.addEventListener(e,t.handleSortEnd,!1)}))),t.setState({sorting:!0,sortingIndex:v}),d&&d({node:h,index:v,collection:p,isKeySorting:g,nodes:t.manager.getOrderedRefs(),helper:t.helper},e),g&&t.keyMove(0)},r=t.props,o=r.axis,a=r.getHelperDimensions,s=r.helperClass,l=r.hideSortableGhost,c=r.updateBeforeSortStart,d=r.onSortStart,u=r.useWindowAsScrollContainer,h=n.node,p=n.collection,g=t.manager.isKeySorting,f=function(){if("function"==typeof c){t._awaitingUpdateBeforeSortStart=!0;var n=function(t,n){try{var i=(r=h.sortableInfo.index,Promise.resolve(c({collection:p,index:r,node:h,isKeySorting:g},e)).then((function(){})))}catch(e){return n(!0,e)}var r;return i&&i.then?i.then(n.bind(null,!1),n.bind(null,!0)):n(!1,value)}(0,(function(e,n){if(t._awaitingUpdateBeforeSortStart=!1,e)throw n;return n}));if(n&&n.then)return n.then((function(){}))}}();return f&&f.then?f.then(i):i()}}();return Promise.resolve(i&&i.then?i.then((function(){})):void 0)}catch(e){return Promise.reject(e)}})),zt(jt(jt(t)),"handleSortMove",(function(e){var n=t.props.onSortMove;"function"==typeof e.preventDefault&&e.cancelable&&e.preventDefault(),t.updateHelperPosition(e),t.animateNodes(),t.autoscroll(),n&&n(e)})),zt(jt(jt(t)),"handleSortEnd",(function(e){var n=t.props,i=n.hideSortableGhost,r=n.onSortEnd,o=t.manager,a=o.active.collection,s=o.isKeySorting,l=t.manager.getOrderedRefs();t.listenerNode&&(s?(t.listenerNode.removeEventListener("wheel",t.handleKeyEnd,!0),t.listenerNode.removeEventListener("mousedown",t.handleKeyEnd,!0),t.listenerNode.removeEventListener("keydown",t.handleKeyDown)):(nn.move.forEach((function(e){return t.listenerNode.removeEventListener(e,t.handleSortMove)})),nn.end.forEach((function(e){return t.listenerNode.removeEventListener(e,t.handleSortEnd)})))),t.helper.parentNode.removeChild(t.helper),i&&t.sortableGhost&&on(t.sortableGhost,{opacity:"",visibility:""});for(var c=0,d=l.length;c<d;c++){var u=l[c],h=u.node;u.edgeOffset=null,u.boundingClientRect=null,an(h,null),sn(h,null),u.translate=null}t.autoScroller.clear(),t.manager.active=null,t.manager.isKeySorting=!1,t.setState({sorting:!1,sortingIndex:null}),"function"==typeof r&&r({collection:a,newIndex:t.newIndex,oldIndex:t.index,isKeySorting:s,nodes:l},e),t.touched=!1})),zt(jt(jt(t)),"autoscroll",(function(){var e=t.props.disableAutoscroll,n=t.manager.isKeySorting;if(e)t.autoScroller.clear();else{if(n){var i=Ft({},t.translate),r=0,o=0;return t.axis.x&&(i.x=Math.min(t.maxTranslate.x,Math.max(t.minTranslate.x,t.translate.x)),r=t.translate.x-i.x),t.axis.y&&(i.y=Math.min(t.maxTranslate.y,Math.max(t.minTranslate.y,t.translate.y)),o=t.translate.y-i.y),t.translate=i,an(t.helper,t.translate),t.scrollContainer.scrollLeft+=r,void(t.scrollContainer.scrollTop+=o)}t.autoScroller.update({height:t.height,maxTranslate:t.maxTranslate,minTranslate:t.minTranslate,translate:t.translate,width:t.width})}})),zt(jt(jt(t)),"onAutoScroll",(function(e){t.translate.x+=e.left,t.translate.y+=e.top,t.animateNodes()})),zt(jt(jt(t)),"handleKeyDown",(function(e){var n=e.keyCode,i=t.props,r=i.shouldCancelStart,o=i.keyCodes,a=Ft({},En,void 0===o?{}:o);t.manager.active&&!t.manager.isKeySorting||!(t.manager.active||a.lift.includes(n)&&!r(e)&&t.isValidSortingTarget(e))||(e.stopPropagation(),e.preventDefault(),a.lift.includes(n)&&!t.manager.active?t.keyLift(e):a.drop.includes(n)&&t.manager.active?t.keyDrop(e):a.cancel.includes(n)?(t.newIndex=t.manager.active.index,t.keyDrop(e)):a.up.includes(n)?t.keyMove(-1):a.down.includes(n)&&t.keyMove(1))})),zt(jt(jt(t)),"keyLift",(function(e){var n=e.target,i=ln(n,(function(e){return null!=e.sortableInfo})).sortableInfo,r=i.index,o=i.collection;t.initialFocusedNode=n,t.manager.isKeySorting=!0,t.manager.active={index:r,collection:o},t.handlePress(e)})),zt(jt(jt(t)),"keyMove",(function(e){var n=t.manager.getOrderedRefs(),i=n[n.length-1].node.sortableInfo.index,r=t.newIndex+e,o=t.newIndex;if(!(r<0||r>i)){t.prevIndex=o,t.newIndex=r;var a=function(e,t,n){return e<n&&e>t?e-1:e>n&&e<t?e+1:e}(t.newIndex,t.prevIndex,t.index),s=n.find((function(e){return e.node.sortableInfo.index===a})),l=s.node,c=t.containerScrollDelta,d=s.boundingClientRect||hn(l,c),u=s.translate||{x:0,y:0},h=d.top+u.y-c.top,p=d.left+u.x-c.left,g=o<r,f=g&&t.axis.x?l.offsetWidth-t.width:0,m=g&&t.axis.y?l.offsetHeight-t.height:0;t.handleSortMove({pageX:p+f,pageY:h+m,ignoreTransition:0===e})}})),zt(jt(jt(t)),"keyDrop",(function(e){t.handleSortEnd(e),t.initialFocusedNode&&t.initialFocusedNode.focus()})),zt(jt(jt(t)),"handleKeyEnd",(function(e){t.manager.active&&t.keyDrop(e)})),zt(jt(jt(t)),"isValidSortingTarget",(function(e){var n=t.props.useDragHandle,i=e.target,r=ln(i,(function(e){return null!=e.sortableInfo}));return r&&r.sortableInfo&&!r.sortableInfo.disabled&&(n?xn(i):i.sortableInfo)}));var r=new Jt;return function(e){Qt()(!(e.distance&&e.pressDelay),"Attempted to set both `pressDelay` and `distance` on SortableContainer, you may only use one or the other, not both at the same time.")}(e),t.manager=r,t.wrappedInstance=(0,i.createRef)(),t.sortableContextValue={manager:r},t.events={end:t.handleEnd,move:t.handleMove,start:t.handleStart},t}return Kt(n,t),Wt(n,[{key:"componentDidMount",value:function(){var e=this,t=this.props.useWindowAsScrollContainer,n=this.getContainer();Promise.resolve(n).then((function(n){e.container=n,e.document=e.container.ownerDocument||document;var i=e.props.contentWindow||e.document.defaultView||window;e.contentWindow="function"==typeof i?i():i,e.scrollContainer=t?e.document.scrollingElement||e.document.documentElement:mn(e.container)||e.container,e.autoScroller=new Sn(e.scrollContainer,e.onAutoScroll),Object.keys(e.events).forEach((function(t){return nn[t].forEach((function(n){return e.container.addEventListener(n,e.events[t],!1)}))})),e.container.addEventListener("keydown",e.handleKeyDown)}))}},{key:"componentWillUnmount",value:function(){var e=this;this.helper&&this.helper.parentNode&&this.helper.parentNode.removeChild(this.helper),this.container&&(Object.keys(this.events).forEach((function(t){return nn[t].forEach((function(n){return e.container.removeEventListener(n,e.events[t])}))})),this.container.removeEventListener("keydown",this.handleKeyDown))}},{key:"updateHelperPosition",value:function(e){var t=this.props,n=t.lockAxis,i=t.lockOffset,r=t.lockToContainerEdges,o=t.transitionDuration,a=t.keyboardSortingTransitionDuration,s=void 0===a?o:a,l=this.manager.isKeySorting,c=e.ignoreTransition,d=pn(e),u={x:d.x-this.initialOffset.x,y:d.y-this.initialOffset.y};if(u.y-=window.pageYOffset-this.initialWindowScroll.top,u.x-=window.pageXOffset-this.initialWindowScroll.left,this.translate=u,r){var h=function(e){var t=e.height,n=e.width,i=e.lockOffset,r=Array.isArray(i)?i:[i,i];Qt()(2===r.length,"lockOffset prop of SortableContainer should be a single value or an array of exactly two values. Given %s",i);var o=Pt(r,2),a=o[0],s=o[1];return[fn({height:t,lockOffset:a,width:n}),fn({height:t,lockOffset:s,width:n})]}({height:this.height,lockOffset:i,width:this.width}),p=Pt(h,2),g=p[0],f=p[1],m={x:this.width/2-g.x,y:this.height/2-g.y},y={x:this.width/2-f.x,y:this.height/2-f.y};u.x=cn(this.minTranslate.x+m.x,this.maxTranslate.x-y.x,u.x),u.y=cn(this.minTranslate.y+m.y,this.maxTranslate.y-y.y,u.y)}"x"===n?u.y=0:"y"===n&&(u.x=0),l&&s&&!c&&sn(this.helper,s),an(this.helper,u)}},{key:"animateNodes",value:function(){var e=this.props,t=e.transitionDuration,n=e.hideSortableGhost,i=e.onSortOver,r=this.containerScrollDelta,o=this.windowScrollDelta,a=this.manager.getOrderedRefs(),s=this.offsetEdge.left+this.translate.x+r.left,l=this.offsetEdge.top+this.translate.y+r.top,c=this.manager.isKeySorting,d=this.newIndex;this.newIndex=null;for(var u=0,h=a.length;u<h;u++){var p=a[u].node,g=p.sortableInfo.index,f=p.offsetWidth,m=p.offsetHeight,y={height:this.height>m?m/2:this.height/2,width:this.width>f?f/2:this.width/2},v=c&&g>this.index&&g<=d,b=c&&g<this.index&&g>=d,w={x:0,y:0},C=a[u].edgeOffset;C||(C=gn(p,this.container),a[u].edgeOffset=C,c&&(a[u].boundingClientRect=hn(p,r)));var x=u<a.length-1&&a[u+1],S=u>0&&a[u-1];x&&!x.edgeOffset&&(x.edgeOffset=gn(x.node,this.container),c&&(x.boundingClientRect=hn(x.node,r))),g!==this.index?(t&&sn(p,t),this.axis.x?this.axis.y?b||g<this.index&&(s+o.left-y.width<=C.left&&l+o.top<=C.top+y.height||l+o.top+y.height<=C.top)?(w.x=this.width+this.marginOffset.x,C.left+w.x>this.containerBoundingRect.width-y.width&&x&&(w.x=x.edgeOffset.left-C.left,w.y=x.edgeOffset.top-C.top),null===this.newIndex&&(this.newIndex=g)):(v||g>this.index&&(s+o.left+y.width>=C.left&&l+o.top+y.height>=C.top||l+o.top+y.height>=C.top+m))&&(w.x=-(this.width+this.marginOffset.x),C.left+w.x<this.containerBoundingRect.left+y.width&&S&&(w.x=S.edgeOffset.left-C.left,w.y=S.edgeOffset.top-C.top),this.newIndex=g):v||g>this.index&&s+o.left+y.width>=C.left?(w.x=-(this.width+this.marginOffset.x),this.newIndex=g):(b||g<this.index&&s+o.left<=C.left+y.width)&&(w.x=this.width+this.marginOffset.x,null==this.newIndex&&(this.newIndex=g)):this.axis.y&&(v||g>this.index&&l+o.top+y.height>=C.top?(w.y=-(this.height+this.marginOffset.y),this.newIndex=g):(b||g<this.index&&l+o.top<=C.top+y.height)&&(w.y=this.height+this.marginOffset.y,null==this.newIndex&&(this.newIndex=g))),an(p,w),a[u].translate=w):n&&(this.sortableGhost=p,on(p,{opacity:0,visibility:"hidden"}))}null==this.newIndex&&(this.newIndex=this.index),c&&(this.newIndex=d);var _=c?this.prevIndex:d;i&&this.newIndex!==_&&i({collection:this.manager.active.collection,index:this.index,newIndex:this.newIndex,oldIndex:_,isKeySorting:c,nodes:a,helper:this.helper})}},{key:"getWrappedInstance",value:function(){return Qt()(r.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableContainer() call"),this.wrappedInstance.current}},{key:"getContainer",value:function(){var e=this.props.getContainer;return"function"!=typeof e?(0,Yt.findDOMNode)(this):e(r.withRef?this.getWrappedInstance():void 0)}},{key:"render",value:function(){var t=r.withRef?this.wrappedInstance:null;return(0,i.createElement)(Mn.Provider,{value:this.sortableContextValue},(0,i.createElement)(e,Rt({ref:t},tn(this.props,$n))))}},{key:"helperContainer",get:function(){var e=this.props.helperContainer;return"function"==typeof e?e():this.props.helperContainer||this.document.body}},{key:"containerScrollDelta",get:function(){return this.props.useWindowAsScrollContainer?{left:0,top:0}:{left:this.scrollContainer.scrollLeft-this.initialScroll.left,top:this.scrollContainer.scrollTop-this.initialScroll.top}}},{key:"windowScrollDelta",get:function(){return{left:this.contentWindow.pageXOffset-this.initialWindowScroll.left,top:this.contentWindow.pageYOffset-this.initialWindowScroll.top}}}]),n}(i.Component),zt(t,"displayName",un("sortableList",e)),zt(t,"defaultProps",kn),zt(t,"propTypes",_n),n}var An={index:Zt().number.isRequired,collection:Zt().oneOfType([Zt().number,Zt().string]),disabled:Zt().bool},Ln=Object.keys(An);function Rn(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{withRef:!1};return n=t=function(t){function n(){var e,t;Bt(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return zt(jt(jt(t=Gt(this,(e=Vt(n)).call.apply(e,[this].concat(o))))),"wrappedInstance",(0,i.createRef)()),t}return Kt(n,t),Wt(n,[{key:"componentDidMount",value:function(){this.register()}},{key:"componentDidUpdate",value:function(e){this.node&&(e.index!==this.props.index&&(this.node.sortableInfo.index=this.props.index),e.disabled!==this.props.disabled&&(this.node.sortableInfo.disabled=this.props.disabled)),e.collection!==this.props.collection&&(this.unregister(e.collection),this.register())}},{key:"componentWillUnmount",value:function(){this.unregister()}},{key:"register",value:function(){var e=this.props,t=e.collection,n=e.disabled,i=e.index,r=(0,Yt.findDOMNode)(this);r.sortableInfo={collection:t,disabled:n,index:i,manager:this.context.manager},this.node=r,this.ref={node:r},this.context.manager.add(t,this.ref)}},{key:"unregister",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props.collection;this.context.manager.remove(e,this.ref)}},{key:"getWrappedInstance",value:function(){return Qt()(r.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableElement() call"),this.wrappedInstance.current}},{key:"render",value:function(){var t=r.withRef?this.wrappedInstance:null;return(0,i.createElement)(e,Rt({ref:t},tn(this.props,Ln)))}}]),n}(i.Component),zt(t,"displayName",un("sortableElement",e)),zt(t,"contextType",Mn),zt(t,"propTypes",An),zt(t,"defaultProps",{collection:0}),n}const On=function(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{withRef:!1};return n=t=function(t){function n(){var e,t;Bt(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return zt(jt(jt(t=Gt(this,(e=Vt(n)).call.apply(e,[this].concat(o))))),"wrappedInstance",(0,i.createRef)()),t}return Kt(n,t),Wt(n,[{key:"componentDidMount",value:function(){(0,Yt.findDOMNode)(this).sortableHandle=!0}},{key:"getWrappedInstance",value:function(){return Qt()(r.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableHandle() call"),this.wrappedInstance.current}},{key:"render",value:function(){var t=r.withRef?this.wrappedInstance:null;return(0,i.createElement)(e,Rt({ref:t},this.props))}}]),n}(i.Component),zt(t,"displayName",un("sortableHandle",e)),n}((()=>(0,i.createElement)("div",{className:"gripIcon"},At))),In=Rn((({sortIndex:e,removeItem:t,duplicateItem:n,ItemSettings:r,active:o,setActive:a,itemLabel:s,title:l,...c})=>{const{value:d,attributes:u,arrKey:h,setActiveIndex:p}=c,g=u?u[h]:d[h],f=g?.[e]?.[l]||"";return(0,i.createElement)("div",{className:"bPlSortablePanelItem"},(0,i.createElement)("div",{className:"itemsPanelHeader mt10"},(0,i.createElement)(On,null),(0,i.createElement)("div",{className:"panel-header-title"},(0,i.createElement)("div",{className:"repeater-panel-title",onClick:()=>{a(o===e?null:e),p&&p(e)}},l?f:s+" "+(e+1)),(0,i.createElement)("div",{className:"itemAction"},(0,i.createElement)("div",{onClick:t=>n(t,e)},Mt),g.length>1&&(0,i.createElement)("div",{onClick:n=>t(n,e)},Tt)))),(0,i.createElement)("div",{className:"itemsPanelBody "+(o===e?"":"hidden")},(0,i.createElement)(r,{...c,index:e})))})),Pn=(Tn((e=>{const{value:t,attributes:n,arrKey:r}=e,o=n?n[r]:t[r];return(0,i.createElement)("div",{className:"bPlItemsPanel"},o.map(((t,n)=>(0,i.createElement)(In,{key:n,index:n,sortIndex:n,...e}))))})),e=>{const{className:t="mt20 mb5",htmlFor:n,children:r}=e;return(0,i.createElement)("label",{className:`bPlLabel ${t}`,htmlFor:n},r)}),Nn=e=>{const{className:t,label:n="",value:r,types:o=["image"],onChange:s,placeholder:l=(0,c.__)("Enter URL")}=e;return(0,i.createElement)("div",{className:t},n&&(0,i.createElement)(Pn,{className:"mb5"},n),(0,i.createElement)(d.PanelRow,{className:"bPlInlineMediaUpload"},(0,i.createElement)(d.TextControl,{value:r,onChange:e=>s(e),placeholder:l}),(0,i.createElement)(a.MediaUploadCheck,null,(0,i.createElement)(a.MediaUpload,{allowedTypes:o,onSelect:e=>s(e.url),render:({open:e})=>(0,i.createElement)(d.Button,{className:"button button-primary",onClick:e,icon:"upload"})}))))},Dn=e=>{const{className:t,label:n="",value:r={},types:o=["image"],onChange:s,placeholder:l=(0,c.__)("Enter URL")}=e;return(0,i.createElement)("div",{className:t},n&&(0,i.createElement)(Pn,{className:"mb5"},n),(0,i.createElement)(d.PanelRow,{className:"bPlInlineMediaUpload"},(0,i.createElement)(d.TextControl,{value:r?.url,onChange:e=>s({id:null,url:e,alt:"",title:"",caption:""}),placeholder:l}),(0,i.createElement)(a.MediaUploadCheck,null,(0,i.createElement)(a.MediaUpload,{allowedTypes:o,onSelect:({id:e,url:t,alt:n,title:i,caption:r})=>s({id:e,url:t,alt:n,title:i,caption:r}),render:({open:e})=>(0,i.createElement)(d.Button,{className:"button button-primary",onClick:e,icon:"upload"})}))))},zn=e=>{const{className:t="",label:n="Choose",value:r,types:o=["image"],onChange:s=()=>{},default:l="",height:c="50px",width:d="50px",style:u}=e;return(0,i.createElement)("div",{style:u,className:`bPlMediaArea ${t}`},(0,i.createElement)(a.MediaUpload,{value:r?.id?[r?.id]:[],onSelect:({id:e,url:t,alt:n,title:i})=>s({id:e,url:t,alt:n,title:i}),gallery:!1,allowedTypes:o,multiple:!1,render:({open:e})=>(0,i.createElement)("div",{className:"mediaAreaContainer"},l||r?.url?(0,i.createElement)("img",{className:"mediaImage",src:r?.url||l,alt:"",onClick:e,style:{height:c,width:d}}):(0,i.createElement)("div",{className:"mediaPlusBtnWrapper",onClick:e},(0,i.createElement)("div",{className:"mediaPlusBtnCircle"},(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",className:"mediaPlusBtn",width:"1em",height:"1em",viewBox:"0 0 448 512",fill:"currentColor"},(0,i.createElement)("path",{d:"M256 80c0-17.7-14.3-32-32-32s-32 14.3-32 32V224H48c-17.7 0-32 14.3-32 32s14.3 32 32 32H192V432c0 17.7 14.3 32 32 32s32-14.3 32-32V288H400c17.7 0 32-14.3 32-32s-14.3-32-32-32H256V80z"})))),(0,i.createElement)("div",{onClick:()=>s({}),className:"mediaDelete"},(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 448 512",fill:"currentColor"},(0,i.createElement)("path",{d:"M268 416h24a12 12 0 0 0 12-12V188a12 12 0 0 0-12-12h-24a12 12 0 0 0-12 12v216a12 12 0 0 0 12 12zM432 80h-82.41l-34-56.7A48 48 0 0 0 274.41 0H173.59a48 48 0 0 0-41.16 23.3L98.41 80H16A16 16 0 0 0 0 96v16a16 16 0 0 0 16 16h16v336a48 48 0 0 0 48 48h288a48 48 0 0 0 48-48V128h16a16 16 0 0 0 16-16V96a16 16 0 0 0-16-16zM171.84 50.91A6 6 0 0 1 177 48h94a6 6 0 0 1 5.15 2.91L293.61 80H154.39zM368 464H80V128h288zm-212-48h24a12 12 0 0 0 12-12V188a12 12 0 0 0-12-12h-24a12 12 0 0 0-12 12v216a12 12 0 0 0 12 12z"}))),(0,i.createElement)("div",{onClick:e,className:"mediaButton"},(0,i.createElement)("span",null,n)))}))};var Fn=n(327);const Bn=e=>{const{className:t="",label:n="",value:r,onChange:o,options:a=[]}=e,s=(0,i.useRef)(null);return(0,i.useEffect)((()=>{s.current&&(s.current.innerHTML="",new Fn.A(s.current,{value:r,onChange:e=>o(e),options:a,multiple:!0,autocomplete:!0,icon:"closeIcon",classNames:{select:"bplSelectPure",multiselect:"selectMultiple",label:"selectLabel",selectedLabel:"selectSelectedLabel",dropdown:"selectOptions",dropdownShown:"selectOptionsOpened",autocompleteInput:"selectAutocomplete",option:"selectOption",selectedOption:"selectOptionSelected",optionDisabled:"selectOptionDisabled",optionHidden:"selectOptionHidden",placeholder:"selectPlaceholder",placeholderHidden:"selectPlaceholderHidden"}}))}),[s]),n?(0,i.createElement)("div",{className:t},(0,i.createElement)(Pn,{className:"mb5"},n),(0,i.createElement)("div",{ref:s})):(0,i.createElement)("div",{className:t,ref:s})},Hn=e=>{const{label:t="Color",value:n,onChange:r=()=>{},className:a=""}=e,s=(0,o.useSelect)("core/block-editor").getSettings().gradients,[l,c]=(0,i.useState)("solid"),u=Math.floor(9999999*Math.random());return(0,i.createElement)("div",{className:a},(0,i.createElement)("style",null,`#customColorControlPanel-${u}-dualColor{\n\t\t\t\t${n?`background: ${n};`:"\n\t\t\t\t\tbackground-image: linear-gradient( 45deg, #d5d8dc 25%, transparent 0, transparent 75%, #d5d8dc 0, #d5d8dc ), linear-gradient( 45deg, #d5d8dc 25%, transparent 0, transparent 75%, #d5d8dc 0, #d5d8dc );\n\t\t\t\t\tbackground-size: 16px 16px;\n\t\t\t\t\tbackground-position: 0 0, calc(16px / 2) calc(16px / 2);\n\t\t\t\t"}\n\t\t\t}`),(0,i.createElement)("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between"}},(0,i.createElement)(Pn,{className:""},t),(0,i.createElement)(d.Dropdown,{className:"my-container-class-name",contentClassName:"my-popover-content-classname",renderToggle:({isOpen:e,onToggle:t,onClose:n})=>(0,i.createElement)("div",{style:{display:"flex",alignItems:"center",gap:"5px"}},(0,i.createElement)("div",{id:`customColorControlPanel-${u}-dualColor`,style:{height:"25px",width:"25px",borderRadius:"50%",border:"1px solid #ccc"}}),(0,i.createElement)(d.Button,{onClick:t,"aria-expanded":e,icon:"edit"})),renderContent:({isOpen:e,onToggle:t,onClose:o})=>(0,i.createElement)("div",{className:"panel-custom-color-control-container"},(0,i.createElement)(xe,{label:"Type:",options:[{label:"Solid",value:"solid"},{label:"Gradient",value:"gradient"}],value:l,onChange:e=>c(e)}),"solid"===l&&(0,i.createElement)("div",{style:{marginTop:"20px"}},(0,i.createElement)(Ee,{value:n,label:"Color :",onChange:e=>r(e)})),"gradient"===l&&(0,i.createElement)("div",{style:{marginTop:"10px"}},(0,i.createElement)(d.GradientPicker,{value:n||s?.[0]?.gradient,onChange:e=>r(e),gradients:s})),(0,i.createElement)("div",{onClick:o}))})))},Wn=Rn((({value:e})=>(0,i.createElement)("li",{className:"bplSortableListItem"},e))),jn=Tn((({items:e,property:t})=>(0,i.createElement)("ul",null,e.map(((e,n)=>(0,i.createElement)(Wn,{key:n,index:n,sortIndex:n,value:t?e[t]:e})))))),Gn=({className:e="",label:t=(0,c.__)("Sort:"),value:n=[],property:r,onChange:o})=>(0,i.createElement)("div",{className:`bplSortableList ${e}`},(0,i.createElement)(Pn,{className:"mb5"},t),(0,i.createElement)(jn,{items:n,property:r,onSortEnd:({oldIndex:e,newIndex:t})=>{var i,r,a;o((r=e,a=t,(i=(i=n).slice()).splice(a<0?i.length+a:a,0,i.splice(r,1)[0]),i))}}),(0,i.createElement)("small",null,(0,c.__)("Drag and drop to sort"))),Vn=({device:e="desktop",onChange:t,className:n="iconButton",style:r})=>{const[o,a]=(0,i.useState)(!1);return window.addEventListener("click",(()=>a(!1))),(0,i.createElement)("div",{className:"bDevice",style:r},!o&&(0,i.createElement)("button",{className:n,title:e[0].toUpperCase()+e.slice(1),onClick:e=>{a(!0),e.stopPropagation()}},"desktop"==e?wt:"tablet"==e?Ct:xt),o&&(0,i.createElement)("div",{className:"bDevicePopup"},[{value:"desktop",icon:wt},{value:"tablet",icon:Ct},{value:"mobile",icon:xt}].map((({icon:e,value:r})=>(0,i.createElement)("button",{key:r,className:n,title:r[0].toUpperCase()+r.slice(1),onClick:()=>{t(r),a(!1)}},e)))))},Un=e=>{const{className:t="",label:n=(0,c.__)("Border:"),value:r,onChange:o,defaults:a={}}=e,s={width:"0px",style:"solid",color:"",side:"all",radius:"0px"},l=e=>a?.[e]||s[e],u=e=>r?.[e]||l(e),h=(e,t)=>o({...r,[e]:t}),p=e=>(0,i.createElement)(d.Button,{icon:"image-rotate",className:"bPlResetVal",onClick:()=>(e=>o({...r,[e]:l(e)}))(e)});return(0,i.createElement)(d.PanelRow,{className:`bPlDropdown ${t}`},(0,i.createElement)(Pn,{className:"mt5"},n),(0,i.createElement)(d.Dropdown,{className:"bPlDropdownContainer",contentClassName:"bPlDropdownPopover",popoverProps:{placement:"bottom-end"},renderToggle:({isOpen:e,onToggle:t})=>(0,i.createElement)(d.Button,{icon:"edit",onClick:t,"aria-expanded":e}),renderContent:()=>(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Width:"),labelPosition:"left",value:u("width"),onChange:e=>h("width",e),units:[se(),ce()]}),r?.width&&r?.width!==l("width")&&p("width")),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Style:")),(0,i.createElement)(d.SelectControl,{value:u("style"),onChange:e=>h("style",e),options:ae}),r?.style&&r?.style!==l("style")&&p("style")),(0,i.createElement)(Ee,{label:(0,c.__)("Color:"),value:u("color"),onChange:e=>h("color",e),defaultColor:l("color")}),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Sides:")),(0,i.createElement)(d.SelectControl,{value:u("side"),onChange:e=>h("side",e),options:pe}),r?.side&&r?.side!==l("side")&&p("side")),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Radius:"),labelPosition:"left",value:u("radius"),onChange:e=>h("radius",e),units:[se(50),le(50),ce(3),de(3)],isResetValueOnUnitChange:!0}),r?.radius&&r?.radius!==l("radius")&&p("radius")))}))},Kn=window.wp.blob,Yn=((0,o.withSelect)(((e,t)=>{const{value:n}=t;return{image:n?.id?e("core").getMedia(n?.id):null,imageSizes:e("core/block-editor").getSettings().imageSizes}}))((e=>{const{className:t,value:n={},onChange:r,image:o,imageSizes:a}=e,l=(e,t)=>r({...n,[e]:t});return(0,i.createElement)("div",{className:t},n?.url&&!(0,Kn.isBlobURL)(n?.url)&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,{className:"mb5"},(0,c.__)("Alt Text (Alternative Text):")),(0,i.createElement)(d.TextControl,{value:n?.alt,onChange:e=>l("alt",e)})),n?.id&&0!==s(o,a)?.length&&(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Select Size:")),(0,i.createElement)(d.SelectControl,{value:n?.url,onChange:e=>l("url",e),options:s(o,a)})))})),(0,d.withNotices)((e=>{const{label:t=(0,c.__)(" Image:"),icon:n="format-image",value:r={},onChange:o,noticeOperations:s,noticeUI:l}=e;return(0,i.createElement)(a.MediaPlaceholder,{labels:{title:t},icon:n,allowedTypes:["image"],accept:"image/*",onSelect:({id:e,url:t,alt:n,title:i})=>o({...r,id:e,url:t,alt:n,title:i}),onSelectURL:e=>o({...r,id:null,url:e,alt:"",title:""}),onError:e=>s.createErrorNotice(e),notices:l})})),e=>{const{className:t="",label:n=(0,c.__)("Space:"),value:r,onChange:o,defaults:a={}}=e,s={side:2,vertical:"0px",horizontal:"0px",top:"0px",right:"0px",bottom:"0px",left:"0px"},l=e=>a?.[e]||s[e],u=e=>r?.[e]||l(e),h=(e,t)=>o({...r,[e]:t}),p=e=>parseInt(u(e)?.replace(/([a-z])+/g,"")),g=e=>null!=e&&"object"==typeof e;return(0,i.createElement)("div",{className:`bPlSpaceControl ${t}`},(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},n),(0,i.createElement)(d.ButtonGroup,{className:"bPlBtnGroup"},(0,i.createElement)(d.Tooltip,{text:(0,c.__)("Vertical, Horizontal"),placement:"top",position:"top"},(0,i.createElement)(d.Button,{className:"side2",size:"small",isPrimary:2===u("side"),"aria-pressed":2===u("side"),onClick:()=>o({...r,side:2,vertical:(p("top")+p("bottom"))/2+"px",horizontal:(p("left")+p("right"))/2+"px"})},(0,i.createElement)("span",{className:"scrollIcon"},St),(0,i.createElement)("span",{className:"sideScrollIcon"},St))),(0,i.createElement)(d.Tooltip,{text:(0,c.__)("Top, Right, Bottom, Left"),placement:"top",position:"top"},(0,i.createElement)(d.Button,{size:"small",isPrimary:4===u("side"),"aria-pressed":4===u("side"),onClick:()=>o({...r,side:4,top:u("vertical"),right:u("horizontal"),bottom:u("vertical"),left:u("horizontal")})},(0,i.createElement)(d.Dashicon,{icon:"arrow-up-alt"}),(0,i.createElement)(d.Dashicon,{icon:"arrow-right-alt"}),(0,i.createElement)(d.Dashicon,{icon:"arrow-down-alt"}),(0,i.createElement)(d.Dashicon,{icon:"arrow-left-alt"})))),!((e,t,n)=>{const i=Object.keys(e||{}).filter((e=>"styles"!==e)),r=(e,t)=>{const n=Object.keys(e);for(const i of n){const n=e[i],o=t[i],a=g(n)&&g(o);if(a&&!r(n,o)||!a&&n!==o)return!1}return!0};for(const o of i){const i=e[o],a=t[o],s=n[o],l=g(i)&&g(a),c=g(i)&&g(s);if(a){if(l&&!r(i,a)||!l&&i!==a)return!1}else if(c&&!r(i,s)||!c&&i!==s)return!1}return!0})(r,a,s)&&(0,i.createElement)(d.Button,{icon:"image-rotate",className:"bPlResetVal",onClick:()=>{const e={side:l("side"),vertical:l("vertical"),horizontal:l("horizontal"),top:l("top"),right:l("right"),bottom:l("bottom"),left:l("left")};o({...r,...e})}})),2===u("side")&&(0,i.createElement)(d.PanelRow,{className:"twoColumn"},(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Top Bottom:"),labelPosition:"top",value:u("vertical"),onChange:e=>h("vertical",e),units:[se(),le(),ce(),de()]}),(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Left Right:"),labelPosition:"top",value:u("horizontal"),onChange:e=>h("horizontal",e),units:[se(),le(),ce(),de()]})),4===u("side")&&(0,i.createElement)(d.PanelRow,{className:"fourColumn"},(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Top:"),labelPosition:"top",value:u("top"),onChange:e=>h("top",e),units:[se(),le(),ce(),de()]}),(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Right:"),labelPosition:"top",value:u("right"),onChange:e=>h("right",e),units:[se(),le(),ce(),de()]}),(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Bottom:"),labelPosition:"top",value:u("bottom"),onChange:e=>h("bottom",e),units:[se(),le(),ce(),de()]}),(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Left:"),labelPosition:"top",value:u("left"),onChange:e=>h("left",e),units:[se(),le(),ce(),de()]})))}),qn=[{family:"Default",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"ABeeZee",variants:[400,"400i"],category:"sans-serif"},{family:"Abel",variants:[400],category:"sans-serif"},{family:"Abhaya Libre",variants:[400,500,600,700,800],category:"serif"},{family:"Abril Fatface",variants:[400],category:"display"},{family:"Aclonica",variants:[400],category:"sans-serif"},{family:"Acme",variants:[400],category:"sans-serif"},{family:"Actor",variants:[400],category:"sans-serif"},{family:"Adamina",variants:[400],category:"serif"},{family:"Advent Pro",variants:[100,200,300,400,500,600,700],category:"sans-serif"},{family:"Aguafina Script",variants:[400],category:"handwriting"},{family:"Akaya Kanadaka",variants:[400],category:"display"},{family:"Akaya Telivigala",variants:[400],category:"display"},{family:"Akronim",variants:[400],category:"display"},{family:"Aladin",variants:[400],category:"handwriting"},{family:"Alata",variants:[400],category:"sans-serif"},{family:"Alatsi",variants:[400],category:"sans-serif"},{family:"Aldrich",variants:[400],category:"sans-serif"},{family:"Alef",variants:[400,700],category:"sans-serif"},{family:"Alegreya",variants:[400,500,600,700,800,900,"400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Alegreya SC",variants:[400,"400i",500,"500i",700,"700i",800,"800i",900,"900i"],category:"serif"},{family:"Alegreya Sans",variants:[100,"100i",300,"300i",400,"400i",500,"500i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Alegreya Sans SC",variants:[100,"100i",300,"300i",400,"400i",500,"500i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Aleo",variants:[300,"300i",400,"400i",700,"700i"],category:"serif"},{family:"Alex Brush",variants:[400],category:"handwriting"},{family:"Alfa Slab One",variants:[400],category:"display"},{family:"Alice",variants:[400],category:"serif"},{family:"Alike",variants:[400],category:"serif"},{family:"Alike Angular",variants:[400],category:"serif"},{family:"Allan",variants:[400,700],category:"display"},{family:"Allerta",variants:[400],category:"sans-serif"},{family:"Allerta Stencil",variants:[400],category:"sans-serif"},{family:"Allura",variants:[400],category:"handwriting"},{family:"Almarai",variants:[300,400,700,800],category:"sans-serif"},{family:"Almendra",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Almendra Display",variants:[400],category:"display"},{family:"Almendra SC",variants:[400],category:"serif"},{family:"Amarante",variants:[400],category:"display"},{family:"Amaranth",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Amatic SC",variants:[400,700],category:"handwriting"},{family:"Amethysta",variants:[400],category:"serif"},{family:"Amiko",variants:[400,600,700],category:"sans-serif"},{family:"Amiri",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Amita",variants:[400,700],category:"handwriting"},{family:"Anaheim",variants:[400],category:"sans-serif"},{family:"Andada",variants:[400],category:"serif"},{family:"Andika",variants:[400],category:"sans-serif"},{family:"Andika New Basic",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Angkor",variants:[400],category:"display"},{family:"Annie Use Your Telescope",variants:[400],category:"handwriting"},{family:"Anonymous Pro",variants:[400,"400i",700,"700i"],category:"monospace"},{family:"Antic",variants:[400],category:"sans-serif"},{family:"Antic Didone",variants:[400],category:"serif"},{family:"Antic Slab",variants:[400],category:"serif"},{family:"Anton",variants:[400],category:"sans-serif"},{family:"Antonio",variants:[100,200,300,400,500,600,700],category:"sans-serif"},{family:"Arapey",variants:[400,"400i"],category:"serif"},{family:"Arbutus",variants:[400],category:"display"},{family:"Arbutus Slab",variants:[400],category:"serif"},{family:"Architects Daughter",variants:[400],category:"handwriting"},{family:"Archivo",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Archivo Black",variants:[400],category:"sans-serif"},{family:"Archivo Narrow",variants:[400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Aref Ruqaa",variants:[400,700],category:"serif"},{family:"Arima Madurai",variants:[100,200,300,400,500,700,800,900],category:"display"},{family:"Arimo",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"sans-serif"},{family:"Arizonia",variants:[400],category:"handwriting"},{family:"Armata",variants:[400],category:"sans-serif"},{family:"Arsenal",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Artifika",variants:[400],category:"serif"},{family:"Arvo",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Arya",variants:[400,700],category:"sans-serif"},{family:"Asap",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"sans-serif"},{family:"Asap Condensed",variants:[400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Asar",variants:[400],category:"serif"},{family:"Asset",variants:[400],category:"display"},{family:"Assistant",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"Astloch",variants:[400,700],category:"display"},{family:"Asul",variants:[400,700],category:"sans-serif"},{family:"Athiti",variants:[200,300,400,500,600,700],category:"sans-serif"},{family:"Atma",variants:[300,400,500,600,700],category:"display"},{family:"Atomic Age",variants:[400],category:"display"},{family:"Aubrey",variants:[400],category:"display"},{family:"Audiowide",variants:[400],category:"display"},{family:"Autour One",variants:[400],category:"display"},{family:"Average",variants:[400],category:"serif"},{family:"Average Sans",variants:[400],category:"sans-serif"},{family:"Averia Gruesa Libre",variants:[400],category:"display"},{family:"Averia Libre",variants:[300,"300i",400,"400i",700,"700i"],category:"display"},{family:"Averia Sans Libre",variants:[300,"300i",400,"400i",700,"700i"],category:"display"},{family:"Averia Serif Libre",variants:[300,"300i",400,"400i",700,"700i"],category:"display"},{family:"B612",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"B612 Mono",variants:[400,"400i",700,"700i"],category:"monospace"},{family:"Bad Script",variants:[400],category:"handwriting"},{family:"Bahiana",variants:[400],category:"display"},{family:"Bahianita",variants:[400],category:"display"},{family:"Bai Jamjuree",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Ballet",variants:[400],category:"handwriting"},{family:"Baloo 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Bhai 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Bhaina 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Chettan 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Da 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Paaji 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Tamma 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Tammudu 2",variants:[400,500,600,700,800],category:"display"},{family:"Baloo Thambi 2",variants:[400,500,600,700,800],category:"display"},{family:"Balsamiq Sans",variants:[400,"400i",700,"700i"],category:"display"},{family:"Balthazar",variants:[400],category:"serif"},{family:"Bangers",variants:[400],category:"display"},{family:"Barlow",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Barlow Condensed",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Barlow Semi Condensed",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Barriecito",variants:[400],category:"display"},{family:"Barrio",variants:[400],category:"display"},{family:"Basic",variants:[400],category:"sans-serif"},{family:"Baskervville",variants:[400,"400i"],category:"serif"},{family:"Battambang",variants:[400,700],category:"display"},{family:"Baumans",variants:[400],category:"display"},{family:"Bayon",variants:[400],category:"display"},{family:"Be Vietnam",variants:[100,"100i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i"],category:"sans-serif"},{family:"Bebas Neue",variants:[400],category:"display"},{family:"Belgrano",variants:[400],category:"serif"},{family:"Bellefair",variants:[400],category:"serif"},{family:"Belleza",variants:[400],category:"sans-serif"},{family:"Bellota",variants:[300,"300i",400,"400i",700,"700i"],category:"display"},{family:"Bellota Text",variants:[300,"300i",400,"400i",700,"700i"],category:"display"},{family:"BenchNine",variants:[300,400,700],category:"sans-serif"},{family:"Benne",variants:[400],category:"serif"},{family:"Bentham",variants:[400],category:"serif"},{family:"Berkshire Swash",variants:[400],category:"handwriting"},{family:"Beth Ellen",variants:[400],category:"handwriting"},{family:"Bevan",variants:[400],category:"display"},{family:"Big Shoulders Display",variants:[100,300,400,500,600,700,800,900],category:"display"},{family:"Big Shoulders Inline Display",variants:[100,300,400,500,600,700,800,900],category:"display"},{family:"Big Shoulders Inline Text",variants:[100,300,400,500,600,700,800,900],category:"display"},{family:"Big Shoulders Stencil Display",variants:[100,300,400,500,600,700,800,900],category:"display"},{family:"Big Shoulders Stencil Text",variants:[100,300,400,500,600,700,800,900],category:"display"},{family:"Big Shoulders Text",variants:[100,300,400,500,600,700,800,900],category:"display"},{family:"Bigelow Rules",variants:[400],category:"display"},{family:"Bigshot One",variants:[400],category:"display"},{family:"Bilbo",variants:[400],category:"handwriting"},{family:"Bilbo Swash Caps",variants:[400],category:"handwriting"},{family:"BioRhyme",variants:[200,300,400,700,800],category:"serif"},{family:"BioRhyme Expanded",variants:[200,300,400,700,800],category:"serif"},{family:"Biryani",variants:[200,300,400,600,700,800,900],category:"sans-serif"},{family:"Bitter",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Black And White Picture",variants:[400],category:"sans-serif"},{family:"Black Han Sans",variants:[400],category:"sans-serif"},{family:"Black Ops One",variants:[400],category:"display"},{family:"Blinker",variants:[100,200,300,400,600,700,800,900],category:"sans-serif"},{family:"Bodoni Moda",variants:[400,500,600,700,800,900,"400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Bokor",variants:[400],category:"display"},{family:"Bonbon",variants:[400],category:"handwriting"},{family:"Boogaloo",variants:[400],category:"display"},{family:"Bowlby One",variants:[400],category:"display"},{family:"Bowlby One SC",variants:[400],category:"display"},{family:"Brawler",variants:[400],category:"serif"},{family:"Bree Serif",variants:[400],category:"serif"},{family:"Brygada 1918",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"serif"},{family:"Bubblegum Sans",variants:[400],category:"display"},{family:"Bubbler One",variants:[400],category:"sans-serif"},{family:"Buda",variants:[300,400],category:"display"},{family:"Buenard",variants:[400,700],category:"serif"},{family:"Bungee",variants:[400],category:"display"},{family:"Bungee Hairline",variants:[400],category:"display"},{family:"Bungee Inline",variants:[400],category:"display"},{family:"Bungee Outline",variants:[400],category:"display"},{family:"Bungee Shade",variants:[400],category:"display"},{family:"Butcherman",variants:[400],category:"display"},{family:"Butterfly Kids",variants:[400],category:"handwriting"},{family:"Cabin",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"sans-serif"},{family:"Cabin Condensed",variants:[400,500,600,700],category:"sans-serif"},{family:"Cabin Sketch",variants:[400,700],category:"display"},{family:"Caesar Dressing",variants:[400],category:"display"},{family:"Cagliostro",variants:[400],category:"sans-serif"},{family:"Cairo",variants:[200,300,400,600,700,900],category:"sans-serif"},{family:"Caladea",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Calistoga",variants:[400],category:"display"},{family:"Calligraffitti",variants:[400],category:"handwriting"},{family:"Cambay",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Cambo",variants:[400],category:"serif"},{family:"Candal",variants:[400],category:"sans-serif"},{family:"Cantarell",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Cantata One",variants:[400],category:"serif"},{family:"Cantora One",variants:[400],category:"sans-serif"},{family:"Capriola",variants:[400],category:"sans-serif"},{family:"Cardo",variants:[400,"400i",700],category:"serif"},{family:"Carme",variants:[400],category:"sans-serif"},{family:"Carrois Gothic",variants:[400],category:"sans-serif"},{family:"Carrois Gothic SC",variants:[400],category:"sans-serif"},{family:"Carter One",variants:[400],category:"display"},{family:"Castoro",variants:[400,"400i"],category:"serif"},{family:"Catamaran",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Caudex",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Caveat",variants:[400,500,600,700],category:"handwriting"},{family:"Caveat Brush",variants:[400],category:"handwriting"},{family:"Cedarville Cursive",variants:[400],category:"handwriting"},{family:"Ceviche One",variants:[400],category:"display"},{family:"Chakra Petch",variants:[300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Changa",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"Changa One",variants:[400,"400i"],category:"display"},{family:"Chango",variants:[400],category:"display"},{family:"Charm",variants:[400,700],category:"handwriting"},{family:"Charmonman",variants:[400,700],category:"handwriting"},{family:"Chathura",variants:[100,300,400,700,800],category:"sans-serif"},{family:"Chau Philomene One",variants:[400,"400i"],category:"sans-serif"},{family:"Chela One",variants:[400],category:"display"},{family:"Chelsea Market",variants:[400],category:"display"},{family:"Chenla",variants:[400],category:"display"},{family:"Cherry Cream Soda",variants:[400],category:"display"},{family:"Cherry Swash",variants:[400,700],category:"display"},{family:"Chewy",variants:[400],category:"display"},{family:"Chicle",variants:[400],category:"display"},{family:"Chilanka",variants:[400],category:"handwriting"},{family:"Chivo",variants:[300,"300i",400,"400i",700,"700i",900,"900i"],category:"sans-serif"},{family:"Chonburi",variants:[400],category:"display"},{family:"Cinzel",variants:[400,500,600,700,800,900],category:"serif"},{family:"Cinzel Decorative",variants:[400,700,900],category:"display"},{family:"Clicker Script",variants:[400],category:"handwriting"},{family:"Coda",variants:[400,800],category:"display"},{family:"Coda Caption",variants:[400,800],category:"sans-serif"},{family:"Codystar",variants:[300,400],category:"display"},{family:"Coiny",variants:[400],category:"display"},{family:"Combo",variants:[400],category:"display"},{family:"Comfortaa",variants:[300,400,500,600,700],category:"display"},{family:"Comic Neue",variants:[300,"300i",400,"400i",700,"700i"],category:"handwriting"},{family:"Coming Soon",variants:[400],category:"handwriting"},{family:"Commissioner",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Concert One",variants:[400],category:"display"},{family:"Condiment",variants:[400],category:"handwriting"},{family:"Content",variants:[400,700],category:"display"},{family:"Contrail One",variants:[400],category:"display"},{family:"Convergence",variants:[400],category:"sans-serif"},{family:"Cookie",variants:[400],category:"handwriting"},{family:"Copse",variants:[400],category:"serif"},{family:"Corben",variants:[400,700],category:"display"},{family:"Cormorant",variants:[300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"serif"},{family:"Cormorant Garamond",variants:[300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"serif"},{family:"Cormorant Infant",variants:[300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"serif"},{family:"Cormorant SC",variants:[300,400,500,600,700],category:"serif"},{family:"Cormorant Unicase",variants:[300,400,500,600,700],category:"serif"},{family:"Cormorant Upright",variants:[300,400,500,600,700],category:"serif"},{family:"Courgette",variants:[400],category:"handwriting"},{family:"Courier Prime",variants:[400,"400i",700,"700i"],category:"monospace"},{family:"Cousine",variants:[400,"400i",700,"700i"],category:"monospace"},{family:"Coustard",variants:[400,900],category:"serif"},{family:"Covered By Your Grace",variants:[400],category:"handwriting"},{family:"Crafty Girls",variants:[400],category:"handwriting"},{family:"Creepster",variants:[400],category:"display"},{family:"Crete Round",variants:[400,"400i"],category:"serif"},{family:"Crimson Pro",variants:[200,300,400,500,600,700,800,900,"200i","300i","400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Crimson Text",variants:[400,"400i",600,"600i",700,"700i"],category:"serif"},{family:"Croissant One",variants:[400],category:"display"},{family:"Crushed",variants:[400],category:"display"},{family:"Cuprum",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"sans-serif"},{family:"Cute Font",variants:[400],category:"display"},{family:"Cutive",variants:[400],category:"serif"},{family:"Cutive Mono",variants:[400],category:"monospace"},{family:"DM Mono",variants:[300,"300i",400,"400i",500,"500i"],category:"monospace"},{family:"DM Sans",variants:[400,"400i",500,"500i",700,"700i"],category:"sans-serif"},{family:"DM Serif Display",variants:[400,"400i"],category:"serif"},{family:"DM Serif Text",variants:[400,"400i"],category:"serif"},{family:"Damion",variants:[400],category:"handwriting"},{family:"Dancing Script",variants:[400,500,600,700],category:"handwriting"},{family:"Dangrek",variants:[400],category:"display"},{family:"Darker Grotesque",variants:[300,400,500,600,700,800,900],category:"sans-serif"},{family:"David Libre",variants:[400,500,700],category:"serif"},{family:"Dawning of a New Day",variants:[400],category:"handwriting"},{family:"Days One",variants:[400],category:"sans-serif"},{family:"Dekko",variants:[400],category:"handwriting"},{family:"Dela Gothic One",variants:[400],category:"display"},{family:"Delius",variants:[400],category:"handwriting"},{family:"Delius Swash Caps",variants:[400],category:"handwriting"},{family:"Delius Unicase",variants:[400,700],category:"handwriting"},{family:"Della Respira",variants:[400],category:"serif"},{family:"Denk One",variants:[400],category:"sans-serif"},{family:"Devonshire",variants:[400],category:"handwriting"},{family:"Dhurjati",variants:[400],category:"sans-serif"},{family:"Didact Gothic",variants:[400],category:"sans-serif"},{family:"Diplomata",variants:[400],category:"display"},{family:"Diplomata SC",variants:[400],category:"display"},{family:"Do Hyeon",variants:[400],category:"sans-serif"},{family:"Dokdo",variants:[400],category:"handwriting"},{family:"Domine",variants:[400,500,600,700],category:"serif"},{family:"Donegal One",variants:[400],category:"serif"},{family:"Doppio One",variants:[400],category:"sans-serif"},{family:"Dorsa",variants:[400],category:"sans-serif"},{family:"Dosis",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"DotGothic16",variants:[400],category:"sans-serif"},{family:"Dr Sugiyama",variants:[400],category:"handwriting"},{family:"Duru Sans",variants:[400],category:"sans-serif"},{family:"Dynalight",variants:[400],category:"display"},{family:"EB Garamond",variants:[400,500,600,700,800,"400i","500i","600i","700i","800i"],category:"serif"},{family:"Eagle Lake",variants:[400],category:"handwriting"},{family:"East Sea Dokdo",variants:[400],category:"handwriting"},{family:"Eater",variants:[400],category:"display"},{family:"Economica",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Eczar",variants:[400,500,600,700,800],category:"serif"},{family:"El Messiri",variants:[400,500,600,700],category:"sans-serif"},{family:"Electrolize",variants:[400],category:"sans-serif"},{family:"Elsie",variants:[400,900],category:"display"},{family:"Elsie Swash Caps",variants:[400,900],category:"display"},{family:"Emblema One",variants:[400],category:"display"},{family:"Emilys Candy",variants:[400],category:"display"},{family:"Encode Sans",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Encode Sans Condensed",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Encode Sans Expanded",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Encode Sans Semi Condensed",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Encode Sans Semi Expanded",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Engagement",variants:[400],category:"handwriting"},{family:"Englebert",variants:[400],category:"sans-serif"},{family:"Enriqueta",variants:[400,500,600,700],category:"serif"},{family:"Epilogue",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Erica One",variants:[400],category:"display"},{family:"Esteban",variants:[400],category:"serif"},{family:"Euphoria Script",variants:[400],category:"handwriting"},{family:"Ewert",variants:[400],category:"display"},{family:"Exo",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Exo 2",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Expletus Sans",variants:[400,"400i",500,"500i",600,"600i",700,"700i"],category:"display"},{family:"Fahkwang",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Fanwood Text",variants:[400,"400i"],category:"serif"},{family:"Farro",variants:[300,400,500,700],category:"sans-serif"},{family:"Farsan",variants:[400],category:"display"},{family:"Fascinate",variants:[400],category:"display"},{family:"Fascinate Inline",variants:[400],category:"display"},{family:"Faster One",variants:[400],category:"display"},{family:"Fasthand",variants:[400],category:"serif"},{family:"Fauna One",variants:[400],category:"serif"},{family:"Faustina",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"serif"},{family:"Federant",variants:[400],category:"display"},{family:"Federo",variants:[400],category:"sans-serif"},{family:"Felipa",variants:[400],category:"handwriting"},{family:"Fenix",variants:[400],category:"serif"},{family:"Finger Paint",variants:[400],category:"display"},{family:"Fira Code",variants:[300,400,500,600,700],category:"monospace"},{family:"Fira Mono",variants:[400,500,700],category:"monospace"},{family:"Fira Sans",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Fira Sans Condensed",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Fira Sans Extra Condensed",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Fjalla One",variants:[400],category:"sans-serif"},{family:"Fjord One",variants:[400],category:"serif"},{family:"Flamenco",variants:[300,400],category:"display"},{family:"Flavors",variants:[400],category:"display"},{family:"Fondamento",variants:[400,"400i"],category:"handwriting"},{family:"Fontdiner Swanky",variants:[400],category:"display"},{family:"Forum",variants:[400],category:"display"},{family:"Francois One",variants:[400],category:"sans-serif"},{family:"Frank Ruhl Libre",variants:[300,400,500,700,900],category:"serif"},{family:"Fraunces",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Freckle Face",variants:[400],category:"display"},{family:"Fredericka the Great",variants:[400],category:"display"},{family:"Fredoka One",variants:[400],category:"display"},{family:"Freehand",variants:[400],category:"display"},{family:"Fresca",variants:[400],category:"sans-serif"},{family:"Frijole",variants:[400],category:"display"},{family:"Fruktur",variants:[400],category:"display"},{family:"Fugaz One",variants:[400],category:"display"},{family:"GFS Didot",variants:[400],category:"serif"},{family:"GFS Neohellenic",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Gabriela",variants:[400],category:"serif"},{family:"Gaegu",variants:[300,400,700],category:"handwriting"},{family:"Gafata",variants:[400],category:"sans-serif"},{family:"Galada",variants:[400],category:"display"},{family:"Galdeano",variants:[400],category:"sans-serif"},{family:"Galindo",variants:[400],category:"display"},{family:"Gamja Flower",variants:[400],category:"handwriting"},{family:"Gayathri",variants:[100,400,700],category:"sans-serif"},{family:"Gelasio",variants:[400,"400i",500,"500i",600,"600i",700,"700i"],category:"serif"},{family:"Gentium Basic",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Gentium Book Basic",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Geo",variants:[400,"400i"],category:"sans-serif"},{family:"Geostar",variants:[400],category:"display"},{family:"Geostar Fill",variants:[400],category:"display"},{family:"Germania One",variants:[400],category:"display"},{family:"Gidugu",variants:[400],category:"sans-serif"},{family:"Gilda Display",variants:[400],category:"serif"},{family:"Girassol",variants:[400],category:"display"},{family:"Give You Glory",variants:[400],category:"handwriting"},{family:"Glass Antiqua",variants:[400],category:"display"},{family:"Glegoo",variants:[400,700],category:"serif"},{family:"Gloria Hallelujah",variants:[400],category:"handwriting"},{family:"Goblin One",variants:[400],category:"display"},{family:"Gochi Hand",variants:[400],category:"handwriting"},{family:"Goldman",variants:[400,700],category:"display"},{family:"Gorditas",variants:[400,700],category:"display"},{family:"Gothic A1",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Gotu",variants:[400],category:"sans-serif"},{family:"Goudy Bookletter 1911",variants:[400],category:"serif"},{family:"Graduate",variants:[400],category:"display"},{family:"Grand Hotel",variants:[400],category:"handwriting"},{family:"Grandstander",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"display"},{family:"Gravitas One",variants:[400],category:"display"},{family:"Great Vibes",variants:[400],category:"handwriting"},{family:"Grenze",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"serif"},{family:"Grenze Gotisch",variants:[100,200,300,400,500,600,700,800,900],category:"display"},{family:"Griffy",variants:[400],category:"display"},{family:"Gruppo",variants:[400],category:"display"},{family:"Gudea",variants:[400,"400i",700],category:"sans-serif"},{family:"Gugi",variants:[400],category:"display"},{family:"Gupter",variants:[400,500,700],category:"serif"},{family:"Gurajada",variants:[400],category:"serif"},{family:"Habibi",variants:[400],category:"serif"},{family:"Hachi Maru Pop",variants:[400],category:"handwriting"},{family:"Halant",variants:[300,400,500,600,700],category:"serif"},{family:"Hammersmith One",variants:[400],category:"sans-serif"},{family:"Hanalei",variants:[400],category:"display"},{family:"Hanalei Fill",variants:[400],category:"display"},{family:"Handlee",variants:[400],category:"handwriting"},{family:"Hanuman",variants:[400,700],category:"serif"},{family:"Happy Monkey",variants:[400],category:"display"},{family:"Harmattan",variants:[400,700],category:"sans-serif"},{family:"Headland One",variants:[400],category:"serif"},{family:"Heebo",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Henny Penny",variants:[400],category:"display"},{family:"Hepta Slab",variants:[100,200,300,400,500,600,700,800,900],category:"serif"},{family:"Herr Von Muellerhoff",variants:[400],category:"handwriting"},{family:"Hi Melody",variants:[400],category:"handwriting"},{family:"Hind",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Hind Guntur",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Hind Madurai",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Hind Siliguri",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Hind Vadodara",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Holtwood One SC",variants:[400],category:"serif"},{family:"Homemade Apple",variants:[400],category:"handwriting"},{family:"Homenaje",variants:[400],category:"sans-serif"},{family:"IBM Plex Mono",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"monospace"},{family:"IBM Plex Sans",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"IBM Plex Sans Condensed",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"IBM Plex Serif",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"serif"},{family:"IM Fell DW Pica",variants:[400,"400i"],category:"serif"},{family:"IM Fell DW Pica SC",variants:[400],category:"serif"},{family:"IM Fell Double Pica",variants:[400,"400i"],category:"serif"},{family:"IM Fell Double Pica SC",variants:[400],category:"serif"},{family:"IM Fell English",variants:[400,"400i"],category:"serif"},{family:"IM Fell English SC",variants:[400],category:"serif"},{family:"IM Fell French Canon",variants:[400,"400i"],category:"serif"},{family:"IM Fell French Canon SC",variants:[400],category:"serif"},{family:"IM Fell Great Primer",variants:[400,"400i"],category:"serif"},{family:"IM Fell Great Primer SC",variants:[400],category:"serif"},{family:"Ibarra Real Nova",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"serif"},{family:"Iceberg",variants:[400],category:"display"},{family:"Iceland",variants:[400],category:"display"},{family:"Imbue",variants:[100,200,300,400,500,600,700,800,900],category:"serif"},{family:"Imprima",variants:[400],category:"sans-serif"},{family:"Inconsolata",variants:[200,300,400,500,600,700,800,900],category:"monospace"},{family:"Inder",variants:[400],category:"sans-serif"},{family:"Indie Flower",variants:[400],category:"handwriting"},{family:"Inika",variants:[400,700],category:"serif"},{family:"Inknut Antiqua",variants:[300,400,500,600,700,800,900],category:"serif"},{family:"Inria Sans",variants:[300,"300i",400,"400i",700,"700i"],category:"sans-serif"},{family:"Inria Serif",variants:[300,"300i",400,"400i",700,"700i"],category:"serif"},{family:"Inter",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Irish Grover",variants:[400],category:"display"},{family:"Istok Web",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Italiana",variants:[400],category:"serif"},{family:"Italianno",variants:[400],category:"handwriting"},{family:"Itim",variants:[400],category:"handwriting"},{family:"Jacques Francois",variants:[400],category:"serif"},{family:"Jacques Francois Shadow",variants:[400],category:"display"},{family:"Jaldi",variants:[400,700],category:"sans-serif"},{family:"JetBrains Mono",variants:[100,200,300,400,500,600,700,800,"100i","200i","300i","400i","500i","600i","700i","800i"],category:"monospace"},{family:"Jim Nightshade",variants:[400],category:"handwriting"},{family:"Jockey One",variants:[400],category:"sans-serif"},{family:"Jolly Lodger",variants:[400],category:"display"},{family:"Jomhuria",variants:[400],category:"display"},{family:"Jomolhari",variants:[400],category:"serif"},{family:"Josefin Sans",variants:[100,200,300,400,500,600,700,"100i","200i","300i","400i","500i","600i","700i"],category:"sans-serif"},{family:"Josefin Slab",variants:[100,200,300,400,500,600,700,"100i","200i","300i","400i","500i","600i","700i"],category:"serif"},{family:"Jost",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Joti One",variants:[400],category:"display"},{family:"Jua",variants:[400],category:"sans-serif"},{family:"Judson",variants:[400,"400i",700],category:"serif"},{family:"Julee",variants:[400],category:"handwriting"},{family:"Julius Sans One",variants:[400],category:"sans-serif"},{family:"Junge",variants:[400],category:"serif"},{family:"Jura",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Just Another Hand",variants:[400],category:"handwriting"},{family:"Just Me Again Down Here",variants:[400],category:"handwriting"},{family:"K2D",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i"],category:"sans-serif"},{family:"Kadwa",variants:[400,700],category:"serif"},{family:"Kalam",variants:[300,400,700],category:"handwriting"},{family:"Kameron",variants:[400,700],category:"serif"},{family:"Kanit",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Kantumruy",variants:[300,400,700],category:"sans-serif"},{family:"Karantina",variants:[300,400,700],category:"display"},{family:"Karla",variants:[200,300,400,500,600,700,800,"200i","300i","400i","500i","600i","700i","800i"],category:"sans-serif"},{family:"Karma",variants:[300,400,500,600,700],category:"serif"},{family:"Katibeh",variants:[400],category:"display"},{family:"Kaushan Script",variants:[400],category:"handwriting"},{family:"Kavivanar",variants:[400],category:"handwriting"},{family:"Kavoon",variants:[400],category:"display"},{family:"Kdam Thmor",variants:[400],category:"display"},{family:"Keania One",variants:[400],category:"display"},{family:"Kelly Slab",variants:[400],category:"display"},{family:"Kenia",variants:[400],category:"display"},{family:"Khand",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Khmer",variants:[400],category:"display"},{family:"Khula",variants:[300,400,600,700,800],category:"sans-serif"},{family:"Kirang Haerang",variants:[400],category:"display"},{family:"Kite One",variants:[400],category:"sans-serif"},{family:"Kiwi Maru",variants:[300,400,500],category:"serif"},{family:"Knewave",variants:[400],category:"display"},{family:"KoHo",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Kodchasan",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Kosugi",variants:[400],category:"sans-serif"},{family:"Kosugi Maru",variants:[400],category:"sans-serif"},{family:"Kotta One",variants:[400],category:"serif"},{family:"Koulen",variants:[400],category:"display"},{family:"Kranky",variants:[400],category:"display"},{family:"Kreon",variants:[300,400,500,600,700],category:"serif"},{family:"Kristi",variants:[400],category:"handwriting"},{family:"Krona One",variants:[400],category:"sans-serif"},{family:"Krub",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Kufam",variants:[400,500,600,700,800,900,"400i","500i","600i","700i","800i","900i"],category:"display"},{family:"Kulim Park",variants:[200,"200i",300,"300i",400,"400i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Kumar One",variants:[400],category:"display"},{family:"Kumar One Outline",variants:[400],category:"display"},{family:"Kumbh Sans",variants:[300,400,700],category:"sans-serif"},{family:"Kurale",variants:[400],category:"serif"},{family:"La Belle Aurore",variants:[400],category:"handwriting"},{family:"Lacquer",variants:[400],category:"display"},{family:"Laila",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Lakki Reddy",variants:[400],category:"handwriting"},{family:"Lalezar",variants:[400],category:"display"},{family:"Lancelot",variants:[400],category:"display"},{family:"Langar",variants:[400],category:"display"},{family:"Lateef",variants:[400],category:"handwriting"},{family:"Lato",variants:[100,"100i",300,"300i",400,"400i",700,"700i",900,"900i"],category:"sans-serif"},{family:"League Script",variants:[400],category:"handwriting"},{family:"Leckerli One",variants:[400],category:"handwriting"},{family:"Ledger",variants:[400],category:"serif"},{family:"Lekton",variants:[400,"400i",700],category:"sans-serif"},{family:"Lemon",variants:[400],category:"display"},{family:"Lemonada",variants:[300,400,500,600,700],category:"display"},{family:"Lexend",variants:[100,300,400,500,600,700,800],category:"sans-serif"},{family:"Lexend Deca",variants:[400],category:"sans-serif"},{family:"Lexend Exa",variants:[400],category:"sans-serif"},{family:"Lexend Giga",variants:[400],category:"sans-serif"},{family:"Lexend Mega",variants:[400],category:"sans-serif"},{family:"Lexend Peta",variants:[400],category:"sans-serif"},{family:"Lexend Tera",variants:[400],category:"sans-serif"},{family:"Lexend Zetta",variants:[400],category:"sans-serif"},{family:"Libre Barcode 128",variants:[400],category:"display"},{family:"Libre Barcode 128 Text",variants:[400],category:"display"},{family:"Libre Barcode 39",variants:[400],category:"display"},{family:"Libre Barcode 39 Extended",variants:[400],category:"display"},{family:"Libre Barcode 39 Extended Text",variants:[400],category:"display"},{family:"Libre Barcode 39 Text",variants:[400],category:"display"},{family:"Libre Barcode EAN13 Text",variants:[400],category:"display"},{family:"Libre Baskerville",variants:[400,"400i",700],category:"serif"},{family:"Libre Caslon Display",variants:[400],category:"serif"},{family:"Libre Caslon Text",variants:[400,"400i",700],category:"serif"},{family:"Libre Franklin",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Life Savers",variants:[400,700,800],category:"display"},{family:"Lilita One",variants:[400],category:"display"},{family:"Lily Script One",variants:[400],category:"display"},{family:"Limelight",variants:[400],category:"display"},{family:"Linden Hill",variants:[400,"400i"],category:"serif"},{family:"Literata",variants:[200,300,400,500,600,700,800,900,"200i","300i","400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Liu Jian Mao Cao",variants:[400],category:"handwriting"},{family:"Livvic",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",900,"900i"],category:"sans-serif"},{family:"Lobster",variants:[400],category:"display"},{family:"Lobster Two",variants:[400,"400i",700,"700i"],category:"display"},{family:"Londrina Outline",variants:[400],category:"display"},{family:"Londrina Shadow",variants:[400],category:"display"},{family:"Londrina Sketch",variants:[400],category:"display"},{family:"Londrina Solid",variants:[100,300,400,900],category:"display"},{family:"Long Cang",variants:[400],category:"handwriting"},{family:"Lora",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"serif"},{family:"Love Ya Like A Sister",variants:[400],category:"display"},{family:"Loved by the King",variants:[400],category:"handwriting"},{family:"Lovers Quarrel",variants:[400],category:"handwriting"},{family:"Luckiest Guy",variants:[400],category:"display"},{family:"Lusitana",variants:[400,700],category:"serif"},{family:"Lustria",variants:[400],category:"serif"},{family:"M PLUS 1p",variants:[100,300,400,500,700,800,900],category:"sans-serif"},{family:"M PLUS Rounded 1c",variants:[100,300,400,500,700,800,900],category:"sans-serif"},{family:"Ma Shan Zheng",variants:[400],category:"handwriting"},{family:"Macondo",variants:[400],category:"display"},{family:"Macondo Swash Caps",variants:[400],category:"display"},{family:"Mada",variants:[200,300,400,500,600,700,900],category:"sans-serif"},{family:"Magra",variants:[400,700],category:"sans-serif"},{family:"Maiden Orange",variants:[400],category:"display"},{family:"Maitree",variants:[200,300,400,500,600,700],category:"serif"},{family:"Major Mono Display",variants:[400],category:"monospace"},{family:"Mako",variants:[400],category:"sans-serif"},{family:"Mali",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"handwriting"},{family:"Mallanna",variants:[400],category:"sans-serif"},{family:"Mandali",variants:[400],category:"sans-serif"},{family:"Manjari",variants:[100,400,700],category:"sans-serif"},{family:"Manrope",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"Mansalva",variants:[400],category:"handwriting"},{family:"Manuale",variants:[400,500,600,700,"400i","500i","600i","700i"],category:"serif"},{family:"Marcellus",variants:[400],category:"serif"},{family:"Marcellus SC",variants:[400],category:"serif"},{family:"Marck Script",variants:[400],category:"handwriting"},{family:"Margarine",variants:[400],category:"display"},{family:"Markazi Text",variants:[400,500,600,700],category:"serif"},{family:"Marko One",variants:[400],category:"serif"},{family:"Marmelad",variants:[400],category:"sans-serif"},{family:"Martel",variants:[200,300,400,600,700,800,900],category:"serif"},{family:"Martel Sans",variants:[200,300,400,600,700,800,900],category:"sans-serif"},{family:"Marvel",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Mate",variants:[400,"400i"],category:"serif"},{family:"Mate SC",variants:[400],category:"serif"},{family:"Maven Pro",variants:[400,500,600,700,800,900],category:"sans-serif"},{family:"McLaren",variants:[400],category:"display"},{family:"Meddon",variants:[400],category:"handwriting"},{family:"MedievalSharp",variants:[400],category:"display"},{family:"Medula One",variants:[400],category:"display"},{family:"Meera Inimai",variants:[400],category:"sans-serif"},{family:"Megrim",variants:[400],category:"display"},{family:"Meie Script",variants:[400],category:"handwriting"},{family:"Merienda",variants:[400,700],category:"handwriting"},{family:"Merienda One",variants:[400],category:"handwriting"},{family:"Merriweather",variants:[300,"300i",400,"400i",700,"700i",900,"900i"],category:"serif"},{family:"Merriweather Sans",variants:[300,400,500,600,700,800,"300i","400i","500i","600i","700i","800i"],category:"sans-serif"},{family:"Metal",variants:[400],category:"display"},{family:"Metal Mania",variants:[400],category:"display"},{family:"Metamorphous",variants:[400],category:"display"},{family:"Metrophobic",variants:[400],category:"sans-serif"},{family:"Michroma",variants:[400],category:"sans-serif"},{family:"Milonga",variants:[400],category:"display"},{family:"Miltonian",variants:[400],category:"display"},{family:"Miltonian Tattoo",variants:[400],category:"display"},{family:"Mina",variants:[400,700],category:"sans-serif"},{family:"Miniver",variants:[400],category:"display"},{family:"Miriam Libre",variants:[400,700],category:"sans-serif"},{family:"Mirza",variants:[400,500,600,700],category:"display"},{family:"Miss Fajardose",variants:[400],category:"handwriting"},{family:"Mitr",variants:[200,300,400,500,600,700],category:"sans-serif"},{family:"Modak",variants:[400],category:"display"},{family:"Modern Antiqua",variants:[400],category:"display"},{family:"Mogra",variants:[400],category:"display"},{family:"Molengo",variants:[400],category:"sans-serif"},{family:"Molle",variants:[400,"400i"],category:"handwriting"},{family:"Monda",variants:[400,700],category:"sans-serif"},{family:"Monofett",variants:[400],category:"display"},{family:"Monoton",variants:[400],category:"display"},{family:"Monsieur La Doulaise",variants:[400],category:"handwriting"},{family:"Montaga",variants:[400],category:"serif"},{family:"Montez",variants:[400],category:"handwriting"},{family:"Montserrat",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Montserrat Alternates",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Montserrat Subrayada",variants:[400,700],category:"sans-serif"},{family:"Moul",variants:[400],category:"display"},{family:"Moulpali",variants:[400],category:"display"},{family:"Mountains of Christmas",variants:[400,700],category:"display"},{family:"Mouse Memoirs",variants:[400],category:"sans-serif"},{family:"Mr Bedfort",variants:[400],category:"handwriting"},{family:"Mr Dafoe",variants:[400],category:"handwriting"},{family:"Mr De Haviland",variants:[400],category:"handwriting"},{family:"Mrs Saint Delafield",variants:[400],category:"handwriting"},{family:"Mrs Sheppards",variants:[400],category:"handwriting"},{family:"Mukta",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"Mukta Mahee",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"Mukta Malar",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"Mukta Vaani",variants:[200,300,400,500,600,700,800],category:"sans-serif"},{family:"Mulish",variants:[200,300,400,500,600,700,800,900,"200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"MuseoModerno",variants:[100,200,300,400,500,600,700,800,900],category:"display"},{family:"Mystery Quest",variants:[400],category:"display"},{family:"NTR",variants:[400],category:"sans-serif"},{family:"Nanum Brush Script",variants:[400],category:"handwriting"},{family:"Nanum Gothic",variants:[400,700,800],category:"sans-serif"},{family:"Nanum Gothic Coding",variants:[400,700],category:"monospace"},{family:"Nanum Myeongjo",variants:[400,700,800],category:"serif"},{family:"Nanum Pen Script",variants:[400],category:"handwriting"},{family:"Nerko One",variants:[400],category:"handwriting"},{family:"Neucha",variants:[400],category:"handwriting"},{family:"Neuton",variants:[200,300,400,"400i",700,800],category:"serif"},{family:"New Rocker",variants:[400],category:"display"},{family:"New Tegomin",variants:[400],category:"serif"},{family:"News Cycle",variants:[400,700],category:"sans-serif"},{family:"Newsreader",variants:[200,300,400,500,600,700,800,"200i","300i","400i","500i","600i","700i","800i"],category:"serif"},{family:"Niconne",variants:[400],category:"handwriting"},{family:"Niramit",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"sans-serif"},{family:"Nixie One",variants:[400],category:"display"},{family:"Nobile",variants:[400,"400i",500,"500i",700,"700i"],category:"sans-serif"},{family:"Nokora",variants:[400,700],category:"serif"},{family:"Norican",variants:[400],category:"handwriting"},{family:"Nosifer",variants:[400],category:"display"},{family:"Notable",variants:[400],category:"sans-serif"},{family:"Nothing You Could Do",variants:[400],category:"handwriting"},{family:"Noticia Text",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Noto Sans",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Noto Sans HK",variants:[100,300,400,500,700,900],category:"sans-serif"},{family:"Noto Sans JP",variants:[100,300,400,500,700,900],category:"sans-serif"},{family:"Noto Sans KR",variants:[100,300,400,500,700,900],category:"sans-serif"},{family:"Noto Sans SC",variants:[100,300,400,500,700,900],category:"sans-serif"},{family:"Noto Sans TC",variants:[100,300,400,500,700,900],category:"sans-serif"},{family:"Noto Serif",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Noto Serif JP",variants:[200,300,400,500,600,700,900],category:"serif"},{family:"Noto Serif KR",variants:[200,300,400,500,600,700,900],category:"serif"},{family:"Noto Serif SC",variants:[200,300,400,500,600,700,900],category:"serif"},{family:"Noto Serif TC",variants:[200,300,400,500,600,700,900],category:"serif"},{family:"Nova Cut",variants:[400],category:"display"},{family:"Nova Flat",variants:[400],category:"display"},{family:"Nova Mono",variants:[400],category:"monospace"},{family:"Nova Oval",variants:[400],category:"display"},{family:"Nova Round",variants:[400],category:"display"},{family:"Nova Script",variants:[400],category:"display"},{family:"Nova Slim",variants:[400],category:"display"},{family:"Nova Square",variants:[400],category:"display"},{family:"Numans",variants:[400],category:"sans-serif"},{family:"Nunito",variants:[200,"200i",300,"300i",400,"400i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Nunito Sans",variants:[200,"200i",300,"300i",400,"400i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Odibee Sans",variants:[400],category:"display"},{family:"Odor Mean Chey",variants:[400],category:"display"},{family:"Offside",variants:[400],category:"display"},{family:"Oi",variants:[400],category:"display"},{family:"Old Standard TT",variants:[400,"400i",700],category:"serif"},{family:"Oldenburg",variants:[400],category:"display"},{family:"Oleo Script",variants:[400,700],category:"display"},{family:"Oleo Script Swash Caps",variants:[400,700],category:"display"},{family:"Open Sans",variants:[300,"300i",400,"400i",600,"600i",700,"700i",800,"800i"],category:"sans-serif"},{family:"Open Sans Condensed",variants:[300,"300i",400,700],category:"sans-serif"},{family:"Oranienbaum",variants:[400],category:"serif"},{family:"Orbitron",variants:[400,500,600,700,800,900],category:"sans-serif"},{family:"Oregano",variants:[400,"400i"],category:"display"},{family:"Orelega One",variants:[400],category:"display"},{family:"Orienta",variants:[400],category:"sans-serif"},{family:"Original Surfer",variants:[400],category:"display"},{family:"Oswald",variants:[200,300,400,500,600,700],category:"sans-serif"},{family:"Over the Rainbow",variants:[400],category:"handwriting"},{family:"Overlock",variants:[400,"400i",700,"700i",900,"900i"],category:"display"},{family:"Overlock SC",variants:[400],category:"display"},{family:"Overpass",variants:[100,"100i",200,"200i",300,"300i",400,"400i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Overpass Mono",variants:[300,400,600,700],category:"monospace"},{family:"Ovo",variants:[400],category:"serif"},{family:"Oxanium",variants:[200,300,400,500,600,700,800],category:"display"},{family:"Oxygen",variants:[300,400,700],category:"sans-serif"},{family:"Oxygen Mono",variants:[400],category:"monospace"},{family:"PT Mono",variants:[400],category:"monospace"},{family:"PT Sans",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"PT Sans Caption",variants:[400,700],category:"sans-serif"},{family:"PT Sans Narrow",variants:[400,700],category:"sans-serif"},{family:"PT Serif",variants:[400,"400i",700,"700i"],category:"serif"},{family:"PT Serif Caption",variants:[400,"400i"],category:"serif"},{family:"Pacifico",variants:[400],category:"handwriting"},{family:"Padauk",variants:[400,700],category:"sans-serif"},{family:"Palanquin",variants:[100,200,300,400,500,600,700],category:"sans-serif"},{family:"Palanquin Dark",variants:[400,500,600,700],category:"sans-serif"},{family:"Pangolin",variants:[400],category:"handwriting"},{family:"Paprika",variants:[400],category:"display"},{family:"Parisienne",variants:[400],category:"handwriting"},{family:"Passero One",variants:[400],category:"display"},{family:"Passion One",variants:[400,700,900],category:"display"},{family:"Pathway Gothic One",variants:[400],category:"sans-serif"},{family:"Patrick Hand",variants:[400],category:"handwriting"},{family:"Patrick Hand SC",variants:[400],category:"handwriting"},{family:"Pattaya",variants:[400],category:"sans-serif"},{family:"Patua One",variants:[400],category:"display"},{family:"Pavanam",variants:[400],category:"sans-serif"},{family:"Paytone One",variants:[400],category:"sans-serif"},{family:"Peddana",variants:[400],category:"serif"},{family:"Peralta",variants:[400],category:"display"},{family:"Permanent Marker",variants:[400],category:"handwriting"},{family:"Petit Formal Script",variants:[400],category:"handwriting"},{family:"Petrona",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Philosopher",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Piazzolla",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Piedra",variants:[400],category:"display"},{family:"Pinyon Script",variants:[400],category:"handwriting"},{family:"Pirata One",variants:[400],category:"display"},{family:"Plaster",variants:[400],category:"display"},{family:"Play",variants:[400,700],category:"sans-serif"},{family:"Playball",variants:[400],category:"display"},{family:"Playfair Display",variants:[400,500,600,700,800,900,"400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Playfair Display SC",variants:[400,"400i",700,"700i",900,"900i"],category:"serif"},{family:"Podkova",variants:[400,500,600,700,800],category:"serif"},{family:"Poiret One",variants:[400],category:"display"},{family:"Poller One",variants:[400],category:"display"},{family:"Poly",variants:[400,"400i"],category:"serif"},{family:"Pompiere",variants:[400],category:"display"},{family:"Pontano Sans",variants:[400],category:"sans-serif"},{family:"Poor Story",variants:[400],category:"display"},{family:"Poppins",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Port Lligat Sans",variants:[400],category:"sans-serif"},{family:"Port Lligat Slab",variants:[400],category:"serif"},{family:"Potta One",variants:[400],category:"display"},{family:"Pragati Narrow",variants:[400,700],category:"sans-serif"},{family:"Prata",variants:[400],category:"serif"},{family:"Preahvihear",variants:[400],category:"display"},{family:"Press Start 2P",variants:[400],category:"display"},{family:"Pridi",variants:[200,300,400,500,600,700],category:"serif"},{family:"Princess Sofia",variants:[400],category:"handwriting"},{family:"Prociono",variants:[400],category:"serif"},{family:"Prompt",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Prosto One",variants:[400],category:"display"},{family:"Proza Libre",variants:[400,"400i",500,"500i",600,"600i",700,"700i",800,"800i"],category:"sans-serif"},{family:"Public Sans",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Puritan",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Purple Purse",variants:[400],category:"display"},{family:"Quando",variants:[400],category:"serif"},{family:"Quantico",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Quattrocento",variants:[400,700],category:"serif"},{family:"Quattrocento Sans",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Questrial",variants:[400],category:"sans-serif"},{family:"Quicksand",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Quintessential",variants:[400],category:"handwriting"},{family:"Qwigley",variants:[400],category:"handwriting"},{family:"Racing Sans One",variants:[400],category:"display"},{family:"Radley",variants:[400,"400i"],category:"serif"},{family:"Rajdhani",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Rakkas",variants:[400],category:"display"},{family:"Raleway",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Raleway Dots",variants:[400],category:"display"},{family:"Ramabhadra",variants:[400],category:"sans-serif"},{family:"Ramaraja",variants:[400],category:"serif"},{family:"Rambla",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Rammetto One",variants:[400],category:"display"},{family:"Ranchers",variants:[400],category:"display"},{family:"Rancho",variants:[400],category:"handwriting"},{family:"Ranga",variants:[400,700],category:"display"},{family:"Rasa",variants:[300,400,500,600,700],category:"serif"},{family:"Rationale",variants:[400],category:"sans-serif"},{family:"Ravi Prakash",variants:[400],category:"display"},{family:"Recursive",variants:[300,400,500,600,700,800,900],category:"sans-serif"},{family:"Red Hat Display",variants:[400,"400i",500,"500i",700,"700i",900,"900i"],category:"sans-serif"},{family:"Red Hat Text",variants:[400,"400i",500,"500i",700,"700i"],category:"sans-serif"},{family:"Red Rose",variants:[300,400,500,600,700],category:"display"},{family:"Redressed",variants:[400],category:"handwriting"},{family:"Reem Kufi",variants:[400],category:"sans-serif"},{family:"Reenie Beanie",variants:[400],category:"handwriting"},{family:"Reggae One",variants:[400],category:"display"},{family:"Revalia",variants:[400],category:"display"},{family:"Rhodium Libre",variants:[400],category:"serif"},{family:"Ribeye",variants:[400],category:"display"},{family:"Ribeye Marrow",variants:[400],category:"display"},{family:"Righteous",variants:[400],category:"display"},{family:"Risque",variants:[400],category:"display"},{family:"Roboto",variants:[100,"100i",300,"300i",400,"400i",500,"500i",700,"700i",900,"900i"],category:"sans-serif"},{family:"Roboto Condensed",variants:[300,"300i",400,"400i",700,"700i"],category:"sans-serif"},{family:"Roboto Mono",variants:[100,200,300,400,500,600,700,"100i","200i","300i","400i","500i","600i","700i"],category:"monospace"},{family:"Roboto Slab",variants:[100,200,300,400,500,600,700,800,900],category:"serif"},{family:"Rochester",variants:[400],category:"handwriting"},{family:"Rock Salt",variants:[400],category:"handwriting"},{family:"RocknRoll One",variants:[400],category:"sans-serif"},{family:"Rokkitt",variants:[100,200,300,400,500,600,700,800,900],category:"serif"},{family:"Romanesco",variants:[400],category:"handwriting"},{family:"Ropa Sans",variants:[400,"400i"],category:"sans-serif"},{family:"Rosario",variants:[300,400,500,600,700,"300i","400i","500i","600i","700i"],category:"sans-serif"},{family:"Rosarivo",variants:[400,"400i"],category:"serif"},{family:"Rouge Script",variants:[400],category:"handwriting"},{family:"Rowdies",variants:[300,400,700],category:"display"},{family:"Rozha One",variants:[400],category:"serif"},{family:"Rubik",variants:[300,400,500,600,700,800,900,"300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Rubik Mono One",variants:[400],category:"sans-serif"},{family:"Ruda",variants:[400,500,600,700,800,900],category:"sans-serif"},{family:"Rufina",variants:[400,700],category:"serif"},{family:"Ruge Boogie",variants:[400],category:"handwriting"},{family:"Ruluko",variants:[400],category:"sans-serif"},{family:"Rum Raisin",variants:[400],category:"sans-serif"},{family:"Ruslan Display",variants:[400],category:"display"},{family:"Russo One",variants:[400],category:"sans-serif"},{family:"Ruthie",variants:[400],category:"handwriting"},{family:"Rye",variants:[400],category:"display"},{family:"Sacramento",variants:[400],category:"handwriting"},{family:"Sahitya",variants:[400,700],category:"serif"},{family:"Sail",variants:[400],category:"display"},{family:"Saira",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Saira Condensed",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Saira Extra Condensed",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Saira Semi Condensed",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Saira Stencil One",variants:[400],category:"display"},{family:"Salsa",variants:[400],category:"display"},{family:"Sanchez",variants:[400,"400i"],category:"serif"},{family:"Sancreek",variants:[400],category:"display"},{family:"Sansita",variants:[400,"400i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Sansita Swashed",variants:[300,400,500,600,700,800,900],category:"display"},{family:"Sarabun",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i"],category:"sans-serif"},{family:"Sarala",variants:[400,700],category:"sans-serif"},{family:"Sarina",variants:[400],category:"display"},{family:"Sarpanch",variants:[400,500,600,700,800,900],category:"sans-serif"},{family:"Satisfy",variants:[400],category:"handwriting"},{family:"Sawarabi Gothic",variants:[400],category:"sans-serif"},{family:"Sawarabi Mincho",variants:[400],category:"sans-serif"},{family:"Scada",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"Scheherazade",variants:[400,700],category:"serif"},{family:"Schoolbell",variants:[400],category:"handwriting"},{family:"Scope One",variants:[400],category:"serif"},{family:"Seaweed Script",variants:[400],category:"display"},{family:"Secular One",variants:[400],category:"sans-serif"},{family:"Sedgwick Ave",variants:[400],category:"handwriting"},{family:"Sedgwick Ave Display",variants:[400],category:"handwriting"},{family:"Sen",variants:[400,700,800],category:"sans-serif"},{family:"Sevillana",variants:[400],category:"display"},{family:"Seymour One",variants:[400],category:"sans-serif"},{family:"Shadows Into Light",variants:[400],category:"handwriting"},{family:"Shadows Into Light Two",variants:[400],category:"handwriting"},{family:"Shanti",variants:[400],category:"sans-serif"},{family:"Share",variants:[400,"400i",700,"700i"],category:"display"},{family:"Share Tech",variants:[400],category:"sans-serif"},{family:"Share Tech Mono",variants:[400],category:"monospace"},{family:"Shippori Mincho",variants:[400,500,600,700,800],category:"serif"},{family:"Shippori Mincho B1",variants:[400,500,600,700,800],category:"serif"},{family:"Shojumaru",variants:[400],category:"display"},{family:"Short Stack",variants:[400],category:"handwriting"},{family:"Shrikhand",variants:[400],category:"display"},{family:"Siemreap",variants:[400],category:"display"},{family:"Sigmar One",variants:[400],category:"display"},{family:"Signika",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Signika Negative",variants:[300,400,600,700],category:"sans-serif"},{family:"Simonetta",variants:[400,"400i",900,"900i"],category:"display"},{family:"Single Day",variants:[400],category:"display"},{family:"Sintony",variants:[400,700],category:"sans-serif"},{family:"Sirin Stencil",variants:[400],category:"display"},{family:"Six Caps",variants:[400],category:"sans-serif"},{family:"Skranji",variants:[400,700],category:"display"},{family:"Slabo 13px",variants:[400],category:"serif"},{family:"Slabo 27px",variants:[400],category:"serif"},{family:"Slackey",variants:[400],category:"display"},{family:"Smokum",variants:[400],category:"display"},{family:"Smythe",variants:[400],category:"display"},{family:"Sniglet",variants:[400,800],category:"display"},{family:"Snippet",variants:[400],category:"sans-serif"},{family:"Snowburst One",variants:[400],category:"display"},{family:"Sofadi One",variants:[400],category:"display"},{family:"Sofia",variants:[400],category:"handwriting"},{family:"Solway",variants:[300,400,500,700,800],category:"serif"},{family:"Song Myung",variants:[400],category:"serif"},{family:"Sonsie One",variants:[400],category:"display"},{family:"Sora",variants:[100,200,300,400,500,600,700,800],category:"sans-serif"},{family:"Sorts Mill Goudy",variants:[400,"400i"],category:"serif"},{family:"Source Code Pro",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",900,"900i"],category:"monospace"},{family:"Source Sans Pro",variants:[200,"200i",300,"300i",400,"400i",600,"600i",700,"700i",900,"900i"],category:"sans-serif"},{family:"Source Serif Pro",variants:[200,"200i",300,"300i",400,"400i",600,"600i",700,"700i",900,"900i"],category:"serif"},{family:"Space Grotesk",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Space Mono",variants:[400,"400i",700,"700i"],category:"monospace"},{family:"Spartan",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Special Elite",variants:[400],category:"display"},{family:"Spectral",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i"],category:"serif"},{family:"Spectral SC",variants:[200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i"],category:"serif"},{family:"Spicy Rice",variants:[400],category:"display"},{family:"Spinnaker",variants:[400],category:"sans-serif"},{family:"Spirax",variants:[400],category:"display"},{family:"Squada One",variants:[400],category:"display"},{family:"Sree Krushnadevaraya",variants:[400],category:"serif"},{family:"Sriracha",variants:[400],category:"handwriting"},{family:"Srisakdi",variants:[400,700],category:"display"},{family:"Staatliches",variants:[400],category:"display"},{family:"Stalemate",variants:[400],category:"handwriting"},{family:"Stalinist One",variants:[400],category:"display"},{family:"Stardos Stencil",variants:[400,700],category:"display"},{family:"Stick",variants:[400],category:"sans-serif"},{family:"Stint Ultra Condensed",variants:[400],category:"display"},{family:"Stint Ultra Expanded",variants:[400],category:"display"},{family:"Stoke",variants:[300,400],category:"serif"},{family:"Strait",variants:[400],category:"sans-serif"},{family:"Stylish",variants:[400],category:"sans-serif"},{family:"Sue Ellen Francisco",variants:[400],category:"handwriting"},{family:"Suez One",variants:[400],category:"serif"},{family:"Sulphur Point",variants:[300,400,700],category:"sans-serif"},{family:"Sumana",variants:[400,700],category:"serif"},{family:"Sunflower",variants:[300,400,500,700],category:"sans-serif"},{family:"Sunshiney",variants:[400],category:"handwriting"},{family:"Supermercado One",variants:[400],category:"display"},{family:"Sura",variants:[400,700],category:"serif"},{family:"Suranna",variants:[400],category:"serif"},{family:"Suravaram",variants:[400],category:"serif"},{family:"Suwannaphum",variants:[400],category:"display"},{family:"Swanky and Moo Moo",variants:[400],category:"handwriting"},{family:"Syncopate",variants:[400,700],category:"sans-serif"},{family:"Syne",variants:[400,500,600,700,800],category:"sans-serif"},{family:"Syne Mono",variants:[400],category:"monospace"},{family:"Syne Tactile",variants:[400],category:"display"},{family:"Tajawal",variants:[200,300,400,500,700,800,900],category:"sans-serif"},{family:"Tangerine",variants:[400,700],category:"handwriting"},{family:"Taprom",variants:[400],category:"display"},{family:"Tauri",variants:[400],category:"sans-serif"},{family:"Taviraj",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"serif"},{family:"Teko",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Telex",variants:[400],category:"sans-serif"},{family:"Tenali Ramakrishna",variants:[400],category:"sans-serif"},{family:"Tenor Sans",variants:[400],category:"sans-serif"},{family:"Text Me One",variants:[400],category:"sans-serif"},{family:"Texturina",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Thasadith",variants:[400,"400i",700,"700i"],category:"sans-serif"},{family:"The Girl Next Door",variants:[400],category:"handwriting"},{family:"Tienne",variants:[400,700,900],category:"serif"},{family:"Tillana",variants:[400,500,600,700,800],category:"handwriting"},{family:"Timmana",variants:[400],category:"sans-serif"},{family:"Tinos",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Titan One",variants:[400],category:"display"},{family:"Titillium Web",variants:[200,"200i",300,"300i",400,"400i",600,"600i",700,"700i",900],category:"sans-serif"},{family:"Tomorrow",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"sans-serif"},{family:"Trade Winds",variants:[400],category:"display"},{family:"Train One",variants:[400],category:"display"},{family:"Trirong",variants:[100,"100i",200,"200i",300,"300i",400,"400i",500,"500i",600,"600i",700,"700i",800,"800i",900,"900i"],category:"serif"},{family:"Trispace",variants:[100,200,300,400,500,600,700,800],category:"sans-serif"},{family:"Trocchi",variants:[400],category:"serif"},{family:"Trochut",variants:[400,"400i",700],category:"display"},{family:"Truculenta",variants:[100,200,300,400,500,600,700,800,900],category:"sans-serif"},{family:"Trykker",variants:[400],category:"serif"},{family:"Tulpen One",variants:[400],category:"display"},{family:"Turret Road",variants:[200,300,400,500,700,800],category:"display"},{family:"Ubuntu",variants:[300,"300i",400,"400i",500,"500i",700,"700i"],category:"sans-serif"},{family:"Ubuntu Condensed",variants:[400],category:"sans-serif"},{family:"Ubuntu Mono",variants:[400,"400i",700,"700i"],category:"monospace"},{family:"Ultra",variants:[400],category:"serif"},{family:"Uncial Antiqua",variants:[400],category:"display"},{family:"Underdog",variants:[400],category:"display"},{family:"Unica One",variants:[400],category:"display"},{family:"UnifrakturCook",variants:[400,700],category:"display"},{family:"UnifrakturMaguntia",variants:[400],category:"display"},{family:"Unkempt",variants:[400,700],category:"display"},{family:"Unlock",variants:[400],category:"display"},{family:"Unna",variants:[400,"400i",700,"700i"],category:"serif"},{family:"VT323",variants:[400],category:"monospace"},{family:"Vampiro One",variants:[400],category:"display"},{family:"Varela",variants:[400],category:"sans-serif"},{family:"Varela Round",variants:[400],category:"sans-serif"},{family:"Varta",variants:[300,400,500,600,700],category:"sans-serif"},{family:"Vast Shadow",variants:[400],category:"display"},{family:"Vesper Libre",variants:[400,500,700,900],category:"serif"},{family:"Viaoda Libre",variants:[400],category:"display"},{family:"Vibes",variants:[400],category:"display"},{family:"Vibur",variants:[400],category:"handwriting"},{family:"Vidaloka",variants:[400],category:"serif"},{family:"Viga",variants:[400],category:"sans-serif"},{family:"Voces",variants:[400],category:"display"},{family:"Volkhov",variants:[400,"400i",700,"700i"],category:"serif"},{family:"Vollkorn",variants:[400,500,600,700,800,900,"400i","500i","600i","700i","800i","900i"],category:"serif"},{family:"Vollkorn SC",variants:[400,600,700,900],category:"serif"},{family:"Voltaire",variants:[400],category:"sans-serif"},{family:"Waiting for the Sunrise",variants:[400],category:"handwriting"},{family:"Wallpoet",variants:[400],category:"display"},{family:"Walter Turncoat",variants:[400],category:"handwriting"},{family:"Warnes",variants:[400],category:"display"},{family:"Wellfleet",variants:[400],category:"display"},{family:"Wendy One",variants:[400],category:"sans-serif"},{family:"Wire One",variants:[400],category:"sans-serif"},{family:"Work Sans",variants:[100,200,300,400,500,600,700,800,900,"100i","200i","300i","400i","500i","600i","700i","800i","900i"],category:"sans-serif"},{family:"Xanh Mono",variants:[400,"400i"],category:"monospace"},{family:"Yanone Kaffeesatz",variants:[200,300,400,500,600,700],category:"sans-serif"},{family:"Yantramanav",variants:[100,300,400,500,700,900],category:"sans-serif"},{family:"Yatra One",variants:[400],category:"display"},{family:"Yellowtail",variants:[400],category:"handwriting"},{family:"Yeon Sung",variants:[400],category:"display"},{family:"Yeseva One",variants:[400],category:"display"},{family:"Yesteryear",variants:[400],category:"handwriting"},{family:"Yrsa",variants:[300,400,500,600,700],category:"serif"},{family:"Yusei Magic",variants:[400],category:"sans-serif"},{family:"ZCOOL KuaiLe",variants:[400],category:"display"},{family:"ZCOOL QingKe HuangYou",variants:[400],category:"display"},{family:"ZCOOL XiaoWei",variants:[400],category:"serif"},{family:"Zen Dots",variants:[400],category:"display"},{family:"Zeyada",variants:[400],category:"handwriting"},{family:"Zhi Mang Xing",variants:[400],category:"handwriting"},{family:"Zilla Slab",variants:[300,"300i",400,"400i",500,"500i",600,"600i",700,"700i"],category:"serif"},{family:"Zilla Slab Highlight",variants:[400,700],category:"display"}],Qn=[{label:(0,c.__)("Normal"),value:"normal"},{label:(0,c.__)("Italic"),value:"italic"},{label:(0,c.__)("Oblique"),value:"oblique"}],Xn=[{label:(0,c.__)("None"),value:"none",icon:"NO"},{label:(0,c.__)("Capitalize"),value:"capitalize",icon:"Aa"},{label:(0,c.__)("Uppercase"),value:"uppercase",icon:"AA"},{label:(0,c.__)("Lowercase"),value:"lowercase",icon:"aa"}],Zn=[{label:(0,c.__)("Default"),value:"auto"},{label:(0,c.__)("Underline"),value:"underline"},{label:(0,c.__)("Overline"),value:"overline"},{label:(0,c.__)("Line Through"),value:"line-through"},{label:(0,c.__)("None"),value:"none"}],Jn=e=>{const{className:t="",label:n=(0,c.__)("Typography:"),value:r,onChange:o,defaults:a={},isFamily:s=!0}=e,l={fontFamily:"Default",fontCategory:"sans-serif",fontWeight:null,isUploadFont:!0,fontSize:{desktop:null,tablet:null,mobile:null},fontStyle:null,textTransform:null,textDecoration:null,lineHeight:null,letterSpace:null},u=e=>a?.[e]||l[e],h=e=>void 0===r?.[e]?u(e):r?.[e],p=e=>r?.[e]&&r?.[e]!==u(e)&&(0,i.createElement)(d.Button,{icon:"image-rotate",className:"bPlResetVal",onClick:()=>(e=>o({...r,[e]:u(e)}))(e)}),[g,f]=(0,i.useState)("desktop"),[m,y]=(0,i.useState)(""),[v,b]=(0,i.useState)(!1),w=qn.filter((({family:e})=>e.toLowerCase().includes(m.toLowerCase()))),C=()=>{const e=qn.find((e=>e.family===h("fontFamily")))?.variants;let t=[];return e?.map((e=>t?.push({label:e,value:e}))),0===t.length?[400]:t},x=(e,t,n)=>{const i=yt(r,(i=>{i[e]=n?{...i[e],[n]:t}:t}));o(i)};return(0,i.createElement)(d.PanelRow,{className:`bPlDropdown ${t}`},(0,i.createElement)(Pn,{className:""},n),(0,i.createElement)(d.Dropdown,{className:"bPlDropdownContainer",contentClassName:"bPlDropdownPopover",popoverProps:{placement:"bottom-end"},renderToggle:({isOpen:e,onToggle:t})=>(0,i.createElement)(d.Button,{icon:"admin-customizer",onClick:t,"aria-expanded":e}),renderContent:()=>(0,i.createElement)(i.Fragment,null,s?(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelRow,{className:"bPlTypoFontTitle"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Font Family:")),(0,i.createElement)(Pn,{className:""},(0,c.__)("Weight:"))),(0,i.createElement)(d.PanelRow,{className:"bPlTypoFont"},(0,i.createElement)("div",{className:"bPlTypoFontSelect"},(0,i.createElement)("input",{type:"search",value:m,onClick:()=>b(!v),placeholder:h("fontFamily")||"Search Font",onChange:e=>y(e.target.value)}),(0,i.createElement)("span",{className:`dashicon dashicons dashicons-${v?"arrow-up":"arrow-down"} `,onClick:()=>b(!v)}),v&&(0,i.createElement)("ul",{className:"bPlTypoFontLists"},w?.map((e=>(0,i.createElement)("li",{key:e?.family,onClick:()=>{o({...r,fontFamily:e?.family,fontCategory:e?.category||"sans-serif",fontWeight:400,fontVariant:400}),y(""),b(!1)}},e?.family))))),(0,i.createElement)(d.SelectControl,{value:h("fontVariant"),onChange:e=>{o({...r,fontWeight:parseInt(e?.replace("00i","00")),fontVariant:e})},options:C()})),(0,i.createElement)(d.ToggleControl,{className:"mt10",label:(0,c.__)("Load Google Font"),checked:h("isUploadFont"),onChange:e=>x("isUploadFont",e)})):(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Weight:")),(0,i.createElement)(d.SelectControl,{value:h("fontWeight"),onChange:e=>x("fontWeight",e),options:C()})),(0,i.createElement)(d.Flex,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Font Size:")),(0,i.createElement)(Vn,{device:g,onChange:e=>f(e)}),(0,i.createElement)(d.__experimentalUnitControl,{value:h("fontSize")?.[g]||h("fontSize"),onChange:e=>x("fontSize",e,g),units:[se(16),de(1),ce(1),ue(.85)],style:{width:"100px"}})),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Font Style:")),(0,i.createElement)(d.SelectControl,{value:h("fontStyle"),onChange:e=>x("fontStyle",e),options:Qn}),p("fontStyle")),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:"mt5"},(0,c.__)("Text Transform:")),(0,i.createElement)(Se,{value:h("textTransform"),onChange:e=>x("textTransform",e),options:Xn,isTextIcon:!0})),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Text Decoration:")),(0,i.createElement)(d.SelectControl,{value:h("textDecoration"),onChange:e=>x("textDecoration",e),options:Zn}),p("textDecoration")),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Line Height:"),labelPosition:"left",value:h("lineHeight"),onChange:e=>x("lineHeight",e),units:[se(24),le(135),ce(2),de(2)],isResetValueOnUnitChange:!0}),p("lineHeight")),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(d.__experimentalUnitControl,{label:(0,c.__)("Letter Spacing:"),labelPosition:"left",value:h("letterSpace"),onChange:e=>x("letterSpace",e),units:[se(),ce(),de()]}),p("letterSpace")))}))},ei=()=>(0,i.createElement)("span",null,"Need more block like this? Checkout the bundle âž¡ ",(0,i.createElement)("a",{href:"https://wordpress.org/plugins/b-blocks",target:"_blank",rel:"noopener noreferrer"},"B Blocks")),ti=({isProModalOpen:e,setIsProModalOpen:t,link:n,children:r})=>e&&(0,i.createElement)(d.Modal,{className:"bplAboutProModal",title:(0,c.__)("Upgrade to PRO"),onRequestClose:()=>t(!1)},(0,i.createElement)("h3",null,(0,c.__)("Explore new features in Pro")),(0,i.createElement)("ul",{className:"features"},r),(0,i.createElement)("h4",{className:"text"},(0,c.__)("To unlock those features! Upgrade to Pro")),(0,i.createElement)("a",{className:"upgradeNow",href:n,target:"_blank",rel:"noreferrer"},(0,c.__)("Upgrade Now"))),ni=({label:e,className:t,onChange:n,isPremium:r=!1,Component:o,setIsProModalOpen:a=()=>{},...s})=>(0,i.createElement)(o,{className:`${t} ${r?"":"bplProIdentifier"}`,label:(e=>r?e:(0,i.createElement)(i.Fragment,null,(0,i.createElement)("span",{className:"bplOpacity75"},e)," ",(0,i.createElement)("span",{className:"labelPro"},(0,c.__)("Pro"))))(e),onChange:e=>r?n(e):a(!0),isPremium:r,...s}),ii=({className:e,onChange:t,isPremium:n=!1,setIsProModalOpen:r=()=>{},options:o=[],proValues:a=[],...s})=>{const l=o.map((e=>({...e,label:a?.includes(e.value)&&!n?`${e.label} - Pro`:e.label}))),c=(0,i.useRef)(null);return(0,i.useEffect)((()=>{const e=c?.current;if(e&&!n){const t=e?.childNodes;t?.forEach((e=>{a?.includes(e.value)&&e.classList.add("proOption")}))}}),[c,a]),(0,i.createElement)(d.SelectControl,{ref:c,className:`${e} ${n?"":"bplPorSelect"}`,onChange:e=>n?t(e):a?.includes(e)?r(!0):t(e),options:l,...s})},ri=e=>{const{className:t,label:n,value:r,onChange:o,options:a,isIcon:s=!1,isTextIcon:l=!1,size:c="compact",isPremium:u=!1,setIsProModalOpen:h=()=>{},proValues:p}=e,g=a.map((e=>({...e,className:p?.includes(e.value)&&!u?"bplProGroupBtn":""}))),f=({className:e=""})=>(0,i.createElement)(d.ButtonGroup,{className:`bPlBtnGroup ${e||null}`},g?.map((e=>{const{className:t="",value:n,icon:a="",label:g="",def:f=""}=e,m=r===n;return(0,i.createElement)(d.Button,{key:n,className:t,label:g,showTooltip:!0,tooltipPosition:"top",icon:s?a:null,variant:m?"primary":"","aria-pressed":m,size:c,onClick:()=>u?o(n,f&&f):p?.includes(n)?h(!0):o(n,f&&f)},l?a:s?"":g)})));return n?(0,i.createElement)(d.PanelRow,{className:t},(0,i.createElement)(Pn,{className:""},n),(0,i.createElement)(f,null)):(0,i.createElement)(f,{className:t})},oi=((0,o.withSelect)((e=>({currentPostType:e("core/editor").getCurrentPostType()})))((({postType:e,shortCode:t,currentPostType:n})=>{const r=(0,i.useRef)(null);return e===n&&(0,i.createElement)("div",{className:"bPlFrontShortCode"},(0,i.createElement)(Pn,{className:"mb5"},(0,c.__)("Copy the shortcode and use it anywhere.")),(0,i.createElement)("div",{className:"bPlFrontShortCodeInput"},(0,i.createElement)("input",{onClick:e=>{const t=e.target;t.select(),t.setSelectionRange(0,30),document.execCommand("copy"),r.current.innerHTML=(0,c.__)("Copied Successfully!"),setTimeout((()=>{r.current.innerHTML=(0,c.__)("Copy To Clipboard")}),1500)},value:t}),(0,i.createElement)("span",{ref:r,className:"tooltip"},(0,c.__)("Copy To Clipboard"))))})),"#4527a4"),ai=(e=24)=>(0,i.createElement)("svg",{width:e,height:e,viewBox:"0 0 512 512"},(0,i.createElement)("path",{fill:oi,d:"m294.416 447.644 56.28-62.302-47.401-27.367-25.815 79.891c-3.315 10.257 9.71 17.777 16.936 9.778z"}),(0,i.createElement)("path",{fill:oi,d:"m496.995 77.21c-14.349-8.284-32.696-3.368-40.981 10.981l-15 25.981 51.962 30 15-25.981c8.284-14.349 3.368-32.696-10.981-40.981z"}),(0,i.createElement)("path",{fill:oi,d:"m301.995 246.396h160v60h-160z",transform:"matrix(.5 -.866 .866 .5 -48.368 469.016)"}),(0,i.createElement)("path",{fill:oi,d:"m429.495 138.143h30v60h-30z",transform:"matrix(.5 -.866 .866 .5 76.632 469.016)"}),(0,i.createElement)("path",{fill:oi,d:"m302 0h-247c-30.376 0-55 24.624-55 55v25h302z"}),(0,i.createElement)("path",{fill:oi,d:"m131.607 225.393 19.199 19.199 28.194-37.592c6-8 18-8 24 0l33 44v-80h-160v88.787l34.393-34.394c5.858-5.858 15.356-5.858 21.214 0z"}),(0,i.createElement)("path",{fill:oi,d:"m97.213 281h47.574l-23.787-23.787z"}),(0,i.createElement)("path",{fill:oi,d:"m172.234 266.021 14.979 14.979h33.787l-30-40z"}),(0,i.createElement)("path",{fill:oi,d:"m432 69.786v-14.786c0-30.376-24.624-55-55-55h-45v80h94.103z"}),(0,i.createElement)("path",{fill:oi,d:"m380.317 397.305-63.64 70.449c-7.603 8.418-18.376 13.246-29.551 13.246-.001 0 0 0-.001 0-12.838 0-25.024-6.214-32.599-16.622-2.991-4.11-5.101-8.641-6.329-13.378h-187.197c-8.284 0-15-6.716-15-15s6.716-15 15-15h190.402l12.925-40h-203.327c-8.284 0-15-6.716-15-15s6.716-15 15-15h213.021l4.102-12.695c.974-3.015 2.264-5.919 3.849-8.663l126.81-219.642h-408.782v347c0 30.376 24.624 55 55 55h322c30.376 0 55-24.624 55-55v-147.215l-46.104 79.855c-1.585 2.744-3.455 5.314-5.579 7.665zm-334.317-241.305c0-8.284 6.716-15 15-15h190c8.284 0 15 6.716 15 15v140c0 8.284-6.716 15-15 15h-190c-8.284 0-15-6.716-15-15z"})),si=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 271.673 271.673"},(0,i.createElement)("path",{d:"M114.939,0H10.449C4.678,0,0,4.678,0,10.449v104.49c0,5.771,4.678,10.449,10.449,10.449h104.49 c5.771,0,10.449-4.678,10.449-10.449V10.449C125.388,4.678,120.71,0,114.939,0z"}),(0,i.createElement)("path",{d:"M261.224,0h-104.49c-5.771,0-10.449,4.678-10.449,10.449v104.49c0,5.771,4.678,10.449,10.449,10.449h104.49 c5.771,0,10.449-4.678,10.449-10.449V10.449C271.673,4.678,266.995,0,261.224,0z"}),(0,i.createElement)("path",{d:"M114.939,146.286H10.449C4.678,146.286,0,150.964,0,156.735v104.49c0,5.771,4.678,10.449,10.449,10.449h104.49 c5.771,0,10.449-4.678,10.449-10.449v-104.49C125.388,150.964,120.71,146.286,114.939,146.286z"}),(0,i.createElement)("path",{d:"M261.224,146.286h-104.49c-5.771,0-10.449,4.678-10.449,10.449v104.49c0,5.771,4.678,10.449,10.449,10.449h104.49 c5.771,0,10.449-4.678,10.449-10.449v-104.49C271.673,150.964,266.995,146.286,261.224,146.286z"})),li=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 500 500"},(0,i.createElement)("path",{d:"M0 0L220 0L220 500L0 500L0 0Z"}),(0,i.createElement)("path",{d:"M280 280L500 280L500 500L280 500L280 280Z"}),(0,i.createElement)("path",{d:"M280 0L370 0L370 220L280 220L280 0Z"}),(0,i.createElement)("path",{d:"M410 0L500 0L500 220L410 220L410 0Z"})),ci=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 48 48"},(0,i.createElement)("rect",{height:"29.498",width:"21.07",y:"-0.033"}),(0,i.createElement)("rect",{height:"29.498",width:"21.07",x:"26.93",y:"18.535"}),(0,i.createElement)("rect",{height:"13.695",width:"21.07",x:"26.93",y:"-0.033"}),(0,i.createElement)("rect",{height:"13.695",width:"21.07",y:"34.338"})),di=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24"},(0,i.createElement)("circle",{cx:"7",cy:"18",r:"1"}),(0,i.createElement)("path",{d:"m7.707 12.293c.391.391.391 1.023 0 1.414-.195.195-.451.293-.707.293s-.512-.098-.707-.293l-3-3c-.391-.391-.391-1.023 0-1.414l3-3c.391-.391 1.023-.391 1.414 0s.391 1.023 0 1.414l-2.293 2.293z"}),(0,i.createElement)("circle",{cx:"12",cy:"18",r:"1"}),(0,i.createElement)("circle",{cx:"17",cy:"18",r:"1"}),(0,i.createElement)("path",{d:"m20.707 10.707-3 3c-.195.195-.451.293-.707.293s-.512-.098-.707-.293c-.391-.391-.391-1.023 0-1.414l2.293-2.293-2.293-2.293c-.391-.391-.391-1.023 0-1.414s1.023-.391 1.414 0l3 3c.391.391.391 1.023 0 1.414z"}),(0,i.createElement)("path",{d:"m21 24h-18c-1.654 0-3-1.346-3-3v-18c0-1.654 1.346-3 3-3h18c1.654 0 3 1.346 3 3v18c0 1.654-1.346 3-3 3zm-18-22c-.552 0-1 .449-1 1v18c0 .551.448 1 1 1h18c.552 0 1-.449 1-1v-18c0-.551-.448-1-1-1z"})),ui=(0,i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 512 512",style:{transform:"rotate(90deg)"}},(0,i.createElement)("path",{d:"M0,45.3v421.4h512V45.3H0z M482.1,436.8H29.9V76h452.1V436.8z M140.2,327.3l-70.9-70.9l70.9-70.9l21.3,21.3 l-49.6,49.6l49.6,49.6L140.2,327.3z M350.5,306l49.6-49.6l-49.6-49.6l21.3-21.3l70.9,70.9l-70.9,70.9L350.5,306z"})),hi=[{label:(0,c.__)("Grid","advanced-post-block"),value:"grid",icon:si},{label:(0,c.__)("Grid 1","advanced-post-block"),value:"grid1",icon:li},{label:(0,c.__)("Masonry","advanced-post-block"),value:"masonry",icon:ci},{label:(0,c.__)("Slider","advanced-post-block"),value:"slider",icon:di},{label:(0,c.__)("Ticker","advanced-post-block"),value:"ticker",icon:ui}],pi=[{label:(0,c.__)("Default","advanced-post-block"),value:"default"},{label:(0,c.__)("Title Meta","advanced-post-block"),value:"title-meta"},{label:(0,c.__)("Left Image","advanced-post-block"),value:"left-image"},{label:(0,c.__)("Right Image","advanced-post-block"),value:"right-image"},{label:(0,c.__)("Overlay Content","advanced-post-block"),value:"overlay-content"},{label:(0,c.__)("Overlay Content Hover","advanced-post-block"),value:"overlay-content-hover"},{label:(0,c.__)("Overlay Box","advanced-post-block"),value:"overlay-box"},{label:(0,c.__)("Overlay Content Box","advanced-post-block"),value:"overlay-content-box"},{label:(0,c.__)("Overlay Half Content","advanced-post-block"),value:"overlay-half-content"}],gi=[{label:(0,c.__)("Auto","advanced-post-block"),value:"auto"},{label:(0,c.__)("Fill Available Space","advanced-post-block"),value:"fill"}],fi=[{label:(0,c.__)("Content","advanced-post-block"),value:"content"},{label:(0,c.__)("Image","advanced-post-block"),value:"image"}],mi=[{label:(0,c.__)("Slide","advanced-post-block"),value:"slide"},{label:(0,c.__)("Fade","advanced-post-block"),value:"fade"},{label:(0,c.__)("Creative","advanced-post-block"),value:"creative"}],yi=[{label:(0,c.__)("Up","advanced-post-block"),value:"up"},{label:(0,c.__)("Down","advanced-post-block"),value:"down"}],vi=[{label:(0,c.__)("Author","advanced-post-block"),value:"author"},{label:(0,c.__)("Title","advanced-post-block"),value:"title"},{label:(0,c.__)("Date","advanced-post-block"),value:"date"},{label:(0,c.__)("Last Modified","advanced-post-block"),value:"modified"}],bi=[{label:(0,c.__)("Ascending","advanced-post-block"),value:"asc"},{label:(0,c.__)("Descending","advanced-post-block"),value:"desc"}],wi=[{label:(0,c.__)("Cover","advanced-post-block"),value:"cover"},{label:(0,c.__)("Contain","advanced-post-block"),value:"contain"}],Ci=[{label:(0,c.__)("Left","advanced-post-block"),value:"left",icon:"editor-alignleft"},{label:(0,c.__)("Center","advanced-post-block"),value:"center",icon:"editor-aligncenter"},{label:(0,c.__)("Right","advanced-post-block"),value:"right",icon:"editor-alignright"},{label:(0,c.__)("Justify","advanced-post-block"),value:"justify",icon:"editor-justify"}],xi=[{label:(0,c.__)("01/15/2022","advanced-post-block"),value:"m/d/Y"},{label:(0,c.__)("15/01/2022","advanced-post-block"),value:"d/m/Y"},{label:(0,c.__)("January 15, 2022","advanced-post-block"),value:"F d, Y"},{label:(0,c.__)("Jan 15, 2022","advanced-post-block"),value:"M d, Y"},{label:(0,c.__)("15th Jan, 2022","advanced-post-block"),value:"dS M, Y"},{label:(0,c.__)("15th January, 2022","advanced-post-block"),value:"dS F, Y"},{label:(0,c.__)("Custom","advanced-post-block"),value:"custom"}],Si=[{label:(0,c.__)("Auto","advanced-post-block"),value:"auto"},{label:(0,c.__)("Bottom","advanced-post-block"),value:"bottom"}],_i=[{name:"general",title:(0,c.__)("General","advanced-post-block")},{name:"elements",title:(0,c.__)("Elements","advanced-post-block")},{name:"style",title:(0,c.__)("Style","advanced-post-block")}],Ei=e=>e?.trim().split(",").map((e=>e?parseInt(e):e)),ki=e=>e?.filter((e=>e&&!isNaN(e))),$i=e=>e?(e?.replace(/(<([^>]+)>)/gi,"").split(/\s+/)||[]).length:0,Mi=e=>(0,i.createElement)("span",{dangerouslySetInnerHTML:{__html:e}}),Ti=({[n]:e,...t},n)=>t,Ai=(e,t)=>e?.map((e=>e.id))?.filter((e=>-1!==t.indexOf(e))),Li=(...e)=>e.reduce(((e,t)=>("string"==typeof t?e.push(t):"object"==typeof t&&Object.entries(t).forEach((([t,n])=>{n&&e.push(t)})),e)),[]).join(" "),Ri=(e=[],t)=>{switch(t){case"true":return e?.filter((e=>e.password));case"false":return e?.filter((e=>!e.password));default:return e}},Oi="apb",Ii="apb",Pi=({currentPostId:e})=>{const t=(0,i.useRef)(null);return(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody"},(0,i.createElement)(Pn,{className:"mb5"},"Copy the shortcode and use it anywhere."),(0,i.createElement)(d.PanelRow,null,(0,i.createElement)("div",{className:`${Oi}FrontShortcode`},(0,i.createElement)("input",{onClick:e=>{const n=e.target;n.select(),n.setSelectionRange(0,30),document.execCommand("copy"),t.current.innerHTML=(0,c.__)("Copied Successfully!","advanced-post-block"),setTimeout((()=>{t.current.innerHTML=(0,c.__)("Copy To Clipboard","advanced-post-block")}),1500)},value:`[${Ii} id=${e}]`}),(0,i.createElement)("span",{ref:t,className:"tooltip"},(0,c.__)("Copy To Clipboard","advanced-post-block")))))},Ni=({attributes:e,setAttributes:t,premiumProps:n})=>{const{tickerDirection:r,tickerSpeed:o,tickerInterval:a,tickerHeight:s,tickerVisible:l,tickerIsMousePause:u}=e;return(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Ticker Options","advanced-post-block"),initialOpen:!1},(0,i.createElement)(ni,{label:(0,c.__)("Direction:","advanced-post-block"),value:r,onChange:e=>t({tickerDirection:e}),options:yi,...n,Component:Se}),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Speed:","advanced-post-block"),value:o,onChange:e=>t({tickerSpeed:e}),...n,Component:d.TextControl}),(0,i.createElement)("small",null,(0,c.__)("Values: slow, medium, fast or any value in milliseconds.","advanced-post-block")),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Interval:","advanced-post-block"),labelPosition:"left",value:a,onChange:e=>t({tickerInterval:parseInt(e)}),...n,Component:d.__experimentalNumberControl}),(0,i.createElement)("small",null,(0,c.__)("Values: time in milliseconds.","advanced-post-block")),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Height:","advanced-post-block"),labelPosition:"left",value:s,onChange:e=>t({tickerHeight:e}),units:[se(),ce()],...n,Component:d.__experimentalUnitControl}),(0,i.createElement)("small",null,(0,c.__)("Keep height 0, to auto height.","advanced-post-block")),"0px"===s||"0em"===s?(0,i.createElement)(i.Fragment,null,(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Post Visible:","advanced-post-block"),value:l,onChange:e=>t({tickerVisible:e}),min:0,max:12,step:1,beforeIcon:"visibility",...n,Component:d.RangeControl}),(0,i.createElement)("small",null,(0,c.__)("0 to display all","advanced-post-block"))):"",(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Ticker Mouse Pause","advanced-post-block"),checked:u,onChange:e=>t({tickerIsMousePause:e}),...n,Component:d.ToggleControl}))},Di=({attributes:e,setAttributes:t})=>{const{sliderIsLoop:n,sliderIsTouchMove:r,sliderIsAutoplay:o,sliderAutoplayOptions:a,sliderSpeed:s,sliderEffect:l,sliderIsPage:u,sliderIsPageClickable:h,sliderIsPageDynamic:p,sliderIsPrevNext:g}=e;return(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Slider Options","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Enable Loop","advanced-post-block"),checked:n,onChange:e=>t({sliderIsLoop:e})}),(0,i.createElement)(d.ToggleControl,{className:"mt10",label:(0,c.__)("Enable Touch Move","advanced-post-block"),checked:r,onChange:e=>t({sliderIsTouchMove:e})}),(0,i.createElement)(d.ToggleControl,{className:"mt10",label:(0,c.__)("Enable Autoplay","advanced-post-block"),checked:o,onChange:e=>t({sliderIsAutoplay:e})}),o&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,{className:"mt10"},(0,c.__)("Autoplay Delay (s):","content-slider-block")),(0,i.createElement)(d.RangeControl,{value:a.delay,onChange:e=>t({sliderAutoplayOptions:{...a,delay:e}}),min:0,max:10,step:.05}),(0,i.createElement)("small",null,(0,c.__)("Smaller delay value will be autoplay faster","content-slider-block"))),(0,i.createElement)(Pn,null,(0,c.__)("Speed (s):","advanced-post-block")),(0,i.createElement)(d.RangeControl,{value:s,onChange:e=>t({sliderSpeed:e}),min:0,max:10,step:.05}),(0,i.createElement)("small",null,(0,c.__)("Smaller speed & delay value will be slide faster","advanced-post-block")),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Effect:","advanced-post-block")),(0,i.createElement)(d.SelectControl,{value:l,onChange:e=>t({sliderEffect:e}),options:mi})),(0,i.createElement)("small",null,(0,c.__)("To work fade & creative effects properly, set single column per view","advanced-post-block")),(0,i.createElement)(Pn,null,(0,i.createElement)("strong",null,(0,c.__)("Pagination:","advanced-post-block"))),(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Pagination","advanced-post-block"),checked:u,onChange:e=>t({sliderIsPage:e})}),u&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.ToggleControl,{className:"mt10",label:(0,c.__)("Enable Pagination Clickable","advanced-post-block"),checked:h,onChange:e=>t({sliderIsPageClickable:e})}),(0,i.createElement)(d.ToggleControl,{className:"mt10",label:(0,c.__)("Enable Pagination Dynamic Bullets","advanced-post-block"),checked:p,onChange:e=>t({sliderIsPageDynamic:e})})),(0,i.createElement)(Pn,null,(0,i.createElement)("strong",null,(0,c.__)("Preview Next Button:","advanced-post-block"))),(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Preview Next Button","advanced-post-block"),checked:g,onChange:e=>t({sliderIsPrevNext:e})}))},zi=({attributes:e,setAttributes:t,premiumProps:n})=>{const{isPagination:r,paginationPrevLabel:o,paginationNextLabel:a,paginationColors:s,paginationHovColors:l,paginationPadding:u,paginationSpacing:h}=e;return(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Pagination","advanced-post-block"),initialOpen:!1},(0,i.createElement)(ni,{label:(0,c.__)("Show Pagination","advanced-post-block"),checked:r,onChange:e=>t({isPagination:e}),...n,Component:d.ToggleControl}),(0,i.createElement)("small",null,(0,c.__)("Pagination will not work if, will not work if 'Post Per Page' is -1","advanced-post-block")),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Previous Label:","advanced-post-block"),value:o,onChange:e=>t({paginationPrevLabel:e}),...n,Component:d.TextControl}),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Next Label:","advanced-post-block"),value:a,onChange:e=>t({paginationNextLabel:e}),...n,Component:d.TextControl}),(0,i.createElement)(ni,{label:(0,c.__)("Colors:","advanced-post-block"),value:s,onChange:e=>t({paginationColors:e}),defaults:{color:"#fff",bg:"#4527a4"},...n,Component:$e}),(0,i.createElement)(ni,{label:(0,c.__)("Active & Hover Colors:","advanced-post-block"),value:l,onChange:e=>t({paginationHovColors:e}),defaults:{color:"#fff",bg:"#8344c5"},...n,Component:$e}),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Padding:","advanced-post-block"),value:u,onChange:e=>t({paginationPadding:e}),defaults:{vertical:"8px",horizontal:"15px"},...n,Component:Yn}),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Space Between:","advanced-post-block"),labelPosition:"left",value:h,onChange:e=>t({paginationSpacing:e}),units:[se(),ce()],...n,Component:d.__experimentalUnitControl}))},Fi=(0,o.withSelect)(((e,{attributes:t})=>{const{getPostTypes:n,getTaxonomies:i,getEntityRecords:r}=e("core"),{getDeviceType:o,getCurrentPostType:a,getCurrentPostId:s}=e("core/editor"),{postType:l}=t,c=i({per_page:-1});return{device:o()?.toLowerCase(),postTypes:n({per_page:-1})?.filter((e=>![Ii,"attachment","nav_menu_item"].includes(e.slug)&&!e.slug.startsWith("wp_")))?.map((({name:e,slug:t})=>({label:e,value:t}))),currentPostType:a(),currentPostId:s(),allTaxonomies:"post"===l?c?.filter((e=>e.types.includes("post"))).filter((e=>"category"!==e.slug&&"post_tag"!==e.slug)):c?.filter((e=>e.types.includes(l))),getTaxonomy:e=>r("taxonomy",e,{per_page:-1})}}))((({attributes:e,setAttributes:t,premiumProps:n,device:r,postTypes:o,currentPostType:a,currentPostId:s,allTaxonomies:l,getTaxonomy:u})=>{const{layout:h,subLayout:p,columns:g,columnGap:f,rowGap:m,isContentEqualHight:y,sliderHeight:v,content:b,postType:w,selectedTaxonomies:C={},selectedCategories:x=[],selectedTags:S,isPostsPerPageAll:_,postsPerPage:E,postsOrderBy:k,postsOrder:$,postsOffset:M,postsInclude:T,postsExclude:A,isExcludeCurrent:L}=e,R="grid"===h,O="grid1"===h,I="slider"===h,P="ticker"===h,N={attributes:e,setAttributes:t,premiumProps:n};return(0,i.createElement)(i.Fragment,null,a===Ii&&(0,i.createElement)(Pi,{currentPostId:s}),(0,i.createElement)(Lt,{slug:"advanced-post-block",docsLink:"https://bplugins.com/docs/advanced-post-block"}),(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Layout","advanced-post-block"),initialOpen:!0},(0,i.createElement)(Pn,{className:"mb5"},(0,c.__)("Layout:","advanced-post-block")),(0,i.createElement)(ri,{value:h,onChange:e=>{t({layout:e,subLayout:["slider","ticker"].includes(e)&&["default","title-meta"].includes(p)||"ticker"===e&&"overlay-half-content"===p?"left-image":p,columns:["slider","ticker"].includes(e)?{...g,desktop:2}:g})},options:hi,isTextIcon:!0,proValues:["grid1"],...n}),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Sub Layout:","advanced-post-block")),(0,i.createElement)(ii,{value:p,onChange:e=>{t({subLayout:e}),"default"===e||"title-meta"===e||"left-image"===e||"right-image"===e?t({contentBG:{color:"#f4f2fc",styles:"background-color: #f4f2fc;"},titleColor:"#4527a4",metaCategoryIn:"image",metaTextColor:"#333",metaLinkColor:"#8344c5",metaIconColor:"#4527a4",excerptColor:"#333"}):"overlay-content"===e||"overlay-content-hover"===e||"overlay-box"===e||"overlay-content-box"===e?t({contentBG:{color:"#000000b3",styles:"background-color: #000000b3;"},titleColor:"#ccc0f0",metaCategoryIn:"content",metaTextColor:"#fff",metaLinkColor:"#e0d0f0",metaIconColor:"#ccc0f0",excerptColor:"#fff"}):"overlay-half-content"===e&&t({contentBG:{type:"gradient",gradient:"linear-gradient(0deg, #000000bf 0%, #0000 100%)",styles:"background-image: linear-gradient(0deg, #000000bf 0%, #0000 100%);"},titleColor:"#fff",metaCategoryIn:"content",metaTextColor:"#fff",metaLinkColor:"#e0d0f0",metaIconColor:"#ccc0f0",excerptColor:"#fff"}),t("left-image"===e||"right-image"===e?{columns:{...g,desktop:2}}:{columns:{...g,desktop:3}}),t("overlay-box"===e||"overlay-content-box"===e?{contentAlign:"center"}:{contentAlign:"left"})},options:O?pi.filter((e=>!["left-image","right-image"].includes(e.value))):P?pi.filter((e=>!["overlay-half-content"].includes(e.value))):pi,proValues:["overlay-content-box","overlay-half-content"],...n})),(0,i.createElement)("small",null,(0,c.__)("Some settings may change when sub layout will be changed.","advanced-post-block")),!O&&!P&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:"mb5"},(0,c.__)("Columns:","advanced-post-block")),(0,i.createElement)(Me,null)),(0,i.createElement)(d.RangeControl,{value:g[r],onChange:e=>{t({columns:{...g,[r]:e}})},min:1,max:6,step:1,beforeIcon:"grid-view"})),!P&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,null,(0,c.__)("Column Gap:","advanced-post-block")),(0,i.createElement)(d.RangeControl,{value:f,onChange:e=>t({columnGap:e}),min:0,max:100,step:1,beforeIcon:"arrow-right-alt"})),!I&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,null,(0,c.__)("Row Gap:","advanced-post-block")),(0,i.createElement)(d.RangeControl,{value:m,onChange:e=>t({rowGap:e}),min:0,max:150,step:1,beforeIcon:"arrow-down-alt"})),(R||O)&&(0,i.createElement)(d.ToggleControl,{className:"mt20",label:(0,c.__)("Post Equal Height","advanced-post-block"),checked:y,onChange:e=>t({isContentEqualHight:e})}),I&&(0,i.createElement)(d.__experimentalUnitControl,{className:"mt20",label:(0,c.__)("Slider Min Height:","advanced-post-block"),labelPosition:"left",value:v,onChange:e=>t({sliderHeight:e}),units:[se(),ce(),he()]}),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Content/Texts Height:","advanced-post-block"),labelPosition:"left",value:b?.height,onChange:e=>t({content:{...b,height:e}}),options:gi,...n,Component:d.SelectControl})),(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Posts Query","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Post Type:","advanced-post-block")),(0,i.createElement)(ii,{value:w,onChange:e=>t({postType:e,selectedTaxonomies:{}}),options:o,proValues:["page"],...n})),"post"===w&&u("category")?.length?(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,null,(0,c.__)("Select Categories:","advanced-post-block")),(0,i.createElement)(Bn,{value:Ai(u("category"),x).map((e=>e.toString())),onChange:e=>t({selectedCategories:e.map((e=>parseInt(e)))}),options:u("category").map((e=>({label:e.name,value:e.id.toString()})))})):null,"post"===w&&u("post_tag")?.length?(0,i.createElement)(i.Fragment,null,(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Select Tags:","advanced-post-block"),value:Ai(u("post_tag"),S).map((e=>e.toString())),onChange:e=>t({selectedTags:e.map((e=>parseInt(e)))}),options:u("post_tag").map((e=>({label:e.name,value:e.id.toString()}))),...n,Component:Bn})):null,l?.length?(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,null,(0,c.__)("Select Taxonomies for filter:","advanced-post-block")),l.map((e=>{const r=Object.keys(C).includes(e.slug);return(0,i.createElement)(ni,{label:e.name,key:e.slug,checked:r,onChange:n=>t({selectedTaxonomies:n?{...C,[e.slug]:[]}:Ti(C,e.slug)}),...n,Component:d.CheckboxControl})}))):null,l?.length&&Object.keys(C)?.length?Object.keys(C).map((e=>u(e)?.length?(0,i.createElement)(ni,{key:e,className:"mt20",label:(0,c.__)(`Select ${l?.find((t=>t.slug===e))?.name}:`,"advanced-post-block"),value:Ai(u(e),C[e]).map((e=>e.toString())),onChange:n=>t({selectedTaxonomies:{...C,[e]:n.map((e=>parseInt(e)))}}),options:u(e).map((e=>({label:e.name,value:e.id.toString()}))),...n,Component:Bn}):null)):null,(0,i.createElement)(Pn,null,(0,c.__)("Post Per Page:","advanced-post-block")),(0,i.createElement)(d.RangeControl,{value:E,onChange:e=>t({postsPerPage:e,isPostsPerPageAll:-1===e}),min:-1,max:36,step:1}),(0,i.createElement)("small",null,(0,c.__)("To show all posts set -1","advanced-post-block")),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Post Order By:","advanced-post-block")),(0,i.createElement)(d.SelectControl,{value:k,onChange:e=>t({postsOrderBy:e}),options:vi})),(0,i.createElement)(d.PanelRow,{className:"mt20"},(0,i.createElement)(Pn,{className:""},(0,c.__)("Post Order:","advanced-post-block")),(0,i.createElement)(d.SelectControl,{value:$,onChange:e=>t({postsOrder:e}),options:bi})),!_&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Post Offset:","advanced-post-block"),labelPosition:"left",value:M,onChange:e=>t({postsOffset:parseInt(e)}),min:0,...n,Component:d.__experimentalNumberControl}),(0,i.createElement)("small",null,(0,c.__)("`Post Offset` will not work if `Post Per Page` is -1","advanced-post-block"))),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Include Posts:","advanced-post-block"),value:T?.join(","),onChange:e=>t({postsInclude:Ei(e)}),...n,Component:d.TextControl}),(0,i.createElement)("small",null,(0,c.__)("Enter the posts id by coma separated Ex: `23,45,16`","advanced-post-block")),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Exclude Posts:","advanced-post-block"),value:A?.join(","),onChange:e=>t({postsExclude:Ei(e)}),...n,Component:d.TextControl}),(0,i.createElement)("small",null,(0,c.__)("Enter the posts id by coma separated Ex: `23,45,16`","advanced-post-block")),(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Exclude Current Post","advanced-post-block"),checked:L,onChange:e=>t({isExcludeCurrent:e}),...n,Component:d.ToggleControl})),I||P||_?"":(0,i.createElement)(zi,{...N}),I&&(0,i.createElement)(Di,{...N}),P&&(0,i.createElement)(Ni,{...N}))})),Bi=(0,o.withSelect)((e=>({imageSizes:e("core/block-editor")?.getSettings()?.imageSizes?.map((e=>({label:e.name,value:e.slug})))})))((({isPremium:e,attributes:t,setAttributes:n,premiumProps:r,taxOfPostType:o,updateObj:a,imageSizes:s})=>{const{elementsSort:l,isFImg:u,fImgSize:h,fImgFitting:p,isFImgLink:g,isTitle:f,isTitleLink:m,isMeta:y,isMetaAuthor:v,isMetaAuthorLink:b,metaAuthorIcon:w,isMetaDate:C,metaDateFormat:x,metaDateIcon:S,isMetaCategory:_,metaCategoryIn:E,metaCategoryIcon:k,metaTaxonomies:$={},isMetaReadTime:M,metaReadTimeIcon:T,isMetaReadTimeSec:A,metaReadTimeLabel:L,isMetaComment:R,metaCommentIcon:O,isExcerpt:I,isExcerptFromContent:P,isEllipsisOnExcerpt:N,excerptLength:D,isReadMore:z,readMorePosition:F,readMoreLabel:B,isLinkNewTab:H}=t,[W,j]=(0,i.useState)(xi.find((e=>e.value===x))?.value||"custom");return(0,i.createElement)(i.Fragment,null,f&&y&&(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Elements","advanced-post-block")},(0,i.createElement)(ni,{label:(0,c.__)("Sort Element:"),value:l,onChange:e=>n({elementsSort:e}),...r,Component:Gn})),(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Feature Image","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Feature Image","advanced-post-block"),checked:u,onChange:e=>n({isFImg:e})}),u&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Size:","advanced-post-block"),labelPosition:"left",value:h,onChange:e=>n({fImgSize:e}),options:s,...r,Component:d.SelectControl}),(0,i.createElement)(d.SelectControl,{className:"mt20",label:(0,c.__)("Fitting:","advanced-post-block"),labelPosition:"left",value:p,onChange:e=>n({fImgFitting:e}),options:wi}),(0,i.createElement)(d.ToggleControl,{className:"mt10",label:(0,c.__)("Enable Link","advanced-post-block"),checked:g,onChange:e=>n({isFImgLink:e})}))),(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Title","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Title","advanced-post-block"),checked:f,onChange:e=>n({isTitle:e})}),f&&(0,i.createElement)(d.ToggleControl,{className:"mt10",label:(0,c.__)("Enable Title Link","advanced-post-block"),checked:m,onChange:e=>n({isTitleLink:e})})),(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Meta Data","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Meta Data","advanced-post-block"),checked:y,onChange:e=>n({isMeta:e})}),y&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)("hr",null),(0,i.createElement)(Pn,{className:"mb10"},(0,i.createElement)("strong",null,(0,c.__)("Author","advanced-post-block"))),(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Author","advanced-post-block"),checked:v,onChange:e=>n({isMetaAuthor:e})}),v&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Author Link","advanced-post-block"),checked:b,onChange:e=>n({isMetaAuthorLink:e}),...r,Component:d.ToggleControl}),(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Author Icon:","advanced-post-block"),value:w,types:["image"],onChange:e=>n({metaAuthorIcon:e}),placeholder:(0,c.__)("Enter Author Icon URL","advanced-post-block"),...r,Component:Nn})),(0,i.createElement)("hr",null),(0,i.createElement)(Pn,{className:"mb10"},(0,i.createElement)("strong",null,(0,c.__)("Date","advanced-post-block"))),(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Date","advanced-post-block"),checked:C,onChange:e=>n({isMetaDate:e})}),C&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Pn,{className:"mt10"},(0,c.__)("Date Format:","advanced-post-block")),(0,i.createElement)(d.PanelRow,{className:"gap15"},(0,i.createElement)(ni,{value:W,onChange:e=>{j(e),n({metaDateFormat:"custom"==e?"Y-m-d":e})},options:xi,...r,Component:d.SelectControl}),"custom"===W&&(0,i.createElement)(ni,{value:x,onChange:e=>n({metaDateFormat:e}),...r,Component:d.TextControl})),"custom"===W&&(0,i.createElement)("small",null,(0,c.__)("Documentation on date formatting in ","advanced-post-block")," ",(0,i.createElement)("a",{href:"https://wordpress.org/support/article/formatting-date-and-time/",target:"_blank",rel:"noreferrer","aria-label":"Documentation on Date Formatting"},"here"),"."),(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Date Icon:","advanced-post-block"),value:S,types:["image"],onChange:e=>n({metaDateIcon:e}),placeholder:(0,c.__)("Enter Date Icon URL","advanced-post-block"),...r,Component:Nn})),(0,i.createElement)("hr",null),(0,i.createElement)(Pn,{className:"mb10"},(0,i.createElement)("strong",null,(0,c.__)("Category","advanced-post-block"))),(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Category","advanced-post-block"),checked:_,onChange:e=>n({isMetaCategory:e})}),_&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Se,{label:(0,c.__)("Category In:","advanced-post-block"),value:E,onChange:e=>n({metaCategoryIn:e}),options:fi}),"content"===E&&(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Category Icon:","advanced-post-block"),value:k,types:["image"],onChange:e=>n({metaCategoryIcon:e}),placeholder:(0,c.__)("Enter Category Icon URL","advanced-post-block"),...r,Component:Nn})),(0,i.createElement)("hr",null),(0,i.createElement)("hr",null),(0,i.createElement)(Pn,{className:"mb10"},(0,i.createElement)("strong",null,(0,c.__)("Taxonomies","advanced-post-block"))),o?.map(((e,t)=>{const{selected:o=[]}=$,{name:s,slug:l}=e;return(0,i.createElement)(i.Fragment,null,(0,i.createElement)(ni,{key:l,className:t?"mt20":"",label:(0,c.__)(`Show ${s} Taxonomy`,"advanced-post-block"),checked:o?.includes(l),onChange:e=>{const t={...$};e?t[l]={}:delete t[l],t.selected=e?[...o,l]:o?.filter((e=>e!==l)),n({metaTaxonomies:t})},...r,Component:d.ToggleControl}),o?.includes(l)&&(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)(`${s} Icon:`,"advanced-post-block"),value:$?.[l]?.icon,types:["image"],onChange:e=>a("metaTaxonomies",l,e,"icon"),placeholder:(0,c.__)(`Enter ${s} Icon URL`,"advanced-post-block"),...r,Component:Nn}))})),(0,i.createElement)("hr",null),(0,i.createElement)("hr",null),(0,i.createElement)(Pn,{className:"mb10"},(0,i.createElement)("strong",null,(0,c.__)("Reading Time","advanced-post-block"))),(0,i.createElement)(ni,{label:(0,c.__)("Show Reading Time","advanced-post-block"),checked:M,onChange:e=>n({isMetaReadTime:e}),...r,Component:d.ToggleControl}),(M||!e)&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)("small",null,(0,c.__)("Reading Time will be displayed if the post has content!","advanced-post-block")),(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Show Reading Time Seconds","advanced-post-block"),checked:A,onChange:e=>n({isMetaReadTimeSec:e}),...r,Component:d.ToggleControl}),(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Reading Time Label:","advanced-post-block"),value:L,onChange:e=>n({metaReadTimeLabel:e}),placeholder:(0,c.__)("Reading Time Label"),...r,Component:d.TextControl}),(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Reading Time Icon:","advanced-post-block"),value:T,types:["image"],onChange:e=>n({metaReadTimeIcon:e}),placeholder:(0,c.__)("Enter Reading Time Icon URL","advanced-post-block"),...r,Component:Nn})),(0,i.createElement)("hr",null),(0,i.createElement)(Pn,{className:"mb10"},(0,i.createElement)("strong",null,(0,c.__)("Comment","advanced-post-block"))),(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Comment","advanced-post-block"),checked:R,onChange:e=>n({isMetaComment:e})}),R&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)("small",null,(0,c.__)("Comment Count will be displayed if the comment status is open!","advanced-post-block")),(0,i.createElement)(ni,{className:"mt10",label:(0,c.__)("Comment Icon:","advanced-post-block"),value:O,types:["image"],onChange:e=>n({metaCommentIcon:e}),placeholder:(0,c.__)("Enter Comment Icon URL","advanced-post-block"),...r,Component:Nn})))),(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Excerpt","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Excerpt","advanced-post-block"),checked:I,onChange:e=>n({isExcerpt:e})}),I&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.ToggleControl,{className:"mt15",label:(0,c.__)("Show Excerpt from Content","advanced-post-block"),checked:P,onChange:e=>n({isExcerptFromContent:e})}),(0,i.createElement)(ni,{className:"mt15",label:(0,c.__)("Show Ellipsis","advanced-post-block"),checked:N,onChange:e=>n({isEllipsisOnExcerpt:e}),...r,Component:d.ToggleControl}),(0,i.createElement)(Pn,{className:"mt15"},(0,c.__)("Excerpt Length:","advanced-post-block")),(0,i.createElement)(d.RangeControl,{value:D,onChange:e=>n({excerptLength:e}),min:-1,max:120,step:1}),(0,i.createElement)("small",null,(0,c.__)("Set -1 to show all the "+(P?"content":"excerpt"),"advanced-post-block")))),(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Read More","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Show Read More","advanced-post-block"),checked:z,onChange:e=>n({isReadMore:e})}),z&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(ni,{className:"mt20",label:(0,c.__)("Position:","advanced-post-block"),labelPosition:"left",value:F,onChange:e=>n({readMorePosition:e}),options:Si,...r,Component:d.SelectControl}),(0,i.createElement)("small",null,(0,c.__)("For the bottom position, select 'Fill Available Space' option for the 'Content/Texts Height' from General->Layout","advanced-post-block")),(0,i.createElement)(Pn,null,(0,c.__)("Read More Label:","advanced-post-block")),(0,i.createElement)(d.TextControl,{value:B,onChange:e=>n({readMoreLabel:""===e?"Read More":e})}),(0,i.createElement)(d.ToggleControl,{label:(0,c.__)("Open link in new tab","advanced-post-block"),checked:H,onChange:e=>n({isLinkNewTab:e})}))))})),Hi=({attributes:e,setAttributes:t})=>{const{layout:n,contentAlign:r,contentBG:o,contentPadding:a,border:s,sliderIsPage:l,sliderPageColor:u,sliderPageWidth:h,sliderPageHeight:p,sliderPageBorder:g,sliderIsPrevNext:f,sliderPrevNextColor:m,isTitle:y,titleTypo:v,titleColor:b,titleMargin:w,isMeta:C,metaCategoryIn:x,metaTypo:S,metaTextColor:_,metaLinkColor:E,metaIconColor:k,metaColorsOnImage:$,metaMargin:M,isExcerpt:T,excerptAlign:A,excerptTypo:L,excerptColor:R,excerptMargin:O,isReadMore:I,readMoreAlign:P,readMoreTypo:N,readMoreColors:D,readMoreHovColors:z,readMorePadding:F,readMoreBorder:B}=e,H="slider"===n;return(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Content","advanced-post-block")},(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Text Align:","advanced-post-block")),(0,i.createElement)(Se,{value:r,onChange:e=>t({contentAlign:e}),options:Ci,isIcon:!0})),(0,i.createElement)(Ce,{label:(0,c.__)("Background","advanced-post-block"),value:o,onChange:e=>t({contentBG:e}),defaults:{color:"#f4f2fc"}}),(0,i.createElement)(Yn,{className:"mt20",label:(0,c.__)("Padding:","advanced-post-block"),value:a,onChange:e=>t({contentPadding:e}),defaults:{vertical:"20px",horizontal:"25px"}}),(0,i.createElement)(Un,{label:(0,c.__)("Border:","advanced-post-block"),value:s,onChange:e=>t({border:e}),defaults:{radius:"5px"}})),H&&(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Slider Options","advanced-post-block"),initialOpen:!1},l&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Ee,{label:(0,c.__)("Pagination Bullets Color:","advanced-post-block"),value:u,onChange:e=>t({sliderPageColor:e}),defaultColor:"#4527a4"}),(0,i.createElement)(d.__experimentalUnitControl,{className:"mt20",label:(0,c.__)("Pagination Width:","advanced-post-block"),labelPosition:"left",value:h,onChange:e=>t({sliderPageWidth:e}),units:[se(),ce()]}),(0,i.createElement)(d.__experimentalUnitControl,{className:"mt20",label:(0,c.__)("Pagination Height:","advanced-post-block"),labelPosition:"left",value:p,onChange:e=>t({sliderPageHeight:e}),units:[se(),ce()]}),(0,i.createElement)(Un,{label:(0,c.__)("Pagination Border:","advanced-post-block"),value:g,onChange:e=>t({sliderPageBorder:e}),defaults:{radius:"50%"}})),f&&(0,i.createElement)(Ee,{label:(0,c.__)("Preview Next Button Color:","advanced-post-block"),value:m,onChange:e=>t({sliderPrevNextColor:e}),defaultColor:"#4527a4"})),y&&(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Title","advanced-post-block"),initialOpen:!1},(0,i.createElement)(Jn,{value:v,onChange:e=>t({titleTypo:e}),defaults:{fontSize:{desktop:25,tablet:22,mobile:20}}}),(0,i.createElement)(Ee,{label:(0,c.__)("Color:","advanced-post-block"),value:b,onChange:e=>t({titleColor:e}),defaultColor:"#4527a4"}),(0,i.createElement)(Yn,{className:"mt20",label:(0,c.__)("Margin:","advanced-post-block"),value:w,onChange:e=>t({titleMargin:e}),defaults:{side:4,bottom:"15px"}})),C&&(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Meta Data","advanced-post-block"),initialOpen:!1},(0,i.createElement)(Jn,{value:S,onChange:e=>t({metaTypo:e}),defaults:{fontSize:{desktop:13,tablet:13,mobile:13},textTransform:"uppercase"}}),(0,i.createElement)(Ee,{label:(0,c.__)("Text Color:","advanced-post-block"),value:_,onChange:e=>t({metaTextColor:e}),defaultColor:"#333"}),(0,i.createElement)(Ee,{label:(0,c.__)("Link Color:","advanced-post-block"),value:E,onChange:e=>t({metaLinkColor:e}),defaultColor:"#8344c5"}),(0,i.createElement)(Ee,{label:(0,c.__)("Icon Color:","advanced-post-block"),value:k,onChange:e=>t({metaIconColor:e}),defaultColor:"#4527a4"}),"image"===x&&(0,i.createElement)($e,{label:(0,c.__)("Category Colors On Image:","advanced-post-block"),value:$,onChange:e=>t({metaColorsOnImage:e}),defaults:{color:"#fff",bg:"#4527a4"}}),(0,i.createElement)(Yn,{className:"mt20",label:(0,c.__)("Margin:","advanced-post-block"),value:M,onChange:e=>t({metaMargin:e}),defaults:{side:4,bottom:"15px"}})),T&&(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Excerpt","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Text Align:","advanced-post-block")),(0,i.createElement)(Se,{value:A,onChange:e=>t({excerptAlign:e}),options:Ci,isIcon:!0})),(0,i.createElement)(Jn,{value:L,onChange:e=>t({excerptTypo:e}),defaults:{fontSize:{desktop:15,tablet:15,mobile:15}}}),(0,i.createElement)(Ee,{label:(0,c.__)("Color:","advanced-post-block"),value:R,onChange:e=>t({excerptColor:e}),defaultColor:"#333"}),(0,i.createElement)(Yn,{className:"mt20",label:(0,c.__)("Margin:","advanced-post-block"),value:O,onChange:e=>t({excerptMargin:e}),defaults:{side:4,bottom:"10px"}})),I&&(0,i.createElement)(d.PanelBody,{className:"bPlPanelBody",title:(0,c.__)("Read More","advanced-post-block"),initialOpen:!1},(0,i.createElement)(d.PanelRow,null,(0,i.createElement)(Pn,{className:""},(0,c.__)("Button Align:","advanced-post-block")),(0,i.createElement)(Se,{value:P,onChange:e=>t({readMoreAlign:e}),options:Ci.filter((e=>"justify"!==e.value)),isIcon:!0})),(0,i.createElement)(Jn,{value:N,onChange:e=>t({readMoreTypo:e}),defaults:{fontSize:{desktop:14,tablet:14,mobile:14},textTransform:"uppercase",fontWeight:600}}),(0,i.createElement)($e,{value:D,onChange:e=>t({readMoreColors:e}),defaults:{color:"#fff",bg:"#8344c5"}}),(0,i.createElement)($e,{label:(0,c.__)("Hover Colors:","advanced-post-block"),value:z,onChange:e=>t({readMoreHovColors:e}),defaults:{color:"#fff",bg:"#4527a4"}}),(0,i.createElement)(Yn,{className:"mt20",label:(0,c.__)("Padding:","advanced-post-block"),value:F,onChange:e=>t({readMorePadding:e}),defaults:{vertical:"12px",horizontal:"35px"}}),(0,i.createElement)(Un,{label:(0,c.__)("Border:","advanced-post-block"),value:B,onChange:e=>t({readMoreBorder:e}),defaults:{radius:"3px"}})))},Wi=({isPremium:e,attributes:t,setAttributes:n,posts:r,taxOfPostType:o})=>{const{contentAlign:s}=t,[u,h]=(0,i.useState)(!1),p=r?.length,g=(e,i,r,o)=>{const a=J(t[e],(e=>{o?e[i][o]=r:e[i]=r}));n({[e]:a})},f={isPremium:e,attributes:t,setAttributes:n,premiumProps:{isPremium:e,setIsProModalOpen:h}};return(0,i.createElement)(i.Fragment,null,(0,i.createElement)(a.InspectorControls,null,!e&&(0,i.createElement)("div",{className:"bPlInspectorInfo"},(0,i.createElement)(ei,null)),(0,i.createElement)(d.TabPanel,{className:"bPlTabPanel",activeClass:"activeTab",tabs:_i,onSelect:()=>l()},(e=>(0,i.createElement)(i.Fragment,null,"general"===e.name&&(0,i.createElement)(Fi,{...f}),"elements"===e.name&&(0,i.createElement)(Bi,{...f,taxOfPostType:o,updateObj:g}),"style"===e.name&&p&&(0,i.createElement)(Hi,{...f}))))),(0,i.createElement)(ti,{isProModalOpen:u,setIsProModalOpen:h,link:"https://bplugins.com/products/advanced-post-block/#pricing"},(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Layouts: ","advanced-post-block")),(0,c.__)("Check out more layouts and sub-layouts.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Display Pages: ","advanced-post-block")),(0,c.__)("Effortlessly showcase pages, just like you do with posts.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Tag Filter: ","advanced-post-block")),(0,c.__)("Post filter by tags (only for default post).","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Custom Taxonomy Filter: ","advanced-post-block")),(0,c.__)("Custom Taxonomy filter for post and custom posts.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Post Offset: ","advanced-post-block")),(0,c.__)("Offset to exclude first N posts.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Include or Exclude Posts: ","advanced-post-block")),(0,c.__)("Include or Exclude the posts by IDs.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Exclude Current Post: ","advanced-post-block")),(0,c.__)("If you use this block in a post and that post type is selected post then you can exclude the post.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Pagination: ","advanced-post-block")),(0,c.__)("Add custom pagination bottom of the posts.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Sort Elements: ","advanced-post-block")),(0,c.__)("Sort the title and meta elements.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Meta Data Icon: ","advanced-post-block")),(0,c.__)("Custom icon for metadata.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Meta Author Link Toggle: ","advanced-post-block")),(0,c.__)("Show meta author with or without link.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Taxonomies in Meta: ","advanced-post-block")),(0,c.__)("Display taxonomies within the metadata., including tags.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Reading Time: ","advanced-post-block")),(0,c.__)("Show post reading time in the meta area.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Excerpt from Content: ","advanced-post-block")),(0,c.__)("Show excerpt from main content.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Ticker Layout Options: ","advanced-post-block")),(0,c.__)("Options for ticker post layout.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Feature Image Size: ","advanced-post-block")),(0,c.__)("Options to set feature image size.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Read More Position: ","advanced-post-block")),(0,c.__)("Options to set the position for the Read More button.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("ShortCode Powered: ","advanced-post-block")),(0,c.__)("Shortcode option to use anywhere.","advanced-post-block")),(0,i.createElement)("li",null," ",(0,i.createElement)("strong",null,(0,c.__)("Update Post Query: ","advanced-post-block")),"Update Post Query using ",(0,i.createElement)("code",null,"apb_query")," filter.")),(0,i.createElement)(a.BlockControls,null,(0,i.createElement)(a.AlignmentToolbar,{value:s,onChange:e=>n({contentAlign:e})})))},ji=()=>(0,i.createElement)("h3",{className:`${Oi}Loading`},(0,i.createElement)(d.Spinner,null)," ",(0,c.__)("Loading...","advanced-post-block")),Gi=()=>(0,i.createElement)("h3",{className:`${Oi}NotFound`},(0,c.__)("No posts found!! Please update the query or add some posts","advanced-post-block")),Vi=(e,t,n)=>(e=>!(null==e||""===e||Array.isArray(e)&&0===e.length||"object"==typeof e&&0===Object.keys(e).length||"string"==typeof e&&""===e.trim()||"number"==typeof e&&0===e))(t)?`${e}: ${t};`:"",Ui=(e,t=!0,n=!0,i=!0)=>{const{type:r="solid",color:o="",gradient:a="",image:s={},position:l="",attachment:c="",repeat:d="",size:u="",overlayColor:h=""}=e||{};return"gradient"===r&&n?Vi("background",a):"image"===r&&i?`background: url(${s?.url});\n\t\t\t\t${Vi("background-color",h)}\n\t\t\t\t${Vi("background-position",l)}\n\t\t\t\t${Vi("background-size",u)}\n\t\t\t\t${Vi("background-repeat",d)}\n\t\t\t\t${Vi("background-attachment",c)}\n\t\t\t\t${Vi("background-repeat",d)}\n\t\t\t\tbackground-blend-mode: overlay;`:t&&Vi("background",o)},Ki=e=>{const{width:t="0px",style:n="solid",color:i="",side:r="all",radius:o="0px"}=e||{},a=e=>{const t=r?.toLowerCase();return t?.includes("all")||t?.includes(e)},s=`${t} ${n} ${i}`,l=`\n\t\t${"0px"!==t&&t?["top","right","bottom","left"].map((e=>a(e)?`border-${e}: ${s};`:"")).join(""):""}\n\t\t${o?`border-radius: ${o};`:""}\n\t`;return l},Yi=e=>{const{color:t="#333",bgType:n="solid",bg:i="",gradient:r="linear-gradient(135deg, #4527a4, #8344c5)"}=e||{};return`\n\t\t${t?`color: ${t};`:""}\n\t\t${r||i?Vi("background","gradient"===n?r:i):""}\n\t`},qi=e=>{const{side:t=2,vertical:n="0px",horizontal:i="0px",top:r="0px",right:o="0px",bottom:a="0px",left:s="0px"}=e||{};return 2===t?`${n} ${i}`:`${r} ${o} ${a} ${s}`},Qi=(e,t,n=!0)=>{const{fontFamily:i="Default",fontCategory:r="sans-serif",fontVariant:o=400,fontWeight:a,isUploadFont:s,fontSize:l={desktop:null,tablet:null,mobile:null},fontStyle:c,textTransform:d,textDecoration:u,lineHeight:h,letterSpace:p}=t||{},g=!n||!i||"Default"===i,f=l?.desktop||l,m=l?.tablet||f,y=l?.mobile||m,v=(e=15)=>{const t=String(e);return["px","em","rem","%","vh","vw"].some((e=>t.endsWith(e)))?t:`${t}px`},b=`\n\t\t${g?"":`font-family: '${i}', ${r};`}\n\t\t${Vi("font-weight",a)}\n\t\t${Vi("font-size",v(f))}\n\t\t${Vi("font-style",c)}\n\t\t${Vi("text-transform",d)}\n\t\t${Vi("text-decoration",u)}\n\t\t${Vi("line-height",h)}\n\t\t${Vi("letter-spacing",p)}\n\t`,w=o&&400!==o?"400i"===o?":ital@1":o?.includes("00i")?`: ital, wght@1, ${o?.replace("00i","00")} `:`: wght@${o} `:"",C=g?"":`https://fonts.googleapis.com/css2?family=${i?.split(" ").join("+")}${w.replace(/ /g,"")}&display=swap`;return{googleFontLink:!s||g?"":`@import url(${C});`,styles:`${e}{\n\t\t\t${b}\n\t\t}\n\t\t@media only screen and (max-width: 1024px) {\n\t\t\t${e}{\n\t\t\t\t${Vi("font-size",v(m))}\n\t\t\t}\n\t\t}\n\t\t@media only screen and (max-width: 640px) {\n\t\t\t${e}{\n\t\t\t\t${Vi("font-size",v(y))}\n\t\t\t}\n\t\t}`.replace(/\s+/g," ").trim()}},Xi=({attributes:e,id:t})=>{const{columnGap:n,rowGap:r,isContentEqualHight:o,sliderHeight:a,paginationColors:s,paginationHovColors:l,paginationPadding:c,paginationSpacing:d,fImgFitting:u="cover",contentAlign:h,contentBG:p,contentPadding:g,border:f,sliderPageColor:m,sliderPageWidth:y,sliderPageHeight:v,sliderPageBorder:b,sliderPrevNextColor:w,titleTypo:C,titleColor:x,titleMargin:S,metaTypo:_,metaTextColor:E,metaLinkColor:k,metaIconColor:$,metaColorsOnImage:M,metaMargin:T,excerptAlign:A,excerptTypo:L,excerptColor:R,excerptMargin:O,readMoreAlign:I,readMoreTypo:P,readMoreColors:N,readMoreHovColors:D,readMorePadding:z,readMoreBorder:F}=e,B=`#${t}`,H=`${B} .${Oi}Post`,W=`${B} .${Oi}SliderPosts`,j=`${H} .${Oi}ReadMore`,G=`${H} .${Oi}Title`,V=`${H} .${Oi}Meta`,U=`${B} .${Oi}Pagination`;return(0,i.createElement)("style",{dangerouslySetInnerHTML:{__html:`\n\t\t${Qi("",C)?.googleFontLink}\n\t\t${Qi("",_)?.googleFontLink}\n\t\t${Qi("",L)?.googleFontLink}\n\t\t${Qi("",P)?.googleFontLink}\n\t\t${Qi(`${G}, ${G} a`,C)?.styles}\n\t\t${Qi(`${V}, ${V} *, ${H} .${Oi}ThumbCats`,_)?.styles}\n\t\t${Qi(`${H} .${Oi}Excerpt`,L)?.styles}\n\t\t${Qi(`${j} a`,P)?.styles}\n\n\t\t${U} .${Oi}PagePrev,\n\t\t${U} .${Oi}PageNumber,\n\t\t${U} .${Oi}PageNext{\n\t\t\tfont-size: 15px;\n\t\t\t${Yi(s)}\n\t\t\tpadding: ${qi(c)};\n\t\t\tmargin: 0 calc( ${d} / 2 );\n\t\t}\n\t\t@media only screen and (max-width: 640px) {\n\t\t\t${U} .${Oi}PagePrev,\n\t\t\t${U} .${Oi}PageNumber,\n\t\t\t${U} .${Oi}PageNext{\n\t\t\t\tfont-size: 12px;\n\t\t\t\tpadding: ${qi(c)?.split(" ").map((e=>`calc( ${e} / 2 )`)).join(" ")};\n\t\t\t\tmargin: 0 calc( ${d} / 4 );\n\t\t\t}\n\t\t}\n\t\t${U} .${Oi}PagePrev:hover,\n\t\t${U} .${Oi}PageNumber:hover,\n\t\t${U} .${Oi}PageNext:hover,\n\t\t${U} .${Oi}ActivePage{\n\t\t\t${Yi(l)}\n\t\t}\n\n\t\t${H}{\n\t\t\t${Ki(f)}\n\t\t}\n\t\t${B} .${Oi}Default,\n\t\t${B} .${Oi}SideImage{\n\t\t\ttext-align: ${h};\n\t\t\t${Ui(p)}\n\t\t}\n\n\t\t${H} .${Oi}Text{\n\t\t\tpadding: ${qi(g)};\n\t\t}\n\t\t${B} .${Oi}Overlay .${Oi}Text{\n\t\t\t${Ui(p)}\n\t\t\talign-items: ${"left"===h?"flex-start":"right"===h?"flex-end":"center"===h?"center":""}\n\t\t}\n\n\t\t${G}, ${G} a{\n\t\t\ttext-align: ${h};\n\t\t\tcolor: ${x};\n\t\t}\n\t\t${G}{\n\t\t\tmargin: ${qi(S)};\n\t\t}\n\t\t${V}{\n\t\t\tjustify-content: ${"left"===h?"flex-start":"right"===h?"flex-end":"center"};\n\t\t\tcolor: ${E};\n\t\t\tmargin: ${qi(T)};\n\t\t}\n\t\t${V} a{\n\t\t\tcolor: ${k};\n\t\t}\n\t\t${V} .dashicons{\n\t\t\tcolor: ${$};\n\t\t}\n\t\t${H} .${Oi}Thumb img, ${H}.${Oi}Overlay img{\n\t\t\tobject-fit: ${u};\n\t\t}\n\t\t${H} .${Oi}ThumbCats a{\n\t\t\t${Yi(M)}\n\t\t}\n\t\t${H} .${Oi}Excerpt{\n\t\t\ttext-align: ${A};\n\t\t\tcolor: ${R};\n\t\t\tmargin: ${qi(O)};\n\t\t}\n\t\t${j}{\n\t\t\ttext-align: ${I};\n\t\t}\n\t\t${j} a{\n\t\t\t${Yi(N)}\n\t\t\tpadding: ${qi(z)};\n\t\t\t${Ki(F)}\n\t\t}\n\t\t${j} a:hover{\n\t\t\t${Yi(D)}\n\t\t}\n\n\t\t${B} .${Oi}GridPosts,\n\t\t${B} .${Oi}Grid1Posts{\n\t\t\tgrid-gap: ${r}px ${n}px;\n\t\t\talign-items: ${!1===o?"start":"initial"};\n\t\t}\n\n\t\t${W},\n\t\t${W} .swiper-slide article{\n\t\t\tmin-height: ${a};\n\t\t}\n\t\t${W} .swiper-pagination .swiper-pagination-bullet{\n\t\t\tbackground: ${m};\n\t\t\twidth: ${y};\n\t\t\theight: ${v};\n\t\t\t${Ki(b)}\n\t\t}\n\t\t${W} .swiper-button-prev,\n\t\t${W} .swiper-button-next{\n\t\t\tcolor: ${w};\n\t\t}\n\t`.replace(/\s+/g," ")}})},Zi=({post:e,attributes:t})=>{const{link:n,thumbnail:{url:r,alt:o},categories:a}=e,{isFImg:s,isFImgLink:l,isMeta:c,isMetaCategory:d,metaCategoryIn:u,isLinkNewTab:h}=t;return s&&r?(0,i.createElement)("figure",{className:`${Oi}Thumb`},l?(0,i.createElement)("a",{href:n,target:h?"_blank":"_self",rel:"noreferrer","aria-label":o},(0,i.createElement)("img",{src:r,alt:o})):(0,i.createElement)("img",{src:r,alt:o}),c&&d&&"image"===u&&a.space&&(0,i.createElement)("div",{className:`${Oi}ThumbCats`,dangerouslySetInnerHTML:{__html:a.space}})):null},Ji=({post:e,attributes:t})=>{const{author:n}=e,{name:r,link:o}=n||{},{isMetaAuthor:a,isMetaAuthorLink:s=!0,metaAuthorIcon:l}=t;return a&&r?(0,i.createElement)("span",null,l?(0,i.createElement)("img",{src:l,alt:"Author"}):(0,i.createElement)("span",{className:"dashicons dashicons-admin-users"}),s?(0,i.createElement)("a",{href:o,target:"_blank",rel:"noreferrer","aria-label":r},r):(0,i.createElement)("span",null,r)):null},er=({post:e,attributes:t})=>{const{date:n}=e,{isMetaDate:r,metaDateIcon:o}=t;return r&&n?(0,i.createElement)("span",null,o?(0,i.createElement)("img",{src:o,alt:"Date"}):(0,i.createElement)("span",{className:"dashicons dashicons-calendar-alt"}),(0,i.createElement)("span",null,n)):null},tr=({post:e,attributes:t})=>{const{categories:n}=e,{isMetaCategory:r,metaCategoryIn:o,metaCategoryIcon:a}=t;return r&&"content"===o&&n.coma?(0,i.createElement)("span",null,a?(0,i.createElement)("img",{src:a,alt:"Author"}):(0,i.createElement)("span",{className:"dashicons dashicons-category"}),Mi(n.coma)):null},nr=({post:e,attributes:t})=>{const{taxonomies:n={}}=e,{metaTaxonomies:r={}}=t,{selected:o=[]}=r;return o.map((e=>{const t=n[e],o=r[e]?.icon,a=o?(0,i.createElement)("img",{src:o,alt:e}):(0,i.createElement)("span",{className:"dashicons "+("post_tag"===e?"dashicons-tag":"dashicons-category")});return t?(0,i.createElement)("span",{key:e},a,Mi(t?.split("a><a")?.join("a>, <a"))):null}))},ir=({post:e,attributes:t})=>{const{readTime:n,content:r}=e,{isMetaReadTime:o,metaReadTimeIcon:a,isMetaReadTimeSec:s,metaReadTimeLabel:l}=t,c=s?`${n?.min}:${n?.sec}`:n?.min;return o&&r?(0,i.createElement)("span",null,a?(0,i.createElement)("img",{src:a,alt:"Author"}):(0,i.createElement)("span",{className:"dashicons dashicons-clock"}),(0,i.createElement)("span",null,c," ",l)):null},rr=({post:e,attributes:t})=>{const{link:n,title:r,commentCount:o,commentStatus:a}=e,{isMetaComment:s,metaCommentIcon:l}=t;return s&&"open"===a?(0,i.createElement)("span",null,l?(0,i.createElement)("img",{src:l,alt:"Author"}):(0,i.createElement)("span",{className:"dashicons dashicons-admin-comments"}),(0,i.createElement)("a",{href:`${n}/#comments`,target:"_blank",rel:"noreferrer","aria-label":`Comments of ${r}`},o)):null},or=({post:e,attributes:t})=>{const{isMeta:n}=t;return n&&(0,i.createElement)("div",{className:`${Oi}Meta`},(0,i.createElement)(Ji,{post:e,attributes:t}),(0,i.createElement)(er,{post:e,attributes:t}),(0,i.createElement)(tr,{post:e,attributes:t}),(0,i.createElement)(nr,{post:e,attributes:t}),(0,i.createElement)(ir,{post:e,attributes:t}),(0,i.createElement)(rr,{post:e,attributes:t}))},ar=({post:e,attributes:t})=>{const{link:n,title:r}=e,{isTitle:o,isTitleLink:a,isLinkNewTab:s}=t;return o?(0,i.createElement)(i.Fragment,null,a?(0,i.createElement)("h3",{className:`${Oi}Title`},(0,i.createElement)("a",{href:n,target:s?"_blank":"_self",rel:"noreferrer",dangerouslySetInnerHTML:{__html:r},"aria-label":r})):(0,i.createElement)("h3",{className:`${Oi}Title`,dangerouslySetInnerHTML:{__html:r}})):null},sr=({post:e,attributes:t})=>{const{elementsSort:n=["title","meta"]}=t;return n.map(((n,r)=>"title"===n?(0,i.createElement)(ar,{key:r,post:e,attributes:t}):(0,i.createElement)(or,{key:r,post:e,attributes:t})))},lr=({post:e,attributes:t})=>{const{excerpt:n,content:r}=e,{isExcerpt:o,isExcerptFromContent:a,isEllipsisOnExcerpt:s,excerptLength:l}=t,c=!a&&n?n:r,d=s&&((u=c)?u.split(" ").length:0)>l?"...":"";var u;const h=-1===l?c:`${((e,t)=>e?e.split(/\s+/).slice(0,t).join(" "):"")(c,l)}${d}`;return o&&c?(0,i.createElement)("div",{className:`${Oi}Excerpt ${Oi}InnerContent`,dangerouslySetInnerHTML:{__html:h}}):null},cr=({post:e,attributes:t})=>{const{link:n}=e,{isReadMore:r,readMorePosition:o="auto",readMoreLabel:a,isLinkNewTab:s}=t;return r?(0,i.createElement)("div",{className:`${Oi}ReadMore ${o}`},(0,i.createElement)("a",{href:n,target:s?"_blank":"_self",rel:"noreferrer",dangerouslySetInnerHTML:{__html:a},"aria-label":a})):null},dr=({post:e,attributes:t,postClass:n})=>{const{subLayout:r}=t,o=Li(n,`${Oi}Default`);return(0,i.createElement)("article",{className:o},(0,i.createElement)(Zi,{post:e,attributes:t}),(0,i.createElement)("div",{className:`${Oi}Text`},(0,i.createElement)(sr,{post:e,attributes:t}),"title-meta"!==r&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(lr,{post:e,attributes:t}),(0,i.createElement)(cr,{post:e,attributes:t}))))},ur=({post:e,attributes:t,postClass:n})=>{const{thumbnail:r}=e,{subLayout:o,isFImg:a}=t,s="left-image"===o,l="right-image"===o,c=Li(n,`${Oi}SideImage`,{grid:a&&r.url,leftImage:s,rightImage:l});return(0,i.createElement)("article",{className:c},s&&(0,i.createElement)(Zi,{post:e,attributes:t}),(0,i.createElement)("div",{className:`${Oi}Text`},(0,i.createElement)(sr,{post:e,attributes:t}),(0,i.createElement)(lr,{post:e,attributes:t}),(0,i.createElement)(cr,{post:e,attributes:t})),l&&(0,i.createElement)(Zi,{post:e,attributes:t}))},hr=({post:e,attributes:t,postClass:n})=>{const{title:r,thumbnail:{url:o}}=e,{subLayout:a}=t,s=Li(n,`${Oi}Overlay`,{[`${Oi}OverlayHover`]:"overlay-content-hover"===a&&o,[`${Oi}OverlayBox`]:"overlay-box"===a||"overlay-content-box"===a,[`${Oi}OverlayHalfContent`]:"overlay-half-content"===a});return(0,i.createElement)("article",{className:s},o&&(0,i.createElement)("img",{src:o,alt:r}),(0,i.createElement)("div",{className:`${Oi}Text`},(0,i.createElement)(sr,{post:e,attributes:t}),"overlay-box"!==a&&"overlay-half-content"!==a&&(0,i.createElement)(i.Fragment,null,(0,i.createElement)(lr,{post:e,attributes:t}),(0,i.createElement)(cr,{post:e,attributes:t}))))},pr=({post:e,attributes:t})=>{const{subLayout:n,content:r={height:"auto"}}=t,{id:o,thumbnail:a}=e,s=Li(`${Oi}Post`,`${Oi}Post-${o}`,`${r?.height}ContentHeight`,{hasThumbnail:a.url});switch(n){case"default":case"title-meta":return(0,i.createElement)(dr,{post:e,attributes:t,postClass:s});case"left-image":case"right-image":return(0,i.createElement)(ur,{post:e,attributes:t,postClass:s});case"overlay-content":case"overlay-content-hover":case"overlay-box":case"overlay-content-box":case"overlay-half-content":return(0,i.createElement)(hr,{post:e,attributes:t,postClass:s});default:return null}};function gr(){return gr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},gr.apply(this,arguments)}function fr(e,t){return fr=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},fr(e,t)}var mr=function(e){var t,n;function i(){var t;return(t=e.call(this)||this).state={columns:[],childRefs:[],hasDistributed:!1},t}n=e,(t=i).prototype=Object.create(n.prototype),t.prototype.constructor=t,fr(t,n);var o=i.prototype;return o.componentDidUpdate=function(){this.state.hasDistributed||this.props.sequential||this.distributeChildren()},i.getDerivedStateFromProps=function(e,t){var n=e.children,r=e.columnsCount,o=r!==t.columns.length;return t&&n===t.children&&!o?null:gr({},i.getEqualCountColumns(n,r),{children:n,hasDistributed:!1})},o.shouldComponentUpdate=function(e){return e.children!==this.state.children||e.columnsCount!==this.props.columnsCount},o.distributeChildren=function(){var e=this,t=this.props,n=t.children,i=t.columnsCount,o=Array(i).fill(0);if(this.state.childRefs.every((function(e){return e.current.getBoundingClientRect().height}))){var a=Array.from({length:i},(function(){return[]})),s=0;r().Children.forEach(n,(function(t){if(t&&r().isValidElement(t)){var n=e.state.childRefs[s].current.getBoundingClientRect().height,i=o.indexOf(Math.min.apply(Math,o));o[i]+=n,a[i].push(t),s++}})),this.setState((function(e){return gr({},e,{columns:a,hasDistributed:!0})}))}},i.getEqualCountColumns=function(e,t){var n=Array.from({length:t},(function(){return[]})),i=0,o=[];return r().Children.forEach(e,(function(e){if(e&&r().isValidElement(e)){var a=r().createRef();o.push(a),n[i%t].push(r().createElement("div",{style:{display:"flex",justifyContent:"stretch"},key:i,ref:a},e)),i++}})),{columns:n,childRefs:o}},o.renderColumns=function(){var e=this.props,t=e.gutter,n=e.itemTag,i=e.itemStyle;return this.state.columns.map((function(e,o){return r().createElement(n,{key:o,style:gr({display:"flex",flexDirection:"column",justifyContent:"flex-start",alignContent:"stretch",flex:1,width:0,gap:t},i)},e.map((function(e){return e})))}))},o.render=function(){var e=this.props,t=e.gutter,n=e.className,i=e.style,o=e.containerTag;return r().createElement(o,{style:gr({display:"flex",flexDirection:"row",justifyContent:"center",alignContent:"stretch",boxSizing:"border-box",width:"100%",gap:t},i),className:n},this.renderColumns())},i}(r().Component);mr.propTypes={},mr.defaultProps={columnsCount:3,gutter:"0",className:null,style:{},containerTag:"div",itemTag:"div",itemStyle:{},sequential:!1};const yr=mr;var vr="undefined"!=typeof window?i.useLayoutEffect:i.useEffect,br=function(e){var t,n,o,a,s,l=e.columnsCountBreakPoints,c=void 0===l?{350:1,750:2,900:3}:l,d=e.gutterBreakPoints,u=void 0===d?{}:d,h=e.children,p=e.className,g=void 0===p?null:p,f=e.style,m=void 0===f?null:f,y=(t=function(){var e=(0,i.useState)(!1),t=e[0],n=e[1];return vr((function(){n(!0)}),[]),t}(),n=(0,i.useState)("undefined"!=typeof window?window.innerWidth:0),o=n[0],a=n[1],s=(0,i.useCallback)((function(){t&&a(window.innerWidth)}),[t]),vr((function(){if(t)return window.addEventListener("resize",s),s(),function(){return window.removeEventListener("resize",s)}}),[t,s]),o),v=(0,i.useCallback)((function(e,t){var n=Object.keys(e).sort((function(e,t){return e-t})),i=n.length>0?e[n[0]]:t;return n.forEach((function(t){t<y&&(i=e[t])})),i}),[y]),b=(0,i.useMemo)((function(){return v(c,1)}),[v,c]),w=(0,i.useMemo)((function(){return v(u,"10px")}),[v,u]);return r().createElement("div",{className:g,style:m},r().Children.map(h,(function(e,t){return r().cloneElement(e,{key:t,columnsCount:b,gutter:w})})))};br.propTypes={};const wr=br,Cr=yr,xr=({posts:e,attributes:t})=>{const{columns:n,columnGap:r,rowGap:o}=t,{desktop:a=3,tablet:s=2,mobile:l=1}=n;return(0,i.createElement)(wr,{className:`${Oi}MasonryPosts`,columnsCountBreakPoints:{0:l,641:s,1025:a}},(0,i.createElement)(Cr,{gutter:`${o}px ${r}px`},e.map((e=>(0,i.createElement)(pr,{key:e.id,post:e,attributes:t})))))},Sr=({posts:e,attributes:t,id:n,Slider:r,Ticker:o})=>{const{layout:a,columns:s}=t,{desktop:l=3,tablet:c=2,mobile:d=1}=s,u=()=>e.map((e=>(0,i.createElement)(pr,{key:e.id,post:e,attributes:t})));switch(a){case"grid":return(0,i.createElement)("div",{className:`${Oi}GridPosts columns-${l} columns-tablet-${c} columns-mobile-${d}`},(0,i.createElement)(u,null));case"grid1":return(0,i.createElement)("div",{className:`${Oi}Grid1Posts`},(0,i.createElement)(u,null));case"masonry":return(0,i.createElement)(xr,{posts:e,attributes:t});case"slider":return(0,i.createElement)(r,{posts:e,attributes:t,id:n});case"ticker":return(0,i.createElement)(o,{posts:e,attributes:t,id:n});default:return null}},_r="·",Er=(e,t)=>{let n=t-e+1;return Array.from({length:n},((t,n)=>n+e))},kr=({attributes:e,totalCount:t,onChange:n})=>{const{layout:r,isPostsPerPageAll:o,postsPerPage:a,isPagination:s,paginationPrevLabel:l,paginationNextLabel:c}=e,[d,u]=(0,i.useState)(1),h=(({currentPage:e,totalCount:t,pageSize:n,siblingCount:r=1})=>(0,i.useMemo)((()=>{const i=Math.ceil(t/n);if(r+5>=i)return Er(1,i);const o=Math.max(e-r,1),a=Math.min(e+r,i),s=o>2,l=a<i-2,c=i;if(!s&&l)return[...Er(1,3+2*r),_r,i];if(s&&!l){let e=Er(i-(3+2*r)+1,i);return[1,_r,...e]}if(s&&l){let e=Er(o,a);return[1,_r,...e,_r,c]}}),[e,t,n,r]))({currentPage:d,totalCount:t,pageSize:a,siblingCount:1});if(0===d||h.length<2)return null;let p=h[h.length-1];const g=e=>{n(e),u(e)};return s&&!o&&"slider"!==r&&"ticker"!==r?(0,i.createElement)("ul",{className:`${Oi}Pagination`},(0,i.createElement)("li",{className:`${Oi}PageNumber ${1===d?"disabled":""}`,onClick:()=>g(d-1)},l),h.map(((e,t)=>e===_r?(0,i.createElement)("li",{key:t,className:"dots"},"·····"):(0,i.createElement)("li",{key:t,className:`${Oi}PageNumber ${e===d?`${Oi}ActivePage`:""}`,onClick:()=>g(e)}," ",e))),(0,i.createElement)("li",{className:`${Oi}PageNumber ${d===p?"disabled":""}`,onClick:()=>g(d+1)},c)):null};function $r(e){return null!==e&&"object"==typeof e&&"constructor"in e&&e.constructor===Object}function Mr(e,t){void 0===e&&(e={}),void 0===t&&(t={});const n=["__proto__","constructor","prototype"];Object.keys(t).filter((e=>n.indexOf(e)<0)).forEach((n=>{void 0===e[n]?e[n]=t[n]:$r(t[n])&&$r(e[n])&&Object.keys(t[n]).length>0&&Mr(e[n],t[n])}))}const Tr={body:{},addEventListener(){},removeEventListener(){},activeElement:{blur(){},nodeName:""},querySelector:()=>null,querySelectorAll:()=>[],getElementById:()=>null,createEvent:()=>({initEvent(){}}),createElement:()=>({children:[],childNodes:[],style:{},setAttribute(){},getElementsByTagName:()=>[]}),createElementNS:()=>({}),importNode:()=>null,location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};function Ar(){const e="undefined"!=typeof document?document:{};return Mr(e,Tr),e}const Lr={document:Tr,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState(){},pushState(){},go(){},back(){}},CustomEvent:function(){return this},addEventListener(){},removeEventListener(){},getComputedStyle:()=>({getPropertyValue:()=>""}),Image(){},Date(){},screen:{},setTimeout(){},clearTimeout(){},matchMedia:()=>({}),requestAnimationFrame:e=>"undefined"==typeof setTimeout?(e(),null):setTimeout(e,0),cancelAnimationFrame(e){"undefined"!=typeof setTimeout&&clearTimeout(e)}};function Rr(){const e="undefined"!=typeof window?window:{};return Mr(e,Lr),e}function Or(e,t){return void 0===t&&(t=0),setTimeout(e,t)}function Ir(){return Date.now()}function Pr(e){return"object"==typeof e&&null!==e&&e.constructor&&"Object"===Object.prototype.toString.call(e).slice(8,-1)}function Nr(){const e=Object(arguments.length<=0?void 0:arguments[0]),t=["__proto__","constructor","prototype"];for(let i=1;i<arguments.length;i+=1){const r=i<0||arguments.length<=i?void 0:arguments[i];if(null!=r&&(n=r,!("undefined"!=typeof window&&void 0!==window.HTMLElement?n instanceof HTMLElement:n&&(1===n.nodeType||11===n.nodeType)))){const n=Object.keys(Object(r)).filter((e=>t.indexOf(e)<0));for(let t=0,i=n.length;t<i;t+=1){const i=n[t],o=Object.getOwnPropertyDescriptor(r,i);void 0!==o&&o.enumerable&&(Pr(e[i])&&Pr(r[i])?r[i].__swiper__?e[i]=r[i]:Nr(e[i],r[i]):!Pr(e[i])&&Pr(r[i])?(e[i]={},r[i].__swiper__?e[i]=r[i]:Nr(e[i],r[i])):e[i]=r[i])}}}var n;return e}function Dr(e,t,n){e.style.setProperty(t,n)}function zr(e){let{swiper:t,targetPosition:n,side:i}=e;const r=Rr(),o=-t.translate;let a,s=null;const l=t.params.speed;t.wrapperEl.style.scrollSnapType="none",r.cancelAnimationFrame(t.cssModeFrameID);const c=n>o?"next":"prev",d=(e,t)=>"next"===c&&e>=t||"prev"===c&&e<=t,u=()=>{a=(new Date).getTime(),null===s&&(s=a);const e=Math.max(Math.min((a-s)/l,1),0),c=.5-Math.cos(e*Math.PI)/2;let h=o+c*(n-o);if(d(h,n)&&(h=n),t.wrapperEl.scrollTo({[i]:h}),d(h,n))return t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.scrollSnapType="",setTimeout((()=>{t.wrapperEl.style.overflow="",t.wrapperEl.scrollTo({[i]:h})})),void r.cancelAnimationFrame(t.cssModeFrameID);t.cssModeFrameID=r.requestAnimationFrame(u)};u()}function Fr(e){return e.querySelector(".swiper-slide-transform")||e.shadowRoot&&e.shadowRoot.querySelector(".swiper-slide-transform")||e}function Br(e,t){void 0===t&&(t="");const n=Rr(),i=[...e.children];return n.HTMLSlotElement&&e instanceof HTMLSlotElement&&i.push(...e.assignedElements()),t?i.filter((e=>e.matches(t))):i}function Hr(e){try{return void console.warn(e)}catch(e){}}function Wr(e,t){void 0===t&&(t=[]);const n=document.createElement(e);return n.classList.add(...Array.isArray(t)?t:function(e){return void 0===e&&(e=""),e.trim().split(" ").filter((e=>!!e.trim()))}(t)),n}function jr(e,t){return Rr().getComputedStyle(e,null).getPropertyValue(t)}function Gr(e){let t,n=e;if(n){for(t=0;null!==(n=n.previousSibling);)1===n.nodeType&&(t+=1);return t}}function Vr(e,t){const n=[];let i=e.parentElement;for(;i;)t?i.matches(t)&&n.push(i):n.push(i),i=i.parentElement;return n}function Ur(e,t,n){const i=Rr();return n?e["width"===t?"offsetWidth":"offsetHeight"]+parseFloat(i.getComputedStyle(e,null).getPropertyValue("width"===t?"margin-right":"margin-top"))+parseFloat(i.getComputedStyle(e,null).getPropertyValue("width"===t?"margin-left":"margin-bottom")):e.offsetWidth}function Kr(e){return(Array.isArray(e)?e:[e]).filter((e=>!!e))}let Yr,qr,Qr;function Xr(){return Yr||(Yr=function(){const e=Rr(),t=Ar();return{smoothScroll:t.documentElement&&t.documentElement.style&&"scrollBehavior"in t.documentElement.style,touch:!!("ontouchstart"in e||e.DocumentTouch&&t instanceof e.DocumentTouch)}}()),Yr}function Zr(e){return void 0===e&&(e={}),qr||(qr=function(e){let{userAgent:t}=void 0===e?{}:e;const n=Xr(),i=Rr(),r=i.navigator.platform,o=t||i.navigator.userAgent,a={ios:!1,android:!1},s=i.screen.width,l=i.screen.height,c=o.match(/(Android);?[\s\/]+([\d.]+)?/);let d=o.match(/(iPad).*OS\s([\d_]+)/);const u=o.match(/(iPod)(.*OS\s([\d_]+))?/),h=!d&&o.match(/(iPhone\sOS|iOS)\s([\d_]+)/),p="Win32"===r;let g="MacIntel"===r;return!d&&g&&n.touch&&["1024x1366","1366x1024","834x1194","1194x834","834x1112","1112x834","768x1024","1024x768","820x1180","1180x820","810x1080","1080x810"].indexOf(`${s}x${l}`)>=0&&(d=o.match(/(Version)\/([\d.]+)/),d||(d=[0,1,"13_0_0"]),g=!1),c&&!p&&(a.os="android",a.android=!0),(d||h||u)&&(a.os="ios",a.ios=!0),a}(e)),qr}function Jr(){return Qr||(Qr=function(){const e=Rr(),t=Zr();let n=!1;function i(){const t=e.navigator.userAgent.toLowerCase();return t.indexOf("safari")>=0&&t.indexOf("chrome")<0&&t.indexOf("android")<0}if(i()){const t=String(e.navigator.userAgent);if(t.includes("Version/")){const[e,i]=t.split("Version/")[1].split(" ")[0].split(".").map((e=>Number(e)));n=e<16||16===e&&i<2}}const r=/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(e.navigator.userAgent),o=i();return{isSafari:n||o,needPerspectiveFix:n,need3dFix:o||r&&t.ios,isWebView:r}}()),Qr}var eo={on(e,t,n){const i=this;if(!i.eventsListeners||i.destroyed)return i;if("function"!=typeof t)return i;const r=n?"unshift":"push";return e.split(" ").forEach((e=>{i.eventsListeners[e]||(i.eventsListeners[e]=[]),i.eventsListeners[e][r](t)})),i},once(e,t,n){const i=this;if(!i.eventsListeners||i.destroyed)return i;if("function"!=typeof t)return i;function r(){i.off(e,r),r.__emitterProxy&&delete r.__emitterProxy;for(var n=arguments.length,o=new Array(n),a=0;a<n;a++)o[a]=arguments[a];t.apply(i,o)}return r.__emitterProxy=t,i.on(e,r,n)},onAny(e,t){const n=this;if(!n.eventsListeners||n.destroyed)return n;if("function"!=typeof e)return n;const i=t?"unshift":"push";return n.eventsAnyListeners.indexOf(e)<0&&n.eventsAnyListeners[i](e),n},offAny(e){const t=this;if(!t.eventsListeners||t.destroyed)return t;if(!t.eventsAnyListeners)return t;const n=t.eventsAnyListeners.indexOf(e);return n>=0&&t.eventsAnyListeners.splice(n,1),t},off(e,t){const n=this;return!n.eventsListeners||n.destroyed?n:n.eventsListeners?(e.split(" ").forEach((e=>{void 0===t?n.eventsListeners[e]=[]:n.eventsListeners[e]&&n.eventsListeners[e].forEach(((i,r)=>{(i===t||i.__emitterProxy&&i.__emitterProxy===t)&&n.eventsListeners[e].splice(r,1)}))})),n):n},emit(){const e=this;if(!e.eventsListeners||e.destroyed)return e;if(!e.eventsListeners)return e;let t,n,i;for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return"string"==typeof o[0]||Array.isArray(o[0])?(t=o[0],n=o.slice(1,o.length),i=e):(t=o[0].events,n=o[0].data,i=o[0].context||e),n.unshift(i),(Array.isArray(t)?t:t.split(" ")).forEach((t=>{e.eventsAnyListeners&&e.eventsAnyListeners.length&&e.eventsAnyListeners.forEach((e=>{e.apply(i,[t,...n])})),e.eventsListeners&&e.eventsListeners[t]&&e.eventsListeners[t].forEach((e=>{e.apply(i,n)}))})),e}};const to=(e,t,n)=>{t&&!e.classList.contains(n)?e.classList.add(n):!t&&e.classList.contains(n)&&e.classList.remove(n)},no=(e,t,n)=>{t&&!e.classList.contains(n)?e.classList.add(n):!t&&e.classList.contains(n)&&e.classList.remove(n)},io=(e,t)=>{if(!e||e.destroyed||!e.params)return;const n=t.closest(e.isElement?"swiper-slide":`.${e.params.slideClass}`);if(n){let t=n.querySelector(`.${e.params.lazyPreloaderClass}`);!t&&e.isElement&&(n.shadowRoot?t=n.shadowRoot.querySelector(`.${e.params.lazyPreloaderClass}`):requestAnimationFrame((()=>{n.shadowRoot&&(t=n.shadowRoot.querySelector(`.${e.params.lazyPreloaderClass}`),t&&t.remove())}))),t&&t.remove()}},ro=(e,t)=>{if(!e.slides[t])return;const n=e.slides[t].querySelector('[loading="lazy"]');n&&n.removeAttribute("loading")},oo=e=>{if(!e||e.destroyed||!e.params)return;let t=e.params.lazyPreloadPrevNext;const n=e.slides.length;if(!n||!t||t<0)return;t=Math.min(t,n);const i="auto"===e.params.slidesPerView?e.slidesPerViewDynamic():Math.ceil(e.params.slidesPerView),r=e.activeIndex;if(e.params.grid&&e.params.grid.rows>1){const n=r,o=[n-t];return o.push(...Array.from({length:t}).map(((e,t)=>n+i+t))),void e.slides.forEach(((t,n)=>{o.includes(t.column)&&ro(e,n)}))}const o=r+i-1;if(e.params.rewind||e.params.loop)for(let i=r-t;i<=o+t;i+=1){const t=(i%n+n)%n;(t<r||t>o)&&ro(e,t)}else for(let i=Math.max(r-t,0);i<=Math.min(o+t,n-1);i+=1)i!==r&&(i>o||i<r)&&ro(e,i)};var ao={updateSize:function(){const e=this;let t,n;const i=e.el;t=void 0!==e.params.width&&null!==e.params.width?e.params.width:i.clientWidth,n=void 0!==e.params.height&&null!==e.params.height?e.params.height:i.clientHeight,0===t&&e.isHorizontal()||0===n&&e.isVertical()||(t=t-parseInt(jr(i,"padding-left")||0,10)-parseInt(jr(i,"padding-right")||0,10),n=n-parseInt(jr(i,"padding-top")||0,10)-parseInt(jr(i,"padding-bottom")||0,10),Number.isNaN(t)&&(t=0),Number.isNaN(n)&&(n=0),Object.assign(e,{width:t,height:n,size:e.isHorizontal()?t:n}))},updateSlides:function(){const e=this;function t(t,n){return parseFloat(t.getPropertyValue(e.getDirectionLabel(n))||0)}const n=e.params,{wrapperEl:i,slidesEl:r,size:o,rtlTranslate:a,wrongRTL:s}=e,l=e.virtual&&n.virtual.enabled,c=l?e.virtual.slides.length:e.slides.length,d=Br(r,`.${e.params.slideClass}, swiper-slide`),u=l?e.virtual.slides.length:d.length;let h=[];const p=[],g=[];let f=n.slidesOffsetBefore;"function"==typeof f&&(f=n.slidesOffsetBefore.call(e));let m=n.slidesOffsetAfter;"function"==typeof m&&(m=n.slidesOffsetAfter.call(e));const y=e.snapGrid.length,v=e.slidesGrid.length;let b=n.spaceBetween,w=-f,C=0,x=0;if(void 0===o)return;"string"==typeof b&&b.indexOf("%")>=0?b=parseFloat(b.replace("%",""))/100*o:"string"==typeof b&&(b=parseFloat(b)),e.virtualSize=-b,d.forEach((e=>{a?e.style.marginLeft="":e.style.marginRight="",e.style.marginBottom="",e.style.marginTop=""})),n.centeredSlides&&n.cssMode&&(Dr(i,"--swiper-centered-offset-before",""),Dr(i,"--swiper-centered-offset-after",""));const S=n.grid&&n.grid.rows>1&&e.grid;let _;S?e.grid.initSlides(d):e.grid&&e.grid.unsetSlides();const E="auto"===n.slidesPerView&&n.breakpoints&&Object.keys(n.breakpoints).filter((e=>void 0!==n.breakpoints[e].slidesPerView)).length>0;for(let i=0;i<u;i+=1){let r;if(_=0,d[i]&&(r=d[i]),S&&e.grid.updateSlide(i,r,d),!d[i]||"none"!==jr(r,"display")){if("auto"===n.slidesPerView){E&&(d[i].style[e.getDirectionLabel("width")]="");const o=getComputedStyle(r),a=r.style.transform,s=r.style.webkitTransform;if(a&&(r.style.transform="none"),s&&(r.style.webkitTransform="none"),n.roundLengths)_=e.isHorizontal()?Ur(r,"width",!0):Ur(r,"height",!0);else{const e=t(o,"width"),n=t(o,"padding-left"),i=t(o,"padding-right"),a=t(o,"margin-left"),s=t(o,"margin-right"),l=o.getPropertyValue("box-sizing");if(l&&"border-box"===l)_=e+a+s;else{const{clientWidth:t,offsetWidth:o}=r;_=e+n+i+a+s+(o-t)}}a&&(r.style.transform=a),s&&(r.style.webkitTransform=s),n.roundLengths&&(_=Math.floor(_))}else _=(o-(n.slidesPerView-1)*b)/n.slidesPerView,n.roundLengths&&(_=Math.floor(_)),d[i]&&(d[i].style[e.getDirectionLabel("width")]=`${_}px`);d[i]&&(d[i].swiperSlideSize=_),g.push(_),n.centeredSlides?(w=w+_/2+C/2+b,0===C&&0!==i&&(w=w-o/2-b),0===i&&(w=w-o/2-b),Math.abs(w)<.001&&(w=0),n.roundLengths&&(w=Math.floor(w)),x%n.slidesPerGroup==0&&h.push(w),p.push(w)):(n.roundLengths&&(w=Math.floor(w)),(x-Math.min(e.params.slidesPerGroupSkip,x))%e.params.slidesPerGroup==0&&h.push(w),p.push(w),w=w+_+b),e.virtualSize+=_+b,C=_,x+=1}}if(e.virtualSize=Math.max(e.virtualSize,o)+m,a&&s&&("slide"===n.effect||"coverflow"===n.effect)&&(i.style.width=`${e.virtualSize+b}px`),n.setWrapperSize&&(i.style[e.getDirectionLabel("width")]=`${e.virtualSize+b}px`),S&&e.grid.updateWrapperSize(_,h),!n.centeredSlides){const t=[];for(let i=0;i<h.length;i+=1){let r=h[i];n.roundLengths&&(r=Math.floor(r)),h[i]<=e.virtualSize-o&&t.push(r)}h=t,Math.floor(e.virtualSize-o)-Math.floor(h[h.length-1])>1&&h.push(e.virtualSize-o)}if(l&&n.loop){const t=g[0]+b;if(n.slidesPerGroup>1){const i=Math.ceil((e.virtual.slidesBefore+e.virtual.slidesAfter)/n.slidesPerGroup),r=t*n.slidesPerGroup;for(let e=0;e<i;e+=1)h.push(h[h.length-1]+r)}for(let i=0;i<e.virtual.slidesBefore+e.virtual.slidesAfter;i+=1)1===n.slidesPerGroup&&h.push(h[h.length-1]+t),p.push(p[p.length-1]+t),e.virtualSize+=t}if(0===h.length&&(h=[0]),0!==b){const t=e.isHorizontal()&&a?"marginLeft":e.getDirectionLabel("marginRight");d.filter(((e,t)=>!(n.cssMode&&!n.loop)||t!==d.length-1)).forEach((e=>{e.style[t]=`${b}px`}))}if(n.centeredSlides&&n.centeredSlidesBounds){let e=0;g.forEach((t=>{e+=t+(b||0)})),e-=b;const t=e>o?e-o:0;h=h.map((e=>e<=0?-f:e>t?t+m:e))}if(n.centerInsufficientSlides){let e=0;g.forEach((t=>{e+=t+(b||0)})),e-=b;const t=(n.slidesOffsetBefore||0)+(n.slidesOffsetAfter||0);if(e+t<o){const n=(o-e-t)/2;h.forEach(((e,t)=>{h[t]=e-n})),p.forEach(((e,t)=>{p[t]=e+n}))}}if(Object.assign(e,{slides:d,snapGrid:h,slidesGrid:p,slidesSizesGrid:g}),n.centeredSlides&&n.cssMode&&!n.centeredSlidesBounds){Dr(i,"--swiper-centered-offset-before",-h[0]+"px"),Dr(i,"--swiper-centered-offset-after",e.size/2-g[g.length-1]/2+"px");const t=-e.snapGrid[0],n=-e.slidesGrid[0];e.snapGrid=e.snapGrid.map((e=>e+t)),e.slidesGrid=e.slidesGrid.map((e=>e+n))}if(u!==c&&e.emit("slidesLengthChange"),h.length!==y&&(e.params.watchOverflow&&e.checkOverflow(),e.emit("snapGridLengthChange")),p.length!==v&&e.emit("slidesGridLengthChange"),n.watchSlidesProgress&&e.updateSlidesOffset(),e.emit("slidesUpdated"),!(l||n.cssMode||"slide"!==n.effect&&"fade"!==n.effect)){const t=`${n.containerModifierClass}backface-hidden`,i=e.el.classList.contains(t);u<=n.maxBackfaceHiddenSlides?i||e.el.classList.add(t):i&&e.el.classList.remove(t)}},updateAutoHeight:function(e){const t=this,n=[],i=t.virtual&&t.params.virtual.enabled;let r,o=0;"number"==typeof e?t.setTransition(e):!0===e&&t.setTransition(t.params.speed);const a=e=>i?t.slides[t.getSlideIndexByData(e)]:t.slides[e];if("auto"!==t.params.slidesPerView&&t.params.slidesPerView>1)if(t.params.centeredSlides)(t.visibleSlides||[]).forEach((e=>{n.push(e)}));else for(r=0;r<Math.ceil(t.params.slidesPerView);r+=1){const e=t.activeIndex+r;if(e>t.slides.length&&!i)break;n.push(a(e))}else n.push(a(t.activeIndex));for(r=0;r<n.length;r+=1)if(void 0!==n[r]){const e=n[r].offsetHeight;o=e>o?e:o}(o||0===o)&&(t.wrapperEl.style.height=`${o}px`)},updateSlidesOffset:function(){const e=this,t=e.slides,n=e.isElement?e.isHorizontal()?e.wrapperEl.offsetLeft:e.wrapperEl.offsetTop:0;for(let i=0;i<t.length;i+=1)t[i].swiperSlideOffset=(e.isHorizontal()?t[i].offsetLeft:t[i].offsetTop)-n-e.cssOverflowAdjustment()},updateSlidesProgress:function(e){void 0===e&&(e=this&&this.translate||0);const t=this,n=t.params,{slides:i,rtlTranslate:r,snapGrid:o}=t;if(0===i.length)return;void 0===i[0].swiperSlideOffset&&t.updateSlidesOffset();let a=-e;r&&(a=e),t.visibleSlidesIndexes=[],t.visibleSlides=[];let s=n.spaceBetween;"string"==typeof s&&s.indexOf("%")>=0?s=parseFloat(s.replace("%",""))/100*t.size:"string"==typeof s&&(s=parseFloat(s));for(let e=0;e<i.length;e+=1){const l=i[e];let c=l.swiperSlideOffset;n.cssMode&&n.centeredSlides&&(c-=i[0].swiperSlideOffset);const d=(a+(n.centeredSlides?t.minTranslate():0)-c)/(l.swiperSlideSize+s),u=(a-o[0]+(n.centeredSlides?t.minTranslate():0)-c)/(l.swiperSlideSize+s),h=-(a-c),p=h+t.slidesSizesGrid[e],g=h>=0&&h<=t.size-t.slidesSizesGrid[e],f=h>=0&&h<t.size-1||p>1&&p<=t.size||h<=0&&p>=t.size;f&&(t.visibleSlides.push(l),t.visibleSlidesIndexes.push(e)),to(l,f,n.slideVisibleClass),to(l,g,n.slideFullyVisibleClass),l.progress=r?-d:d,l.originalProgress=r?-u:u}},updateProgress:function(e){const t=this;if(void 0===e){const n=t.rtlTranslate?-1:1;e=t&&t.translate&&t.translate*n||0}const n=t.params,i=t.maxTranslate()-t.minTranslate();let{progress:r,isBeginning:o,isEnd:a,progressLoop:s}=t;const l=o,c=a;if(0===i)r=0,o=!0,a=!0;else{r=(e-t.minTranslate())/i;const n=Math.abs(e-t.minTranslate())<1,s=Math.abs(e-t.maxTranslate())<1;o=n||r<=0,a=s||r>=1,n&&(r=0),s&&(r=1)}if(n.loop){const n=t.getSlideIndexByData(0),i=t.getSlideIndexByData(t.slides.length-1),r=t.slidesGrid[n],o=t.slidesGrid[i],a=t.slidesGrid[t.slidesGrid.length-1],l=Math.abs(e);s=l>=r?(l-r)/a:(l+a-o)/a,s>1&&(s-=1)}Object.assign(t,{progress:r,progressLoop:s,isBeginning:o,isEnd:a}),(n.watchSlidesProgress||n.centeredSlides&&n.autoHeight)&&t.updateSlidesProgress(e),o&&!l&&t.emit("reachBeginning toEdge"),a&&!c&&t.emit("reachEnd toEdge"),(l&&!o||c&&!a)&&t.emit("fromEdge"),t.emit("progress",r)},updateSlidesClasses:function(){const e=this,{slides:t,params:n,slidesEl:i,activeIndex:r}=e,o=e.virtual&&n.virtual.enabled,a=e.grid&&n.grid&&n.grid.rows>1,s=e=>Br(i,`.${n.slideClass}${e}, swiper-slide${e}`)[0];let l,c,d;if(o)if(n.loop){let t=r-e.virtual.slidesBefore;t<0&&(t=e.virtual.slides.length+t),t>=e.virtual.slides.length&&(t-=e.virtual.slides.length),l=s(`[data-swiper-slide-index="${t}"]`)}else l=s(`[data-swiper-slide-index="${r}"]`);else a?(l=t.find((e=>e.column===r)),d=t.find((e=>e.column===r+1)),c=t.find((e=>e.column===r-1))):l=t[r];l&&(a||(d=function(e,t){const n=[];for(;e.nextElementSibling;){const i=e.nextElementSibling;t?i.matches(t)&&n.push(i):n.push(i),e=i}return n}(l,`.${n.slideClass}, swiper-slide`)[0],n.loop&&!d&&(d=t[0]),c=function(e,t){const n=[];for(;e.previousElementSibling;){const i=e.previousElementSibling;t?i.matches(t)&&n.push(i):n.push(i),e=i}return n}(l,`.${n.slideClass}, swiper-slide`)[0],n.loop&&0===!c&&(c=t[t.length-1]))),t.forEach((e=>{no(e,e===l,n.slideActiveClass),no(e,e===d,n.slideNextClass),no(e,e===c,n.slidePrevClass)})),e.emitSlidesClasses()},updateActiveIndex:function(e){const t=this,n=t.rtlTranslate?t.translate:-t.translate,{snapGrid:i,params:r,activeIndex:o,realIndex:a,snapIndex:s}=t;let l,c=e;const d=e=>{let n=e-t.virtual.slidesBefore;return n<0&&(n=t.virtual.slides.length+n),n>=t.virtual.slides.length&&(n-=t.virtual.slides.length),n};if(void 0===c&&(c=function(e){const{slidesGrid:t,params:n}=e,i=e.rtlTranslate?e.translate:-e.translate;let r;for(let e=0;e<t.length;e+=1)void 0!==t[e+1]?i>=t[e]&&i<t[e+1]-(t[e+1]-t[e])/2?r=e:i>=t[e]&&i<t[e+1]&&(r=e+1):i>=t[e]&&(r=e);return n.normalizeSlideIndex&&(r<0||void 0===r)&&(r=0),r}(t)),i.indexOf(n)>=0)l=i.indexOf(n);else{const e=Math.min(r.slidesPerGroupSkip,c);l=e+Math.floor((c-e)/r.slidesPerGroup)}if(l>=i.length&&(l=i.length-1),c===o&&!t.params.loop)return void(l!==s&&(t.snapIndex=l,t.emit("snapIndexChange")));if(c===o&&t.params.loop&&t.virtual&&t.params.virtual.enabled)return void(t.realIndex=d(c));const u=t.grid&&r.grid&&r.grid.rows>1;let h;if(t.virtual&&r.virtual.enabled&&r.loop)h=d(c);else if(u){const e=t.slides.find((e=>e.column===c));let n=parseInt(e.getAttribute("data-swiper-slide-index"),10);Number.isNaN(n)&&(n=Math.max(t.slides.indexOf(e),0)),h=Math.floor(n/r.grid.rows)}else if(t.slides[c]){const e=t.slides[c].getAttribute("data-swiper-slide-index");h=e?parseInt(e,10):c}else h=c;Object.assign(t,{previousSnapIndex:s,snapIndex:l,previousRealIndex:a,realIndex:h,previousIndex:o,activeIndex:c}),t.initialized&&oo(t),t.emit("activeIndexChange"),t.emit("snapIndexChange"),(t.initialized||t.params.runCallbacksOnInit)&&(a!==h&&t.emit("realIndexChange"),t.emit("slideChange"))},updateClickedSlide:function(e,t){const n=this,i=n.params;let r=e.closest(`.${i.slideClass}, swiper-slide`);!r&&n.isElement&&t&&t.length>1&&t.includes(e)&&[...t.slice(t.indexOf(e)+1,t.length)].forEach((e=>{!r&&e.matches&&e.matches(`.${i.slideClass}, swiper-slide`)&&(r=e)}));let o,a=!1;if(r)for(let e=0;e<n.slides.length;e+=1)if(n.slides[e]===r){a=!0,o=e;break}if(!r||!a)return n.clickedSlide=void 0,void(n.clickedIndex=void 0);n.clickedSlide=r,n.virtual&&n.params.virtual.enabled?n.clickedIndex=parseInt(r.getAttribute("data-swiper-slide-index"),10):n.clickedIndex=o,i.slideToClickedSlide&&void 0!==n.clickedIndex&&n.clickedIndex!==n.activeIndex&&n.slideToClickedSlide()}};function so(e){let{swiper:t,runCallbacks:n,direction:i,step:r}=e;const{activeIndex:o,previousIndex:a}=t;let s=i;if(s||(s=o>a?"next":o<a?"prev":"reset"),t.emit(`transition${r}`),n&&o!==a){if("reset"===s)return void t.emit(`slideResetTransition${r}`);t.emit(`slideChangeTransition${r}`),"next"===s?t.emit(`slideNextTransition${r}`):t.emit(`slidePrevTransition${r}`)}}var lo={slideTo:function(e,t,n,i,r){void 0===e&&(e=0),void 0===n&&(n=!0),"string"==typeof e&&(e=parseInt(e,10));const o=this;let a=e;a<0&&(a=0);const{params:s,snapGrid:l,slidesGrid:c,previousIndex:d,activeIndex:u,rtlTranslate:h,wrapperEl:p,enabled:g}=o;if(!g&&!i&&!r||o.destroyed||o.animating&&s.preventInteractionOnTransition)return!1;void 0===t&&(t=o.params.speed);const f=Math.min(o.params.slidesPerGroupSkip,a);let m=f+Math.floor((a-f)/o.params.slidesPerGroup);m>=l.length&&(m=l.length-1);const y=-l[m];if(s.normalizeSlideIndex)for(let e=0;e<c.length;e+=1){const t=-Math.floor(100*y),n=Math.floor(100*c[e]),i=Math.floor(100*c[e+1]);void 0!==c[e+1]?t>=n&&t<i-(i-n)/2?a=e:t>=n&&t<i&&(a=e+1):t>=n&&(a=e)}if(o.initialized&&a!==u){if(!o.allowSlideNext&&(h?y>o.translate&&y>o.minTranslate():y<o.translate&&y<o.minTranslate()))return!1;if(!o.allowSlidePrev&&y>o.translate&&y>o.maxTranslate()&&(u||0)!==a)return!1}let v;a!==(d||0)&&n&&o.emit("beforeSlideChangeStart"),o.updateProgress(y),v=a>u?"next":a<u?"prev":"reset";const b=o.virtual&&o.params.virtual.enabled;if((!b||!r)&&(h&&-y===o.translate||!h&&y===o.translate))return o.updateActiveIndex(a),s.autoHeight&&o.updateAutoHeight(),o.updateSlidesClasses(),"slide"!==s.effect&&o.setTranslate(y),"reset"!==v&&(o.transitionStart(n,v),o.transitionEnd(n,v)),!1;if(s.cssMode){const e=o.isHorizontal(),n=h?y:-y;if(0===t)b&&(o.wrapperEl.style.scrollSnapType="none",o._immediateVirtual=!0),b&&!o._cssModeVirtualInitialSet&&o.params.initialSlide>0?(o._cssModeVirtualInitialSet=!0,requestAnimationFrame((()=>{p[e?"scrollLeft":"scrollTop"]=n}))):p[e?"scrollLeft":"scrollTop"]=n,b&&requestAnimationFrame((()=>{o.wrapperEl.style.scrollSnapType="",o._immediateVirtual=!1}));else{if(!o.support.smoothScroll)return zr({swiper:o,targetPosition:n,side:e?"left":"top"}),!0;p.scrollTo({[e?"left":"top"]:n,behavior:"smooth"})}return!0}const w=Jr().isSafari;return b&&!r&&w&&o.isElement&&o.virtual.update(!1,!1,a),o.setTransition(t),o.setTranslate(y),o.updateActiveIndex(a),o.updateSlidesClasses(),o.emit("beforeTransitionStart",t,i),o.transitionStart(n,v),0===t?o.transitionEnd(n,v):o.animating||(o.animating=!0,o.onSlideToWrapperTransitionEnd||(o.onSlideToWrapperTransitionEnd=function(e){o&&!o.destroyed&&e.target===this&&(o.wrapperEl.removeEventListener("transitionend",o.onSlideToWrapperTransitionEnd),o.onSlideToWrapperTransitionEnd=null,delete o.onSlideToWrapperTransitionEnd,o.transitionEnd(n,v))}),o.wrapperEl.addEventListener("transitionend",o.onSlideToWrapperTransitionEnd)),!0},slideToLoop:function(e,t,n,i){void 0===e&&(e=0),void 0===n&&(n=!0),"string"==typeof e&&(e=parseInt(e,10));const r=this;if(r.destroyed)return;void 0===t&&(t=r.params.speed);const o=r.grid&&r.params.grid&&r.params.grid.rows>1;let a=e;if(r.params.loop)if(r.virtual&&r.params.virtual.enabled)a+=r.virtual.slidesBefore;else{let e;if(o){const t=a*r.params.grid.rows;e=r.slides.find((e=>1*e.getAttribute("data-swiper-slide-index")===t)).column}else e=r.getSlideIndexByData(a);const t=o?Math.ceil(r.slides.length/r.params.grid.rows):r.slides.length,{centeredSlides:n}=r.params;let s=r.params.slidesPerView;"auto"===s?s=r.slidesPerViewDynamic():(s=Math.ceil(parseFloat(r.params.slidesPerView,10)),n&&s%2==0&&(s+=1));let l=t-e<s;if(n&&(l=l||e<Math.ceil(s/2)),i&&n&&"auto"!==r.params.slidesPerView&&!o&&(l=!1),l){const i=n?e<r.activeIndex?"prev":"next":e-r.activeIndex-1<r.params.slidesPerView?"next":"prev";r.loopFix({direction:i,slideTo:!0,activeSlideIndex:"next"===i?e+1:e-t+1,slideRealIndex:"next"===i?r.realIndex:void 0})}if(o){const e=a*r.params.grid.rows;a=r.slides.find((t=>1*t.getAttribute("data-swiper-slide-index")===e)).column}else a=r.getSlideIndexByData(a)}return requestAnimationFrame((()=>{r.slideTo(a,t,n,i)})),r},slideNext:function(e,t,n){void 0===t&&(t=!0);const i=this,{enabled:r,params:o,animating:a}=i;if(!r||i.destroyed)return i;void 0===e&&(e=i.params.speed);let s=o.slidesPerGroup;"auto"===o.slidesPerView&&1===o.slidesPerGroup&&o.slidesPerGroupAuto&&(s=Math.max(i.slidesPerViewDynamic("current",!0),1));const l=i.activeIndex<o.slidesPerGroupSkip?1:s,c=i.virtual&&o.virtual.enabled;if(o.loop){if(a&&!c&&o.loopPreventsSliding)return!1;if(i.loopFix({direction:"next"}),i._clientLeft=i.wrapperEl.clientLeft,i.activeIndex===i.slides.length-1&&o.cssMode)return requestAnimationFrame((()=>{i.slideTo(i.activeIndex+l,e,t,n)})),!0}return o.rewind&&i.isEnd?i.slideTo(0,e,t,n):i.slideTo(i.activeIndex+l,e,t,n)},slidePrev:function(e,t,n){void 0===t&&(t=!0);const i=this,{params:r,snapGrid:o,slidesGrid:a,rtlTranslate:s,enabled:l,animating:c}=i;if(!l||i.destroyed)return i;void 0===e&&(e=i.params.speed);const d=i.virtual&&r.virtual.enabled;if(r.loop){if(c&&!d&&r.loopPreventsSliding)return!1;i.loopFix({direction:"prev"}),i._clientLeft=i.wrapperEl.clientLeft}function u(e){return e<0?-Math.floor(Math.abs(e)):Math.floor(e)}const h=u(s?i.translate:-i.translate),p=o.map((e=>u(e))),g=r.freeMode&&r.freeMode.enabled;let f=o[p.indexOf(h)-1];if(void 0===f&&(r.cssMode||g)){let e;o.forEach(((t,n)=>{h>=t&&(e=n)})),void 0!==e&&(f=g?o[e]:o[e>0?e-1:e])}let m=0;if(void 0!==f&&(m=a.indexOf(f),m<0&&(m=i.activeIndex-1),"auto"===r.slidesPerView&&1===r.slidesPerGroup&&r.slidesPerGroupAuto&&(m=m-i.slidesPerViewDynamic("previous",!0)+1,m=Math.max(m,0))),r.rewind&&i.isBeginning){const r=i.params.virtual&&i.params.virtual.enabled&&i.virtual?i.virtual.slides.length-1:i.slides.length-1;return i.slideTo(r,e,t,n)}return r.loop&&0===i.activeIndex&&r.cssMode?(requestAnimationFrame((()=>{i.slideTo(m,e,t,n)})),!0):i.slideTo(m,e,t,n)},slideReset:function(e,t,n){void 0===t&&(t=!0);const i=this;if(!i.destroyed)return void 0===e&&(e=i.params.speed),i.slideTo(i.activeIndex,e,t,n)},slideToClosest:function(e,t,n,i){void 0===t&&(t=!0),void 0===i&&(i=.5);const r=this;if(r.destroyed)return;void 0===e&&(e=r.params.speed);let o=r.activeIndex;const a=Math.min(r.params.slidesPerGroupSkip,o),s=a+Math.floor((o-a)/r.params.slidesPerGroup),l=r.rtlTranslate?r.translate:-r.translate;if(l>=r.snapGrid[s]){const e=r.snapGrid[s];l-e>(r.snapGrid[s+1]-e)*i&&(o+=r.params.slidesPerGroup)}else{const e=r.snapGrid[s-1];l-e<=(r.snapGrid[s]-e)*i&&(o-=r.params.slidesPerGroup)}return o=Math.max(o,0),o=Math.min(o,r.slidesGrid.length-1),r.slideTo(o,e,t,n)},slideToClickedSlide:function(){const e=this;if(e.destroyed)return;const{params:t,slidesEl:n}=e,i="auto"===t.slidesPerView?e.slidesPerViewDynamic():t.slidesPerView;let r,o=e.clickedIndex;const a=e.isElement?"swiper-slide":`.${t.slideClass}`;if(t.loop){if(e.animating)return;r=parseInt(e.clickedSlide.getAttribute("data-swiper-slide-index"),10),t.centeredSlides?o<e.loopedSlides-i/2||o>e.slides.length-e.loopedSlides+i/2?(e.loopFix(),o=e.getSlideIndex(Br(n,`${a}[data-swiper-slide-index="${r}"]`)[0]),Or((()=>{e.slideTo(o)}))):e.slideTo(o):o>e.slides.length-i?(e.loopFix(),o=e.getSlideIndex(Br(n,`${a}[data-swiper-slide-index="${r}"]`)[0]),Or((()=>{e.slideTo(o)}))):e.slideTo(o)}else e.slideTo(o)}},co={loopCreate:function(e,t){const n=this,{params:i,slidesEl:r}=n;if(!i.loop||n.virtual&&n.params.virtual.enabled)return;const o=()=>{Br(r,`.${i.slideClass}, swiper-slide`).forEach(((e,t)=>{e.setAttribute("data-swiper-slide-index",t)}))},a=n.grid&&i.grid&&i.grid.rows>1,s=i.slidesPerGroup*(a?i.grid.rows:1),l=n.slides.length%s!=0,c=a&&n.slides.length%i.grid.rows!=0,d=e=>{for(let t=0;t<e;t+=1){const e=n.isElement?Wr("swiper-slide",[i.slideBlankClass]):Wr("div",[i.slideClass,i.slideBlankClass]);n.slidesEl.append(e)}};l?(i.loopAddBlankSlides?(d(s-n.slides.length%s),n.recalcSlides(),n.updateSlides()):Hr("Swiper Loop Warning: The number of slides is not even to slidesPerGroup, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)"),o()):c?(i.loopAddBlankSlides?(d(i.grid.rows-n.slides.length%i.grid.rows),n.recalcSlides(),n.updateSlides()):Hr("Swiper Loop Warning: The number of slides is not even to grid.rows, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)"),o()):o(),n.loopFix({slideRealIndex:e,direction:i.centeredSlides?void 0:"next",initial:t})},loopFix:function(e){let{slideRealIndex:t,slideTo:n=!0,direction:i,setTranslate:r,activeSlideIndex:o,initial:a,byController:s,byMousewheel:l}=void 0===e?{}:e;const c=this;if(!c.params.loop)return;c.emit("beforeLoopFix");const{slides:d,allowSlidePrev:u,allowSlideNext:h,slidesEl:p,params:g}=c,{centeredSlides:f,initialSlide:m}=g;if(c.allowSlidePrev=!0,c.allowSlideNext=!0,c.virtual&&g.virtual.enabled)return n&&(g.centeredSlides||0!==c.snapIndex?g.centeredSlides&&c.snapIndex<g.slidesPerView?c.slideTo(c.virtual.slides.length+c.snapIndex,0,!1,!0):c.snapIndex===c.snapGrid.length-1&&c.slideTo(c.virtual.slidesBefore,0,!1,!0):c.slideTo(c.virtual.slides.length,0,!1,!0)),c.allowSlidePrev=u,c.allowSlideNext=h,void c.emit("loopFix");let y=g.slidesPerView;"auto"===y?y=c.slidesPerViewDynamic():(y=Math.ceil(parseFloat(g.slidesPerView,10)),f&&y%2==0&&(y+=1));const v=g.slidesPerGroupAuto?y:g.slidesPerGroup;let b=v;b%v!=0&&(b+=v-b%v),b+=g.loopAdditionalSlides,c.loopedSlides=b;const w=c.grid&&g.grid&&g.grid.rows>1;d.length<y+b||"cards"===c.params.effect&&d.length<y+2*b?Hr("Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled or not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters"):w&&"row"===g.grid.fill&&Hr("Swiper Loop Warning: Loop mode is not compatible with grid.fill = `row`");const C=[],x=[],S=w?Math.ceil(d.length/g.grid.rows):d.length,_=a&&S-m<y&&!f;let E=_?m:c.activeIndex;void 0===o?o=c.getSlideIndex(d.find((e=>e.classList.contains(g.slideActiveClass)))):E=o;const k="next"===i||!i,$="prev"===i||!i;let M=0,T=0;const A=(w?d[o].column:o)+(f&&void 0===r?-y/2+.5:0);if(A<b){M=Math.max(b-A,v);for(let e=0;e<b-A;e+=1){const t=e-Math.floor(e/S)*S;if(w){const e=S-t-1;for(let t=d.length-1;t>=0;t-=1)d[t].column===e&&C.push(t)}else C.push(S-t-1)}}else if(A+y>S-b){T=Math.max(A-(S-2*b),v),_&&(T=Math.max(T,y-S+m+1));for(let e=0;e<T;e+=1){const t=e-Math.floor(e/S)*S;w?d.forEach(((e,n)=>{e.column===t&&x.push(n)})):x.push(t)}}if(c.__preventObserver__=!0,requestAnimationFrame((()=>{c.__preventObserver__=!1})),"cards"===c.params.effect&&d.length<y+2*b&&(x.includes(o)&&x.splice(x.indexOf(o),1),C.includes(o)&&C.splice(C.indexOf(o),1)),$&&C.forEach((e=>{d[e].swiperLoopMoveDOM=!0,p.prepend(d[e]),d[e].swiperLoopMoveDOM=!1})),k&&x.forEach((e=>{d[e].swiperLoopMoveDOM=!0,p.append(d[e]),d[e].swiperLoopMoveDOM=!1})),c.recalcSlides(),"auto"===g.slidesPerView?c.updateSlides():w&&(C.length>0&&$||x.length>0&&k)&&c.slides.forEach(((e,t)=>{c.grid.updateSlide(t,e,c.slides)})),g.watchSlidesProgress&&c.updateSlidesOffset(),n)if(C.length>0&&$){if(void 0===t){const e=c.slidesGrid[E],t=c.slidesGrid[E+M]-e;l?c.setTranslate(c.translate-t):(c.slideTo(E+Math.ceil(M),0,!1,!0),r&&(c.touchEventsData.startTranslate=c.touchEventsData.startTranslate-t,c.touchEventsData.currentTranslate=c.touchEventsData.currentTranslate-t))}else if(r){const e=w?C.length/g.grid.rows:C.length;c.slideTo(c.activeIndex+e,0,!1,!0),c.touchEventsData.currentTranslate=c.translate}}else if(x.length>0&&k)if(void 0===t){const e=c.slidesGrid[E],t=c.slidesGrid[E-T]-e;l?c.setTranslate(c.translate-t):(c.slideTo(E-T,0,!1,!0),r&&(c.touchEventsData.startTranslate=c.touchEventsData.startTranslate-t,c.touchEventsData.currentTranslate=c.touchEventsData.currentTranslate-t))}else{const e=w?x.length/g.grid.rows:x.length;c.slideTo(c.activeIndex-e,0,!1,!0)}if(c.allowSlidePrev=u,c.allowSlideNext=h,c.controller&&c.controller.control&&!s){const e={slideRealIndex:t,direction:i,setTranslate:r,activeSlideIndex:o,byController:!0};Array.isArray(c.controller.control)?c.controller.control.forEach((t=>{!t.destroyed&&t.params.loop&&t.loopFix({...e,slideTo:t.params.slidesPerView===g.slidesPerView&&n})})):c.controller.control instanceof c.constructor&&c.controller.control.params.loop&&c.controller.control.loopFix({...e,slideTo:c.controller.control.params.slidesPerView===g.slidesPerView&&n})}c.emit("loopFix")},loopDestroy:function(){const e=this,{params:t,slidesEl:n}=e;if(!t.loop||!n||e.virtual&&e.params.virtual.enabled)return;e.recalcSlides();const i=[];e.slides.forEach((e=>{const t=void 0===e.swiperSlideIndex?1*e.getAttribute("data-swiper-slide-index"):e.swiperSlideIndex;i[t]=e})),e.slides.forEach((e=>{e.removeAttribute("data-swiper-slide-index")})),i.forEach((e=>{n.append(e)})),e.recalcSlides(),e.slideTo(e.realIndex,0)}};function uo(e,t,n){const i=Rr(),{params:r}=e,o=r.edgeSwipeDetection,a=r.edgeSwipeThreshold;return!o||!(n<=a||n>=i.innerWidth-a)||"prevent"===o&&(t.preventDefault(),!0)}function ho(e){const t=this,n=Ar();let i=e;i.originalEvent&&(i=i.originalEvent);const r=t.touchEventsData;if("pointerdown"===i.type){if(null!==r.pointerId&&r.pointerId!==i.pointerId)return;r.pointerId=i.pointerId}else"touchstart"===i.type&&1===i.targetTouches.length&&(r.touchId=i.targetTouches[0].identifier);if("touchstart"===i.type)return void uo(t,i,i.targetTouches[0].pageX);const{params:o,touches:a,enabled:s}=t;if(!s)return;if(!o.simulateTouch&&"mouse"===i.pointerType)return;if(t.animating&&o.preventInteractionOnTransition)return;!t.animating&&o.cssMode&&o.loop&&t.loopFix();let l=i.target;if("wrapper"===o.touchEventsTarget&&!function(e,t){const n=Rr();let i=t.contains(e);return!i&&n.HTMLSlotElement&&t instanceof HTMLSlotElement&&(i=[...t.assignedElements()].includes(e),i||(i=function(e,t){const n=[t];for(;n.length>0;){const t=n.shift();if(e===t)return!0;n.push(...t.children,...t.shadowRoot?t.shadowRoot.children:[],...t.assignedElements?t.assignedElements():[])}}(e,t))),i}(l,t.wrapperEl))return;if("which"in i&&3===i.which)return;if("button"in i&&i.button>0)return;if(r.isTouched&&r.isMoved)return;const c=!!o.noSwipingClass&&""!==o.noSwipingClass,d=i.composedPath?i.composedPath():i.path;c&&i.target&&i.target.shadowRoot&&d&&(l=d[0]);const u=o.noSwipingSelector?o.noSwipingSelector:`.${o.noSwipingClass}`,h=!(!i.target||!i.target.shadowRoot);if(o.noSwiping&&(h?function(e,t){return void 0===t&&(t=this),function t(n){if(!n||n===Ar()||n===Rr())return null;n.assignedSlot&&(n=n.assignedSlot);const i=n.closest(e);return i||n.getRootNode?i||t(n.getRootNode().host):null}(t)}(u,l):l.closest(u)))return void(t.allowClick=!0);if(o.swipeHandler&&!l.closest(o.swipeHandler))return;a.currentX=i.pageX,a.currentY=i.pageY;const p=a.currentX,g=a.currentY;if(!uo(t,i,p))return;Object.assign(r,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),a.startX=p,a.startY=g,r.touchStartTime=Ir(),t.allowClick=!0,t.updateSize(),t.swipeDirection=void 0,o.threshold>0&&(r.allowThresholdMove=!1);let f=!0;l.matches(r.focusableElements)&&(f=!1,"SELECT"===l.nodeName&&(r.isTouched=!1)),n.activeElement&&n.activeElement.matches(r.focusableElements)&&n.activeElement!==l&&("mouse"===i.pointerType||"mouse"!==i.pointerType&&!l.matches(r.focusableElements))&&n.activeElement.blur();const m=f&&t.allowTouchMove&&o.touchStartPreventDefault;!o.touchStartForcePreventDefault&&!m||l.isContentEditable||i.preventDefault(),o.freeMode&&o.freeMode.enabled&&t.freeMode&&t.animating&&!o.cssMode&&t.freeMode.onTouchStart(),t.emit("touchStart",i)}function po(e){const t=Ar(),n=this,i=n.touchEventsData,{params:r,touches:o,rtlTranslate:a,enabled:s}=n;if(!s)return;if(!r.simulateTouch&&"mouse"===e.pointerType)return;let l,c=e;if(c.originalEvent&&(c=c.originalEvent),"pointermove"===c.type){if(null!==i.touchId)return;if(c.pointerId!==i.pointerId)return}if("touchmove"===c.type){if(l=[...c.changedTouches].find((e=>e.identifier===i.touchId)),!l||l.identifier!==i.touchId)return}else l=c;if(!i.isTouched)return void(i.startMoving&&i.isScrolling&&n.emit("touchMoveOpposite",c));const d=l.pageX,u=l.pageY;if(c.preventedByNestedSwiper)return o.startX=d,void(o.startY=u);if(!n.allowTouchMove)return c.target.matches(i.focusableElements)||(n.allowClick=!1),void(i.isTouched&&(Object.assign(o,{startX:d,startY:u,currentX:d,currentY:u}),i.touchStartTime=Ir()));if(r.touchReleaseOnEdges&&!r.loop)if(n.isVertical()){if(u<o.startY&&n.translate<=n.maxTranslate()||u>o.startY&&n.translate>=n.minTranslate())return i.isTouched=!1,void(i.isMoved=!1)}else{if(a&&(d>o.startX&&-n.translate<=n.maxTranslate()||d<o.startX&&-n.translate>=n.minTranslate()))return;if(!a&&(d<o.startX&&n.translate<=n.maxTranslate()||d>o.startX&&n.translate>=n.minTranslate()))return}if(t.activeElement&&t.activeElement.matches(i.focusableElements)&&t.activeElement!==c.target&&"mouse"!==c.pointerType&&t.activeElement.blur(),t.activeElement&&c.target===t.activeElement&&c.target.matches(i.focusableElements))return i.isMoved=!0,void(n.allowClick=!1);i.allowTouchCallbacks&&n.emit("touchMove",c),o.previousX=o.currentX,o.previousY=o.currentY,o.currentX=d,o.currentY=u;const h=o.currentX-o.startX,p=o.currentY-o.startY;if(n.params.threshold&&Math.sqrt(h**2+p**2)<n.params.threshold)return;if(void 0===i.isScrolling){let e;n.isHorizontal()&&o.currentY===o.startY||n.isVertical()&&o.currentX===o.startX?i.isScrolling=!1:h*h+p*p>=25&&(e=180*Math.atan2(Math.abs(p),Math.abs(h))/Math.PI,i.isScrolling=n.isHorizontal()?e>r.touchAngle:90-e>r.touchAngle)}if(i.isScrolling&&n.emit("touchMoveOpposite",c),void 0===i.startMoving&&(o.currentX===o.startX&&o.currentY===o.startY||(i.startMoving=!0)),i.isScrolling||"touchmove"===c.type&&i.preventTouchMoveFromPointerMove)return void(i.isTouched=!1);if(!i.startMoving)return;n.allowClick=!1,!r.cssMode&&c.cancelable&&c.preventDefault(),r.touchMoveStopPropagation&&!r.nested&&c.stopPropagation();let g=n.isHorizontal()?h:p,f=n.isHorizontal()?o.currentX-o.previousX:o.currentY-o.previousY;r.oneWayMovement&&(g=Math.abs(g)*(a?1:-1),f=Math.abs(f)*(a?1:-1)),o.diff=g,g*=r.touchRatio,a&&(g=-g,f=-f);const m=n.touchesDirection;n.swipeDirection=g>0?"prev":"next",n.touchesDirection=f>0?"prev":"next";const y=n.params.loop&&!r.cssMode,v="next"===n.touchesDirection&&n.allowSlideNext||"prev"===n.touchesDirection&&n.allowSlidePrev;if(!i.isMoved){if(y&&v&&n.loopFix({direction:n.swipeDirection}),i.startTranslate=n.getTranslate(),n.setTransition(0),n.animating){const e=new window.CustomEvent("transitionend",{bubbles:!0,cancelable:!0,detail:{bySwiperTouchMove:!0}});n.wrapperEl.dispatchEvent(e)}i.allowMomentumBounce=!1,!r.grabCursor||!0!==n.allowSlideNext&&!0!==n.allowSlidePrev||n.setGrabCursor(!0),n.emit("sliderFirstMove",c)}if((new Date).getTime(),!1!==r._loopSwapReset&&i.isMoved&&i.allowThresholdMove&&m!==n.touchesDirection&&y&&v&&Math.abs(g)>=1)return Object.assign(o,{startX:d,startY:u,currentX:d,currentY:u,startTranslate:i.currentTranslate}),i.loopSwapReset=!0,void(i.startTranslate=i.currentTranslate);n.emit("sliderMove",c),i.isMoved=!0,i.currentTranslate=g+i.startTranslate;let b=!0,w=r.resistanceRatio;if(r.touchReleaseOnEdges&&(w=0),g>0?(y&&v&&i.allowThresholdMove&&i.currentTranslate>(r.centeredSlides?n.minTranslate()-n.slidesSizesGrid[n.activeIndex+1]-("auto"!==r.slidesPerView&&n.slides.length-r.slidesPerView>=2?n.slidesSizesGrid[n.activeIndex+1]+n.params.spaceBetween:0)-n.params.spaceBetween:n.minTranslate())&&n.loopFix({direction:"prev",setTranslate:!0,activeSlideIndex:0}),i.currentTranslate>n.minTranslate()&&(b=!1,r.resistance&&(i.currentTranslate=n.minTranslate()-1+(-n.minTranslate()+i.startTranslate+g)**w))):g<0&&(y&&v&&i.allowThresholdMove&&i.currentTranslate<(r.centeredSlides?n.maxTranslate()+n.slidesSizesGrid[n.slidesSizesGrid.length-1]+n.params.spaceBetween+("auto"!==r.slidesPerView&&n.slides.length-r.slidesPerView>=2?n.slidesSizesGrid[n.slidesSizesGrid.length-1]+n.params.spaceBetween:0):n.maxTranslate())&&n.loopFix({direction:"next",setTranslate:!0,activeSlideIndex:n.slides.length-("auto"===r.slidesPerView?n.slidesPerViewDynamic():Math.ceil(parseFloat(r.slidesPerView,10)))}),i.currentTranslate<n.maxTranslate()&&(b=!1,r.resistance&&(i.currentTranslate=n.maxTranslate()+1-(n.maxTranslate()-i.startTranslate-g)**w))),b&&(c.preventedByNestedSwiper=!0),!n.allowSlideNext&&"next"===n.swipeDirection&&i.currentTranslate<i.startTranslate&&(i.currentTranslate=i.startTranslate),!n.allowSlidePrev&&"prev"===n.swipeDirection&&i.currentTranslate>i.startTranslate&&(i.currentTranslate=i.startTranslate),n.allowSlidePrev||n.allowSlideNext||(i.currentTranslate=i.startTranslate),r.threshold>0){if(!(Math.abs(g)>r.threshold||i.allowThresholdMove))return void(i.currentTranslate=i.startTranslate);if(!i.allowThresholdMove)return i.allowThresholdMove=!0,o.startX=o.currentX,o.startY=o.currentY,i.currentTranslate=i.startTranslate,void(o.diff=n.isHorizontal()?o.currentX-o.startX:o.currentY-o.startY)}r.followFinger&&!r.cssMode&&((r.freeMode&&r.freeMode.enabled&&n.freeMode||r.watchSlidesProgress)&&(n.updateActiveIndex(),n.updateSlidesClasses()),r.freeMode&&r.freeMode.enabled&&n.freeMode&&n.freeMode.onTouchMove(),n.updateProgress(i.currentTranslate),n.setTranslate(i.currentTranslate))}function go(e){const t=this,n=t.touchEventsData;let i,r=e;if(r.originalEvent&&(r=r.originalEvent),"touchend"===r.type||"touchcancel"===r.type){if(i=[...r.changedTouches].find((e=>e.identifier===n.touchId)),!i||i.identifier!==n.touchId)return}else{if(null!==n.touchId)return;if(r.pointerId!==n.pointerId)return;i=r}if(["pointercancel","pointerout","pointerleave","contextmenu"].includes(r.type)&&(!["pointercancel","contextmenu"].includes(r.type)||!t.browser.isSafari&&!t.browser.isWebView))return;n.pointerId=null,n.touchId=null;const{params:o,touches:a,rtlTranslate:s,slidesGrid:l,enabled:c}=t;if(!c)return;if(!o.simulateTouch&&"mouse"===r.pointerType)return;if(n.allowTouchCallbacks&&t.emit("touchEnd",r),n.allowTouchCallbacks=!1,!n.isTouched)return n.isMoved&&o.grabCursor&&t.setGrabCursor(!1),n.isMoved=!1,void(n.startMoving=!1);o.grabCursor&&n.isMoved&&n.isTouched&&(!0===t.allowSlideNext||!0===t.allowSlidePrev)&&t.setGrabCursor(!1);const d=Ir(),u=d-n.touchStartTime;if(t.allowClick){const e=r.path||r.composedPath&&r.composedPath();t.updateClickedSlide(e&&e[0]||r.target,e),t.emit("tap click",r),u<300&&d-n.lastClickTime<300&&t.emit("doubleTap doubleClick",r)}if(n.lastClickTime=Ir(),Or((()=>{t.destroyed||(t.allowClick=!0)})),!n.isTouched||!n.isMoved||!t.swipeDirection||0===a.diff&&!n.loopSwapReset||n.currentTranslate===n.startTranslate&&!n.loopSwapReset)return n.isTouched=!1,n.isMoved=!1,void(n.startMoving=!1);let h;if(n.isTouched=!1,n.isMoved=!1,n.startMoving=!1,h=o.followFinger?s?t.translate:-t.translate:-n.currentTranslate,o.cssMode)return;if(o.freeMode&&o.freeMode.enabled)return void t.freeMode.onTouchEnd({currentPos:h});const p=h>=-t.maxTranslate()&&!t.params.loop;let g=0,f=t.slidesSizesGrid[0];for(let e=0;e<l.length;e+=e<o.slidesPerGroupSkip?1:o.slidesPerGroup){const t=e<o.slidesPerGroupSkip-1?1:o.slidesPerGroup;void 0!==l[e+t]?(p||h>=l[e]&&h<l[e+t])&&(g=e,f=l[e+t]-l[e]):(p||h>=l[e])&&(g=e,f=l[l.length-1]-l[l.length-2])}let m=null,y=null;o.rewind&&(t.isBeginning?y=o.virtual&&o.virtual.enabled&&t.virtual?t.virtual.slides.length-1:t.slides.length-1:t.isEnd&&(m=0));const v=(h-l[g])/f,b=g<o.slidesPerGroupSkip-1?1:o.slidesPerGroup;if(u>o.longSwipesMs){if(!o.longSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&(v>=o.longSwipesRatio?t.slideTo(o.rewind&&t.isEnd?m:g+b):t.slideTo(g)),"prev"===t.swipeDirection&&(v>1-o.longSwipesRatio?t.slideTo(g+b):null!==y&&v<0&&Math.abs(v)>o.longSwipesRatio?t.slideTo(y):t.slideTo(g))}else{if(!o.shortSwipes)return void t.slideTo(t.activeIndex);!t.navigation||r.target!==t.navigation.nextEl&&r.target!==t.navigation.prevEl?("next"===t.swipeDirection&&t.slideTo(null!==m?m:g+b),"prev"===t.swipeDirection&&t.slideTo(null!==y?y:g)):r.target===t.navigation.nextEl?t.slideTo(g+b):t.slideTo(g)}}function fo(){const e=this,{params:t,el:n}=e;if(n&&0===n.offsetWidth)return;t.breakpoints&&e.setBreakpoint();const{allowSlideNext:i,allowSlidePrev:r,snapGrid:o}=e,a=e.virtual&&e.params.virtual.enabled;e.allowSlideNext=!0,e.allowSlidePrev=!0,e.updateSize(),e.updateSlides(),e.updateSlidesClasses();const s=a&&t.loop;!("auto"===t.slidesPerView||t.slidesPerView>1)||!e.isEnd||e.isBeginning||e.params.centeredSlides||s?e.params.loop&&!a?e.slideToLoop(e.realIndex,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0):e.slideTo(e.slides.length-1,0,!1,!0),e.autoplay&&e.autoplay.running&&e.autoplay.paused&&(clearTimeout(e.autoplay.resizeTimeout),e.autoplay.resizeTimeout=setTimeout((()=>{e.autoplay&&e.autoplay.running&&e.autoplay.paused&&e.autoplay.resume()}),500)),e.allowSlidePrev=r,e.allowSlideNext=i,e.params.watchOverflow&&o!==e.snapGrid&&e.checkOverflow()}function mo(e){const t=this;t.enabled&&(t.allowClick||(t.params.preventClicks&&e.preventDefault(),t.params.preventClicksPropagation&&t.animating&&(e.stopPropagation(),e.stopImmediatePropagation())))}function yo(){const e=this,{wrapperEl:t,rtlTranslate:n,enabled:i}=e;if(!i)return;let r;e.previousTranslate=e.translate,e.isHorizontal()?e.translate=-t.scrollLeft:e.translate=-t.scrollTop,0===e.translate&&(e.translate=0),e.updateActiveIndex(),e.updateSlidesClasses();const o=e.maxTranslate()-e.minTranslate();r=0===o?0:(e.translate-e.minTranslate())/o,r!==e.progress&&e.updateProgress(n?-e.translate:e.translate),e.emit("setTranslate",e.translate,!1)}function vo(e){const t=this;io(t,e.target),t.params.cssMode||"auto"!==t.params.slidesPerView&&!t.params.autoHeight||t.update()}function bo(){const e=this;e.documentTouchHandlerProceeded||(e.documentTouchHandlerProceeded=!0,e.params.touchReleaseOnEdges&&(e.el.style.touchAction="auto"))}const wo=(e,t)=>{const n=Ar(),{params:i,el:r,wrapperEl:o,device:a}=e,s=!!i.nested,l="on"===t?"addEventListener":"removeEventListener",c=t;r&&"string"!=typeof r&&(n[l]("touchstart",e.onDocumentTouchStart,{passive:!1,capture:s}),r[l]("touchstart",e.onTouchStart,{passive:!1}),r[l]("pointerdown",e.onTouchStart,{passive:!1}),n[l]("touchmove",e.onTouchMove,{passive:!1,capture:s}),n[l]("pointermove",e.onTouchMove,{passive:!1,capture:s}),n[l]("touchend",e.onTouchEnd,{passive:!0}),n[l]("pointerup",e.onTouchEnd,{passive:!0}),n[l]("pointercancel",e.onTouchEnd,{passive:!0}),n[l]("touchcancel",e.onTouchEnd,{passive:!0}),n[l]("pointerout",e.onTouchEnd,{passive:!0}),n[l]("pointerleave",e.onTouchEnd,{passive:!0}),n[l]("contextmenu",e.onTouchEnd,{passive:!0}),(i.preventClicks||i.preventClicksPropagation)&&r[l]("click",e.onClick,!0),i.cssMode&&o[l]("scroll",e.onScroll),i.updateOnWindowResize?e[c](a.ios||a.android?"resize orientationchange observerUpdate":"resize observerUpdate",fo,!0):e[c]("observerUpdate",fo,!0),r[l]("load",e.onLoad,{capture:!0}))},Co=(e,t)=>e.grid&&t.grid&&t.grid.rows>1;var xo={addClasses:function(){const e=this,{classNames:t,params:n,rtl:i,el:r,device:o}=e,a=function(e,t){const n=[];return e.forEach((e=>{"object"==typeof e?Object.keys(e).forEach((i=>{e[i]&&n.push(t+i)})):"string"==typeof e&&n.push(t+e)})),n}(["initialized",n.direction,{"free-mode":e.params.freeMode&&n.freeMode.enabled},{autoheight:n.autoHeight},{rtl:i},{grid:n.grid&&n.grid.rows>1},{"grid-column":n.grid&&n.grid.rows>1&&"column"===n.grid.fill},{android:o.android},{ios:o.ios},{"css-mode":n.cssMode},{centered:n.cssMode&&n.centeredSlides},{"watch-progress":n.watchSlidesProgress}],n.containerModifierClass);t.push(...a),r.classList.add(...t),e.emitContainerClasses()},removeClasses:function(){const{el:e,classNames:t}=this;e&&"string"!=typeof e&&(e.classList.remove(...t),this.emitContainerClasses())}},So={init:!0,direction:"horizontal",oneWayMovement:!1,swiperElementNodeName:"SWIPER-CONTAINER",touchEventsTarget:"wrapper",initialSlide:0,speed:300,cssMode:!1,updateOnWindowResize:!0,resizeObserver:!0,nested:!1,createElements:!1,eventsPrefix:"swiper",enabled:!0,focusableElements:"input, select, option, textarea, button, video, label",width:null,height:null,preventInteractionOnTransition:!1,userAgent:null,url:null,edgeSwipeDetection:!1,edgeSwipeThreshold:20,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,breakpointsBase:"window",spaceBetween:0,slidesPerView:1,slidesPerGroup:1,slidesPerGroupSkip:0,slidesPerGroupAuto:!1,centeredSlides:!1,centeredSlidesBounds:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,centerInsufficientSlides:!1,watchOverflow:!0,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:5,touchMoveStopPropagation:!1,touchStartPreventDefault:!0,touchStartForcePreventDefault:!1,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,loop:!1,loopAddBlankSlides:!0,loopAdditionalSlides:0,loopPreventsSliding:!0,rewind:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,maxBackfaceHiddenSlides:10,containerModifierClass:"swiper-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-blank",slideActiveClass:"swiper-slide-active",slideVisibleClass:"swiper-slide-visible",slideFullyVisibleClass:"swiper-slide-fully-visible",slideNextClass:"swiper-slide-next",slidePrevClass:"swiper-slide-prev",wrapperClass:"swiper-wrapper",lazyPreloaderClass:"swiper-lazy-preloader",lazyPreloadPrevNext:0,runCallbacksOnInit:!0,_emitClasses:!1};function _o(e,t){return function(n){void 0===n&&(n={});const i=Object.keys(n)[0],r=n[i];"object"==typeof r&&null!==r?(!0===e[i]&&(e[i]={enabled:!0}),"navigation"===i&&e[i]&&e[i].enabled&&!e[i].prevEl&&!e[i].nextEl&&(e[i].auto=!0),["pagination","scrollbar"].indexOf(i)>=0&&e[i]&&e[i].enabled&&!e[i].el&&(e[i].auto=!0),i in e&&"enabled"in r?("object"!=typeof e[i]||"enabled"in e[i]||(e[i].enabled=!0),e[i]||(e[i]={enabled:!1}),Nr(t,n)):Nr(t,n)):Nr(t,n)}}const Eo={eventsEmitter:eo,update:ao,translate:{getTranslate:function(e){void 0===e&&(e=this.isHorizontal()?"x":"y");const{params:t,rtlTranslate:n,translate:i,wrapperEl:r}=this;if(t.virtualTranslate)return n?-i:i;if(t.cssMode)return i;let o=function(e,t){void 0===t&&(t="x");const n=Rr();let i,r,o;const a=function(e){const t=Rr();let n;return t.getComputedStyle&&(n=t.getComputedStyle(e,null)),!n&&e.currentStyle&&(n=e.currentStyle),n||(n=e.style),n}(e);return n.WebKitCSSMatrix?(r=a.transform||a.webkitTransform,r.split(",").length>6&&(r=r.split(", ").map((e=>e.replace(",","."))).join(", ")),o=new n.WebKitCSSMatrix("none"===r?"":r)):(o=a.MozTransform||a.OTransform||a.MsTransform||a.msTransform||a.transform||a.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,"),i=o.toString().split(",")),"x"===t&&(r=n.WebKitCSSMatrix?o.m41:16===i.length?parseFloat(i[12]):parseFloat(i[4])),"y"===t&&(r=n.WebKitCSSMatrix?o.m42:16===i.length?parseFloat(i[13]):parseFloat(i[5])),r||0}(r,e);return o+=this.cssOverflowAdjustment(),n&&(o=-o),o||0},setTranslate:function(e,t){const n=this,{rtlTranslate:i,params:r,wrapperEl:o,progress:a}=n;let s,l=0,c=0;n.isHorizontal()?l=i?-e:e:c=e,r.roundLengths&&(l=Math.floor(l),c=Math.floor(c)),n.previousTranslate=n.translate,n.translate=n.isHorizontal()?l:c,r.cssMode?o[n.isHorizontal()?"scrollLeft":"scrollTop"]=n.isHorizontal()?-l:-c:r.virtualTranslate||(n.isHorizontal()?l-=n.cssOverflowAdjustment():c-=n.cssOverflowAdjustment(),o.style.transform=`translate3d(${l}px, ${c}px, 0px)`);const d=n.maxTranslate()-n.minTranslate();s=0===d?0:(e-n.minTranslate())/d,s!==a&&n.updateProgress(e),n.emit("setTranslate",n.translate,t)},minTranslate:function(){return-this.snapGrid[0]},maxTranslate:function(){return-this.snapGrid[this.snapGrid.length-1]},translateTo:function(e,t,n,i,r){void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===n&&(n=!0),void 0===i&&(i=!0);const o=this,{params:a,wrapperEl:s}=o;if(o.animating&&a.preventInteractionOnTransition)return!1;const l=o.minTranslate(),c=o.maxTranslate();let d;if(d=i&&e>l?l:i&&e<c?c:e,o.updateProgress(d),a.cssMode){const e=o.isHorizontal();if(0===t)s[e?"scrollLeft":"scrollTop"]=-d;else{if(!o.support.smoothScroll)return zr({swiper:o,targetPosition:-d,side:e?"left":"top"}),!0;s.scrollTo({[e?"left":"top"]:-d,behavior:"smooth"})}return!0}return 0===t?(o.setTransition(0),o.setTranslate(d),n&&(o.emit("beforeTransitionStart",t,r),o.emit("transitionEnd"))):(o.setTransition(t),o.setTranslate(d),n&&(o.emit("beforeTransitionStart",t,r),o.emit("transitionStart")),o.animating||(o.animating=!0,o.onTranslateToWrapperTransitionEnd||(o.onTranslateToWrapperTransitionEnd=function(e){o&&!o.destroyed&&e.target===this&&(o.wrapperEl.removeEventListener("transitionend",o.onTranslateToWrapperTransitionEnd),o.onTranslateToWrapperTransitionEnd=null,delete o.onTranslateToWrapperTransitionEnd,o.animating=!1,n&&o.emit("transitionEnd"))}),o.wrapperEl.addEventListener("transitionend",o.onTranslateToWrapperTransitionEnd))),!0}},transition:{setTransition:function(e,t){const n=this;n.params.cssMode||(n.wrapperEl.style.transitionDuration=`${e}ms`,n.wrapperEl.style.transitionDelay=0===e?"0ms":""),n.emit("setTransition",e,t)},transitionStart:function(e,t){void 0===e&&(e=!0);const n=this,{params:i}=n;i.cssMode||(i.autoHeight&&n.updateAutoHeight(),so({swiper:n,runCallbacks:e,direction:t,step:"Start"}))},transitionEnd:function(e,t){void 0===e&&(e=!0);const n=this,{params:i}=n;n.animating=!1,i.cssMode||(n.setTransition(0),so({swiper:n,runCallbacks:e,direction:t,step:"End"}))}},slide:lo,loop:co,grabCursor:{setGrabCursor:function(e){const t=this;if(!t.params.simulateTouch||t.params.watchOverflow&&t.isLocked||t.params.cssMode)return;const n="container"===t.params.touchEventsTarget?t.el:t.wrapperEl;t.isElement&&(t.__preventObserver__=!0),n.style.cursor="move",n.style.cursor=e?"grabbing":"grab",t.isElement&&requestAnimationFrame((()=>{t.__preventObserver__=!1}))},unsetGrabCursor:function(){const e=this;e.params.watchOverflow&&e.isLocked||e.params.cssMode||(e.isElement&&(e.__preventObserver__=!0),e["container"===e.params.touchEventsTarget?"el":"wrapperEl"].style.cursor="",e.isElement&&requestAnimationFrame((()=>{e.__preventObserver__=!1})))}},events:{attachEvents:function(){const e=this,{params:t}=e;e.onTouchStart=ho.bind(e),e.onTouchMove=po.bind(e),e.onTouchEnd=go.bind(e),e.onDocumentTouchStart=bo.bind(e),t.cssMode&&(e.onScroll=yo.bind(e)),e.onClick=mo.bind(e),e.onLoad=vo.bind(e),wo(e,"on")},detachEvents:function(){wo(this,"off")}},breakpoints:{setBreakpoint:function(){const e=this,{realIndex:t,initialized:n,params:i,el:r}=e,o=i.breakpoints;if(!o||o&&0===Object.keys(o).length)return;const a=Ar(),s="window"!==i.breakpointsBase&&i.breakpointsBase?"container":i.breakpointsBase,l=["window","container"].includes(i.breakpointsBase)||!i.breakpointsBase?e.el:a.querySelector(i.breakpointsBase),c=e.getBreakpoint(o,s,l);if(!c||e.currentBreakpoint===c)return;const d=(c in o?o[c]:void 0)||e.originalParams,u=Co(e,i),h=Co(e,d),p=e.params.grabCursor,g=d.grabCursor,f=i.enabled;u&&!h?(r.classList.remove(`${i.containerModifierClass}grid`,`${i.containerModifierClass}grid-column`),e.emitContainerClasses()):!u&&h&&(r.classList.add(`${i.containerModifierClass}grid`),(d.grid.fill&&"column"===d.grid.fill||!d.grid.fill&&"column"===i.grid.fill)&&r.classList.add(`${i.containerModifierClass}grid-column`),e.emitContainerClasses()),p&&!g?e.unsetGrabCursor():!p&&g&&e.setGrabCursor(),["navigation","pagination","scrollbar"].forEach((t=>{if(void 0===d[t])return;const n=i[t]&&i[t].enabled,r=d[t]&&d[t].enabled;n&&!r&&e[t].disable(),!n&&r&&e[t].enable()}));const m=d.direction&&d.direction!==i.direction,y=i.loop&&(d.slidesPerView!==i.slidesPerView||m),v=i.loop;m&&n&&e.changeDirection(),Nr(e.params,d);const b=e.params.enabled,w=e.params.loop;Object.assign(e,{allowTouchMove:e.params.allowTouchMove,allowSlideNext:e.params.allowSlideNext,allowSlidePrev:e.params.allowSlidePrev}),f&&!b?e.disable():!f&&b&&e.enable(),e.currentBreakpoint=c,e.emit("_beforeBreakpoint",d),n&&(y?(e.loopDestroy(),e.loopCreate(t),e.updateSlides()):!v&&w?(e.loopCreate(t),e.updateSlides()):v&&!w&&e.loopDestroy()),e.emit("breakpoint",d)},getBreakpoint:function(e,t,n){if(void 0===t&&(t="window"),!e||"container"===t&&!n)return;let i=!1;const r=Rr(),o="window"===t?r.innerHeight:n.clientHeight,a=Object.keys(e).map((e=>{if("string"==typeof e&&0===e.indexOf("@")){const t=parseFloat(e.substr(1));return{value:o*t,point:e}}return{value:e,point:e}}));a.sort(((e,t)=>parseInt(e.value,10)-parseInt(t.value,10)));for(let e=0;e<a.length;e+=1){const{point:o,value:s}=a[e];"window"===t?r.matchMedia(`(min-width: ${s}px)`).matches&&(i=o):s<=n.clientWidth&&(i=o)}return i||"max"}},checkOverflow:{checkOverflow:function(){const e=this,{isLocked:t,params:n}=e,{slidesOffsetBefore:i}=n;if(i){const t=e.slides.length-1,n=e.slidesGrid[t]+e.slidesSizesGrid[t]+2*i;e.isLocked=e.size>n}else e.isLocked=1===e.snapGrid.length;!0===n.allowSlideNext&&(e.allowSlideNext=!e.isLocked),!0===n.allowSlidePrev&&(e.allowSlidePrev=!e.isLocked),t&&t!==e.isLocked&&(e.isEnd=!1),t!==e.isLocked&&e.emit(e.isLocked?"lock":"unlock")}},classes:xo},ko={};class $o{constructor(){let e,t;for(var n=arguments.length,i=new Array(n),r=0;r<n;r++)i[r]=arguments[r];1===i.length&&i[0].constructor&&"Object"===Object.prototype.toString.call(i[0]).slice(8,-1)?t=i[0]:[e,t]=i,t||(t={}),t=Nr({},t),e&&!t.el&&(t.el=e);const o=Ar();if(t.el&&"string"==typeof t.el&&o.querySelectorAll(t.el).length>1){const e=[];return o.querySelectorAll(t.el).forEach((n=>{const i=Nr({},t,{el:n});e.push(new $o(i))})),e}const a=this;a.__swiper__=!0,a.support=Xr(),a.device=Zr({userAgent:t.userAgent}),a.browser=Jr(),a.eventsListeners={},a.eventsAnyListeners=[],a.modules=[...a.__modules__],t.modules&&Array.isArray(t.modules)&&a.modules.push(...t.modules);const s={};a.modules.forEach((e=>{e({params:t,swiper:a,extendParams:_o(t,s),on:a.on.bind(a),once:a.once.bind(a),off:a.off.bind(a),emit:a.emit.bind(a)})}));const l=Nr({},So,s);return a.params=Nr({},l,ko,t),a.originalParams=Nr({},a.params),a.passedParams=Nr({},t),a.params&&a.params.on&&Object.keys(a.params.on).forEach((e=>{a.on(e,a.params.on[e])})),a.params&&a.params.onAny&&a.onAny(a.params.onAny),Object.assign(a,{enabled:a.params.enabled,el:e,classNames:[],slides:[],slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:()=>"horizontal"===a.params.direction,isVertical:()=>"vertical"===a.params.direction,activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,previousTranslate:0,progress:0,velocity:0,animating:!1,cssOverflowAdjustment(){return Math.trunc(this.translate/2**23)*2**23},allowSlideNext:a.params.allowSlideNext,allowSlidePrev:a.params.allowSlidePrev,touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,focusableElements:a.params.focusableElements,lastClickTime:0,clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,startMoving:void 0,pointerId:null,touchId:null},allowClick:!0,allowTouchMove:a.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),a.emit("_swiper"),a.params.init&&a.init(),a}getDirectionLabel(e){return this.isHorizontal()?e:{width:"height","margin-top":"margin-left","margin-bottom ":"margin-right","margin-left":"margin-top","margin-right":"margin-bottom","padding-left":"padding-top","padding-right":"padding-bottom",marginRight:"marginBottom"}[e]}getSlideIndex(e){const{slidesEl:t,params:n}=this,i=Gr(Br(t,`.${n.slideClass}, swiper-slide`)[0]);return Gr(e)-i}getSlideIndexByData(e){return this.getSlideIndex(this.slides.find((t=>1*t.getAttribute("data-swiper-slide-index")===e)))}recalcSlides(){const{slidesEl:e,params:t}=this;this.slides=Br(e,`.${t.slideClass}, swiper-slide`)}enable(){const e=this;e.enabled||(e.enabled=!0,e.params.grabCursor&&e.setGrabCursor(),e.emit("enable"))}disable(){const e=this;e.enabled&&(e.enabled=!1,e.params.grabCursor&&e.unsetGrabCursor(),e.emit("disable"))}setProgress(e,t){const n=this;e=Math.min(Math.max(e,0),1);const i=n.minTranslate(),r=(n.maxTranslate()-i)*e+i;n.translateTo(r,void 0===t?0:t),n.updateActiveIndex(),n.updateSlidesClasses()}emitContainerClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=e.el.className.split(" ").filter((t=>0===t.indexOf("swiper")||0===t.indexOf(e.params.containerModifierClass)));e.emit("_containerClasses",t.join(" "))}getSlideClasses(e){const t=this;return t.destroyed?"":e.className.split(" ").filter((e=>0===e.indexOf("swiper-slide")||0===e.indexOf(t.params.slideClass))).join(" ")}emitSlidesClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=[];e.slides.forEach((n=>{const i=e.getSlideClasses(n);t.push({slideEl:n,classNames:i}),e.emit("_slideClass",n,i)})),e.emit("_slideClasses",t)}slidesPerViewDynamic(e,t){void 0===e&&(e="current"),void 0===t&&(t=!1);const{params:n,slides:i,slidesGrid:r,slidesSizesGrid:o,size:a,activeIndex:s}=this;let l=1;if("number"==typeof n.slidesPerView)return n.slidesPerView;if(n.centeredSlides){let e,t=i[s]?Math.ceil(i[s].swiperSlideSize):0;for(let n=s+1;n<i.length;n+=1)i[n]&&!e&&(t+=Math.ceil(i[n].swiperSlideSize),l+=1,t>a&&(e=!0));for(let n=s-1;n>=0;n-=1)i[n]&&!e&&(t+=i[n].swiperSlideSize,l+=1,t>a&&(e=!0))}else if("current"===e)for(let e=s+1;e<i.length;e+=1)(t?r[e]+o[e]-r[s]<a:r[e]-r[s]<a)&&(l+=1);else for(let e=s-1;e>=0;e-=1)r[s]-r[e]<a&&(l+=1);return l}update(){const e=this;if(!e||e.destroyed)return;const{snapGrid:t,params:n}=e;function i(){const t=e.rtlTranslate?-1*e.translate:e.translate,n=Math.min(Math.max(t,e.maxTranslate()),e.minTranslate());e.setTranslate(n),e.updateActiveIndex(),e.updateSlidesClasses()}let r;if(n.breakpoints&&e.setBreakpoint(),[...e.el.querySelectorAll('[loading="lazy"]')].forEach((t=>{t.complete&&io(e,t)})),e.updateSize(),e.updateSlides(),e.updateProgress(),e.updateSlidesClasses(),n.freeMode&&n.freeMode.enabled&&!n.cssMode)i(),n.autoHeight&&e.updateAutoHeight();else{if(("auto"===n.slidesPerView||n.slidesPerView>1)&&e.isEnd&&!n.centeredSlides){const t=e.virtual&&n.virtual.enabled?e.virtual.slides:e.slides;r=e.slideTo(t.length-1,0,!1,!0)}else r=e.slideTo(e.activeIndex,0,!1,!0);r||i()}n.watchOverflow&&t!==e.snapGrid&&e.checkOverflow(),e.emit("update")}changeDirection(e,t){void 0===t&&(t=!0);const n=this,i=n.params.direction;return e||(e="horizontal"===i?"vertical":"horizontal"),e===i||"horizontal"!==e&&"vertical"!==e||(n.el.classList.remove(`${n.params.containerModifierClass}${i}`),n.el.classList.add(`${n.params.containerModifierClass}${e}`),n.emitContainerClasses(),n.params.direction=e,n.slides.forEach((t=>{"vertical"===e?t.style.width="":t.style.height=""})),n.emit("changeDirection"),t&&n.update()),n}changeLanguageDirection(e){const t=this;t.rtl&&"rtl"===e||!t.rtl&&"ltr"===e||(t.rtl="rtl"===e,t.rtlTranslate="horizontal"===t.params.direction&&t.rtl,t.rtl?(t.el.classList.add(`${t.params.containerModifierClass}rtl`),t.el.dir="rtl"):(t.el.classList.remove(`${t.params.containerModifierClass}rtl`),t.el.dir="ltr"),t.update())}mount(e){const t=this;if(t.mounted)return!0;let n=e||t.params.el;if("string"==typeof n&&(n=document.querySelector(n)),!n)return!1;n.swiper=t,n.parentNode&&n.parentNode.host&&n.parentNode.host.nodeName===t.params.swiperElementNodeName.toUpperCase()&&(t.isElement=!0);const i=()=>`.${(t.params.wrapperClass||"").trim().split(" ").join(".")}`;let r=n&&n.shadowRoot&&n.shadowRoot.querySelector?n.shadowRoot.querySelector(i()):Br(n,i())[0];return!r&&t.params.createElements&&(r=Wr("div",t.params.wrapperClass),n.append(r),Br(n,`.${t.params.slideClass}`).forEach((e=>{r.append(e)}))),Object.assign(t,{el:n,wrapperEl:r,slidesEl:t.isElement&&!n.parentNode.host.slideSlots?n.parentNode.host:r,hostEl:t.isElement?n.parentNode.host:n,mounted:!0,rtl:"rtl"===n.dir.toLowerCase()||"rtl"===jr(n,"direction"),rtlTranslate:"horizontal"===t.params.direction&&("rtl"===n.dir.toLowerCase()||"rtl"===jr(n,"direction")),wrongRTL:"-webkit-box"===jr(r,"display")}),!0}init(e){const t=this;if(t.initialized)return t;if(!1===t.mount(e))return t;t.emit("beforeInit"),t.params.breakpoints&&t.setBreakpoint(),t.addClasses(),t.updateSize(),t.updateSlides(),t.params.watchOverflow&&t.checkOverflow(),t.params.grabCursor&&t.enabled&&t.setGrabCursor(),t.params.loop&&t.virtual&&t.params.virtual.enabled?t.slideTo(t.params.initialSlide+t.virtual.slidesBefore,0,t.params.runCallbacksOnInit,!1,!0):t.slideTo(t.params.initialSlide,0,t.params.runCallbacksOnInit,!1,!0),t.params.loop&&t.loopCreate(void 0,!0),t.attachEvents();const n=[...t.el.querySelectorAll('[loading="lazy"]')];return t.isElement&&n.push(...t.hostEl.querySelectorAll('[loading="lazy"]')),n.forEach((e=>{e.complete?io(t,e):e.addEventListener("load",(e=>{io(t,e.target)}))})),oo(t),t.initialized=!0,oo(t),t.emit("init"),t.emit("afterInit"),t}destroy(e,t){void 0===e&&(e=!0),void 0===t&&(t=!0);const n=this,{params:i,el:r,wrapperEl:o,slides:a}=n;return void 0===n.params||n.destroyed||(n.emit("beforeDestroy"),n.initialized=!1,n.detachEvents(),i.loop&&n.loopDestroy(),t&&(n.removeClasses(),r&&"string"!=typeof r&&r.removeAttribute("style"),o&&o.removeAttribute("style"),a&&a.length&&a.forEach((e=>{e.classList.remove(i.slideVisibleClass,i.slideFullyVisibleClass,i.slideActiveClass,i.slideNextClass,i.slidePrevClass),e.removeAttribute("style"),e.removeAttribute("data-swiper-slide-index")}))),n.emit("destroy"),Object.keys(n.eventsListeners).forEach((e=>{n.off(e)})),!1!==e&&(n.el&&"string"!=typeof n.el&&(n.el.swiper=null),function(e){const t=e;Object.keys(t).forEach((e=>{try{t[e]=null}catch(e){}try{delete t[e]}catch(e){}}))}(n)),n.destroyed=!0),null}static extendDefaults(e){Nr(ko,e)}static get extendedDefaults(){return ko}static get defaults(){return So}static installModule(e){$o.prototype.__modules__||($o.prototype.__modules__=[]);const t=$o.prototype.__modules__;"function"==typeof e&&t.indexOf(e)<0&&t.push(e)}static use(e){return Array.isArray(e)?(e.forEach((e=>$o.installModule(e))),$o):($o.installModule(e),$o)}}Object.keys(Eo).forEach((e=>{Object.keys(Eo[e]).forEach((t=>{$o.prototype[t]=Eo[e][t]}))})),$o.use([function(e){let{swiper:t,on:n,emit:i}=e;const r=Rr();let o=null,a=null;const s=()=>{t&&!t.destroyed&&t.initialized&&(i("beforeResize"),i("resize"))},l=()=>{t&&!t.destroyed&&t.initialized&&i("orientationchange")};n("init",(()=>{t.params.resizeObserver&&void 0!==r.ResizeObserver?t&&!t.destroyed&&t.initialized&&(o=new ResizeObserver((e=>{a=r.requestAnimationFrame((()=>{const{width:n,height:i}=t;let r=n,o=i;e.forEach((e=>{let{contentBoxSize:n,contentRect:i,target:a}=e;a&&a!==t.el||(r=i?i.width:(n[0]||n).inlineSize,o=i?i.height:(n[0]||n).blockSize)})),r===n&&o===i||s()}))})),o.observe(t.el)):(r.addEventListener("resize",s),r.addEventListener("orientationchange",l))})),n("destroy",(()=>{a&&r.cancelAnimationFrame(a),o&&o.unobserve&&t.el&&(o.unobserve(t.el),o=null),r.removeEventListener("resize",s),r.removeEventListener("orientationchange",l)}))},function(e){let{swiper:t,extendParams:n,on:i,emit:r}=e;const o=[],a=Rr(),s=function(e,n){void 0===n&&(n={});const i=new(a.MutationObserver||a.WebkitMutationObserver)((e=>{if(t.__preventObserver__)return;if(1===e.length)return void r("observerUpdate",e[0]);const n=function(){r("observerUpdate",e[0])};a.requestAnimationFrame?a.requestAnimationFrame(n):a.setTimeout(n,0)}));i.observe(e,{attributes:void 0===n.attributes||n.attributes,childList:t.isElement||(void 0===n.childList||n).childList,characterData:void 0===n.characterData||n.characterData}),o.push(i)};n({observer:!1,observeParents:!1,observeSlideChildren:!1}),i("init",(()=>{if(t.params.observer){if(t.params.observeParents){const e=Vr(t.hostEl);for(let t=0;t<e.length;t+=1)s(e[t])}s(t.hostEl,{childList:t.params.observeSlideChildren}),s(t.wrapperEl,{attributes:!1})}})),i("destroy",(()=>{o.forEach((e=>{e.disconnect()})),o.splice(0,o.length)}))}]);const Mo=["eventsPrefix","injectStyles","injectStylesUrls","modules","init","_direction","oneWayMovement","swiperElementNodeName","touchEventsTarget","initialSlide","_speed","cssMode","updateOnWindowResize","resizeObserver","nested","focusableElements","_enabled","_width","_height","preventInteractionOnTransition","userAgent","url","_edgeSwipeDetection","_edgeSwipeThreshold","_freeMode","_autoHeight","setWrapperSize","virtualTranslate","_effect","breakpoints","breakpointsBase","_spaceBetween","_slidesPerView","maxBackfaceHiddenSlides","_grid","_slidesPerGroup","_slidesPerGroupSkip","_slidesPerGroupAuto","_centeredSlides","_centeredSlidesBounds","_slidesOffsetBefore","_slidesOffsetAfter","normalizeSlideIndex","_centerInsufficientSlides","_watchOverflow","roundLengths","touchRatio","touchAngle","simulateTouch","_shortSwipes","_longSwipes","longSwipesRatio","longSwipesMs","_followFinger","allowTouchMove","_threshold","touchMoveStopPropagation","touchStartPreventDefault","touchStartForcePreventDefault","touchReleaseOnEdges","uniqueNavElements","_resistance","_resistanceRatio","_watchSlidesProgress","_grabCursor","preventClicks","preventClicksPropagation","_slideToClickedSlide","_loop","loopAdditionalSlides","loopAddBlankSlides","loopPreventsSliding","_rewind","_allowSlidePrev","_allowSlideNext","_swipeHandler","_noSwiping","noSwipingClass","noSwipingSelector","passiveListeners","containerModifierClass","slideClass","slideActiveClass","slideVisibleClass","slideFullyVisibleClass","slideNextClass","slidePrevClass","slideBlankClass","wrapperClass","lazyPreloaderClass","lazyPreloadPrevNext","runCallbacksOnInit","observer","observeParents","observeSlideChildren","a11y","_autoplay","_controller","coverflowEffect","cubeEffect","fadeEffect","flipEffect","creativeEffect","cardsEffect","hashNavigation","history","keyboard","mousewheel","_navigation","_pagination","parallax","_scrollbar","_thumbs","virtual","zoom","control"];function To(e){return"object"==typeof e&&null!==e&&e.constructor&&"Object"===Object.prototype.toString.call(e).slice(8,-1)&&!e.__swiper__}function Ao(e,t){const n=["__proto__","constructor","prototype"];Object.keys(t).filter((e=>n.indexOf(e)<0)).forEach((n=>{void 0===e[n]?e[n]=t[n]:To(t[n])&&To(e[n])&&Object.keys(t[n]).length>0?t[n].__swiper__?e[n]=t[n]:Ao(e[n],t[n]):e[n]=t[n]}))}function Lo(e){return void 0===e&&(e={}),e.navigation&&void 0===e.navigation.nextEl&&void 0===e.navigation.prevEl}function Ro(e){return void 0===e&&(e={}),e.pagination&&void 0===e.pagination.el}function Oo(e){return void 0===e&&(e={}),e.scrollbar&&void 0===e.scrollbar.el}function Io(e){void 0===e&&(e="");const t=e.split(" ").map((e=>e.trim())).filter((e=>!!e)),n=[];return t.forEach((e=>{n.indexOf(e)<0&&n.push(e)})),n.join(" ")}function Po(e){return void 0===e&&(e=""),e?e.includes("swiper-wrapper")?e:`swiper-wrapper ${e}`:"swiper-wrapper"}function No(){return No=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},No.apply(this,arguments)}function Do(e){return e.type&&e.type.displayName&&e.type.displayName.includes("SwiperSlide")}function zo(e){const t=[];return i.Children.toArray(e).forEach((e=>{Do(e)?t.push(e):e.props&&e.props.children&&zo(e.props.children).forEach((e=>t.push(e)))})),t}function Fo(e){const t=[],n={"container-start":[],"container-end":[],"wrapper-start":[],"wrapper-end":[]};return i.Children.toArray(e).forEach((e=>{if(Do(e))t.push(e);else if(e.props&&e.props.slot&&n[e.props.slot])n[e.props.slot].push(e);else if(e.props&&e.props.children){const i=zo(e.props.children);i.length>0?i.forEach((e=>t.push(e))):n["container-end"].push(e)}else n["container-end"].push(e)})),{slides:t,slots:n}}function Bo(e,t){return"undefined"==typeof window?(0,i.useEffect)(e,t):(0,i.useLayoutEffect)(e,t)}const Ho=(0,i.createContext)(null),Wo=(0,i.createContext)(null),jo=(0,i.forwardRef)((function(e,t){let{className:n,tag:r="div",wrapperTag:o="div",children:a,onSwiper:s,...l}=void 0===e?{}:e,c=!1;const[d,u]=(0,i.useState)("swiper"),[h,p]=(0,i.useState)(null),[g,f]=(0,i.useState)(!1),m=(0,i.useRef)(!1),y=(0,i.useRef)(null),v=(0,i.useRef)(null),b=(0,i.useRef)(null),w=(0,i.useRef)(null),C=(0,i.useRef)(null),x=(0,i.useRef)(null),S=(0,i.useRef)(null),_=(0,i.useRef)(null),{params:E,passedParams:k,rest:$,events:M}=function(e,t){void 0===e&&(e={}),void 0===t&&(t=!0);const n={on:{}},i={},r={};Ao(n,So),n._emitClasses=!0,n.init=!1;const o={},a=Mo.map((e=>e.replace(/_/,""))),s=Object.assign({},e);return Object.keys(s).forEach((s=>{void 0!==e[s]&&(a.indexOf(s)>=0?To(e[s])?(n[s]={},r[s]={},Ao(n[s],e[s]),Ao(r[s],e[s])):(n[s]=e[s],r[s]=e[s]):0===s.search(/on[A-Z]/)&&"function"==typeof e[s]?t?i[`${s[2].toLowerCase()}${s.substr(3)}`]=e[s]:n.on[`${s[2].toLowerCase()}${s.substr(3)}`]=e[s]:o[s]=e[s])})),["navigation","pagination","scrollbar"].forEach((e=>{!0===n[e]&&(n[e]={}),!1===n[e]&&delete n[e]})),{params:n,passedParams:r,rest:o,events:i}}(l),{slides:T,slots:A}=Fo(a),L=()=>{f(!g)};Object.assign(E.on,{_containerClasses(e,t){u(t)}});const R=()=>{Object.assign(E.on,M),c=!0;const e={...E};if(delete e.wrapperClass,v.current=new $o(e),v.current.virtual&&v.current.params.virtual.enabled){v.current.virtual.slides=T;const e={cache:!1,slides:T,renderExternal:p,renderExternalUpdate:!1};Ao(v.current.params.virtual,e),Ao(v.current.originalParams.virtual,e)}};return y.current||R(),v.current&&v.current.on("_beforeBreakpoint",L),(0,i.useEffect)((()=>()=>{v.current&&v.current.off("_beforeBreakpoint",L)})),(0,i.useEffect)((()=>{!m.current&&v.current&&(v.current.emitSlidesClasses(),m.current=!0)})),Bo((()=>{if(t&&(t.current=y.current),y.current)return v.current.destroyed&&R(),function(e,t){let{el:n,nextEl:i,prevEl:r,paginationEl:o,scrollbarEl:a,swiper:s}=e;Lo(t)&&i&&r&&(s.params.navigation.nextEl=i,s.originalParams.navigation.nextEl=i,s.params.navigation.prevEl=r,s.originalParams.navigation.prevEl=r),Ro(t)&&o&&(s.params.pagination.el=o,s.originalParams.pagination.el=o),Oo(t)&&a&&(s.params.scrollbar.el=a,s.originalParams.scrollbar.el=a),s.init(n)}({el:y.current,nextEl:C.current,prevEl:x.current,paginationEl:S.current,scrollbarEl:_.current,swiper:v.current},E),s&&!v.current.destroyed&&s(v.current),()=>{v.current&&!v.current.destroyed&&v.current.destroy(!0,!1)}}),[]),Bo((()=>{!c&&M&&v.current&&Object.keys(M).forEach((e=>{v.current.on(e,M[e])}));const e=function(e,t,n,i,r){const o=[];if(!t)return o;const a=e=>{o.indexOf(e)<0&&o.push(e)};if(n&&i){const e=i.map(r),t=n.map(r);e.join("")!==t.join("")&&a("children"),i.length!==n.length&&a("children")}return Mo.filter((e=>"_"===e[0])).map((e=>e.replace(/_/,""))).forEach((n=>{if(n in e&&n in t)if(To(e[n])&&To(t[n])){const i=Object.keys(e[n]),r=Object.keys(t[n]);i.length!==r.length?a(n):(i.forEach((i=>{e[n][i]!==t[n][i]&&a(n)})),r.forEach((i=>{e[n][i]!==t[n][i]&&a(n)})))}else e[n]!==t[n]&&a(n)})),o}(k,b.current,T,w.current,(e=>e.key));return b.current=k,w.current=T,e.length&&v.current&&!v.current.destroyed&&function(e){let{swiper:t,slides:n,passedParams:i,changedParams:r,nextEl:o,prevEl:a,scrollbarEl:s,paginationEl:l}=e;const c=r.filter((e=>"children"!==e&&"direction"!==e&&"wrapperClass"!==e)),{params:d,pagination:u,navigation:h,scrollbar:p,virtual:g,thumbs:f}=t;let m,y,v,b,w,C,x,S;r.includes("thumbs")&&i.thumbs&&i.thumbs.swiper&&!i.thumbs.swiper.destroyed&&d.thumbs&&(!d.thumbs.swiper||d.thumbs.swiper.destroyed)&&(m=!0),r.includes("controller")&&i.controller&&i.controller.control&&d.controller&&!d.controller.control&&(y=!0),r.includes("pagination")&&i.pagination&&(i.pagination.el||l)&&(d.pagination||!1===d.pagination)&&u&&!u.el&&(v=!0),r.includes("scrollbar")&&i.scrollbar&&(i.scrollbar.el||s)&&(d.scrollbar||!1===d.scrollbar)&&p&&!p.el&&(b=!0),r.includes("navigation")&&i.navigation&&(i.navigation.prevEl||a)&&(i.navigation.nextEl||o)&&(d.navigation||!1===d.navigation)&&h&&!h.prevEl&&!h.nextEl&&(w=!0);const _=e=>{t[e]&&(t[e].destroy(),"navigation"===e?(t.isElement&&(t[e].prevEl.remove(),t[e].nextEl.remove()),d[e].prevEl=void 0,d[e].nextEl=void 0,t[e].prevEl=void 0,t[e].nextEl=void 0):(t.isElement&&t[e].el.remove(),d[e].el=void 0,t[e].el=void 0))};r.includes("loop")&&t.isElement&&(d.loop&&!i.loop?C=!0:!d.loop&&i.loop?x=!0:S=!0),c.forEach((e=>{if(To(d[e])&&To(i[e]))Object.assign(d[e],i[e]),"navigation"!==e&&"pagination"!==e&&"scrollbar"!==e||!("enabled"in i[e])||i[e].enabled||_(e);else{const t=i[e];!0!==t&&!1!==t||"navigation"!==e&&"pagination"!==e&&"scrollbar"!==e?d[e]=i[e]:!1===t&&_(e)}})),c.includes("controller")&&!y&&t.controller&&t.controller.control&&d.controller&&d.controller.control&&(t.controller.control=d.controller.control),r.includes("children")&&n&&g&&d.virtual.enabled?(g.slides=n,g.update(!0)):r.includes("virtual")&&g&&d.virtual.enabled&&(n&&(g.slides=n),g.update(!0)),r.includes("children")&&n&&d.loop&&(S=!0),m&&f.init()&&f.update(!0),y&&(t.controller.control=d.controller.control),v&&(!t.isElement||l&&"string"!=typeof l||(l=document.createElement("div"),l.classList.add("swiper-pagination"),l.part.add("pagination"),t.el.appendChild(l)),l&&(d.pagination.el=l),u.init(),u.render(),u.update()),b&&(!t.isElement||s&&"string"!=typeof s||(s=document.createElement("div"),s.classList.add("swiper-scrollbar"),s.part.add("scrollbar"),t.el.appendChild(s)),s&&(d.scrollbar.el=s),p.init(),p.updateSize(),p.setTranslate()),w&&(t.isElement&&(o&&"string"!=typeof o||(o=document.createElement("div"),o.classList.add("swiper-button-next"),o.innerHTML=t.hostEl.constructor.nextButtonSvg,o.part.add("button-next"),t.el.appendChild(o)),a&&"string"!=typeof a||(a=document.createElement("div"),a.classList.add("swiper-button-prev"),a.innerHTML=t.hostEl.constructor.prevButtonSvg,a.part.add("button-prev"),t.el.appendChild(a))),o&&(d.navigation.nextEl=o),a&&(d.navigation.prevEl=a),h.init(),h.update()),r.includes("allowSlideNext")&&(t.allowSlideNext=i.allowSlideNext),r.includes("allowSlidePrev")&&(t.allowSlidePrev=i.allowSlidePrev),r.includes("direction")&&t.changeDirection(i.direction,!1),(C||S)&&t.loopDestroy(),(x||S)&&t.loopCreate(),t.update()}({swiper:v.current,slides:T,passedParams:k,changedParams:e,nextEl:C.current,prevEl:x.current,scrollbarEl:_.current,paginationEl:S.current}),()=>{M&&v.current&&Object.keys(M).forEach((e=>{v.current.off(e,M[e])}))}})),Bo((()=>{var e;!(e=v.current)||e.destroyed||!e.params.virtual||e.params.virtual&&!e.params.virtual.enabled||(e.updateSlides(),e.updateProgress(),e.updateSlidesClasses(),e.parallax&&e.params.parallax&&e.params.parallax.enabled&&e.parallax.setTranslate())}),[h]),i.createElement(r,No({ref:y,className:Io(`${d}${n?` ${n}`:""}`)},$),i.createElement(Wo.Provider,{value:v.current},A["container-start"],i.createElement(o,{className:Po(E.wrapperClass)},A["wrapper-start"],E.virtual?function(e,t,n){if(!n)return null;const r=e=>{let n=e;return e<0?n=t.length+e:n>=t.length&&(n-=t.length),n},o=e.isHorizontal()?{[e.rtlTranslate?"right":"left"]:`${n.offset}px`}:{top:`${n.offset}px`},{from:a,to:s}=n,l=e.params.loop?-t.length:0,c=e.params.loop?2*t.length:t.length,d=[];for(let e=l;e<c;e+=1)e>=a&&e<=s&&d.push(t[r(e)]);return d.map(((t,n)=>i.cloneElement(t,{swiper:e,style:o,key:t.props.virtualIndex||t.key||`slide-${n}`})))}(v.current,T,h):T.map(((e,t)=>i.cloneElement(e,{swiper:v.current,swiperSlideIndex:t}))),A["wrapper-end"]),Lo(E)&&i.createElement(i.Fragment,null,i.createElement("div",{ref:x,className:"swiper-button-prev"}),i.createElement("div",{ref:C,className:"swiper-button-next"})),Oo(E)&&i.createElement("div",{ref:_,className:"swiper-scrollbar"}),Ro(E)&&i.createElement("div",{ref:S,className:"swiper-pagination"}),A["container-end"]))}));jo.displayName="Swiper";const Go=(0,i.forwardRef)((function(e,t){let{tag:n="div",children:r,className:o="",swiper:a,zoom:s,lazy:l,virtualIndex:c,swiperSlideIndex:d,...u}=void 0===e?{}:e;const h=(0,i.useRef)(null),[p,g]=(0,i.useState)("swiper-slide"),[f,m]=(0,i.useState)(!1);function y(e,t,n){t===h.current&&g(n)}Bo((()=>{if(void 0!==d&&(h.current.swiperSlideIndex=d),t&&(t.current=h.current),h.current&&a){if(!a.destroyed)return a.on("_slideClass",y),()=>{a&&a.off("_slideClass",y)};"swiper-slide"!==p&&g("swiper-slide")}})),Bo((()=>{a&&h.current&&!a.destroyed&&g(a.getSlideClasses(h.current))}),[a]);const v={isActive:p.indexOf("swiper-slide-active")>=0,isVisible:p.indexOf("swiper-slide-visible")>=0,isPrev:p.indexOf("swiper-slide-prev")>=0,isNext:p.indexOf("swiper-slide-next")>=0},b=()=>"function"==typeof r?r(v):r;return i.createElement(n,No({ref:h,className:Io(`${p}${o?` ${o}`:""}`),"data-swiper-slide-index":c,onLoad:()=>{m(!0)}},u),s&&i.createElement(Ho.Provider,{value:v},i.createElement("div",{className:"swiper-zoom-container","data-swiper-zoom":"number"==typeof s?s:void 0},b(),l&&!f&&i.createElement("div",{className:"swiper-lazy-preloader"}))),!s&&i.createElement(Ho.Provider,{value:v},b(),l&&!f&&i.createElement("div",{className:"swiper-lazy-preloader"})))}));function Vo(e,t,n,i){return e.params.createElements&&Object.keys(i).forEach((r=>{if(!n[r]&&!0===n.auto){let o=Br(e.el,`.${i[r]}`)[0];o||(o=Wr("div",i[r]),o.className=i[r],e.el.append(o)),n[r]=o,t[r]=o}})),n}function Uo(e){let{swiper:t,extendParams:n,on:i,emit:r}=e;function o(e){let n;return e&&"string"==typeof e&&t.isElement&&(n=t.el.querySelector(e)||t.hostEl.querySelector(e),n)?n:(e&&("string"==typeof e&&(n=[...document.querySelectorAll(e)]),t.params.uniqueNavElements&&"string"==typeof e&&n&&n.length>1&&1===t.el.querySelectorAll(e).length?n=t.el.querySelector(e):n&&1===n.length&&(n=n[0])),e&&!n?e:n)}function a(e,n){const i=t.params.navigation;(e=Kr(e)).forEach((e=>{e&&(e.classList[n?"add":"remove"](...i.disabledClass.split(" ")),"BUTTON"===e.tagName&&(e.disabled=n),t.params.watchOverflow&&t.enabled&&e.classList[t.isLocked?"add":"remove"](i.lockClass))}))}function s(){const{nextEl:e,prevEl:n}=t.navigation;if(t.params.loop)return a(n,!1),void a(e,!1);a(n,t.isBeginning&&!t.params.rewind),a(e,t.isEnd&&!t.params.rewind)}function l(e){e.preventDefault(),(!t.isBeginning||t.params.loop||t.params.rewind)&&(t.slidePrev(),r("navigationPrev"))}function c(e){e.preventDefault(),(!t.isEnd||t.params.loop||t.params.rewind)&&(t.slideNext(),r("navigationNext"))}function d(){const e=t.params.navigation;if(t.params.navigation=Vo(t,t.originalParams.navigation,t.params.navigation,{nextEl:"swiper-button-next",prevEl:"swiper-button-prev"}),!e.nextEl&&!e.prevEl)return;let n=o(e.nextEl),i=o(e.prevEl);Object.assign(t.navigation,{nextEl:n,prevEl:i}),n=Kr(n),i=Kr(i);const r=(n,i)=>{n&&n.addEventListener("click","next"===i?c:l),!t.enabled&&n&&n.classList.add(...e.lockClass.split(" "))};n.forEach((e=>r(e,"next"))),i.forEach((e=>r(e,"prev")))}function u(){let{nextEl:e,prevEl:n}=t.navigation;e=Kr(e),n=Kr(n);const i=(e,n)=>{e.removeEventListener("click","next"===n?c:l),e.classList.remove(...t.params.navigation.disabledClass.split(" "))};e.forEach((e=>i(e,"next"))),n.forEach((e=>i(e,"prev")))}n({navigation:{nextEl:null,prevEl:null,hideOnClick:!1,disabledClass:"swiper-button-disabled",hiddenClass:"swiper-button-hidden",lockClass:"swiper-button-lock",navigationDisabledClass:"swiper-navigation-disabled"}}),t.navigation={nextEl:null,prevEl:null},i("init",(()=>{!1===t.params.navigation.enabled?h():(d(),s())})),i("toEdge fromEdge lock unlock",(()=>{s()})),i("destroy",(()=>{u()})),i("enable disable",(()=>{let{nextEl:e,prevEl:n}=t.navigation;e=Kr(e),n=Kr(n),t.enabled?s():[...e,...n].filter((e=>!!e)).forEach((e=>e.classList.add(t.params.navigation.lockClass)))})),i("click",((e,n)=>{let{nextEl:i,prevEl:o}=t.navigation;i=Kr(i),o=Kr(o);const a=n.target;let s=o.includes(a)||i.includes(a);if(t.isElement&&!s){const e=n.path||n.composedPath&&n.composedPath();e&&(s=e.find((e=>i.includes(e)||o.includes(e))))}if(t.params.navigation.hideOnClick&&!s){if(t.pagination&&t.params.pagination&&t.params.pagination.clickable&&(t.pagination.el===a||t.pagination.el.contains(a)))return;let e;i.length?e=i[0].classList.contains(t.params.navigation.hiddenClass):o.length&&(e=o[0].classList.contains(t.params.navigation.hiddenClass)),r(!0===e?"navigationShow":"navigationHide"),[...i,...o].filter((e=>!!e)).forEach((e=>e.classList.toggle(t.params.navigation.hiddenClass)))}}));const h=()=>{t.el.classList.add(...t.params.navigation.navigationDisabledClass.split(" ")),u()};Object.assign(t.navigation,{enable:()=>{t.el.classList.remove(...t.params.navigation.navigationDisabledClass.split(" ")),d(),s()},disable:h,update:s,init:d,destroy:u})}function Ko(e){return void 0===e&&(e=""),`.${e.trim().replace(/([\.:!+\/])/g,"\\$1").replace(/ /g,".")}`}function Yo(e){let{swiper:t,extendParams:n,on:i,emit:r}=e;const o="swiper-pagination";let a;n({pagination:{el:null,bulletElement:"span",clickable:!1,hideOnClick:!1,renderBullet:null,renderProgressbar:null,renderFraction:null,renderCustom:null,progressbarOpposite:!1,type:"bullets",dynamicBullets:!1,dynamicMainBullets:1,formatFractionCurrent:e=>e,formatFractionTotal:e=>e,bulletClass:`${o}-bullet`,bulletActiveClass:`${o}-bullet-active`,modifierClass:`${o}-`,currentClass:`${o}-current`,totalClass:`${o}-total`,hiddenClass:`${o}-hidden`,progressbarFillClass:`${o}-progressbar-fill`,progressbarOppositeClass:`${o}-progressbar-opposite`,clickableClass:`${o}-clickable`,lockClass:`${o}-lock`,horizontalClass:`${o}-horizontal`,verticalClass:`${o}-vertical`,paginationDisabledClass:`${o}-disabled`}}),t.pagination={el:null,bullets:[]};let s=0;function l(){return!t.params.pagination.el||!t.pagination.el||Array.isArray(t.pagination.el)&&0===t.pagination.el.length}function c(e,n){const{bulletActiveClass:i}=t.params.pagination;e&&(e=e[("prev"===n?"previous":"next")+"ElementSibling"])&&(e.classList.add(`${i}-${n}`),(e=e[("prev"===n?"previous":"next")+"ElementSibling"])&&e.classList.add(`${i}-${n}-${n}`))}function d(e){const n=e.target.closest(Ko(t.params.pagination.bulletClass));if(!n)return;e.preventDefault();const i=Gr(n)*t.params.slidesPerGroup;if(t.params.loop){if(t.realIndex===i)return;const e=(r=t.realIndex,o=i,(o%=a=t.slides.length)==1+(r%=a)?"next":o===r-1?"previous":void 0);"next"===e?t.slideNext():"previous"===e?t.slidePrev():t.slideToLoop(i)}else t.slideTo(i);var r,o,a}function u(){const e=t.rtl,n=t.params.pagination;if(l())return;let i,o,d=t.pagination.el;d=Kr(d);const u=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.slides.length,h=t.params.loop?Math.ceil(u/t.params.slidesPerGroup):t.snapGrid.length;if(t.params.loop?(o=t.previousRealIndex||0,i=t.params.slidesPerGroup>1?Math.floor(t.realIndex/t.params.slidesPerGroup):t.realIndex):void 0!==t.snapIndex?(i=t.snapIndex,o=t.previousSnapIndex):(o=t.previousIndex||0,i=t.activeIndex||0),"bullets"===n.type&&t.pagination.bullets&&t.pagination.bullets.length>0){const r=t.pagination.bullets;let l,u,h;if(n.dynamicBullets&&(a=Ur(r[0],t.isHorizontal()?"width":"height",!0),d.forEach((e=>{e.style[t.isHorizontal()?"width":"height"]=a*(n.dynamicMainBullets+4)+"px"})),n.dynamicMainBullets>1&&void 0!==o&&(s+=i-(o||0),s>n.dynamicMainBullets-1?s=n.dynamicMainBullets-1:s<0&&(s=0)),l=Math.max(i-s,0),u=l+(Math.min(r.length,n.dynamicMainBullets)-1),h=(u+l)/2),r.forEach((e=>{const t=[...["","-next","-next-next","-prev","-prev-prev","-main"].map((e=>`${n.bulletActiveClass}${e}`))].map((e=>"string"==typeof e&&e.includes(" ")?e.split(" "):e)).flat();e.classList.remove(...t)})),d.length>1)r.forEach((e=>{const r=Gr(e);r===i?e.classList.add(...n.bulletActiveClass.split(" ")):t.isElement&&e.setAttribute("part","bullet"),n.dynamicBullets&&(r>=l&&r<=u&&e.classList.add(...`${n.bulletActiveClass}-main`.split(" ")),r===l&&c(e,"prev"),r===u&&c(e,"next"))}));else{const e=r[i];if(e&&e.classList.add(...n.bulletActiveClass.split(" ")),t.isElement&&r.forEach(((e,t)=>{e.setAttribute("part",t===i?"bullet-active":"bullet")})),n.dynamicBullets){const e=r[l],t=r[u];for(let e=l;e<=u;e+=1)r[e]&&r[e].classList.add(...`${n.bulletActiveClass}-main`.split(" "));c(e,"prev"),c(t,"next")}}if(n.dynamicBullets){const i=Math.min(r.length,n.dynamicMainBullets+4),o=(a*i-a)/2-h*a,s=e?"right":"left";r.forEach((e=>{e.style[t.isHorizontal()?s:"top"]=`${o}px`}))}}d.forEach(((e,o)=>{if("fraction"===n.type&&(e.querySelectorAll(Ko(n.currentClass)).forEach((e=>{e.textContent=n.formatFractionCurrent(i+1)})),e.querySelectorAll(Ko(n.totalClass)).forEach((e=>{e.textContent=n.formatFractionTotal(h)}))),"progressbar"===n.type){let r;r=n.progressbarOpposite?t.isHorizontal()?"vertical":"horizontal":t.isHorizontal()?"horizontal":"vertical";const o=(i+1)/h;let a=1,s=1;"horizontal"===r?a=o:s=o,e.querySelectorAll(Ko(n.progressbarFillClass)).forEach((e=>{e.style.transform=`translate3d(0,0,0) scaleX(${a}) scaleY(${s})`,e.style.transitionDuration=`${t.params.speed}ms`}))}"custom"===n.type&&n.renderCustom?(e.innerHTML=n.renderCustom(t,i+1,h),0===o&&r("paginationRender",e)):(0===o&&r("paginationRender",e),r("paginationUpdate",e)),t.params.watchOverflow&&t.enabled&&e.classList[t.isLocked?"add":"remove"](n.lockClass)}))}function h(){const e=t.params.pagination;if(l())return;const n=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.grid&&t.params.grid.rows>1?t.slides.length/Math.ceil(t.params.grid.rows):t.slides.length;let i=t.pagination.el;i=Kr(i);let o="";if("bullets"===e.type){let i=t.params.loop?Math.ceil(n/t.params.slidesPerGroup):t.snapGrid.length;t.params.freeMode&&t.params.freeMode.enabled&&i>n&&(i=n);for(let n=0;n<i;n+=1)e.renderBullet?o+=e.renderBullet.call(t,n,e.bulletClass):o+=`<${e.bulletElement} ${t.isElement?'part="bullet"':""} class="${e.bulletClass}"></${e.bulletElement}>`}"fraction"===e.type&&(o=e.renderFraction?e.renderFraction.call(t,e.currentClass,e.totalClass):`<span class="${e.currentClass}"></span> / <span class="${e.totalClass}"></span>`),"progressbar"===e.type&&(o=e.renderProgressbar?e.renderProgressbar.call(t,e.progressbarFillClass):`<span class="${e.progressbarFillClass}"></span>`),t.pagination.bullets=[],i.forEach((n=>{"custom"!==e.type&&(n.innerHTML=o||""),"bullets"===e.type&&t.pagination.bullets.push(...n.querySelectorAll(Ko(e.bulletClass)))})),"custom"!==e.type&&r("paginationRender",i[0])}function p(){t.params.pagination=Vo(t,t.originalParams.pagination,t.params.pagination,{el:"swiper-pagination"});const e=t.params.pagination;if(!e.el)return;let n;"string"==typeof e.el&&t.isElement&&(n=t.el.querySelector(e.el)),n||"string"!=typeof e.el||(n=[...document.querySelectorAll(e.el)]),n||(n=e.el),n&&0!==n.length&&(t.params.uniqueNavElements&&"string"==typeof e.el&&Array.isArray(n)&&n.length>1&&(n=[...t.el.querySelectorAll(e.el)],n.length>1&&(n=n.find((e=>Vr(e,".swiper")[0]===t.el)))),Array.isArray(n)&&1===n.length&&(n=n[0]),Object.assign(t.pagination,{el:n}),n=Kr(n),n.forEach((n=>{"bullets"===e.type&&e.clickable&&n.classList.add(...(e.clickableClass||"").split(" ")),n.classList.add(e.modifierClass+e.type),n.classList.add(t.isHorizontal()?e.horizontalClass:e.verticalClass),"bullets"===e.type&&e.dynamicBullets&&(n.classList.add(`${e.modifierClass}${e.type}-dynamic`),s=0,e.dynamicMainBullets<1&&(e.dynamicMainBullets=1)),"progressbar"===e.type&&e.progressbarOpposite&&n.classList.add(e.progressbarOppositeClass),e.clickable&&n.addEventListener("click",d),t.enabled||n.classList.add(e.lockClass)})))}function g(){const e=t.params.pagination;if(l())return;let n=t.pagination.el;n&&(n=Kr(n),n.forEach((n=>{n.classList.remove(e.hiddenClass),n.classList.remove(e.modifierClass+e.type),n.classList.remove(t.isHorizontal()?e.horizontalClass:e.verticalClass),e.clickable&&(n.classList.remove(...(e.clickableClass||"").split(" ")),n.removeEventListener("click",d))}))),t.pagination.bullets&&t.pagination.bullets.forEach((t=>t.classList.remove(...e.bulletActiveClass.split(" "))))}i("changeDirection",(()=>{if(!t.pagination||!t.pagination.el)return;const e=t.params.pagination;let{el:n}=t.pagination;n=Kr(n),n.forEach((n=>{n.classList.remove(e.horizontalClass,e.verticalClass),n.classList.add(t.isHorizontal()?e.horizontalClass:e.verticalClass)}))})),i("init",(()=>{!1===t.params.pagination.enabled?f():(p(),h(),u())})),i("activeIndexChange",(()=>{void 0===t.snapIndex&&u()})),i("snapIndexChange",(()=>{u()})),i("snapGridLengthChange",(()=>{h(),u()})),i("destroy",(()=>{g()})),i("enable disable",(()=>{let{el:e}=t.pagination;e&&(e=Kr(e),e.forEach((e=>e.classList[t.enabled?"remove":"add"](t.params.pagination.lockClass))))})),i("lock unlock",(()=>{u()})),i("click",((e,n)=>{const i=n.target,o=Kr(t.pagination.el);if(t.params.pagination.el&&t.params.pagination.hideOnClick&&o&&o.length>0&&!i.classList.contains(t.params.pagination.bulletClass)){if(t.navigation&&(t.navigation.nextEl&&i===t.navigation.nextEl||t.navigation.prevEl&&i===t.navigation.prevEl))return;const e=o[0].classList.contains(t.params.pagination.hiddenClass);r(!0===e?"paginationShow":"paginationHide"),o.forEach((e=>e.classList.toggle(t.params.pagination.hiddenClass)))}}));const f=()=>{t.el.classList.add(t.params.pagination.paginationDisabledClass);let{el:e}=t.pagination;e&&(e=Kr(e),e.forEach((e=>e.classList.add(t.params.pagination.paginationDisabledClass)))),g()};Object.assign(t.pagination,{enable:()=>{t.el.classList.remove(t.params.pagination.paginationDisabledClass);let{el:e}=t.pagination;e&&(e=Kr(e),e.forEach((e=>e.classList.remove(t.params.pagination.paginationDisabledClass)))),p(),h(),u()},disable:f,render:h,update:u,init:p,destroy:g})}function qo(e){let t,n,{swiper:i,extendParams:r,on:o,emit:a,params:s}=e;i.autoplay={running:!1,paused:!1,timeLeft:0},r({autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!1,stopOnLastSlide:!1,reverseDirection:!1,pauseOnMouseEnter:!1}});let l,c,d,u,h,p,g,f,m=s&&s.autoplay?s.autoplay.delay:3e3,y=s&&s.autoplay?s.autoplay.delay:3e3,v=(new Date).getTime();function b(e){i&&!i.destroyed&&i.wrapperEl&&e.target===i.wrapperEl&&(i.wrapperEl.removeEventListener("transitionend",b),f||e.detail&&e.detail.bySwiperTouchMove||E())}const w=()=>{if(i.destroyed||!i.autoplay.running)return;i.autoplay.paused?c=!0:c&&(y=l,c=!1);const e=i.autoplay.paused?l:v+y-(new Date).getTime();i.autoplay.timeLeft=e,a("autoplayTimeLeft",e,e/m),n=requestAnimationFrame((()=>{w()}))},C=e=>{if(i.destroyed||!i.autoplay.running)return;cancelAnimationFrame(n),w();let r=void 0===e?i.params.autoplay.delay:e;m=i.params.autoplay.delay,y=i.params.autoplay.delay;const o=(()=>{let e;if(e=i.virtual&&i.params.virtual.enabled?i.slides.find((e=>e.classList.contains("swiper-slide-active"))):i.slides[i.activeIndex],e)return parseInt(e.getAttribute("data-swiper-autoplay"),10)})();!Number.isNaN(o)&&o>0&&void 0===e&&(r=o,m=o,y=o),l=r;const s=i.params.speed,c=()=>{i&&!i.destroyed&&(i.params.autoplay.reverseDirection?!i.isBeginning||i.params.loop||i.params.rewind?(i.slidePrev(s,!0,!0),a("autoplay")):i.params.autoplay.stopOnLastSlide||(i.slideTo(i.slides.length-1,s,!0,!0),a("autoplay")):!i.isEnd||i.params.loop||i.params.rewind?(i.slideNext(s,!0,!0),a("autoplay")):i.params.autoplay.stopOnLastSlide||(i.slideTo(0,s,!0,!0),a("autoplay")),i.params.cssMode&&(v=(new Date).getTime(),requestAnimationFrame((()=>{C()}))))};return r>0?(clearTimeout(t),t=setTimeout((()=>{c()}),r)):requestAnimationFrame((()=>{c()})),r},x=()=>{v=(new Date).getTime(),i.autoplay.running=!0,C(),a("autoplayStart")},S=()=>{i.autoplay.running=!1,clearTimeout(t),cancelAnimationFrame(n),a("autoplayStop")},_=(e,n)=>{if(i.destroyed||!i.autoplay.running)return;clearTimeout(t),e||(g=!0);const r=()=>{a("autoplayPause"),i.params.autoplay.waitForTransition?i.wrapperEl.addEventListener("transitionend",b):E()};if(i.autoplay.paused=!0,n)return p&&(l=i.params.autoplay.delay),p=!1,void r();const o=l||i.params.autoplay.delay;l=o-((new Date).getTime()-v),i.isEnd&&l<0&&!i.params.loop||(l<0&&(l=0),r())},E=()=>{i.isEnd&&l<0&&!i.params.loop||i.destroyed||!i.autoplay.running||(v=(new Date).getTime(),g?(g=!1,C(l)):C(),i.autoplay.paused=!1,a("autoplayResume"))},k=()=>{if(i.destroyed||!i.autoplay.running)return;const e=Ar();"hidden"===e.visibilityState&&(g=!0,_(!0)),"visible"===e.visibilityState&&E()},$=e=>{"mouse"===e.pointerType&&(g=!0,f=!0,i.animating||i.autoplay.paused||_(!0))},M=e=>{"mouse"===e.pointerType&&(f=!1,i.autoplay.paused&&E())};o("init",(()=>{i.params.autoplay.enabled&&(i.params.autoplay.pauseOnMouseEnter&&(i.el.addEventListener("pointerenter",$),i.el.addEventListener("pointerleave",M)),Ar().addEventListener("visibilitychange",k),x())})),o("destroy",(()=>{i.el&&"string"!=typeof i.el&&(i.el.removeEventListener("pointerenter",$),i.el.removeEventListener("pointerleave",M)),Ar().removeEventListener("visibilitychange",k),i.autoplay.running&&S()})),o("_freeModeStaticRelease",(()=>{(u||g)&&E()})),o("_freeModeNoMomentumRelease",(()=>{i.params.autoplay.disableOnInteraction?S():_(!0,!0)})),o("beforeTransitionStart",((e,t,n)=>{!i.destroyed&&i.autoplay.running&&(n||!i.params.autoplay.disableOnInteraction?_(!0,!0):S())})),o("sliderFirstMove",(()=>{!i.destroyed&&i.autoplay.running&&(i.params.autoplay.disableOnInteraction?S():(d=!0,u=!1,g=!1,h=setTimeout((()=>{g=!0,u=!0,_(!0)}),200)))})),o("touchEnd",(()=>{if(!i.destroyed&&i.autoplay.running&&d){if(clearTimeout(h),clearTimeout(t),i.params.autoplay.disableOnInteraction)return u=!1,void(d=!1);u&&i.params.cssMode&&E(),u=!1,d=!1}})),o("slideChange",(()=>{!i.destroyed&&i.autoplay.running&&(p=!0)})),Object.assign(i.autoplay,{start:x,stop:S,pause:_,resume:E})}function Qo(e){const{effect:t,swiper:n,on:i,setTranslate:r,setTransition:o,overwriteParams:a,perspective:s,recreateShadows:l,getEffectParams:c}=e;let d;i("beforeInit",(()=>{if(n.params.effect!==t)return;n.classNames.push(`${n.params.containerModifierClass}${t}`),s&&s()&&n.classNames.push(`${n.params.containerModifierClass}3d`);const e=a?a():{};Object.assign(n.params,e),Object.assign(n.originalParams,e)})),i("setTranslate",(()=>{n.params.effect===t&&r()})),i("setTransition",((e,i)=>{n.params.effect===t&&o(i)})),i("transitionEnd",(()=>{if(n.params.effect===t&&l){if(!c||!c().slideShadows)return;n.slides.forEach((e=>{e.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((e=>e.remove()))})),l()}})),i("virtualUpdate",(()=>{n.params.effect===t&&(n.slides.length||(d=!0),requestAnimationFrame((()=>{d&&n.slides&&n.slides.length&&(r(),d=!1)})))}))}function Xo(e,t){const n=Fr(t);return n!==t&&(n.style.backfaceVisibility="hidden",n.style["-webkit-backface-visibility"]="hidden"),n}function Zo(e){let{swiper:t,duration:n,transformElements:i,allSlides:r}=e;const{activeIndex:o}=t;if(t.params.virtualTranslate&&0!==n){let e,n=!1;e=r?i:i.filter((e=>{const n=e.classList.contains("swiper-slide-transform")?(e=>e.parentElement?e.parentElement:t.slides.find((t=>t.shadowRoot&&t.shadowRoot===e.parentNode)))(e):e;return t.getSlideIndex(n)===o})),e.forEach((e=>{!function(e,t){t&&e.addEventListener("transitionend",(function n(i){i.target===e&&(t.call(e,i),e.removeEventListener("transitionend",n))}))}(e,(()=>{if(n)return;if(!t||t.destroyed)return;n=!0,t.animating=!1;const e=new window.CustomEvent("transitionend",{bubbles:!0,cancelable:!0});t.wrapperEl.dispatchEvent(e)}))}))}}function Jo(e){let{swiper:t,extendParams:n,on:i}=e;n({fadeEffect:{crossFade:!1}}),Qo({effect:"fade",swiper:t,on:i,setTranslate:()=>{const{slides:e}=t;t.params.fadeEffect;for(let n=0;n<e.length;n+=1){const e=t.slides[n];let i=-e.swiperSlideOffset;t.params.virtualTranslate||(i-=t.translate);let r=0;t.isHorizontal()||(r=i,i=0);const o=t.params.fadeEffect.crossFade?Math.max(1-Math.abs(e.progress),0):1+Math.min(Math.max(e.progress,-1),0),a=Xo(0,e);a.style.opacity=o,a.style.transform=`translate3d(${i}px, ${r}px, 0px)`}},setTransition:e=>{const n=t.slides.map((e=>Fr(e)));n.forEach((t=>{t.style.transitionDuration=`${e}ms`})),Zo({swiper:t,duration:e,transformElements:n,allSlides:!0})},overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!t.params.cssMode})})}function ea(e,t,n){const i=`swiper-slide-shadow${n?`-${n}`:""}${e?` swiper-slide-shadow-${e}`:""}`,r=Fr(t);let o=r.querySelector(`.${i.split(" ").join(".")}`);return o||(o=Wr("div",i.split(" ")),r.append(o)),o}function ta(e){let{swiper:t,extendParams:n,on:i}=e;n({creativeEffect:{limitProgress:1,shadowPerProgress:!1,progressMultiplier:1,perspective:!0,prev:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1},next:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1}}});const r=e=>"string"==typeof e?e:`${e}px`;Qo({effect:"creative",swiper:t,on:i,setTranslate:()=>{const{slides:e,wrapperEl:n,slidesSizesGrid:i}=t,o=t.params.creativeEffect,{progressMultiplier:a}=o,s=t.params.centeredSlides,l=function(e){return t=>Math.abs(t)>0&&e.browser&&e.browser.need3dFix&&Math.abs(t)%90==0?t+.001:t}(t);if(s){const e=i[0]/2-t.params.slidesOffsetBefore||0;n.style.transform=`translateX(calc(50% - ${e}px))`}for(let n=0;n<e.length;n+=1){const i=e[n],c=i.progress,d=Math.min(Math.max(i.progress,-o.limitProgress),o.limitProgress);let u=d;s||(u=Math.min(Math.max(i.originalProgress,-o.limitProgress),o.limitProgress));const h=i.swiperSlideOffset,p=[t.params.cssMode?-h-t.translate:-h,0,0],g=[0,0,0];let f=!1;t.isHorizontal()||(p[1]=p[0],p[0]=0);let m={translate:[0,0,0],rotate:[0,0,0],scale:1,opacity:1};d<0?(m=o.next,f=!0):d>0&&(m=o.prev,f=!0),p.forEach(((e,t)=>{p[t]=`calc(${e}px + (${r(m.translate[t])} * ${Math.abs(d*a)}))`})),g.forEach(((e,t)=>{let n=m.rotate[t]*Math.abs(d*a);g[t]=n})),i.style.zIndex=-Math.abs(Math.round(c))+e.length;const y=p.join(", "),v=`rotateX(${l(g[0])}deg) rotateY(${l(g[1])}deg) rotateZ(${l(g[2])}deg)`,b=u<0?`scale(${1+(1-m.scale)*u*a})`:`scale(${1-(1-m.scale)*u*a})`,w=u<0?1+(1-m.opacity)*u*a:1-(1-m.opacity)*u*a,C=`translate3d(${y}) ${v} ${b}`;if(f&&m.shadow||!f){let e=i.querySelector(".swiper-slide-shadow");if(!e&&m.shadow&&(e=ea("creative",i)),e){const t=o.shadowPerProgress?d*(1/o.limitProgress):d;e.style.opacity=Math.min(Math.max(Math.abs(t),0),1)}}const x=Xo(0,i);x.style.transform=C,x.style.opacity=w,m.origin&&(x.style.transformOrigin=m.origin)}},setTransition:e=>{const n=t.slides.map((e=>Fr(e)));n.forEach((t=>{t.style.transitionDuration=`${e}ms`,t.querySelectorAll(".swiper-slide-shadow").forEach((t=>{t.style.transitionDuration=`${e}ms`}))})),Zo({swiper:t,duration:e,transformElements:n,allSlides:!0})},perspective:()=>t.params.creativeEffect.perspective,overwriteParams:()=>({watchSlidesProgress:!0,virtualTranslate:!t.params.cssMode})})}Go.displayName="SwiperSlide";const na=({posts:e,attributes:t,id:n})=>{const{columns:r,columnGap:o,sliderIsLoop:a,sliderIsTouchMove:s,sliderIsAutoplay:l,sliderAutoplayOptions:c={delay:1.5},sliderSpeed:d,sliderEffect:u,sliderIsPage:h,sliderIsPageClickable:p,sliderIsPageDynamic:g,sliderIsPrevNext:f}=t;return(0,i.useEffect)((()=>{(e=>{const t=[],n=document.querySelectorAll(`#${e} .swiper .swiper-slide`),i=document.querySelectorAll(`#${e} .swiper .swiper-slide .${Oi}Text`);i?.forEach((e=>{t.push(e?.clientHeight)})),n?.length&&n.forEach((e=>{e.querySelector("article").style.height=`${Math.max(...t)}px`}))})(n)}),[e?.length]),(0,i.createElement)(jo,{className:`${Oi}SliderPosts`,spaceBetween:o,slidesPerView:r.mobile,breakpoints:{641:{slidesPerView:r.tablet},1025:{slidesPerView:r.desktop}},modules:[qo,Jo,ta,Uo,Yo],loop:a,allowTouchMove:s,grabCursor:s,autoplay:!!l&&{delay:1e3*c?.delay},speed:1e3*d,effect:u,fadeEffect:{crossFade:!0},creativeEffect:{prev:{shadow:!0,translate:["-120%",0,-500]},next:{shadow:!0,translate:["120%",0,-500]}},pagination:!!h&&{clickable:p,dynamicBullets:g},navigation:f,allowSlideNext:!0,allowSlidePrev:!0,autoHeight:!1,notificationClass:null},e.map((e=>(0,i.createElement)(Go,{key:e.id},(0,i.createElement)(pr,{post:e,attributes:t})))))},ia=({posts:e,attributes:t,id:n})=>{const{columns:r,columnGap:o,sliderIsLoop:a,sliderIsTouchMove:s,sliderIsAutoplay:l,sliderAutoplayOptions:c={delay:1.5},sliderSpeed:d,sliderEffect:u,sliderIsPage:h,sliderIsPageClickable:p,sliderIsPageDynamic:g,sliderIsPrevNext:f}=t,[m,y]=(0,i.useState)(!0);return(0,i.useEffect)((()=>{y(!m)}),[r,o,a,s,l,c,d,u,h,p,g,f]),(0,i.createElement)((()=>(0,i.createElement)(na,{posts:e,attributes:t,id:n})),null)},ra=jQuery,oa=({posts:e,attributes:t,id:n})=>{const{rowGap:r,tickerDirection:o,tickerSpeed:a,tickerInterval:s,tickerHeight:l,tickerVisible:c,tickerIsMousePause:d}=t,u=(0,i.useRef)(null),h=(0,i.useRef)(null),p=`#${n}`;return(0,i.useEffect)((()=>{const e=h.current;e&&(e.innerHTML="",e.innerHTML=u.current.outerHTML,ra(`${p} .${Oi}TickerWrapper .${Oi}TickerPosts`).easyTicker((e=>{const{rowGap:t,tickerDirection:n="up",tickerSpeed:i="slow",tickerInterval:r=2e3,tickerHeight:o="0px",tickerVisible:a=3,tickerIsMousePause:s=!0}=e;return{direction:n,easing:"swing",speed:isNaN(i)?i:parseInt(i),interval:r,height:"0px"===o||"0em"===o?"auto":o,gap:t,visible:a,mousePause:s}})(t)))}),[r,o,a,s,l,c,d]),(0,i.createElement)(i.Fragment,null,(0,i.createElement)("div",{className:`${Oi}TickerWrapper`,ref:h}),(0,i.createElement)("div",{className:`${Oi}TickerPosts`,ref:u},(0,i.createElement)("div",null,e.map((e=>(0,i.createElement)(pr,{key:e.id,post:e,attributes:t}))))))},aa=({posts:e,totalPosts:t,attributes:n,setAttributes:r,id:o,isPremium:a})=>(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Xi,{attributes:n,id:o}),(0,i.createElement)(Sr,{posts:e,attributes:n,id:o,Slider:ia,Ticker:oa}),a&&(0,i.createElement)(kr,{attributes:n,totalCount:t,onChange:e=>r({paginationCurrentPage:e})})),sa=()=>{const{data:e=null,refetch:t,isLoading:n=!0}=((e,t={},n=!0)=>{const[r,o]=(0,i.useState)(!1),[a,s]=(0,i.useState)(!1),[l,c]=(0,i.useState)(null),[d,u]=(0,i.useState)(null);if(!wp.ajax)return void console.error("Please use wp-util as a dependency");const h=(n={})=>{o(!0),s(!1),c(null),wp.ajax.post(e,{...t,...n}).done((e=>{o(!1),u(e)})).fail((e=>{o(!1),s(!0),c(e)}))},p=(e={})=>{h(e)};return(0,i.useEffect)((()=>{n&&h(t)}),[]),{data:d,saveData:p,refetch:p,isLoading:r,isError:a,error:l}})("apbPipeChecker",{_wpnonce:wpApiSettings?.nonce},!0),r=!n&&e?.isPipe||!1;return(0,i.useEffect)((()=>{null===e&&t()}),[e,wpApiSettings?.nonce]),{isPremium:r,isLoading:n}},{dateI18n:la}=wp.date,ca=(0,o.withSelect)(((e,{attributes:t,setAttributes:n})=>{const{getUsers:r,getEntityRecords:o,getTaxonomies:a,getMedia:s,getComments:l}=e("core"),{postType:c,selectedTaxonomies:d={},selectedCategories:u=[],selectedTags:h=[],isPostsPerPageAll:p,postsPerPage:g,postsOrderBy:f,postsOrder:m,postsOffset:y=0,postsInclude:v=[],postsExclude:b=[],isExcludeCurrent:w,isPagination:C,paginationCurrentPage:x,fImgSize:S="full",metaDateFormat:_="M j, Y"}=t,E="post"===c?{categories:u}:{},k="post"===c?{tags:h}:{};var $,M;const T={...Object.assign({},d?.category?{categories:d.category}:{},d?.post_tag?{tags:d.post_tag}:{},($=d,M=e=>"category"!==e&&"post_tag"!==e,Object.fromEntries(Object.entries($).filter((([e,t])=>M(e)))))),...E,...k,per_page:p?-1:g,orderby:f,order:m,offset:p?0:y,...ki(v)?.length?{include:ki(v)}:{},exclude:w?[e("core/editor").getCurrentPostId(),...ki(b)]:ki(b),status:"publish"},A=Ri(o("postType",c,{...T,per_page:-1}),"false");(0,i.useEffect)((()=>n({paginationCurrentPage:1})),[]);const L=g*(x-1),R=L+g,O=A?.slice(L,R),I=e=>o("taxonomy",e,{per_page:-1}),P=e=>l({per_page:-1})?.filter((({post:t})=>e===t)),N=a({per_page:-1})?.filter((e=>e.types.includes(c)&&"category"!==e.slug))?.map((({name:e,slug:t,rest_base:n})=>({name:e,slug:t,rest_base:n}))),D=C&&!p?O:Ri(o("postType",c,T),"false");return{totalPosts:A?.length,posts:(e=>e?.map((e=>{const{id:t,link:n,slug:i,featured_media:o,title:a,excerpt:l,author:c,categories:d,content:u,date:h,date_gmt:p,modified:g,modified_gmt:f,comment_status:m,status:y}=e,v=((e,t)=>{const n=s(e),i=n?.media_details?.sizes?.[t]?.source_url||n?.source_url;return{url:i?.replace(/<[^>]+>/g,""),alt:n?.alt_text}})(o,S),b={};N?.map((t=>{const n=I(t.slug)?.filter((n=>e[t.rest_base]?.includes(n.id)))?.map((e=>`<a href='${e.link}' rel='${t.slug}'>${e.name}</a>`));b[t.slug]=n?.join("")}));const w=u?.raw?.replace(/(<([^>]+)>)/gi,"")?.trim(),C=d?.length?I("category")?.filter((e=>d?.includes(e.id)))?.map((e=>`<a href='${e.link}' rel='category tag'>${e.name}</a>`)):[],x=r({who:"authors"})?.map((({id:e,name:t,link:n})=>({id:e,name:t,link:n})))?.find((e=>e.id===c));return{id:t,link:n,name:i,thumbnail:v,title:a?.rendered,excerpt:l?.raw?.replace(/(<([^>]+)>)/gi,"")?.trim(),content:w,author:x,date:la(_,new Date(h)),dateGMT:p,modifiedDate:g,modifiedDateGMT:f,commentCount:P(t)?.length,commentStatus:m,categories:{coma:C?.join(", "),space:C?.join(" ")},taxonomies:b,readTime:{min:Math.floor($i(w)/200),sec:Math.floor($i(w)%200/(200/60))},status:y}})))(D),taxOfPostType:N,media:e=>s(e)}}))((e=>{const{attributes:t,setAttributes:n,clientId:r,isSelected:o,totalPosts:s,posts:c,taxOfPostType:d}=e,u=(0,a.useBlockProps)(),{isPremium:h=!1}=sa();(0,i.useEffect)((()=>l()),[o]);const p=`block-${r}`;return(0,i.createElement)(i.Fragment,null,(0,i.createElement)(Wi,{isPremium:h,attributes:t,setAttributes:n,posts:c,taxOfPostType:d}),c?c?.length?(0,i.createElement)("div",{...u},(0,i.createElement)(aa,{posts:c,totalPosts:s,attributes:t,setAttributes:n,id:p,isPremium:h})):(0,i.createElement)(Gi,null):(0,i.createElement)(ji,null))}));(0,e.updateCategory)("APBlock",{icon:ai(20)}),(0,e.registerBlockType)(t,{icon:ai(24),edit:ca,save:()=>null})})()})();