@eox/layercontrol 0.13.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(je,ye){typeof exports=="object"&&typeof module<"u"?ye(exports):typeof define=="function"&&define.amd?define(["exports"],ye):(je=typeof globalThis<"u"?globalThis:je||self,ye(je["eox-layercontrol"]={}))})(this,function(je){"use strict";var Yf=Object.defineProperty;var Xf=(je,ye,Fe)=>ye in je?Yf(je,ye,{enumerable:!0,configurable:!0,writable:!0,value:Fe}):je[ye]=Fe;var Xe=(je,ye,Fe)=>(Xf(je,typeof ye!="symbol"?ye+"":ye,Fe),Fe),ic=(je,ye,Fe)=>{if(!ye.has(je))throw TypeError("Cannot "+Fe)};var Ee=(je,ye,Fe)=>(ic(je,ye,"read from private field"),Fe?Fe.call(je):ye.get(je)),se=(je,ye,Fe)=>{if(ye.has(je))throw TypeError("Cannot add the same private member more than once");ye instanceof WeakSet?ye.add(je):ye.set(je,Fe)},Si=(je,ye,Fe,Po)=>(ic(je,ye,"write to private field"),Po?Po.call(je,Fe):ye.set(je,Fe),Fe);var rr=(je,ye,Fe)=>(ic(je,ye,"access private method"),Fe);/**
|
|
2
2
|
* @license
|
|
3
3
|
* Copyright 2019 Google LLC
|
|
4
4
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
13
13
|
*/const Ao=globalThis,ba=Ao.trustedTypes,hc=ba?ba.createPolicy("lit-html",{createHTML:m=>m}):void 0,Bs="$lit$",bn=`lit$${(Math.random()+"").slice(9)}$`,Ds="?"+bn,uh=`<${Ds}>`,ti=document,Lo=()=>ti.createComment(""),Ro=m=>m===null||typeof m!="object"&&typeof m!="function",dc=Array.isArray,pc=m=>dc(m)||typeof(m==null?void 0:m[Symbol.iterator])=="function",Ns=`[
|
|
14
14
|
\f\r]`,Io=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,fc=/-->/g,mc=/>/g,ei=RegExp(`>|${Ns}(?:([^\\s"'>=/]+)(${Ns}*=${Ns}*(?:[^
|
|
15
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),yc=/'/g,bc=/"/g,vc=/^(?:script|style|textarea|title)$/i,hh=m=>(s,...p)=>({_$litType$:m,strings:s,values:p}),ae=hh(1),Nr=Symbol.for("lit-noChange"),
|
|
15
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),yc=/'/g,bc=/"/g,vc=/^(?:script|style|textarea|title)$/i,hh=m=>(s,...p)=>({_$litType$:m,strings:s,values:p}),ae=hh(1),Nr=Symbol.for("lit-noChange"),_e=Symbol.for("lit-nothing"),gc=new WeakMap,ri=ti.createTreeWalker(ti,129);function wc(m,s){if(!Array.isArray(m)||!m.hasOwnProperty("raw"))throw Error("invalid template strings array");return hc!==void 0?hc.createHTML(s):s}const _c=(m,s)=>{const p=m.length-1,b=[];let _,E=s===2?"<svg>":"",y=Io;for(let j=0;j<p;j++){const r=m[j];let v,g,w=-1,k=0;for(;k<r.length&&(y.lastIndex=k,g=y.exec(r),g!==null);)k=y.lastIndex,y===Io?g[1]==="!--"?y=fc:g[1]!==void 0?y=mc:g[2]!==void 0?(vc.test(g[2])&&(_=RegExp("</"+g[2],"g")),y=ei):g[3]!==void 0&&(y=ei):y===ei?g[0]===">"?(y=_??Io,w=-1):g[1]===void 0?w=-2:(w=y.lastIndex-g[2].length,v=g[1],y=g[3]===void 0?ei:g[3]==='"'?bc:yc):y===bc||y===yc?y=ei:y===fc||y===mc?y=Io:(y=ei,_=void 0);const O=y===ei&&m[j+1].startsWith("/>")?" ":"";E+=y===Io?r+uh:w>=0?(b.push(v),r.slice(0,w)+Bs+r.slice(w)+bn+O):r+bn+(w===-2?j:O)}return[wc(m,E+(m[p]||"<?>")+(s===2?"</svg>":"")),b]};class Bo{constructor({strings:s,_$litType$:p},b){let _;this.parts=[];let E=0,y=0;const j=s.length-1,r=this.parts,[v,g]=_c(s,p);if(this.el=Bo.createElement(v,b),ri.currentNode=this.el.content,p===2){const w=this.el.content.firstChild;w.replaceWith(...w.childNodes)}for(;(_=ri.nextNode())!==null&&r.length<j;){if(_.nodeType===1){if(_.hasAttributes())for(const w of _.getAttributeNames())if(w.endsWith(Bs)){const k=g[y++],O=_.getAttribute(w).split(bn),C=/([.?@])?(.*)/.exec(k);r.push({type:1,index:E,name:C[2],strings:O,ctor:C[1]==="."?kc:C[1]==="?"?jc:C[1]==="@"?Oc:Do}),_.removeAttribute(w)}else w.startsWith(bn)&&(r.push({type:6,index:E}),_.removeAttribute(w));if(vc.test(_.tagName)){const w=_.textContent.split(bn),k=w.length-1;if(k>0){_.textContent=ba?ba.emptyScript:"";for(let O=0;O<k;O++)_.append(w[O],Lo()),ri.nextNode(),r.push({type:2,index:++E});_.append(w[k],Lo())}}}else if(_.nodeType===8)if(_.data===Ds)r.push({type:2,index:E});else{let w=-1;for(;(w=_.data.indexOf(bn,w+1))!==-1;)r.push({type:7,index:E}),w+=bn.length-1}E++}}static createElement(s,p){const b=ti.createElement("template");return b.innerHTML=s,b}}function ni(m,s,p=m,b){var y,j;if(s===Nr)return s;let _=b!==void 0?(y=p._$Co)==null?void 0:y[b]:p._$Cl;const E=Ro(s)?void 0:s._$litDirective$;return(_==null?void 0:_.constructor)!==E&&((j=_==null?void 0:_._$AO)==null||j.call(_,!1),E===void 0?_=void 0:(_=new E(m),_._$AT(m,p,b)),b!==void 0?(p._$Co??(p._$Co=[]))[b]=_:p._$Cl=_),_!==void 0&&(s=ni(m,_._$AS(m,s.values),_,b)),s}class xc{constructor(s,p){this._$AV=[],this._$AN=void 0,this._$AD=s,this._$AM=p}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(s){const{el:{content:p},parts:b}=this._$AD,_=((s==null?void 0:s.creationScope)??ti).importNode(p,!0);ri.currentNode=_;let E=ri.nextNode(),y=0,j=0,r=b[0];for(;r!==void 0;){if(y===r.index){let v;r.type===2?v=new Ti(E,E.nextSibling,this,s):r.type===1?v=new r.ctor(E,r.name,r.strings,this,s):r.type===6&&(v=new Ec(E,this,s)),this._$AV.push(v),r=b[++j]}y!==(r==null?void 0:r.index)&&(E=ri.nextNode(),y++)}return ri.currentNode=ti,_}p(s){let p=0;for(const b of this._$AV)b!==void 0&&(b.strings!==void 0?(b._$AI(s,b,p),p+=b.strings.length-2):b._$AI(s[p])),p++}}class Ti{get _$AU(){var s;return((s=this._$AM)==null?void 0:s._$AU)??this._$Cv}constructor(s,p,b,_){this.type=2,this._$AH=_e,this._$AN=void 0,this._$AA=s,this._$AB=p,this._$AM=b,this.options=_,this._$Cv=(_==null?void 0:_.isConnected)??!0}get parentNode(){let s=this._$AA.parentNode;const p=this._$AM;return p!==void 0&&(s==null?void 0:s.nodeType)===11&&(s=p.parentNode),s}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(s,p=this){s=ni(this,s,p),Ro(s)?s===_e||s==null||s===""?(this._$AH!==_e&&this._$AR(),this._$AH=_e):s!==this._$AH&&s!==Nr&&this._(s):s._$litType$!==void 0?this.g(s):s.nodeType!==void 0?this.$(s):pc(s)?this.T(s):this._(s)}k(s){return this._$AA.parentNode.insertBefore(s,this._$AB)}$(s){this._$AH!==s&&(this._$AR(),this._$AH=this.k(s))}_(s){this._$AH!==_e&&Ro(this._$AH)?this._$AA.nextSibling.data=s:this.$(ti.createTextNode(s)),this._$AH=s}g(s){var E;const{values:p,_$litType$:b}=s,_=typeof b=="number"?this._$AC(s):(b.el===void 0&&(b.el=Bo.createElement(wc(b.h,b.h[0]),this.options)),b);if(((E=this._$AH)==null?void 0:E._$AD)===_)this._$AH.p(p);else{const y=new xc(_,this),j=y.u(this.options);y.p(p),this.$(j),this._$AH=y}}_$AC(s){let p=gc.get(s.strings);return p===void 0&&gc.set(s.strings,p=new Bo(s)),p}T(s){dc(this._$AH)||(this._$AH=[],this._$AR());const p=this._$AH;let b,_=0;for(const E of s)_===p.length?p.push(b=new Ti(this.k(Lo()),this.k(Lo()),this,this.options)):b=p[_],b._$AI(E),_++;_<p.length&&(this._$AR(b&&b._$AB.nextSibling,_),p.length=_)}_$AR(s=this._$AA.nextSibling,p){var b;for((b=this._$AP)==null?void 0:b.call(this,!1,!0,p);s&&s!==this._$AB;){const _=s.nextSibling;s.remove(),s=_}}setConnected(s){var p;this._$AM===void 0&&(this._$Cv=s,(p=this._$AP)==null||p.call(this,s))}}class Do{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(s,p,b,_,E){this.type=1,this._$AH=_e,this._$AN=void 0,this.element=s,this.name=p,this._$AM=_,this.options=E,b.length>2||b[0]!==""||b[1]!==""?(this._$AH=Array(b.length-1).fill(new String),this.strings=b):this._$AH=_e}_$AI(s,p=this,b,_){const E=this.strings;let y=!1;if(E===void 0)s=ni(this,s,p,0),y=!Ro(s)||s!==this._$AH&&s!==Nr,y&&(this._$AH=s);else{const j=s;let r,v;for(s=E[0],r=0;r<E.length-1;r++)v=ni(this,j[b+r],p,r),v===Nr&&(v=this._$AH[r]),y||(y=!Ro(v)||v!==this._$AH[r]),v===_e?s=_e:s!==_e&&(s+=(v??"")+E[r+1]),this._$AH[r]=v}y&&!_&&this.O(s)}O(s){s===_e?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,s??"")}}class kc extends Do{constructor(){super(...arguments),this.type=3}O(s){this.element[this.name]=s===_e?void 0:s}}class jc extends Do{constructor(){super(...arguments),this.type=4}O(s){this.element.toggleAttribute(this.name,!!s&&s!==_e)}}class Oc extends Do{constructor(s,p,b,_,E){super(s,p,b,_,E),this.type=5}_$AI(s,p=this){if((s=ni(this,s,p,0)??_e)===Nr)return;const b=this._$AH,_=s===_e&&b!==_e||s.capture!==b.capture||s.once!==b.once||s.passive!==b.passive,E=s!==_e&&(b===_e||_);_&&this.element.removeEventListener(this.name,this,b),E&&this.element.addEventListener(this.name,this,s),this._$AH=s}handleEvent(s){var p;typeof this._$AH=="function"?this._$AH.call(((p=this.options)==null?void 0:p.host)??this.element,s):this._$AH.handleEvent(s)}}class Ec{constructor(s,p,b){this.element=s,this.type=6,this._$AN=void 0,this._$AM=p,this.options=b}get _$AU(){return this._$AM._$AU}_$AI(s){ni(this,s)}}const dh={j:Bs,P:bn,A:Ds,C:1,M:_c,L:xc,R:pc,V:ni,D:Ti,I:Do,H:jc,N:Oc,U:kc,B:Ec},$s=Ao.litHtmlPolyfillSupport;$s==null||$s(Bo,Ti),(Ao.litHtmlVersions??(Ao.litHtmlVersions=[])).push("3.1.0");const ph=(m,s,p)=>{const b=(p==null?void 0:p.renderBefore)??s;let _=b._$litPart$;if(_===void 0){const E=(p==null?void 0:p.renderBefore)??null;b._$litPart$=_=new Ti(s.insertBefore(Lo(),E),E,void 0,p??{})}return _._$AI(m),_};/**
|
|
16
16
|
* @license
|
|
17
17
|
* Copyright 2017 Google LLC
|
|
18
18
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -38,48 +38,48 @@
|
|
|
38
38
|
* @license BSD-2-Clause
|
|
39
39
|
* @preserve
|
|
40
40
|
*/var ie=m=>m!==void 0,Tc=(m,s,p)=>s in m?m[s]:m[s]=p;const $o={ELEMENT:1,ATTRIBUTE:2,TEXT:3,CDATA_SECTION:4,ENTITY_REFERENCE:5,ENTITY:6,PROCESSING_INSTRUCTION:7,COMMENT:8,DOCUMENT:9,DOCUMENT_TYPE:10,DOCUMENT_FRAGMENT:11,NOTATION:12};class gh{constructor(s){this._parser=new s}toDocument(s){return this._parser.parseFromString(s,"application/xml")}getAllTextContent(s,p){return va(s,p).join("")}}function va(m,s){return Ac(m,s,[]).join("")}function Ac(m,s,p){if(m.nodeType===$o.CDATA_SECTION||m.nodeType===$o.TEXT)s?p.push(String(m.nodeValue).replace(/(\r\n|\r|\n)/g,"")):p.push(m.nodeValue);else{var b;for(b=m.firstChild;b;b=b.nextSibling)Ac(b,s,p)}return p}function wh(m,s,p,b){for(var _=_h(s);_;_=xh(_)){var E=_.namespaceURI||null,y=m[E];if(ie(y)){var j=y[_.localName];ie(j)&&j.call(b,_,p)}}}function _h(m){let s=m.firstElementChild||m.firstChild;for(;s&&s.nodeType!==$o.ELEMENT;)s=s.nextSibling;return s}function xh(m){let s=m.nextElementSibling||m.nextSibling;for(;s&&s.nodeType!==$o.ELEMENT;)s=s.nextSibling;return s}function or(m,s,p){return kh(m,s,p)}function kh(m,s,p){var b=ie(p)?p:{},_,E;for(_=0,E=m.length;_<E;++_)b[m[_]]=s;return b}function Lc(m,s){return function(p,b){var _=m.call(ie(s)?s:this,p,b);if(ie(_)){var E=b[b.length-1];E.push(_)}}}function nr(m,s,p,b,_){return b.push(m),wh(s,p,b,_),b.pop()}function Pt(m,s,p){return function(b,_){let E=m.call(ie(p)?p:this,b,_);if(ie(E)){var y=_[_.length-1],j=ie(s)?s:b.localName;y[j]=E}}}function Or(m,s,p){return function(b,_){var E=m.call(ie(p)?p:this,b,_);if(ie(E)){var y=_[_.length-1],j=ie(s)?s:b.localName,r=Tc(y,j,[]);r.push(E)}}}const jh=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function Oh(m){return m.replace(jh,"")}function oi(m){const s=/^\s*(true|1)|(false|0)\s*$/.exec(m);if(s)return ie(s[1])||!1}function Ai(m){return vn(va(m,!1))}function vn(m){const s=/^\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)\s*$/i.exec(m);if(s)return parseFloat(s[1])}function zs(m){return ga(va(m,!1))}function ga(m){const s=/^\s*(\d+)\s*$/.exec(m);if(s)return parseInt(s[1],10)}function pe(m){return Oh(va(m,!1))}const Eh="http://www.w3.org/1999/xlink";function Us(m){return m.getAttributeNS(Eh,"href")}function Ch(m,s){return nr({},td,m,s)}function Rc(m){return[vn(m.getAttribute("minx")),vn(m.getAttribute("miny")),vn(m.getAttribute("maxx")),vn(m.getAttribute("maxy"))]}function Sh(m,s){const p=Rc(m),b=[vn(m.getAttribute("resx")),vn(m.getAttribute("resy"))];return{crs:m.getAttribute("CRS")||m.getAttribute("SRS"),extent:p,res:b}}function Ph(m,s){const p=Rc(m);if(!(!ie(p[0])||!ie(p[1])||!ie(p[2])||!ie(p[3])))return p}function Th(m,s){const p=parseFloat(m.getAttribute("min")),b=parseFloat(m.getAttribute("max"));return{min:p,max:b}}function Ah(m,s){const p=nr({},ed,m,s);if(!ie(p))return;const b=p.westBoundLongitude,_=p.southBoundLatitude,E=p.eastBoundLongitude,y=p.northBoundLatitude;if(!(!ie(b)||!ie(_)||!ie(E)||!ie(y)))return[b,_,E,y]}function Lh(m,s){return nr({},Zh,m,s)}function Rh(m,s){return nr({},Jh,m,s)}function Ih(m,s){return nr({},Yh,m,s)}function Bh(m,s){return nr({},Xh,m,s)}function Dh(m,s){return nr({},Kh,m,s)}function Nh(m,s){return nr([],Qh,m,s)}function $h(m,s){const p=oi(m.getAttribute("queryable"));return nr({queryable:ie(p)?p:!1},Dc,m,s)}function Mh(m,s){var p=s[s.length-1];const b=nr({},Dc,m,s);if(!ie(b))return;let _=oi(m.getAttribute("queryable"));ie(_)||(_=p.queryable),b.queryable=ie(_)?_:!1;let E=ga(m.getAttribute("cascaded"));ie(E)||(E=p.cascaded),b.cascaded=E;let y=oi(m.getAttribute("opaque"));ie(y)||(y=p.opaque),b.opaque=ie(y)?y:!1;let j=oi(m.getAttribute("noSubsets"));ie(j)||(j=p.noSubsets),b.noSubsets=ie(j)?j:!1;let r=vn(m.getAttribute("fixedWidth"));ie(r)||(r=p.fixedWidth),b.fixedWidth=r;let v=vn(m.getAttribute("fixedHeight"));ie(v)||(v=p.fixedHeight),b.fixedHeight=v;const g=["Style","CRS","AuthorityURL"];for(let k=0,O=g.length;k<O;k++){const C=g[k],S=p[C];if(ie(S)){let T=Tc(b,C,[]);T=T.concat(S),b[C]=T}}const w=["EX_GeographicBoundingBox","BoundingBox","Dimension","Attribution","MinScaleDenominator","MaxScaleDenominator"];for(let k=0,O=w.length;k<O;k++){const C=w[k],S=b[C];if(!ie(S)){const T=p[C];b[C]=T}}return b}function Hh(m,s){return{name:m.getAttribute("name"),units:m.getAttribute("units"),unitSymbol:m.getAttribute("unitSymbol"),default:m.getAttribute("default"),multipleValues:oi(m.getAttribute("multipleValues")),nearestValue:oi(m.getAttribute("nearestValue")),current:oi(m.getAttribute("current")),values:pe(m)}}function gn(m,s){return nr({},sd,m,s)}function Fh(m,s){return nr({},rd,m,s)}function Vh(m,s){return nr({},id,m,s)}function zh(m,s){return nr({},od,m,s)}function qs(m,s){return nr({},nd,m,s)}function Ic(m,s){var p=gn(m,s);if(ie(p)){const b=[ga(m.getAttribute("width")),ga(m.getAttribute("height"))];return p.size=b,p}}function Uh(m,s){var p=gn(m,s);if(ie(p))return p.name=m.getAttribute("name"),p}function qh(m,s){var p=gn(m,s);if(ie(p))return p.type=m.getAttribute("type"),p}function Gh(m,s){return nr({},ad,m,s)}function Bc(m,s){return nr([],ld,m,s)}const ar=[null,"http://www.opengis.net/wms"],Wh=or(ar,{Service:Pt(Rh),Capability:Pt(Lh)}),Zh=or(ar,{Request:Pt(Fh),Exception:Pt(Nh),Layer:Pt($h)}),Jh=or(ar,{Name:Pt(pe),Title:Pt(pe),Abstract:Pt(pe),KeywordList:Pt(Bc),OnlineResource:Pt(Us),ContactInformation:Pt(Ih),Fees:Pt(pe),AccessConstraints:Pt(pe),LayerLimit:Pt(zs),MaxWidth:Pt(zs),MaxHeight:Pt(zs)}),Yh=or(ar,{ContactPersonPrimary:Pt(Bh),ContactPosition:Pt(pe),ContactAddress:Pt(Dh),ContactVoiceTelephone:Pt(pe),ContactFacsimileTelephone:Pt(pe),ContactElectronicMailAddress:Pt(pe)}),Xh=or(ar,{ContactPerson:Pt(pe),ContactOrganization:Pt(pe)}),Kh=or(ar,{AddressType:Pt(pe),Address:Pt(pe),City:Pt(pe),StateOrProvince:Pt(pe),PostCode:Pt(pe),Country:Pt(pe)}),Qh=or(ar,{Format:Lc(pe)}),Dc=or(ar,{Name:Pt(pe),Title:Pt(pe),Abstract:Pt(pe),KeywordList:Pt(Bc),CRS:Or(pe),SRS:Or(pe),EX_GeographicBoundingBox:Pt(Ah),LatLonBoundingBox:Pt(Ph),BoundingBox:Or(Sh),Dimension:Or(Hh),Attribution:Pt(Ch),AuthorityURL:Or(Uh),Identifier:Or(pe),MetadataURL:Or(qh),DataURL:Or(gn),FeatureListURL:Or(gn),Style:Or(Gh),MinScaleDenominator:Pt(Ai),MaxScaleDenominator:Pt(Ai),ScaleHint:Pt(Th),Layer:Or(Mh)}),td=or(ar,{Title:Pt(pe),OnlineResource:Pt(Us),LogoURL:Pt(Ic)}),ed=or(ar,{westBoundLongitude:Pt(Ai),eastBoundLongitude:Pt(Ai),southBoundLatitude:Pt(Ai),northBoundLatitude:Pt(Ai)}),rd=or(ar,{GetCapabilities:Pt(qs),GetMap:Pt(qs),GetFeatureInfo:Pt(qs)}),nd=or(ar,{Format:Or(pe),DCPType:Or(Vh)}),id=or(ar,{HTTP:Pt(zh)}),od=or(ar,{Get:Pt(gn),Post:Pt(gn)}),ad=or(ar,{Name:Pt(pe),Title:Pt(pe),Abstract:Pt(pe),LegendURL:Or(Ic),StyleSheetURL:Pt(gn),StyleURL:Pt(gn)}),sd=or(ar,{Format:Pt(pe),OnlineResource:Pt(Us)}),ld=or(ar,{Keyword:Lc(pe)});class cd{constructor(s,p){!p&&typeof window<"u"&&(p=window.DOMParser),this.version=void 0,this._parser=new gh(p),this._data=s}data(s){return this._data=s,this}toJSON(s){return s=s||this._data,this.parse(s)}parse(s){return this.readFromDocument(this._parser.toDocument(s))}readFromDocument(s){for(let p=s.firstChild;p;p=p.nextSibling)if(p.nodeType==$o.ELEMENT)return this.readFromNode(p);return null}readFromNode(s){return this.version=s.getAttribute("version"),nr({version:this.version},Wh,s,[])||null}}async function ud(m){let s=new URL(m),p=s.searchParams;p.set("SERVICE","WMS"),p.set("REQUEST","GetCapabilities");let b=s.toString();const _=await fetch(b);if(_.ok){const E=await _.text();return new cd(E).toJSON()}else throw new Error(`Error: ${_.status}`)}function Gs(m){const s=/\b(?:wms|ows)\b/i,p=/{(?:z|x|y-?)}\/{(?:z|x|y-?)}\/{(?:z|x|y-?)}/i;return s.test(m)?"TileWMS":p.test(m)?"XYZ":!1}function hd(m){const p=/^(?:(?:https?|ftp):\/\/|\/\/)?(?:localhost|\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}|(?:\w+[\w-]*\.)+\w+)(?::\d+)?(?:\/\S*)?$/.test(m),b=Gs(m);return!!(m&&p&&b)}function Nc(m){return m.replace(/(['"])?([a-zA-Z0-9_]+)(['"])?:/g,'"$2": ').replace(/,\s*}/g,"}").replace(/,\s*]/g,"]").replace(/\s*(\{|}|\[|\]|,)\s*/g,"$1").replaceAll('": //',"://")}function dd(m){try{return JSON.parse(Nc(m)),!!m}catch{return!1}}function pd(m,s){const p=new URL(m).searchParams;Object.entries(s).forEach(([y,j])=>{typeof j=="object"&&!Array.isArray(j)&&j!==null?Object.keys(j).forEach(r=>{p.set(r,j[r])}):p.set(y,j)});const b=m.split("?")[0],_=p.toString();return`${b}?${_}`}/**!
|
|
41
|
-
* Sortable 1.15.
|
|
41
|
+
* Sortable 1.15.2
|
|
42
42
|
* @author RubaXa <trash@rubaxa.org>
|
|
43
43
|
* @author owenm <owen23355@gmail.com>
|
|
44
44
|
* @license MIT
|
|
45
|
-
*/function $c(m,s){var p=Object.keys(m);if(Object.getOwnPropertySymbols){var b=Object.getOwnPropertySymbols(m);s&&(b=b.filter(function(_){return Object.getOwnPropertyDescriptor(m,_).enumerable})),p.push.apply(p,b)}return p}function en(m){for(var s=1;s<arguments.length;s++){var p=arguments[s]!=null?arguments[s]:{};s%2?$c(Object(p),!0).forEach(function(b){fd(m,b,p[b])}):Object.getOwnPropertyDescriptors?Object.defineProperties(m,Object.getOwnPropertyDescriptors(p)):$c(Object(p)).forEach(function(b){Object.defineProperty(m,b,Object.getOwnPropertyDescriptor(p,b))})}return m}function wa(m){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?wa=function(s){return typeof s}:wa=function(s){return s&&typeof Symbol=="function"&&s.constructor===Symbol&&s!==Symbol.prototype?"symbol":typeof s},wa(m)}function fd(m,s,p){return s in m?Object.defineProperty(m,s,{value:p,enumerable:!0,configurable:!0,writable:!0}):m[s]=p,m}function wn(){return wn=Object.assign||function(m){for(var s=1;s<arguments.length;s++){var p=arguments[s];for(var b in p)Object.prototype.hasOwnProperty.call(p,b)&&(m[b]=p[b])}return m},wn.apply(this,arguments)}function md(m,s){if(m==null)return{};var p={},b=Object.keys(m),_,E;for(E=0;E<b.length;E++)_=b[E],!(s.indexOf(_)>=0)&&(p[_]=m[_]);return p}function yd(m,s){if(m==null)return{};var p=md(m,s),b,_;if(Object.getOwnPropertySymbols){var E=Object.getOwnPropertySymbols(m);for(_=0;_<E.length;_++)b=E[_],!(s.indexOf(b)>=0)&&Object.prototype.propertyIsEnumerable.call(m,b)&&(p[b]=m[b])}return p}var bd="1.15.1";function _n(m){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(m)}var xn=_n(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),Mo=_n(/Edge/i),Mc=_n(/firefox/i),Ho=_n(/safari/i)&&!_n(/chrome/i)&&!_n(/android/i),Hc=_n(/iP(ad|od|hone)/i),Fc=_n(/chrome/i)&&_n(/android/i),Vc={capture:!1,passive:!1};function be(m,s,p){m.addEventListener(s,p,!xn&&Vc)}function he(m,s,p){m.removeEventListener(s,p,!xn&&Vc)}function _a(m,s){if(s){if(s[0]===">"&&(s=s.substring(1)),m)try{if(m.matches)return m.matches(s);if(m.msMatchesSelector)return m.msMatchesSelector(s);if(m.webkitMatchesSelector)return m.webkitMatchesSelector(s)}catch{return!1}return!1}}function vd(m){return m.host&&m!==document&&m.host.nodeType?m.host:m.parentNode}function rn(m,s,p,b){if(m){p=p||document;do{if(s!=null&&(s[0]===">"?m.parentNode===p&&_a(m,s):_a(m,s))||b&&m===p)return m;if(m===p)break}while(m=vd(m))}return null}var zc=/\s+/g;function Lr(m,s,p){if(m&&s)if(m.classList)m.classList[p?"add":"remove"](s);else{var b=(" "+m.className+" ").replace(zc," ").replace(" "+s+" "," ");m.className=(b+(p?" "+s:"")).replace(zc," ")}}function Rt(m,s,p){var b=m&&m.style;if(b){if(p===void 0)return document.defaultView&&document.defaultView.getComputedStyle?p=document.defaultView.getComputedStyle(m,""):m.currentStyle&&(p=m.currentStyle),s===void 0?p:p[s];!(s in b)&&s.indexOf("webkit")===-1&&(s="-webkit-"+s),b[s]=p+(typeof p=="string"?"":"px")}}function Li(m,s){var p="";if(typeof m=="string")p=m;else do{var b=Rt(m,"transform");b&&b!=="none"&&(p=b+" "+p)}while(!s&&(m=m.parentNode));var _=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return _&&new _(p)}function Uc(m,s,p){if(m){var b=m.getElementsByTagName(s),_=0,E=b.length;if(p)for(;_<E;_++)p(b[_],_);return b}return[]}function nn(){var m=document.scrollingElement;return m||document.documentElement}function Je(m,s,p,b,_){if(!(!m.getBoundingClientRect&&m!==window)){var E,y,j,r,v,g,w;if(m!==window&&m.parentNode&&m!==nn()?(E=m.getBoundingClientRect(),y=E.top,j=E.left,r=E.bottom,v=E.right,g=E.height,w=E.width):(y=0,j=0,r=window.innerHeight,v=window.innerWidth,g=window.innerHeight,w=window.innerWidth),(s||p)&&m!==window&&(_=_||m.parentNode,!xn))do if(_&&_.getBoundingClientRect&&(Rt(_,"transform")!=="none"||p&&Rt(_,"position")!=="static")){var k=_.getBoundingClientRect();y-=k.top+parseInt(Rt(_,"border-top-width")),j-=k.left+parseInt(Rt(_,"border-left-width")),r=y+E.height,v=j+E.width;break}while(_=_.parentNode);if(b&&m!==window){var O=Li(_||m),C=O&&O.a,S=O&&O.d;O&&(y/=S,j/=C,w/=C,g/=S,r=y+g,v=j+w)}return{top:y,left:j,bottom:r,right:v,width:w,height:g}}}function qc(m){var s=Je(m),p=parseInt(Rt(m,"padding-left")),b=parseInt(Rt(m,"padding-top")),_=parseInt(Rt(m,"padding-right")),E=parseInt(Rt(m,"padding-bottom"));return s.top+=b+parseInt(Rt(m,"border-top-width")),s.left+=p+parseInt(Rt(m,"border-left-width")),s.width=m.clientWidth-p-_,s.height=m.clientHeight-b-E,s.bottom=s.top+s.height,s.right=s.left+s.width,s}function Gc(m,s,p){for(var b=Rn(m,!0),_=Je(m)[s];b;){var E=Je(b)[p],y=void 0;if(p==="top"||p==="left"?y=_>=E:y=_<=E,!y)return b;if(b===nn())break;b=Rn(b,!1)}return!1}function Ri(m,s,p,b){for(var _=0,E=0,y=m.children;E<y.length;){if(y[E].style.display!=="none"&&y[E]!==Ft.ghost&&(b||y[E]!==Ft.dragged)&&rn(y[E],p.draggable,m,!1)){if(_===s)return y[E];_++}E++}return null}function Ws(m,s){for(var p=m.lastElementChild;p&&(p===Ft.ghost||Rt(p,"display")==="none"||s&&!_a(p,s));)p=p.previousElementSibling;return p||null}function $r(m,s){var p=0;if(!m||!m.parentNode)return-1;for(;m=m.previousElementSibling;)m.nodeName.toUpperCase()!=="TEMPLATE"&&m!==Ft.clone&&(!s||_a(m,s))&&p++;return p}function Wc(m){var s=0,p=0,b=nn();if(m)do{var _=Li(m),E=_.a,y=_.d;s+=m.scrollLeft*E,p+=m.scrollTop*y}while(m!==b&&(m=m.parentNode));return[s,p]}function gd(m,s){for(var p in m)if(m.hasOwnProperty(p)){for(var b in s)if(s.hasOwnProperty(b)&&s[b]===m[p][b])return Number(p)}return-1}function Rn(m,s){if(!m||!m.getBoundingClientRect)return nn();var p=m,b=!1;do if(p.clientWidth<p.scrollWidth||p.clientHeight<p.scrollHeight){var _=Rt(p);if(p.clientWidth<p.scrollWidth&&(_.overflowX=="auto"||_.overflowX=="scroll")||p.clientHeight<p.scrollHeight&&(_.overflowY=="auto"||_.overflowY=="scroll")){if(!p.getBoundingClientRect||p===document.body)return nn();if(b||s)return p;b=!0}}while(p=p.parentNode);return nn()}function wd(m,s){if(m&&s)for(var p in s)s.hasOwnProperty(p)&&(m[p]=s[p]);return m}function Zs(m,s){return Math.round(m.top)===Math.round(s.top)&&Math.round(m.left)===Math.round(s.left)&&Math.round(m.height)===Math.round(s.height)&&Math.round(m.width)===Math.round(s.width)}var Fo;function Zc(m,s){return function(){if(!Fo){var p=arguments,b=this;p.length===1?m.call(b,p[0]):m.apply(b,p),Fo=setTimeout(function(){Fo=void 0},s)}}}function _d(){clearTimeout(Fo),Fo=void 0}function Jc(m,s,p){m.scrollLeft+=s,m.scrollTop+=p}function Yc(m){var s=window.Polymer,p=window.jQuery||window.Zepto;return s&&s.dom?s.dom(m).cloneNode(!0):p?p(m).clone(!0)[0]:m.cloneNode(!0)}var Rr="Sortable"+new Date().getTime();function xd(){var m=[],s;return{captureAnimationState:function(){if(m=[],!!this.options.animation){var b=[].slice.call(this.el.children);b.forEach(function(_){if(!(Rt(_,"display")==="none"||_===Ft.ghost)){m.push({target:_,rect:Je(_)});var E=en({},m[m.length-1].rect);if(_.thisAnimationDuration){var y=Li(_,!0);y&&(E.top-=y.f,E.left-=y.e)}_.fromRect=E}})}},addAnimationState:function(b){m.push(b)},removeAnimationState:function(b){m.splice(gd(m,{target:b}),1)},animateAll:function(b){var _=this;if(!this.options.animation){clearTimeout(s),typeof b=="function"&&b();return}var E=!1,y=0;m.forEach(function(j){var r=0,v=j.target,g=v.fromRect,w=Je(v),k=v.prevFromRect,O=v.prevToRect,C=j.rect,S=Li(v,!0);S&&(w.top-=S.f,w.left-=S.e),v.toRect=w,v.thisAnimationDuration&&Zs(k,w)&&!Zs(g,w)&&(C.top-w.top)/(C.left-w.left)===(g.top-w.top)/(g.left-w.left)&&(r=jd(C,k,O,_.options)),Zs(w,g)||(v.prevFromRect=g,v.prevToRect=w,r||(r=_.options.animation),_.animate(v,C,w,r)),r&&(E=!0,y=Math.max(y,r),clearTimeout(v.animationResetTimer),v.animationResetTimer=setTimeout(function(){v.animationTime=0,v.prevFromRect=null,v.fromRect=null,v.prevToRect=null,v.thisAnimationDuration=null},r),v.thisAnimationDuration=r)}),clearTimeout(s),E?s=setTimeout(function(){typeof b=="function"&&b()},y):typeof b=="function"&&b(),m=[]},animate:function(b,_,E,y){if(y){Rt(b,"transition",""),Rt(b,"transform","");var j=Li(this.el),r=j&&j.a,v=j&&j.d,g=(_.left-E.left)/(r||1),w=(_.top-E.top)/(v||1);b.animatingX=!!g,b.animatingY=!!w,Rt(b,"transform","translate3d("+g+"px,"+w+"px,0)"),this.forRepaintDummy=kd(b),Rt(b,"transition","transform "+y+"ms"+(this.options.easing?" "+this.options.easing:"")),Rt(b,"transform","translate3d(0,0,0)"),typeof b.animated=="number"&&clearTimeout(b.animated),b.animated=setTimeout(function(){Rt(b,"transition",""),Rt(b,"transform",""),b.animated=!1,b.animatingX=!1,b.animatingY=!1},y)}}}}function kd(m){return m.offsetWidth}function jd(m,s,p,b){return Math.sqrt(Math.pow(s.top-m.top,2)+Math.pow(s.left-m.left,2))/Math.sqrt(Math.pow(s.top-p.top,2)+Math.pow(s.left-p.left,2))*b.animation}var Ii=[],Js={initializeByDefault:!0},Vo={mount:function(s){for(var p in Js)Js.hasOwnProperty(p)&&!(p in s)&&(s[p]=Js[p]);Ii.forEach(function(b){if(b.pluginName===s.pluginName)throw"Sortable: Cannot mount plugin ".concat(s.pluginName," more than once")}),Ii.push(s)},pluginEvent:function(s,p,b){var _=this;this.eventCanceled=!1,b.cancel=function(){_.eventCanceled=!0};var E=s+"Global";Ii.forEach(function(y){p[y.pluginName]&&(p[y.pluginName][E]&&p[y.pluginName][E](en({sortable:p},b)),p.options[y.pluginName]&&p[y.pluginName][s]&&p[y.pluginName][s](en({sortable:p},b)))})},initializePlugins:function(s,p,b,_){Ii.forEach(function(j){var r=j.pluginName;if(!(!s.options[r]&&!j.initializeByDefault)){var v=new j(s,p,s.options);v.sortable=s,v.options=s.options,s[r]=v,wn(b,v.defaults)}});for(var E in s.options)if(s.options.hasOwnProperty(E)){var y=this.modifyOption(s,E,s.options[E]);typeof y<"u"&&(s.options[E]=y)}},getEventProperties:function(s,p){var b={};return Ii.forEach(function(_){typeof _.eventProperties=="function"&&wn(b,_.eventProperties.call(p[_.pluginName],s))}),b},modifyOption:function(s,p,b){var _;return Ii.forEach(function(E){s[E.pluginName]&&E.optionListeners&&typeof E.optionListeners[p]=="function"&&(_=E.optionListeners[p].call(s[E.pluginName],b))}),_}};function Od(m){var s=m.sortable,p=m.rootEl,b=m.name,_=m.targetEl,E=m.cloneEl,y=m.toEl,j=m.fromEl,r=m.oldIndex,v=m.newIndex,g=m.oldDraggableIndex,w=m.newDraggableIndex,k=m.originalEvent,O=m.putSortable,C=m.extraEventProperties;if(s=s||p&&p[Rr],!!s){var S,T=s.options,A="on"+b.charAt(0).toUpperCase()+b.substr(1);window.CustomEvent&&!xn&&!Mo?S=new CustomEvent(b,{bubbles:!0,cancelable:!0}):(S=document.createEvent("Event"),S.initEvent(b,!0,!0)),S.to=y||p,S.from=j||p,S.item=_||p,S.clone=E,S.oldIndex=r,S.newIndex=v,S.oldDraggableIndex=g,S.newDraggableIndex=w,S.originalEvent=k,S.pullMode=O?O.lastPutMode:void 0;var R=en(en({},C),Vo.getEventProperties(b,s));for(var I in R)S[I]=R[I];p&&p.dispatchEvent(S),T[A]&&T[A].call(s,S)}}var Ed=["evt"],Er=function(s,p){var b=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},_=b.evt,E=yd(b,Ed);Vo.pluginEvent.bind(Ft)(s,p,en({dragEl:ht,parentEl:Ve,ghostEl:Yt,rootEl:Ie,nextEl:ai,lastDownEl:xa,cloneEl:De,cloneHidden:In,dragStarted:Uo,putSortable:sr,activeSortable:Ft.active,originalEvent:_,oldIndex:Bi,oldDraggableIndex:zo,newIndex:Ir,newDraggableIndex:Bn,hideGhostForTarget:nu,unhideGhostForTarget:iu,cloneNowHidden:function(){In=!0},cloneNowShown:function(){In=!1},dispatchSortableEvent:function(j){_r({sortable:p,name:j,originalEvent:_})}},E))};function _r(m){Od(en({putSortable:sr,cloneEl:De,targetEl:ht,rootEl:Ie,oldIndex:Bi,oldDraggableIndex:zo,newIndex:Ir,newDraggableIndex:Bn},m))}var ht,Ve,Yt,Ie,ai,xa,De,In,Bi,Ir,zo,Bn,ka,sr,Di=!1,ja=!1,Oa=[],si,Gr,Ys,Xs,Xc,Kc,Uo,Ni,qo,Go=!1,Ea=!1,Ca,hr,Ks=[],Qs=!1,Sa=[],Pa=typeof document<"u",Ta=Hc,Qc=Mo||xn?"cssFloat":"float",Cd=Pa&&!Fc&&!Hc&&"draggable"in document.createElement("div"),tu=function(){if(Pa){if(xn)return!1;var m=document.createElement("x");return m.style.cssText="pointer-events:auto",m.style.pointerEvents==="auto"}}(),eu=function(s,p){var b=Rt(s),_=parseInt(b.width)-parseInt(b.paddingLeft)-parseInt(b.paddingRight)-parseInt(b.borderLeftWidth)-parseInt(b.borderRightWidth),E=Ri(s,0,p),y=Ri(s,1,p),j=E&&Rt(E),r=y&&Rt(y),v=j&&parseInt(j.marginLeft)+parseInt(j.marginRight)+Je(E).width,g=r&&parseInt(r.marginLeft)+parseInt(r.marginRight)+Je(y).width;if(b.display==="flex")return b.flexDirection==="column"||b.flexDirection==="column-reverse"?"vertical":"horizontal";if(b.display==="grid")return b.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(E&&j.float&&j.float!=="none"){var w=j.float==="left"?"left":"right";return y&&(r.clear==="both"||r.clear===w)?"vertical":"horizontal"}return E&&(j.display==="block"||j.display==="flex"||j.display==="table"||j.display==="grid"||v>=_&&b[Qc]==="none"||y&&b[Qc]==="none"&&v+g>_)?"vertical":"horizontal"},Sd=function(s,p,b){var _=b?s.left:s.top,E=b?s.right:s.bottom,y=b?s.width:s.height,j=b?p.left:p.top,r=b?p.right:p.bottom,v=b?p.width:p.height;return _===j||E===r||_+y/2===j+v/2},Pd=function(s,p){var b;return Oa.some(function(_){var E=_[Rr].options.emptyInsertThreshold;if(!(!E||Ws(_))){var y=Je(_),j=s>=y.left-E&&s<=y.right+E,r=p>=y.top-E&&p<=y.bottom+E;if(j&&r)return b=_}}),b},ru=function(s){function p(E,y){return function(j,r,v,g){var w=j.options.group.name&&r.options.group.name&&j.options.group.name===r.options.group.name;if(E==null&&(y||w))return!0;if(E==null||E===!1)return!1;if(y&&E==="clone")return E;if(typeof E=="function")return p(E(j,r,v,g),y)(j,r,v,g);var k=(y?j:r).options.group.name;return E===!0||typeof E=="string"&&E===k||E.join&&E.indexOf(k)>-1}}var b={},_=s.group;(!_||wa(_)!="object")&&(_={name:_}),b.name=_.name,b.checkPull=p(_.pull,!0),b.checkPut=p(_.put),b.revertClone=_.revertClone,s.group=b},nu=function(){!tu&&Yt&&Rt(Yt,"display","none")},iu=function(){!tu&&Yt&&Rt(Yt,"display","")};Pa&&!Fc&&document.addEventListener("click",function(m){if(ja)return m.preventDefault(),m.stopPropagation&&m.stopPropagation(),m.stopImmediatePropagation&&m.stopImmediatePropagation(),ja=!1,!1},!0);var li=function(s){if(ht){s=s.touches?s.touches[0]:s;var p=Pd(s.clientX,s.clientY);if(p){var b={};for(var _ in s)s.hasOwnProperty(_)&&(b[_]=s[_]);b.target=b.rootEl=p,b.preventDefault=void 0,b.stopPropagation=void 0,p[Rr]._onDragOver(b)}}},Td=function(s){ht&&ht.parentNode[Rr]._isOutsideThisEl(s.target)};function Ft(m,s){if(!(m&&m.nodeType&&m.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(m));this.el=m,this.options=s=wn({},s),m[Rr]=this;var p={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(m.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return eu(m,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(y,j){y.setData("Text",j.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:Ft.supportPointer!==!1&&"PointerEvent"in window&&!Ho,emptyInsertThreshold:5};Vo.initializePlugins(this,m,p);for(var b in p)!(b in s)&&(s[b]=p[b]);ru(s);for(var _ in this)_.charAt(0)==="_"&&typeof this[_]=="function"&&(this[_]=this[_].bind(this));this.nativeDraggable=s.forceFallback?!1:Cd,this.nativeDraggable&&(this.options.touchStartThreshold=1),s.supportPointer?be(m,"pointerdown",this._onTapStart):(be(m,"mousedown",this._onTapStart),be(m,"touchstart",this._onTapStart)),this.nativeDraggable&&(be(m,"dragover",this),be(m,"dragenter",this)),Oa.push(this.el),s.store&&s.store.get&&this.sort(s.store.get(this)||[]),wn(this,xd())}Ft.prototype={constructor:Ft,_isOutsideThisEl:function(s){!this.el.contains(s)&&s!==this.el&&(Ni=null)},_getDirection:function(s,p){return typeof this.options.direction=="function"?this.options.direction.call(this,s,p,ht):this.options.direction},_onTapStart:function(s){if(s.cancelable){var p=this,b=this.el,_=this.options,E=_.preventOnFilter,y=s.type,j=s.touches&&s.touches[0]||s.pointerType&&s.pointerType==="touch"&&s,r=(j||s).target,v=s.target.shadowRoot&&(s.path&&s.path[0]||s.composedPath&&s.composedPath()[0])||r,g=_.filter;if($d(b),!ht&&!(/mousedown|pointerdown/.test(y)&&s.button!==0||_.disabled)&&!v.isContentEditable&&!(!this.nativeDraggable&&Ho&&r&&r.tagName.toUpperCase()==="SELECT")&&(r=rn(r,_.draggable,b,!1),!(r&&r.animated)&&xa!==r)){if(Bi=$r(r),zo=$r(r,_.draggable),typeof g=="function"){if(g.call(this,s,r,this)){_r({sortable:p,rootEl:v,name:"filter",targetEl:r,toEl:b,fromEl:b}),Er("filter",p,{evt:s}),E&&s.cancelable&&s.preventDefault();return}}else if(g&&(g=g.split(",").some(function(w){if(w=rn(v,w.trim(),b,!1),w)return _r({sortable:p,rootEl:w,name:"filter",targetEl:r,fromEl:b,toEl:b}),Er("filter",p,{evt:s}),!0}),g)){E&&s.cancelable&&s.preventDefault();return}_.handle&&!rn(v,_.handle,b,!1)||this._prepareDragStart(s,j,r)}}},_prepareDragStart:function(s,p,b){var _=this,E=_.el,y=_.options,j=E.ownerDocument,r;if(b&&!ht&&b.parentNode===E){var v=Je(b);if(Ie=E,ht=b,Ve=ht.parentNode,ai=ht.nextSibling,xa=b,ka=y.group,Ft.dragged=ht,si={target:ht,clientX:(p||s).clientX,clientY:(p||s).clientY},Xc=si.clientX-v.left,Kc=si.clientY-v.top,this._lastX=(p||s).clientX,this._lastY=(p||s).clientY,ht.style["will-change"]="all",r=function(){if(Er("delayEnded",_,{evt:s}),Ft.eventCanceled){_._onDrop();return}_._disableDelayedDragEvents(),!Mc&&_.nativeDraggable&&(ht.draggable=!0),_._triggerDragStart(s,p),_r({sortable:_,name:"choose",originalEvent:s}),Lr(ht,y.chosenClass,!0)},y.ignore.split(",").forEach(function(g){Uc(ht,g.trim(),tl)}),be(j,"dragover",li),be(j,"mousemove",li),be(j,"touchmove",li),be(j,"mouseup",_._onDrop),be(j,"touchend",_._onDrop),be(j,"touchcancel",_._onDrop),Mc&&this.nativeDraggable&&(this.options.touchStartThreshold=4,ht.draggable=!0),Er("delayStart",this,{evt:s}),y.delay&&(!y.delayOnTouchOnly||p)&&(!this.nativeDraggable||!(Mo||xn))){if(Ft.eventCanceled){this._onDrop();return}be(j,"mouseup",_._disableDelayedDrag),be(j,"touchend",_._disableDelayedDrag),be(j,"touchcancel",_._disableDelayedDrag),be(j,"mousemove",_._delayedDragTouchMoveHandler),be(j,"touchmove",_._delayedDragTouchMoveHandler),y.supportPointer&&be(j,"pointermove",_._delayedDragTouchMoveHandler),_._dragStartTimer=setTimeout(r,y.delay)}else r()}},_delayedDragTouchMoveHandler:function(s){var p=s.touches?s.touches[0]:s;Math.max(Math.abs(p.clientX-this._lastX),Math.abs(p.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){ht&&tl(ht),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var s=this.el.ownerDocument;he(s,"mouseup",this._disableDelayedDrag),he(s,"touchend",this._disableDelayedDrag),he(s,"touchcancel",this._disableDelayedDrag),he(s,"mousemove",this._delayedDragTouchMoveHandler),he(s,"touchmove",this._delayedDragTouchMoveHandler),he(s,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(s,p){p=p||s.pointerType=="touch"&&s,!this.nativeDraggable||p?this.options.supportPointer?be(document,"pointermove",this._onTouchMove):p?be(document,"touchmove",this._onTouchMove):be(document,"mousemove",this._onTouchMove):(be(ht,"dragend",this),be(Ie,"dragstart",this._onDragStart));try{document.selection?La(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(s,p){if(Di=!1,Ie&&ht){Er("dragStarted",this,{evt:p}),this.nativeDraggable&&be(document,"dragover",Td);var b=this.options;!s&&Lr(ht,b.dragClass,!1),Lr(ht,b.ghostClass,!0),Ft.active=this,s&&this._appendGhost(),_r({sortable:this,name:"start",originalEvent:p})}else this._nulling()},_emulateDragOver:function(){if(Gr){this._lastX=Gr.clientX,this._lastY=Gr.clientY,nu();for(var s=document.elementFromPoint(Gr.clientX,Gr.clientY),p=s;s&&s.shadowRoot&&(s=s.shadowRoot.elementFromPoint(Gr.clientX,Gr.clientY),s!==p);)p=s;if(ht.parentNode[Rr]._isOutsideThisEl(s),p)do{if(p[Rr]){var b=void 0;if(b=p[Rr]._onDragOver({clientX:Gr.clientX,clientY:Gr.clientY,target:s,rootEl:p}),b&&!this.options.dragoverBubble)break}s=p}while(p=p.parentNode);iu()}},_onTouchMove:function(s){if(si){var p=this.options,b=p.fallbackTolerance,_=p.fallbackOffset,E=s.touches?s.touches[0]:s,y=Yt&&Li(Yt,!0),j=Yt&&y&&y.a,r=Yt&&y&&y.d,v=Ta&&hr&&Wc(hr),g=(E.clientX-si.clientX+_.x)/(j||1)+(v?v[0]-Ks[0]:0)/(j||1),w=(E.clientY-si.clientY+_.y)/(r||1)+(v?v[1]-Ks[1]:0)/(r||1);if(!Ft.active&&!Di){if(b&&Math.max(Math.abs(E.clientX-this._lastX),Math.abs(E.clientY-this._lastY))<b)return;this._onDragStart(s,!0)}if(Yt){y?(y.e+=g-(Ys||0),y.f+=w-(Xs||0)):y={a:1,b:0,c:0,d:1,e:g,f:w};var k="matrix(".concat(y.a,",").concat(y.b,",").concat(y.c,",").concat(y.d,",").concat(y.e,",").concat(y.f,")");Rt(Yt,"webkitTransform",k),Rt(Yt,"mozTransform",k),Rt(Yt,"msTransform",k),Rt(Yt,"transform",k),Ys=g,Xs=w,Gr=E}s.cancelable&&s.preventDefault()}},_appendGhost:function(){if(!Yt){var s=this.options.fallbackOnBody?document.body:Ie,p=Je(ht,!0,Ta,!0,s),b=this.options;if(Ta){for(hr=s;Rt(hr,"position")==="static"&&Rt(hr,"transform")==="none"&&hr!==document;)hr=hr.parentNode;hr!==document.body&&hr!==document.documentElement?(hr===document&&(hr=nn()),p.top+=hr.scrollTop,p.left+=hr.scrollLeft):hr=nn(),Ks=Wc(hr)}Yt=ht.cloneNode(!0),Lr(Yt,b.ghostClass,!1),Lr(Yt,b.fallbackClass,!0),Lr(Yt,b.dragClass,!0),Rt(Yt,"transition",""),Rt(Yt,"transform",""),Rt(Yt,"box-sizing","border-box"),Rt(Yt,"margin",0),Rt(Yt,"top",p.top),Rt(Yt,"left",p.left),Rt(Yt,"width",p.width),Rt(Yt,"height",p.height),Rt(Yt,"opacity","0.8"),Rt(Yt,"position",Ta?"absolute":"fixed"),Rt(Yt,"zIndex","100000"),Rt(Yt,"pointerEvents","none"),Ft.ghost=Yt,s.appendChild(Yt),Rt(Yt,"transform-origin",Xc/parseInt(Yt.style.width)*100+"% "+Kc/parseInt(Yt.style.height)*100+"%")}},_onDragStart:function(s,p){var b=this,_=s.dataTransfer,E=b.options;if(Er("dragStart",this,{evt:s}),Ft.eventCanceled){this._onDrop();return}Er("setupClone",this),Ft.eventCanceled||(De=Yc(ht),De.removeAttribute("id"),De.draggable=!1,De.style["will-change"]="",this._hideClone(),Lr(De,this.options.chosenClass,!1),Ft.clone=De),b.cloneId=La(function(){Er("clone",b),!Ft.eventCanceled&&(b.options.removeCloneOnHide||Ie.insertBefore(De,ht),b._hideClone(),_r({sortable:b,name:"clone"}))}),!p&&Lr(ht,E.dragClass,!0),p?(ja=!0,b._loopId=setInterval(b._emulateDragOver,50)):(he(document,"mouseup",b._onDrop),he(document,"touchend",b._onDrop),he(document,"touchcancel",b._onDrop),_&&(_.effectAllowed="move",E.setData&&E.setData.call(b,_,ht)),be(document,"drop",b),Rt(ht,"transform","translateZ(0)")),Di=!0,b._dragStartId=La(b._dragStarted.bind(b,p,s)),be(document,"selectstart",b),Uo=!0,Ho&&Rt(document.body,"user-select","none")},_onDragOver:function(s){var p=this.el,b=s.target,_,E,y,j=this.options,r=j.group,v=Ft.active,g=ka===r,w=j.sort,k=sr||v,O,C=this,S=!1;if(Qs)return;function T(yt,ct){Er(yt,C,en({evt:s,isOwner:g,axis:O?"vertical":"horizontal",revert:y,dragRect:_,targetRect:E,canSort:w,fromSortable:k,target:b,completed:R,onMove:function(At,Vt){return Aa(Ie,p,ht,_,At,Je(At),s,Vt)},changed:I},ct))}function A(){T("dragOverAnimationCapture"),C.captureAnimationState(),C!==k&&k.captureAnimationState()}function R(yt){return T("dragOverCompleted",{insertion:yt}),yt&&(g?v._hideClone():v._showClone(C),C!==k&&(Lr(ht,sr?sr.options.ghostClass:v.options.ghostClass,!1),Lr(ht,j.ghostClass,!0)),sr!==C&&C!==Ft.active?sr=C:C===Ft.active&&sr&&(sr=null),k===C&&(C._ignoreWhileAnimating=b),C.animateAll(function(){T("dragOverAnimationComplete"),C._ignoreWhileAnimating=null}),C!==k&&(k.animateAll(),k._ignoreWhileAnimating=null)),(b===ht&&!ht.animated||b===p&&!b.animated)&&(Ni=null),!j.dragoverBubble&&!s.rootEl&&b!==document&&(ht.parentNode[Rr]._isOutsideThisEl(s.target),!yt&&li(s)),!j.dragoverBubble&&s.stopPropagation&&s.stopPropagation(),S=!0}function I(){Ir=$r(ht),Bn=$r(ht,j.draggable),_r({sortable:C,name:"change",toEl:p,newIndex:Ir,newDraggableIndex:Bn,originalEvent:s})}if(s.preventDefault!==void 0&&s.cancelable&&s.preventDefault(),b=rn(b,j.draggable,p,!0),T("dragOver"),Ft.eventCanceled)return S;if(ht.contains(s.target)||b.animated&&b.animatingX&&b.animatingY||C._ignoreWhileAnimating===b)return R(!1);if(ja=!1,v&&!j.disabled&&(g?w||(y=Ve!==Ie):sr===this||(this.lastPutMode=ka.checkPull(this,v,ht,s))&&r.checkPut(this,v,ht,s))){if(O=this._getDirection(s,b)==="vertical",_=Je(ht),T("dragOverValid"),Ft.eventCanceled)return S;if(y)return Ve=Ie,A(),this._hideClone(),T("revert"),Ft.eventCanceled||(ai?Ie.insertBefore(ht,ai):Ie.appendChild(ht)),R(!0);var $=Ws(p,j.draggable);if(!$||Id(s,O,this)&&!$.animated){if($===ht)return R(!1);if($&&p===s.target&&(b=$),b&&(E=Je(b)),Aa(Ie,p,ht,_,b,E,s,!!b)!==!1)return A(),$&&$.nextSibling?p.insertBefore(ht,$.nextSibling):p.appendChild(ht),Ve=p,I(),R(!0)}else if($&&Rd(s,O,this)){var M=Ri(p,0,j,!0);if(M===ht)return R(!1);if(b=M,E=Je(b),Aa(Ie,p,ht,_,b,E,s,!1)!==!1)return A(),p.insertBefore(ht,M),Ve=p,I(),R(!0)}else if(b.parentNode===p){E=Je(b);var B=0,q,F=ht.parentNode!==p,N=!Sd(ht.animated&&ht.toRect||_,b.animated&&b.toRect||E,O),U=O?"top":"left",H=Gc(b,"top","top")||Gc(ht,"top","top"),X=H?H.scrollTop:void 0;Ni!==b&&(q=E[U],Go=!1,Ea=!N&&j.invertSwap||F),B=Bd(s,b,E,O,N?1:j.swapThreshold,j.invertedSwapThreshold==null?j.swapThreshold:j.invertedSwapThreshold,Ea,Ni===b);var Y;if(B!==0){var K=$r(ht);do K-=B,Y=Ve.children[K];while(Y&&(Rt(Y,"display")==="none"||Y===Yt))}if(B===0||Y===b)return R(!1);Ni=b,qo=B;var tt=b.nextElementSibling,it=!1;it=B===1;var st=Aa(Ie,p,ht,_,b,E,s,it);if(st!==!1)return(st===1||st===-1)&&(it=st===1),Qs=!0,setTimeout(Ld,30),A(),it&&!tt?p.appendChild(ht):b.parentNode.insertBefore(ht,it?tt:b),H&&Jc(H,0,X-H.scrollTop),Ve=ht.parentNode,q!==void 0&&!Ea&&(Ca=Math.abs(q-Je(b)[U])),I(),R(!0)}if(p.contains(ht))return R(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){he(document,"mousemove",this._onTouchMove),he(document,"touchmove",this._onTouchMove),he(document,"pointermove",this._onTouchMove),he(document,"dragover",li),he(document,"mousemove",li),he(document,"touchmove",li)},_offUpEvents:function(){var s=this.el.ownerDocument;he(s,"mouseup",this._onDrop),he(s,"touchend",this._onDrop),he(s,"pointerup",this._onDrop),he(s,"touchcancel",this._onDrop),he(document,"selectstart",this)},_onDrop:function(s){var p=this.el,b=this.options;if(Ir=$r(ht),Bn=$r(ht,b.draggable),Er("drop",this,{evt:s}),Ve=ht&&ht.parentNode,Ir=$r(ht),Bn=$r(ht,b.draggable),Ft.eventCanceled){this._nulling();return}Di=!1,Ea=!1,Go=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),el(this.cloneId),el(this._dragStartId),this.nativeDraggable&&(he(document,"drop",this),he(p,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),Ho&&Rt(document.body,"user-select",""),Rt(ht,"transform",""),s&&(Uo&&(s.cancelable&&s.preventDefault(),!b.dropBubble&&s.stopPropagation()),Yt&&Yt.parentNode&&Yt.parentNode.removeChild(Yt),(Ie===Ve||sr&&sr.lastPutMode!=="clone")&&De&&De.parentNode&&De.parentNode.removeChild(De),ht&&(this.nativeDraggable&&he(ht,"dragend",this),tl(ht),ht.style["will-change"]="",Uo&&!Di&&Lr(ht,sr?sr.options.ghostClass:this.options.ghostClass,!1),Lr(ht,this.options.chosenClass,!1),_r({sortable:this,name:"unchoose",toEl:Ve,newIndex:null,newDraggableIndex:null,originalEvent:s}),Ie!==Ve?(Ir>=0&&(_r({rootEl:Ve,name:"add",toEl:Ve,fromEl:Ie,originalEvent:s}),_r({sortable:this,name:"remove",toEl:Ve,originalEvent:s}),_r({rootEl:Ve,name:"sort",toEl:Ve,fromEl:Ie,originalEvent:s}),_r({sortable:this,name:"sort",toEl:Ve,originalEvent:s})),sr&&sr.save()):Ir!==Bi&&Ir>=0&&(_r({sortable:this,name:"update",toEl:Ve,originalEvent:s}),_r({sortable:this,name:"sort",toEl:Ve,originalEvent:s})),Ft.active&&((Ir==null||Ir===-1)&&(Ir=Bi,Bn=zo),_r({sortable:this,name:"end",toEl:Ve,originalEvent:s}),this.save()))),this._nulling()},_nulling:function(){Er("nulling",this),Ie=ht=Ve=Yt=ai=De=xa=In=si=Gr=Uo=Ir=Bn=Bi=zo=Ni=qo=sr=ka=Ft.dragged=Ft.ghost=Ft.clone=Ft.active=null,Sa.forEach(function(s){s.checked=!0}),Sa.length=Ys=Xs=0},handleEvent:function(s){switch(s.type){case"drop":case"dragend":this._onDrop(s);break;case"dragenter":case"dragover":ht&&(this._onDragOver(s),Ad(s));break;case"selectstart":s.preventDefault();break}},toArray:function(){for(var s=[],p,b=this.el.children,_=0,E=b.length,y=this.options;_<E;_++)p=b[_],rn(p,y.draggable,this.el,!1)&&s.push(p.getAttribute(y.dataIdAttr)||Nd(p));return s},sort:function(s,p){var b={},_=this.el;this.toArray().forEach(function(E,y){var j=_.children[y];rn(j,this.options.draggable,_,!1)&&(b[E]=j)},this),p&&this.captureAnimationState(),s.forEach(function(E){b[E]&&(_.removeChild(b[E]),_.appendChild(b[E]))}),p&&this.animateAll()},save:function(){var s=this.options.store;s&&s.set&&s.set(this)},closest:function(s,p){return rn(s,p||this.options.draggable,this.el,!1)},option:function(s,p){var b=this.options;if(p===void 0)return b[s];var _=Vo.modifyOption(this,s,p);typeof _<"u"?b[s]=_:b[s]=p,s==="group"&&ru(b)},destroy:function(){Er("destroy",this);var s=this.el;s[Rr]=null,he(s,"mousedown",this._onTapStart),he(s,"touchstart",this._onTapStart),he(s,"pointerdown",this._onTapStart),this.nativeDraggable&&(he(s,"dragover",this),he(s,"dragenter",this)),Array.prototype.forEach.call(s.querySelectorAll("[draggable]"),function(p){p.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),Oa.splice(Oa.indexOf(this.el),1),this.el=s=null},_hideClone:function(){if(!In){if(Er("hideClone",this),Ft.eventCanceled)return;Rt(De,"display","none"),this.options.removeCloneOnHide&&De.parentNode&&De.parentNode.removeChild(De),In=!0}},_showClone:function(s){if(s.lastPutMode!=="clone"){this._hideClone();return}if(In){if(Er("showClone",this),Ft.eventCanceled)return;ht.parentNode==Ie&&!this.options.group.revertClone?Ie.insertBefore(De,ht):ai?Ie.insertBefore(De,ai):Ie.appendChild(De),this.options.group.revertClone&&this.animate(ht,De),Rt(De,"display",""),In=!1}}};function Ad(m){m.dataTransfer&&(m.dataTransfer.dropEffect="move"),m.cancelable&&m.preventDefault()}function Aa(m,s,p,b,_,E,y,j){var r,v=m[Rr],g=v.options.onMove,w;return window.CustomEvent&&!xn&&!Mo?r=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(r=document.createEvent("Event"),r.initEvent("move",!0,!0)),r.to=s,r.from=m,r.dragged=p,r.draggedRect=b,r.related=_||s,r.relatedRect=E||Je(s),r.willInsertAfter=j,r.originalEvent=y,m.dispatchEvent(r),g&&(w=g.call(v,r,y)),w}function tl(m){m.draggable=!1}function Ld(){Qs=!1}function Rd(m,s,p){var b=Je(Ri(p.el,0,p.options,!0)),_=qc(p.el),E=10;return s?m.clientX<_.left-E||m.clientY<b.top&&m.clientX<b.right:m.clientY<_.top-E||m.clientY<b.bottom&&m.clientX<b.left}function Id(m,s,p){var b=Je(Ws(p.el,p.options.draggable)),_=qc(p.el),E=10;return s?m.clientX>_.right+E||m.clientY>b.bottom&&m.clientX>b.left:m.clientY>_.bottom+E||m.clientX>b.right&&m.clientY>b.top}function Bd(m,s,p,b,_,E,y,j){var r=b?m.clientY:m.clientX,v=b?p.height:p.width,g=b?p.top:p.left,w=b?p.bottom:p.right,k=!1;if(!y){if(j&&Ca<v*_){if(!Go&&(qo===1?r>g+v*E/2:r<w-v*E/2)&&(Go=!0),Go)k=!0;else if(qo===1?r<g+Ca:r>w-Ca)return-qo}else if(r>g+v*(1-_)/2&&r<w-v*(1-_)/2)return Dd(s)}return k=k||y,k&&(r<g+v*E/2||r>w-v*E/2)?r>g+v/2?1:-1:0}function Dd(m){return $r(ht)<$r(m)?1:-1}function Nd(m){for(var s=m.tagName+m.className+m.src+m.href+m.textContent,p=s.length,b=0;p--;)b+=s.charCodeAt(p);return b.toString(36)}function $d(m){Sa.length=0;for(var s=m.getElementsByTagName("input"),p=s.length;p--;){var b=s[p];b.checked&&Sa.push(b)}}function La(m){return setTimeout(m,0)}function el(m){return clearTimeout(m)}Pa&&be(document,"touchmove",function(m){(Ft.active||Di)&&m.cancelable&&m.preventDefault()}),Ft.utils={on:be,off:he,css:Rt,find:Uc,is:function(s,p){return!!rn(s,p,s,!1)},extend:wd,throttle:Zc,closest:rn,toggleClass:Lr,clone:Yc,index:$r,nextTick:La,cancelNextTick:el,detectDirection:eu,getChild:Ri},Ft.get=function(m){return m[Rr]},Ft.mount=function(){for(var m=arguments.length,s=new Array(m),p=0;p<m;p++)s[p]=arguments[p];s[0].constructor===Array&&(s=s[0]),s.forEach(function(b){if(!b.prototype||!b.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(b));b.utils&&(Ft.utils=en(en({},Ft.utils),b.utils)),Vo.mount(b)})},Ft.create=function(m,s){return new Ft(m,s)},Ft.version=bd;var Ye=[],Wo,rl,nl=!1,il,ol,Ra,Zo;function Md(){function m(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var s in this)s.charAt(0)==="_"&&typeof this[s]=="function"&&(this[s]=this[s].bind(this))}return m.prototype={dragStarted:function(p){var b=p.originalEvent;this.sortable.nativeDraggable?be(document,"dragover",this._handleAutoScroll):this.options.supportPointer?be(document,"pointermove",this._handleFallbackAutoScroll):b.touches?be(document,"touchmove",this._handleFallbackAutoScroll):be(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(p){var b=p.originalEvent;!this.options.dragOverBubble&&!b.rootEl&&this._handleAutoScroll(b)},drop:function(){this.sortable.nativeDraggable?he(document,"dragover",this._handleAutoScroll):(he(document,"pointermove",this._handleFallbackAutoScroll),he(document,"touchmove",this._handleFallbackAutoScroll),he(document,"mousemove",this._handleFallbackAutoScroll)),ou(),Ia(),_d()},nulling:function(){Ra=rl=Wo=nl=Zo=il=ol=null,Ye.length=0},_handleFallbackAutoScroll:function(p){this._handleAutoScroll(p,!0)},_handleAutoScroll:function(p,b){var _=this,E=(p.touches?p.touches[0]:p).clientX,y=(p.touches?p.touches[0]:p).clientY,j=document.elementFromPoint(E,y);if(Ra=p,b||this.options.forceAutoScrollFallback||Mo||xn||Ho){al(p,this.options,j,b);var r=Rn(j,!0);nl&&(!Zo||E!==il||y!==ol)&&(Zo&&ou(),Zo=setInterval(function(){var v=Rn(document.elementFromPoint(E,y),!0);v!==r&&(r=v,Ia()),al(p,_.options,v,b)},10),il=E,ol=y)}else{if(!this.options.bubbleScroll||Rn(j,!0)===nn()){Ia();return}al(p,this.options,Rn(j,!1),!1)}}},wn(m,{pluginName:"scroll",initializeByDefault:!0})}function Ia(){Ye.forEach(function(m){clearInterval(m.pid)}),Ye=[]}function ou(){clearInterval(Zo)}var al=Zc(function(m,s,p,b){if(s.scroll){var _=(m.touches?m.touches[0]:m).clientX,E=(m.touches?m.touches[0]:m).clientY,y=s.scrollSensitivity,j=s.scrollSpeed,r=nn(),v=!1,g;rl!==p&&(rl=p,Ia(),Wo=s.scroll,g=s.scrollFn,Wo===!0&&(Wo=Rn(p,!0)));var w=0,k=Wo;do{var O=k,C=Je(O),S=C.top,T=C.bottom,A=C.left,R=C.right,I=C.width,$=C.height,M=void 0,B=void 0,q=O.scrollWidth,F=O.scrollHeight,N=Rt(O),U=O.scrollLeft,H=O.scrollTop;O===r?(M=I<q&&(N.overflowX==="auto"||N.overflowX==="scroll"||N.overflowX==="visible"),B=$<F&&(N.overflowY==="auto"||N.overflowY==="scroll"||N.overflowY==="visible")):(M=I<q&&(N.overflowX==="auto"||N.overflowX==="scroll"),B=$<F&&(N.overflowY==="auto"||N.overflowY==="scroll"));var X=M&&(Math.abs(R-_)<=y&&U+I<q)-(Math.abs(A-_)<=y&&!!U),Y=B&&(Math.abs(T-E)<=y&&H+$<F)-(Math.abs(S-E)<=y&&!!H);if(!Ye[w])for(var K=0;K<=w;K++)Ye[K]||(Ye[K]={});(Ye[w].vx!=X||Ye[w].vy!=Y||Ye[w].el!==O)&&(Ye[w].el=O,Ye[w].vx=X,Ye[w].vy=Y,clearInterval(Ye[w].pid),(X!=0||Y!=0)&&(v=!0,Ye[w].pid=setInterval((function(){b&&this.layer===0&&Ft.active._onTouchMove(Ra);var tt=Ye[this.layer].vy?Ye[this.layer].vy*j:0,it=Ye[this.layer].vx?Ye[this.layer].vx*j:0;typeof g=="function"&&g.call(Ft.dragged.parentNode[Rr],it,tt,m,Ra,Ye[this.layer].el)!=="continue"||Jc(Ye[this.layer].el,it,tt)}).bind({layer:w}),24))),w++}while(s.bubbleScroll&&k!==r&&(k=Rn(k,!1)));nl=v}},30),au=function(s){var p=s.originalEvent,b=s.putSortable,_=s.dragEl,E=s.activeSortable,y=s.dispatchSortableEvent,j=s.hideGhostForTarget,r=s.unhideGhostForTarget;if(p){var v=b||E;j();var g=p.changedTouches&&p.changedTouches.length?p.changedTouches[0]:p,w=document.elementFromPoint(g.clientX,g.clientY);r(),v&&!v.el.contains(w)&&(y("spill"),this.onSpill({dragEl:_,putSortable:b}))}};function sl(){}sl.prototype={startIndex:null,dragStart:function(s){var p=s.oldDraggableIndex;this.startIndex=p},onSpill:function(s){var p=s.dragEl,b=s.putSortable;this.sortable.captureAnimationState(),b&&b.captureAnimationState();var _=Ri(this.sortable.el,this.startIndex,this.options);_?this.sortable.el.insertBefore(p,_):this.sortable.el.appendChild(p),this.sortable.animateAll(),b&&b.animateAll()},drop:au},wn(sl,{pluginName:"revertOnSpill"});function ll(){}ll.prototype={onSpill:function(s){var p=s.dragEl,b=s.putSortable,_=b||this.sortable;_.captureAnimationState(),p.parentNode&&p.parentNode.removeChild(p),_.animateAll()},drop:au},wn(ll,{pluginName:"removeOnSpill"}),Ft.mount(new Md),Ft.mount(ll,sl);const Hd=m=>{const s=m.item;let p=Array.prototype.slice.call(s.parentNode.childNodes);return p=p.filter(b=>b.nodeType!=Node.ELEMENT_NODE||!b.classList.contains("sortable-fallback")),p},Fd=(m,s,p,b,_,E)=>{const j=m.item.parentNode;for(const S of p)j.appendChild(S);if(m.oldIndex==m.newIndex)return;const r=b.getArray(),v=m.item.querySelector("eox-layercontrol-layer").layer.get(_),g=r.find(S=>S.get(_)===v),w=E.dataset.layer,k=r.find(S=>S.get(_)==w);let O,C;for(O=0;O<r.length;O++)if(r[O]==g){b.removeAt(O);break}for(C=0;C<r.length;C++)if(r[C]===k){O>C?b.insertAt(C,g):b.insertAt(C+1,g);break}s.requestUpdate()};function Vd(m,s,p,b){let _=[],E=null;m._sortable=Ft.create(m,{handle:".drag-handle",filter:".drag-handle.disabled",swapThreshold:.5,animation:150,easing:"cubic-bezier(1, 0, 0, 1)",onStart:y=>_=Hd(y),onMove:y=>{E=y.related},onEnd:y=>Fd(y,b,_,s,p,E)})}function zd(m,s,p){m.getArray().forEach(_=>{const E=_.ol_uid;_.get(s)||_.set(s,E),_.get(p)||_.set(p,`layer ${E}`)})}function cl(m,s,p){let b=[];const _=(E,y,j)=>{b=[...b,...E.filter(v=>v.get(y)===j)];const r=E.filter(v=>v.getLayers);return r.length>0&&r.forEach(v=>_(v.getLayers().getArray(),y,j)),b};return _(m,s,p),b}function Ud(m,s,p){if(!m||!s)return!1;if(!su(m,p))return!0;const b=m.get("minZoom"),_=m.get("maxZoom"),E=s.getView().getZoom();return E>b&&E<_}function su(m,s){const p=m.get("minZoom"),b=m.get("maxZoom");return!!(s&&(p!==-1/0||b!==1/0))}function qd(m,s){var _,E,y;return!m||!s?void 0:m.getLayers?"group":((y=(_=s.getInteractions().getArray().filter(j=>j.freehand_!==void 0).map(j=>j.source_))==null?void 0:_.ol_uid)==null?void 0:y.includes(m.getSource?(E=m.getSource())==null?void 0:E.ol_uid:void 0))?"draw":m.declutter_!==void 0?"vector":"raster"}function lu(m,s){var b;let p={};for(const _ in m){const E=m[_].type;if(E&&E!=="object")p[_]=E==="number"?Number(s[_]):s[_];else if(typeof m[_]=="object"&&((b=m[_])!=null&&b.properties)){const y=lu(m[_].properties,s);Object.keys(y).length>0&&(p[_]=y)}}return p}function Gd(m,s){var E;if(!s||!m.getSource().getTileUrlFunction())return null;const p=new URL(m.getSource().getTileUrlFunction()([0,0,0])),b=Object.fromEntries(p.searchParams.entries()),_=lu(((E=s.schema)==null?void 0:E.properties)||s.schema,b);return Object.keys(_).length?_:null}const Wd=(m,s)=>m==null?void 0:m.filter(p=>["remove","sort"].filter(b=>s!=null&&s.get("layerControlDisable")?b!=="sort":!0).includes(p)),Zd=(m,s)=>m==null?void 0:m.filter(p=>{let b=!0;return["remove","sort"].includes(p)&&(b=!1),p==="info"&&(b=s.get("description")),p==="config"&&(b=s.get("layerConfig")),b}),Jd=(m,s)=>ae`
|
|
46
|
-
<button slot="${m}-icon" class="icon">${s?m:
|
|
45
|
+
*/function $c(m,s){var p=Object.keys(m);if(Object.getOwnPropertySymbols){var b=Object.getOwnPropertySymbols(m);s&&(b=b.filter(function(_){return Object.getOwnPropertyDescriptor(m,_).enumerable})),p.push.apply(p,b)}return p}function rn(m){for(var s=1;s<arguments.length;s++){var p=arguments[s]!=null?arguments[s]:{};s%2?$c(Object(p),!0).forEach(function(b){fd(m,b,p[b])}):Object.getOwnPropertyDescriptors?Object.defineProperties(m,Object.getOwnPropertyDescriptors(p)):$c(Object(p)).forEach(function(b){Object.defineProperty(m,b,Object.getOwnPropertyDescriptor(p,b))})}return m}function wa(m){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?wa=function(s){return typeof s}:wa=function(s){return s&&typeof Symbol=="function"&&s.constructor===Symbol&&s!==Symbol.prototype?"symbol":typeof s},wa(m)}function fd(m,s,p){return s in m?Object.defineProperty(m,s,{value:p,enumerable:!0,configurable:!0,writable:!0}):m[s]=p,m}function wn(){return wn=Object.assign||function(m){for(var s=1;s<arguments.length;s++){var p=arguments[s];for(var b in p)Object.prototype.hasOwnProperty.call(p,b)&&(m[b]=p[b])}return m},wn.apply(this,arguments)}function md(m,s){if(m==null)return{};var p={},b=Object.keys(m),_,E;for(E=0;E<b.length;E++)_=b[E],!(s.indexOf(_)>=0)&&(p[_]=m[_]);return p}function yd(m,s){if(m==null)return{};var p=md(m,s),b,_;if(Object.getOwnPropertySymbols){var E=Object.getOwnPropertySymbols(m);for(_=0;_<E.length;_++)b=E[_],!(s.indexOf(b)>=0)&&Object.prototype.propertyIsEnumerable.call(m,b)&&(p[b]=m[b])}return p}var bd="1.15.2";function _n(m){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(m)}var xn=_n(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),Mo=_n(/Edge/i),Mc=_n(/firefox/i),Ho=_n(/safari/i)&&!_n(/chrome/i)&&!_n(/android/i),Hc=_n(/iP(ad|od|hone)/i),Fc=_n(/chrome/i)&&_n(/android/i),Vc={capture:!1,passive:!1};function be(m,s,p){m.addEventListener(s,p,!xn&&Vc)}function he(m,s,p){m.removeEventListener(s,p,!xn&&Vc)}function _a(m,s){if(s){if(s[0]===">"&&(s=s.substring(1)),m)try{if(m.matches)return m.matches(s);if(m.msMatchesSelector)return m.msMatchesSelector(s);if(m.webkitMatchesSelector)return m.webkitMatchesSelector(s)}catch{return!1}return!1}}function vd(m){return m.host&&m!==document&&m.host.nodeType?m.host:m.parentNode}function Gr(m,s,p,b){if(m){p=p||document;do{if(s!=null&&(s[0]===">"?m.parentNode===p&&_a(m,s):_a(m,s))||b&&m===p)return m;if(m===p)break}while(m=vd(m))}return null}var zc=/\s+/g;function Lr(m,s,p){if(m&&s)if(m.classList)m.classList[p?"add":"remove"](s);else{var b=(" "+m.className+" ").replace(zc," ").replace(" "+s+" "," ");m.className=(b+(p?" "+s:"")).replace(zc," ")}}function Ht(m,s,p){var b=m&&m.style;if(b){if(p===void 0)return document.defaultView&&document.defaultView.getComputedStyle?p=document.defaultView.getComputedStyle(m,""):m.currentStyle&&(p=m.currentStyle),s===void 0?p:p[s];!(s in b)&&s.indexOf("webkit")===-1&&(s="-webkit-"+s),b[s]=p+(typeof p=="string"?"":"px")}}function Li(m,s){var p="";if(typeof m=="string")p=m;else do{var b=Ht(m,"transform");b&&b!=="none"&&(p=b+" "+p)}while(!s&&(m=m.parentNode));var _=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return _&&new _(p)}function Uc(m,s,p){if(m){var b=m.getElementsByTagName(s),_=0,E=b.length;if(p)for(;_<E;_++)p(b[_],_);return b}return[]}function nn(){var m=document.scrollingElement;return m||document.documentElement}function Je(m,s,p,b,_){if(!(!m.getBoundingClientRect&&m!==window)){var E,y,j,r,v,g,w;if(m!==window&&m.parentNode&&m!==nn()?(E=m.getBoundingClientRect(),y=E.top,j=E.left,r=E.bottom,v=E.right,g=E.height,w=E.width):(y=0,j=0,r=window.innerHeight,v=window.innerWidth,g=window.innerHeight,w=window.innerWidth),(s||p)&&m!==window&&(_=_||m.parentNode,!xn))do if(_&&_.getBoundingClientRect&&(Ht(_,"transform")!=="none"||p&&Ht(_,"position")!=="static")){var k=_.getBoundingClientRect();y-=k.top+parseInt(Ht(_,"border-top-width")),j-=k.left+parseInt(Ht(_,"border-left-width")),r=y+E.height,v=j+E.width;break}while(_=_.parentNode);if(b&&m!==window){var O=Li(_||m),C=O&&O.a,S=O&&O.d;O&&(y/=S,j/=C,w/=C,g/=S,r=y+g,v=j+w)}return{top:y,left:j,bottom:r,right:v,width:w,height:g}}}function qc(m,s,p){for(var b=Rn(m,!0),_=Je(m)[s];b;){var E=Je(b)[p],y=void 0;if(p==="top"||p==="left"?y=_>=E:y=_<=E,!y)return b;if(b===nn())break;b=Rn(b,!1)}return!1}function Ri(m,s,p,b){for(var _=0,E=0,y=m.children;E<y.length;){if(y[E].style.display!=="none"&&y[E]!==Ft.ghost&&(b||y[E]!==Ft.dragged)&&Gr(y[E],p.draggable,m,!1)){if(_===s)return y[E];_++}E++}return null}function Ws(m,s){for(var p=m.lastElementChild;p&&(p===Ft.ghost||Ht(p,"display")==="none"||s&&!_a(p,s));)p=p.previousElementSibling;return p||null}function $r(m,s){var p=0;if(!m||!m.parentNode)return-1;for(;m=m.previousElementSibling;)m.nodeName.toUpperCase()!=="TEMPLATE"&&m!==Ft.clone&&(!s||_a(m,s))&&p++;return p}function Gc(m){var s=0,p=0,b=nn();if(m)do{var _=Li(m),E=_.a,y=_.d;s+=m.scrollLeft*E,p+=m.scrollTop*y}while(m!==b&&(m=m.parentNode));return[s,p]}function gd(m,s){for(var p in m)if(m.hasOwnProperty(p)){for(var b in s)if(s.hasOwnProperty(b)&&s[b]===m[p][b])return Number(p)}return-1}function Rn(m,s){if(!m||!m.getBoundingClientRect)return nn();var p=m,b=!1;do if(p.clientWidth<p.scrollWidth||p.clientHeight<p.scrollHeight){var _=Ht(p);if(p.clientWidth<p.scrollWidth&&(_.overflowX=="auto"||_.overflowX=="scroll")||p.clientHeight<p.scrollHeight&&(_.overflowY=="auto"||_.overflowY=="scroll")){if(!p.getBoundingClientRect||p===document.body)return nn();if(b||s)return p;b=!0}}while(p=p.parentNode);return nn()}function wd(m,s){if(m&&s)for(var p in s)s.hasOwnProperty(p)&&(m[p]=s[p]);return m}function Zs(m,s){return Math.round(m.top)===Math.round(s.top)&&Math.round(m.left)===Math.round(s.left)&&Math.round(m.height)===Math.round(s.height)&&Math.round(m.width)===Math.round(s.width)}var Fo;function Wc(m,s){return function(){if(!Fo){var p=arguments,b=this;p.length===1?m.call(b,p[0]):m.apply(b,p),Fo=setTimeout(function(){Fo=void 0},s)}}}function _d(){clearTimeout(Fo),Fo=void 0}function Zc(m,s,p){m.scrollLeft+=s,m.scrollTop+=p}function Jc(m){var s=window.Polymer,p=window.jQuery||window.Zepto;return s&&s.dom?s.dom(m).cloneNode(!0):p?p(m).clone(!0)[0]:m.cloneNode(!0)}function Yc(m,s,p){var b={};return Array.from(m.children).forEach(function(_){var E,y,j,r;if(!(!Gr(_,s.draggable,m,!1)||_.animated||_===p)){var v=Je(_);b.left=Math.min((E=b.left)!==null&&E!==void 0?E:1/0,v.left),b.top=Math.min((y=b.top)!==null&&y!==void 0?y:1/0,v.top),b.right=Math.max((j=b.right)!==null&&j!==void 0?j:-1/0,v.right),b.bottom=Math.max((r=b.bottom)!==null&&r!==void 0?r:-1/0,v.bottom)}}),b.width=b.right-b.left,b.height=b.bottom-b.top,b.x=b.left,b.y=b.top,b}var Rr="Sortable"+new Date().getTime();function xd(){var m=[],s;return{captureAnimationState:function(){if(m=[],!!this.options.animation){var b=[].slice.call(this.el.children);b.forEach(function(_){if(!(Ht(_,"display")==="none"||_===Ft.ghost)){m.push({target:_,rect:Je(_)});var E=rn({},m[m.length-1].rect);if(_.thisAnimationDuration){var y=Li(_,!0);y&&(E.top-=y.f,E.left-=y.e)}_.fromRect=E}})}},addAnimationState:function(b){m.push(b)},removeAnimationState:function(b){m.splice(gd(m,{target:b}),1)},animateAll:function(b){var _=this;if(!this.options.animation){clearTimeout(s),typeof b=="function"&&b();return}var E=!1,y=0;m.forEach(function(j){var r=0,v=j.target,g=v.fromRect,w=Je(v),k=v.prevFromRect,O=v.prevToRect,C=j.rect,S=Li(v,!0);S&&(w.top-=S.f,w.left-=S.e),v.toRect=w,v.thisAnimationDuration&&Zs(k,w)&&!Zs(g,w)&&(C.top-w.top)/(C.left-w.left)===(g.top-w.top)/(g.left-w.left)&&(r=jd(C,k,O,_.options)),Zs(w,g)||(v.prevFromRect=g,v.prevToRect=w,r||(r=_.options.animation),_.animate(v,C,w,r)),r&&(E=!0,y=Math.max(y,r),clearTimeout(v.animationResetTimer),v.animationResetTimer=setTimeout(function(){v.animationTime=0,v.prevFromRect=null,v.fromRect=null,v.prevToRect=null,v.thisAnimationDuration=null},r),v.thisAnimationDuration=r)}),clearTimeout(s),E?s=setTimeout(function(){typeof b=="function"&&b()},y):typeof b=="function"&&b(),m=[]},animate:function(b,_,E,y){if(y){Ht(b,"transition",""),Ht(b,"transform","");var j=Li(this.el),r=j&&j.a,v=j&&j.d,g=(_.left-E.left)/(r||1),w=(_.top-E.top)/(v||1);b.animatingX=!!g,b.animatingY=!!w,Ht(b,"transform","translate3d("+g+"px,"+w+"px,0)"),this.forRepaintDummy=kd(b),Ht(b,"transition","transform "+y+"ms"+(this.options.easing?" "+this.options.easing:"")),Ht(b,"transform","translate3d(0,0,0)"),typeof b.animated=="number"&&clearTimeout(b.animated),b.animated=setTimeout(function(){Ht(b,"transition",""),Ht(b,"transform",""),b.animated=!1,b.animatingX=!1,b.animatingY=!1},y)}}}}function kd(m){return m.offsetWidth}function jd(m,s,p,b){return Math.sqrt(Math.pow(s.top-m.top,2)+Math.pow(s.left-m.left,2))/Math.sqrt(Math.pow(s.top-p.top,2)+Math.pow(s.left-p.left,2))*b.animation}var Ii=[],Js={initializeByDefault:!0},Vo={mount:function(s){for(var p in Js)Js.hasOwnProperty(p)&&!(p in s)&&(s[p]=Js[p]);Ii.forEach(function(b){if(b.pluginName===s.pluginName)throw"Sortable: Cannot mount plugin ".concat(s.pluginName," more than once")}),Ii.push(s)},pluginEvent:function(s,p,b){var _=this;this.eventCanceled=!1,b.cancel=function(){_.eventCanceled=!0};var E=s+"Global";Ii.forEach(function(y){p[y.pluginName]&&(p[y.pluginName][E]&&p[y.pluginName][E](rn({sortable:p},b)),p.options[y.pluginName]&&p[y.pluginName][s]&&p[y.pluginName][s](rn({sortable:p},b)))})},initializePlugins:function(s,p,b,_){Ii.forEach(function(j){var r=j.pluginName;if(!(!s.options[r]&&!j.initializeByDefault)){var v=new j(s,p,s.options);v.sortable=s,v.options=s.options,s[r]=v,wn(b,v.defaults)}});for(var E in s.options)if(s.options.hasOwnProperty(E)){var y=this.modifyOption(s,E,s.options[E]);typeof y<"u"&&(s.options[E]=y)}},getEventProperties:function(s,p){var b={};return Ii.forEach(function(_){typeof _.eventProperties=="function"&&wn(b,_.eventProperties.call(p[_.pluginName],s))}),b},modifyOption:function(s,p,b){var _;return Ii.forEach(function(E){s[E.pluginName]&&E.optionListeners&&typeof E.optionListeners[p]=="function"&&(_=E.optionListeners[p].call(s[E.pluginName],b))}),_}};function Od(m){var s=m.sortable,p=m.rootEl,b=m.name,_=m.targetEl,E=m.cloneEl,y=m.toEl,j=m.fromEl,r=m.oldIndex,v=m.newIndex,g=m.oldDraggableIndex,w=m.newDraggableIndex,k=m.originalEvent,O=m.putSortable,C=m.extraEventProperties;if(s=s||p&&p[Rr],!!s){var S,T=s.options,A="on"+b.charAt(0).toUpperCase()+b.substr(1);window.CustomEvent&&!xn&&!Mo?S=new CustomEvent(b,{bubbles:!0,cancelable:!0}):(S=document.createEvent("Event"),S.initEvent(b,!0,!0)),S.to=y||p,S.from=j||p,S.item=_||p,S.clone=E,S.oldIndex=r,S.newIndex=v,S.oldDraggableIndex=g,S.newDraggableIndex=w,S.originalEvent=k,S.pullMode=O?O.lastPutMode:void 0;var R=rn(rn({},C),Vo.getEventProperties(b,s));for(var I in R)S[I]=R[I];p&&p.dispatchEvent(S),T[A]&&T[A].call(s,S)}}var Ed=["evt"],Er=function(s,p){var b=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},_=b.evt,E=yd(b,Ed);Vo.pluginEvent.bind(Ft)(s,p,rn({dragEl:ht,parentEl:Ve,ghostEl:Wt,rootEl:Ie,nextEl:ai,lastDownEl:xa,cloneEl:De,cloneHidden:In,dragStarted:Uo,putSortable:sr,activeSortable:Ft.active,originalEvent:_,oldIndex:Bi,oldDraggableIndex:zo,newIndex:Ir,newDraggableIndex:Bn,hideGhostForTarget:nu,unhideGhostForTarget:iu,cloneNowHidden:function(){In=!0},cloneNowShown:function(){In=!1},dispatchSortableEvent:function(j){_r({sortable:p,name:j,originalEvent:_})}},E))};function _r(m){Od(rn({putSortable:sr,cloneEl:De,targetEl:ht,rootEl:Ie,oldIndex:Bi,oldDraggableIndex:zo,newIndex:Ir,newDraggableIndex:Bn},m))}var ht,Ve,Wt,Ie,ai,xa,De,In,Bi,Ir,zo,Bn,ka,sr,Di=!1,ja=!1,Oa=[],si,Wr,Ys,Xs,Xc,Kc,Uo,Ni,qo,Go=!1,Ea=!1,Ca,hr,Ks=[],Qs=!1,Sa=[],Pa=typeof document<"u",Ta=Hc,Qc=Mo||xn?"cssFloat":"float",Cd=Pa&&!Fc&&!Hc&&"draggable"in document.createElement("div"),tu=function(){if(Pa){if(xn)return!1;var m=document.createElement("x");return m.style.cssText="pointer-events:auto",m.style.pointerEvents==="auto"}}(),eu=function(s,p){var b=Ht(s),_=parseInt(b.width)-parseInt(b.paddingLeft)-parseInt(b.paddingRight)-parseInt(b.borderLeftWidth)-parseInt(b.borderRightWidth),E=Ri(s,0,p),y=Ri(s,1,p),j=E&&Ht(E),r=y&&Ht(y),v=j&&parseInt(j.marginLeft)+parseInt(j.marginRight)+Je(E).width,g=r&&parseInt(r.marginLeft)+parseInt(r.marginRight)+Je(y).width;if(b.display==="flex")return b.flexDirection==="column"||b.flexDirection==="column-reverse"?"vertical":"horizontal";if(b.display==="grid")return b.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(E&&j.float&&j.float!=="none"){var w=j.float==="left"?"left":"right";return y&&(r.clear==="both"||r.clear===w)?"vertical":"horizontal"}return E&&(j.display==="block"||j.display==="flex"||j.display==="table"||j.display==="grid"||v>=_&&b[Qc]==="none"||y&&b[Qc]==="none"&&v+g>_)?"vertical":"horizontal"},Sd=function(s,p,b){var _=b?s.left:s.top,E=b?s.right:s.bottom,y=b?s.width:s.height,j=b?p.left:p.top,r=b?p.right:p.bottom,v=b?p.width:p.height;return _===j||E===r||_+y/2===j+v/2},Pd=function(s,p){var b;return Oa.some(function(_){var E=_[Rr].options.emptyInsertThreshold;if(!(!E||Ws(_))){var y=Je(_),j=s>=y.left-E&&s<=y.right+E,r=p>=y.top-E&&p<=y.bottom+E;if(j&&r)return b=_}}),b},ru=function(s){function p(E,y){return function(j,r,v,g){var w=j.options.group.name&&r.options.group.name&&j.options.group.name===r.options.group.name;if(E==null&&(y||w))return!0;if(E==null||E===!1)return!1;if(y&&E==="clone")return E;if(typeof E=="function")return p(E(j,r,v,g),y)(j,r,v,g);var k=(y?j:r).options.group.name;return E===!0||typeof E=="string"&&E===k||E.join&&E.indexOf(k)>-1}}var b={},_=s.group;(!_||wa(_)!="object")&&(_={name:_}),b.name=_.name,b.checkPull=p(_.pull,!0),b.checkPut=p(_.put),b.revertClone=_.revertClone,s.group=b},nu=function(){!tu&&Wt&&Ht(Wt,"display","none")},iu=function(){!tu&&Wt&&Ht(Wt,"display","")};Pa&&!Fc&&document.addEventListener("click",function(m){if(ja)return m.preventDefault(),m.stopPropagation&&m.stopPropagation(),m.stopImmediatePropagation&&m.stopImmediatePropagation(),ja=!1,!1},!0);var li=function(s){if(ht){s=s.touches?s.touches[0]:s;var p=Pd(s.clientX,s.clientY);if(p){var b={};for(var _ in s)s.hasOwnProperty(_)&&(b[_]=s[_]);b.target=b.rootEl=p,b.preventDefault=void 0,b.stopPropagation=void 0,p[Rr]._onDragOver(b)}}},Td=function(s){ht&&ht.parentNode[Rr]._isOutsideThisEl(s.target)};function Ft(m,s){if(!(m&&m.nodeType&&m.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(m));this.el=m,this.options=s=wn({},s),m[Rr]=this;var p={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(m.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return eu(m,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(y,j){y.setData("Text",j.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:Ft.supportPointer!==!1&&"PointerEvent"in window&&!Ho,emptyInsertThreshold:5};Vo.initializePlugins(this,m,p);for(var b in p)!(b in s)&&(s[b]=p[b]);ru(s);for(var _ in this)_.charAt(0)==="_"&&typeof this[_]=="function"&&(this[_]=this[_].bind(this));this.nativeDraggable=s.forceFallback?!1:Cd,this.nativeDraggable&&(this.options.touchStartThreshold=1),s.supportPointer?be(m,"pointerdown",this._onTapStart):(be(m,"mousedown",this._onTapStart),be(m,"touchstart",this._onTapStart)),this.nativeDraggable&&(be(m,"dragover",this),be(m,"dragenter",this)),Oa.push(this.el),s.store&&s.store.get&&this.sort(s.store.get(this)||[]),wn(this,xd())}Ft.prototype={constructor:Ft,_isOutsideThisEl:function(s){!this.el.contains(s)&&s!==this.el&&(Ni=null)},_getDirection:function(s,p){return typeof this.options.direction=="function"?this.options.direction.call(this,s,p,ht):this.options.direction},_onTapStart:function(s){if(s.cancelable){var p=this,b=this.el,_=this.options,E=_.preventOnFilter,y=s.type,j=s.touches&&s.touches[0]||s.pointerType&&s.pointerType==="touch"&&s,r=(j||s).target,v=s.target.shadowRoot&&(s.path&&s.path[0]||s.composedPath&&s.composedPath()[0])||r,g=_.filter;if($d(b),!ht&&!(/mousedown|pointerdown/.test(y)&&s.button!==0||_.disabled)&&!v.isContentEditable&&!(!this.nativeDraggable&&Ho&&r&&r.tagName.toUpperCase()==="SELECT")&&(r=Gr(r,_.draggable,b,!1),!(r&&r.animated)&&xa!==r)){if(Bi=$r(r),zo=$r(r,_.draggable),typeof g=="function"){if(g.call(this,s,r,this)){_r({sortable:p,rootEl:v,name:"filter",targetEl:r,toEl:b,fromEl:b}),Er("filter",p,{evt:s}),E&&s.cancelable&&s.preventDefault();return}}else if(g&&(g=g.split(",").some(function(w){if(w=Gr(v,w.trim(),b,!1),w)return _r({sortable:p,rootEl:w,name:"filter",targetEl:r,fromEl:b,toEl:b}),Er("filter",p,{evt:s}),!0}),g)){E&&s.cancelable&&s.preventDefault();return}_.handle&&!Gr(v,_.handle,b,!1)||this._prepareDragStart(s,j,r)}}},_prepareDragStart:function(s,p,b){var _=this,E=_.el,y=_.options,j=E.ownerDocument,r;if(b&&!ht&&b.parentNode===E){var v=Je(b);if(Ie=E,ht=b,Ve=ht.parentNode,ai=ht.nextSibling,xa=b,ka=y.group,Ft.dragged=ht,si={target:ht,clientX:(p||s).clientX,clientY:(p||s).clientY},Xc=si.clientX-v.left,Kc=si.clientY-v.top,this._lastX=(p||s).clientX,this._lastY=(p||s).clientY,ht.style["will-change"]="all",r=function(){if(Er("delayEnded",_,{evt:s}),Ft.eventCanceled){_._onDrop();return}_._disableDelayedDragEvents(),!Mc&&_.nativeDraggable&&(ht.draggable=!0),_._triggerDragStart(s,p),_r({sortable:_,name:"choose",originalEvent:s}),Lr(ht,y.chosenClass,!0)},y.ignore.split(",").forEach(function(g){Uc(ht,g.trim(),tl)}),be(j,"dragover",li),be(j,"mousemove",li),be(j,"touchmove",li),be(j,"mouseup",_._onDrop),be(j,"touchend",_._onDrop),be(j,"touchcancel",_._onDrop),Mc&&this.nativeDraggable&&(this.options.touchStartThreshold=4,ht.draggable=!0),Er("delayStart",this,{evt:s}),y.delay&&(!y.delayOnTouchOnly||p)&&(!this.nativeDraggable||!(Mo||xn))){if(Ft.eventCanceled){this._onDrop();return}be(j,"mouseup",_._disableDelayedDrag),be(j,"touchend",_._disableDelayedDrag),be(j,"touchcancel",_._disableDelayedDrag),be(j,"mousemove",_._delayedDragTouchMoveHandler),be(j,"touchmove",_._delayedDragTouchMoveHandler),y.supportPointer&&be(j,"pointermove",_._delayedDragTouchMoveHandler),_._dragStartTimer=setTimeout(r,y.delay)}else r()}},_delayedDragTouchMoveHandler:function(s){var p=s.touches?s.touches[0]:s;Math.max(Math.abs(p.clientX-this._lastX),Math.abs(p.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){ht&&tl(ht),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var s=this.el.ownerDocument;he(s,"mouseup",this._disableDelayedDrag),he(s,"touchend",this._disableDelayedDrag),he(s,"touchcancel",this._disableDelayedDrag),he(s,"mousemove",this._delayedDragTouchMoveHandler),he(s,"touchmove",this._delayedDragTouchMoveHandler),he(s,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(s,p){p=p||s.pointerType=="touch"&&s,!this.nativeDraggable||p?this.options.supportPointer?be(document,"pointermove",this._onTouchMove):p?be(document,"touchmove",this._onTouchMove):be(document,"mousemove",this._onTouchMove):(be(ht,"dragend",this),be(Ie,"dragstart",this._onDragStart));try{document.selection?La(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(s,p){if(Di=!1,Ie&&ht){Er("dragStarted",this,{evt:p}),this.nativeDraggable&&be(document,"dragover",Td);var b=this.options;!s&&Lr(ht,b.dragClass,!1),Lr(ht,b.ghostClass,!0),Ft.active=this,s&&this._appendGhost(),_r({sortable:this,name:"start",originalEvent:p})}else this._nulling()},_emulateDragOver:function(){if(Wr){this._lastX=Wr.clientX,this._lastY=Wr.clientY,nu();for(var s=document.elementFromPoint(Wr.clientX,Wr.clientY),p=s;s&&s.shadowRoot&&(s=s.shadowRoot.elementFromPoint(Wr.clientX,Wr.clientY),s!==p);)p=s;if(ht.parentNode[Rr]._isOutsideThisEl(s),p)do{if(p[Rr]){var b=void 0;if(b=p[Rr]._onDragOver({clientX:Wr.clientX,clientY:Wr.clientY,target:s,rootEl:p}),b&&!this.options.dragoverBubble)break}s=p}while(p=p.parentNode);iu()}},_onTouchMove:function(s){if(si){var p=this.options,b=p.fallbackTolerance,_=p.fallbackOffset,E=s.touches?s.touches[0]:s,y=Wt&&Li(Wt,!0),j=Wt&&y&&y.a,r=Wt&&y&&y.d,v=Ta&&hr&&Gc(hr),g=(E.clientX-si.clientX+_.x)/(j||1)+(v?v[0]-Ks[0]:0)/(j||1),w=(E.clientY-si.clientY+_.y)/(r||1)+(v?v[1]-Ks[1]:0)/(r||1);if(!Ft.active&&!Di){if(b&&Math.max(Math.abs(E.clientX-this._lastX),Math.abs(E.clientY-this._lastY))<b)return;this._onDragStart(s,!0)}if(Wt){y?(y.e+=g-(Ys||0),y.f+=w-(Xs||0)):y={a:1,b:0,c:0,d:1,e:g,f:w};var k="matrix(".concat(y.a,",").concat(y.b,",").concat(y.c,",").concat(y.d,",").concat(y.e,",").concat(y.f,")");Ht(Wt,"webkitTransform",k),Ht(Wt,"mozTransform",k),Ht(Wt,"msTransform",k),Ht(Wt,"transform",k),Ys=g,Xs=w,Wr=E}s.cancelable&&s.preventDefault()}},_appendGhost:function(){if(!Wt){var s=this.options.fallbackOnBody?document.body:Ie,p=Je(ht,!0,Ta,!0,s),b=this.options;if(Ta){for(hr=s;Ht(hr,"position")==="static"&&Ht(hr,"transform")==="none"&&hr!==document;)hr=hr.parentNode;hr!==document.body&&hr!==document.documentElement?(hr===document&&(hr=nn()),p.top+=hr.scrollTop,p.left+=hr.scrollLeft):hr=nn(),Ks=Gc(hr)}Wt=ht.cloneNode(!0),Lr(Wt,b.ghostClass,!1),Lr(Wt,b.fallbackClass,!0),Lr(Wt,b.dragClass,!0),Ht(Wt,"transition",""),Ht(Wt,"transform",""),Ht(Wt,"box-sizing","border-box"),Ht(Wt,"margin",0),Ht(Wt,"top",p.top),Ht(Wt,"left",p.left),Ht(Wt,"width",p.width),Ht(Wt,"height",p.height),Ht(Wt,"opacity","0.8"),Ht(Wt,"position",Ta?"absolute":"fixed"),Ht(Wt,"zIndex","100000"),Ht(Wt,"pointerEvents","none"),Ft.ghost=Wt,s.appendChild(Wt),Ht(Wt,"transform-origin",Xc/parseInt(Wt.style.width)*100+"% "+Kc/parseInt(Wt.style.height)*100+"%")}},_onDragStart:function(s,p){var b=this,_=s.dataTransfer,E=b.options;if(Er("dragStart",this,{evt:s}),Ft.eventCanceled){this._onDrop();return}Er("setupClone",this),Ft.eventCanceled||(De=Jc(ht),De.removeAttribute("id"),De.draggable=!1,De.style["will-change"]="",this._hideClone(),Lr(De,this.options.chosenClass,!1),Ft.clone=De),b.cloneId=La(function(){Er("clone",b),!Ft.eventCanceled&&(b.options.removeCloneOnHide||Ie.insertBefore(De,ht),b._hideClone(),_r({sortable:b,name:"clone"}))}),!p&&Lr(ht,E.dragClass,!0),p?(ja=!0,b._loopId=setInterval(b._emulateDragOver,50)):(he(document,"mouseup",b._onDrop),he(document,"touchend",b._onDrop),he(document,"touchcancel",b._onDrop),_&&(_.effectAllowed="move",E.setData&&E.setData.call(b,_,ht)),be(document,"drop",b),Ht(ht,"transform","translateZ(0)")),Di=!0,b._dragStartId=La(b._dragStarted.bind(b,p,s)),be(document,"selectstart",b),Uo=!0,Ho&&Ht(document.body,"user-select","none")},_onDragOver:function(s){var p=this.el,b=s.target,_,E,y,j=this.options,r=j.group,v=Ft.active,g=ka===r,w=j.sort,k=sr||v,O,C=this,S=!1;if(Qs)return;function T(yt,ct){Er(yt,C,rn({evt:s,isOwner:g,axis:O?"vertical":"horizontal",revert:y,dragRect:_,targetRect:E,canSort:w,fromSortable:k,target:b,completed:R,onMove:function(At,Vt){return Aa(Ie,p,ht,_,At,Je(At),s,Vt)},changed:I},ct))}function A(){T("dragOverAnimationCapture"),C.captureAnimationState(),C!==k&&k.captureAnimationState()}function R(yt){return T("dragOverCompleted",{insertion:yt}),yt&&(g?v._hideClone():v._showClone(C),C!==k&&(Lr(ht,sr?sr.options.ghostClass:v.options.ghostClass,!1),Lr(ht,j.ghostClass,!0)),sr!==C&&C!==Ft.active?sr=C:C===Ft.active&&sr&&(sr=null),k===C&&(C._ignoreWhileAnimating=b),C.animateAll(function(){T("dragOverAnimationComplete"),C._ignoreWhileAnimating=null}),C!==k&&(k.animateAll(),k._ignoreWhileAnimating=null)),(b===ht&&!ht.animated||b===p&&!b.animated)&&(Ni=null),!j.dragoverBubble&&!s.rootEl&&b!==document&&(ht.parentNode[Rr]._isOutsideThisEl(s.target),!yt&&li(s)),!j.dragoverBubble&&s.stopPropagation&&s.stopPropagation(),S=!0}function I(){Ir=$r(ht),Bn=$r(ht,j.draggable),_r({sortable:C,name:"change",toEl:p,newIndex:Ir,newDraggableIndex:Bn,originalEvent:s})}if(s.preventDefault!==void 0&&s.cancelable&&s.preventDefault(),b=Gr(b,j.draggable,p,!0),T("dragOver"),Ft.eventCanceled)return S;if(ht.contains(s.target)||b.animated&&b.animatingX&&b.animatingY||C._ignoreWhileAnimating===b)return R(!1);if(ja=!1,v&&!j.disabled&&(g?w||(y=Ve!==Ie):sr===this||(this.lastPutMode=ka.checkPull(this,v,ht,s))&&r.checkPut(this,v,ht,s))){if(O=this._getDirection(s,b)==="vertical",_=Je(ht),T("dragOverValid"),Ft.eventCanceled)return S;if(y)return Ve=Ie,A(),this._hideClone(),T("revert"),Ft.eventCanceled||(ai?Ie.insertBefore(ht,ai):Ie.appendChild(ht)),R(!0);var $=Ws(p,j.draggable);if(!$||Id(s,O,this)&&!$.animated){if($===ht)return R(!1);if($&&p===s.target&&(b=$),b&&(E=Je(b)),Aa(Ie,p,ht,_,b,E,s,!!b)!==!1)return A(),$&&$.nextSibling?p.insertBefore(ht,$.nextSibling):p.appendChild(ht),Ve=p,I(),R(!0)}else if($&&Rd(s,O,this)){var M=Ri(p,0,j,!0);if(M===ht)return R(!1);if(b=M,E=Je(b),Aa(Ie,p,ht,_,b,E,s,!1)!==!1)return A(),p.insertBefore(ht,M),Ve=p,I(),R(!0)}else if(b.parentNode===p){E=Je(b);var B=0,q,F=ht.parentNode!==p,N=!Sd(ht.animated&&ht.toRect||_,b.animated&&b.toRect||E,O),U=O?"top":"left",H=qc(b,"top","top")||qc(ht,"top","top"),X=H?H.scrollTop:void 0;Ni!==b&&(q=E[U],Go=!1,Ea=!N&&j.invertSwap||F),B=Bd(s,b,E,O,N?1:j.swapThreshold,j.invertedSwapThreshold==null?j.swapThreshold:j.invertedSwapThreshold,Ea,Ni===b);var Y;if(B!==0){var K=$r(ht);do K-=B,Y=Ve.children[K];while(Y&&(Ht(Y,"display")==="none"||Y===Wt))}if(B===0||Y===b)return R(!1);Ni=b,qo=B;var tt=b.nextElementSibling,it=!1;it=B===1;var st=Aa(Ie,p,ht,_,b,E,s,it);if(st!==!1)return(st===1||st===-1)&&(it=st===1),Qs=!0,setTimeout(Ld,30),A(),it&&!tt?p.appendChild(ht):b.parentNode.insertBefore(ht,it?tt:b),H&&Zc(H,0,X-H.scrollTop),Ve=ht.parentNode,q!==void 0&&!Ea&&(Ca=Math.abs(q-Je(b)[U])),I(),R(!0)}if(p.contains(ht))return R(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){he(document,"mousemove",this._onTouchMove),he(document,"touchmove",this._onTouchMove),he(document,"pointermove",this._onTouchMove),he(document,"dragover",li),he(document,"mousemove",li),he(document,"touchmove",li)},_offUpEvents:function(){var s=this.el.ownerDocument;he(s,"mouseup",this._onDrop),he(s,"touchend",this._onDrop),he(s,"pointerup",this._onDrop),he(s,"touchcancel",this._onDrop),he(document,"selectstart",this)},_onDrop:function(s){var p=this.el,b=this.options;if(Ir=$r(ht),Bn=$r(ht,b.draggable),Er("drop",this,{evt:s}),Ve=ht&&ht.parentNode,Ir=$r(ht),Bn=$r(ht,b.draggable),Ft.eventCanceled){this._nulling();return}Di=!1,Ea=!1,Go=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),el(this.cloneId),el(this._dragStartId),this.nativeDraggable&&(he(document,"drop",this),he(p,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),Ho&&Ht(document.body,"user-select",""),Ht(ht,"transform",""),s&&(Uo&&(s.cancelable&&s.preventDefault(),!b.dropBubble&&s.stopPropagation()),Wt&&Wt.parentNode&&Wt.parentNode.removeChild(Wt),(Ie===Ve||sr&&sr.lastPutMode!=="clone")&&De&&De.parentNode&&De.parentNode.removeChild(De),ht&&(this.nativeDraggable&&he(ht,"dragend",this),tl(ht),ht.style["will-change"]="",Uo&&!Di&&Lr(ht,sr?sr.options.ghostClass:this.options.ghostClass,!1),Lr(ht,this.options.chosenClass,!1),_r({sortable:this,name:"unchoose",toEl:Ve,newIndex:null,newDraggableIndex:null,originalEvent:s}),Ie!==Ve?(Ir>=0&&(_r({rootEl:Ve,name:"add",toEl:Ve,fromEl:Ie,originalEvent:s}),_r({sortable:this,name:"remove",toEl:Ve,originalEvent:s}),_r({rootEl:Ve,name:"sort",toEl:Ve,fromEl:Ie,originalEvent:s}),_r({sortable:this,name:"sort",toEl:Ve,originalEvent:s})),sr&&sr.save()):Ir!==Bi&&Ir>=0&&(_r({sortable:this,name:"update",toEl:Ve,originalEvent:s}),_r({sortable:this,name:"sort",toEl:Ve,originalEvent:s})),Ft.active&&((Ir==null||Ir===-1)&&(Ir=Bi,Bn=zo),_r({sortable:this,name:"end",toEl:Ve,originalEvent:s}),this.save()))),this._nulling()},_nulling:function(){Er("nulling",this),Ie=ht=Ve=Wt=ai=De=xa=In=si=Wr=Uo=Ir=Bn=Bi=zo=Ni=qo=sr=ka=Ft.dragged=Ft.ghost=Ft.clone=Ft.active=null,Sa.forEach(function(s){s.checked=!0}),Sa.length=Ys=Xs=0},handleEvent:function(s){switch(s.type){case"drop":case"dragend":this._onDrop(s);break;case"dragenter":case"dragover":ht&&(this._onDragOver(s),Ad(s));break;case"selectstart":s.preventDefault();break}},toArray:function(){for(var s=[],p,b=this.el.children,_=0,E=b.length,y=this.options;_<E;_++)p=b[_],Gr(p,y.draggable,this.el,!1)&&s.push(p.getAttribute(y.dataIdAttr)||Nd(p));return s},sort:function(s,p){var b={},_=this.el;this.toArray().forEach(function(E,y){var j=_.children[y];Gr(j,this.options.draggable,_,!1)&&(b[E]=j)},this),p&&this.captureAnimationState(),s.forEach(function(E){b[E]&&(_.removeChild(b[E]),_.appendChild(b[E]))}),p&&this.animateAll()},save:function(){var s=this.options.store;s&&s.set&&s.set(this)},closest:function(s,p){return Gr(s,p||this.options.draggable,this.el,!1)},option:function(s,p){var b=this.options;if(p===void 0)return b[s];var _=Vo.modifyOption(this,s,p);typeof _<"u"?b[s]=_:b[s]=p,s==="group"&&ru(b)},destroy:function(){Er("destroy",this);var s=this.el;s[Rr]=null,he(s,"mousedown",this._onTapStart),he(s,"touchstart",this._onTapStart),he(s,"pointerdown",this._onTapStart),this.nativeDraggable&&(he(s,"dragover",this),he(s,"dragenter",this)),Array.prototype.forEach.call(s.querySelectorAll("[draggable]"),function(p){p.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),Oa.splice(Oa.indexOf(this.el),1),this.el=s=null},_hideClone:function(){if(!In){if(Er("hideClone",this),Ft.eventCanceled)return;Ht(De,"display","none"),this.options.removeCloneOnHide&&De.parentNode&&De.parentNode.removeChild(De),In=!0}},_showClone:function(s){if(s.lastPutMode!=="clone"){this._hideClone();return}if(In){if(Er("showClone",this),Ft.eventCanceled)return;ht.parentNode==Ie&&!this.options.group.revertClone?Ie.insertBefore(De,ht):ai?Ie.insertBefore(De,ai):Ie.appendChild(De),this.options.group.revertClone&&this.animate(ht,De),Ht(De,"display",""),In=!1}}};function Ad(m){m.dataTransfer&&(m.dataTransfer.dropEffect="move"),m.cancelable&&m.preventDefault()}function Aa(m,s,p,b,_,E,y,j){var r,v=m[Rr],g=v.options.onMove,w;return window.CustomEvent&&!xn&&!Mo?r=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(r=document.createEvent("Event"),r.initEvent("move",!0,!0)),r.to=s,r.from=m,r.dragged=p,r.draggedRect=b,r.related=_||s,r.relatedRect=E||Je(s),r.willInsertAfter=j,r.originalEvent=y,m.dispatchEvent(r),g&&(w=g.call(v,r,y)),w}function tl(m){m.draggable=!1}function Ld(){Qs=!1}function Rd(m,s,p){var b=Je(Ri(p.el,0,p.options,!0)),_=Yc(p.el,p.options,Wt),E=10;return s?m.clientX<_.left-E||m.clientY<b.top&&m.clientX<b.right:m.clientY<_.top-E||m.clientY<b.bottom&&m.clientX<b.left}function Id(m,s,p){var b=Je(Ws(p.el,p.options.draggable)),_=Yc(p.el,p.options,Wt),E=10;return s?m.clientX>_.right+E||m.clientY>b.bottom&&m.clientX>b.left:m.clientY>_.bottom+E||m.clientX>b.right&&m.clientY>b.top}function Bd(m,s,p,b,_,E,y,j){var r=b?m.clientY:m.clientX,v=b?p.height:p.width,g=b?p.top:p.left,w=b?p.bottom:p.right,k=!1;if(!y){if(j&&Ca<v*_){if(!Go&&(qo===1?r>g+v*E/2:r<w-v*E/2)&&(Go=!0),Go)k=!0;else if(qo===1?r<g+Ca:r>w-Ca)return-qo}else if(r>g+v*(1-_)/2&&r<w-v*(1-_)/2)return Dd(s)}return k=k||y,k&&(r<g+v*E/2||r>w-v*E/2)?r>g+v/2?1:-1:0}function Dd(m){return $r(ht)<$r(m)?1:-1}function Nd(m){for(var s=m.tagName+m.className+m.src+m.href+m.textContent,p=s.length,b=0;p--;)b+=s.charCodeAt(p);return b.toString(36)}function $d(m){Sa.length=0;for(var s=m.getElementsByTagName("input"),p=s.length;p--;){var b=s[p];b.checked&&Sa.push(b)}}function La(m){return setTimeout(m,0)}function el(m){return clearTimeout(m)}Pa&&be(document,"touchmove",function(m){(Ft.active||Di)&&m.cancelable&&m.preventDefault()}),Ft.utils={on:be,off:he,css:Ht,find:Uc,is:function(s,p){return!!Gr(s,p,s,!1)},extend:wd,throttle:Wc,closest:Gr,toggleClass:Lr,clone:Jc,index:$r,nextTick:La,cancelNextTick:el,detectDirection:eu,getChild:Ri},Ft.get=function(m){return m[Rr]},Ft.mount=function(){for(var m=arguments.length,s=new Array(m),p=0;p<m;p++)s[p]=arguments[p];s[0].constructor===Array&&(s=s[0]),s.forEach(function(b){if(!b.prototype||!b.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(b));b.utils&&(Ft.utils=rn(rn({},Ft.utils),b.utils)),Vo.mount(b)})},Ft.create=function(m,s){return new Ft(m,s)},Ft.version=bd;var Ye=[],Wo,rl,nl=!1,il,ol,Ra,Zo;function Md(){function m(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var s in this)s.charAt(0)==="_"&&typeof this[s]=="function"&&(this[s]=this[s].bind(this))}return m.prototype={dragStarted:function(p){var b=p.originalEvent;this.sortable.nativeDraggable?be(document,"dragover",this._handleAutoScroll):this.options.supportPointer?be(document,"pointermove",this._handleFallbackAutoScroll):b.touches?be(document,"touchmove",this._handleFallbackAutoScroll):be(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(p){var b=p.originalEvent;!this.options.dragOverBubble&&!b.rootEl&&this._handleAutoScroll(b)},drop:function(){this.sortable.nativeDraggable?he(document,"dragover",this._handleAutoScroll):(he(document,"pointermove",this._handleFallbackAutoScroll),he(document,"touchmove",this._handleFallbackAutoScroll),he(document,"mousemove",this._handleFallbackAutoScroll)),ou(),Ia(),_d()},nulling:function(){Ra=rl=Wo=nl=Zo=il=ol=null,Ye.length=0},_handleFallbackAutoScroll:function(p){this._handleAutoScroll(p,!0)},_handleAutoScroll:function(p,b){var _=this,E=(p.touches?p.touches[0]:p).clientX,y=(p.touches?p.touches[0]:p).clientY,j=document.elementFromPoint(E,y);if(Ra=p,b||this.options.forceAutoScrollFallback||Mo||xn||Ho){al(p,this.options,j,b);var r=Rn(j,!0);nl&&(!Zo||E!==il||y!==ol)&&(Zo&&ou(),Zo=setInterval(function(){var v=Rn(document.elementFromPoint(E,y),!0);v!==r&&(r=v,Ia()),al(p,_.options,v,b)},10),il=E,ol=y)}else{if(!this.options.bubbleScroll||Rn(j,!0)===nn()){Ia();return}al(p,this.options,Rn(j,!1),!1)}}},wn(m,{pluginName:"scroll",initializeByDefault:!0})}function Ia(){Ye.forEach(function(m){clearInterval(m.pid)}),Ye=[]}function ou(){clearInterval(Zo)}var al=Wc(function(m,s,p,b){if(s.scroll){var _=(m.touches?m.touches[0]:m).clientX,E=(m.touches?m.touches[0]:m).clientY,y=s.scrollSensitivity,j=s.scrollSpeed,r=nn(),v=!1,g;rl!==p&&(rl=p,Ia(),Wo=s.scroll,g=s.scrollFn,Wo===!0&&(Wo=Rn(p,!0)));var w=0,k=Wo;do{var O=k,C=Je(O),S=C.top,T=C.bottom,A=C.left,R=C.right,I=C.width,$=C.height,M=void 0,B=void 0,q=O.scrollWidth,F=O.scrollHeight,N=Ht(O),U=O.scrollLeft,H=O.scrollTop;O===r?(M=I<q&&(N.overflowX==="auto"||N.overflowX==="scroll"||N.overflowX==="visible"),B=$<F&&(N.overflowY==="auto"||N.overflowY==="scroll"||N.overflowY==="visible")):(M=I<q&&(N.overflowX==="auto"||N.overflowX==="scroll"),B=$<F&&(N.overflowY==="auto"||N.overflowY==="scroll"));var X=M&&(Math.abs(R-_)<=y&&U+I<q)-(Math.abs(A-_)<=y&&!!U),Y=B&&(Math.abs(T-E)<=y&&H+$<F)-(Math.abs(S-E)<=y&&!!H);if(!Ye[w])for(var K=0;K<=w;K++)Ye[K]||(Ye[K]={});(Ye[w].vx!=X||Ye[w].vy!=Y||Ye[w].el!==O)&&(Ye[w].el=O,Ye[w].vx=X,Ye[w].vy=Y,clearInterval(Ye[w].pid),(X!=0||Y!=0)&&(v=!0,Ye[w].pid=setInterval((function(){b&&this.layer===0&&Ft.active._onTouchMove(Ra);var tt=Ye[this.layer].vy?Ye[this.layer].vy*j:0,it=Ye[this.layer].vx?Ye[this.layer].vx*j:0;typeof g=="function"&&g.call(Ft.dragged.parentNode[Rr],it,tt,m,Ra,Ye[this.layer].el)!=="continue"||Zc(Ye[this.layer].el,it,tt)}).bind({layer:w}),24))),w++}while(s.bubbleScroll&&k!==r&&(k=Rn(k,!1)));nl=v}},30),au=function(s){var p=s.originalEvent,b=s.putSortable,_=s.dragEl,E=s.activeSortable,y=s.dispatchSortableEvent,j=s.hideGhostForTarget,r=s.unhideGhostForTarget;if(p){var v=b||E;j();var g=p.changedTouches&&p.changedTouches.length?p.changedTouches[0]:p,w=document.elementFromPoint(g.clientX,g.clientY);r(),v&&!v.el.contains(w)&&(y("spill"),this.onSpill({dragEl:_,putSortable:b}))}};function sl(){}sl.prototype={startIndex:null,dragStart:function(s){var p=s.oldDraggableIndex;this.startIndex=p},onSpill:function(s){var p=s.dragEl,b=s.putSortable;this.sortable.captureAnimationState(),b&&b.captureAnimationState();var _=Ri(this.sortable.el,this.startIndex,this.options);_?this.sortable.el.insertBefore(p,_):this.sortable.el.appendChild(p),this.sortable.animateAll(),b&&b.animateAll()},drop:au},wn(sl,{pluginName:"revertOnSpill"});function ll(){}ll.prototype={onSpill:function(s){var p=s.dragEl,b=s.putSortable,_=b||this.sortable;_.captureAnimationState(),p.parentNode&&p.parentNode.removeChild(p),_.animateAll()},drop:au},wn(ll,{pluginName:"removeOnSpill"}),Ft.mount(new Md),Ft.mount(ll,sl);const Hd=m=>{const s=m.item;let p=Array.prototype.slice.call(s.parentNode.childNodes);return p=p.filter(b=>b.nodeType!=Node.ELEMENT_NODE||!b.classList.contains("sortable-fallback")),p},Fd=(m,s,p,b,_,E)=>{const j=m.item.parentNode;for(const S of p)j.appendChild(S);if(m.oldIndex==m.newIndex)return;const r=b.getArray(),v=m.item.querySelector("eox-layercontrol-layer").layer.get(_),g=r.find(S=>S.get(_)===v),w=E.dataset.layer,k=r.find(S=>S.get(_)==w);let O,C;for(O=0;O<r.length;O++)if(r[O]==g){b.removeAt(O);break}for(C=0;C<r.length;C++)if(r[C]===k){O>C?b.insertAt(C,g):b.insertAt(C+1,g);break}s.requestUpdate()};function Vd(m,s,p,b){let _=[],E=null;m._sortable=Ft.create(m,{handle:".drag-handle",filter:".drag-handle.disabled",swapThreshold:.5,animation:150,easing:"cubic-bezier(1, 0, 0, 1)",onStart:y=>_=Hd(y),onMove:y=>{E=y.related},onEnd:y=>Fd(y,b,_,s,p,E)})}function zd(m,s,p,b){const _=m.getArray();let E=!1;_.forEach(y=>{const j=y.ol_uid;y.get(s)||(y.set(s,j),E=!0),y.get(p)||(y.set(p,`layer ${j}`),E=!0),E&&b.requestUpdate()})}function cl(m,s,p){let b=[];const _=(E,y,j)=>{b=[...b,...E.filter(v=>v.get(y)===j)];const r=E.filter(v=>v.getLayers);return r.length>0&&r.forEach(v=>_(v.getLayers().getArray(),y,j)),b};return _(m,s,p),b}function Ud(m,s,p){if(!m||!s)return!1;if(!su(m,p))return!0;const b=m.get("minZoom"),_=m.get("maxZoom"),E=s.getView().getZoom();return E>b&&E<_}function su(m,s){const p=m.get("minZoom"),b=m.get("maxZoom");return!!(s&&(p!==-1/0||b!==1/0))}function qd(m,s){var _,E,y;return!m||!s?void 0:m.getLayers?"group":((y=(_=s.getInteractions().getArray().filter(j=>j.freehand_!==void 0).map(j=>j.source_))==null?void 0:_.ol_uid)==null?void 0:y.includes(m.getSource?(E=m.getSource())==null?void 0:E.ol_uid:void 0))?"draw":m.declutter_!==void 0?"vector":"raster"}function lu(m,s){var b;let p={};for(const _ in m){const E=m[_].type;if(E&&E!=="object")p[_]=E==="number"?Number(s[_]):s[_];else if(typeof m[_]=="object"&&((b=m[_])!=null&&b.properties)){const y=lu(m[_].properties,s);Object.keys(y).length>0&&(p[_]=y)}}return p}function Gd(m,s){var E;if(!s||!m.getSource().getTileUrlFunction())return null;const p=new URL(m.getSource().getTileUrlFunction()([0,0,0])),b=Object.fromEntries(p.searchParams.entries()),_=lu(((E=s.schema)==null?void 0:E.properties)||s.schema,b);return Object.keys(_).length?_:null}const Wd=(m,s)=>m==null?void 0:m.filter(p=>["remove","sort"].filter(b=>s!=null&&s.get("layerControlDisable")?b!=="sort":!0).includes(p)),Zd=(m,s)=>m==null?void 0:m.filter(p=>{let b=!0;return["remove","sort"].includes(p)&&(b=!1),p==="info"&&(b=s.get("description")),p==="config"&&(b=s.get("layerConfig")),b}),Jd=(m,s)=>ae`
|
|
46
|
+
<button slot="${m}-icon" class="icon">${s?m:_e}</button>
|
|
47
47
|
`,Yd=m=>ae`
|
|
48
48
|
<button
|
|
49
49
|
class="remove-icon icon"
|
|
50
50
|
@click=${()=>{const{layer:s}=m;s==null||s.set("layerControlOptional",!0),s==null||s.setVisible(!1),m.dispatchEvent(new CustomEvent("changed",{detail:s,bubbles:!0}))}}
|
|
51
51
|
>
|
|
52
|
-
${m.unstyled?"x":
|
|
52
|
+
${m.unstyled?"x":_e}
|
|
53
53
|
</button>
|
|
54
54
|
`,Xd=m=>ae`
|
|
55
|
-
<
|
|
56
|
-
${m?"
|
|
57
|
-
</
|
|
55
|
+
<span class="button sort-icon icon drag-handle">
|
|
56
|
+
${m?"═":_e}
|
|
57
|
+
</span>
|
|
58
58
|
`;/**
|
|
59
59
|
* @license
|
|
60
60
|
* Copyright 2020 Google LLC
|
|
61
61
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
62
|
-
*/const cu=Hs(class extends Fs{constructor(m){if(super(m),m.type!==Ln.PROPERTY&&m.type!==Ln.ATTRIBUTE&&m.type!==Ln.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!mh(m))throw Error("`live` bindings can only contain a single expression")}render(m){return m}update(m,[s]){if(s===Nr||s===
|
|
62
|
+
*/const cu=Hs(class extends Fs{constructor(m){if(super(m),m.type!==Ln.PROPERTY&&m.type!==Ln.ATTRIBUTE&&m.type!==Ln.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!mh(m))throw Error("`live` bindings can only contain a single expression")}render(m){return m}update(m,[s]){if(s===Nr||s===_e)return s;const p=m.element,b=m.name;if(m.type===Ln.PROPERTY){if(s===p[b])return Nr}else if(m.type===Ln.BOOLEAN_ATTRIBUTE){if(!!s===p.hasAttribute(b))return Nr}else if(m.type===Ln.ATTRIBUTE&&p.getAttribute(b)===s+"")return Nr;return Sc(m),s}});/**
|
|
63
63
|
* @license
|
|
64
64
|
* Copyright 2017 Google LLC
|
|
65
65
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
66
|
-
*/class ul extends Fs{constructor(s){if(super(s),this.et=
|
|
66
|
+
*/class ul extends Fs{constructor(s){if(super(s),this.et=_e,s.type!==Ln.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(s){if(s===_e||s==null)return this.vt=void 0,this.et=s;if(s===Nr)return s;if(typeof s!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(s===this.et)return this.vt;this.et=s;const p=[s];return p.raw=p,this.vt={_$litType$:this.constructor.resultType,strings:p,values:[]}}}ul.directiveName="unsafeHTML",ul.resultType=1;const Kd=Hs(ul);/**
|
|
67
67
|
* @license
|
|
68
68
|
* Copyright 2021 Google LLC
|
|
69
69
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
70
|
-
*/function*Ba(m,s){if(m!==void 0){let p=0;for(const b of m)yield s(b,p++)}}var Da=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Qd(m){return m&&m.__esModule&&Object.prototype.hasOwnProperty.call(m,"default")?m.default:m}var uu={exports:{}};/*! For license information please see jsoneditor.js.LICENSE.txt */(function(m,s){(function(p,b){m.exports=b()})(self,()=>(()=>{var p={9662:(y,j,r)=>{var v=r(614),g=r(6330),w=TypeError;y.exports=function(k){if(v(k))return k;throw w(g(k)+" is not a function")}},9483:(y,j,r)=>{var v=r(4411),g=r(6330),w=TypeError;y.exports=function(k){if(v(k))return k;throw w(g(k)+" is not a constructor")}},6077:(y,j,r)=>{var v=r(614),g=String,w=TypeError;y.exports=function(k){if(typeof k=="object"||v(k))return k;throw w("Can't set "+g(k)+" as a prototype")}},1223:(y,j,r)=>{var v=r(5112),g=r(30),w=r(3070).f,k=v("unscopables"),O=Array.prototype;O[k]==null&&w(O,k,{configurable:!0,value:g(null)}),y.exports=function(C){O[k][C]=!0}},1530:(y,j,r)=>{var v=r(8710).charAt;y.exports=function(g,w,k){return w+(k?v(g,w).length:1)}},5787:(y,j,r)=>{var v=r(7976),g=TypeError;y.exports=function(w,k){if(v(k,w))return w;throw g("Incorrect invocation")}},9670:(y,j,r)=>{var v=r(111),g=String,w=TypeError;y.exports=function(k){if(v(k))return k;throw w(g(k)+" is not an object")}},8533:(y,j,r)=>{var v=r(2092).forEach,g=r(9341)("forEach");y.exports=g?[].forEach:function(w){return v(this,w,arguments.length>1?arguments[1]:void 0)}},8457:(y,j,r)=>{var v=r(9974),g=r(6916),w=r(7908),k=r(3411),O=r(7659),C=r(4411),S=r(6244),T=r(6135),A=r(4121),R=r(1246),I=Array;y.exports=function($){var M=w($),B=C(this),q=arguments.length,F=q>1?arguments[1]:void 0,N=F!==void 0;N&&(F=v(F,q>2?arguments[2]:void 0));var U,H,X,Y,K,tt,it=R(M),st=0;if(!it||this===I&&O(it))for(U=S(M),H=B?new this(U):I(U);U>st;st++)tt=N?F(M[st],st):M[st],T(H,st,tt);else for(K=(Y=A(M,it)).next,H=B?new this:[];!(X=g(K,Y)).done;st++)tt=N?k(Y,F,[X.value,st],!0):X.value,T(H,st,tt);return H.length=st,H}},1318:(y,j,r)=>{var v=r(5656),g=r(1400),w=r(6244),k=function(O){return function(C,S,T){var A,R=v(C),I=w(R),$=g(T,I);if(O&&S!=S){for(;I>$;)if((A=R[$++])!=A)return!0}else for(;I>$;$++)if((O||$ in R)&&R[$]===S)return O||$||0;return!O&&-1}};y.exports={includes:k(!0),indexOf:k(!1)}},2092:(y,j,r)=>{var v=r(9974),g=r(1702),w=r(8361),k=r(7908),O=r(6244),C=r(5417),S=g([].push),T=function(A){var R=A==1,I=A==2,$=A==3,M=A==4,B=A==6,q=A==7,F=A==5||B;return function(N,U,H,X){for(var Y,K,tt=k(N),it=w(tt),st=v(U,H),yt=O(it),ct=0,Et=X||C,At=R?Et(N,yt):I||q?Et(N,0):void 0;yt>ct;ct++)if((F||ct in it)&&(K=st(Y=it[ct],ct,tt),A))if(R)At[ct]=K;else if(K)switch(A){case 3:return!0;case 5:return Y;case 6:return ct;case 2:S(At,Y)}else switch(A){case 4:return!1;case 7:S(At,Y)}return B?-1:$||M?M:At}};y.exports={forEach:T(0),map:T(1),filter:T(2),some:T(3),every:T(4),find:T(5),findIndex:T(6),filterReject:T(7)}},1194:(y,j,r)=>{var v=r(7293),g=r(5112),w=r(7392),k=g("species");y.exports=function(O){return w>=51||!v(function(){var C=[];return(C.constructor={})[k]=function(){return{foo:1}},C[O](Boolean).foo!==1})}},9341:(y,j,r)=>{var v=r(7293);y.exports=function(g,w){var k=[][g];return!!k&&v(function(){k.call(null,w||function(){return 1},1)})}},3671:(y,j,r)=>{var v=r(9662),g=r(7908),w=r(8361),k=r(6244),O=TypeError,C=function(S){return function(T,A,R,I){v(A);var $=g(T),M=w($),B=k($),q=S?B-1:0,F=S?-1:1;if(R<2)for(;;){if(q in M){I=M[q],q+=F;break}if(q+=F,S?q<0:B<=q)throw O("Reduce of empty array with no initial value")}for(;S?q>=0:B>q;q+=F)q in M&&(I=A(I,M[q],q,$));return I}};y.exports={left:C(!1),right:C(!0)}},3658:(y,j,r)=>{var v=r(9781),g=r(3157),w=TypeError,k=Object.getOwnPropertyDescriptor,O=v&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(C){return C instanceof TypeError}}();y.exports=O?function(C,S){if(g(C)&&!k(C,"length").writable)throw w("Cannot set read only .length");return C.length=S}:function(C,S){return C.length=S}},1589:(y,j,r)=>{var v=r(1400),g=r(6244),w=r(6135),k=Array,O=Math.max;y.exports=function(C,S,T){for(var A=g(C),R=v(S,A),I=v(T===void 0?A:T,A),$=k(O(I-R,0)),M=0;R<I;R++,M++)w($,M,C[R]);return $.length=M,$}},206:(y,j,r)=>{var v=r(1702);y.exports=v([].slice)},4362:(y,j,r)=>{var v=r(1589),g=Math.floor,w=function(C,S){var T=C.length,A=g(T/2);return T<8?k(C,S):O(C,w(v(C,0,A),S),w(v(C,A),S),S)},k=function(C,S){for(var T,A,R=C.length,I=1;I<R;){for(A=I,T=C[I];A&&S(C[A-1],T)>0;)C[A]=C[--A];A!==I++&&(C[A]=T)}return C},O=function(C,S,T,A){for(var R=S.length,I=T.length,$=0,M=0;$<R||M<I;)C[$+M]=$<R&&M<I?A(S[$],T[M])<=0?S[$++]:T[M++]:$<R?S[$++]:T[M++];return C};y.exports=w},7475:(y,j,r)=>{var v=r(3157),g=r(4411),w=r(111),k=r(5112)("species"),O=Array;y.exports=function(C){var S;return v(C)&&(S=C.constructor,(g(S)&&(S===O||v(S.prototype))||w(S)&&(S=S[k])===null)&&(S=void 0)),S===void 0?O:S}},5417:(y,j,r)=>{var v=r(7475);y.exports=function(g,w){return new(v(g))(w===0?0:w)}},3411:(y,j,r)=>{var v=r(9670),g=r(9212);y.exports=function(w,k,O,C){try{return C?k(v(O)[0],O[1]):k(O)}catch(S){g(w,"throw",S)}}},7072:(y,j,r)=>{var v=r(5112)("iterator"),g=!1;try{var w=0,k={next:function(){return{done:!!w++}},return:function(){g=!0}};k[v]=function(){return this},Array.from(k,function(){throw 2})}catch{}y.exports=function(O,C){if(!C&&!g)return!1;var S=!1;try{var T={};T[v]=function(){return{next:function(){return{done:S=!0}}}},O(T)}catch{}return S}},4326:(y,j,r)=>{var v=r(1702),g=v({}.toString),w=v("".slice);y.exports=function(k){return w(g(k),8,-1)}},648:(y,j,r)=>{var v=r(1694),g=r(614),w=r(4326),k=r(5112)("toStringTag"),O=Object,C=w(function(){return arguments}())=="Arguments";y.exports=v?w:function(S){var T,A,R;return S===void 0?"Undefined":S===null?"Null":typeof(A=function(I,$){try{return I[$]}catch{}}(T=O(S),k))=="string"?A:C?w(T):(R=w(T))=="Object"&&g(T.callee)?"Arguments":R}},9920:(y,j,r)=>{var v=r(2597),g=r(3887),w=r(1236),k=r(3070);y.exports=function(O,C,S){for(var T=g(C),A=k.f,R=w.f,I=0;I<T.length;I++){var $=T[I];v(O,$)||S&&v(S,$)||A(O,$,R(C,$))}}},4964:(y,j,r)=>{var v=r(5112)("match");y.exports=function(g){var w=/./;try{"/./"[g](w)}catch{try{return w[v]=!1,"/./"[g](w)}catch{}}return!1}},8544:(y,j,r)=>{var v=r(7293);y.exports=!v(function(){function g(){}return g.prototype.constructor=null,Object.getPrototypeOf(new g)!==g.prototype})},6178:y=>{y.exports=function(j,r){return{value:j,done:r}}},8880:(y,j,r)=>{var v=r(9781),g=r(3070),w=r(9114);y.exports=v?function(k,O,C){return g.f(k,O,w(1,C))}:function(k,O,C){return k[O]=C,k}},9114:y=>{y.exports=function(j,r){return{enumerable:!(1&j),configurable:!(2&j),writable:!(4&j),value:r}}},6135:(y,j,r)=>{var v=r(4948),g=r(3070),w=r(9114);y.exports=function(k,O,C){var S=v(O);S in k?g.f(k,S,w(0,C)):k[S]=C}},5573:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(6650).start,k=RangeError,O=isFinite,C=Math.abs,S=Date.prototype,T=S.toISOString,A=v(S.getTime),R=v(S.getUTCDate),I=v(S.getUTCFullYear),$=v(S.getUTCHours),M=v(S.getUTCMilliseconds),B=v(S.getUTCMinutes),q=v(S.getUTCMonth),F=v(S.getUTCSeconds);y.exports=g(function(){return T.call(new Date(-50000000000001))!="0385-07-25T07:06:39.999Z"})||!g(function(){T.call(new Date(NaN))})?function(){if(!O(A(this)))throw k("Invalid time value");var N=this,U=I(N),H=M(N),X=U<0?"-":U>9999?"+":"";return X+w(C(U),X?6:4,0)+"-"+w(q(N)+1,2,0)+"-"+w(R(N),2,0)+"T"+w($(N),2,0)+":"+w(B(N),2,0)+":"+w(F(N),2,0)+"."+w(H,3,0)+"Z"}:T},8709:(y,j,r)=>{var v=r(9670),g=r(2140),w=TypeError;y.exports=function(k){if(v(this),k==="string"||k==="default")k="string";else if(k!=="number")throw w("Incorrect hint");return g(this,k)}},7045:(y,j,r)=>{var v=r(6339),g=r(3070);y.exports=function(w,k,O){return O.get&&v(O.get,k,{getter:!0}),O.set&&v(O.set,k,{setter:!0}),g.f(w,k,O)}},8052:(y,j,r)=>{var v=r(614),g=r(3070),w=r(6339),k=r(3072);y.exports=function(O,C,S,T){T||(T={});var A=T.enumerable,R=T.name!==void 0?T.name:C;if(v(S)&&w(S,R,T),T.global)A?O[C]=S:k(C,S);else{try{T.unsafe?O[C]&&(A=!0):delete O[C]}catch{}A?O[C]=S:g.f(O,C,{value:S,enumerable:!1,configurable:!T.nonConfigurable,writable:!T.nonWritable})}return O}},3072:(y,j,r)=>{var v=r(7854),g=Object.defineProperty;y.exports=function(w,k){try{g(v,w,{value:k,configurable:!0,writable:!0})}catch{v[w]=k}return k}},5117:(y,j,r)=>{var v=r(6330),g=TypeError;y.exports=function(w,k){if(!delete w[k])throw g("Cannot delete property "+v(k)+" of "+v(w))}},9781:(y,j,r)=>{var v=r(7293);y.exports=!v(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7})},4154:y=>{var j=typeof document=="object"&&document.all,r=j===void 0&&j!==void 0;y.exports={all:j,IS_HTMLDDA:r}},317:(y,j,r)=>{var v=r(7854),g=r(111),w=v.document,k=g(w)&&g(w.createElement);y.exports=function(O){return k?w.createElement(O):{}}},7207:y=>{var j=TypeError;y.exports=function(r){if(r>9007199254740991)throw j("Maximum allowed index exceeded");return r}},8324:y=>{y.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},8509:(y,j,r)=>{var v=r(317)("span").classList,g=v&&v.constructor&&v.constructor.prototype;y.exports=g===Object.prototype?void 0:g},8886:(y,j,r)=>{var v=r(8113).match(/firefox\/(\d+)/i);y.exports=!!v&&+v[1]},7871:(y,j,r)=>{var v=r(3823),g=r(5268);y.exports=!v&&!g&&typeof window=="object"&&typeof document=="object"},9363:y=>{y.exports=typeof Bun=="function"&&Bun&&typeof Bun.version=="string"},3823:y=>{y.exports=typeof Deno=="object"&&Deno&&typeof Deno.version=="object"},256:(y,j,r)=>{var v=r(8113);y.exports=/MSIE|Trident/.test(v)},1528:(y,j,r)=>{var v=r(8113);y.exports=/ipad|iphone|ipod/i.test(v)&&typeof Pebble<"u"},8334:(y,j,r)=>{var v=r(8113);y.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(v)},5268:(y,j,r)=>{var v=r(4326);y.exports=typeof process<"u"&&v(process)=="process"},1036:(y,j,r)=>{var v=r(8113);y.exports=/web0s(?!.*chrome)/i.test(v)},8113:y=>{y.exports=typeof navigator<"u"&&String(navigator.userAgent)||""},7392:(y,j,r)=>{var v,g,w=r(7854),k=r(8113),O=w.process,C=w.Deno,S=O&&O.versions||C&&C.version,T=S&&S.v8;T&&(g=(v=T.split("."))[0]>0&&v[0]<4?1:+(v[0]+v[1])),!g&&k&&(!(v=k.match(/Edge\/(\d+)/))||v[1]>=74)&&(v=k.match(/Chrome\/(\d+)/))&&(g=+v[1]),y.exports=g},8008:(y,j,r)=>{var v=r(8113).match(/AppleWebKit\/(\d+)\./);y.exports=!!v&&+v[1]},748:y=>{y.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},2109:(y,j,r)=>{var v=r(7854),g=r(1236).f,w=r(8880),k=r(8052),O=r(3072),C=r(9920),S=r(4705);y.exports=function(T,A){var R,I,$,M,B,q=T.target,F=T.global,N=T.stat;if(R=F?v:N?v[q]||O(q,{}):(v[q]||{}).prototype)for(I in A){if(M=A[I],$=T.dontCallGetSet?(B=g(R,I))&&B.value:R[I],!S(F?I:q+(N?".":"#")+I,T.forced)&&$!==void 0){if(typeof M==typeof $)continue;C(M,$)}(T.sham||$&&$.sham)&&w(M,"sham",!0),k(R,I,M,T)}}},7293:y=>{y.exports=function(j){try{return!!j()}catch{return!0}}},7007:(y,j,r)=>{r(4916);var v=r(1470),g=r(8052),w=r(2261),k=r(7293),O=r(5112),C=r(8880),S=O("species"),T=RegExp.prototype;y.exports=function(A,R,I,$){var M=O(A),B=!k(function(){var U={};return U[M]=function(){return 7},""[A](U)!=7}),q=B&&!k(function(){var U=!1,H=/a/;return A==="split"&&((H={}).constructor={},H.constructor[S]=function(){return H},H.flags="",H[M]=/./[M]),H.exec=function(){return U=!0,null},H[M](""),!U});if(!B||!q||I){var F=v(/./[M]),N=R(M,""[A],function(U,H,X,Y,K){var tt=v(U),it=H.exec;return it===w||it===T.exec?B&&!K?{done:!0,value:F(H,X,Y)}:{done:!0,value:tt(X,H,Y)}:{done:!1}});g(String.prototype,A,N[0]),g(T,M,N[1])}$&&C(T[M],"sham",!0)}},2104:(y,j,r)=>{var v=r(4374),g=Function.prototype,w=g.apply,k=g.call;y.exports=typeof Reflect=="object"&&Reflect.apply||(v?k.bind(w):function(){return k.apply(w,arguments)})},9974:(y,j,r)=>{var v=r(1470),g=r(9662),w=r(4374),k=v(v.bind);y.exports=function(O,C){return g(O),C===void 0?O:w?k(O,C):function(){return O.apply(C,arguments)}}},4374:(y,j,r)=>{var v=r(7293);y.exports=!v(function(){var g=(function(){}).bind();return typeof g!="function"||g.hasOwnProperty("prototype")})},7065:(y,j,r)=>{var v=r(1702),g=r(9662),w=r(111),k=r(2597),O=r(206),C=r(4374),S=Function,T=v([].concat),A=v([].join),R={},I=function($,M,B){if(!k(R,M)){for(var q=[],F=0;F<M;F++)q[F]="a["+F+"]";R[M]=S("C,a","return new C("+A(q,",")+")")}return R[M]($,B)};y.exports=C?S.bind:function($){var M=g(this),B=M.prototype,q=O(arguments,1),F=function(){var N=T(q,O(arguments));return this instanceof F?I(M,N.length,N):M.apply($,N)};return w(B)&&(F.prototype=B),F}},6916:(y,j,r)=>{var v=r(4374),g=Function.prototype.call;y.exports=v?g.bind(g):function(){return g.apply(g,arguments)}},6530:(y,j,r)=>{var v=r(9781),g=r(2597),w=Function.prototype,k=v&&Object.getOwnPropertyDescriptor,O=g(w,"name"),C=O&&(function(){}).name==="something",S=O&&(!v||v&&k(w,"name").configurable);y.exports={EXISTS:O,PROPER:C,CONFIGURABLE:S}},5668:(y,j,r)=>{var v=r(1702),g=r(9662);y.exports=function(w,k,O){try{return v(g(Object.getOwnPropertyDescriptor(w,k)[O]))}catch{}}},1470:(y,j,r)=>{var v=r(4326),g=r(1702);y.exports=function(w){if(v(w)==="Function")return g(w)}},1702:(y,j,r)=>{var v=r(4374),g=Function.prototype,w=g.call,k=v&&g.bind.bind(w,w);y.exports=v?k:function(O){return function(){return w.apply(O,arguments)}}},5005:(y,j,r)=>{var v=r(7854),g=r(614),w=function(k){return g(k)?k:void 0};y.exports=function(k,O){return arguments.length<2?w(v[k]):v[k]&&v[k][O]}},1246:(y,j,r)=>{var v=r(648),g=r(8173),w=r(8554),k=r(7497),O=r(5112)("iterator");y.exports=function(C){if(!w(C))return g(C,O)||g(C,"@@iterator")||k[v(C)]}},4121:(y,j,r)=>{var v=r(6916),g=r(9662),w=r(9670),k=r(6330),O=r(1246),C=TypeError;y.exports=function(S,T){var A=arguments.length<2?O(S):T;if(g(A))return w(v(A,S));throw C(k(S)+" is not iterable")}},8044:(y,j,r)=>{var v=r(1702),g=r(3157),w=r(614),k=r(4326),O=r(1340),C=v([].push);y.exports=function(S){if(w(S))return S;if(g(S)){for(var T=S.length,A=[],R=0;R<T;R++){var I=S[R];typeof I=="string"?C(A,I):typeof I!="number"&&k(I)!="Number"&&k(I)!="String"||C(A,O(I))}var $=A.length,M=!0;return function(B,q){if(M)return M=!1,q;if(g(this))return q;for(var F=0;F<$;F++)if(A[F]===B)return q}}}},8173:(y,j,r)=>{var v=r(9662),g=r(8554);y.exports=function(w,k){var O=w[k];return g(O)?void 0:v(O)}},647:(y,j,r)=>{var v=r(1702),g=r(7908),w=Math.floor,k=v("".charAt),O=v("".replace),C=v("".slice),S=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,T=/\$([$&'`]|\d{1,2})/g;y.exports=function(A,R,I,$,M,B){var q=I+A.length,F=$.length,N=T;return M!==void 0&&(M=g(M),N=S),O(B,N,function(U,H){var X;switch(k(H,0)){case"$":return"$";case"&":return A;case"`":return C(R,0,I);case"'":return C(R,q);case"<":X=M[C(H,1,-1)];break;default:var Y=+H;if(Y===0)return U;if(Y>F){var K=w(Y/10);return K===0?U:K<=F?$[K-1]===void 0?k(H,1):$[K-1]+k(H,1):U}X=$[Y-1]}return X===void 0?"":X})}},7854:(y,j,r)=>{var v=function(g){return g&&g.Math==Math&&g};y.exports=v(typeof globalThis=="object"&&globalThis)||v(typeof window=="object"&&window)||v(typeof self=="object"&&self)||v(typeof r.g=="object"&&r.g)||function(){return this}()||Function("return this")()},2597:(y,j,r)=>{var v=r(1702),g=r(7908),w=v({}.hasOwnProperty);y.exports=Object.hasOwn||function(k,O){return w(g(k),O)}},3501:y=>{y.exports={}},842:y=>{y.exports=function(j,r){try{arguments.length==1?console.error(j):console.error(j,r)}catch{}}},490:(y,j,r)=>{var v=r(5005);y.exports=v("document","documentElement")},4664:(y,j,r)=>{var v=r(9781),g=r(7293),w=r(317);y.exports=!v&&!g(function(){return Object.defineProperty(w("div"),"a",{get:function(){return 7}}).a!=7})},8361:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(4326),k=Object,O=v("".split);y.exports=g(function(){return!k("z").propertyIsEnumerable(0)})?function(C){return w(C)=="String"?O(C,""):k(C)}:k},9587:(y,j,r)=>{var v=r(614),g=r(111),w=r(7674);y.exports=function(k,O,C){var S,T;return w&&v(S=O.constructor)&&S!==C&&g(T=S.prototype)&&T!==C.prototype&&w(k,T),k}},2788:(y,j,r)=>{var v=r(1702),g=r(614),w=r(5465),k=v(Function.toString);g(w.inspectSource)||(w.inspectSource=function(O){return k(O)}),y.exports=w.inspectSource},9909:(y,j,r)=>{var v,g,w,k=r(4811),O=r(7854),C=r(111),S=r(8880),T=r(2597),A=r(5465),R=r(6200),I=r(3501),$="Object already initialized",M=O.TypeError,B=O.WeakMap;if(k||A.state){var q=A.state||(A.state=new B);q.get=q.get,q.has=q.has,q.set=q.set,v=function(N,U){if(q.has(N))throw M($);return U.facade=N,q.set(N,U),U},g=function(N){return q.get(N)||{}},w=function(N){return q.has(N)}}else{var F=R("state");I[F]=!0,v=function(N,U){if(T(N,F))throw M($);return U.facade=N,S(N,F,U),U},g=function(N){return T(N,F)?N[F]:{}},w=function(N){return T(N,F)}}y.exports={set:v,get:g,has:w,enforce:function(N){return w(N)?g(N):v(N,{})},getterFor:function(N){return function(U){var H;if(!C(U)||(H=g(U)).type!==N)throw M("Incompatible receiver, "+N+" required");return H}}}},7659:(y,j,r)=>{var v=r(5112),g=r(7497),w=v("iterator"),k=Array.prototype;y.exports=function(O){return O!==void 0&&(g.Array===O||k[w]===O)}},3157:(y,j,r)=>{var v=r(4326);y.exports=Array.isArray||function(g){return v(g)=="Array"}},614:(y,j,r)=>{var v=r(4154),g=v.all;y.exports=v.IS_HTMLDDA?function(w){return typeof w=="function"||w===g}:function(w){return typeof w=="function"}},4411:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(614),k=r(648),O=r(5005),C=r(2788),S=function(){},T=[],A=O("Reflect","construct"),R=/^\s*(?:class|function)\b/,I=v(R.exec),$=!R.exec(S),M=function(q){if(!w(q))return!1;try{return A(S,T,q),!0}catch{return!1}},B=function(q){if(!w(q))return!1;switch(k(q)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return $||!!I(R,C(q))}catch{return!0}};B.sham=!0,y.exports=!A||g(function(){var q;return M(M.call)||!M(Object)||!M(function(){q=!0})||q})?B:M},5032:(y,j,r)=>{var v=r(2597);y.exports=function(g){return g!==void 0&&(v(g,"value")||v(g,"writable"))}},4705:(y,j,r)=>{var v=r(7293),g=r(614),w=/#|\.prototype\./,k=function(A,R){var I=C[O(A)];return I==T||I!=S&&(g(R)?v(R):!!R)},O=k.normalize=function(A){return String(A).replace(w,".").toLowerCase()},C=k.data={},S=k.NATIVE="N",T=k.POLYFILL="P";y.exports=k},8554:y=>{y.exports=function(j){return j==null}},111:(y,j,r)=>{var v=r(614),g=r(4154),w=g.all;y.exports=g.IS_HTMLDDA?function(k){return typeof k=="object"?k!==null:v(k)||k===w}:function(k){return typeof k=="object"?k!==null:v(k)}},1913:y=>{y.exports=!1},7850:(y,j,r)=>{var v=r(111),g=r(4326),w=r(5112)("match");y.exports=function(k){var O;return v(k)&&((O=k[w])!==void 0?!!O:g(k)=="RegExp")}},2190:(y,j,r)=>{var v=r(5005),g=r(614),w=r(7976),k=r(3307),O=Object;y.exports=k?function(C){return typeof C=="symbol"}:function(C){var S=v("Symbol");return g(S)&&w(S.prototype,O(C))}},408:(y,j,r)=>{var v=r(9974),g=r(6916),w=r(9670),k=r(6330),O=r(7659),C=r(6244),S=r(7976),T=r(4121),A=r(1246),R=r(9212),I=TypeError,$=function(B,q){this.stopped=B,this.result=q},M=$.prototype;y.exports=function(B,q,F){var N,U,H,X,Y,K,tt,it=F&&F.that,st=!(!F||!F.AS_ENTRIES),yt=!(!F||!F.IS_RECORD),ct=!(!F||!F.IS_ITERATOR),Et=!(!F||!F.INTERRUPTED),At=v(q,it),Vt=function(wt){return N&&R(N,"normal",wt),new $(!0,wt)},lt=function(wt){return st?(w(wt),Et?At(wt[0],wt[1],Vt):At(wt[0],wt[1])):Et?At(wt,Vt):At(wt)};if(yt)N=B.iterator;else if(ct)N=B;else{if(!(U=A(B)))throw I(k(B)+" is not iterable");if(O(U)){for(H=0,X=C(B);X>H;H++)if((Y=lt(B[H]))&&S(M,Y))return Y;return new $(!1)}N=T(B,U)}for(K=yt?B.next:N.next;!(tt=g(K,N)).done;){try{Y=lt(tt.value)}catch(wt){R(N,"throw",wt)}if(typeof Y=="object"&&Y&&S(M,Y))return Y}return new $(!1)}},9212:(y,j,r)=>{var v=r(6916),g=r(9670),w=r(8173);y.exports=function(k,O,C){var S,T;g(k);try{if(!(S=w(k,"return"))){if(O==="throw")throw C;return C}S=v(S,k)}catch(A){T=!0,S=A}if(O==="throw")throw C;if(T)throw S;return g(S),C}},3061:(y,j,r)=>{var v=r(3383).IteratorPrototype,g=r(30),w=r(9114),k=r(8003),O=r(7497),C=function(){return this};y.exports=function(S,T,A,R){var I=T+" Iterator";return S.prototype=g(v,{next:w(+!R,A)}),k(S,I,!1,!0),O[I]=C,S}},1656:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(1913),k=r(6530),O=r(614),C=r(3061),S=r(9518),T=r(7674),A=r(8003),R=r(8880),I=r(8052),$=r(5112),M=r(7497),B=r(3383),q=k.PROPER,F=k.CONFIGURABLE,N=B.IteratorPrototype,U=B.BUGGY_SAFARI_ITERATORS,H=$("iterator"),X="keys",Y="values",K="entries",tt=function(){return this};y.exports=function(it,st,yt,ct,Et,At,Vt){C(yt,st,ct);var lt,wt,_t,Ut=function(xt){if(xt===Et&&Bt)return Bt;if(!U&&xt in St)return St[xt];switch(xt){case X:case Y:case K:return function(){return new yt(this,xt)}}return function(){return new yt(this)}},Kt=st+" Iterator",fe=!1,St=it.prototype,jt=St[H]||St["@@iterator"]||Et&&St[Et],Bt=!U&&jt||Ut(Et),qt=st=="Array"&&St.entries||jt;if(qt&&(lt=S(qt.call(new it)))!==Object.prototype&<.next&&(w||S(lt)===N||(T?T(lt,N):O(lt[H])||I(lt,H,tt)),A(lt,Kt,!0,!0),w&&(M[Kt]=tt)),q&&Et==Y&&jt&&jt.name!==Y&&(!w&&F?R(St,"name",Y):(fe=!0,Bt=function(){return g(jt,this)})),Et)if(wt={values:Ut(Y),keys:At?Bt:Ut(X),entries:Ut(K)},Vt)for(_t in wt)(U||fe||!(_t in St))&&I(St,_t,wt[_t]);else v({target:st,proto:!0,forced:U||fe},wt);return w&&!Vt||St[H]===Bt||I(St,H,Bt,{name:Et}),M[st]=Bt,wt}},3383:(y,j,r)=>{var v,g,w,k=r(7293),O=r(614),C=r(111),S=r(30),T=r(9518),A=r(8052),R=r(5112),I=r(1913),$=R("iterator"),M=!1;[].keys&&("next"in(w=[].keys())?(g=T(T(w)))!==Object.prototype&&(v=g):M=!0),!C(v)||k(function(){var B={};return v[$].call(B)!==B})?v={}:I&&(v=S(v)),O(v[$])||A(v,$,function(){return this}),y.exports={IteratorPrototype:v,BUGGY_SAFARI_ITERATORS:M}},7497:y=>{y.exports={}},6244:(y,j,r)=>{var v=r(7466);y.exports=function(g){return v(g.length)}},6339:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(614),k=r(2597),O=r(9781),C=r(6530).CONFIGURABLE,S=r(2788),T=r(9909),A=T.enforce,R=T.get,I=String,$=Object.defineProperty,M=v("".slice),B=v("".replace),q=v([].join),F=O&&!g(function(){return $(function(){},"length",{value:8}).length!==8}),N=String(String).split("String"),U=y.exports=function(H,X,Y){M(I(X),0,7)==="Symbol("&&(X="["+B(I(X),/^Symbol\(([^)]*)\)/,"$1")+"]"),Y&&Y.getter&&(X="get "+X),Y&&Y.setter&&(X="set "+X),(!k(H,"name")||C&&H.name!==X)&&(O?$(H,"name",{value:X,configurable:!0}):H.name=X),F&&Y&&k(Y,"arity")&&H.length!==Y.arity&&$(H,"length",{value:Y.arity});try{Y&&k(Y,"constructor")&&Y.constructor?O&&$(H,"prototype",{writable:!1}):H.prototype&&(H.prototype=void 0)}catch{}var K=A(H);return k(K,"source")||(K.source=q(N,typeof X=="string"?X:"")),H};Function.prototype.toString=U(function(){return w(this)&&R(this).source||S(this)},"toString")},4758:y=>{var j=Math.ceil,r=Math.floor;y.exports=Math.trunc||function(v){var g=+v;return(g>0?r:j)(g)}},5948:(y,j,r)=>{var v,g,w,k,O,C=r(7854),S=r(9974),T=r(1236).f,A=r(261).set,R=r(8572),I=r(8334),$=r(1528),M=r(1036),B=r(5268),q=C.MutationObserver||C.WebKitMutationObserver,F=C.document,N=C.process,U=C.Promise,H=T(C,"queueMicrotask"),X=H&&H.value;if(!X){var Y=new R,K=function(){var tt,it;for(B&&(tt=N.domain)&&tt.exit();it=Y.get();)try{it()}catch(st){throw Y.head&&v(),st}tt&&tt.enter()};I||B||M||!q||!F?!$&&U&&U.resolve?((k=U.resolve(void 0)).constructor=U,O=S(k.then,k),v=function(){O(K)}):B?v=function(){N.nextTick(K)}:(A=S(A,C),v=function(){A(K)}):(g=!0,w=F.createTextNode(""),new q(K).observe(w,{characterData:!0}),v=function(){w.data=g=!g}),X=function(tt){Y.head||v(),Y.add(tt)}}y.exports=X},8523:(y,j,r)=>{var v=r(9662),g=TypeError,w=function(k){var O,C;this.promise=new k(function(S,T){if(O!==void 0||C!==void 0)throw g("Bad Promise constructor");O=S,C=T}),this.resolve=v(O),this.reject=v(C)};y.exports.f=function(k){return new w(k)}},3929:(y,j,r)=>{var v=r(7850),g=TypeError;y.exports=function(w){if(v(w))throw g("The method doesn't accept regular expressions");return w}},2814:(y,j,r)=>{var v=r(7854),g=r(7293),w=r(1702),k=r(1340),O=r(3111).trim,C=r(1361),S=w("".charAt),T=v.parseFloat,A=v.Symbol,R=A&&A.iterator,I=1/T(C+"-0")!=-1/0||R&&!g(function(){T(Object(R))});y.exports=I?function($){var M=O(k($)),B=T(M);return B===0&&S(M,0)=="-"?-0:B}:T},3009:(y,j,r)=>{var v=r(7854),g=r(7293),w=r(1702),k=r(1340),O=r(3111).trim,C=r(1361),S=v.parseInt,T=v.Symbol,A=T&&T.iterator,R=/^[+-]?0x/i,I=w(R.exec),$=S(C+"08")!==8||S(C+"0x16")!==22||A&&!g(function(){S(Object(A))});y.exports=$?function(M,B){var q=O(k(M));return S(q,B>>>0||(I(R,q)?16:10))}:S},1574:(y,j,r)=>{var v=r(9781),g=r(1702),w=r(6916),k=r(7293),O=r(1956),C=r(5181),S=r(5296),T=r(7908),A=r(8361),R=Object.assign,I=Object.defineProperty,$=g([].concat);y.exports=!R||k(function(){if(v&&R({b:1},R(I({},"a",{enumerable:!0,get:function(){I(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var M={},B={},q=Symbol(),F="abcdefghijklmnopqrst";return M[q]=7,F.split("").forEach(function(N){B[N]=N}),R({},M)[q]!=7||O(R({},B)).join("")!=F})?function(M,B){for(var q=T(M),F=arguments.length,N=1,U=C.f,H=S.f;F>N;)for(var X,Y=A(arguments[N++]),K=U?$(O(Y),U(Y)):O(Y),tt=K.length,it=0;tt>it;)X=K[it++],v&&!w(H,Y,X)||(q[X]=Y[X]);return q}:R},30:(y,j,r)=>{var v,g=r(9670),w=r(6048),k=r(748),O=r(3501),C=r(490),S=r(317),T=r(6200),A="prototype",R="script",I=T("IE_PROTO"),$=function(){},M=function(F){return"<"+R+">"+F+"</"+R+">"},B=function(F){F.write(M("")),F.close();var N=F.parentWindow.Object;return F=null,N},q=function(){try{v=new ActiveXObject("htmlfile")}catch{}var F,N,U;q=typeof document<"u"?document.domain&&v?B(v):(N=S("iframe"),U="java"+R+":",N.style.display="none",C.appendChild(N),N.src=String(U),(F=N.contentWindow.document).open(),F.write(M("document.F=Object")),F.close(),F.F):B(v);for(var H=k.length;H--;)delete q[A][k[H]];return q()};O[I]=!0,y.exports=Object.create||function(F,N){var U;return F!==null?($[A]=g(F),U=new $,$[A]=null,U[I]=F):U=q(),N===void 0?U:w.f(U,N)}},6048:(y,j,r)=>{var v=r(9781),g=r(3353),w=r(3070),k=r(9670),O=r(5656),C=r(1956);j.f=v&&!g?Object.defineProperties:function(S,T){k(S);for(var A,R=O(T),I=C(T),$=I.length,M=0;$>M;)w.f(S,A=I[M++],R[A]);return S}},3070:(y,j,r)=>{var v=r(9781),g=r(4664),w=r(3353),k=r(9670),O=r(4948),C=TypeError,S=Object.defineProperty,T=Object.getOwnPropertyDescriptor,A="enumerable",R="configurable",I="writable";j.f=v?w?function($,M,B){if(k($),M=O(M),k(B),typeof $=="function"&&M==="prototype"&&"value"in B&&I in B&&!B[I]){var q=T($,M);q&&q[I]&&($[M]=B.value,B={configurable:R in B?B[R]:q[R],enumerable:A in B?B[A]:q[A],writable:!1})}return S($,M,B)}:S:function($,M,B){if(k($),M=O(M),k(B),g)try{return S($,M,B)}catch{}if("get"in B||"set"in B)throw C("Accessors not supported");return"value"in B&&($[M]=B.value),$}},1236:(y,j,r)=>{var v=r(9781),g=r(6916),w=r(5296),k=r(9114),O=r(5656),C=r(4948),S=r(2597),T=r(4664),A=Object.getOwnPropertyDescriptor;j.f=v?A:function(R,I){if(R=O(R),I=C(I),T)try{return A(R,I)}catch{}if(S(R,I))return k(!g(w.f,R,I),R[I])}},1156:(y,j,r)=>{var v=r(4326),g=r(5656),w=r(8006).f,k=r(1589),O=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];y.exports.f=function(C){return O&&v(C)=="Window"?function(S){try{return w(S)}catch{return k(O)}}(C):w(g(C))}},8006:(y,j,r)=>{var v=r(6324),g=r(748).concat("length","prototype");j.f=Object.getOwnPropertyNames||function(w){return v(w,g)}},5181:(y,j)=>{j.f=Object.getOwnPropertySymbols},9518:(y,j,r)=>{var v=r(2597),g=r(614),w=r(7908),k=r(6200),O=r(8544),C=k("IE_PROTO"),S=Object,T=S.prototype;y.exports=O?S.getPrototypeOf:function(A){var R=w(A);if(v(R,C))return R[C];var I=R.constructor;return g(I)&&R instanceof I?I.prototype:R instanceof S?T:null}},7976:(y,j,r)=>{var v=r(1702);y.exports=v({}.isPrototypeOf)},6324:(y,j,r)=>{var v=r(1702),g=r(2597),w=r(5656),k=r(1318).indexOf,O=r(3501),C=v([].push);y.exports=function(S,T){var A,R=w(S),I=0,$=[];for(A in R)!g(O,A)&&g(R,A)&&C($,A);for(;T.length>I;)g(R,A=T[I++])&&(~k($,A)||C($,A));return $}},1956:(y,j,r)=>{var v=r(6324),g=r(748);y.exports=Object.keys||function(w){return v(w,g)}},5296:(y,j)=>{var r={}.propertyIsEnumerable,v=Object.getOwnPropertyDescriptor,g=v&&!r.call({1:2},1);j.f=g?function(w){var k=v(this,w);return!!k&&k.enumerable}:r},7674:(y,j,r)=>{var v=r(5668),g=r(9670),w=r(6077);y.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var k,O=!1,C={};try{(k=v(Object.prototype,"__proto__","set"))(C,[]),O=C instanceof Array}catch{}return function(S,T){return g(S),w(T),O?k(S,T):S.__proto__=T,S}}():void 0)},4699:(y,j,r)=>{var v=r(9781),g=r(1702),w=r(1956),k=r(5656),O=g(r(5296).f),C=g([].push),S=function(T){return function(A){for(var R,I=k(A),$=w(I),M=$.length,B=0,q=[];M>B;)R=$[B++],v&&!O(I,R)||C(q,T?[R,I[R]]:I[R]);return q}};y.exports={entries:S(!0),values:S(!1)}},288:(y,j,r)=>{var v=r(1694),g=r(648);y.exports=v?{}.toString:function(){return"[object "+g(this)+"]"}},2140:(y,j,r)=>{var v=r(6916),g=r(614),w=r(111),k=TypeError;y.exports=function(O,C){var S,T;if(C==="string"&&g(S=O.toString)&&!w(T=v(S,O))||g(S=O.valueOf)&&!w(T=v(S,O))||C!=="string"&&g(S=O.toString)&&!w(T=v(S,O)))return T;throw k("Can't convert object to primitive value")}},3887:(y,j,r)=>{var v=r(5005),g=r(1702),w=r(8006),k=r(5181),O=r(9670),C=g([].concat);y.exports=v("Reflect","ownKeys")||function(S){var T=w.f(O(S)),A=k.f;return A?C(T,A(S)):T}},857:(y,j,r)=>{var v=r(7854);y.exports=v},2534:y=>{y.exports=function(j){try{return{error:!1,value:j()}}catch(r){return{error:!0,value:r}}}},3702:(y,j,r)=>{var v=r(7854),g=r(2492),w=r(614),k=r(4705),O=r(2788),C=r(5112),S=r(7871),T=r(3823),A=r(1913),R=r(7392),I=g&&g.prototype,$=C("species"),M=!1,B=w(v.PromiseRejectionEvent),q=k("Promise",function(){var F=O(g),N=F!==String(g);if(!N&&R===66||A&&(!I.catch||!I.finally))return!0;if(!R||R<51||!/native code/.test(F)){var U=new g(function(X){X(1)}),H=function(X){X(function(){},function(){})};if((U.constructor={})[$]=H,!(M=U.then(function(){})instanceof H))return!0}return!N&&(S||T)&&!B});y.exports={CONSTRUCTOR:q,REJECTION_EVENT:B,SUBCLASSING:M}},2492:(y,j,r)=>{var v=r(7854);y.exports=v.Promise},9478:(y,j,r)=>{var v=r(9670),g=r(111),w=r(8523);y.exports=function(k,O){if(v(k),g(O)&&O.constructor===k)return O;var C=w.f(k);return(0,C.resolve)(O),C.promise}},612:(y,j,r)=>{var v=r(2492),g=r(7072),w=r(3702).CONSTRUCTOR;y.exports=w||!g(function(k){v.all(k).then(void 0,function(){})})},2626:(y,j,r)=>{var v=r(3070).f;y.exports=function(g,w,k){k in g||v(g,k,{configurable:!0,get:function(){return w[k]},set:function(O){w[k]=O}})}},8572:y=>{var j=function(){this.head=null,this.tail=null};j.prototype={add:function(r){var v={item:r,next:null},g=this.tail;g?g.next=v:this.head=v,this.tail=v},get:function(){var r=this.head;if(r)return(this.head=r.next)===null&&(this.tail=null),r.item}},y.exports=j},7651:(y,j,r)=>{var v=r(6916),g=r(9670),w=r(614),k=r(4326),O=r(2261),C=TypeError;y.exports=function(S,T){var A=S.exec;if(w(A)){var R=v(A,S,T);return R!==null&&g(R),R}if(k(S)==="RegExp")return v(O,S,T);throw C("RegExp#exec called on incompatible receiver")}},2261:(y,j,r)=>{var v,g,w=r(6916),k=r(1702),O=r(1340),C=r(7066),S=r(2999),T=r(2309),A=r(30),R=r(9909).get,I=r(9441),$=r(7168),M=T("native-string-replace",String.prototype.replace),B=RegExp.prototype.exec,q=B,F=k("".charAt),N=k("".indexOf),U=k("".replace),H=k("".slice),X=(g=/b*/g,w(B,v=/a/,"a"),w(B,g,"a"),v.lastIndex!==0||g.lastIndex!==0),Y=S.BROKEN_CARET,K=/()??/.exec("")[1]!==void 0;(X||K||Y||I||$)&&(q=function(tt){var it,st,yt,ct,Et,At,Vt,lt=this,wt=R(lt),_t=O(tt),Ut=wt.raw;if(Ut)return Ut.lastIndex=lt.lastIndex,it=w(q,Ut,_t),lt.lastIndex=Ut.lastIndex,it;var Kt=wt.groups,fe=Y&<.sticky,St=w(C,lt),jt=lt.source,Bt=0,qt=_t;if(fe&&(St=U(St,"y",""),N(St,"g")===-1&&(St+="g"),qt=H(_t,lt.lastIndex),lt.lastIndex>0&&(!lt.multiline||lt.multiline&&F(_t,lt.lastIndex-1)!==`
|
|
71
|
-
`)&&(jt="(?: "+jt+")",qt=" "+qt,
|
|
70
|
+
*/function*Ba(m,s){if(m!==void 0){let p=0;for(const b of m)yield s(b,p++)}}var Da=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Qd(m){return m&&m.__esModule&&Object.prototype.hasOwnProperty.call(m,"default")?m.default:m}var uu={exports:{}};/*! For license information please see jsoneditor.js.LICENSE.txt */(function(m,s){(function(p,b){m.exports=b()})(self,()=>(()=>{var p={9662:(y,j,r)=>{var v=r(614),g=r(6330),w=TypeError;y.exports=function(k){if(v(k))return k;throw w(g(k)+" is not a function")}},9483:(y,j,r)=>{var v=r(4411),g=r(6330),w=TypeError;y.exports=function(k){if(v(k))return k;throw w(g(k)+" is not a constructor")}},6077:(y,j,r)=>{var v=r(614),g=String,w=TypeError;y.exports=function(k){if(typeof k=="object"||v(k))return k;throw w("Can't set "+g(k)+" as a prototype")}},1223:(y,j,r)=>{var v=r(5112),g=r(30),w=r(3070).f,k=v("unscopables"),O=Array.prototype;O[k]==null&&w(O,k,{configurable:!0,value:g(null)}),y.exports=function(C){O[k][C]=!0}},1530:(y,j,r)=>{var v=r(8710).charAt;y.exports=function(g,w,k){return w+(k?v(g,w).length:1)}},5787:(y,j,r)=>{var v=r(7976),g=TypeError;y.exports=function(w,k){if(v(k,w))return w;throw g("Incorrect invocation")}},9670:(y,j,r)=>{var v=r(111),g=String,w=TypeError;y.exports=function(k){if(v(k))return k;throw w(g(k)+" is not an object")}},8533:(y,j,r)=>{var v=r(2092).forEach,g=r(9341)("forEach");y.exports=g?[].forEach:function(w){return v(this,w,arguments.length>1?arguments[1]:void 0)}},8457:(y,j,r)=>{var v=r(9974),g=r(6916),w=r(7908),k=r(3411),O=r(7659),C=r(4411),S=r(6244),T=r(6135),A=r(4121),R=r(1246),I=Array;y.exports=function($){var M=w($),B=C(this),q=arguments.length,F=q>1?arguments[1]:void 0,N=F!==void 0;N&&(F=v(F,q>2?arguments[2]:void 0));var U,H,X,Y,K,tt,it=R(M),st=0;if(!it||this===I&&O(it))for(U=S(M),H=B?new this(U):I(U);U>st;st++)tt=N?F(M[st],st):M[st],T(H,st,tt);else for(K=(Y=A(M,it)).next,H=B?new this:[];!(X=g(K,Y)).done;st++)tt=N?k(Y,F,[X.value,st],!0):X.value,T(H,st,tt);return H.length=st,H}},1318:(y,j,r)=>{var v=r(5656),g=r(1400),w=r(6244),k=function(O){return function(C,S,T){var A,R=v(C),I=w(R),$=g(T,I);if(O&&S!=S){for(;I>$;)if((A=R[$++])!=A)return!0}else for(;I>$;$++)if((O||$ in R)&&R[$]===S)return O||$||0;return!O&&-1}};y.exports={includes:k(!0),indexOf:k(!1)}},2092:(y,j,r)=>{var v=r(9974),g=r(1702),w=r(8361),k=r(7908),O=r(6244),C=r(5417),S=g([].push),T=function(A){var R=A==1,I=A==2,$=A==3,M=A==4,B=A==6,q=A==7,F=A==5||B;return function(N,U,H,X){for(var Y,K,tt=k(N),it=w(tt),st=v(U,H),yt=O(it),ct=0,Et=X||C,At=R?Et(N,yt):I||q?Et(N,0):void 0;yt>ct;ct++)if((F||ct in it)&&(K=st(Y=it[ct],ct,tt),A))if(R)At[ct]=K;else if(K)switch(A){case 3:return!0;case 5:return Y;case 6:return ct;case 2:S(At,Y)}else switch(A){case 4:return!1;case 7:S(At,Y)}return B?-1:$||M?M:At}};y.exports={forEach:T(0),map:T(1),filter:T(2),some:T(3),every:T(4),find:T(5),findIndex:T(6),filterReject:T(7)}},1194:(y,j,r)=>{var v=r(7293),g=r(5112),w=r(7392),k=g("species");y.exports=function(O){return w>=51||!v(function(){var C=[];return(C.constructor={})[k]=function(){return{foo:1}},C[O](Boolean).foo!==1})}},9341:(y,j,r)=>{var v=r(7293);y.exports=function(g,w){var k=[][g];return!!k&&v(function(){k.call(null,w||function(){return 1},1)})}},3671:(y,j,r)=>{var v=r(9662),g=r(7908),w=r(8361),k=r(6244),O=TypeError,C=function(S){return function(T,A,R,I){v(A);var $=g(T),M=w($),B=k($),q=S?B-1:0,F=S?-1:1;if(R<2)for(;;){if(q in M){I=M[q],q+=F;break}if(q+=F,S?q<0:B<=q)throw O("Reduce of empty array with no initial value")}for(;S?q>=0:B>q;q+=F)q in M&&(I=A(I,M[q],q,$));return I}};y.exports={left:C(!1),right:C(!0)}},3658:(y,j,r)=>{var v=r(9781),g=r(3157),w=TypeError,k=Object.getOwnPropertyDescriptor,O=v&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(C){return C instanceof TypeError}}();y.exports=O?function(C,S){if(g(C)&&!k(C,"length").writable)throw w("Cannot set read only .length");return C.length=S}:function(C,S){return C.length=S}},1589:(y,j,r)=>{var v=r(1400),g=r(6244),w=r(6135),k=Array,O=Math.max;y.exports=function(C,S,T){for(var A=g(C),R=v(S,A),I=v(T===void 0?A:T,A),$=k(O(I-R,0)),M=0;R<I;R++,M++)w($,M,C[R]);return $.length=M,$}},206:(y,j,r)=>{var v=r(1702);y.exports=v([].slice)},4362:(y,j,r)=>{var v=r(1589),g=Math.floor,w=function(C,S){var T=C.length,A=g(T/2);return T<8?k(C,S):O(C,w(v(C,0,A),S),w(v(C,A),S),S)},k=function(C,S){for(var T,A,R=C.length,I=1;I<R;){for(A=I,T=C[I];A&&S(C[A-1],T)>0;)C[A]=C[--A];A!==I++&&(C[A]=T)}return C},O=function(C,S,T,A){for(var R=S.length,I=T.length,$=0,M=0;$<R||M<I;)C[$+M]=$<R&&M<I?A(S[$],T[M])<=0?S[$++]:T[M++]:$<R?S[$++]:T[M++];return C};y.exports=w},7475:(y,j,r)=>{var v=r(3157),g=r(4411),w=r(111),k=r(5112)("species"),O=Array;y.exports=function(C){var S;return v(C)&&(S=C.constructor,(g(S)&&(S===O||v(S.prototype))||w(S)&&(S=S[k])===null)&&(S=void 0)),S===void 0?O:S}},5417:(y,j,r)=>{var v=r(7475);y.exports=function(g,w){return new(v(g))(w===0?0:w)}},3411:(y,j,r)=>{var v=r(9670),g=r(9212);y.exports=function(w,k,O,C){try{return C?k(v(O)[0],O[1]):k(O)}catch(S){g(w,"throw",S)}}},7072:(y,j,r)=>{var v=r(5112)("iterator"),g=!1;try{var w=0,k={next:function(){return{done:!!w++}},return:function(){g=!0}};k[v]=function(){return this},Array.from(k,function(){throw 2})}catch{}y.exports=function(O,C){if(!C&&!g)return!1;var S=!1;try{var T={};T[v]=function(){return{next:function(){return{done:S=!0}}}},O(T)}catch{}return S}},4326:(y,j,r)=>{var v=r(1702),g=v({}.toString),w=v("".slice);y.exports=function(k){return w(g(k),8,-1)}},648:(y,j,r)=>{var v=r(1694),g=r(614),w=r(4326),k=r(5112)("toStringTag"),O=Object,C=w(function(){return arguments}())=="Arguments";y.exports=v?w:function(S){var T,A,R;return S===void 0?"Undefined":S===null?"Null":typeof(A=function(I,$){try{return I[$]}catch{}}(T=O(S),k))=="string"?A:C?w(T):(R=w(T))=="Object"&&g(T.callee)?"Arguments":R}},9920:(y,j,r)=>{var v=r(2597),g=r(3887),w=r(1236),k=r(3070);y.exports=function(O,C,S){for(var T=g(C),A=k.f,R=w.f,I=0;I<T.length;I++){var $=T[I];v(O,$)||S&&v(S,$)||A(O,$,R(C,$))}}},4964:(y,j,r)=>{var v=r(5112)("match");y.exports=function(g){var w=/./;try{"/./"[g](w)}catch{try{return w[v]=!1,"/./"[g](w)}catch{}}return!1}},8544:(y,j,r)=>{var v=r(7293);y.exports=!v(function(){function g(){}return g.prototype.constructor=null,Object.getPrototypeOf(new g)!==g.prototype})},6178:y=>{y.exports=function(j,r){return{value:j,done:r}}},8880:(y,j,r)=>{var v=r(9781),g=r(3070),w=r(9114);y.exports=v?function(k,O,C){return g.f(k,O,w(1,C))}:function(k,O,C){return k[O]=C,k}},9114:y=>{y.exports=function(j,r){return{enumerable:!(1&j),configurable:!(2&j),writable:!(4&j),value:r}}},6135:(y,j,r)=>{var v=r(4948),g=r(3070),w=r(9114);y.exports=function(k,O,C){var S=v(O);S in k?g.f(k,S,w(0,C)):k[S]=C}},5573:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(6650).start,k=RangeError,O=isFinite,C=Math.abs,S=Date.prototype,T=S.toISOString,A=v(S.getTime),R=v(S.getUTCDate),I=v(S.getUTCFullYear),$=v(S.getUTCHours),M=v(S.getUTCMilliseconds),B=v(S.getUTCMinutes),q=v(S.getUTCMonth),F=v(S.getUTCSeconds);y.exports=g(function(){return T.call(new Date(-50000000000001))!="0385-07-25T07:06:39.999Z"})||!g(function(){T.call(new Date(NaN))})?function(){if(!O(A(this)))throw k("Invalid time value");var N=this,U=I(N),H=M(N),X=U<0?"-":U>9999?"+":"";return X+w(C(U),X?6:4,0)+"-"+w(q(N)+1,2,0)+"-"+w(R(N),2,0)+"T"+w($(N),2,0)+":"+w(B(N),2,0)+":"+w(F(N),2,0)+"."+w(H,3,0)+"Z"}:T},8709:(y,j,r)=>{var v=r(9670),g=r(2140),w=TypeError;y.exports=function(k){if(v(this),k==="string"||k==="default")k="string";else if(k!=="number")throw w("Incorrect hint");return g(this,k)}},7045:(y,j,r)=>{var v=r(6339),g=r(3070);y.exports=function(w,k,O){return O.get&&v(O.get,k,{getter:!0}),O.set&&v(O.set,k,{setter:!0}),g.f(w,k,O)}},8052:(y,j,r)=>{var v=r(614),g=r(3070),w=r(6339),k=r(3072);y.exports=function(O,C,S,T){T||(T={});var A=T.enumerable,R=T.name!==void 0?T.name:C;if(v(S)&&w(S,R,T),T.global)A?O[C]=S:k(C,S);else{try{T.unsafe?O[C]&&(A=!0):delete O[C]}catch{}A?O[C]=S:g.f(O,C,{value:S,enumerable:!1,configurable:!T.nonConfigurable,writable:!T.nonWritable})}return O}},3072:(y,j,r)=>{var v=r(7854),g=Object.defineProperty;y.exports=function(w,k){try{g(v,w,{value:k,configurable:!0,writable:!0})}catch{v[w]=k}return k}},5117:(y,j,r)=>{var v=r(6330),g=TypeError;y.exports=function(w,k){if(!delete w[k])throw g("Cannot delete property "+v(k)+" of "+v(w))}},9781:(y,j,r)=>{var v=r(7293);y.exports=!v(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7})},4154:y=>{var j=typeof document=="object"&&document.all,r=j===void 0&&j!==void 0;y.exports={all:j,IS_HTMLDDA:r}},317:(y,j,r)=>{var v=r(7854),g=r(111),w=v.document,k=g(w)&&g(w.createElement);y.exports=function(O){return k?w.createElement(O):{}}},7207:y=>{var j=TypeError;y.exports=function(r){if(r>9007199254740991)throw j("Maximum allowed index exceeded");return r}},8324:y=>{y.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},8509:(y,j,r)=>{var v=r(317)("span").classList,g=v&&v.constructor&&v.constructor.prototype;y.exports=g===Object.prototype?void 0:g},8886:(y,j,r)=>{var v=r(8113).match(/firefox\/(\d+)/i);y.exports=!!v&&+v[1]},7871:(y,j,r)=>{var v=r(3823),g=r(5268);y.exports=!v&&!g&&typeof window=="object"&&typeof document=="object"},9363:y=>{y.exports=typeof Bun=="function"&&Bun&&typeof Bun.version=="string"},3823:y=>{y.exports=typeof Deno=="object"&&Deno&&typeof Deno.version=="object"},256:(y,j,r)=>{var v=r(8113);y.exports=/MSIE|Trident/.test(v)},1528:(y,j,r)=>{var v=r(8113);y.exports=/ipad|iphone|ipod/i.test(v)&&typeof Pebble<"u"},8334:(y,j,r)=>{var v=r(8113);y.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(v)},5268:(y,j,r)=>{var v=r(4326);y.exports=typeof process<"u"&&v(process)=="process"},1036:(y,j,r)=>{var v=r(8113);y.exports=/web0s(?!.*chrome)/i.test(v)},8113:y=>{y.exports=typeof navigator<"u"&&String(navigator.userAgent)||""},7392:(y,j,r)=>{var v,g,w=r(7854),k=r(8113),O=w.process,C=w.Deno,S=O&&O.versions||C&&C.version,T=S&&S.v8;T&&(g=(v=T.split("."))[0]>0&&v[0]<4?1:+(v[0]+v[1])),!g&&k&&(!(v=k.match(/Edge\/(\d+)/))||v[1]>=74)&&(v=k.match(/Chrome\/(\d+)/))&&(g=+v[1]),y.exports=g},8008:(y,j,r)=>{var v=r(8113).match(/AppleWebKit\/(\d+)\./);y.exports=!!v&&+v[1]},748:y=>{y.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},2109:(y,j,r)=>{var v=r(7854),g=r(1236).f,w=r(8880),k=r(8052),O=r(3072),C=r(9920),S=r(4705);y.exports=function(T,A){var R,I,$,M,B,q=T.target,F=T.global,N=T.stat;if(R=F?v:N?v[q]||O(q,{}):(v[q]||{}).prototype)for(I in A){if(M=A[I],$=T.dontCallGetSet?(B=g(R,I))&&B.value:R[I],!S(F?I:q+(N?".":"#")+I,T.forced)&&$!==void 0){if(typeof M==typeof $)continue;C(M,$)}(T.sham||$&&$.sham)&&w(M,"sham",!0),k(R,I,M,T)}}},7293:y=>{y.exports=function(j){try{return!!j()}catch{return!0}}},7007:(y,j,r)=>{r(4916);var v=r(1470),g=r(8052),w=r(2261),k=r(7293),O=r(5112),C=r(8880),S=O("species"),T=RegExp.prototype;y.exports=function(A,R,I,$){var M=O(A),B=!k(function(){var U={};return U[M]=function(){return 7},""[A](U)!=7}),q=B&&!k(function(){var U=!1,H=/a/;return A==="split"&&((H={}).constructor={},H.constructor[S]=function(){return H},H.flags="",H[M]=/./[M]),H.exec=function(){return U=!0,null},H[M](""),!U});if(!B||!q||I){var F=v(/./[M]),N=R(M,""[A],function(U,H,X,Y,K){var tt=v(U),it=H.exec;return it===w||it===T.exec?B&&!K?{done:!0,value:F(H,X,Y)}:{done:!0,value:tt(X,H,Y)}:{done:!1}});g(String.prototype,A,N[0]),g(T,M,N[1])}$&&C(T[M],"sham",!0)}},2104:(y,j,r)=>{var v=r(4374),g=Function.prototype,w=g.apply,k=g.call;y.exports=typeof Reflect=="object"&&Reflect.apply||(v?k.bind(w):function(){return k.apply(w,arguments)})},9974:(y,j,r)=>{var v=r(1470),g=r(9662),w=r(4374),k=v(v.bind);y.exports=function(O,C){return g(O),C===void 0?O:w?k(O,C):function(){return O.apply(C,arguments)}}},4374:(y,j,r)=>{var v=r(7293);y.exports=!v(function(){var g=(function(){}).bind();return typeof g!="function"||g.hasOwnProperty("prototype")})},7065:(y,j,r)=>{var v=r(1702),g=r(9662),w=r(111),k=r(2597),O=r(206),C=r(4374),S=Function,T=v([].concat),A=v([].join),R={},I=function($,M,B){if(!k(R,M)){for(var q=[],F=0;F<M;F++)q[F]="a["+F+"]";R[M]=S("C,a","return new C("+A(q,",")+")")}return R[M]($,B)};y.exports=C?S.bind:function($){var M=g(this),B=M.prototype,q=O(arguments,1),F=function(){var N=T(q,O(arguments));return this instanceof F?I(M,N.length,N):M.apply($,N)};return w(B)&&(F.prototype=B),F}},6916:(y,j,r)=>{var v=r(4374),g=Function.prototype.call;y.exports=v?g.bind(g):function(){return g.apply(g,arguments)}},6530:(y,j,r)=>{var v=r(9781),g=r(2597),w=Function.prototype,k=v&&Object.getOwnPropertyDescriptor,O=g(w,"name"),C=O&&(function(){}).name==="something",S=O&&(!v||v&&k(w,"name").configurable);y.exports={EXISTS:O,PROPER:C,CONFIGURABLE:S}},5668:(y,j,r)=>{var v=r(1702),g=r(9662);y.exports=function(w,k,O){try{return v(g(Object.getOwnPropertyDescriptor(w,k)[O]))}catch{}}},1470:(y,j,r)=>{var v=r(4326),g=r(1702);y.exports=function(w){if(v(w)==="Function")return g(w)}},1702:(y,j,r)=>{var v=r(4374),g=Function.prototype,w=g.call,k=v&&g.bind.bind(w,w);y.exports=v?k:function(O){return function(){return w.apply(O,arguments)}}},5005:(y,j,r)=>{var v=r(7854),g=r(614),w=function(k){return g(k)?k:void 0};y.exports=function(k,O){return arguments.length<2?w(v[k]):v[k]&&v[k][O]}},1246:(y,j,r)=>{var v=r(648),g=r(8173),w=r(8554),k=r(7497),O=r(5112)("iterator");y.exports=function(C){if(!w(C))return g(C,O)||g(C,"@@iterator")||k[v(C)]}},4121:(y,j,r)=>{var v=r(6916),g=r(9662),w=r(9670),k=r(6330),O=r(1246),C=TypeError;y.exports=function(S,T){var A=arguments.length<2?O(S):T;if(g(A))return w(v(A,S));throw C(k(S)+" is not iterable")}},8044:(y,j,r)=>{var v=r(1702),g=r(3157),w=r(614),k=r(4326),O=r(1340),C=v([].push);y.exports=function(S){if(w(S))return S;if(g(S)){for(var T=S.length,A=[],R=0;R<T;R++){var I=S[R];typeof I=="string"?C(A,I):typeof I!="number"&&k(I)!="Number"&&k(I)!="String"||C(A,O(I))}var $=A.length,M=!0;return function(B,q){if(M)return M=!1,q;if(g(this))return q;for(var F=0;F<$;F++)if(A[F]===B)return q}}}},8173:(y,j,r)=>{var v=r(9662),g=r(8554);y.exports=function(w,k){var O=w[k];return g(O)?void 0:v(O)}},647:(y,j,r)=>{var v=r(1702),g=r(7908),w=Math.floor,k=v("".charAt),O=v("".replace),C=v("".slice),S=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,T=/\$([$&'`]|\d{1,2})/g;y.exports=function(A,R,I,$,M,B){var q=I+A.length,F=$.length,N=T;return M!==void 0&&(M=g(M),N=S),O(B,N,function(U,H){var X;switch(k(H,0)){case"$":return"$";case"&":return A;case"`":return C(R,0,I);case"'":return C(R,q);case"<":X=M[C(H,1,-1)];break;default:var Y=+H;if(Y===0)return U;if(Y>F){var K=w(Y/10);return K===0?U:K<=F?$[K-1]===void 0?k(H,1):$[K-1]+k(H,1):U}X=$[Y-1]}return X===void 0?"":X})}},7854:(y,j,r)=>{var v=function(g){return g&&g.Math==Math&&g};y.exports=v(typeof globalThis=="object"&&globalThis)||v(typeof window=="object"&&window)||v(typeof self=="object"&&self)||v(typeof r.g=="object"&&r.g)||function(){return this}()||Function("return this")()},2597:(y,j,r)=>{var v=r(1702),g=r(7908),w=v({}.hasOwnProperty);y.exports=Object.hasOwn||function(k,O){return w(g(k),O)}},3501:y=>{y.exports={}},842:y=>{y.exports=function(j,r){try{arguments.length==1?console.error(j):console.error(j,r)}catch{}}},490:(y,j,r)=>{var v=r(5005);y.exports=v("document","documentElement")},4664:(y,j,r)=>{var v=r(9781),g=r(7293),w=r(317);y.exports=!v&&!g(function(){return Object.defineProperty(w("div"),"a",{get:function(){return 7}}).a!=7})},8361:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(4326),k=Object,O=v("".split);y.exports=g(function(){return!k("z").propertyIsEnumerable(0)})?function(C){return w(C)=="String"?O(C,""):k(C)}:k},9587:(y,j,r)=>{var v=r(614),g=r(111),w=r(7674);y.exports=function(k,O,C){var S,T;return w&&v(S=O.constructor)&&S!==C&&g(T=S.prototype)&&T!==C.prototype&&w(k,T),k}},2788:(y,j,r)=>{var v=r(1702),g=r(614),w=r(5465),k=v(Function.toString);g(w.inspectSource)||(w.inspectSource=function(O){return k(O)}),y.exports=w.inspectSource},9909:(y,j,r)=>{var v,g,w,k=r(4811),O=r(7854),C=r(111),S=r(8880),T=r(2597),A=r(5465),R=r(6200),I=r(3501),$="Object already initialized",M=O.TypeError,B=O.WeakMap;if(k||A.state){var q=A.state||(A.state=new B);q.get=q.get,q.has=q.has,q.set=q.set,v=function(N,U){if(q.has(N))throw M($);return U.facade=N,q.set(N,U),U},g=function(N){return q.get(N)||{}},w=function(N){return q.has(N)}}else{var F=R("state");I[F]=!0,v=function(N,U){if(T(N,F))throw M($);return U.facade=N,S(N,F,U),U},g=function(N){return T(N,F)?N[F]:{}},w=function(N){return T(N,F)}}y.exports={set:v,get:g,has:w,enforce:function(N){return w(N)?g(N):v(N,{})},getterFor:function(N){return function(U){var H;if(!C(U)||(H=g(U)).type!==N)throw M("Incompatible receiver, "+N+" required");return H}}}},7659:(y,j,r)=>{var v=r(5112),g=r(7497),w=v("iterator"),k=Array.prototype;y.exports=function(O){return O!==void 0&&(g.Array===O||k[w]===O)}},3157:(y,j,r)=>{var v=r(4326);y.exports=Array.isArray||function(g){return v(g)=="Array"}},614:(y,j,r)=>{var v=r(4154),g=v.all;y.exports=v.IS_HTMLDDA?function(w){return typeof w=="function"||w===g}:function(w){return typeof w=="function"}},4411:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(614),k=r(648),O=r(5005),C=r(2788),S=function(){},T=[],A=O("Reflect","construct"),R=/^\s*(?:class|function)\b/,I=v(R.exec),$=!R.exec(S),M=function(q){if(!w(q))return!1;try{return A(S,T,q),!0}catch{return!1}},B=function(q){if(!w(q))return!1;switch(k(q)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return $||!!I(R,C(q))}catch{return!0}};B.sham=!0,y.exports=!A||g(function(){var q;return M(M.call)||!M(Object)||!M(function(){q=!0})||q})?B:M},5032:(y,j,r)=>{var v=r(2597);y.exports=function(g){return g!==void 0&&(v(g,"value")||v(g,"writable"))}},4705:(y,j,r)=>{var v=r(7293),g=r(614),w=/#|\.prototype\./,k=function(A,R){var I=C[O(A)];return I==T||I!=S&&(g(R)?v(R):!!R)},O=k.normalize=function(A){return String(A).replace(w,".").toLowerCase()},C=k.data={},S=k.NATIVE="N",T=k.POLYFILL="P";y.exports=k},8554:y=>{y.exports=function(j){return j==null}},111:(y,j,r)=>{var v=r(614),g=r(4154),w=g.all;y.exports=g.IS_HTMLDDA?function(k){return typeof k=="object"?k!==null:v(k)||k===w}:function(k){return typeof k=="object"?k!==null:v(k)}},1913:y=>{y.exports=!1},7850:(y,j,r)=>{var v=r(111),g=r(4326),w=r(5112)("match");y.exports=function(k){var O;return v(k)&&((O=k[w])!==void 0?!!O:g(k)=="RegExp")}},2190:(y,j,r)=>{var v=r(5005),g=r(614),w=r(7976),k=r(3307),O=Object;y.exports=k?function(C){return typeof C=="symbol"}:function(C){var S=v("Symbol");return g(S)&&w(S.prototype,O(C))}},408:(y,j,r)=>{var v=r(9974),g=r(6916),w=r(9670),k=r(6330),O=r(7659),C=r(6244),S=r(7976),T=r(4121),A=r(1246),R=r(9212),I=TypeError,$=function(B,q){this.stopped=B,this.result=q},M=$.prototype;y.exports=function(B,q,F){var N,U,H,X,Y,K,tt,it=F&&F.that,st=!(!F||!F.AS_ENTRIES),yt=!(!F||!F.IS_RECORD),ct=!(!F||!F.IS_ITERATOR),Et=!(!F||!F.INTERRUPTED),At=v(q,it),Vt=function(wt){return N&&R(N,"normal",wt),new $(!0,wt)},lt=function(wt){return st?(w(wt),Et?At(wt[0],wt[1],Vt):At(wt[0],wt[1])):Et?At(wt,Vt):At(wt)};if(yt)N=B.iterator;else if(ct)N=B;else{if(!(U=A(B)))throw I(k(B)+" is not iterable");if(O(U)){for(H=0,X=C(B);X>H;H++)if((Y=lt(B[H]))&&S(M,Y))return Y;return new $(!1)}N=T(B,U)}for(K=yt?B.next:N.next;!(tt=g(K,N)).done;){try{Y=lt(tt.value)}catch(wt){R(N,"throw",wt)}if(typeof Y=="object"&&Y&&S(M,Y))return Y}return new $(!1)}},9212:(y,j,r)=>{var v=r(6916),g=r(9670),w=r(8173);y.exports=function(k,O,C){var S,T;g(k);try{if(!(S=w(k,"return"))){if(O==="throw")throw C;return C}S=v(S,k)}catch(A){T=!0,S=A}if(O==="throw")throw C;if(T)throw S;return g(S),C}},3061:(y,j,r)=>{var v=r(3383).IteratorPrototype,g=r(30),w=r(9114),k=r(8003),O=r(7497),C=function(){return this};y.exports=function(S,T,A,R){var I=T+" Iterator";return S.prototype=g(v,{next:w(+!R,A)}),k(S,I,!1,!0),O[I]=C,S}},1656:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(1913),k=r(6530),O=r(614),C=r(3061),S=r(9518),T=r(7674),A=r(8003),R=r(8880),I=r(8052),$=r(5112),M=r(7497),B=r(3383),q=k.PROPER,F=k.CONFIGURABLE,N=B.IteratorPrototype,U=B.BUGGY_SAFARI_ITERATORS,H=$("iterator"),X="keys",Y="values",K="entries",tt=function(){return this};y.exports=function(it,st,yt,ct,Et,At,Vt){C(yt,st,ct);var lt,wt,_t,Ut=function(xt){if(xt===Et&&It)return It;if(!U&&xt in St)return St[xt];switch(xt){case X:case Y:case K:return function(){return new yt(this,xt)}}return function(){return new yt(this)}},Kt=st+" Iterator",fe=!1,St=it.prototype,jt=St[H]||St["@@iterator"]||Et&&St[Et],It=!U&&jt||Ut(Et),qt=st=="Array"&&St.entries||jt;if(qt&&(lt=S(qt.call(new it)))!==Object.prototype&<.next&&(w||S(lt)===N||(T?T(lt,N):O(lt[H])||I(lt,H,tt)),A(lt,Kt,!0,!0),w&&(M[Kt]=tt)),q&&Et==Y&&jt&&jt.name!==Y&&(!w&&F?R(St,"name",Y):(fe=!0,It=function(){return g(jt,this)})),Et)if(wt={values:Ut(Y),keys:At?It:Ut(X),entries:Ut(K)},Vt)for(_t in wt)(U||fe||!(_t in St))&&I(St,_t,wt[_t]);else v({target:st,proto:!0,forced:U||fe},wt);return w&&!Vt||St[H]===It||I(St,H,It,{name:Et}),M[st]=It,wt}},3383:(y,j,r)=>{var v,g,w,k=r(7293),O=r(614),C=r(111),S=r(30),T=r(9518),A=r(8052),R=r(5112),I=r(1913),$=R("iterator"),M=!1;[].keys&&("next"in(w=[].keys())?(g=T(T(w)))!==Object.prototype&&(v=g):M=!0),!C(v)||k(function(){var B={};return v[$].call(B)!==B})?v={}:I&&(v=S(v)),O(v[$])||A(v,$,function(){return this}),y.exports={IteratorPrototype:v,BUGGY_SAFARI_ITERATORS:M}},7497:y=>{y.exports={}},6244:(y,j,r)=>{var v=r(7466);y.exports=function(g){return v(g.length)}},6339:(y,j,r)=>{var v=r(1702),g=r(7293),w=r(614),k=r(2597),O=r(9781),C=r(6530).CONFIGURABLE,S=r(2788),T=r(9909),A=T.enforce,R=T.get,I=String,$=Object.defineProperty,M=v("".slice),B=v("".replace),q=v([].join),F=O&&!g(function(){return $(function(){},"length",{value:8}).length!==8}),N=String(String).split("String"),U=y.exports=function(H,X,Y){M(I(X),0,7)==="Symbol("&&(X="["+B(I(X),/^Symbol\(([^)]*)\)/,"$1")+"]"),Y&&Y.getter&&(X="get "+X),Y&&Y.setter&&(X="set "+X),(!k(H,"name")||C&&H.name!==X)&&(O?$(H,"name",{value:X,configurable:!0}):H.name=X),F&&Y&&k(Y,"arity")&&H.length!==Y.arity&&$(H,"length",{value:Y.arity});try{Y&&k(Y,"constructor")&&Y.constructor?O&&$(H,"prototype",{writable:!1}):H.prototype&&(H.prototype=void 0)}catch{}var K=A(H);return k(K,"source")||(K.source=q(N,typeof X=="string"?X:"")),H};Function.prototype.toString=U(function(){return w(this)&&R(this).source||S(this)},"toString")},4758:y=>{var j=Math.ceil,r=Math.floor;y.exports=Math.trunc||function(v){var g=+v;return(g>0?r:j)(g)}},5948:(y,j,r)=>{var v,g,w,k,O,C=r(7854),S=r(9974),T=r(1236).f,A=r(261).set,R=r(8572),I=r(8334),$=r(1528),M=r(1036),B=r(5268),q=C.MutationObserver||C.WebKitMutationObserver,F=C.document,N=C.process,U=C.Promise,H=T(C,"queueMicrotask"),X=H&&H.value;if(!X){var Y=new R,K=function(){var tt,it;for(B&&(tt=N.domain)&&tt.exit();it=Y.get();)try{it()}catch(st){throw Y.head&&v(),st}tt&&tt.enter()};I||B||M||!q||!F?!$&&U&&U.resolve?((k=U.resolve(void 0)).constructor=U,O=S(k.then,k),v=function(){O(K)}):B?v=function(){N.nextTick(K)}:(A=S(A,C),v=function(){A(K)}):(g=!0,w=F.createTextNode(""),new q(K).observe(w,{characterData:!0}),v=function(){w.data=g=!g}),X=function(tt){Y.head||v(),Y.add(tt)}}y.exports=X},8523:(y,j,r)=>{var v=r(9662),g=TypeError,w=function(k){var O,C;this.promise=new k(function(S,T){if(O!==void 0||C!==void 0)throw g("Bad Promise constructor");O=S,C=T}),this.resolve=v(O),this.reject=v(C)};y.exports.f=function(k){return new w(k)}},3929:(y,j,r)=>{var v=r(7850),g=TypeError;y.exports=function(w){if(v(w))throw g("The method doesn't accept regular expressions");return w}},2814:(y,j,r)=>{var v=r(7854),g=r(7293),w=r(1702),k=r(1340),O=r(3111).trim,C=r(1361),S=w("".charAt),T=v.parseFloat,A=v.Symbol,R=A&&A.iterator,I=1/T(C+"-0")!=-1/0||R&&!g(function(){T(Object(R))});y.exports=I?function($){var M=O(k($)),B=T(M);return B===0&&S(M,0)=="-"?-0:B}:T},3009:(y,j,r)=>{var v=r(7854),g=r(7293),w=r(1702),k=r(1340),O=r(3111).trim,C=r(1361),S=v.parseInt,T=v.Symbol,A=T&&T.iterator,R=/^[+-]?0x/i,I=w(R.exec),$=S(C+"08")!==8||S(C+"0x16")!==22||A&&!g(function(){S(Object(A))});y.exports=$?function(M,B){var q=O(k(M));return S(q,B>>>0||(I(R,q)?16:10))}:S},1574:(y,j,r)=>{var v=r(9781),g=r(1702),w=r(6916),k=r(7293),O=r(1956),C=r(5181),S=r(5296),T=r(7908),A=r(8361),R=Object.assign,I=Object.defineProperty,$=g([].concat);y.exports=!R||k(function(){if(v&&R({b:1},R(I({},"a",{enumerable:!0,get:function(){I(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var M={},B={},q=Symbol(),F="abcdefghijklmnopqrst";return M[q]=7,F.split("").forEach(function(N){B[N]=N}),R({},M)[q]!=7||O(R({},B)).join("")!=F})?function(M,B){for(var q=T(M),F=arguments.length,N=1,U=C.f,H=S.f;F>N;)for(var X,Y=A(arguments[N++]),K=U?$(O(Y),U(Y)):O(Y),tt=K.length,it=0;tt>it;)X=K[it++],v&&!w(H,Y,X)||(q[X]=Y[X]);return q}:R},30:(y,j,r)=>{var v,g=r(9670),w=r(6048),k=r(748),O=r(3501),C=r(490),S=r(317),T=r(6200),A="prototype",R="script",I=T("IE_PROTO"),$=function(){},M=function(F){return"<"+R+">"+F+"</"+R+">"},B=function(F){F.write(M("")),F.close();var N=F.parentWindow.Object;return F=null,N},q=function(){try{v=new ActiveXObject("htmlfile")}catch{}var F,N,U;q=typeof document<"u"?document.domain&&v?B(v):(N=S("iframe"),U="java"+R+":",N.style.display="none",C.appendChild(N),N.src=String(U),(F=N.contentWindow.document).open(),F.write(M("document.F=Object")),F.close(),F.F):B(v);for(var H=k.length;H--;)delete q[A][k[H]];return q()};O[I]=!0,y.exports=Object.create||function(F,N){var U;return F!==null?($[A]=g(F),U=new $,$[A]=null,U[I]=F):U=q(),N===void 0?U:w.f(U,N)}},6048:(y,j,r)=>{var v=r(9781),g=r(3353),w=r(3070),k=r(9670),O=r(5656),C=r(1956);j.f=v&&!g?Object.defineProperties:function(S,T){k(S);for(var A,R=O(T),I=C(T),$=I.length,M=0;$>M;)w.f(S,A=I[M++],R[A]);return S}},3070:(y,j,r)=>{var v=r(9781),g=r(4664),w=r(3353),k=r(9670),O=r(4948),C=TypeError,S=Object.defineProperty,T=Object.getOwnPropertyDescriptor,A="enumerable",R="configurable",I="writable";j.f=v?w?function($,M,B){if(k($),M=O(M),k(B),typeof $=="function"&&M==="prototype"&&"value"in B&&I in B&&!B[I]){var q=T($,M);q&&q[I]&&($[M]=B.value,B={configurable:R in B?B[R]:q[R],enumerable:A in B?B[A]:q[A],writable:!1})}return S($,M,B)}:S:function($,M,B){if(k($),M=O(M),k(B),g)try{return S($,M,B)}catch{}if("get"in B||"set"in B)throw C("Accessors not supported");return"value"in B&&($[M]=B.value),$}},1236:(y,j,r)=>{var v=r(9781),g=r(6916),w=r(5296),k=r(9114),O=r(5656),C=r(4948),S=r(2597),T=r(4664),A=Object.getOwnPropertyDescriptor;j.f=v?A:function(R,I){if(R=O(R),I=C(I),T)try{return A(R,I)}catch{}if(S(R,I))return k(!g(w.f,R,I),R[I])}},1156:(y,j,r)=>{var v=r(4326),g=r(5656),w=r(8006).f,k=r(1589),O=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];y.exports.f=function(C){return O&&v(C)=="Window"?function(S){try{return w(S)}catch{return k(O)}}(C):w(g(C))}},8006:(y,j,r)=>{var v=r(6324),g=r(748).concat("length","prototype");j.f=Object.getOwnPropertyNames||function(w){return v(w,g)}},5181:(y,j)=>{j.f=Object.getOwnPropertySymbols},9518:(y,j,r)=>{var v=r(2597),g=r(614),w=r(7908),k=r(6200),O=r(8544),C=k("IE_PROTO"),S=Object,T=S.prototype;y.exports=O?S.getPrototypeOf:function(A){var R=w(A);if(v(R,C))return R[C];var I=R.constructor;return g(I)&&R instanceof I?I.prototype:R instanceof S?T:null}},7976:(y,j,r)=>{var v=r(1702);y.exports=v({}.isPrototypeOf)},6324:(y,j,r)=>{var v=r(1702),g=r(2597),w=r(5656),k=r(1318).indexOf,O=r(3501),C=v([].push);y.exports=function(S,T){var A,R=w(S),I=0,$=[];for(A in R)!g(O,A)&&g(R,A)&&C($,A);for(;T.length>I;)g(R,A=T[I++])&&(~k($,A)||C($,A));return $}},1956:(y,j,r)=>{var v=r(6324),g=r(748);y.exports=Object.keys||function(w){return v(w,g)}},5296:(y,j)=>{var r={}.propertyIsEnumerable,v=Object.getOwnPropertyDescriptor,g=v&&!r.call({1:2},1);j.f=g?function(w){var k=v(this,w);return!!k&&k.enumerable}:r},7674:(y,j,r)=>{var v=r(5668),g=r(9670),w=r(6077);y.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var k,O=!1,C={};try{(k=v(Object.prototype,"__proto__","set"))(C,[]),O=C instanceof Array}catch{}return function(S,T){return g(S),w(T),O?k(S,T):S.__proto__=T,S}}():void 0)},4699:(y,j,r)=>{var v=r(9781),g=r(1702),w=r(1956),k=r(5656),O=g(r(5296).f),C=g([].push),S=function(T){return function(A){for(var R,I=k(A),$=w(I),M=$.length,B=0,q=[];M>B;)R=$[B++],v&&!O(I,R)||C(q,T?[R,I[R]]:I[R]);return q}};y.exports={entries:S(!0),values:S(!1)}},288:(y,j,r)=>{var v=r(1694),g=r(648);y.exports=v?{}.toString:function(){return"[object "+g(this)+"]"}},2140:(y,j,r)=>{var v=r(6916),g=r(614),w=r(111),k=TypeError;y.exports=function(O,C){var S,T;if(C==="string"&&g(S=O.toString)&&!w(T=v(S,O))||g(S=O.valueOf)&&!w(T=v(S,O))||C!=="string"&&g(S=O.toString)&&!w(T=v(S,O)))return T;throw k("Can't convert object to primitive value")}},3887:(y,j,r)=>{var v=r(5005),g=r(1702),w=r(8006),k=r(5181),O=r(9670),C=g([].concat);y.exports=v("Reflect","ownKeys")||function(S){var T=w.f(O(S)),A=k.f;return A?C(T,A(S)):T}},857:(y,j,r)=>{var v=r(7854);y.exports=v},2534:y=>{y.exports=function(j){try{return{error:!1,value:j()}}catch(r){return{error:!0,value:r}}}},3702:(y,j,r)=>{var v=r(7854),g=r(2492),w=r(614),k=r(4705),O=r(2788),C=r(5112),S=r(7871),T=r(3823),A=r(1913),R=r(7392),I=g&&g.prototype,$=C("species"),M=!1,B=w(v.PromiseRejectionEvent),q=k("Promise",function(){var F=O(g),N=F!==String(g);if(!N&&R===66||A&&(!I.catch||!I.finally))return!0;if(!R||R<51||!/native code/.test(F)){var U=new g(function(X){X(1)}),H=function(X){X(function(){},function(){})};if((U.constructor={})[$]=H,!(M=U.then(function(){})instanceof H))return!0}return!N&&(S||T)&&!B});y.exports={CONSTRUCTOR:q,REJECTION_EVENT:B,SUBCLASSING:M}},2492:(y,j,r)=>{var v=r(7854);y.exports=v.Promise},9478:(y,j,r)=>{var v=r(9670),g=r(111),w=r(8523);y.exports=function(k,O){if(v(k),g(O)&&O.constructor===k)return O;var C=w.f(k);return(0,C.resolve)(O),C.promise}},612:(y,j,r)=>{var v=r(2492),g=r(7072),w=r(3702).CONSTRUCTOR;y.exports=w||!g(function(k){v.all(k).then(void 0,function(){})})},2626:(y,j,r)=>{var v=r(3070).f;y.exports=function(g,w,k){k in g||v(g,k,{configurable:!0,get:function(){return w[k]},set:function(O){w[k]=O}})}},8572:y=>{var j=function(){this.head=null,this.tail=null};j.prototype={add:function(r){var v={item:r,next:null},g=this.tail;g?g.next=v:this.head=v,this.tail=v},get:function(){var r=this.head;if(r)return(this.head=r.next)===null&&(this.tail=null),r.item}},y.exports=j},7651:(y,j,r)=>{var v=r(6916),g=r(9670),w=r(614),k=r(4326),O=r(2261),C=TypeError;y.exports=function(S,T){var A=S.exec;if(w(A)){var R=v(A,S,T);return R!==null&&g(R),R}if(k(S)==="RegExp")return v(O,S,T);throw C("RegExp#exec called on incompatible receiver")}},2261:(y,j,r)=>{var v,g,w=r(6916),k=r(1702),O=r(1340),C=r(7066),S=r(2999),T=r(2309),A=r(30),R=r(9909).get,I=r(9441),$=r(7168),M=T("native-string-replace",String.prototype.replace),B=RegExp.prototype.exec,q=B,F=k("".charAt),N=k("".indexOf),U=k("".replace),H=k("".slice),X=(g=/b*/g,w(B,v=/a/,"a"),w(B,g,"a"),v.lastIndex!==0||g.lastIndex!==0),Y=S.BROKEN_CARET,K=/()??/.exec("")[1]!==void 0;(X||K||Y||I||$)&&(q=function(tt){var it,st,yt,ct,Et,At,Vt,lt=this,wt=R(lt),_t=O(tt),Ut=wt.raw;if(Ut)return Ut.lastIndex=lt.lastIndex,it=w(q,Ut,_t),lt.lastIndex=Ut.lastIndex,it;var Kt=wt.groups,fe=Y&<.sticky,St=w(C,lt),jt=lt.source,It=0,qt=_t;if(fe&&(St=U(St,"y",""),N(St,"g")===-1&&(St+="g"),qt=H(_t,lt.lastIndex),lt.lastIndex>0&&(!lt.multiline||lt.multiline&&F(_t,lt.lastIndex-1)!==`
|
|
71
|
+
`)&&(jt="(?: "+jt+")",qt=" "+qt,It++),st=new RegExp("^(?:"+jt+")",St)),K&&(st=new RegExp("^"+jt+"$(?!\\s)",St)),X&&(yt=lt.lastIndex),ct=w(B,fe?st:lt,qt),fe?ct?(ct.input=H(ct.input,It),ct[0]=H(ct[0],It),ct.index=lt.lastIndex,lt.lastIndex+=ct[0].length):lt.lastIndex=0:X&&ct&&(lt.lastIndex=lt.global?ct.index+ct[0].length:yt),K&&ct&&ct.length>1&&w(M,ct[0],st,function(){for(Et=1;Et<arguments.length-2;Et++)arguments[Et]===void 0&&(ct[Et]=void 0)}),ct&&Kt)for(ct.groups=At=A(null),Et=0;Et<Kt.length;Et++)At[(Vt=Kt[Et])[0]]=ct[Vt[1]];return ct}),y.exports=q},7066:(y,j,r)=>{var v=r(9670);y.exports=function(){var g=v(this),w="";return g.hasIndices&&(w+="d"),g.global&&(w+="g"),g.ignoreCase&&(w+="i"),g.multiline&&(w+="m"),g.dotAll&&(w+="s"),g.unicode&&(w+="u"),g.unicodeSets&&(w+="v"),g.sticky&&(w+="y"),w}},4706:(y,j,r)=>{var v=r(6916),g=r(2597),w=r(7976),k=r(7066),O=RegExp.prototype;y.exports=function(C){var S=C.flags;return S!==void 0||"flags"in O||g(C,"flags")||!w(O,C)?S:v(k,C)}},2999:(y,j,r)=>{var v=r(7293),g=r(7854).RegExp,w=v(function(){var C=g("a","y");return C.lastIndex=2,C.exec("abcd")!=null}),k=w||v(function(){return!g("a","y").sticky}),O=w||v(function(){var C=g("^r","gy");return C.lastIndex=2,C.exec("str")!=null});y.exports={BROKEN_CARET:O,MISSED_STICKY:k,UNSUPPORTED_Y:w}},9441:(y,j,r)=>{var v=r(7293),g=r(7854).RegExp;y.exports=v(function(){var w=g(".","s");return!(w.dotAll&&w.exec(`
|
|
72
72
|
`)&&w.flags==="s")})},7168:(y,j,r)=>{var v=r(7293),g=r(7854).RegExp;y.exports=v(function(){var w=g("(?<a>b)","g");return w.exec("b").groups.a!=="b"||"b".replace(w,"$<a>c")!=="bc"})},4488:(y,j,r)=>{var v=r(8554),g=TypeError;y.exports=function(w){if(v(w))throw g("Can't call method on "+w);return w}},7152:(y,j,r)=>{var v,g=r(7854),w=r(2104),k=r(614),O=r(9363),C=r(8113),S=r(206),T=r(8053),A=g.Function,R=/MSIE .\./.test(C)||O&&((v=g.Bun.version.split(".")).length<3||v[0]==0&&(v[1]<3||v[1]==3&&v[2]==0));y.exports=function(I,$){var M=$?2:1;return R?function(B,q){var F=T(arguments.length,1)>M,N=k(B)?B:A(B),U=F?S(arguments,M):[],H=F?function(){w(N,this,U)}:N;return $?I(H,q):I(H)}:I}},6340:(y,j,r)=>{var v=r(5005),g=r(7045),w=r(5112),k=r(9781),O=w("species");y.exports=function(C){var S=v(C);k&&S&&!S[O]&&g(S,O,{configurable:!0,get:function(){return this}})}},8003:(y,j,r)=>{var v=r(3070).f,g=r(2597),w=r(5112)("toStringTag");y.exports=function(k,O,C){k&&!C&&(k=k.prototype),k&&!g(k,w)&&v(k,w,{configurable:!0,value:O})}},6200:(y,j,r)=>{var v=r(2309),g=r(9711),w=v("keys");y.exports=function(k){return w[k]||(w[k]=g(k))}},5465:(y,j,r)=>{var v=r(7854),g=r(3072),w="__core-js_shared__",k=v[w]||g(w,{});y.exports=k},2309:(y,j,r)=>{var v=r(1913),g=r(5465);(y.exports=function(w,k){return g[w]||(g[w]=k!==void 0?k:{})})("versions",[]).push({version:"3.29.0",mode:v?"pure":"global",copyright:"© 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.29.0/LICENSE",source:"https://github.com/zloirock/core-js"})},6707:(y,j,r)=>{var v=r(9670),g=r(9483),w=r(8554),k=r(5112)("species");y.exports=function(O,C){var S,T=v(O).constructor;return T===void 0||w(S=v(T)[k])?C:g(S)}},8710:(y,j,r)=>{var v=r(1702),g=r(9303),w=r(1340),k=r(4488),O=v("".charAt),C=v("".charCodeAt),S=v("".slice),T=function(A){return function(R,I){var $,M,B=w(k(R)),q=g(I),F=B.length;return q<0||q>=F?A?"":void 0:($=C(B,q))<55296||$>56319||q+1===F||(M=C(B,q+1))<56320||M>57343?A?O(B,q):$:A?S(B,q,q+2):M-56320+($-55296<<10)+65536}};y.exports={codeAt:T(!1),charAt:T(!0)}},6650:(y,j,r)=>{var v=r(1702),g=r(7466),w=r(1340),k=r(8415),O=r(4488),C=v(k),S=v("".slice),T=Math.ceil,A=function(R){return function(I,$,M){var B,q,F=w(O(I)),N=g($),U=F.length,H=M===void 0?" ":w(M);return N<=U||H==""?F:((q=C(H,T((B=N-U)/H.length))).length>B&&(q=S(q,0,B)),R?F+q:q+F)}};y.exports={start:A(!1),end:A(!0)}},8415:(y,j,r)=>{var v=r(9303),g=r(1340),w=r(4488),k=RangeError;y.exports=function(O){var C=g(w(this)),S="",T=v(O);if(T<0||T==1/0)throw k("Wrong number of repetitions");for(;T>0;(T>>>=1)&&(C+=C))1&T&&(S+=C);return S}},6091:(y,j,r)=>{var v=r(6530).PROPER,g=r(7293),w=r(1361);y.exports=function(k){return g(function(){return!!w[k]()||"
"[k]()!=="
"||v&&w[k].name!==k})}},3111:(y,j,r)=>{var v=r(1702),g=r(4488),w=r(1340),k=r(1361),O=v("".replace),C=RegExp("^["+k+"]+"),S=RegExp("(^|[^"+k+"])["+k+"]+$"),T=function(A){return function(R){var I=w(g(R));return 1&A&&(I=O(I,C,"")),2&A&&(I=O(I,S,"$1")),I}};y.exports={start:T(1),end:T(2),trim:T(3)}},6293:(y,j,r)=>{var v=r(7392),g=r(7293);y.exports=!!Object.getOwnPropertySymbols&&!g(function(){var w=Symbol();return!String(w)||!(Object(w)instanceof Symbol)||!Symbol.sham&&v&&v<41})},6532:(y,j,r)=>{var v=r(6916),g=r(5005),w=r(5112),k=r(8052);y.exports=function(){var O=g("Symbol"),C=O&&O.prototype,S=C&&C.valueOf,T=w("toPrimitive");C&&!C[T]&&k(C,T,function(A){return v(S,this)},{arity:1})}},2015:(y,j,r)=>{var v=r(6293);y.exports=v&&!!Symbol.for&&!!Symbol.keyFor},261:(y,j,r)=>{var v,g,w,k,O=r(7854),C=r(2104),S=r(9974),T=r(614),A=r(2597),R=r(7293),I=r(490),$=r(206),M=r(317),B=r(8053),q=r(8334),F=r(5268),N=O.setImmediate,U=O.clearImmediate,H=O.process,X=O.Dispatch,Y=O.Function,K=O.MessageChannel,tt=O.String,it=0,st={},yt="onreadystatechange";R(function(){v=O.location});var ct=function(lt){if(A(st,lt)){var wt=st[lt];delete st[lt],wt()}},Et=function(lt){return function(){ct(lt)}},At=function(lt){ct(lt.data)},Vt=function(lt){O.postMessage(tt(lt),v.protocol+"//"+v.host)};N&&U||(N=function(lt){B(arguments.length,1);var wt=T(lt)?lt:Y(lt),_t=$(arguments,1);return st[++it]=function(){C(wt,void 0,_t)},g(it),it},U=function(lt){delete st[lt]},F?g=function(lt){H.nextTick(Et(lt))}:X&&X.now?g=function(lt){X.now(Et(lt))}:K&&!q?(k=(w=new K).port2,w.port1.onmessage=At,g=S(k.postMessage,k)):O.addEventListener&&T(O.postMessage)&&!O.importScripts&&v&&v.protocol!=="file:"&&!R(Vt)?(g=Vt,O.addEventListener("message",At,!1)):g=yt in M("script")?function(lt){I.appendChild(M("script"))[yt]=function(){I.removeChild(this),ct(lt)}}:function(lt){setTimeout(Et(lt),0)}),y.exports={set:N,clear:U}},863:(y,j,r)=>{var v=r(1702);y.exports=v(1 .valueOf)},1400:(y,j,r)=>{var v=r(9303),g=Math.max,w=Math.min;y.exports=function(k,O){var C=v(k);return C<0?g(C+O,0):w(C,O)}},5656:(y,j,r)=>{var v=r(8361),g=r(4488);y.exports=function(w){return v(g(w))}},9303:(y,j,r)=>{var v=r(4758);y.exports=function(g){var w=+g;return w!=w||w===0?0:v(w)}},7466:(y,j,r)=>{var v=r(9303),g=Math.min;y.exports=function(w){return w>0?g(v(w),9007199254740991):0}},7908:(y,j,r)=>{var v=r(4488),g=Object;y.exports=function(w){return g(v(w))}},7593:(y,j,r)=>{var v=r(6916),g=r(111),w=r(2190),k=r(8173),O=r(2140),C=r(5112),S=TypeError,T=C("toPrimitive");y.exports=function(A,R){if(!g(A)||w(A))return A;var I,$=k(A,T);if($){if(R===void 0&&(R="default"),I=v($,A,R),!g(I)||w(I))return I;throw S("Can't convert object to primitive value")}return R===void 0&&(R="number"),O(A,R)}},4948:(y,j,r)=>{var v=r(7593),g=r(2190);y.exports=function(w){var k=v(w,"string");return g(k)?k:k+""}},1694:(y,j,r)=>{var v={};v[r(5112)("toStringTag")]="z",y.exports=String(v)==="[object z]"},1340:(y,j,r)=>{var v=r(648),g=String;y.exports=function(w){if(v(w)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return g(w)}},6330:y=>{var j=String;y.exports=function(r){try{return j(r)}catch{return"Object"}}},9711:(y,j,r)=>{var v=r(1702),g=0,w=Math.random(),k=v(1 .toString);y.exports=function(O){return"Symbol("+(O===void 0?"":O)+")_"+k(++g+w,36)}},3307:(y,j,r)=>{var v=r(6293);y.exports=v&&!Symbol.sham&&typeof Symbol.iterator=="symbol"},3353:(y,j,r)=>{var v=r(9781),g=r(7293);y.exports=v&&g(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!=42})},8053:y=>{var j=TypeError;y.exports=function(r,v){if(r<v)throw j("Not enough arguments");return r}},4811:(y,j,r)=>{var v=r(7854),g=r(614),w=v.WeakMap;y.exports=g(w)&&/native code/.test(String(w))},6800:(y,j,r)=>{var v=r(857),g=r(2597),w=r(6061),k=r(3070).f;y.exports=function(O){var C=v.Symbol||(v.Symbol={});g(C,O)||k(C,O,{value:w.f(O)})}},6061:(y,j,r)=>{var v=r(5112);j.f=v},5112:(y,j,r)=>{var v=r(7854),g=r(2309),w=r(2597),k=r(9711),O=r(6293),C=r(3307),S=v.Symbol,T=g("wks"),A=C?S.for||S:S&&S.withoutSetter||k;y.exports=function(R){return w(T,R)||(T[R]=O&&w(S,R)?S[R]:A("Symbol."+R)),T[R]}},1361:y=>{y.exports=`
|
|
73
|
-
\v\f\r \u2028\u2029\uFEFF`},2222:(y,j,r)=>{var v=r(2109),g=r(7293),w=r(3157),k=r(111),O=r(7908),C=r(6244),S=r(7207),T=r(6135),A=r(5417),R=r(1194),I=r(5112),$=r(7392),M=I("isConcatSpreadable"),B=$>=51||!g(function(){var F=[];return F[M]=!1,F.concat()[0]!==F}),q=function(F){if(!k(F))return!1;var N=F[M];return N!==void 0?!!N:w(F)};v({target:"Array",proto:!0,arity:1,forced:!B||!R("concat")},{concat:function(F){var N,U,H,X,Y,K=O(this),tt=A(K,0),it=0;for(N=-1,H=arguments.length;N<H;N++)if(q(Y=N===-1?K:arguments[N]))for(X=C(Y),S(it+X),U=0;U<X;U++,it++)U in Y&&T(tt,it,Y[U]);else S(it+1),T(tt,it++,Y);return tt.length=it,tt}})},6541:(y,j,r)=>{var v=r(2109),g=r(2092).every;v({target:"Array",proto:!0,forced:!r(9341)("every")},{every:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},7327:(y,j,r)=>{var v=r(2109),g=r(2092).filter;v({target:"Array",proto:!0,forced:!r(1194)("filter")},{filter:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},9826:(y,j,r)=>{var v=r(2109),g=r(2092).find,w=r(1223),k="find",O=!0;k in[]&&Array(1)[k](function(){O=!1}),v({target:"Array",proto:!0,forced:O},{find:function(C){return g(this,C,arguments.length>1?arguments[1]:void 0)}}),w(k)},9554:(y,j,r)=>{var v=r(2109),g=r(8533);v({target:"Array",proto:!0,forced:[].forEach!=g},{forEach:g})},1038:(y,j,r)=>{var v=r(2109),g=r(8457);v({target:"Array",stat:!0,forced:!r(7072)(function(w){Array.from(w)})},{from:g})},6699:(y,j,r)=>{var v=r(2109),g=r(1318).includes,w=r(7293),k=r(1223);v({target:"Array",proto:!0,forced:w(function(){return!Array(1).includes()})},{includes:function(O){return g(this,O,arguments.length>1?arguments[1]:void 0)}}),k("includes")},2772:(y,j,r)=>{var v=r(2109),g=r(1470),w=r(1318).indexOf,k=r(9341),O=g([].indexOf),C=!!O&&1/O([1],1,-0)<0;v({target:"Array",proto:!0,forced:C||!k("indexOf")},{indexOf:function(S){var T=arguments.length>1?arguments[1]:void 0;return C?O(this,S,T)||0:w(this,S,T)}})},9753:(y,j,r)=>{r(2109)({target:"Array",stat:!0},{isArray:r(3157)})},6992:(y,j,r)=>{var v=r(5656),g=r(1223),w=r(7497),k=r(9909),O=r(3070).f,C=r(1656),S=r(6178),T=r(1913),A=r(9781),R="Array Iterator",I=k.set,$=k.getterFor(R);y.exports=C(Array,"Array",function(B,q){I(this,{type:R,target:v(B),index:0,kind:q})},function(){var B=$(this),q=B.target,F=B.kind,N=B.index++;return!q||N>=q.length?(B.target=void 0,S(void 0,!0)):S(F=="keys"?N:F=="values"?q[N]:[N,q[N]],!1)},"values");var M=w.Arguments=w.Array;if(g("keys"),g("values"),g("entries"),!T&&A&&M.name!=="values")try{O(M,"name",{value:"values"})}catch{}},9600:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(8361),k=r(5656),O=r(9341),C=g([].join);v({target:"Array",proto:!0,forced:w!=Object||!O("join",",")},{join:function(S){return C(k(this),S===void 0?",":S)}})},1249:(y,j,r)=>{var v=r(2109),g=r(2092).map;v({target:"Array",proto:!0,forced:!r(1194)("map")},{map:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},5827:(y,j,r)=>{var v=r(2109),g=r(3671).left,w=r(9341),k=r(7392);v({target:"Array",proto:!0,forced:!r(5268)&&k>79&&k<83||!w("reduce")},{reduce:function(O){var C=arguments.length;return g(this,O,C,C>1?arguments[1]:void 0)}})},5069:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(3157),k=g([].reverse),O=[1,2];v({target:"Array",proto:!0,forced:String(O)===String(O.reverse())},{reverse:function(){return w(this)&&(this.length=this.length),k(this)}})},7042:(y,j,r)=>{var v=r(2109),g=r(3157),w=r(4411),k=r(111),O=r(1400),C=r(6244),S=r(5656),T=r(6135),A=r(5112),R=r(1194),I=r(206),$=R("slice"),M=A("species"),B=Array,q=Math.max;v({target:"Array",proto:!0,forced:!$},{slice:function(F,N){var U,H,X,Y=S(this),K=C(Y),tt=O(F,K),it=O(N===void 0?K:N,K);if(g(Y)&&(U=Y.constructor,(w(U)&&(U===B||g(U.prototype))||k(U)&&(U=U[M])===null)&&(U=void 0),U===B||U===void 0))return I(Y,tt,it);for(H=new(U===void 0?B:U)(q(it-tt,0)),X=0;tt<it;tt++,X++)tt in Y&&T(H,X,Y[tt]);return H.length=X,H}})},5212:(y,j,r)=>{var v=r(2109),g=r(2092).some;v({target:"Array",proto:!0,forced:!r(9341)("some")},{some:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},2707:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(9662),k=r(7908),O=r(6244),C=r(5117),S=r(1340),T=r(7293),A=r(4362),R=r(9341),I=r(8886),$=r(256),M=r(7392),B=r(8008),q=[],F=g(q.sort),N=g(q.push),U=T(function(){q.sort(void 0)}),H=T(function(){q.sort(null)}),X=R("sort"),Y=!T(function(){if(M)return M<70;if(!(I&&I>3)){if($)return!0;if(B)return B<603;var K,tt,it,st,yt="";for(K=65;K<76;K++){switch(tt=String.fromCharCode(K),K){case 66:case 69:case 70:case 72:it=3;break;case 68:case 71:it=4;break;default:it=2}for(st=0;st<47;st++)q.push({k:tt+st,v:it})}for(q.sort(function(ct,Et){return Et.v-ct.v}),st=0;st<q.length;st++)tt=q[st].k.charAt(0),yt.charAt(yt.length-1)!==tt&&(yt+=tt);return yt!=="DGBEFHACIJK"}});v({target:"Array",proto:!0,forced:U||!H||!X||!Y},{sort:function(K){K!==void 0&&w(K);var tt=k(this);if(Y)return K===void 0?F(tt):F(tt,K);var it,st,yt=[],ct=O(tt);for(st=0;st<ct;st++)st in tt&&N(yt,tt[st]);for(A(yt,function(Et){return function(At,Vt){return Vt===void 0?-1:At===void 0?1:Et!==void 0?+Et(At,Vt)||0:S(At)>S(Vt)?1:-1}}(K)),it=O(yt),st=0;st<it;)tt[st]=yt[st++];for(;st<ct;)C(tt,st++);return tt}})},561:(y,j,r)=>{var v=r(2109),g=r(7908),w=r(1400),k=r(9303),O=r(6244),C=r(3658),S=r(7207),T=r(5417),A=r(6135),R=r(5117),I=r(1194)("splice"),$=Math.max,M=Math.min;v({target:"Array",proto:!0,forced:!I},{splice:function(B,q){var F,N,U,H,X,Y,K=g(this),tt=O(K),it=w(B,tt),st=arguments.length;for(st===0?F=N=0:st===1?(F=0,N=tt-it):(F=st-2,N=M($(k(q),0),tt-it)),S(tt+F-N),U=T(K,N),H=0;H<N;H++)(X=it+H)in K&&A(U,H,K[X]);if(U.length=N,F<N){for(H=it;H<tt-N;H++)Y=H+F,(X=H+N)in K?K[Y]=K[X]:R(K,Y);for(H=tt;H>tt-N+F;H--)R(K,H-1)}else if(F>N)for(H=tt-N;H>it;H--)Y=H+F-1,(X=H+N-1)in K?K[Y]=K[X]:R(K,Y);for(H=0;H<F;H++)K[H+it]=arguments[H+2];return C(K,tt-N+F),U}})},3843:(y,j,r)=>{var v=r(2109),g=r(1702),w=Date,k=g(w.prototype.getTime);v({target:"Date",stat:!0},{now:function(){return k(new w)}})},8733:(y,j,r)=>{var v=r(2109),g=r(5573);v({target:"Date",proto:!0,forced:Date.prototype.toISOString!==g},{toISOString:g})},6078:(y,j,r)=>{var v=r(2597),g=r(8052),w=r(8709),k=r(5112)("toPrimitive"),O=Date.prototype;v(O,k)||g(O,k,w)},3710:(y,j,r)=>{var v=r(1702),g=r(8052),w=Date.prototype,k="Invalid Date",O="toString",C=v(w[O]),S=v(w.getTime);String(new Date(NaN))!=k&&g(w,O,function(){var T=S(this);return T==T?C(this):k})},4812:(y,j,r)=>{var v=r(2109),g=r(7065);v({target:"Function",proto:!0,forced:Function.bind!==g},{bind:g})},8309:(y,j,r)=>{var v=r(9781),g=r(6530).EXISTS,w=r(1702),k=r(7045),O=Function.prototype,C=w(O.toString),S=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,T=w(S.exec);v&&!g&&k(O,"name",{configurable:!0,get:function(){try{return T(S,C(this))[1]}catch{return""}}})},8862:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(2104),k=r(6916),O=r(1702),C=r(7293),S=r(614),T=r(2190),A=r(206),R=r(8044),I=r(6293),$=String,M=g("JSON","stringify"),B=O(/./.exec),q=O("".charAt),F=O("".charCodeAt),N=O("".replace),U=O(1 .toString),H=/[\uD800-\uDFFF]/g,X=/^[\uD800-\uDBFF]$/,Y=/^[\uDC00-\uDFFF]$/,K=!I||C(function(){var yt=g("Symbol")();return M([yt])!="[null]"||M({a:yt})!="{}"||M(Object(yt))!="{}"}),tt=C(function(){return M("\uDF06\uD834")!=='"\\udf06\\ud834"'||M("\uDEAD")!=='"\\udead"'}),it=function(yt,ct){var Et=A(arguments),At=R(ct);if(S(At)||yt!==void 0&&!T(yt))return Et[1]=function(Vt,lt){if(S(At)&&(lt=k(At,this,$(Vt),lt)),!T(lt))return lt},w(M,null,Et)},st=function(yt,ct,Et){var At=q(Et,ct-1),Vt=q(Et,ct+1);return B(X,yt)&&!B(Y,Vt)||B(Y,yt)&&!B(X,At)?"\\u"+U(F(yt,0),16):yt};M&&v({target:"JSON",stat:!0,arity:3,forced:K||tt},{stringify:function(yt,ct,Et){var At=A(arguments),Vt=w(K?it:M,null,At);return tt&&typeof Vt=="string"?N(Vt,H,st):Vt}})},3706:(y,j,r)=>{var v=r(7854);r(8003)(v.JSON,"JSON",!0)},2703:(y,j,r)=>{r(8003)(Math,"Math",!0)},9653:(y,j,r)=>{var v=r(2109),g=r(1913),w=r(9781),k=r(7854),O=r(857),C=r(1702),S=r(4705),T=r(2597),A=r(9587),R=r(7976),I=r(2190),$=r(7593),M=r(7293),B=r(8006).f,q=r(1236).f,F=r(3070).f,N=r(863),U=r(3111).trim,H="Number",X=k[H],Y=O[H],K=X.prototype,tt=k.TypeError,it=C("".slice),st=C("".charCodeAt),yt=function(wt){var _t=$(wt,"number");return typeof _t=="bigint"?_t:ct(_t)},ct=function(wt){var _t,Ut,Kt,fe,St,jt,Bt,qt,xt=$(wt,"number");if(I(xt))throw tt("Cannot convert a Symbol value to a number");if(typeof xt=="string"&&xt.length>2){if(xt=U(xt),(_t=st(xt,0))===43||_t===45){if((Ut=st(xt,2))===88||Ut===120)return NaN}else if(_t===48){switch(st(xt,1)){case 66:case 98:Kt=2,fe=49;break;case 79:case 111:Kt=8,fe=55;break;default:return+xt}for(jt=(St=it(xt,2)).length,Bt=0;Bt<jt;Bt++)if((qt=st(St,Bt))<48||qt>fe)return NaN;return parseInt(St,Kt)}}return+xt},Et=S(H,!X(" 0o1")||!X("0b1")||X("+0x1")),At=function(wt){return R(K,wt)&&M(function(){N(wt)})},Vt=function(wt){var _t=arguments.length<1?0:X(yt(wt));return At(this)?A(Object(_t),this,Vt):_t};Vt.prototype=K,Et&&!g&&(K.constructor=Vt),v({global:!0,constructor:!0,wrap:!0,forced:Et},{Number:Vt});var lt=function(wt,_t){for(var Ut,Kt=w?B(_t):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range".split(","),fe=0;Kt.length>fe;fe++)T(_t,Ut=Kt[fe])&&!T(wt,Ut)&&F(wt,Ut,q(_t,Ut))};g&&Y&<(O[H],Y),(Et||g)&<(O[H],X)},6977:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(9303),k=r(863),O=r(8415),C=r(7293),S=RangeError,T=String,A=Math.floor,R=g(O),I=g("".slice),$=g(1 .toFixed),M=function(N,U,H){return U===0?H:U%2==1?M(N,U-1,H*N):M(N*N,U/2,H)},B=function(N,U,H){for(var X=-1,Y=H;++X<6;)Y+=U*N[X],N[X]=Y%1e7,Y=A(Y/1e7)},q=function(N,U){for(var H=6,X=0;--H>=0;)X+=N[H],N[H]=A(X/U),X=X%U*1e7},F=function(N){for(var U=6,H="";--U>=0;)if(H!==""||U===0||N[U]!==0){var X=T(N[U]);H=H===""?X:H+R("0",7-X.length)+X}return H};v({target:"Number",proto:!0,forced:C(function(){return $(8e-5,3)!=="0.000"||$(.9,0)!=="1"||$(1.255,2)!=="1.25"||$(0xde0b6b3a7640080,0)!=="1000000000000000128"})||!C(function(){$({})})},{toFixed:function(N){var U,H,X,Y,K=k(this),tt=w(N),it=[0,0,0,0,0,0],st="",yt="0";if(tt<0||tt>20)throw S("Incorrect fraction digits");if(K!=K)return"NaN";if(K<=-1e21||K>=1e21)return T(K);if(K<0&&(st="-",K=-K),K>1e-21)if(H=(U=function(ct){for(var Et=0,At=ct;At>=4096;)Et+=12,At/=4096;for(;At>=2;)Et+=1,At/=2;return Et}(K*M(2,69,1))-69)<0?K*M(2,-U,1):K/M(2,U,1),H*=4503599627370496,(U=52-U)>0){for(B(it,0,H),X=tt;X>=7;)B(it,1e7,0),X-=7;for(B(it,M(10,X,1),0),X=U-1;X>=23;)q(it,8388608),X-=23;q(it,1<<X),B(it,1,1),q(it,2),yt=F(it)}else B(it,0,H),B(it,1<<-U,0),yt=F(it)+R("0",tt);return tt>0?st+((Y=yt.length)<=tt?"0."+R("0",tt-Y)+yt:I(yt,0,Y-tt)+"."+I(yt,Y-tt)):st+yt}})},9601:(y,j,r)=>{var v=r(2109),g=r(1574);v({target:"Object",stat:!0,arity:2,forced:Object.assign!==g},{assign:g})},8011:(y,j,r)=>{r(2109)({target:"Object",stat:!0,sham:!r(9781)},{create:r(30)})},3321:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(6048).f;v({target:"Object",stat:!0,forced:Object.defineProperties!==w,sham:!g},{defineProperties:w})},9070:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(3070).f;v({target:"Object",stat:!0,forced:Object.defineProperty!==w,sham:!g},{defineProperty:w})},9720:(y,j,r)=>{var v=r(2109),g=r(4699).entries;v({target:"Object",stat:!0},{entries:function(w){return g(w)}})},5003:(y,j,r)=>{var v=r(2109),g=r(7293),w=r(5656),k=r(1236).f,O=r(9781);v({target:"Object",stat:!0,forced:!O||g(function(){k(1)}),sham:!O},{getOwnPropertyDescriptor:function(C,S){return k(w(C),S)}})},9337:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(3887),k=r(5656),O=r(1236),C=r(6135);v({target:"Object",stat:!0,sham:!g},{getOwnPropertyDescriptors:function(S){for(var T,A,R=k(S),I=O.f,$=w(R),M={},B=0;$.length>B;)(A=I(R,T=$[B++]))!==void 0&&C(M,T,A);return M}})},9660:(y,j,r)=>{var v=r(2109),g=r(6293),w=r(7293),k=r(5181),O=r(7908);v({target:"Object",stat:!0,forced:!g||w(function(){k.f(1)})},{getOwnPropertySymbols:function(C){var S=k.f;return S?S(O(C)):[]}})},489:(y,j,r)=>{var v=r(2109),g=r(7293),w=r(7908),k=r(9518),O=r(8544);v({target:"Object",stat:!0,forced:g(function(){k(1)}),sham:!O},{getPrototypeOf:function(C){return k(w(C))}})},7941:(y,j,r)=>{var v=r(2109),g=r(7908),w=r(1956);v({target:"Object",stat:!0,forced:r(7293)(function(){w(1)})},{keys:function(k){return w(g(k))}})},8304:(y,j,r)=>{r(2109)({target:"Object",stat:!0},{setPrototypeOf:r(7674)})},1539:(y,j,r)=>{var v=r(1694),g=r(8052),w=r(288);v||g(Object.prototype,"toString",w,{unsafe:!0})},6833:(y,j,r)=>{var v=r(2109),g=r(4699).values;v({target:"Object",stat:!0},{values:function(w){return g(w)}})},4678:(y,j,r)=>{var v=r(2109),g=r(2814);v({global:!0,forced:parseFloat!=g},{parseFloat:g})},1058:(y,j,r)=>{var v=r(2109),g=r(3009);v({global:!0,forced:parseInt!=g},{parseInt:g})},821:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(9662),k=r(8523),O=r(2534),C=r(408);v({target:"Promise",stat:!0,forced:r(612)},{all:function(S){var T=this,A=k.f(T),R=A.resolve,I=A.reject,$=O(function(){var M=w(T.resolve),B=[],q=0,F=1;C(S,function(N){var U=q++,H=!1;F++,g(M,T,N).then(function(X){H||(H=!0,B[U]=X,--F||R(B))},I)}),--F||R(B)});return $.error&&I($.value),A.promise}})},4164:(y,j,r)=>{var v=r(2109),g=r(1913),w=r(3702).CONSTRUCTOR,k=r(2492),O=r(5005),C=r(614),S=r(8052),T=k&&k.prototype;if(v({target:"Promise",proto:!0,forced:w,real:!0},{catch:function(R){return this.then(void 0,R)}}),!g&&C(k)){var A=O("Promise").prototype.catch;T.catch!==A&&S(T,"catch",A,{unsafe:!0})}},3401:(y,j,r)=>{var v,g,w,k=r(2109),O=r(1913),C=r(5268),S=r(7854),T=r(6916),A=r(8052),R=r(7674),I=r(8003),$=r(6340),M=r(9662),B=r(614),q=r(111),F=r(5787),N=r(6707),U=r(261).set,H=r(5948),X=r(842),Y=r(2534),K=r(8572),tt=r(9909),it=r(2492),st=r(3702),yt=r(8523),ct="Promise",Et=st.CONSTRUCTOR,At=st.REJECTION_EVENT,Vt=st.SUBCLASSING,lt=tt.getterFor(ct),wt=tt.set,_t=it&&it.prototype,Ut=it,Kt=_t,fe=S.TypeError,St=S.document,jt=S.process,Bt=yt.f,qt=Bt,xt=!!(St&&St.createEvent&&S.dispatchEvent),lr="unhandledrejection",de=function(ot){var bt;return!(!q(ot)||!B(bt=ot.then))&&bt},Ne=function(ot,bt){var Ht,Mt,Qt,Ze=bt.value,Ke=bt.state==1,xr=Ke?ot.ok:ot.fail,Qe=ot.resolve,fr=ot.reject,Se=ot.domain;try{xr?(Ke||(bt.rejection===2&&Le(bt),bt.rejection=1),xr===!0?Ht=Ze:(Se&&Se.enter(),Ht=xr(Ze),Se&&(Se.exit(),Qt=!0)),Ht===ot.promise?fr(fe("Promise-chain cycle")):(Mt=de(Ht))?T(Mt,Ht,Qe,fr):Qe(Ht)):fr(Ze)}catch(Dn){Se&&!Qt&&Se.exit(),fr(Dn)}},ge=function(ot,bt){ot.notified||(ot.notified=!0,H(function(){for(var Ht,Mt=ot.reactions;Ht=Mt.get();)Ne(Ht,ot);ot.notified=!1,bt&&!ot.rejection&&Ae(ot)}))},cr=function(ot,bt,Ht){var Mt,Qt;xt?((Mt=St.createEvent("Event")).promise=bt,Mt.reason=Ht,Mt.initEvent(ot,!1,!0),S.dispatchEvent(Mt)):Mt={promise:bt,reason:Ht},!At&&(Qt=S["on"+ot])?Qt(Mt):ot===lr&&X("Unhandled promise rejection",Ht)},Ae=function(ot){T(U,S,function(){var bt,Ht=ot.facade,Mt=ot.value;if(dr(ot)&&(bt=Y(function(){C?jt.emit("unhandledRejection",Mt,Ht):cr(lr,Ht,Mt)}),ot.rejection=C||dr(ot)?2:1,bt.error))throw bt.value})},dr=function(ot){return ot.rejection!==1&&!ot.parent},Le=function(ot){T(U,S,function(){var bt=ot.facade;C?jt.emit("rejectionHandled",bt):cr("rejectionhandled",bt,ot.value)})},We=function(ot,bt,Ht){return function(Mt){ot(bt,Mt,Ht)}},Ce=function(ot,bt,Ht){ot.done||(ot.done=!0,Ht&&(ot=Ht),ot.value=bt,ot.state=2,ge(ot,!0))},pr=function(ot,bt,Ht){if(!ot.done){ot.done=!0,Ht&&(ot=Ht);try{if(ot.facade===bt)throw fe("Promise can't be resolved itself");var Mt=de(bt);Mt?H(function(){var Qt={done:!1};try{T(Mt,bt,We(pr,Qt,ot),We(Ce,Qt,ot))}catch(Ze){Ce(Qt,Ze,ot)}}):(ot.value=bt,ot.state=1,ge(ot,!1))}catch(Qt){Ce({done:!1},Qt,ot)}}};if(Et&&(Kt=(Ut=function(ot){F(this,Kt),M(ot),T(v,this);var bt=lt(this);try{ot(We(pr,bt),We(Ce,bt))}catch(Ht){Ce(bt,Ht)}}).prototype,(v=function(ot){wt(this,{type:ct,done:!1,notified:!1,parent:!1,reactions:new K,rejection:!1,state:0,value:void 0})}).prototype=A(Kt,"then",function(ot,bt){var Ht=lt(this),Mt=Bt(N(this,Ut));return Ht.parent=!0,Mt.ok=!B(ot)||ot,Mt.fail=B(bt)&&bt,Mt.domain=C?jt.domain:void 0,Ht.state==0?Ht.reactions.add(Mt):H(function(){Ne(Mt,Ht)}),Mt.promise}),g=function(){var ot=new v,bt=lt(ot);this.promise=ot,this.resolve=We(pr,bt),this.reject=We(Ce,bt)},yt.f=Bt=function(ot){return ot===Ut||ot===void 0?new g(ot):qt(ot)},!O&&B(it)&&_t!==Object.prototype)){w=_t.then,Vt||A(_t,"then",function(ot,bt){var Ht=this;return new Ut(function(Mt,Qt){T(w,Ht,Mt,Qt)}).then(ot,bt)},{unsafe:!0});try{delete _t.constructor}catch{}R&&R(_t,Kt)}k({global:!0,constructor:!0,wrap:!0,forced:Et},{Promise:Ut}),I(Ut,ct,!1,!0),$(ct)},8674:(y,j,r)=>{r(3401),r(821),r(4164),r(6027),r(683),r(6294)},6027:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(9662),k=r(8523),O=r(2534),C=r(408);v({target:"Promise",stat:!0,forced:r(612)},{race:function(S){var T=this,A=k.f(T),R=A.reject,I=O(function(){var $=w(T.resolve);C(S,function(M){g($,T,M).then(A.resolve,R)})});return I.error&&R(I.value),A.promise}})},683:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(8523);v({target:"Promise",stat:!0,forced:r(3702).CONSTRUCTOR},{reject:function(k){var O=w.f(this);return g(O.reject,void 0,k),O.promise}})},6294:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(1913),k=r(2492),O=r(3702).CONSTRUCTOR,C=r(9478),S=g("Promise"),T=w&&!O;v({target:"Promise",stat:!0,forced:w||O},{resolve:function(A){return C(T&&this===S?k:this,A)}})},2419:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(2104),k=r(7065),O=r(9483),C=r(9670),S=r(111),T=r(30),A=r(7293),R=g("Reflect","construct"),I=Object.prototype,$=[].push,M=A(function(){function F(){}return!(R(function(){},[],F)instanceof F)}),B=!A(function(){R(function(){})}),q=M||B;v({target:"Reflect",stat:!0,forced:q,sham:q},{construct:function(F,N){O(F),C(N);var U=arguments.length<3?F:O(arguments[2]);if(B&&!M)return R(F,N,U);if(F==U){switch(N.length){case 0:return new F;case 1:return new F(N[0]);case 2:return new F(N[0],N[1]);case 3:return new F(N[0],N[1],N[2]);case 4:return new F(N[0],N[1],N[2],N[3])}var H=[null];return w($,H,N),new(w(k,F,H))}var X=U.prototype,Y=T(S(X)?X:I),K=w(F,Y,N);return S(K)?K:Y}})},4819:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(111),k=r(9670),O=r(5032),C=r(1236),S=r(9518);v({target:"Reflect",stat:!0},{get:function T(A,R){var I,$,M=arguments.length<3?A:arguments[2];return k(A)===M?A[R]:(I=C.f(A,R))?O(I)?I.value:I.get===void 0?void 0:g(I.get,M):w($=S(A))?T($,R,M):void 0}})},4603:(y,j,r)=>{var v=r(9781),g=r(7854),w=r(1702),k=r(4705),O=r(9587),C=r(8880),S=r(8006).f,T=r(7976),A=r(7850),R=r(1340),I=r(4706),$=r(2999),M=r(2626),B=r(8052),q=r(7293),F=r(2597),N=r(9909).enforce,U=r(6340),H=r(5112),X=r(9441),Y=r(7168),K=H("match"),tt=g.RegExp,it=tt.prototype,st=g.SyntaxError,yt=w(it.exec),ct=w("".charAt),Et=w("".replace),At=w("".indexOf),Vt=w("".slice),lt=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,wt=/a/g,_t=/a/g,Ut=new tt(wt)!==wt,Kt=$.MISSED_STICKY,fe=$.UNSUPPORTED_Y;if(k("RegExp",v&&(!Ut||Kt||X||Y||q(function(){return _t[K]=!1,tt(wt)!=wt||tt(_t)==_t||tt(wt,"i")!="/a/i"})))){for(var St=function(qt,xt){var lr,de,Ne,ge,cr,Ae,dr=T(it,this),Le=A(qt),We=xt===void 0,Ce=[],pr=qt;if(!dr&&Le&&We&&qt.constructor===St)return qt;if((Le||T(it,qt))&&(qt=qt.source,We&&(xt=I(pr))),qt=qt===void 0?"":R(qt),xt=xt===void 0?"":R(xt),pr=qt,X&&"dotAll"in wt&&(de=!!xt&&At(xt,"s")>-1)&&(xt=Et(xt,/s/g,"")),lr=xt,Kt&&"sticky"in wt&&(Ne=!!xt&&At(xt,"y")>-1)&&fe&&(xt=Et(xt,/y/g,"")),Y&&(ge=function(ot){for(var bt,Ht=ot.length,Mt=0,Qt="",Ze=[],Ke={},xr=!1,Qe=!1,fr=0,Se="";Mt<=Ht;Mt++){if((bt=ct(ot,Mt))==="\\")bt+=ct(ot,++Mt);else if(bt==="]")xr=!1;else if(!xr)switch(!0){case bt==="[":xr=!0;break;case bt==="(":yt(lt,Vt(ot,Mt+1))&&(Mt+=2,Qe=!0),Qt+=bt,fr++;continue;case(bt===">"&&Qe):if(Se===""||F(Ke,Se))throw new st("Invalid capture group name");Ke[Se]=!0,Ze[Ze.length]=[Se,fr],Qe=!1,Se="";continue}Qe?Se+=bt:Qt+=bt}return[Qt,Ze]}(qt),qt=ge[0],Ce=ge[1]),cr=O(tt(qt,xt),dr?this:it,St),(de||Ne||Ce.length)&&(Ae=N(cr),de&&(Ae.dotAll=!0,Ae.raw=St(function(ot){for(var bt,Ht=ot.length,Mt=0,Qt="",Ze=!1;Mt<=Ht;Mt++)(bt=ct(ot,Mt))!=="\\"?Ze||bt!=="."?(bt==="["?Ze=!0:bt==="]"&&(Ze=!1),Qt+=bt):Qt+="[\\s\\S]":Qt+=bt+ct(ot,++Mt);return Qt}(qt),lr)),Ne&&(Ae.sticky=!0),Ce.length&&(Ae.groups=Ce)),qt!==pr)try{C(cr,"source",pr===""?"(?:)":pr)}catch{}return cr},jt=S(tt),Bt=0;jt.length>Bt;)M(St,tt,jt[Bt++]);it.constructor=St,St.prototype=it,B(g,"RegExp",St,{constructor:!0})}U("RegExp")},4916:(y,j,r)=>{var v=r(2109),g=r(2261);v({target:"RegExp",proto:!0,forced:/./.exec!==g},{exec:g})},9714:(y,j,r)=>{var v=r(6530).PROPER,g=r(8052),w=r(9670),k=r(1340),O=r(7293),C=r(4706),S="toString",T=RegExp.prototype[S],A=O(function(){return T.call({source:"a",flags:"b"})!="/a/b"}),R=v&&T.name!=S;(A||R)&&g(RegExp.prototype,S,function(){var I=w(this);return"/"+k(I.source)+"/"+k(C(I))},{unsafe:!0})},2023:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(3929),k=r(4488),O=r(1340),C=r(4964),S=g("".indexOf);v({target:"String",proto:!0,forced:!C("includes")},{includes:function(T){return!!~S(O(k(this)),O(w(T)),arguments.length>1?arguments[1]:void 0)}})},8783:(y,j,r)=>{var v=r(8710).charAt,g=r(1340),w=r(9909),k=r(1656),O=r(6178),C="String Iterator",S=w.set,T=w.getterFor(C);k(String,"String",function(A){S(this,{type:C,string:g(A),index:0})},function(){var A,R=T(this),I=R.string,$=R.index;return $>=I.length?O(void 0,!0):(A=v(I,$),R.index+=A.length,O(A,!1))})},4723:(y,j,r)=>{var v=r(6916),g=r(7007),w=r(9670),k=r(8554),O=r(7466),C=r(1340),S=r(4488),T=r(8173),A=r(1530),R=r(7651);g("match",function(I,$,M){return[function(B){var q=S(this),F=k(B)?void 0:T(B,I);return F?v(F,B,q):new RegExp(B)[I](C(q))},function(B){var q=w(this),F=C(B),N=M($,q,F);if(N.done)return N.value;if(!q.global)return R(q,F);var U=q.unicode;q.lastIndex=0;for(var H,X=[],Y=0;(H=R(q,F))!==null;){var K=C(H[0]);X[Y]=K,K===""&&(q.lastIndex=A(F,O(q.lastIndex),U)),Y++}return Y===0?null:X}]})},5306:(y,j,r)=>{var v=r(2104),g=r(6916),w=r(1702),k=r(7007),O=r(7293),C=r(9670),S=r(614),T=r(8554),A=r(9303),R=r(7466),I=r(1340),$=r(4488),M=r(1530),B=r(8173),q=r(647),F=r(7651),N=r(5112)("replace"),U=Math.max,H=Math.min,X=w([].concat),Y=w([].push),K=w("".indexOf),tt=w("".slice),it="a".replace(/./,"$0")==="$0",st=!!/./[N]&&/./[N]("a","$0")==="";k("replace",function(yt,ct,Et){var At=st?"$":"$0";return[function(Vt,lt){var wt=$(this),_t=T(Vt)?void 0:B(Vt,N);return _t?g(_t,Vt,wt,lt):g(ct,I(wt),Vt,lt)},function(Vt,lt){var wt=C(this),_t=I(Vt);if(typeof lt=="string"&&K(lt,At)===-1&&K(lt,"$<")===-1){var Ut=Et(ct,wt,_t,lt);if(Ut.done)return Ut.value}var Kt=S(lt);Kt||(lt=I(lt));var fe=wt.global;if(fe){var St=wt.unicode;wt.lastIndex=0}for(var jt=[];;){var Bt=F(wt,_t);if(Bt===null||(Y(jt,Bt),!fe))break;I(Bt[0])===""&&(wt.lastIndex=M(_t,R(wt.lastIndex),St))}for(var qt,xt="",lr=0,de=0;de<jt.length;de++){for(var Ne=I((Bt=jt[de])[0]),ge=U(H(A(Bt.index),_t.length),0),cr=[],Ae=1;Ae<Bt.length;Ae++)Y(cr,(qt=Bt[Ae])===void 0?qt:String(qt));var dr=Bt.groups;if(Kt){var Le=X([Ne],cr,ge,_t);dr!==void 0&&Y(Le,dr);var We=I(v(lt,void 0,Le))}else We=q(Ne,_t,ge,cr,dr,lt);ge>=lr&&(xt+=tt(_t,lr,ge)+We,lr=ge+Ne.length)}return xt+tt(_t,lr)}]},!!O(function(){var yt=/./;return yt.exec=function(){var ct=[];return ct.groups={a:"7"},ct},"".replace(yt,"$<a>")!=="7"})||!it||st)},6755:(y,j,r)=>{var v,g=r(2109),w=r(1470),k=r(1236).f,O=r(7466),C=r(1340),S=r(3929),T=r(4488),A=r(4964),R=r(1913),I=w("".startsWith),$=w("".slice),M=Math.min,B=A("startsWith");g({target:"String",proto:!0,forced:!(!R&&!B&&(v=k(String.prototype,"startsWith"),v&&!v.writable)||B)},{startsWith:function(q){var F=C(T(this));S(q);var N=O(M(arguments.length>1?arguments[1]:void 0,F.length)),U=C(q);return I?I(F,U,N):$(F,N,N+U.length)===U}})},3210:(y,j,r)=>{var v=r(2109),g=r(3111).trim;v({target:"String",proto:!0,forced:r(6091)("trim")},{trim:function(){return g(this)}})},2443:(y,j,r)=>{r(6800)("asyncIterator")},4032:(y,j,r)=>{var v=r(2109),g=r(7854),w=r(6916),k=r(1702),O=r(1913),C=r(9781),S=r(6293),T=r(7293),A=r(2597),R=r(7976),I=r(9670),$=r(5656),M=r(4948),B=r(1340),q=r(9114),F=r(30),N=r(1956),U=r(8006),H=r(1156),X=r(5181),Y=r(1236),K=r(3070),tt=r(6048),it=r(5296),st=r(8052),yt=r(7045),ct=r(2309),Et=r(6200),At=r(3501),Vt=r(9711),lt=r(5112),wt=r(6061),_t=r(6800),Ut=r(6532),Kt=r(8003),fe=r(9909),St=r(2092).forEach,jt=Et("hidden"),Bt="Symbol",qt="prototype",xt=fe.set,lr=fe.getterFor(Bt),de=Object[qt],Ne=g.Symbol,ge=Ne&&Ne[qt],cr=g.TypeError,Ae=g.QObject,dr=Y.f,Le=K.f,We=H.f,Ce=it.f,pr=k([].push),ot=ct("symbols"),bt=ct("op-symbols"),Ht=ct("wks"),Mt=!Ae||!Ae[qt]||!Ae[qt].findChild,Qt=C&&T(function(){return F(Le({},"a",{get:function(){return Le(this,"a",{value:7}).a}})).a!=7})?function(Nt,te,Xt){var ce=dr(de,te);ce&&delete de[te],Le(Nt,te,Xt),ce&&Nt!==de&&Le(de,te,ce)}:Le,Ze=function(Nt,te){var Xt=ot[Nt]=F(ge);return xt(Xt,{type:Bt,tag:Nt,description:te}),C||(Xt.description=te),Xt},Ke=function(Nt,te,Xt){Nt===de&&Ke(bt,te,Xt),I(Nt);var ce=M(te);return I(Xt),A(ot,ce)?(Xt.enumerable?(A(Nt,jt)&&Nt[jt][ce]&&(Nt[jt][ce]=!1),Xt=F(Xt,{enumerable:q(0,!1)})):(A(Nt,jt)||Le(Nt,jt,q(1,{})),Nt[jt][ce]=!0),Qt(Nt,ce,Xt)):Le(Nt,ce,Xt)},xr=function(Nt,te){I(Nt);var Xt=$(te),ce=N(Xt).concat(Dn(Xt));return St(ce,function(ze){C&&!w(Qe,Xt,ze)||Ke(Nt,ze,Xt[ze])}),Nt},Qe=function(Nt){var te=M(Nt),Xt=w(Ce,this,te);return!(this===de&&A(ot,te)&&!A(bt,te))&&(!(Xt||!A(this,te)||!A(ot,te)||A(this,jt)&&this[jt][te])||Xt)},fr=function(Nt,te){var Xt=$(Nt),ce=M(te);if(Xt!==de||!A(ot,ce)||A(bt,ce)){var ze=dr(Xt,ce);return!ze||!A(ot,ce)||A(Xt,jt)&&Xt[jt][ce]||(ze.enumerable=!0),ze}},Se=function(Nt){var te=We($(Nt)),Xt=[];return St(te,function(ce){A(ot,ce)||A(At,ce)||pr(Xt,ce)}),Xt},Dn=function(Nt){var te=Nt===de,Xt=We(te?bt:$(Nt)),ce=[];return St(Xt,function(ze){!A(ot,ze)||te&&!A(de,ze)||pr(ce,ot[ze])}),ce};S||(st(ge=(Ne=function(){if(R(ge,this))throw cr("Symbol is not a constructor");var Nt=arguments.length&&arguments[0]!==void 0?B(arguments[0]):void 0,te=Vt(Nt),Xt=function(ce){this===de&&w(Xt,bt,ce),A(this,jt)&&A(this[jt],te)&&(this[jt][te]=!1),Qt(this,te,q(1,ce))};return C&&Mt&&Qt(de,te,{configurable:!0,set:Xt}),Ze(te,Nt)})[qt],"toString",function(){return lr(this).tag}),st(Ne,"withoutSetter",function(Nt){return Ze(Vt(Nt),Nt)}),it.f=Qe,K.f=Ke,tt.f=xr,Y.f=fr,U.f=H.f=Se,X.f=Dn,wt.f=function(Nt){return Ze(lt(Nt),Nt)},C&&(yt(ge,"description",{configurable:!0,get:function(){return lr(this).description}}),O||st(de,"propertyIsEnumerable",Qe,{unsafe:!0}))),v({global:!0,constructor:!0,wrap:!0,forced:!S,sham:!S},{Symbol:Ne}),St(N(Ht),function(Nt){_t(Nt)}),v({target:Bt,stat:!0,forced:!S},{useSetter:function(){Mt=!0},useSimple:function(){Mt=!1}}),v({target:"Object",stat:!0,forced:!S,sham:!C},{create:function(Nt,te){return te===void 0?F(Nt):xr(F(Nt),te)},defineProperty:Ke,defineProperties:xr,getOwnPropertyDescriptor:fr}),v({target:"Object",stat:!0,forced:!S},{getOwnPropertyNames:Se}),Ut(),Kt(Ne,Bt),At[jt]=!0},1817:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(7854),k=r(1702),O=r(2597),C=r(614),S=r(7976),T=r(1340),A=r(7045),R=r(9920),I=w.Symbol,$=I&&I.prototype;if(g&&C(I)&&(!("description"in $)||I().description!==void 0)){var M={},B=function(){var Y=arguments.length<1||arguments[0]===void 0?void 0:T(arguments[0]),K=S($,this)?new I(Y):Y===void 0?I():I(Y);return Y===""&&(M[K]=!0),K};R(B,I),B.prototype=$,$.constructor=B;var q=String(I("test"))=="Symbol(test)",F=k($.valueOf),N=k($.toString),U=/^Symbol\((.*)\)[^)]+$/,H=k("".replace),X=k("".slice);A($,"description",{configurable:!0,get:function(){var Y=F(this);if(O(M,Y))return"";var K=N(Y),tt=q?X(K,7,-1):H(K,U,"$1");return tt===""?void 0:tt}}),v({global:!0,constructor:!0,forced:!0},{Symbol:B})}},763:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(2597),k=r(1340),O=r(2309),C=r(2015),S=O("string-to-symbol-registry"),T=O("symbol-to-string-registry");v({target:"Symbol",stat:!0,forced:!C},{for:function(A){var R=k(A);if(w(S,R))return S[R];var I=g("Symbol")(R);return S[R]=I,T[I]=R,I}})},2165:(y,j,r)=>{r(6800)("iterator")},2526:(y,j,r)=>{r(4032),r(763),r(6620),r(8862),r(9660)},6620:(y,j,r)=>{var v=r(2109),g=r(2597),w=r(2190),k=r(6330),O=r(2309),C=r(2015),S=O("symbol-to-string-registry");v({target:"Symbol",stat:!0,forced:!C},{keyFor:function(T){if(!w(T))throw TypeError(k(T)+" is not a symbol");if(g(S,T))return S[T]}})},6649:(y,j,r)=>{var v=r(6800),g=r(6532);v("toPrimitive"),g()},3680:(y,j,r)=>{var v=r(5005),g=r(6800),w=r(8003);g("toStringTag"),w(v("Symbol"),"Symbol")},4747:(y,j,r)=>{var v=r(7854),g=r(8324),w=r(8509),k=r(8533),O=r(8880),C=function(T){if(T&&T.forEach!==k)try{O(T,"forEach",k)}catch{T.forEach=k}};for(var S in g)g[S]&&C(v[S]&&v[S].prototype);C(w)},3948:(y,j,r)=>{var v=r(7854),g=r(8324),w=r(8509),k=r(6992),O=r(8880),C=r(5112),S=C("iterator"),T=C("toStringTag"),A=k.values,R=function($,M){if($){if($[S]!==A)try{O($,S,A)}catch{$[S]=A}if($[T]||O($,T,M),g[M]){for(var B in k)if($[B]!==k[B])try{O($,B,k[B])}catch{$[B]=k[B]}}}};for(var I in g)R(v[I]&&v[I].prototype,I);R(w,"DOMTokenList")},6815:(y,j,r)=>{var v=r(2109),g=r(7854),w=r(7152)(g.setInterval,!0);v({global:!0,bind:!0,forced:g.setInterval!==w},{setInterval:w})},8417:(y,j,r)=>{var v=r(2109),g=r(7854),w=r(7152)(g.setTimeout,!0);v({global:!0,bind:!0,forced:g.setTimeout!==w},{setTimeout:w})},2564:(y,j,r)=>{r(6815),r(8417)}},b={};function _(y){var j=b[y];if(j!==void 0)return j.exports;var r=b[y]={exports:{}};return p[y](r,r.exports,_),r.exports}_.d=(y,j)=>{for(var r in j)_.o(j,r)&&!_.o(y,r)&&Object.defineProperty(y,r,{enumerable:!0,get:j[r]})},_.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch{if(typeof window=="object")return window}}(),_.o=(y,j)=>Object.prototype.hasOwnProperty.call(y,j),_.r=y=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(y,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(y,"__esModule",{value:!0})};var E={};return(()=>{_.r(E),_.d(E,{JSONEditor:()=>Tn}),_(3710),_(1539),_(9714),_(5827),_(6833),_(9826),_(9554),_(4747),_(7941),_(2222),_(9601),_(6649),_(6078),_(2526),_(1817),_(9653),_(9070),_(8674),_(2165),_(6992),_(8783),_(3948),_(2443),_(3680),_(3706),_(2703),_(8011),_(489),_(8309),_(8304),_(5069),_(7042),_(9753),_(1038),_(4916),_(9720),_(5306),_(4603),_(6699);var y=["actionscript","batchfile","c","c++","cpp","coffee","csharp","css","dart","django","ejs","erlang","golang","groovy","handlebars","haskell","haxe","html","ini","jade","java","javascript","json","less","lisp","lua","makefile","matlab","mysql","objectivec","pascal","perl","pgsql","php","python","prql","r","ruby","rust","sass","scala","scss","sh","smarty","sql","sqlserver","stylus","svg","typescript","twig","vbscript","xml","yaml","zig"],j=[function(c){return c.type==="string"&&c.format==="color"&&"colorpicker"},function(c){return c.type==="string"&&["ip","ipv4","ipv6","hostname"].includes(c.format)&&"ip"},function(c){return c.type==="string"&&y.includes(c.format)&&"ace"},function(c){return c.type==="string"&&["xhtml","bbcode"].includes(c.format)&&"sceditor"},function(c){return c.type==="string"&&c.format==="markdown"&&"simplemde"},function(c){return c.type==="string"&&c.format==="jodit"&&"jodit"},function(c){return c.type==="string"&&c.format==="autocomplete"&&"autocomplete"},function(c){return c.type==="string"&&c.format==="uuid"&&"uuid"},function(c){return c.format==="info"&&"info"},function(c){return c.format==="button"&&"button"},function(c){if((c.type==="integer"||c.type==="number")&&c.format==="stepper")return"stepper"},function(c){if(c.links){for(var n=0;n<c.links.length;n++)if(c.links[n].rel&&c.links[n].rel.toLowerCase()==="describedby")return"describedBy"}},function(c){return["string","integer"].includes(c.type)&&["starrating","rating"].includes(c.format)&&"starrating"},function(c){return["string","integer"].includes(c.type)&&["date","time","datetime-local"].includes(c.format)&&"datetime"},function(c){return(c.oneOf||c.anyOf)&&"multiple"},function(c){return c.if&&"multiple"},function(c,n){if(c.items&&(c.items=n.expandSchema(c.items)),c.type==="array"&&c.items&&!Array.isArray(c.items)&&["string","number","integer"].includes(c.items.type)){if(c.format==="choices")return"arrayChoices";if(c.uniqueItems){if(c.format==="selectize")return"arraySelectize";if(c.format==="select2")return"arraySelect2";if(c.items.enum)return"multiselect"}}},function(c){if(c.enum){if(c.type==="array"||c.type==="object")return"enum";if(c.type==="number"||c.type==="integer"||c.type==="string")return c.format==="radio"?"radio":c.format==="select2"?"select2":c.format==="selectize"?"selectize":c.format==="choices"?"choices":"select"}},function(c){if(c.enumSource)return c.format==="radio"?"radio":c.format==="select2"?"select2":c.format==="selectize"?"selectize":c.format==="choices"?"choices":"select"},function(c){return c.type==="array"&&c.format==="table"&&"table"},function(c){return c.type==="string"&&c.format==="url"&&window.FileReader&&c.options&&c.options.upload===Object(c.options.upload)&&"upload"},function(c){return c.type==="string"&&c.media&&c.media.binaryEncoding==="base64"&&"base64"},function(c){return c.type==="any"&&"multiple"},function(c){if(c.type==="boolean")return c.format==="checkbox"||c.options&&c.options.checkbox?"checkbox":c.format==="select2"?"select2":c.format==="selectize"?"selectize":c.format==="choices"?"choices":"select"},function(c){return c.type==="string"&&c.format==="signature"&&"signature"},function(c){return typeof c.type=="string"&&["string","number","integer","boolean","null","array","object"].includes(c.type)&&c.type},function(c){return!c.type&&c.properties&&"object"},function(c){return typeof c.type!="string"&&"multiple"},function(c){return typeof c.type=="string"&&"string"}];function r(c,n,f){return(n=function(i){var h=function(a,l){if(v(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(v(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i);return v(h)==="symbol"?h:String(h)}(n))in c?Object.defineProperty(c,n,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[n]=f,c}function v(c){return v=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},v(c)}function g(c){return!(c===null||v(c)!=="object"||c.nodeType||c===c.window||c.constructor&&!S(c.constructor.prototype,"isPrototypeOf"))}function w(c){return g(c)?k({},c):Array.isArray(c)?c.map(w):c}function k(c){for(var n=arguments.length,f=new Array(n>1?n-1:0),i=1;i<n;i++)f[i-1]=arguments[i];return f.forEach(function(h){h&&Object.keys(h).forEach(function(a){h[a]&&g(h[a])?(S(c,a)||(c[a]={}),k(c[a],h[a])):Array.isArray(h[a])?c[a]=w(h[a]):c[a]=h[a]})}),c}function O(c,n){var f=document.createEvent("HTMLEvents");f.initEvent(n,!0,!0),c.dispatchEvent(f)}function C(c){return c&&(c.toString()==="[object ShadowRoot]"?c:C(c.parentNode))}function S(c,n){return c&&Object.prototype.hasOwnProperty.call(c,n)}_(4812),_(2419),_(4819),_(5003),_(4723),_(2023),_(9600),_(6755),_(5212),_(2772),_(1249),_(4678),_(1058);var T=/^\s*(-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,A=/^\s*(-|\+)?(\d+)\s*$/;function R(){var c=new Date().getTime();return typeof performance<"u"&&typeof performance.now=="function"&&(c+=performance.now()),"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(n){var f=(c+16*Math.random())%16|0;return c=Math.floor(c/16),(n==="x"?f:3&f|8).toString(16)})}function I(c){return c&&v(c)==="object"&&!Array.isArray(c)}function $(c){for(var n=arguments.length,f=new Array(n>1?n-1:0),i=1;i<n;i++)f[i-1]=arguments[i];if(!f.length)return c;var h=f.shift();if(I(c)&&I(h))for(var a in h)I(h[a])?(c[a]||Object.assign(c,r({},a,{})),$(c[a],h[a])):Object.assign(c,r({},a,h[a]));return $.apply(void 0,[c].concat(f))}function M(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function B(c){return B=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},B(c)}function q(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(B(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(B(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),B(h)==="symbol"?h:String(h)),i)}var h}var F=function(){function c(i,h){(function(a,l){if(!(a instanceof l))throw new TypeError("Cannot call a class as a function")})(this,c),this.defaults=h,this.jsoneditor=i.jsoneditor,this.theme=this.jsoneditor.theme,this.template_engine=this.jsoneditor.template,this.iconlib=this.jsoneditor.iconlib,this.translate=this.jsoneditor.translate||this.defaults.translate,this.translateProperty=this.jsoneditor.translateProperty||this.defaults.translateProperty,this.original_schema=i.schema,this.schema=this.jsoneditor.expandSchema(this.original_schema),this.active=!0,this.options=k({},this.options||{},this.schema.options||{},i.schema.options||{},i),this.formname=this.jsoneditor.options.form_name_root||"root",i.path||this.schema.id||(this.schema.id=this.formname),this.path=i.path||this.formname,this.formname=i.formname||this.path.replace(/\.([^.]+)/g,"[$1]"),this.parent=i.parent,this.key=this.parent!==void 0?this.path.split(".").slice(this.parent.path.split(".").length).join("."):this.path,this.link_watchers=[],this.watchLoop=!1,i.container&&this.setContainer(i.container),this.registerDependencies()}var n,f;return n=c,f=[{key:"onChildEditorChange",value:function(i){this.onChange(!0)}},{key:"notify",value:function(){this.path&&this.jsoneditor.notifyWatchers(this.path)}},{key:"change",value:function(){this.parent?this.parent.onChildEditorChange(this):this.jsoneditor&&this.jsoneditor.onChange()}},{key:"onChange",value:function(i){this.notify(),this.watch_listener&&this.watch_listener(),i&&this.change()}},{key:"register",value:function(){this.jsoneditor.registerEditor(this),this.onChange()}},{key:"unregister",value:function(){this.jsoneditor&&this.jsoneditor.unregisterEditor(this)}},{key:"getNumColumns",value:function(){return 12}},{key:"isActive",value:function(){return this.active}},{key:"activate",value:function(){this.active=!0,this.optInCheckbox.checked=!0,this.enable(),this.change()}},{key:"deactivate",value:function(){this.isRequired()||(this.active=!1,this.optInCheckbox.checked=!1,this.disable(),this.change())}},{key:"registerDependencies",value:function(){var i=this;this.dependenciesFulfilled=!0;var h=this.options.dependencies;h&&Object.keys(h).forEach(function(a){var l;a.startsWith(i.jsoneditor.root.path)?l=a:((l=i.path.split("."))[l.length-1]=a,l=l.join(".")),i.jsoneditor.watch(l,function(){i.evaluateDependencies()})})}},{key:"evaluateDependencies",value:function(){var i=this,h=this.container||this.control;if(h&&this.jsoneditor!==null){var a=this.options.dependencies;if(a){var l=this.dependenciesFulfilled;this.dependenciesFulfilled=!0,Object.keys(a).forEach(function(e){var o;e.startsWith(i.jsoneditor.root.path)?o=e:((o=i.path.split("."))[o.length-1]=e,o=o.join("."));var u=a[e];i.checkDependency(o,u)}),this.dependenciesFulfilled!==l&&this.notify();var t=this.dependenciesFulfilled?"block":"none";this.options.hidden&&(t="none"),h.tagName==="TD"?Object.keys(h.childNodes).forEach(function(e){return h.childNodes[e].style.display=t}):h.style.display=t}}}},{key:"checkDependency",value:function(i,h){var a=this;if(this.path!==i&&this.jsoneditor!==null){var l=this.jsoneditor.getEditor(i),t=l?l.getValue():void 0;l&&l.dependenciesFulfilled?Array.isArray(h)?this.dependenciesFulfilled=h.some(function(e){if(JSON.stringify(t)===JSON.stringify(e))return!0}):B(h)==="object"?B(t)!=="object"?this.dependenciesFulfilled=h===t:Object.keys(h).some(function(e){return!!S(h,e)&&(S(t,e)&&h[e]===t[e]?void 0:(a.dependenciesFulfilled=!1,!0))}):typeof h=="string"||typeof h=="number"?this.dependenciesFulfilled=this.dependenciesFulfilled&&t===h:typeof h=="boolean"&&(this.dependenciesFulfilled=h?this.dependenciesFulfilled&&(t||t.length>0):this.dependenciesFulfilled&&(!t||t.length===0)):this.dependenciesFulfilled=!1}}},{key:"setContainer",value:function(i){this.container=i,this.setContainerAttributes(),this.schema.id&&this.container.setAttribute("data-schemaid",this.schema.id),this.schema.type&&typeof this.schema.type=="string"&&this.container.setAttribute("data-schematype",this.schema.type),this.container.setAttribute("data-schemapath",this.path)}},{key:"setOptInCheckbox",value:function(i){var h=this;this.optInCheckbox=document.createElement("input"),this.optInCheckbox.setAttribute("type","checkbox"),this.optInCheckbox.setAttribute("style","margin: 0 10px 0 0;"),this.optInCheckbox.classList.add("json-editor-opt-in"),this.optInCheckbox.addEventListener("click",function(){h.isActive()?h.deactivate():h.activate()});var a=this.jsoneditor.options.show_opt_in,l=this.parent.options.show_opt_in!==void 0,t=l&&this.parent.options.show_opt_in===!0,e=l&&this.parent.options.show_opt_in===!1;(t||!e&&a||!l&&a)&&this.parent&&this.parent.schema.type==="object"&&!this.isRequired()&&this.header&&(this.header.appendChild(this.optInCheckbox),this.header.insertBefore(this.optInCheckbox,this.header.firstChild))}},{key:"preBuild",value:function(){}},{key:"build",value:function(){}},{key:"postBuild",value:function(){this.setupWatchListeners(),this.addLinks(),this.register(),this.setValue(this.getDefault(),!0),this.updateHeaderText(),this.onWatchedFieldChange()}},{key:"setupWatchListeners",value:function(){var i=this;if(this.watched={},this.schema.vars&&(this.schema.watch=this.schema.vars),this.watched_values={},this.watch_listener=function(){i.refreshWatchedFieldValues()&&i.onWatchedFieldChange()},S(this.schema,"watch")){var h,a,l,t,e,o=this.container.getAttribute("data-schemapath");Object.keys(this.schema.watch).forEach(function(u){if(h=i.schema.watch[u],Array.isArray(h)){if(h.length<2)return;a=[h[0]].concat(h[1].split("."))}else a=h.split("."),i.theme.closest(i.container,'[data-schemaid="'.concat(a[0],'"]'))||a.unshift("#");if((l=a.shift())==="#"&&(l=i.jsoneditor.schema.id||i.jsoneditor.root.formname),!(t=i.theme.closest(i.container,'[data-schemaid="'.concat(l,'"]'))))throw new Error("Could not find ancestor node with id ".concat(l));e="".concat(t.getAttribute("data-schemapath"),".").concat(a.join(".")),o.startsWith(e)&&(i.watchLoop=!0),i.jsoneditor.watch(e,i.watch_listener),i.watched[u]=e})}this.schema.headerTemplate&&(this.header_template=this.jsoneditor.compileTemplate(this.schema.headerTemplate,this.template_engine))}},{key:"addLinks",value:function(){if(!this.no_link_holder&&(this.link_holder=this.theme.getLinksHolder(),this.description!==void 0?this.description.parentNode.insertBefore(this.link_holder,this.description):this.container.appendChild(this.link_holder),this.schema.links))for(var i=0;i<this.schema.links.length;i++)this.addLink(this.getLink(this.schema.links[i]))}},{key:"onMove",value:function(){}},{key:"getButton",value:function(i,h,a){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[],t="json-editor-btn-".concat(h);h=this.iconlib?this.iconlib.getIcon(h):null,i=this.translate(i,l),a=this.translate(a,l),!h&&a&&(i=a,a=null);var e=this.theme.getButton(i,h,a);return e.classList.add(t),e}},{key:"setButtonText",value:function(i,h,a,l){var t=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[];return a=this.iconlib?this.iconlib.getIcon(a):null,h=this.translate(h,t),l=this.translate(l,t),!a&&l&&(h=l,l=null),this.theme.setButtonText(i,h,a,l)}},{key:"addLink",value:function(i){this.link_holder&&this.link_holder.appendChild(i)}},{key:"getLink",value:function(i){var h,a,l=(i.mediaType||"application/javascript").split("/")[0],t=this.jsoneditor.compileTemplate(i.href,this.template_engine),e=this.jsoneditor.compileTemplate(i.rel?i.rel:i.href,this.template_engine),o=null;if(i.download&&(o=i.download),o&&o!==!0&&(o=this.jsoneditor.compileTemplate(o,this.template_engine)),l==="image"){h=this.theme.getBlockLinkHolder(),(a=document.createElement("a")).setAttribute("target","_blank");var u=document.createElement("img");this.theme.createImageLink(h,a,u),this.link_watchers.push(function(x){var P=t(x),D=e(x);a.setAttribute("href",P),a.setAttribute("title",D||P),u.setAttribute("src",P)})}else if(["audio","video"].includes(l)){h=this.theme.getBlockLinkHolder(),(a=this.theme.getBlockLink()).setAttribute("target","_blank");var d=document.createElement(l);d.setAttribute("controls","controls"),this.theme.createMediaLink(h,a,d),this.link_watchers.push(function(x){var P=t(x),D=e(x);a.setAttribute("href",P),a.textContent=D||P,d.setAttribute("src",P)})}else a=h=this.theme.getBlockLink(),h.setAttribute("target","_blank"),h.textContent=i.rel,h.style.display="none",this.link_watchers.push(function(x){var P=t(x),D=e(x);P&&(h.style.display=""),h.setAttribute("href",P),h.textContent=D||P});return o&&a&&(o===!0?a.setAttribute("download",""):this.link_watchers.push(function(x){a.setAttribute("download",o(x))})),i.class&&a.classList.add(i.class),h}},{key:"refreshWatchedFieldValues",value:function(){var i=this;if(this.watched_values){var h={},a=!1;return this.watched&&Object.keys(this.watched).forEach(function(l){var t=i.jsoneditor.getEditor(i.watched[l]),e=t?t.getValue():null;i.watched_values[l]!==e&&(a=!0),h[l]=e}),h.self=this.getValue(),this.watched_values.self!==h.self&&(a=!0),this.watched_values=h,a}}},{key:"getWatchedFieldValues",value:function(){return this.watched_values}},{key:"updateHeaderText",value:function(){if(this.header){var i=this.getHeaderText();if(this.header.children.length){for(var h=0;h<this.header.childNodes.length;h++)if(this.header.childNodes[h].nodeType===3){this.header.childNodes[h].nodeValue=this.cleanText(i);break}}else window.DOMPurify?this.header.innerHTML=window.DOMPurify.sanitize(i):this.header.textContent=this.cleanText(i)}}},{key:"getHeaderText",value:function(i){return this.header_text?this.header_text:i?this.translateProperty(this.schema.title):this.getTitle()}},{key:"getPathDepth",value:function(){return this.path.split(".").length}},{key:"cleanText",value:function(i){var h=document.createElement("div");return h.innerHTML=i,h.textContent||h.innerText}},{key:"onWatchedFieldChange",value:function(){var i,h=this;if(this.header_template){i=k(this.getWatchedFieldValues(),{key:this.key,i:this.key,i0:1*this.key,i1:1*this.key+1,title:this.getTitle()}),Object.keys(this.editors).length&&(i.properties={},Object.keys(this.editors).forEach(function(t){var e=h.editors[t];if(e.schema&&e.schema.enum&&e.schema.options&&e.schema.options.enum_titles){var o=e.schema.enum.indexOf(e.value),u=e.options.enum_titles[o];i.properties[t]={enumTitle:u}}}));var a=this.header_template(i);a!==this.header_text&&(this.header_text=a,this.updateHeaderText(),this.notify())}if(this.link_watchers.length){i=this.getWatchedFieldValues();for(var l=0;l<this.link_watchers.length;l++)this.link_watchers[l](i)}}},{key:"setValue",value:function(i){this.value=i}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.value}},{key:"refreshValue",value:function(){}},{key:"getChildEditors",value:function(){return!1}},{key:"destroy",value:function(){var i=this;this.unregister(this),this.watched&&Object.values(this.watched).forEach(function(h){return i.jsoneditor.unwatch(h,i.watch_listener)}),this.watched=null,this.watched_values=null,this.watch_listener=null,this.header_text=null,this.header_template=null,this.value=null,this.container&&this.container.parentNode&&this.container.parentNode.removeChild(this.container),this.container=null,this.jsoneditor=null,this.schema=null,this.path=null,this.key=null,this.parent=null}},{key:"isDefaultRequired",value:function(){return this.isRequired()||!!this.jsoneditor.options.use_default_values}},{key:"getDefault",value:function(){if(this.schema.default!==void 0)return this.schema.default;if(this.schema.enum!==void 0)return this.schema.enum[0];var i=this.schema.type||this.schema.oneOf;if(i&&Array.isArray(i)&&(i=i[0]),i&&B(i)==="object"&&(i=i.type),i&&Array.isArray(i)&&(i=i[0]),typeof i=="string"){if(i==="number")return this.isDefaultRequired()?0:void 0;if(i==="boolean")return!this.isDefaultRequired()&&void 0;if(i==="integer")return this.isDefaultRequired()?0:void 0;if(i==="string")return this.isDefaultRequired()?"":void 0;if(i==="null")return null;if(i==="object")return{};if(i==="array")return[]}}},{key:"getTitle",value:function(){return this.translateProperty(this.schema.title||this.key)}},{key:"enable",value:function(){this.disabled=!1}},{key:"disable",value:function(){this.disabled=!0}},{key:"isEnabled",value:function(){return!this.disabled}},{key:"isRequired",value:function(){return typeof this.schema.required=="boolean"?this.schema.required:this.parent&&this.parent.schema&&Array.isArray(this.parent.schema.required)?this.parent.schema.required.includes(this.key):!!this.jsoneditor.options.required_by_default}},{key:"getDisplayText",value:function(i){var h=[],a={};i.forEach(function(t){t.title&&(a[t.title]=a[t.title]||0,a[t.title]++),t.description&&(a[t.description]=a[t.description]||0,a[t.description]++),t.format&&(a[t.format]=a[t.format]||0,a[t.format]++),t.type&&(a[t.type]=a[t.type]||0,a[t.type]++)}),i.forEach(function(t){var e;e=typeof t=="string"?t:t.title&&a[t.title]<=1?t.title:t.format&&a[t.format]<=1?t.format:t.type&&a[t.type]<=1?t.type:t.description&&a[t.description]<=1?t.description:t.title?t.title:t.format?t.format:t.type?t.type:t.description?t.description:JSON.stringify(t).length<500?JSON.stringify(t):"type",h.push(e)});var l={};return h.forEach(function(t,e){l[t]=l[t]||0,l[t]++,a[t]>1&&(h[e]="".concat(t," ").concat(l[t]))}),h}},{key:"getValidId",value:function(i){return(i=i===void 0?"":i.toString()).replace(/\s+/g,"-")}},{key:"setInputAttributes",value:function(i){var h=this;if(this.schema.options&&this.schema.options.inputAttributes){var a=this.schema.options.inputAttributes,l=["name","type"].concat(i);Object.keys(a).forEach(function(t){l.includes(t.toLowerCase())||h.input.setAttribute(t,a[t])})}}},{key:"setContainerAttributes",value:function(){var i=this;if(this.schema.options&&this.schema.options.containerAttributes){var h=this.schema.options.containerAttributes,a=["data-schemapath","data-schematype","data-schemaid"];Object.keys(h).forEach(function(l){a.includes(l.toLowerCase())||i.container.setAttribute(l,h[l])})}}},{key:"expandCallbacks",value:function(i,h){var a=this,l=this.defaults.callbacks[i];return Object.entries(h).forEach(function(t){var e,o,u=(o=2,function(P){if(Array.isArray(P))return P}(e=t)||function(P,D){var J=P==null?null:typeof Symbol<"u"&&P[Symbol.iterator]||P["@@iterator"];if(J!=null){var nt,ut,dt,kt,Ct=[],$t=!0,ne=!1;try{if(dt=(J=J.call(P)).next,D===0){if(Object(J)!==J)return;$t=!1}else for(;!($t=(nt=dt.call(J)).done)&&(Ct.push(nt.value),Ct.length!==D);$t=!0);}catch(Re){ne=!0,ut=Re}finally{try{if(!$t&&J.return!=null&&(kt=J.return(),Object(kt)!==kt))return}finally{if(ne)throw ut}}return Ct}}(e,o)||function(P,D){if(P){if(typeof P=="string")return M(P,D);var J=Object.prototype.toString.call(P).slice(8,-1);return J==="Object"&&P.constructor&&(J=P.constructor.name),J==="Map"||J==="Set"?Array.from(P):J==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(J)?M(P,D):void 0}}(e,o)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
74
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()),d=u[0],x=u[1];x===Object(x)?h[d]=a.expandCallbacks(i,x):typeof x=="string"&&B(l)==="object"&&typeof l[x]=="function"&&(h[d]=l[x].bind(null,a))}),h}},{key:"showValidationErrors",value:function(i){}}],f&&q(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function N(c){return N=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},N(c)}function U(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(N(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(N(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),N(h)==="symbol"?h:String(h)),i)}var h}function H(){return H=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Y(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},H.apply(this,arguments)}function X(c,n){return X=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},X(c,n)}function Y(c){return Y=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Y(c)}var K=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&X(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Y(i);if(h){var o=Y(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(N(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){H(Y(l.prototype),"register",this).call(this),this.input&&(this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname),this.input.setAttribute("aria-label",this.formname))}},{key:"unregister",value:function(){H(Y(l.prototype),"unregister",this).call(this),this.input&&(this.input.removeAttribute("name"),this.input.removeAttribute("aria-label"))}},{key:"setValue",value:function(t,e,o){if((!this.template||o)&&(this.shouldBeUnset()||t!=null?N(t)==="object"?t=JSON.stringify(t):this.shouldBeUnset()||typeof t=="string"||(t="".concat(t)):t="",t!==this.serialized)){var u=this.sanitize(t);if(this.input.value!==u){if(this.setValueToInputField(u),this.format==="range"){var d=this.control.querySelector("output");d&&(d.value=u)}var x=o||this.getValue()!==t;return this.refreshValue(),e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.adjust_height&&this.adjust_height(this.input),this.onChange(x),{changed:x,value:u}}}}},{key:"setValueToInputField",value:function(t){this.input.value=t===void 0?"":t}},{key:"getNumColumns",value:function(){var t,e=Math.ceil(Math.max(this.getTitle().length,this.schema.maxLength||0,this.schema.minLength||0)/5);return t=this.input_type==="textarea"?6:["text","email"].includes(this.input_type)?4:2,Math.min(12,Math.max(e,t))}},{key:"build",value:function(){var t=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.format=this.schema.format,!this.format&&this.schema.media&&this.schema.media.type&&(this.format=this.schema.media.type.replace(/(^(application|text)\/(x-)?(script\.)?)|(-source$)/g,"")),!this.format&&this.options.default_format&&(this.format=this.options.default_format),this.options.format&&(this.format=this.options.format),this.format)if(this.format==="textarea")this.input_type="textarea",this.input=this.theme.getTextareaInput();else if(this.format==="range"){this.input_type="range";var e=this.schema.minimum||0,o=this.schema.maximum||Math.max(100,e+1),u=1;this.schema.multipleOf&&(e%this.schema.multipleOf&&(e=Math.ceil(e/this.schema.multipleOf)*this.schema.multipleOf),o%this.schema.multipleOf&&(o=Math.floor(o/this.schema.multipleOf)*this.schema.multipleOf),u=this.schema.multipleOf),this.input=this.theme.getRangeInput(e,o,u)}else this.input_type="text",["button","checkbox","color","date","datetime-local","email","file","hidden","image","month","number","password","radio","reset","search","submit","tel","text","time","url","week"].includes(this.format)&&(this.input_type=this.format),this.input=this.theme.getFormInputField(this.input_type);else this.input_type="text",this.input=this.theme.getFormInputField(this.input_type);this.schema.maxLength!==void 0&&this.input.setAttribute("maxlength",this.schema.maxLength),this.schema.pattern!==void 0?this.input.setAttribute("pattern",this.schema.pattern):this.schema.minLength!==void 0&&this.input.setAttribute("pattern",".{".concat(this.schema.minLength,",}")),this.options.compact?this.container.classList.add("compact"):this.options.input_width&&(this.input.style.width=this.options.input_width),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&(this.disable(!0),this.input.setAttribute("readonly","true")),this.setInputAttributes(["maxlength","pattern","readonly","min","max","step"]),this.input.addEventListener("change",function(P){if(P.preventDefault(),P.stopPropagation(),t.schema.template)P.currentTarget.value=t.value;else{var D=P.currentTarget.value,J=t.sanitize(D);D!==J&&(P.currentTarget.value=J),t.is_dirty=!0,t.refreshValue(),t.onChange(!0)}}),this.options.input_height&&(this.input.style.height=this.options.input_height),this.options.expand_height&&(this.adjust_height=function(P){if(P){var D,J=P.offsetHeight;if(P.offsetHeight<P.scrollHeight)for(D=0;P.offsetHeight<P.scrollHeight+3&&!(D>100);)D++,J++,P.style.height="".concat(J,"px");else{for(D=0;P.offsetHeight>=P.scrollHeight+3&&!(D>100);)D++,J--,P.style.height="".concat(J,"px");P.style.height="".concat(J+1,"px")}}},this.input.addEventListener("keyup",function(P){t.adjust_height(P.currentTarget)}),this.input.addEventListener("change",function(P){t.adjust_height(P.currentTarget)}),this.adjust_height()),this.format&&this.input.setAttribute("data-schemaformat",this.format);var d=this.input;if(this.format==="range"&&(d=this.theme.getRangeControl(this.input,this.theme.getRangeOutput(this.input,this.schema.default||Math.max(this.schema.minimum||0,0)))),this.control=this.theme.getFormControl(this.label,d,this.description,this.infoButton,this.formname),this.container.appendChild(this.control),window.requestAnimationFrame(function(){t.input.parentNode&&t.afterInputReady(),t.adjust_height&&t.adjust_height(t.input),t.format==="range"&&(t.control.querySelector("output").value=t.input.value)}),this.schema.template){var x=this.expandCallbacks("template",{template:this.schema.template});typeof x.template=="function"?this.template=x.template:this.template=this.jsoneditor.compileTemplate(this.schema.template,this.template_engine),this.refreshValue()}else this.refreshValue()}},{key:"setupCleave",value:function(t){var e=this.expandCallbacks("cleave",k({},this.defaults.options.cleave||{},this.options.cleave||{}));N(e)==="object"&&Object.keys(e).length>0&&(this.cleave_instance=new window.Cleave(t,e))}},{key:"setupImask",value:function(t){var e=this.expandCallbacks("imask",k({},this.defaults.options.imask||{},this.options.imask||{}));N(e)==="object"&&Object.keys(e).length>0&&(this.imask_instance=window.IMask(t,this.ajustIMaskOptions(e)))}},{key:"ajustIMaskOptions",value:function(t){var e=this;return Object.keys(t).forEach(function(o){if(t[o]===Object(t[o]))t[o]=e.ajustIMaskOptions(t[o]);else if(o==="mask")if(t[o].substr(0,6)==="regex:"){var u=t[o].match(/^regex:\/(.*)\/([gimsuy]*)$/);if(u!==null)try{t[o]=new RegExp(u[1],u[2])}catch{}}else t[o]=e.getGlobalPropertyFromString(t[o])}),t}},{key:"getGlobalPropertyFromString",value:function(t){if(t.includes(".")){var e=t.split("."),o=e[0],u=e[1];if(window[o]!==void 0&&window[o][u]!==void 0)return window[o][u]}else if(window[t]!==void 0)return window[t];return t}},{key:"shouldBeUnset",value:function(){return!this.jsoneditor.options.use_default_values&&!this.is_dirty}},{key:"getValue",value:function(){var t=!(!this.input||!this.input.value);if(!this.shouldBeUnset()||t)return this.imask_instance&&this.dependenciesFulfilled&&this.options.imask.returnUnmasked?this.imask_instance.unmaskedValue:H(Y(l.prototype),"getValue",this).call(this)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,H(Y(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,H(Y(l.prototype),"disable",this).call(this)}},{key:"afterInputReady",value:function(){this.theme.afterInputReady(this.input),window.Cleave&&!this.cleave_instance?this.setupCleave(this.input):window.IMask&&!this.imask_instance&&this.setupImask(this.input)}},{key:"refreshValue",value:function(){this.input&&(this.value=this.input.value,typeof this.value=="string"||this.shouldBeUnset()||(this.value=""),this.serialized=this.value)}},{key:"destroy",value:function(){this.cleave_instance&&this.cleave_instance.destroy(),this.imask_instance&&this.imask_instance.destroy(),this.template=null,this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),H(Y(l.prototype),"destroy",this).call(this)}},{key:"sanitize",value:function(t){return t}},{key:"onWatchedFieldChange",value:function(){var t;this.template&&(t=this.getWatchedFieldValues(),this.setValue(this.template(t),!1,!0)),H(Y(l.prototype),"onWatchedFieldChange",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;if(this.jsoneditor.options.show_errors!=="always"){if(!this.is_dirty&&this.previous_error_setting===this.jsoneditor.options.show_errors)return}this.previous_error_setting=this.jsoneditor.options.show_errors;var o=t.reduce(function(u,d){return d.path===e.path&&u.push(d.message),u},[]);o.length?this.theme.addInputError(this.input,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input)}}])&&U(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function tt(c){return tt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},tt(c)}function it(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(tt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(tt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),tt(h)==="symbol"?h:String(h)),i)}var h}function st(){return st=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ct(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},st.apply(this,arguments)}function yt(c,n){return yt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},yt(c,n)}function ct(c){return ct=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ct(c)}var Et=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&yt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ct(i);if(h){var o=ct(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(tt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=st(ct(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.ace_editor_instance&&(this.ace_editor_instance.setValue(u.value),this.ace_editor_instance.session.getSelection().clearSelection(),this.ace_editor_instance.resize())}},{key:"build",value:function(){this.options.format="textarea",st(ct(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t,e=this;if(window.ace){var o=this.input_type;o!=="cpp"&&o!=="c++"&&o!=="c"||(o="c_cpp"),t=this.expandCallbacks("ace",k({},{selectionStyle:"text",minLines:30,maxLines:30},this.defaults.options.ace||{},this.options.ace||{},{mode:"ace/mode/".concat(o)})),this.ace_container=document.createElement("div"),this.ace_container.style.width="100%",this.ace_container.style.position="relative",this.input.parentNode.insertBefore(this.ace_container,this.input),this.input.style.display="none",this.ace_editor_instance=window.ace.edit(this.ace_container,t),this.ace_editor_instance.setValue(this.getValue()),this.ace_editor_instance.session.getSelection().clearSelection(),this.ace_editor_instance.resize(),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&this.ace_editor_instance.setReadOnly(!0),this.ace_editor_instance.on("change",function(){e.input.value=e.ace_editor_instance.getValue(),e.refreshValue(),e.is_dirty=!0,e.onChange(!0)}),this.theme.afterInputReady(this.input)}else st(ct(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.ace_editor_instance&&this.ace_editor_instance.setReadOnly(!1),st(ct(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.ace_editor_instance&&this.ace_editor_instance.setReadOnly(!0),st(ct(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.ace_editor_instance&&(this.ace_editor_instance.destroy(),this.ace_editor_instance=null),st(ct(l.prototype),"destroy",this).call(this)}}])&&it(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function At(c){return At=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},At(c)}function Vt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(At(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(At(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),At(h)==="symbol"?h:String(h)),i)}var h}function lt(){return lt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=_t(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},lt.apply(this,arguments)}function wt(c,n){return wt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},wt(c,n)}function _t(c){return _t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},_t(c)}_(7327);var Ut=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&wt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=_t(i);if(h){var o=_t(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(At(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,f=[{key:"askConfirmation",value:function(){return this.jsoneditor.options.prompt_before_delete!==!0||window.confirm(this.translate("button_delete_node_warning"))!==!1}},{key:"getDefault",value:function(){return this.schema.default||[]}},{key:"register",value:function(){lt(_t(l.prototype),"register",this).call(this),this.rows&&this.rows.forEach(function(t){return t.register()})}},{key:"unregister",value:function(){lt(_t(l.prototype),"unregister",this).call(this),this.rows&&this.rows.forEach(function(t){return t.unregister()})}},{key:"getNumColumns",value:function(){var t=this.getItemInfo(0);return this.tabs_holder&&this.schema.format!=="tabs-top"?Math.max(Math.min(12,t.width+2),4):t.width}},{key:"enable",value:function(){var t=this;this.always_disabled||(this.setAvailability(this,!1),this.rows&&this.rows.forEach(function(e){e.enable(),t.setAvailability(e,!1)}),lt(_t(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){var e=this;t&&(this.always_disabled=!0),this.setAvailability(this,!0),this.rows&&this.rows.forEach(function(o){o.disable(t),e.setAvailability(o,!0)}),lt(_t(l.prototype),"disable",this).call(this)}},{key:"setAvailability",value:function(t,e){t.add_row_button&&(t.add_row_button.disabled=e),t.remove_all_rows_button&&(t.remove_all_rows_button.disabled=e),t.delete_last_row_button&&(t.delete_last_row_button.disabled=e),t.copy_button&&(t.copy_button.disabled=e),t.delete_button&&(t.delete_button.disabled=e),t.moveup_button&&(t.moveup_button.disabled=e),t.movedown_button&&(t.movedown_button.disabled=e)}},{key:"preBuild",value:function(){lt(_t(l.prototype),"preBuild",this).call(this),this.rows=[],this.row_cache=[],this.hide_delete_buttons=this.options.disable_array_delete||this.jsoneditor.options.disable_array_delete,this.hide_delete_all_rows_buttons=this.hide_delete_buttons||this.options.disable_array_delete_all_rows||this.jsoneditor.options.disable_array_delete_all_rows,this.hide_delete_last_row_buttons=this.hide_delete_buttons||this.options.disable_array_delete_last_row||this.jsoneditor.options.disable_array_delete_last_row,this.hide_move_buttons=this.options.disable_array_reorder||this.jsoneditor.options.disable_array_reorder,this.hide_add_button=this.options.disable_array_add||this.jsoneditor.options.disable_array_add,this.show_copy_button=this.options.enable_array_copy||this.jsoneditor.options.enable_array_copy,this.array_controls_top=this.options.array_controls_top||this.jsoneditor.options.array_controls_top}},{key:"build",value:function(){this.options.compact?(this.title=this.theme.getHeader("",this.getPathDepth()),this.container.appendChild(this.title),this.panel=this.theme.getIndentedPanel(),this.container.appendChild(this.panel),this.title_controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.title_controls),this.controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.controls),this.row_holder=document.createElement("div"),this.panel.appendChild(this.row_holder)):(this.header=document.createElement("label"),this.header.textContent=this.getTitle(),this.title=this.theme.getHeader(this.header,this.getPathDepth()),this.container.appendChild(this.title),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText)),this.container.appendChild(this.infoButton)),this.title_controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.title_controls),this.schema.description&&(this.description=this.theme.getDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.description)),this.error_holder=document.createElement("div"),this.container.appendChild(this.error_holder),this.schema.format==="tabs-top"?(this.controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.controls),this.tabs_holder=this.theme.getTopTabHolder(this.getValidId(this.getItemTitle())),this.container.appendChild(this.tabs_holder),this.row_holder=this.theme.getTopTabContentHolder(this.tabs_holder),this.active_tab=null):this.schema.format==="tabs"?(this.controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.controls),this.tabs_holder=this.theme.getTabHolder(this.getValidId(this.getItemTitle())),this.container.appendChild(this.tabs_holder),this.row_holder=this.theme.getTabContentHolder(this.tabs_holder),this.active_tab=null):(this.panel=this.theme.getIndentedPanel(),this.container.appendChild(this.panel),this.row_holder=document.createElement("div"),this.panel.appendChild(this.row_holder),this.controls=this.theme.getButtonHolder(),this.array_controls_top?this.title.appendChild(this.controls):this.panel.appendChild(this.controls))),this.addControls()}},{key:"onChildEditorChange",value:function(t){this.refreshValue(),this.refreshTabs(!0),lt(_t(l.prototype),"onChildEditorChange",this).call(this,t)}},{key:"getItemTitle",value:function(){if(!this.item_title)if(this.schema.items&&!Array.isArray(this.schema.items)){var t=this.jsoneditor.expandRefs(this.schema.items);this.item_title=this.translateProperty(t.title)||this.translate("default_array_item_title")}else this.item_title=this.translate("default_array_item_title");return this.cleanText(this.item_title)}},{key:"getItemSchema",value:function(t){return Array.isArray(this.schema.items)?t>=this.schema.items.length?this.schema.additionalItems===!0?{}:this.schema.additionalItems?k({},this.schema.additionalItems):void 0:k({},this.schema.items[t]):this.schema.items?k({},this.schema.items):{}}},{key:"getItemInfo",value:function(t){var e=this.getItemSchema(t);this.item_info=this.item_info||{};var o=JSON.stringify(e);return this.item_info[o]!==void 0||(e=this.jsoneditor.expandRefs(e),this.item_info[o]={title:this.translateProperty(e.title)||this.translate("default_array_item_title"),default:e.default,width:12,child_editors:e.properties||e.items}),this.item_info[o]}},{key:"getElementEditor",value:function(t){var e=this.getItemInfo(t),o=this.getItemSchema(t);(o=this.jsoneditor.expandRefs(o)).title="".concat(e.title," ").concat(t+1);var u,d=this.jsoneditor.getEditorClass(o);this.tabs_holder?(u=this.schema.format==="tabs-top"?this.theme.getTopTabContent():this.theme.getTabContent()).id="".concat(this.path,".").concat(t):u=e.child_editors?this.theme.getChildEditorHolder():this.theme.getIndentedPanel(),this.row_holder.appendChild(u);var x=this.jsoneditor.createEditor(d,{jsoneditor:this.jsoneditor,schema:o,container:u,path:"".concat(this.path,".").concat(t),parent:this,required:!0});return x.preBuild(),x.build(),x.postBuild(),x.title_controls||(x.array_controls=this.theme.getButtonHolder(),u.appendChild(x.array_controls)),x}},{key:"checkParent",value:function(t){return t&&t.parentNode}},{key:"destroy",value:function(){this.empty(!0),this.checkParent(this.title)&&this.title.parentNode.removeChild(this.title),this.checkParent(this.description)&&this.description.parentNode.removeChild(this.description),this.checkParent(this.row_holder)&&this.row_holder.parentNode.removeChild(this.row_holder),this.checkParent(this.controls)&&this.controls.parentNode.removeChild(this.controls),this.checkParent(this.panel)&&this.panel.parentNode.removeChild(this.panel),this.rows=this.row_cache=this.title=this.description=this.row_holder=this.panel=this.controls=null,lt(_t(l.prototype),"destroy",this).call(this)}},{key:"empty",value:function(t){var e=this;this.rows&&(this.rows.forEach(function(o,u){t&&(e.checkParent(o.tab)&&o.tab.parentNode.removeChild(o.tab),e.destroyRow(o,!0),e.row_cache[u]=null),e.rows[u]=null}),this.rows=[],t&&(this.row_cache=[]))}},{key:"destroyRow",value:function(t,e){var o=t.container;e?(t.destroy(),o.parentNode&&o.parentNode.removeChild(o),this.checkParent(t.tab)&&t.tab.parentNode.removeChild(t.tab)):(t.tab&&(t.tab.style.display="none"),o.style.display="none",t.unregister())}},{key:"getMax",value:function(){return Array.isArray(this.schema.items)&&this.schema.additionalItems===!1?Math.min(this.schema.items.length,this.schema.maxItems||1/0):this.schema.maxItems||1/0}},{key:"refreshTabs",value:function(t){var e=this;this.rows.forEach(function(o){o.tab&&(t?o.tab_text.textContent=o.getHeaderText():o.tab===e.active_tab?e.theme.markTabActive(o):e.theme.markTabInactive(o))})}},{key:"ensureArraySize",value:function(t){if(Array.isArray(t)||(t=[t]),this.schema.minItems)for(;t.length<this.schema.minItems;)t.push(this.getItemInfo(t.length).default);return this.getMax()&&t.length>this.getMax()&&(t=t.slice(0,this.getMax())),t}},{key:"setValue",value:function(){var t=this,e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],o=arguments.length>1?arguments[1]:void 0;if(e=this.ensureArraySize(e),JSON.stringify(e)!==this.serialized){e.forEach(function(P,D){if(t.rows[D])t.rows[D].setValue(P,o);else if(t.row_cache[D])t.rows[D]=t.row_cache[D],t.rows[D].setValue(P,o),t.rows[D].container.style.display="",t.rows[D].tab&&(t.rows[D].tab.style.display=""),t.rows[D].register(),t.jsoneditor.trigger("addRow",t.rows[D]);else{var J=t.addRow(P,o);t.jsoneditor.trigger("addRow",J)}});for(var u=e.length;u<this.rows.length;u++)this.destroyRow(this.rows[u]),this.rows[u]=null;this.rows=this.rows.slice(0,e.length);var d=this.rows.find(function(P){return P.tab===t.active_tab}),x=d!==void 0?d.tab:null;!x&&this.rows.length&&(x=this.rows[0].tab),this.active_tab=x,this.refreshValue(o),this.refreshTabs(!0),this.refreshTabs(),this.onChange()}}},{key:"setButtonState",value:function(t,e){switch(this.options.button_state_mode||this.jsoneditor.options.button_state_mode){case 1:default:t.style.display=e?"":"none";break;case 2:t.disabled=!e}}},{key:"setupButtons",value:function(t){var e=[];if(this.value.length)if(this.value.length===1){this.setButtonState(this.remove_all_rows_button,!1);var o=!(t||this.hide_delete_last_row_buttons);this.setButtonState(this.delete_last_row_button,o),e.push(o)}else{var u=!(t||this.hide_delete_last_row_buttons);this.setButtonState(this.delete_last_row_button,u),e.push(u);var d=!(t||this.hide_delete_all_rows_buttons);this.setButtonState(this.remove_all_rows_button,d),e.push(d)}else this.setButtonState(this.delete_last_row_button,!1),this.setButtonState(this.remove_all_rows_button,!1);var x=!(this.getMax()&&this.getMax()<=this.rows.length||this.hide_add_button);return this.setButtonState(this.add_row_button,x),e.push(x),e.some(function(P){return P})}},{key:"refreshValue",value:function(t){var e=this,o=this.value?this.value.length:0;if(this.value=this.rows.map(function(d){return d.getValue()}),o!==this.value.length||t){var u=this.schema.minItems&&this.schema.minItems>=this.rows.length;this.rows.forEach(function(d,x){if(d.movedown_button){var P=x!==e.rows.length-1;e.setButtonState(d.movedown_button,P)}d.delete_button&&e.setButtonState(d.delete_button,!u),e.value[x]=d.getValue()}),!this.collapsed&&this.setupButtons(u)?this.controls.style.display="inline-block":this.controls.style.display="none"}this.serialized=JSON.stringify(this.value)}},{key:"addRow",value:function(t,e){var o=this,u=this.rows.length;this.rows[u]=this.getElementEditor(u),this.row_cache[u]=this.rows[u],this.tabs_holder&&(this.rows[u].tab_text=document.createElement("span"),this.rows[u].tab_text.textContent=this.rows[u].getHeaderText(),this.schema.format==="tabs-top"?(this.rows[u].tab=this.theme.getTopTab(this.rows[u].tab_text,this.getValidId(this.rows[u].path)),this.theme.addTopTab(this.tabs_holder,this.rows[u].tab)):(this.rows[u].tab=this.theme.getTab(this.rows[u].tab_text,this.getValidId(this.rows[u].path)),this.theme.addTab(this.tabs_holder,this.rows[u].tab)),this.rows[u].tab.addEventListener("click",function(x){o.active_tab=o.rows[u].tab,o.refreshTabs(),x.preventDefault(),x.stopPropagation()}));var d=this.rows[u].title_controls||this.rows[u].array_controls;return this.hide_delete_buttons||(this.rows[u].delete_button=this._createDeleteButton(u,d)),this.show_copy_button&&(this.rows[u].copy_button=this._createCopyButton(u,d)),u&&!this.hide_move_buttons&&(this.rows[u].moveup_button=this._createMoveUpButton(u,d)),this.hide_move_buttons||(this.rows[u].movedown_button=this._createMoveDownButton(u,d)),t!==void 0&&this.rows[u].setValue(t,e),this.refreshTabs(),this.rows[u]}},{key:"_createDeleteButton",value:function(t,e){var o=this,u=this.getButton(this.getItemTitle(),"delete","button_delete_row_title",[this.getItemTitle()]);return u.classList.add("delete","json-editor-btntype-delete"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){if(d.preventDefault(),d.stopPropagation(),!o.askConfirmation())return!1;var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue().filter(function(nt,ut){return ut!==x}),D=null,J=o.rows[x].getValue();o.setValue(P),o.rows[x]?D=o.rows[x].tab:o.rows[x-1]&&(D=o.rows[x-1].tab),D&&(o.active_tab=D,o.refreshTabs()),o.onChange(!0),o.jsoneditor.trigger("deleteRow",J)}),e&&e.appendChild(u),u}},{key:"_createCopyButton",value:function(t,e){var o=this,u=this.getButton(this.getItemTitle(),"copy","button_copy_row_title",[this.getItemTitle()]),d=this.schema;return u.classList.add("copy","json-editor-btntype-copy"),u.setAttribute("data-i",t),u.addEventListener("click",function(x){var P=o.getValue();x.preventDefault(),x.stopPropagation();var D=1*x.currentTarget.getAttribute("data-i");P.forEach(function(J,nt){if(nt===D){if(d.items.type==="string"&&d.items.format==="uuid")J=R();else if(d.items.type==="object"&&d.items.properties)for(var ut=0,dt=Object.keys(J);ut<dt.length;ut++){var kt=dt[ut];d.items.properties&&d.items.properties[kt]&&d.items.properties[kt].format==="uuid"&&(J[kt]=R())}P.push(J)}}),o.setValue(P),o.refreshValue(!0),o.onChange(!0)}),e.appendChild(u),u}},{key:"_createMoveUpButton",value:function(t,e){var o=this,u=this.getButton("",this.schema.format==="tabs-top"?"moveleft":"moveup","button_move_up_title");return u.classList.add("moveup","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i");if(!(x<=0)){var P=o.getValue(),D=P[x-1];P[x-1]=P[x],P[x]=D,o.setValue(P),o.active_tab=o.rows[x-1].tab,o.refreshTabs(),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x-1])}}),e&&e.appendChild(u),u}},{key:"_createMoveDownButton",value:function(t,e){var o=this,u=this.getButton("",this.schema.format==="tabs-top"?"moveright":"movedown","button_move_down_title");return u.classList.add("movedown","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue();if(!(x>=P.length-1)){var D=P[x+1];P[x+1]=P[x],P[x]=D,o.setValue(P),o.active_tab=o.rows[x+1].tab,o.refreshTabs(),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x+1])}}),e&&e.appendChild(u),u}},{key:"addControls",value:function(){this.collapsed=!1,this.toggle_button=this._createToggleButton(),this.options.collapsed&&O(this.toggle_button,"click"),this.schema.options&&this.schema.options.disable_collapse!==void 0?this.schema.options.disable_collapse&&(this.toggle_button.style.display="none"):this.jsoneditor.options.disable_collapse&&(this.toggle_button.style.display="none"),this.add_row_button=this._createAddRowButton(),this.delete_last_row_button=this._createDeleteLastRowButton(),this.remove_all_rows_button=this._createRemoveAllRowsButton(),this.tabs&&(this.add_row_button.classList.add("je-array-control-btn"),this.delete_last_row_button.classList.add("je-array-control-btn"),this.remove_all_rows_button.classList.add("je-array-control-btn"))}},{key:"_createToggleButton",value:function(){var t=this,e=this.getButton("","collapse","button_collapse");e.classList.add("json-editor-btntype-toggle"),this.title.insertBefore(e,this.title.childNodes[0]);var o=this.row_holder.style.display,u=this.controls.style.display;return e.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation(),t.panel&&t.setButtonState(t.panel,t.collapsed),t.tabs_holder&&t.setButtonState(t.tabs_holder,t.collapsed),t.collapsed?(t.collapsed=!1,t.row_holder.style.display=o,t.controls.style.display=u,t.setButtonText(d.currentTarget,"","collapse","button_collapse")):(t.collapsed=!0,t.row_holder.style.display="none",t.controls.style.display="none",t.setButtonText(d.currentTarget,"","expand","button_expand"))}),e}},{key:"_createAddRowButton",value:function(){var t=this,e=this.getButton(this.getItemTitle(),"add","button_add_row_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-add"),e.addEventListener("click",function(o){o.preventDefault(),o.stopPropagation();var u,d=t.rows.length;t.row_cache[d]?(u=t.rows[d]=t.row_cache[d],t.rows[d].setValue(t.rows[d].getDefault(),!0),t.rows[d].container.style.display="",t.rows[d].tab&&(t.rows[d].tab.style.display=""),t.rows[d].register()):u=t.addRow(),t.active_tab=t.rows[d].tab,t.refreshTabs(),t.refreshValue(),t.onChange(!0),t.jsoneditor.trigger("addRow",u)}),this.controls.appendChild(e),e}},{key:"_createDeleteLastRowButton",value:function(){var t=this,e=this.getButton("button_delete_last","subtract","button_delete_last_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-deletelast"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue(),d=null,x=u.pop();t.setValue(u),t.rows[t.rows.length-1]&&(d=t.rows[t.rows.length-1].tab),d&&(t.active_tab=d,t.refreshTabs()),t.onChange(!0),t.jsoneditor.trigger("deleteRow",x)}),this.controls.appendChild(e),e}},{key:"_createRemoveAllRowsButton",value:function(){var t=this,e=this.getButton("button_delete_all","delete","button_delete_all_title");return e.classList.add("json-editor-btntype-deleteall"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue();t.empty(!0),t.setValue([]),t.onChange(!0),t.jsoneditor.trigger("deleteAllRows",u)}),this.controls.appendChild(e),e}},{key:"showValidationErrors",value:function(t){var e=this,o=[],u=[];t.forEach(function(d){d.path===e.path?o.push(d):u.push(d)}),this.error_holder&&(o.length?(this.error_holder.innerHTML="",this.error_holder.style.display="",o.forEach(function(d){e.error_holder.appendChild(e.theme.getErrorMessage(d.message))})):this.error_holder.style.display="none"),this.rows.forEach(function(d){return d.showValidationErrors(u)})}}],f&&Vt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Kt(c){return Kt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Kt(c)}function fe(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Kt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Kt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Kt(h)==="symbol"?h:String(h)),i)}var h}function St(){return St=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Bt(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},St.apply(this,arguments)}function jt(c,n){return jt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},jt(c,n)}function Bt(c){return Bt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Bt(c)}Ut.rules={".json-editor-btntype-toggle":"margin:0%2010px%200%200",".je-array-control-btn":"width:100%25;text-align:left;margin-bottom:3px"};var qt=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&jt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Bt(i);if(h){var o=Bt(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Kt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"onInputChange",value:function(){this.value=this.input.value,this.onChange(!0)}},{key:"register",value:function(){St(Bt(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){St(Bt(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"getNumColumns",value:function(){var t=this,e=this.getTitle().length;return Object.keys(this.select_values).forEach(function(o){return e=Math.max(e,"".concat(t.select_values[o]).length+4)}),Math.min(12,Math.max(e/7,2))}},{key:"preBuild",value:function(){var t;St(Bt(l.prototype),"preBuild",this).call(this),this.select_options={},this.select_values={},this.option_titles=[],this.option_keys=[],this.option_enum=[];var e=this.jsoneditor.expandRefs(this.schema.items||{}),o=e.enum||[],u=e.options&&e.options.enum||[],d=e.options&&e.options.enum_titles||[];for(t=0;t<o.length;t++)if(this.sanitize(o[t])===o[t]){var x=u[t]||{};"title"in x||(x.title="".concat(d[t]||o[t])),this.option_keys.push("".concat(o[t])),this.option_enum.push(x),this.select_values["".concat(o[t])]=o[t]}}},{key:"build",value:function(){var t,e=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),!this.schema.format&&this.option_keys.length<8||this.schema.format==="checkbox"){for(this.input_type="checkboxes",this.inputs={},this.controls={},t=0;t<this.option_keys.length;t++){var o=this.formname+t.toString();this.inputs[this.option_keys[t]]=this.theme.getCheckbox(),this.inputs[this.option_keys[t]].id=o,this.select_options[this.option_keys[t]]=this.inputs[this.option_keys[t]];var u=this.theme.getCheckboxLabel(this.option_enum[t].title);if(u.htmlFor=o,this.option_enum[t].infoText){var d=this.theme.getInfoButton(this.translateProperty(this.option_enum[t].infoText));u.appendChild(d)}this.controls["_"+this.option_keys[t]]=this.theme.getFormControl(u,this.inputs[this.option_keys[t]])}this.control=this.theme.getMultiCheckboxHolder(this.controls,this.label,this.description,this.infoButton),this.inputs.controlgroup=this.inputs.controls=this.control}else{for(this.input_type="select",this.input=this.theme.getSelectInput(this.option_keys,!0),this.theme.setSelectOptions(this.input,this.option_keys,this.option_enum.map(function(x){return x.title})),this.input.setAttribute("multiple","multiple"),this.input.size=Math.min(10,this.option_keys.length),t=0;t<this.option_keys.length;t++)this.select_options[this.option_keys[t]]=this.input.children[t];this.control=this.theme.getFormControl(this.label,this.input,this.description,this.infoButton)}(this.schema.readOnly||this.schema.readonly)&&this.disable(!0),this.container.appendChild(this.control),this.multiselectChangeHandler=function(x){var P=[];for(t=0;t<e.option_keys.length;t++)e.select_options[e.option_keys[t]]&&(e.select_options[e.option_keys[t]].selected||e.select_options[e.option_keys[t]].checked)&&P.push(e.select_values[e.option_keys[t]]);e.updateValue(P),e.onChange(!0)},this.control.addEventListener("change",this.multiselectChangeHandler,!1),window.requestAnimationFrame(function(){e.afterInputReady()})}},{key:"postBuild",value:function(){St(Bt(l.prototype),"postBuild",this).call(this)}},{key:"afterInputReady",value:function(){this.theme.afterInputReady(this.input||this.inputs)}},{key:"setValue",value:function(t,e){var o=this;t=t||[],Array.isArray(t)||(t=[t]),t=t.map(function(u){return"".concat(u)}),Object.keys(this.select_options).forEach(function(u){o.select_options[u][o.input_type==="select"?"selected":"checked"]=t.includes(u)}),this.updateValue(t),this.onChange(!0)}},{key:"removeValue",value:function(t){t=[].concat(t),this.setValue(this.getValue().filter(function(e){return!t.includes(e)}))}},{key:"addValue",value:function(t){this.setValue(this.getValue().concat(t))}},{key:"updateValue",value:function(t){for(var e=!1,o=[],u=0;u<t.length;u++)if(this.select_options["".concat(t[u])]){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}else e=!0;return this.value=o,e}},{key:"sanitize",value:function(t){return this.schema.items.type==="boolean"?!!t:this.schema.items.type==="number"?1*t||0:this.schema.items.type==="integer"?Math.floor(1*t||0):"".concat(t)}},{key:"enable",value:function(){var t=this;this.always_disabled||(this.input?this.input.disabled=!1:this.inputs&&Object.keys(this.inputs).forEach(function(e){return t.inputs[e].disabled=!1}),St(Bt(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){var e=this;t&&(this.always_disabled=!0),this.input?this.input.disabled=!0:this.inputs&&Object.keys(this.inputs).forEach(function(o){return e.inputs[o].disabled=!0}),St(Bt(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){St(Bt(l.prototype),"destroy",this).call(this)}},{key:"escapeRegExp",value:function(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}},{key:"showValidationErrors",value:function(t){var e=new RegExp("^".concat(this.escapeRegExp(this.path),"(\\.\\d+)?$")),o=t.reduce(function(u,d){return d.path.match(e)&&u.push(d.message),u},[]);o.length?this.theme.addInputError(this.input||this.inputs,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input||this.inputs)}}])&&fe(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function xt(c){return xt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},xt(c)}function lr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(xt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(xt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),xt(h)==="symbol"?h:String(h)),i)}var h}function de(){return de=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ge(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},de.apply(this,arguments)}function Ne(c,n){return Ne=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ne(c,n)}function ge(c){return ge=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ge(c)}var cr=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ne(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ge(i);if(h){var o=ge(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(xt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){this.choices_instance?(t=[].concat(t).map(function(o){return"".concat(o)}),this.updateValue(t),this.choices_instance.removeActiveItems(),this.choices_instance.setChoiceByValue(this.value),this.onChange(!0)):de(ge(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t=this;if(window.Choices&&!this.choices_instance){var e=this.expandCallbacks("choices",k({},{removeItems:!0,removeItemButton:!0},this.defaults.options.choices||{},this.options.choices||{},{addItems:!0,editItems:!1,duplicateItemsAllowed:!1}));this.newEnumAllowed=!1,this.choices_instance=new window.Choices(this.input,e),this.control.removeEventListener("change",this.multiselectChangeHandler),this.multiselectChangeHandler=function(o){var u=t.choices_instance.getValue(!0);t.updateValue(u),t.onChange(!0)},this.control.addEventListener("change",this.multiselectChangeHandler,!1)}de(ge(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){t=[].concat(t);for(var e=!1,o=[],u=0;u<t.length;u++)if(!(!this.select_values["".concat(t[u])]&&(e=!0,!this.newEnumAllowed||!this.addNewOption(t[u])))){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}return this.value=o,e}},{key:"addNewOption",value:function(t){return this.option_keys.push("".concat(t)),this.option_titles.push("".concat(t)),this.select_values["".concat(t)]=t,this.schema.items.enum.push(t),this.choices_instance.setChoices([{value:"".concat(t),label:"".concat(t)}],"value","label",!1),!0}},{key:"enable",value:function(){!this.always_disabled&&this.choices_instance&&this.choices_instance.enable(),de(ge(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.choices_instance&&this.choices_instance.disable(),de(ge(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.choices_instance&&(this.choices_instance.destroy(),this.choices_instance=null),de(ge(l.prototype),"destroy",this).call(this)}}])&&lr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(qt);function Ae(c){return Ae=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ae(c)}function dr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Ae(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Ae(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Ae(h)==="symbol"?h:String(h)),i)}var h}function Le(){return Le=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Ce(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Le.apply(this,arguments)}function We(c,n){return We=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},We(c,n)}function Ce(c){return Ce=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ce(c)}var pr=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&We(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Ce(i);if(h){var o=Ce(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Ae(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){this.select2_instance?(t=[].concat(t).map(function(o){return"".concat(o)}),this.updateValue(t),this.select2v4?this.select2_instance.val(this.value).change():this.select2_instance.select2("val",this.value),this.onChange(!0)):Le(Ce(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t,e=this;window.jQuery&&window.jQuery.fn&&window.jQuery.fn.select2&&!this.select2_instance&&(t=this.expandCallbacks("select2",k({},{tags:!0,width:"100%"},this.defaults.options.select2||{},this.options.select2||{})),this.newEnumAllowed=t.tags=!!t.tags&&this.schema.items&&this.schema.items.type==="string",this.select2_instance=window.jQuery(this.input).select2(t),this.select2v4=S(this.select2_instance.select2,"amd"),this.selectChangeHandler=function(){var o=e.select2v4?e.select2_instance.val():e.select2_instance.select2("val");e.updateValue(o),e.onChange(!0)},this.select2_instance.on("select2-blur",this.selectChangeHandler),this.select2_instance.on("change",this.selectChangeHandler)),Le(Ce(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){t=[].concat(t);for(var e=!1,o=[],u=0;u<t.length;u++)if(!(!this.select_values["".concat(t[u])]&&(e=!0,!this.newEnumAllowed||!this.addNewOption(t[u])))){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}return this.value=o,e}},{key:"addNewOption",value:function(t){this.option_keys.push("".concat(t)),this.option_titles.push("".concat(t)),this.select_values["".concat(t)]=t,this.schema.items.enum.push(t);var e=this.input.querySelector('option[value="'.concat(t,'"]'));return e?e.removeAttribute("data-select2-tag"):this.input.appendChild(new Option(t,t,!1,!1)).trigger("change"),!0}},{key:"enable",value:function(){!this.always_disabled&&this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!1):this.select2_instance.select2("enable",!0)),Le(Ce(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!0):this.select2_instance.select2("enable",!1)),Le(Ce(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){this.select2_instance&&(this.select2_instance.select2("destroy"),this.select2_instance=null),Le(Ce(l.prototype),"destroy",this).call(this)}}])&&dr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(qt);function ot(c){return ot=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ot(c)}function bt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ot(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ot(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ot(h)==="symbol"?h:String(h)),i)}var h}function Ht(){return Ht=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Qt(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Ht.apply(this,arguments)}function Mt(c,n){return Mt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Mt(c,n)}function Qt(c){return Qt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qt(c)}var Ze=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Mt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Qt(i);if(h){var o=Qt(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(ot(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){this.selectize_instance?(t=[].concat(t).map(function(o){return"".concat(o)}),this.updateValue(t),this.selectize_instance.setValue(this.value),this.onChange(!0)):Ht(Qt(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t,e=this;window.jQuery&&window.jQuery.fn&&window.jQuery.fn.selectize&&!this.selectize_instance&&(t=this.expandCallbacks("selectize",k({},{plugins:["remove_button"],delimiter:!1,createOnBlur:!0,create:!0},this.defaults.options.selectize||{},this.options.selectize||{})),this.newEnumAllowed=t.create=!!t.create&&this.schema.items&&this.schema.items.type==="string",this.selectize_instance=window.jQuery(this.input).selectize(t)[0].selectize,this.control.removeEventListener("change",this.multiselectChangeHandler),this.multiselectChangeHandler=function(o){var u=e.selectize_instance.getValue();e.updateValue(u),e.onChange(!0)},this.selectize_instance.on("change",this.multiselectChangeHandler)),Ht(Qt(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){t=[].concat(t);for(var e=!1,o=[],u=0;u<t.length;u++)if(!(!this.select_values["".concat(t[u])]&&(e=!0,!this.newEnumAllowed||!this.addNewOption(t[u])))){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}return this.value=o,e}},{key:"addNewOption",value:function(t){return this.option_keys.push("".concat(t)),this.option_titles.push("".concat(t)),this.select_values["".concat(t)]=t,this.selectize_instance.addOption({text:t,value:t}),!0}},{key:"enable",value:function(){!this.always_disabled&&this.selectize_instance&&this.selectize_instance.unlock(),Ht(Qt(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.selectize_instance&&this.selectize_instance.lock(),Ht(Qt(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.selectize_instance&&(this.selectize_instance.destroy(),this.selectize_instance=null),Ht(Qt(l.prototype),"destroy",this).call(this)}}])&&bt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(qt);function Ke(c){return Ke=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ke(c)}function xr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Ke(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Ke(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Ke(h)==="symbol"?h:String(h)),i)}var h}function Qe(){return Qe=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Se(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Qe.apply(this,arguments)}function fr(c,n){return fr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},fr(c,n)}function Se(c){return Se=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Se(c)}var Dn=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&fr(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Se(i);if(h){var o=Se(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Ke(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"postBuild",value:function(){window.Autocomplete&&(this.autocomplete_wrapper=document.createElement("div"),this.input.parentNode.insertBefore(this.autocomplete_wrapper,this.input.nextSibling),this.autocomplete_wrapper.appendChild(this.input),this.autocomplete_dropdown=document.createElement("ul"),this.input.parentNode.insertBefore(this.autocomplete_dropdown,this.input.nextSibling)),Qe(Se(l.prototype),"postBuild",this).call(this)}},{key:"afterInputReady",value:function(){var t,e=this;window.Autocomplete&&!this.autocomplete_instance&&(t=this.expandCallbacks("autocomplete",k({},{search:function(o){return console.log('No "search" callback defined for autocomplete in property "'.concat(o.key,'"')),[]},onSubmit:function(){e.input.blur()},baseClass:"autocomplete"},this.defaults.options.autocomplete||{},this.options.autocomplete||{})),this.autocomplete_wrapper.classList.add(t.baseClass),this.autocomplete_dropdown.classList.add("".concat(t.baseClass,"-result-list")),this.autocomplete_instance=new window.Autocomplete(this.autocomplete_wrapper,t)),Qe(Se(l.prototype),"afterInputReady",this).call(this)}},{key:"destroy",value:function(){this.autocomplete_instance&&(this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.autocomplete_dropdown&&this.autocomplete_dropdown.parentNode&&this.autocomplete_dropdown.parentNode.removeChild(this.autocomplete_dropdown),this.autocomplete_wrapper&&this.autocomplete_wrapper.parentNode&&this.autocomplete_wrapper.parentNode.removeChild(this.autocomplete_wrapper),this.autocomplete_instance=null),Qe(Se(l.prototype),"destroy",this).call(this)}}])&&xr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function Nt(c){return Nt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Nt(c)}function te(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Nt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Nt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Nt(h)==="symbol"?h:String(h)),i)}var h}function Xt(){return Xt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ze(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Xt.apply(this,arguments)}function ce(c,n){return ce=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ce(c,n)}function ze(c){return ze=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ze(c)}_(561);var Vi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ce(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ze(i);if(h){var o=ze(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Nt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 4}},{key:"setFileReaderListener",value:function(t){var e=this;t.addEventListener("load",function(o){if(e.count===e.current_item_index)e.value[e.count][e.key]=o.target.result;else{var u={};for(var d in e.parent.schema.properties)u[d]="";u[e.key]=o.target.result,e.value.splice(e.count,0,u)}e.count+=1,e.count===e.total+e.current_item_index&&e.arrayEditor.setValue(e.value)})}},{key:"build",value:function(){var t=this;if(this.options.compact||(this.title=this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.input=this.theme.getFormInputField("hidden"),this.container.appendChild(this.input),!this.schema.readOnly&&!this.schema.readonly){if(!window.FileReader)throw new Error("FileReader required for base64 editor");this.uploader=this.theme.getFormInputField("file"),this.uploader.style.display="none",this.schema.options&&this.schema.options.multiple&&this.schema.options.multiple===!0&&this.parent&&this.parent.schema.type==="object"&&this.parent.parent&&this.parent.parent.schema.type==="array"&&this.uploader.setAttribute("multiple",""),this.uploader.addEventListener("change",function(o){if(o.preventDefault(),o.stopPropagation(),o.currentTarget.files&&o.currentTarget.files.length)if(o.currentTarget.files.length>1&&t.schema.options&&t.schema.options.multiple&&t.schema.options.multiple===!0&&t.parent&&t.parent.schema.type==="object"&&t.parent.parent&&t.parent.parent.schema.type==="array"){t.arrayEditor=t.jsoneditor.getEditor(t.parent.parent.path),t.value=t.arrayEditor.getValue(),t.total=o.currentTarget.files.length,t.current_item_index=parseInt(t.parent.key),t.count=t.current_item_index;for(var u=0;u<t.total;u++){var d=new FileReader;t.setFileReaderListener(d),d.readAsDataURL(o.currentTarget.files[u])}}else{var x=new FileReader;x.onload=function(P){t.value=P.target.result,t.refreshPreview(),t.onChange(!0),x=null},x.readAsDataURL(o.currentTarget.files[0])}})}this.preview=this.theme.getFormInputDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.preview),this.control=this.theme.getFormControl(this.label,this.uploader||this.input,this.preview,this.infoButton),this.container.appendChild(this.control);var e=this.getButton("button_upload","upload","button_upload");e.addEventListener("click",function(){t.uploader.click()}),this.control.appendChild(e)}},{key:"refreshPreview",value:function(){if(this.last_preview!==this.value&&(this.last_preview=this.value,this.preview.innerHTML="",this.value)){var t=this.value.match(/^data:([^;,]+)[;,]/);if(t&&(t=t[1]),t){if(this.preview.innerHTML="<strong>Type:</strong> ".concat(t,", <strong>Size:</strong> ").concat(Math.floor((this.value.length-this.value.split(",")[0].length-1)/1.33333)," bytes"),t.substr(0,5)==="image"){this.preview.innerHTML+="<br>";var e=document.createElement("img");e.style.maxWidth="100%",e.style.maxHeight="100px",e.src=this.value,this.preview.appendChild(e)}}else this.preview.innerHTML="<em>Invalid data URI</em>"}}},{key:"enable",value:function(){this.always_disabled||(this.uploader&&(this.uploader.disabled=!1),Xt(ze(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.uploader&&(this.uploader.disabled=!0),Xt(ze(l.prototype),"disable",this).call(this)}},{key:"setValue",value:function(t){this.value!==t&&(this.schema.readOnly&&this.schema.enum&&!this.schema.enum.includes(t)?this.value=this.schema.enum[0]:this.value=t,this.input.value=this.value,this.refreshPreview(),this.onChange())}},{key:"destroy",value:function(){this.preview&&this.preview.parentNode&&this.preview.parentNode.removeChild(this.preview),this.title&&this.title.parentNode&&this.title.parentNode.removeChild(this.title),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.uploader&&this.uploader.parentNode&&this.uploader.parentNode.removeChild(this.uploader),Xt(ze(l.prototype),"destroy",this).call(this)}}])&&te(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Nn(c){return Nn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Nn(c)}function us(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Nn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Nn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Nn(h)==="symbol"?h:String(h)),i)}var h}function ui(){return ui=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Wr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},ui.apply(this,arguments)}function on(c,n){return on=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},on(c,n)}function Wr(c){return Wr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Wr(c)}var hs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&on(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Wr(i);if(h){var o=Wr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Nn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t,e){var o;return function(u,d){if(!(u instanceof d))throw new TypeError("Cannot call a class as a function")}(this,l),(o=a.call(this,t,e)).active=!1,o.parent&&o.parent.schema&&(Array.isArray(o.parent.schema.required)?o.parent.schema.required.includes(o.key)||o.parent.schema.required.push(o.key):o.parent.schema.required=[o.key]),o}return n=l,(f=[{key:"build",value:function(){var t=this;this.options.compact=!0;var e=this.expandCallbacks("button",k({},{icon:"",validated:!1,align:"left",action:function(u,d){window.alert('No button action defined for "'.concat(u.path,'"'))}},this.defaults.options.button||{},this.options.button||{})),o=this.translateProperty(e.text||this.schema.title)||this.key;this.input=this.getButton(o,e.icon,o),typeof e.action!="function"?window.alert('No button action defined for "'.concat(this.path,'"')):this.input.addEventListener("click",e.action,!1),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&(this.disable(!0),this.input.setAttribute("readonly","true")),this.setInputAttributes(["readonly"]),this.control=this.theme.getFormButtonHolder(e.align),this.control.appendChild(this.input),this.container.appendChild(this.control),this.changeHandler=function(){t.jsoneditor.validate(t.jsoneditor.getValue()).length>0?t.disable():t.enable()},e.validated&&this.jsoneditor.on("change",this.changeHandler)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,ui(Wr(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,ui(Wr(l.prototype),"disable",this).call(this)}},{key:"getNumColumns",value:function(){return 2}},{key:"activate",value:function(){this.active=!1,this.enable()}},{key:"deactivate",value:function(){this.isRequired()||(this.active=!1,this.disable())}},{key:"destroy",value:function(){this.jsoneditor.off("change",this.changeHandler),this.changeHandler=null,ui(Wr(l.prototype),"destroy",this).call(this)}}])&&us(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function $n(c){return $n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},$n(c)}function ds(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if($n(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if($n(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),$n(h)==="symbol"?h:String(h)),i)}var h}function kn(){return kn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Mr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},kn.apply(this,arguments)}function zi(c,n){return zi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},zi(c,n)}function Mr(c){return Mr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Mr(c)}var ps=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&zi(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Mr(i);if(h){var o=Mr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&($n(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){t=!!t;var o=this.getValue()!==t;this.value=t,this.input.checked=this.value,this.onChange(o)}},{key:"register",value:function(){kn(Mr(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){kn(Mr(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"getNumColumns",value:function(){return Math.min(12,Math.max(this.getTitle().length/7,2))}},{key:"build",value:function(){var t=this;this.parent.options.table_row||(this.label=this.header=this.theme.getCheckboxLabel(this.getTitle(),this.isRequired()),this.label.htmlFor=this.formname),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&!this.options.compact&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.input=this.theme.getCheckbox(),this.input.id=this.formname,this.control=this.theme.getFormControl(this.label,this.input,this.description,this.infoButton),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),this.input.disabled=!0),this.input.addEventListener("change",function(e){e.preventDefault(),e.stopPropagation(),t.value=e.currentTarget.checked,t.onChange(!0)}),this.container.appendChild(this.control)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,kn(Mr(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,kn(Mr(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),kn(Mr(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;this.previous_error_setting=this.jsoneditor.options.show_errors;var o=t.reduce(function(u,d){return d.path===e.path&&u.push(d.message),u},[]);this.input.controlgroup=this.control,o.length?this.theme.addInputError(this.input,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input)}}])&&ds(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Mn(c){return Mn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Mn(c)}function ea(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Mn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Mn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Mn(h)==="symbol"?h:String(h)),i)}var h}function Cr(){return Cr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Sr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Cr.apply(this,arguments)}function an(c,n){return an=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},an(c,n)}function Sr(c){return Sr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Sr(c)}_(2707);var hi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&an(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Sr(i);if(h){var o=Sr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Mn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){var o=this.typecast(t),u=!!this.jsoneditor.options.use_default_values||this.schema.default!==void 0;(this.enum_options.length>0&&!this.enum_values.includes(o)||e&&!this.isRequired()&&!u)&&(o=this.enum_values[0]),this.value!==o&&(e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.input.value=this.enum_options[this.enum_values.indexOf(o)],this.value=o,this.onChange(),this.change())}},{key:"register",value:function(){Cr(Sr(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){Cr(Sr(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"getNumColumns",value:function(){if(!this.enum_options)return 3;for(var t=this.getTitle().length,e=0;e<this.enum_options.length;e++)t=Math.max(t,this.enum_options[e].length+4);return Math.min(12,Math.max(t/7,2))}},{key:"typecast",value:function(t){return this.schema.type==="boolean"?t==="undefined"||t===void 0?void 0:!!t:this.schema.type==="number"?1*t||0:this.schema.type==="integer"?Math.floor(1*t||0):this.schema.enum&&t===void 0?void 0:"".concat(t)}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.typecast(this.value)}},{key:"preBuild",value:function(){var t,e,o=this;if(this.input_type="select",this.enum_options=[],this.enum_values=[],this.enum_display=[],this.schema.enum){var u=this.schema.options&&this.schema.options.enum_titles||[];this.schema.enum.forEach(function(d,x){o.enum_options[x]="".concat(d),o.enum_display[x]="".concat(o.translateProperty(u[x])||d),o.enum_values[x]=o.typecast(d)})}else if(this.schema.type==="boolean")this.enum_display=this.schema.options&&this.schema.options.enum_titles||["true","false"],this.enum_options=["1",""],this.enum_values=[!0,!1],this.isRequired()||(this.enum_display.unshift(" "),this.enum_options.unshift("undefined"),this.enum_values.unshift(void 0));else{if(!this.schema.enumSource)throw new Error("'select' editor requires the enum property to be set.");if(this.enumSource=[],this.enum_display=[],this.enum_options=[],this.enum_values=[],Array.isArray(this.schema.enumSource))for(t=0;t<this.schema.enumSource.length;t++)typeof this.schema.enumSource[t]=="string"?this.enumSource[t]={source:this.schema.enumSource[t]}:Array.isArray(this.schema.enumSource[t])?this.enumSource[t]=this.schema.enumSource[t]:this.enumSource[t]=k({},this.schema.enumSource[t]);else this.schema.enumValue?this.enumSource=[{source:this.schema.enumSource,value:this.schema.enumValue}]:this.enumSource=[{source:this.schema.enumSource}];for(t=0;t<this.enumSource.length;t++)this.enumSource[t].value&&(typeof(e=this.expandCallbacks("template",{template:this.enumSource[t].value})).template=="function"?this.enumSource[t].value=e.template:this.enumSource[t].value=this.jsoneditor.compileTemplate(this.enumSource[t].value,this.template_engine)),this.enumSource[t].title&&(typeof(e=this.expandCallbacks("template",{template:this.enumSource[t].title})).template=="function"?this.enumSource[t].title=e.template:this.enumSource[t].title=this.jsoneditor.compileTemplate(this.enumSource[t].title,this.template_engine)),this.enumSource[t].filter&&this.enumSource[t].value&&(typeof(e=this.expandCallbacks("template",{template:this.enumSource[t].filter})).template=="function"?this.enumSource[t].filter=e.template:this.enumSource[t].filter=this.jsoneditor.compileTemplate(this.enumSource[t].filter,this.template_engine))}}},{key:"build",value:function(){var t=this;this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.input=this.theme.getSelectInput(this.enum_options,!1),this.theme.setSelectOptions(this.input,this.enum_options,this.enum_display),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),this.input.disabled=!0),this.setInputAttributes([]),this.input.addEventListener("change",function(e){e.preventDefault(),e.stopPropagation(),t.onInputChange()}),this.control=this.theme.getFormControl(this.label,this.input,this.description,this.infoButton),this.container.appendChild(this.control),this.value=this.enum_values[0],window.requestAnimationFrame(function(){t.input.parentNode&&t.afterInputReady()})}},{key:"afterInputReady",value:function(){this.theme.afterInputReady(this.input)}},{key:"onInputChange",value:function(){var t,e=this.typecast(this.input.value);(t=this.enum_values.includes(e)?this.enum_values[this.enum_values.indexOf(e)]:this.enum_values[0])!==this.value&&(this.is_dirty=!0,this.value=t,this.onChange(!0))}},{key:"onWatchedFieldChange",value:function(){var t,e,o=[],u=[];if(this.enumSource){t=this.getWatchedFieldValues();for(var d=0;d<this.enumSource.length;d++)if(Array.isArray(this.enumSource[d]))o=o.concat(this.enumSource[d]),u=u.concat(this.enumSource[d]);else{var x=[];if(x=Array.isArray(this.enumSource[d].source)?this.enumSource[d].source:t[this.enumSource[d].source]){if(this.enumSource[d].slice&&(x=Array.prototype.slice.apply(x,this.enumSource[d].slice)),this.enumSource[d].filter){var P=[];for(e=0;e<x.length;e++)this.enumSource[d].filter({i:e,item:x[e],watched:t})&&P.push(x[e]);x=P}var D=[],J=[];for(e=0;e<x.length;e++){var nt=x[e];this.enumSource[d].value?J[e]=this.typecast(this.enumSource[d].value({i:e,item:nt})):J[e]=x[e],this.enumSource[d].title?D[e]=this.enumSource[d].title({i:e,item:nt}):D[e]=J[e]}this.enumSource[d].sort&&(function(dt,kt,Ct){dt.map(function($t,ne){return{v:$t,t:kt[ne]}}).sort(function($t,ne){return $t.v<ne.v?-Ct:$t.v===ne.v?0:Ct}).forEach(function($t,ne){dt[ne]=$t.v,kt[ne]=$t.t})}).bind(null,J,D,this.enumSource[d].sort==="desc"?1:-1)(),o=o.concat(J),u=u.concat(D)}}var ut=this.value;this.theme.setSelectOptions(this.input,o,u),this.enum_options=o,this.enum_display=u,this.enum_values=o,o.includes(ut)||this.jsoneditor.options.enum_source_value_auto_select!==!1?(this.input.value=ut,this.value=ut):(this.input.value=o[0],this.value=this.typecast(o[0]||""),this.parent&&!this.watchLoop?this.parent.onChildEditorChange(this):this.jsoneditor.onChange(),this.jsoneditor.notifyWatchers(this.path))}Cr(Sr(l.prototype),"onWatchedFieldChange",this).call(this)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,Cr(Sr(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,Cr(Sr(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),Cr(Sr(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;this.previous_error_setting=this.jsoneditor.options.show_errors;var o=t.reduce(function(u,d){return d.path===e.path&&u.push(d.message),u},[]);o.length?this.theme.addInputError(this.input,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input)}}])&&ea(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Hn(c){return Hn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Hn(c)}function ml(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Hn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Hn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Hn(h)==="symbol"?h:String(h)),i)}var h}function Hr(){return Hr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=z(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Hr.apply(this,arguments)}function L(c,n){return L=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},L(c,n)}function z(c){return z=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},z(c)}var rt=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&L(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=z(i);if(h){var o=z(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Hn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){if(this.choices_instance){var o=this.typecast(t||"");if(this.enum_values.includes(o)||(o=this.enum_values[0]),this.value===o)return;e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.input.value=this.enum_options[this.enum_values.indexOf(o)],this.choices_instance.setChoiceByValue(this.input.value),this.value=o,this.onChange()}else Hr(z(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){if(window.Choices&&!this.choices_instance){var t=this.expandCallbacks("choices",k({},this.defaults.options.choices||{},this.options.choices||{}));this.choices_instance=new window.Choices(this.input,t)}Hr(z(l.prototype),"afterInputReady",this).call(this)}},{key:"onWatchedFieldChange",value:function(){var t=this;if(Hr(z(l.prototype),"onWatchedFieldChange",this).call(this),this.choices_instance){var e=this.enum_options.map(function(o,u){return{value:o,label:t.enum_display[u]}});this.choices_instance.setChoices(e,"value","label",!0),this.choices_instance.setChoiceByValue("".concat(this.value))}}},{key:"enable",value:function(){!this.always_disabled&&this.choices_instance&&this.choices_instance.enable(),Hr(z(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.choices_instance&&this.choices_instance.disable(),Hr(z(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.choices_instance&&(this.choices_instance.destroy(),this.choices_instance=null),Hr(z(l.prototype),"destroy",this).call(this)}}])&&ml(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function Q(c){return Q=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Q(c)}function mt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Q(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Q(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Q(h)==="symbol"?h:String(h)),i)}var h}function Dt(){return Dt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ft(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Dt.apply(this,arguments)}function Jt(c,n){return Jt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Jt(c,n)}function ft(c){return ft=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ft(c)}rt.rules={".choices > *":"box-sizing:border-box"};var vt=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Jt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ft(i);if(h){var o=ft(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Q(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){if(Dt(ft(l.prototype),"build",this).call(this),this.input&&(this.schema.max&&typeof this.schema.max=="string"&&this.input.setAttribute("max",this.schema.max),this.schema.min&&typeof this.schema.max=="string"&&this.input.setAttribute("min",this.schema.min),window.flatpickr&&Q(this.options.flatpickr)==="object")){this.options.flatpickr.enableTime=this.schema.format!=="date",this.options.flatpickr.noCalendar=this.schema.format==="time",this.schema.type==="integer"&&(this.options.flatpickr.mode="single"),this.input.setAttribute("data-input","");var t=this.input;if(this.options.flatpickr.wrap===!0){var e=[];if(this.options.flatpickr.showToggleButton!==!1){var o=this.getButton("",this.schema.format==="time"?"time":"calendar","flatpickr_toggle_button");o.setAttribute("data-toggle",""),e.push(o)}if(this.options.flatpickr.showClearButton!==!1){var u=this.getButton("","clear","flatpickr_clear_button");u.setAttribute("data-clear",""),e.push(u)}var d=this.input.parentNode,x=this.input.nextSibling,P=this.theme.getInputGroup(this.input,e);P!==void 0?(this.options.flatpickr.inline=!1,d.insertBefore(P,x),t=P):this.options.flatpickr.wrap=!1}this.flatpickr=window.flatpickr(t,this.options.flatpickr),this.options.flatpickr.inline===!0&&this.options.flatpickr.inlineHideInput===!0&&this.input.setAttribute("type","hidden")}}},{key:"getValue",value:function(){if(this.dependenciesFulfilled){if(this.schema.type==="string")return this.value;if(this.value!==""&&this.value!==void 0){var t=this.schema.format==="time"?"1970-01-01 ".concat(this.value):this.value;return parseInt(new Date(t).getTime()/1e3)}}}},{key:"setValue",value:function(t,e,o){if(this.schema.type==="string")Dt(ft(l.prototype),"setValue",this).call(this,t,e,o),this.flatpickr&&this.flatpickr.setDate(t);else if(t>0){var u=new Date(1e3*t),d=u.getFullYear(),x=this.zeroPad(u.getMonth()+1),P=this.zeroPad(u.getDate()),D=this.zeroPad(u.getHours()),J=this.zeroPad(u.getMinutes()),nt=this.zeroPad(u.getSeconds()),ut=[d,x,P].join("-"),dt=[D,J,nt].join(":"),kt="".concat(ut,"T").concat(dt);this.schema.format==="date"?kt=ut:this.schema.format==="time"&&(kt=dt),this.input.value=kt,this.refreshValue(),this.flatpickr&&this.flatpickr.setDate(kt)}}},{key:"destroy",value:function(){this.flatpickr&&this.flatpickr.destroy(),this.flatpickr=null,Dt(ft(l.prototype),"destroy",this).call(this)}},{key:"zeroPad",value:function(t){return"0".concat(t).slice(-2)}}])&&mt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function Wt(c){return Wt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Wt(c)}function oe(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Wt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Wt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Wt(h)==="symbol"?h:String(h)),i)}var h}function Tt(){return Tt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Be(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Tt.apply(this,arguments)}function ue(c,n){return ue=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ue(c,n)}function Be(c){return Be=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Be(c)}var ir=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ue(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Be(i);if(h){var o=Be(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Wt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){if(this.editors){for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister();this.editors[this.currentEditor]&&this.editors[this.currentEditor].register()}Tt(Be(l.prototype),"register",this).call(this)}},{key:"unregister",value:function(){if(Tt(Be(l.prototype),"unregister",this).call(this),this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister()}},{key:"getNumColumns",value:function(){return this.editors[this.currentEditor]?Math.max(this.editors[this.currentEditor].getNumColumns(),4):4}},{key:"enable",value:function(){if(this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].enable();Tt(Be(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(){if(this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].disable();Tt(Be(l.prototype),"disable",this).call(this)}},{key:"switchEditor",value:function(){var t=this,e=this.getWatchedFieldValues();if(e){var o=document.location.origin+document.location.pathname+this.template(e);this.editors[this.refs[o]]||this.buildChildEditor(o),this.currentEditor=this.refs[o],this.register(),this.editors.forEach(function(u,d){u&&(t.currentEditor===d?u.container.style.display="":u.container.style.display="none")}),this.refreshValue(),this.onChange(!0)}}},{key:"buildChildEditor",value:function(t){this.refs[t]=this.editors.length;var e=this.theme.getChildEditorHolder();this.editor_holder.appendChild(e);var o=k({},this.schema,this.jsoneditor.refs[t]),u=this.jsoneditor.getEditorClass(o,this.jsoneditor),d=this.jsoneditor.createEditor(u,{jsoneditor:this.jsoneditor,schema:o,container:e,path:this.path,parent:this,required:!0});this.editors.push(d),d.preBuild(),d.build(),d.postBuild()}},{key:"preBuild",value:function(){var t;for(this.refs={},this.editors=[],this.currentEditor="",t=0;t<this.schema.links.length;t++)if(this.schema.links[t].rel.toLowerCase()==="describedby"){this.template=this.jsoneditor.compileTemplate(this.schema.links[t].href,this.template_engine);break}this.schema.links=this.schema.links.slice(0,t).concat(this.schema.links.slice(t+1)),this.schema.links.length===0&&delete this.schema.links,this.baseSchema=k({},this.schema)}},{key:"build",value:function(){this.editor_holder=document.createElement("div"),this.container.appendChild(this.editor_holder),this.switchEditor()}},{key:"onWatchedFieldChange",value:function(){this.switchEditor()}},{key:"onChildEditorChange",value:function(t){this.editors[this.currentEditor]&&this.refreshValue(),Tt(Be(l.prototype),"onChildEditorChange",this).call(this,t)}},{key:"refreshValue",value:function(){this.editors[this.currentEditor]&&(this.value=this.editors[this.currentEditor].getValue())}},{key:"setValue",value:function(t,e){this.editors[this.currentEditor]&&(this.editors[this.currentEditor].setValue(t,e),this.refreshValue(),this.onChange())}},{key:"destroy",value:function(){this.editors.forEach(function(t){t&&t.destroy()}),this.editor_holder&&this.editor_holder.parentNode&&this.editor_holder.parentNode.removeChild(this.editor_holder),Tt(Be(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){this.editors.forEach(function(e){e&&e.showValidationErrors(t)})}}])&&oe(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function It(c){return It=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},It(c)}function ee(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function zt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(It(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(It(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),It(h)==="symbol"?h:String(h)),i)}var h}function me(){return me=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Oe(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},me.apply(this,arguments)}function Ue(c,n){return Ue=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ue(c,n)}function Oe(c){return Oe=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Oe(c)}var $e=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ue(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Oe(i);if(h){var o=Oe(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(It(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 4}},{key:"build",value:function(){var t=this;this.title=this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired()),this.container.appendChild(this.title),this.options.enum_titles=this.options.enum_titles||[],this.enum=this.schema.enum,this.selected=0,this.select_options=[],this.html_values=[];for(var e=0;e<this.enum.length;e++)this.select_options[e]=this.options.enum_titles[e]||"Value ".concat(e+1),this.html_values[e]=this.getHTML(this.enum[e]);this.switcher=this.theme.getSwitcher(this.select_options),this.container.appendChild(this.switcher),this.display_area=this.theme.getIndentedPanel(),this.container.appendChild(this.display_area),this.options.hide_display&&(this.display_area.style.display="none"),this.switcher.addEventListener("change",function(o){t.selected=t.select_options.indexOf(o.currentTarget.value),t.value=t.enum[t.selected],t.refreshValue(),t.onChange(!0)}),this.value=this.enum[0],this.refreshValue(),this.enum.length===1&&(this.switcher.style.display="none")}},{key:"refreshValue",value:function(){var t=this;this.selected=-1;var e=JSON.stringify(this.value);this.enum.forEach(function(o,u){if(e===JSON.stringify(o))return t.selected=u,!1}),this.selected<0?this.setValue(this.enum[0]):(this.switcher.value=this.select_options[this.selected],this.display_area.innerHTML=this.html_values[this.selected])}},{key:"enable",value:function(){this.always_disabled||(this.switcher.disabled=!1,me(Oe(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.switcher.disabled=!0,me(Oe(l.prototype),"disable",this).call(this)}},{key:"getHTML",value:function(t){var e,o,u=this;if(t===null)return"<em>null</em>";if(It(t)==="object"){var d="";return e=t,o=function(x,P){var D=u.getHTML(P);Array.isArray(t)||(D="<div><em>".concat(x,"</em>: ").concat(D,"</div>")),d+="<li>".concat(D,"</li>")},Array.isArray(e)||typeof e.length=="number"&&e.length>0&&e.length-1 in e?Array.from(e).forEach(function(x,P){return o(P,x)}):Object.entries(e).forEach(function(x){var P,D,J=(D=2,function(dt){if(Array.isArray(dt))return dt}(P=x)||function(dt,kt){var Ct=dt==null?null:typeof Symbol<"u"&&dt[Symbol.iterator]||dt["@@iterator"];if(Ct!=null){var $t,ne,Re,Gt,gt=[],Zt=!0,Ge=!1;try{if(Re=(Ct=Ct.call(dt)).next,kt===0){if(Object(Ct)!==Ct)return;Zt=!1}else for(;!(Zt=($t=Re.call(Ct)).done)&&(gt.push($t.value),gt.length!==kt);Zt=!0);}catch(W){Ge=!0,ne=W}finally{try{if(!Zt&&Ct.return!=null&&(Gt=Ct.return(),Object(Gt)!==Gt))return}finally{if(Ge)throw ne}}return gt}}(P,D)||function(dt,kt){if(dt){if(typeof dt=="string")return ee(dt,kt);var Ct=Object.prototype.toString.call(dt).slice(8,-1);return Ct==="Object"&&dt.constructor&&(Ct=dt.constructor.name),Ct==="Map"||Ct==="Set"?Array.from(dt):Ct==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Ct)?ee(dt,kt):void 0}}(P,D)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
75
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()),nt=J[0],ut=J[1];return o(nt,ut)}),d=Array.isArray(t)?"<ol>".concat(d,"</ol>"):"<ul style='margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0;'>".concat(d,"</ul>")}return typeof t=="boolean"?t?"true":"false":typeof t=="string"?t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"):t}},{key:"setValue",value:function(t){this.value!==t&&(this.value=t,this.refreshValue(),this.onChange())}},{key:"destroy",value:function(){this.display_area&&this.display_area.parentNode&&this.display_area.parentNode.removeChild(this.display_area),this.title&&this.title.parentNode&&this.title.parentNode.removeChild(this.title),this.switcher&&this.switcher.parentNode&&this.switcher.parentNode.removeChild(this.switcher),me(Oe(l.prototype),"destroy",this).call(this)}}])&&zt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function _e(c){return _e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},_e(c)}function mr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(_e(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(_e(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),_e(h)==="symbol"?h:String(h)),i)}var h}function Me(){return Me=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Pr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Me.apply(this,arguments)}function Fr(c,n){return Fr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Fr(c,n)}function Pr(c){return Pr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Pr(c)}var fs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Fr(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Pr(i);if(h){var o=Pr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(_e(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){Me(Pr(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){Me(Pr(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"setValue",value:function(t,e,o){if((!this.template||o)&&(t==null?t="":_e(t)==="object"?t=JSON.stringify(t):typeof t!="string"&&(t="".concat(t)),t!==this.serialized)){var u=this.sanitize(t);if(this.input.value!==u){this.input.value=u;var d=o||this.getValue()!==t;this.refreshValue(),e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.adjust_height&&this.adjust_height(this.input),this.onChange(d)}}}},{key:"getNumColumns",value:function(){return 2}},{key:"enable",value:function(){Me(Pr(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(){Me(Pr(l.prototype),"disable",this).call(this)}},{key:"refreshValue",value:function(){this.value=this.input.value,typeof this.value!="string"&&(this.value=""),this.serialized=this.value}},{key:"destroy",value:function(){this.template=null,this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),Me(Pr(l.prototype),"destroy",this).call(this)}},{key:"sanitize",value:function(t){return t}},{key:"onWatchedFieldChange",value:function(){var t;this.template&&(t=this.getWatchedFieldValues(),this.setValue(this.template(t),!1,!0)),Me(Pr(l.prototype),"onWatchedFieldChange",this).call(this)}},{key:"build",value:function(){if(this.format=this.schema.format,!this.format&&this.options.default_format&&(this.format=this.options.default_format),this.options.format&&(this.format=this.options.format),this.input_type="hidden",this.input=this.theme.getFormInputField(this.input_type),this.format&&this.input.setAttribute("data-schemaformat",this.format),this.container.appendChild(this.input),this.schema.template){var t=this.expandCallbacks("template",{template:this.schema.template});typeof t.template=="function"?this.template=t.template:this.template=this.jsoneditor.compileTemplate(this.schema.template,this.template_engine),this.refreshValue()}else this.refreshValue()}}])&&mr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Zr(c){return Zr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Zr(c)}function yl(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Zr(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Zr(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Zr(h)==="symbol"?h:String(h)),i)}var h}function Ui(c,n){return Ui=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ui(c,n)}function Vr(c){return Vr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Vr(c)}var qi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ui(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Vr(i);if(h){var o=Vr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Zr(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){this.options.compact=!1,this.header=this.label=this.theme.getFormInputLabel(this.getTitle()),this.description=this.theme.getDescription(this.schema.description||""),this.control=this.theme.getFormControl(this.label,this.description,null),this.container.appendChild(this.control)}},{key:"getTitle",value:function(){return this.translateProperty(this.schema.title)}},{key:"getNumColumns",value:function(){return 12}}])&&yl(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hs);function jn(c){return jn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},jn(c)}function ms(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(jn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(jn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),jn(h)==="symbol"?h:String(h)),i)}var h}function Gi(){return Gi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Fn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Gi.apply(this,arguments)}function Wi(c,n){return Wi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Wi(c,n)}function Fn(c){return Fn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Fn(c)}var ys=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Wi(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Fn(i);if(h){var o=Fn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(jn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){if(Gi(Fn(l.prototype),"build",this).call(this),this.schema.minimum!==void 0){var t=this.schema.minimum;this.schema.exclusiveMinimum!==void 0&&(t+=1),this.input.setAttribute("min",t)}if(this.schema.maximum!==void 0){var e=this.schema.maximum;this.schema.exclusiveMaximum!==void 0&&(e-=1),this.input.setAttribute("max",e)}if(this.schema.step!==void 0){var o=this.schema.step||1;this.input.setAttribute("step",o)}this.setInputAttributes(["maxlength","pattern","readonly","min","max","step"])}},{key:"getNumColumns",value:function(){return 2}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.schema.default||this.jsoneditor.options.use_default_values||this.value!==""?function(t){if(t==null)return!1;var e=t.match(T),o=parseFloat(t);return e!==null&&!isNaN(o)&&isFinite(o)}(this.value)?parseFloat(this.value):this.value:void(this.shouldBeUnset()&&(this.input.value=""))}}])&&ms(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function zr(c){return zr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},zr(c)}function di(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(zr(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(zr(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),zr(h)==="symbol"?h:String(h)),i)}var h}function Jr(c,n){return Jr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Jr(c,n)}function Zi(c){return Zi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Zi(c)}var bs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Jr(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Zi(i);if(h){var o=Zi(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(zr(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 2}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.schema.default||this.jsoneditor.options.use_default_values||this.value!==""?function(t){if(t==null)return!1;var e=t.match(A),o=parseInt(t);return e!==null&&!isNaN(o)&&isFinite(o)}(this.value)?parseInt(this.value):this.value:void this.shouldBeUnset()}}])&&di(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(ys);function Vn(c){return Vn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Vn(c)}function Ji(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Vn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Vn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Vn(h)==="symbol"?h:String(h)),i)}var h}function sn(){return sn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Yr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},sn.apply(this,arguments)}function zn(c,n){return zn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},zn(c,n)}function Yr(c){return Yr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Yr(c)}var ra=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&zn(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Yr(i);if(h){var o=Yr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Vn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"preBuild",value:function(){if(sn(Yr(l.prototype),"preBuild",this).call(this),this.schema.options||(this.schema.options={}),!this.schema.options.cleave)switch(this.format){case"ipv6":this.schema.options.cleave={delimiters:[":"],blocks:[4,4,4,4,4,4,4,4],uppercase:!0};break;case"ipv4":this.schema.options.cleave={delimiters:["."],blocks:[3,3,3,3],numericOnly:!0}}this.options=k(this.options,this.schema.options||{})}}])&&Ji(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function Un(c){return Un=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Un(c)}function bl(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Un(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Un(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Un(h)==="symbol"?h:String(h)),i)}var h}function Xr(){return Xr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Tr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Xr.apply(this,arguments)}function Yi(c,n){return Yi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Yi(c,n)}function Tr(c){return Tr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Tr(c)}var vs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Yi(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Tr(i);if(h){var o=Tr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Un(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=Xr(Tr(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.jodit_instance&&this.jodit_instance.setEditorValue(u.value)}},{key:"build",value:function(){this.options.format="textarea",Xr(Tr(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t,e=this;window.Jodit?(t=this.expandCallbacks("jodit",k({},{height:300},this.defaults.options.jodit||{},this.options.jodit||{})),this.jodit_instance=new window.Jodit(this.input,t),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&this.jodit_instance.setReadOnly(!0),this.jodit_instance.events.on("change",function(){e.value=e.jodit_instance.getEditorValue(),e.is_dirty=!0,e.onChange(!0)}),this.theme.afterInputReady(this.input)):Xr(Tr(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.jodit_instance&&this.jodit_instance.setReadOnly(!1),Xr(Tr(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.jodit_instance&&this.jodit_instance.setReadOnly(!0),Xr(Tr(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.jodit_instance&&(this.jodit_instance.destruct(),this.jodit_instance=null),Xr(Tr(l.prototype),"destroy",this).call(this)}}])&&bl(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K),gs=(_(6541),_(9337),_(3321),function(c){var n=c.split(".");if(n.length!==4)throw new Error("error_ipv4");n.forEach(function(f){if(isNaN(+f)||+f<0||+f>255)throw new Error("error_ipv4")})}),na=function(c){if(!c.match("^(?:(?:(?:[a-fA-F0-9]{1,4}:){6}|(?=(?:[a-fA-F0-9]{0,4}:){2,6}(?:[0-9]{1,3}.){3}[0-9]{1,3}$)(([0-9a-fA-F]{1,4}:){1,5}|:)((:[0-9a-fA-F]{1,4}){1,5}:|:)|::(?:[a-fA-F0-9]{1,4}:){5})(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9])|(?:[a-fA-F0-9]{1,4}:){7}[a-fA-F0-9]{1,4}|(?=(?:[a-fA-F0-9]{0,4}:){0,7}[a-fA-F0-9]{0,4}$)(([0-9a-fA-F]{1,4}:){1,7}|:)((:[0-9a-fA-F]{1,4}){1,7}|:)|(?:[a-fA-F0-9]{1,4}:){7}:|:(:[a-fA-F0-9]{1,4}){7})$"))throw new Error("error_ipv6")},ia=function(c){if(!c.match("(?=^.{4,253}$)(^((?!-)[a-zA-Z0-9-]{0,62}[a-zA-Z0-9].)+[a-zA-Z]{2,63}$)"))throw new Error("error_hostname")};function oa(c,n,f,i){try{switch(c.format){case"ipv4":gs(n);break;case"ipv6":na(n);break;case"hostname":ia(n)}return[]}catch(h){return[{path:f,property:"format",message:i(h.message)}]}}function Xi(c,n){var f=Object.keys(c);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(c);n&&(i=i.filter(function(h){return Object.getOwnPropertyDescriptor(c,h).enumerable})),f.push.apply(f,i)}return f}function aa(c,n,f){return(n=Ki(n))in c?Object.defineProperty(c,n,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[n]=f,c}function pi(c,n){return function(f){if(Array.isArray(f))return f}(c)||function(f,i){var h=f==null?null:typeof Symbol<"u"&&f[Symbol.iterator]||f["@@iterator"];if(h!=null){var a,l,t,e,o=[],u=!0,d=!1;try{if(t=(h=h.call(f)).next,i===0){if(Object(h)!==h)return;u=!1}else for(;!(u=(a=t.call(h)).done)&&(o.push(a.value),o.length!==i);u=!0);}catch(x){d=!0,l=x}finally{try{if(!u&&h.return!=null&&(e=h.return(),Object(e)!==e))return}finally{if(d)throw l}}return o}}(c,n)||fi(c,n)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
76
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function yr(c){return yr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},yr(c)}function
|
|
77
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function fi(c,n){if(c){if(typeof c=="string")return mi(c,n);var f=Object.prototype.toString.call(c).slice(8,-1);return f==="Object"&&c.constructor&&(f=c.constructor.name),f==="Map"||f==="Set"?Array.from(c):f==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(f)?mi(c,n):void 0}}function mi(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function sa(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,Ki(i.key),i)}}function Ki(c){var n=function(f,i){if(yr(f)!=="object"||f===null)return f;var h=f[Symbol.toPrimitive];if(h!==void 0){var a=h.call(f,"string");if(yr(a)!=="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(f)}(c);return yr(n)==="symbol"?n:String(n)}var Qi=function(){function c(i,h,a,l){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,c),this.jsoneditor=i,this.schema=h||this.jsoneditor.schema,this.options=a||{},this.translate=this.jsoneditor.translate||l.translate,this.translateProperty=this.jsoneditor.translateProperty||l.translateProperty,this.defaults=l,this._validateSubSchema={dependentRequired:function(t,e,o){var u=[];if(t.dependentRequired!==void 0){var d=[];Object.keys(t.dependentRequired).forEach(function(x){if(e[x]!==void 0){var P=t.dependentRequired[x];d=P.filter(function(D){return!S(e,D)})}}),d.length>0&&u.push({message:"Must have the required properties: "+d.join(", "),path:o})}return u},dependentSchemas:function(t,e,o){var u=this,d=[];return Object.keys(t.dependentSchemas).forEach(function(x){if(e[x]!==void 0){var P=t.dependentSchemas[x],D=u._validateSchema(P,e,o);d=[].concat(xe(d),xe(D))}}),d},contains:function(t,e,o){var u=this,d=[],x=0;e.forEach(function(D){u._validateSchema(t.contains,D,o).length===0&&x++});var P=x===0;return t.minContains!==void 0?x<t.minContains&&d.push({message:this.translate("error_minContains",[x,t.minContains],t),path:o}):P&&d.push({message:this.translate("error_contains",null,t),path:o}),t.maxContains!==void 0&&x>t.maxContains&&d.push({message:this.translate("error_maxContains",[x,t.maxContains],t),path:o}),d},if:function(t,e,o){if(t.then===void 0&&t.else===void 0)return[];var u=this._validateSchema(t.if,e,o),d=[],x=[];return t.then!==void 0&&(d=this._validateSchema(t.then,e,o)),t.else!==void 0&&(x=this._validateSchema(t.else,e,o)),t.if===!0?d:t.if===!1?x:u.length===0?d:u.length>0?x:[]},const:function(t,e,o){return JSON.stringify(t.const)!==JSON.stringify(e)||Array.isArray(e)||yr(e)==="object"?[{path:o,property:"const",message:this.translate("error_const",null,t)}]:[]},enum:function(t,e,o){var u=JSON.stringify(e);return t.enum.some(function(d){return u===JSON.stringify(d)})?[]:[{path:o,property:"enum",message:this.translate("error_enum",null,t)}]},extends:function(t,e,o){var u=this;return t.extends.reduce(function(d,x){return d.push.apply(d,xe(u._validateSchema(x,e,o))),d},[])},allOf:function(t,e,o){var u=this;return t.allOf.reduce(function(d,x){return d.push.apply(d,xe(u._validateSchema(x,e,o))),d},[])},anyOf:function(t,e,o){var u=this;return t.anyOf.some(function(d){return!u._validateSchema(d,e,o).length})?[]:[{path:o,property:"anyOf",message:this.translate("error_anyOf",null,t)}]},oneOf:function(t,e,o){var u=this,d=0,x=[];t.oneOf.forEach(function(D,J){var nt=u._validateSchema(D,e,o);nt.length||d++,nt.forEach(function(ut){ut.path="".concat(o,".oneOf[").concat(J,"]").concat(ut.path.substr(o.length))}),x.push.apply(x,xe(nt))});var P=[];return d!==1&&(P.push({path:o,property:"oneOf",message:this.translate("error_oneOf",[d],t)}),P.push.apply(P,x)),P},not:function(t,e,o){return this._validateSchema(t.not,e,o).length?[]:[{path:o,property:"not",message:this.translate("error_not",null,t)}]},type:function(t,e,o){var u=this;if(Array.isArray(t.type)){if(!t.type.some(function(d){return u._checkType(d,e)}))return[{path:o,property:"type",message:this.translate("error_type_union",null,t)}]}else if(["date","time","datetime-local"].includes(t.format)&&t.type==="integer"){if(!this._checkType("string","".concat(e)))return[{path:o,property:"type",message:this.translate("error_type",[t.format],t)}]}else if(!this._checkType(t.type,e))return[{path:o,property:"type",message:this.translate("error_type",[t.type],t)}];return[]},disallow:function(t,e,o){var u=this;if(Array.isArray(t.disallow)){if(t.disallow.some(function(d){return u._checkType(d,e)}))return[{path:o,property:"disallow",message:this.translate("error_disallow_union",null,t)}]}else if(this._checkType(t.disallow,e))return[{path:o,property:"disallow",message:this.translate("error_disallow",[t.disallow],t)}];return[]}},this._validateNumberSubSchema={multipleOf:function(t,e,o){return this._validateNumberSubSchemaMultipleDivisible(t,e,o)},divisibleBy:function(t,e,o){return this._validateNumberSubSchemaMultipleDivisible(t,e,o)},maximum:function(t,e,o){var u=t.exclusiveMaximum?e<t.maximum:e<=t.maximum;return window.math?u=window.math[t.exclusiveMaximum?"smaller":"smallerEq"](window.math.bignumber(e),window.math.bignumber(t.maximum)):window.Decimal&&(u=new window.Decimal(e)[t.exclusiveMaximum?"lt":"lte"](new window.Decimal(t.maximum))),u?[]:[{path:o,property:"maximum",message:this.translate(t.exclusiveMaximum?"error_maximum_excl":"error_maximum_incl",[t.maximum],t)}]},minimum:function(t,e,o){var u=t.exclusiveMinimum?e>t.minimum:e>=t.minimum;return window.math?u=window.math[t.exclusiveMinimum?"larger":"largerEq"](window.math.bignumber(e),window.math.bignumber(t.minimum)):window.Decimal&&(u=new window.Decimal(e)[t.exclusiveMinimum?"gt":"gte"](new window.Decimal(t.minimum))),u?[]:[{path:o,property:"minimum",message:this.translate(t.exclusiveMinimum?"error_minimum_excl":"error_minimum_incl",[t.minimum],t)}]}},this._validateStringSubSchema={maxLength:function(t,e,o){var u=[];return"".concat(e).length>t.maxLength&&u.push({path:o,property:"maxLength",message:this.translate("error_maxLength",[t.maxLength],t)}),u},minLength:function(t,e,o){return"".concat(e).length<t.minLength?[{path:o,property:"minLength",message:this.translate(t.minLength===1?"error_notempty":"error_minLength",[t.minLength],t)}]:[]},pattern:function(t,e,o){return new RegExp(t.pattern).test(e)?[]:[{path:o,property:"pattern",message:t.options&&t.options.patternmessage?t.options.patternmessage:this.translate("error_pattern",[t.pattern],t)}]}},this._validateArraySubSchema={items:function(t,e,o){var u=this,d=[];if(Array.isArray(t.items))for(var x=0;x<e.length;x++)if(t.items[x])d.push.apply(d,xe(this._validateSchema(t.items[x],e[x],"".concat(o,".").concat(x))));else{if(t.additionalItems===!0)break;if(!t.additionalItems){if(t.additionalItems===!1){d.push({path:o,property:"additionalItems",message:this.translate("error_additionalItems",null,t)});break}break}d.push.apply(d,xe(this._validateSchema(t.additionalItems,e[x],"".concat(o,".").concat(x))))}else e.forEach(function(P,D){d.push.apply(d,xe(u._validateSchema(t.items,P,"".concat(o,".").concat(D))))});return d},maxItems:function(t,e,o){return e.length>t.maxItems?[{path:o,property:"maxItems",message:this.translate("error_maxItems",[t.maxItems],t)}]:[]},minItems:function(t,e,o){return e.length<t.minItems?[{path:o,property:"minItems",message:this.translate("error_minItems",[t.minItems],t)}]:[]},uniqueItems:function(t,e,o){for(var u={},d=0;d<e.length;d++){var x=JSON.stringify(e[d]);if(u[x])return[{path:o,property:"uniqueItems",message:this.translate("error_uniqueItems",null,t)}];u[x]=!0}return[]}},this._validateObjectSubSchema={maxProperties:function(t,e,o){return Object.keys(e).length>t.maxProperties?[{path:o,property:"maxProperties",message:this.translate("error_maxProperties",[t.maxProperties],t)}]:[]},minProperties:function(t,e,o){return Object.keys(e).length<t.minProperties?[{path:o,property:"minProperties",message:this.translate("error_minProperties",[t.minProperties],t)}]:[]},required:function(t,e,o){var u=this,d=[];return Array.isArray(t.required)&&t.required.forEach(function(x){if(e[x]===void 0){var P=u.jsoneditor.getEditor("".concat(o,".").concat(x));P&&P.dependenciesFulfilled===!1||P&&["button","info"].includes(P.schema.format||P.schema.type)||d.push({path:o,property:"required",message:u.translate("error_required",[t&&t.properties&&t.properties[x]&&t.properties[x].title?t.properties[x].title:x],t)})}}),d},properties:function(t,e,o,u){var d=this,x=[];return Object.entries(t.properties).forEach(function(P){var D=pi(P,2),J=D[0],nt=D[1];u[J]=!0,x.push.apply(x,xe(d._validateSchema(nt,e[J],"".concat(o,".").concat(J))))}),x},patternProperties:function(t,e,o,u){var d=this,x=[];return Object.entries(t.patternProperties).forEach(function(P){var D=pi(P,2),J=D[0],nt=D[1],ut=new RegExp(J);Object.entries(e).forEach(function(dt){var kt=pi(dt,2),Ct=kt[0],$t=kt[1];ut.test(Ct)&&(u[Ct]=!0,x.push.apply(x,xe(d._validateSchema(nt,$t,"".concat(o,".").concat(Ct)))))})}),x}},this._validateObjectSubSchema2={propertyNames:function(t,e,o,u){for(var d=this,x=[],P=Object.keys(e),D=null,J=function(){var dt="";return D=P[nt],typeof t.propertyNames=="boolean"?t.propertyNames===!0?"continue":(x.push({path:o,property:"propertyNames",message:d.translate("error_property_names_false",[D],t)}),"break"):Object.entries(t.propertyNames).every(function(kt){var Ct=pi(kt,2),$t=Ct[0],ne=Ct[1],Re=!1;switch($t){case"maxLength":if(typeof ne!="number"){dt="error_property_names_maxlength";break}if(D.length>ne){dt="error_property_names_exceeds_maxlength";break}return!0;case"const":if(ne!==D){dt="error_property_names_const_mismatch";break}return!0;case"enum":if(!Array.isArray(ne)){dt="error_property_names_enum";break}if(ne.forEach(function(Gt){Gt===D&&(Re=!0)}),!Re){dt="error_property_names_enum_mismatch";break}return!0;case"pattern":if(typeof ne!="string"){dt="error_property_names_pattern";break}if(!new RegExp(ne).test(D)){dt="error_property_names_pattern_mismatch";break}return!0;default:return x.push({path:o,property:"propertyNames",message:d.translate("error_property_names_unsupported",[$t],t)}),!1}return x.push({path:o,property:"propertyNames",message:d.translate(dt,[D],t)}),!1})?void 0:"break"},nt=0;nt<P.length;nt++){var ut=J();if(ut!=="continue"&&ut==="break")break}return x},additionalProperties:function(t,e,o,u){for(var d=[],x=Object.keys(e),P=0;P<x.length;P++){var D=x[P];if(!u[D]){if(!t.additionalProperties){d.push({path:o,property:"additionalProperties",message:this.translate("error_additional_properties",[D],t)});break}if(t.additionalProperties===!0)break;d.push.apply(d,xe(this._validateSchema(t.additionalProperties,e[D],"".concat(o,".").concat(D))))}}return d},dependencies:function(t,e,o){var u=this,d=[];return Object.entries(t.dependencies).forEach(function(x){var P=pi(x,2),D=P[0],J=P[1];e[D]!==void 0&&(Array.isArray(J)?J.forEach(function(nt){e[nt]===void 0&&d.push({path:o,property:"dependencies",message:u.translate("error_dependency",[nt],t)})}):d.push.apply(d,xe(u._validateSchema(J,e,o))))}),d}}}var n,f;return n=c,f=[{key:"fitTest",value:function(i,h){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1e7,l={match:0,extra:0};if(yr(i)==="object"&&i!==null){var t=this._getSchema(h);if(t.anyOf){var e,o=function(nt){for(var ut=1;ut<arguments.length;ut++){var dt=arguments[ut]!=null?arguments[ut]:{};ut%2?Xi(Object(dt),!0).forEach(function(kt){aa(nt,kt,dt[kt])}):Object.getOwnPropertyDescriptors?Object.defineProperties(nt,Object.getOwnPropertyDescriptors(dt)):Xi(Object(dt)).forEach(function(kt){Object.defineProperty(nt,kt,Object.getOwnPropertyDescriptor(dt,kt))})}return nt}({},l),u=function(nt,ut){var dt=typeof Symbol<"u"&&nt[Symbol.iterator]||nt["@@iterator"];if(!dt){if(Array.isArray(nt)||(dt=fi(nt))){dt&&(nt=dt);var kt=0,Ct=function(){};return{s:Ct,n:function(){return kt>=nt.length?{done:!0}:{done:!1,value:nt[kt++]}},e:function(Gt){throw Gt},f:Ct}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
78
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var $t,ne=!0,Re=!1;return{s:function(){dt=dt.call(nt)},n:function(){var Gt=dt.next();return ne=Gt.done,Gt},e:function(Gt){Re=!0,$t=Gt},f:function(){try{ne||dt.return==null||dt.return()}finally{if(Re)throw $t}}}}(t.anyOf);try{for(u.s();!(e=u.n()).done;){var d=e.value,x=this.fitTest(i,d,a);(x.match>o.match||x.match===o.match&&x.extra<o.extra)&&(o=x)}}catch(nt){u.e(nt)}finally{u.f()}return o}var P=this._getSchema(h).properties;for(var D in P)if(S(P,D)){if(yr(i[D])==="object"&&yr(P[D])==="object"&&yr(P[D].properties)==="object"){var J=this.fitTest(i[D],P[D],a/100);l.match+=J.match,l.extra+=J.extra}i[D]!==void 0&&(l.match+=a)}else l.extra+=a}return l}},{key:"_getSchema",value:function(i){return i===void 0?k({},this.jsoneditor.expandRefs(this.schema)):i}},{key:"validate",value:function(i){return this._validateSchema(this.schema,i)}},{key:"_validateSchema",value:function(i,h,a){var l=this,t=[];return a=a||this.jsoneditor.root.formname,i=k({},this.jsoneditor.expandRefs(i)),h===void 0?this._validateV3Required(i,h,a):(Object.keys(i).forEach(function(e){l._validateSubSchema[e]&&t.push.apply(t,xe(l._validateSubSchema[e].call(l,i,h,a)))}),t.push.apply(t,xe(this._validateByValueType(i,h,a))),i.links&&i.links.forEach(function(e,o){e.rel&&e.rel.toLowerCase()==="describedby"&&(i=l._expandSchemaLink(i,o),t.push.apply(t,xe(l._validateSchema(i,h,a,l.translate))))}),["date","time","datetime-local"].includes(i.format)&&t.push.apply(t,xe(this._validateDateTimeSubSchema(i,h,a))),["uuid"].includes(i.format)&&t.push.apply(t,xe(this._validateUUIDSchema(i,h,a))),t.push.apply(t,xe(this._validateCustomValidator(i,h,a))),this._removeDuplicateErrors(t))}},{key:"_expandSchemaLink",value:function(i,h){var a=i.links[h].href,l=this.jsoneditor.root.getValue(),t=this.jsoneditor.compileTemplate(a,this.jsoneditor.template),e=document.location.origin+document.location.pathname+t(l);return i.links=i.links.slice(0,h).concat(i.links.slice(h+1)),k({},i,this.jsoneditor.refs[e])}},{key:"_validateV3Required",value:function(i,h,a){return(i.required!==void 0&&i.required===!0||i.required===void 0&&this.jsoneditor.options.required_by_default===!0)&&i.type!=="info"?[{path:a,property:"required",message:this.translate("error_notset",null,i)}]:[]}},{key:"_validateByValueType",value:function(i,h,a){var l=this,t=[];if(h===null)return t;if(typeof h=="number")Object.keys(i).forEach(function(o){l._validateNumberSubSchema[o]&&t.push.apply(t,xe(l._validateNumberSubSchema[o].call(l,i,h,a)))});else if(typeof h=="string")Object.keys(i).forEach(function(o){l._validateStringSubSchema[o]&&t.push.apply(t,xe(l._validateStringSubSchema[o].call(l,i,h,a)))});else if(Array.isArray(h))Object.keys(i).forEach(function(o){l._validateArraySubSchema[o]&&t.push.apply(t,xe(l._validateArraySubSchema[o].call(l,i,h,a)))});else if(yr(h)==="object"){var e={};Object.keys(i).forEach(function(o){l._validateObjectSubSchema[o]&&t.push.apply(t,xe(l._validateObjectSubSchema[o].call(l,i,h,a,e)))}),i.additionalProperties!==void 0||!this.jsoneditor.options.no_additional_properties||i.oneOf||i.anyOf||i.allOf||(i.additionalProperties=!1),Object.keys(i).forEach(function(o){l._validateObjectSubSchema2[o]!==void 0&&t.push.apply(t,xe(l._validateObjectSubSchema2[o].call(l,i,h,a,e)))})}return t}},{key:"_validateUUIDSchema",value:function(i,h,a){return/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(h)?[]:[{path:a,property:"format",message:this.translate("error_pattern",["^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"],i)}]}},{key:"_validateNumberSubSchemaMultipleDivisible",value:function(i,h,a){var l=i.multipleOf||i.divisibleBy,t=h/l===Math.floor(h/l);return window.math?t=window.math.mod(window.math.bignumber(h),window.math.bignumber(l)).equals(0):window.Decimal&&(t=new window.Decimal(h).mod(new window.Decimal(l)).equals(0)),t?[]:[{path:a,property:i.multipleOf?"multipleOf":"divisibleBy",message:this.translate("error_multipleOf",[l],i)}]}},{key:"_validateDateTimeSubSchema",value:function(i,h,a){var l=this,t=this.jsoneditor.getEditor(a),e=t&&t.flatpickr?t.flatpickr.config.dateFormat:{date:'"YYYY-MM-DD"',time:'"HH:MM"',"datetime-local":'"YYYY-MM-DD HH:MM"'}[i.format];if(i.type==="integer")return function(o,u,d){return 1*u<1?[{path:d,property:"format",message:l.translate("error_invalid_epoch",null,o)}]:u!==Math.abs(parseInt(u))?[{path:d,property:"format",message:l.translate("error_".concat(o.format.replace(/-/g,"_")),[e],o)}]:[]}(i,h,a);if(t&&t.flatpickr){if(t)return function(o,u,d,x){if(u!==""){var P;if(x.flatpickr.config.mode!=="single"){var D=x.flatpickr.config.mode==="range"?x.flatpickr.l10n.rangeSeparator:", ";P=x.flatpickr.selectedDates.map(function(nt){return x.flatpickr.formatDate(nt,x.flatpickr.config.dateFormat)}).join(D)}try{if(P){if(P!==u)throw new Error("".concat(x.flatpickr.config.mode," mismatch"))}else if(x.flatpickr.formatDate(x.flatpickr.parseDate(u,x.flatpickr.config.dateFormat),x.flatpickr.config.dateFormat)!==u)throw new Error("mismatch")}catch{var J=x.flatpickr.config.errorDateFormat!==void 0?x.flatpickr.config.errorDateFormat:x.flatpickr.config.dateFormat;return[{path:d,property:"format",message:l.translate("error_".concat(x.format.replace(/-/g,"_")),[J],o)}]}}return[]}(i,h,a,t)}else if(!{date:/^(\d{4}\D\d{2}\D\d{2})?$/,time:/^(\d{2}:\d{2}(?::\d{2})?)?$/,"datetime-local":/^(\d{4}\D\d{2}\D\d{2}[ T]\d{2}:\d{2}(?::\d{2})?)?$/}[i.format].test(h))return[{path:a,property:"format",message:this.translate("error_".concat(i.format.replace(/-/g,"_")),[e],i)}];return[]}},{key:"_validateCustomValidator",value:function(i,h,a){var l=this,t=[];t.push.apply(t,xe(oa.call(this,i,h,a,this.translate)));var e=function(o){t.push.apply(t,xe(o.call(l,i,h,a)))};return this.defaults.custom_validators.forEach(e),this.options.custom_validators&&this.options.custom_validators.forEach(e),t}},{key:"_removeDuplicateErrors",value:function(i){return i.reduce(function(h,a){var l=!0;return h||(h=[]),h.forEach(function(t){t.message===a.message&&t.path===a.path&&t.property===a.property&&(t.errorcount++,l=!1)}),l&&(a.errorcount=1,h.push(a)),h},[])}},{key:"_checkType",value:function(i,h){var a={string:function(l){return typeof l=="string"},number:function(l){return typeof l=="number"},integer:function(l){return typeof l=="number"&&l===Math.floor(l)},boolean:function(l){return typeof l=="boolean"},array:function(l){return Array.isArray(l)},object:function(l){return l!==null&&!Array.isArray(l)&&yr(l)==="object"},null:function(l){return l===null}};return typeof i=="string"?!a[i]||a[i](h):!this._validateSchema(i,h).length}}],f&&sa(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function qe(c){return qe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},qe(c)}function Ur(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(qe(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(qe(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),qe(h)==="symbol"?h:String(h)),i)}var h}function ln(){return ln=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=br(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},ln.apply(this,arguments)}function la(c,n){return la=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},la(c,n)}function br(c){return br=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},br(c)}var to=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&la(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=br(i);if(h){var o=br(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(qe(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){if(this.editors){for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister();this.editors[this.type]&&this.editors[this.type].register()}ln(br(l.prototype),"register",this).call(this)}},{key:"unregister",value:function(){if(ln(br(l.prototype),"unregister",this).call(this),this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister()}},{key:"getNumColumns",value:function(){return this.editors[this.type]?Math.max(this.editors[this.type].getNumColumns(),4):4}},{key:"enable",value:function(){if(!this.always_disabled){if(this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].enable();this.switcher.disabled=!1,ln(br(l.prototype),"enable",this).call(this)}}},{key:"disable",value:function(t){if(t&&(this.always_disabled=!0),this.editors)for(var e=0;e<this.editors.length;e++)this.editors[e]&&this.editors[e].disable(t);this.switcher.disabled=!0,ln(br(l.prototype),"disable",this).call(this)}},{key:"switchEditor",value:function(t){var e=this;this.lastType=this.type,this.editors[t]||this.buildChildEditor(t);var o=this.getValue();this.type=t,this.register(),this.editors.forEach(function(u,d){var x,P;u&&(e.type===d?(e.keep_only_existing_values&&(x=u.getValue(),P=o,Object.keys(P).forEach(function(D){D in x&&(x[D]=P[D])}),o=x),(e.keep_values||e.if)&&u.setValue(o,!0),u.container.style.display=""):u.container.style.display="none")}),this.refreshValue(),this.refreshHeaderText()}},{key:"buildChildEditor",value:function(t){var e,o=this,u=this.types[t],d=this.theme.getChildEditorHolder();this.editor_holder.appendChild(d),typeof u=="string"?(e=k({},this.schema)).type=u:(e=k({},this.schema,u),e=this.jsoneditor.expandRefs(e),u&&u.required&&Array.isArray(u.required)&&this.schema.required&&Array.isArray(this.schema.required)&&(e.required=this.schema.required.concat(u.required)));var x=this.jsoneditor.getEditorClass(e);this.editors[t]=this.jsoneditor.createEditor(x,{jsoneditor:this.jsoneditor,schema:e,container:d,path:this.path,parent:this,required:!0}),this.editors[t].preBuild(),this.editors[t].build(),this.editors[t].postBuild(),this.editors[t].header&&(this.editors[t].header.style.display="none"),this.editors[t].option=this.switcher_options[t],d.addEventListener("change_header_text",function(){o.refreshHeaderText()}),t!==this.type&&(d.style.display="none")}},{key:"preBuild",value:function(){if(this.types=[],this.type=0,this.editors=[],this.validators=[],this.keep_values=!0,this.jsoneditor.options.keep_oneof_values!==void 0&&(this.keep_values=this.jsoneditor.options.keep_oneof_values),this.options.keep_oneof_values!==void 0&&(this.keep_values=this.options.keep_oneof_values),this.keep_only_existing_values=!1,this.jsoneditor.options.keep_only_existing_values!==void 0&&(this.keep_only_existing_values=this.jsoneditor.options.keep_only_existing_values),this.options.keep_only_existing_values!==void 0&&(this.keep_only_existing_values=this.options.keep_only_existing_values),this.schema.oneOf)this.oneOf=!0,this.types=this.schema.oneOf,delete this.schema.oneOf;else if(this.schema.anyOf)this.anyOf=!0,this.types=this.schema.anyOf,delete this.schema.anyOf;else if(this.schema.if)this.if=!0,this.ifSchema=JSON.parse(JSON.stringify(this.schema.if)),this.thenSchema={title:"then"},this.elseSchema={title:"else"},this.types=[],this.schema.then&&$(this.thenSchema,this.schema,this.schema.then),this.schema.else&&$(this.elseSchema,this.schema,this.schema.else),this.types.push(this.thenSchema),this.types.push(this.elseSchema),this.types.forEach(function(o){delete o.if,delete o.then,delete o.else}),delete this.schema.if;else{if(this.schema.type&&this.schema.type!=="any")Array.isArray(this.schema.type)?this.types=this.schema.type:this.types=[this.schema.type];else if(this.types=["string","number","integer","boolean","object","array","null"],this.schema.disallow){var t=this.schema.disallow;qe(t)==="object"&&Array.isArray(t)||(t=[t]);var e=[];this.types.forEach(function(o){t.includes(o)||e.push(o)}),this.types=e}delete this.schema.type}this.display_text=this.getDisplayText(this.types)}},{key:"build",value:function(){var t=this,e=this.container;this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired()),this.switcher=this.theme.getSwitcher(this.display_text),this.if||(this.container.appendChild(this.header),e.appendChild(this.switcher)),this.switcher.addEventListener("change",function(u){u.preventDefault(),u.stopPropagation(),t.switchEditor(t.display_text.indexOf(u.currentTarget.value)),t.onChange(!0)}),this.editor_holder=document.createElement("div"),e.appendChild(this.editor_holder);var o={};this.jsoneditor.options.custom_validators&&(o.custom_validators=this.jsoneditor.options.custom_validators),this.switcher_options=this.theme.getSwitcherOptions(this.switcher),this.types.forEach(function(u,d){var x;t.editors[d]=!1,typeof u=="string"?(x=k({},t.schema)).type=u:(x=k({},t.schema,u),u.required&&Array.isArray(u.required)&&t.schema.required&&Array.isArray(t.schema.required)&&(x.required=t.schema.required.concat(u.required))),t.validators[d]=new Qi(t.jsoneditor,x,o,t.defaults)}),this.jsoneditor.on("change",function(){t.switchIf()}),this.switchEditor(0)}},{key:"onChildEditorChange",value:function(t){this.editors[this.type]&&(this.refreshValue(),this.refreshHeaderText()),ln(br(l.prototype),"onChildEditorChange",this).call(this)}},{key:"refreshHeaderText",value:function(){var t=this.getDisplayText(this.types);Array.from(this.switcher_options).forEach(function(e,o){e.textContent=t[o]})}},{key:"refreshValue",value:function(){this.editors[this.type]&&(this.value=this.editors[this.type].getValue())}},{key:"switchIf",value:function(){if(this.ifSchema&&this.value){var t=this.getIfType(this.value);this.lastType!==t&&(this.switchEditor(t),this.editors[this.type].setValue(this.value,!0)),this.switcher.value=this.display_text[this.type]}}},{key:"getIfType",value:function(t){return this.jsoneditor.validator._validateSchema(this.ifSchema,t).length===0?0:1}},{key:"setValue",value:function(t,e){var o=this,u=this.type,d={match:0,extra:0,i:this.type},x={match:0,i:null};this.validators.forEach(function(J,nt){var ut=null;o.anyOf!==void 0&&o.anyOf&&(ut=J.fitTest(t),(d.match<ut.match||d.match===ut.match&&d.extra>ut.extra)&&((d=ut).i=nt)),J.validate(t).length||x.i!==null?d=x:(x.i=nt,ut!==null&&(x.match=ut.match))});var P=x.i;this.anyOf!==void 0&&this.anyOf&&x.match<d.match&&(P=d.i),this.if&&(P=this.getIfType(t)),P===null&&(P=this.type),this.type=P,this.switcher.value=this.display_text[P];var D=this.type!==u;D&&(this.switchEditor(this.type),this.editors[this.type].setValue(t,e)),t!==void 0&&this.editors[this.type].setValue(t,e),this.refreshValue(),this.onChange(D)}},{key:"destroy",value:function(){this.editors.forEach(function(t){t&&t.destroy()}),this.editor_holder&&this.editor_holder.parentNode&&this.editor_holder.parentNode.removeChild(this.editor_holder),this.switcher&&this.switcher.parentNode&&this.switcher.parentNode.removeChild(this.switcher),ln(br(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;if(this.oneOf||this.anyOf){var o=this.oneOf?"oneOf":"anyOf";this.editors.forEach(function(u,d){if(u){var x="".concat(e.path,".").concat(o,"[").concat(d,"]");u.showValidationErrors(t.reduce(function(P,D){if(D.path.startsWith(x)||D.path===x.substr(0,D.path.length)){var J=k({},D);D.path.startsWith(x)&&(J.path=e.path+J.path.substr(x.length)),P.push(J)}return P},[]))}})}else this.editors.forEach(function(u){u&&u.showValidationErrors(t)})}},{key:"addLinks",value:function(){}}])&&Ur(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function On(c){return On=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},On(c)}function eo(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(On(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(On(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),On(h)==="symbol"?h:String(h)),i)}var h}function qn(c,n){return qn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},qn(c,n)}function Gn(c){return Gn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Gn(c)}var ca=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&qn(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Gn(i);if(h){var o=Gn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(On(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getValue",value:function(){if(this.dependenciesFulfilled)return null}},{key:"setValue",value:function(){this.onChange()}},{key:"getNumColumns",value:function(){return 2}}])&&eo(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function ro(c,n){var f=Object.keys(c);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(c);n&&(i=i.filter(function(h){return Object.getOwnPropertyDescriptor(c,h).enumerable})),f.push.apply(f,i)}return f}function cn(c){for(var n=1;n<arguments.length;n++){var f=arguments[n]!=null?arguments[n]:{};n%2?ro(Object(f),!0).forEach(function(i){yi(c,i,f[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(f)):ro(Object(f)).forEach(function(i){Object.defineProperty(c,i,Object.getOwnPropertyDescriptor(f,i))})}return c}function yi(c,n,f){return(n=io(n))in c?Object.defineProperty(c,n,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[n]=f,c}function En(c,n){return function(f){if(Array.isArray(f))return f}(c)||function(f,i){var h=f==null?null:typeof Symbol<"u"&&f[Symbol.iterator]||f["@@iterator"];if(h!=null){var a,l,t,e,o=[],u=!0,d=!1;try{if(t=(h=h.call(f)).next,i===0){if(Object(h)!==h)return;u=!1}else for(;!(u=(a=t.call(h)).done)&&(o.push(a.value),o.length!==i);u=!0);}catch(x){d=!0,l=x}finally{try{if(!u&&h.return!=null&&(e=h.return(),Object(e)!==e))return}finally{if(d)throw l}}return o}}(c,n)||function(f,i){if(f){if(typeof f=="string")return no(f,i);var h=Object.prototype.toString.call(f).slice(8,-1);return h==="Object"&&f.constructor&&(h=f.constructor.name),h==="Map"||h==="Set"?Array.from(f):h==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(h)?no(f,i):void 0}}(c,n)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
79
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function no(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function Br(c){return Br=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Br(c)}function ua(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,io(i.key),i)}}function io(c){var n=function(f,i){if(Br(f)!=="object"||f===null)return f;var h=f[Symbol.toPrimitive];if(h!==void 0){var a=h.call(f,"string");if(Br(a)!=="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(f)}(c);return Br(n)==="symbol"?n:String(n)}function Ar(){return Ar=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=vr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Ar.apply(this,arguments)}function oo(c,n){return oo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},oo(c,n)}function vr(c){return vr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},vr(c)}var bi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&oo(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=vr(i);if(h){var o=vr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Br(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t,e,o){var u;return function(d,x){if(!(d instanceof x))throw new TypeError("Cannot call a class as a function")}(this,l),(u=a.call(this,t,e)).currentDepth=o,u}return n=l,(f=[{key:"getDefault",value:function(){return k({},this.schema.default||{})}},{key:"getChildEditors",value:function(){return this.editors}},{key:"register",value:function(){Ar(vr(l.prototype),"register",this).call(this),this.editors&&Object.values(this.editors).forEach(function(t){return t.register()})}},{key:"unregister",value:function(){Ar(vr(l.prototype),"unregister",this).call(this),this.editors&&Object.values(this.editors).forEach(function(t){return t.unregister()})}},{key:"getNumColumns",value:function(){return Math.max(Math.min(12,this.maxwidth),3)}},{key:"enable",value:function(){this.always_disabled||(this.editjson_control&&(this.editjson_control.disabled=!1),this.addproperty_button&&(this.addproperty_button.disabled=!1),Ar(vr(l.prototype),"enable",this).call(this),this.editors&&Object.values(this.editors).forEach(function(t){t.isActive()&&t.enable(),t.optInCheckbox.disabled=!1}))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.editjson_control&&(this.editjson_control.disabled=!0),this.addproperty_button&&(this.addproperty_button.disabled=!0),this.hideEditJSON(),Ar(vr(l.prototype),"disable",this).call(this),this.editors&&Object.values(this.editors).forEach(function(e){e.isActive()&&e.disable(t),e.optInCheckbox.disabled=!0})}},{key:"layoutEditors",value:function(){var t,e,o=this;if(this.row_container){var u;this.property_order=Object.keys(this.editors),this.property_order=this.property_order.sort(function(Gt,gt){var Zt=o.editors[Gt].schema.propertyOrder,Ge=o.editors[gt].schema.propertyOrder;return typeof Zt!="number"&&(Zt=1e3),typeof Ge!="number"&&(Ge=1e3),Zt-Ge});var d,x=this.format==="categories",P=[],D=null,J=null;if(this.format==="grid-strict"){var nt=0;if(d=[],this.property_order.forEach(function(Gt){var gt=o.editors[Gt];if(!gt.property_removed){var Zt=gt.options.hidden?0:gt.options.grid_columns||gt.getNumColumns(),Ge=gt.options.hidden?0:gt.options.grid_offset||0,W=!gt.options.hidden&&(gt.options.grid_break||!1),G={key:Gt,width:Zt,offset:Ge,height:gt.options.hidden?0:gt.container.offsetHeight};d.push(G),P[nt]=d,W&&(nt++,d=[])}}),this.layout===JSON.stringify(P))return!1;for(this.layout=JSON.stringify(P),u=document.createElement("div"),t=0;t<P.length;t++)for(d=this.theme.getGridRow(),u.appendChild(d),e=0;e<P[t].length;e++)D=P[t][e].key,(J=this.editors[D]).options.hidden?J.container.style.display="none":this.theme.setGridColumnSize(J.container,P[t][e].width,P[t][e].offset),d.appendChild(J.container)}else if(this.format==="grid"){for(this.property_order.forEach(function(Gt){var gt=o.editors[Gt];if(!gt.property_removed){for(var Zt=!1,Ge=gt.options.hidden?0:gt.options.grid_columns||gt.getNumColumns(),W=gt.options.hidden?0:gt.container.offsetHeight,G=0;G<P.length;G++)P[G].width+Ge<=12&&(!W||.5*P[G].minh<W&&2*P[G].maxh>W)&&(Zt=G);Zt===!1&&(P.push({width:0,minh:999999,maxh:0,editors:[]}),Zt=P.length-1),P[Zt].editors.push({key:Gt,width:Ge,height:W}),P[Zt].width+=Ge,P[Zt].minh=Math.min(P[Zt].minh,W),P[Zt].maxh=Math.max(P[Zt].maxh,W)}}),t=0;t<P.length;t++)if(P[t].width<12){var ut=!1,dt=0;for(e=0;e<P[t].editors.length;e++)(ut===!1||P[t].editors[e].width>P[t].editors[ut].width)&&(ut=e),P[t].editors[e].width*=12/P[t].width,P[t].editors[e].width=Math.floor(P[t].editors[e].width),dt+=P[t].editors[e].width;dt<12&&(P[t].editors[ut].width+=12-dt),P[t].width=12}if(this.layout===JSON.stringify(P))return!1;for(this.layout=JSON.stringify(P),u=document.createElement("div"),t=0;t<P.length;t++)for(d=this.theme.getGridRow(),u.appendChild(d),e=0;e<P[t].editors.length;e++)D=P[t].editors[e].key,(J=this.editors[D]).options.hidden?J.container.style.display="none":this.theme.setGridColumnSize(J.container,P[t].editors[e].width),d.appendChild(J.container)}else{if(u=document.createElement("div"),x){var kt=document.createElement("div"),Ct=this.theme.getTopTabHolder(this.translateProperty(this.schema.title)),$t=this.theme.getTopTabContentHolder(Ct);for(this.property_order.forEach(function(Gt){var gt=o.editors[Gt];if(!gt.property_removed){var Zt=o.theme.getTabContent(),Ge=gt.schema&&(gt.schema.type==="object"||gt.schema.type==="array");Zt.isObjOrArray=Ge;var W=o.theme.getGridRow();gt.tab||(o.basicPane===void 0?o.addRow(gt,Ct,Zt):o.addRow(gt,Ct,o.basicPane)),Zt.id=o.getValidId(gt.tab_text.textContent),Ge?(Zt.appendChild(W),$t.appendChild(Zt),o.theme.addTopTab(Ct,gt.tab)):(kt.appendChild(W),$t.childElementCount>0?$t.firstChild.isObjOrArray&&(Zt.appendChild(kt),$t.insertBefore(Zt,$t.firstChild),o.theme.insertBasicTopTab(gt.tab,Ct),gt.basicPane=Zt):(Zt.appendChild(kt),$t.appendChild(Zt),o.theme.addTopTab(Ct,gt.tab),gt.basicPane=Zt)),gt.options.hidden?gt.container.style.display="none":o.theme.setGridColumnSize(gt.container,12),W.appendChild(gt.container),gt.rowPane=Zt}});this.tabPanesContainer.firstChild;)this.tabPanesContainer.removeChild(this.tabPanesContainer.firstChild);var ne=this.tabs_holder.parentNode;ne.removeChild(ne.firstChild),ne.appendChild(Ct),this.tabPanesContainer=$t,this.tabs_holder=Ct;var Re=this.theme.getFirstTab(this.tabs_holder);return void(Re&&O(Re,"click"))}this.property_order.forEach(function(Gt){var gt=o.editors[Gt];gt.property_removed||(d=o.theme.getGridRow(),u.appendChild(d),gt.options.hidden?gt.container.style.display="none":o.theme.setGridColumnSize(gt.container,12),d.appendChild(gt.container))})}for(;this.row_container.firstChild;)this.row_container.removeChild(this.row_container.firstChild);this.row_container.appendChild(u)}}},{key:"getPropertySchema",value:function(t){var e=this,o=this.schema.properties[t]||{};o=k({},o);var u=!!this.schema.properties[t];return this.schema.patternProperties&&Object.keys(this.schema.patternProperties).forEach(function(d){new RegExp(d).test(t)&&(o.allOf=o.allOf||[],o.allOf.push(e.schema.patternProperties[d]),u=!0)}),!u&&this.schema.additionalProperties&&Br(this.schema.additionalProperties)==="object"&&(o=k({},this.schema.additionalProperties)),o}},{key:"preBuild",value:function(){var t=this;if(Ar(vr(l.prototype),"preBuild",this).call(this),this.editors={},this.cached_editors={},this.format=this.options.layout||this.options.object_layout||this.schema.format||this.jsoneditor.options.object_layout||"normal",this.schema.properties=this.schema.properties||{},this.minwidth=0,this.maxwidth=0,this.options.table_row)Object.entries(this.schema.properties).forEach(function(e){var o=En(e,2),u=o[0],d=o[1],x=t.jsoneditor.getEditorClass(d);t.editors[u]=t.jsoneditor.createEditor(x,{jsoneditor:t.jsoneditor,schema:d,path:"".concat(t.path,".").concat(u),parent:t,compact:!0,required:!0},t.currentDepth+1),t.editors[u].preBuild();var P=t.editors[u].options.hidden?0:t.editors[u].options.grid_columns||t.editors[u].getNumColumns();t.minwidth+=P,t.maxwidth+=P}),this.no_link_holder=!0;else{if(this.options.table)throw new Error("Not supported yet");this.schema.defaultProperties||(this.jsoneditor.options.display_required_only||this.options.display_required_only?this.schema.defaultProperties=Object.keys(this.schema.properties).filter(function(e){return t.isRequiredObject({key:e,schema:t.schema.properties[e]})}):this.schema.defaultProperties=Object.keys(this.schema.properties)),this.maxwidth+=1,Array.isArray(this.schema.defaultProperties)&&this.schema.defaultProperties.forEach(function(e){t.addObjectProperty(e,!0),t.editors[e]&&(t.minwidth=Math.max(t.minwidth,t.editors[e].options.grid_columns||t.editors[e].getNumColumns()),t.maxwidth+=t.editors[e].options.grid_columns||t.editors[e].getNumColumns())})}this.property_order=Object.keys(this.editors),this.property_order=this.property_order.sort(function(e,o){var u=t.editors[e].schema.propertyOrder,d=t.editors[o].schema.propertyOrder;return typeof u!="number"&&(u=1e3),typeof d!="number"&&(d=1e3),u-d})}},{key:"addTab",value:function(t){var e=this,o=this.rows[t].schema&&(this.rows[t].schema.type==="object"||this.rows[t].schema.type==="array");this.tabs_holder&&(this.rows[t].tab_text=document.createElement("span"),this.rows[t].tab_text.textContent=o?this.rows[t].getHeaderText():this.schema.basicCategoryTitle===void 0?"Basic":this.schema.basicCategoryTitle,this.rows[t].tab=this.theme.getTopTab(this.rows[t].tab_text,this.getValidId(this.rows[t].tab_text.textContent)),this.rows[t].tab.addEventListener("click",function(u){e.active_tab=e.rows[t].tab,e.refreshTabs(),u.preventDefault(),u.stopPropagation()}))}},{key:"addRow",value:function(t,e,o){var u=this.rows.length,d=t.schema.type==="object"||t.schema.type==="array";this.rows[u]=t,this.rows[u].rowPane=o,d?(this.addTab(u),this.theme.addTopTab(e,this.rows[u].tab)):this.basicTab===void 0?(this.addTab(u),this.basicTab=u,this.basicPane=o,this.theme.addTopTab(e,this.rows[u].tab)):(this.rows[u].tab=this.rows[this.basicTab].tab,this.rows[u].tab_text=this.rows[this.basicTab].tab_text,this.rows[u].rowPane=this.rows[this.basicTab].rowPane)}},{key:"refreshTabs",value:function(t){var e=this,o=this.basicTab!==void 0,u=!1;this.rows.forEach(function(d){d.tab&&d.rowPane&&d.rowPane.parentNode&&(o&&d.tab===e.rows[e.basicTab].tab&&u||(t?d.tab_text.textContent=d.getHeaderText():(o&&d.tab===e.rows[e.basicTab].tab&&(u=!0),d.tab===e.active_tab?e.theme.markTabActive(d):e.theme.markTabInactive(d))))})}},{key:"build",value:function(){var t=this,e=this.format==="categories";if(this.rows=[],this.active_tab=null,this.options.table_row)this.editor_holder=this.container,Object.entries(this.editors).forEach(function(u){var d=En(u,2),x=d[0],P=d[1],D=t.theme.getTableCell();t.editor_holder.appendChild(D),P.setContainer(D),P.build(),P.postBuild(),P.setOptInCheckbox(P.header),P.setValue(P.getDefault(),!0),t.editors[x].options.hidden&&(D.style.display="none"),t.editors[x].options.input_width&&(D.style.width=t.editors[x].options.input_width)});else{if(this.options.table)throw new Error("Not supported yet");this.header="",this.options.compact||(this.header=document.createElement("label"),this.header.textContent=this.getTitle()),this.title=this.theme.getHeader(this.header,this.getPathDepth()),this.title.classList.add("je-object__title"),this.controls=this.theme.getButtonHolder(),this.controls.classList.add("je-object__controls"),this.container.appendChild(this.title),this.container.appendChild(this.controls),this.container.classList.add("je-object__container"),this.editjson_holder=this.theme.getModal(),this.editjson_textarea=this.theme.getTextareaInput(),this.editjson_textarea.classList.add("je-edit-json--textarea"),this.editjson_save=this.getButton("button_save","save","button_save"),this.editjson_save.classList.add("json-editor-btntype-save"),this.editjson_save.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.saveJSON()}),this.editjson_copy=this.getButton("button_copy","copy","button_copy"),this.editjson_copy.classList.add("json-editor-btntype-copy"),this.editjson_copy.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.copyJSON()}),this.editjson_cancel=this.getButton("button_cancel","cancel","button_cancel"),this.editjson_cancel.classList.add("json-editor-btntype-cancel"),this.editjson_cancel.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.hideEditJSON()}),this.editjson_holder.appendChild(this.editjson_textarea),this.editjson_holder.appendChild(this.editjson_save),this.editjson_holder.appendChild(this.editjson_copy),this.editjson_holder.appendChild(this.editjson_cancel),this.addproperty_holder=this.theme.getModal(),this.addproperty_list=document.createElement("div"),this.addproperty_list.classList.add("property-selector"),this.addproperty_add=this.getButton("button_add","add","button_add"),this.addproperty_add.classList.add("json-editor-btntype-add"),this.addproperty_input=this.theme.getFormInputField("text"),this.addproperty_input.setAttribute("placeholder","Property name..."),this.addproperty_input.classList.add("property-selector-input"),this.addproperty_add.addEventListener("click",function(u){if(u.preventDefault(),u.stopPropagation(),t.addproperty_input.value){if(t.editors[t.addproperty_input.value])return void window.alert("there is already a property with that name");t.addObjectProperty(t.addproperty_input.value),t.editors[t.addproperty_input.value]&&t.editors[t.addproperty_input.value].disable(),t.onChange(!0)}}),this.addproperty_input.addEventListener("input",function(u){u.target.previousSibling.childNodes.forEach(function(d){var x=d.innerText,P=u.target.value;t.options.case_sensitive_property_search||t.jsoneditor.options.case_sensitive_property_search||(x=x.toLowerCase(),P=P.toLowerCase()),x.includes(P)?d.style.display="":d.style.display="none"})}),this.addproperty_holder.appendChild(this.addproperty_list),this.addproperty_holder.appendChild(this.addproperty_input),this.addproperty_holder.appendChild(this.addproperty_add);var o=document.createElement("div");o.style.clear="both",this.addproperty_holder.appendChild(o),this.onOutsideModalClickListener=this.onOutsideModalClick.bind(this),document.addEventListener("click",this.onOutsideModalClickListener,!0),this.schema.description&&(this.description=this.theme.getDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.description)),this.error_holder=document.createElement("div"),this.container.appendChild(this.error_holder),this.editor_holder=this.theme.getIndentedPanel(),this.container.appendChild(this.editor_holder),this.row_container=this.theme.getGridContainer(),e?(this.tabs_holder=this.theme.getTopTabHolder(this.getValidId(this.translateProperty(this.schema.title))),this.tabPanesContainer=this.theme.getTopTabContentHolder(this.tabs_holder),this.editor_holder.appendChild(this.tabs_holder)):(this.tabs_holder=this.theme.getTabHolder(this.getValidId(this.translateProperty(this.schema.title))),this.tabPanesContainer=this.theme.getTabContentHolder(this.tabs_holder),this.editor_holder.appendChild(this.row_container)),Object.values(this.editors).forEach(function(u){var d=t.theme.getTabContent(),x=t.theme.getGridColumn(),P=!(!u.schema||u.schema.type!=="object"&&u.schema.type!=="array");if(d.isObjOrArray=P,e){if(P){var D=t.theme.getGridContainer();D.appendChild(x),d.appendChild(D),t.tabPanesContainer.appendChild(d),t.row_container=D}else t.row_container_basic===void 0&&(t.row_container_basic=t.theme.getGridContainer(),d.appendChild(t.row_container_basic),t.tabPanesContainer.childElementCount===0?t.tabPanesContainer.appendChild(d):t.tabPanesContainer.insertBefore(d,t.tabPanesContainer.childNodes[1])),t.row_container_basic.appendChild(x);t.addRow(u,t.tabs_holder,d),d.id=t.getValidId(u.schema.title)}else t.row_container.appendChild(x);u.setContainer(x),u.build(),u.postBuild(),u.setOptInCheckbox(u.header)}),this.rows[0]&&O(this.rows[0].tab,"click"),this.collapsed=!1,this.collapse_control=this.getButton("","collapse","button_collapse"),this.collapse_control.classList.add("json-editor-btntype-toggle"),this.title.insertBefore(this.collapse_control,this.title.childNodes[0]),this.collapse_control.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.collapsed?(t.editor_holder.style.display="",t.collapsed=!1,t.setButtonText(t.collapse_control,"","collapse","button_collapse")):(t.editor_holder.style.display="none",t.collapsed=!0,t.setButtonText(t.collapse_control,"","expand","button_expand"))}),this.options.collapsed&&O(this.collapse_control,"click"),this.schema.options&&this.schema.options.disable_collapse!==void 0?this.schema.options.disable_collapse&&(this.collapse_control.style.display="none"):this.jsoneditor.options.disable_collapse&&(this.collapse_control.style.display="none"),this.editjson_control=this.getButton("JSON","edit","button_edit_json"),this.editjson_control.classList.add("json-editor-btntype-editjson"),this.editjson_control.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.toggleEditJSON()}),this.controls.appendChild(this.editjson_control),this.controls.insertBefore(this.editjson_holder,this.controls.childNodes[0]),this.schema.options&&this.schema.options.disable_edit_json!==void 0?this.schema.options.disable_edit_json&&(this.editjson_control.style.display="none"):this.jsoneditor.options.disable_edit_json&&(this.editjson_control.style.display="none"),this.addproperty_button=this.getButton("properties","edit_properties","button_object_properties"),this.addproperty_button.classList.add("json-editor-btntype-properties"),this.addproperty_button.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.toggleAddProperty()}),this.controls.appendChild(this.addproperty_button),this.controls.insertBefore(this.addproperty_holder,this.controls.childNodes[1]),this.refreshAddProperties(),this.deactivateNonRequiredProperties()}this.options.table_row?(this.editor_holder=this.container,this.property_order.forEach(function(u){t.editor_holder.appendChild(t.editors[u].container)})):(this.layoutEditors(),this.layoutEditors())}},{key:"deactivateNonRequiredProperties",value:function(){var t=this,e=this.jsoneditor.options.show_opt_in,o=this.options.show_opt_in!==void 0,u=o&&this.options.show_opt_in===!0,d=o&&this.options.show_opt_in===!1;(u||!d&&e||!o&&e)&&Object.entries(this.editors).forEach(function(x){var P=En(x,2),D=P[0],J=P[1];t.isRequiredObject(J)||t.editors[D].deactivate()})}},{key:"showEditJSON",value:function(){this.editjson_holder&&(this.hideAddProperty(),this.editjson_holder.style.left="".concat(this.editjson_control.offsetLeft,"px"),this.editjson_holder.style.top="".concat(this.editjson_control.offsetTop+this.editjson_control.offsetHeight,"px"),this.editjson_textarea.value=JSON.stringify(this.getValue(),null,2),this.disable(),this.editjson_holder.style.display="",this.editjson_control.disabled=!1,this.editing_json=!0)}},{key:"hideEditJSON",value:function(){this.editjson_holder&&this.editing_json&&(this.editjson_holder.style.display="none",this.enable(),this.editing_json=!1)}},{key:"copyJSON",value:function(){if(this.editjson_holder){var t=document.createElement("textarea");t.value=this.editjson_textarea.value,t.setAttribute("readonly",""),t.style.position="absolute",t.style.left="-9999px",document.body.appendChild(t),t.select(),document.execCommand("copy"),document.body.removeChild(t)}}},{key:"saveJSON",value:function(){if(this.editjson_holder)try{var t=JSON.parse(this.editjson_textarea.value);this.setValue(t),this.hideEditJSON(),this.onChange(!0)}catch(e){throw window.alert("invalid JSON"),e}}},{key:"toggleEditJSON",value:function(){this.editing_json?this.hideEditJSON():this.showEditJSON()}},{key:"insertPropertyControlUsingPropertyOrder",value:function(t,e,o){var u;this.schema.properties[t]&&(u=this.schema.properties[t].propertyOrder),typeof u!="number"&&(u=1e3),e.propertyOrder=u;for(var d=0;d<o.childNodes.length;d++){var x=o.childNodes[d];if(e.propertyOrder<x.propertyOrder){this.addproperty_list.insertBefore(e,x),e=null;break}}e&&this.addproperty_list.appendChild(e)}},{key:"addPropertyCheckbox",value:function(t){var e,o=this,u=this.theme.getCheckbox();e=this.schema.properties[t]&&this.schema.properties[t].title?this.schema.properties[t].title:t;var d=this.theme.getCheckboxLabel(e),x=this.theme.getFormControl(d,u);return x.style.paddingBottom=x.style.marginBottom=x.style.paddingTop=x.style.marginTop=0,x.style.height="auto",this.insertPropertyControlUsingPropertyOrder(t,x,this.addproperty_list),u.checked=t in this.editors,u.addEventListener("change",function(){u.checked?o.addObjectProperty(t):o.removeObjectProperty(t),o.onChange(!0)}),this.addproperty_checkboxes[t]=u,u}},{key:"showAddProperty",value:function(){this.addproperty_holder&&(this.hideEditJSON(),this.addproperty_holder.style.left="".concat(this.addproperty_button.offsetLeft,"px"),this.addproperty_holder.style.top="".concat(this.addproperty_button.offsetTop+this.addproperty_button.offsetHeight,"px"),this.disable(),this.adding_property=!0,this.addproperty_button.disabled=!1,this.addproperty_holder.style.display="",this.refreshAddProperties())}},{key:"hideAddProperty",value:function(){this.addproperty_holder&&this.adding_property&&(this.addproperty_holder.style.display="none",this.enable(),this.adding_property=!1)}},{key:"toggleAddProperty",value:function(){this.adding_property?this.hideAddProperty():this.showAddProperty()}},{key:"removeObjectProperty",value:function(t){this.editors[t]&&(this.editors[t].unregister(),delete this.editors[t],this.refreshValue(),this.layoutEditors())}},{key:"getSchemaOnMaxDepth",value:function(t){return Object.keys(t).reduce(function(e,o){switch(o){case"$ref":return e;case"properties":case"items":return cn(cn({},e),{},yi({},o,{}));case"additionalProperties":case"propertyNames":return cn(cn({},e),{},yi({},o,!0));default:return cn(cn({},e),{},yi({},o,t[o]))}},{})}},{key:"addObjectProperty",value:function(t,e){if(!this.editors[t]){if(this.cached_editors[t]){if(this.editors[t]=this.cached_editors[t],e)return;this.editors[t].register()}else{if(!(this.canHaveAdditionalProperties()||this.schema.properties&&this.schema.properties[t]||this.schema.patternProperties&&Object.keys(this.schema.patternProperties).find(function(P){return new RegExp(P).test(t)})))return;var o=this.getPropertySchema(t);typeof o.propertyOrder!="number"&&(o.propertyOrder=Object.keys(this.editors).length+1e3);var u=this.jsoneditor.getEditorClass(o),d=this.jsoneditor.options.max_depth;if(this.editors[t]=this.jsoneditor.createEditor(u,{jsoneditor:this.jsoneditor,schema:d&&this.currentDepth>=d?this.getSchemaOnMaxDepth(o):o,path:"".concat(this.path,".").concat(t),parent:this},this.currentDepth+1),this.editors[t].preBuild(),!e){var x=this.theme.getChildEditorHolder();this.editor_holder.appendChild(x),this.editors[t].setContainer(x),this.editors[t].build(),this.editors[t].postBuild(),this.editors[t].setOptInCheckbox(u.header),this.editors[t].activate()}this.cached_editors[t]=this.editors[t]}e||(this.refreshValue(),this.layoutEditors())}}},{key:"onOutsideModalClick",value:function(t){var e=t.path||t.composedPath&&t.composedPath();this.addproperty_holder&&!this.addproperty_holder.contains(e[0])&&this.adding_property&&(t.preventDefault(),t.stopPropagation(),this.toggleAddProperty())}},{key:"onChildEditorChange",value:function(t){this.refreshValue(),Ar(vr(l.prototype),"onChildEditorChange",this).call(this,t)}},{key:"canHaveAdditionalProperties",value:function(){return typeof this.schema.additionalProperties=="boolean"?this.schema.additionalProperties:Br(this.schema.additionalProperties)==="object"&&this.schema.additionalProperties!==null||(typeof this.options.no_additional_properties=="boolean"?!this.options.no_additional_properties:typeof this.jsoneditor.options.no_additional_properties!="boolean"||!this.jsoneditor.options.no_additional_properties)}},{key:"destroy",value:function(){Object.values(this.cached_editors).forEach(function(t){return t.destroy()}),this.editor_holder&&(this.editor_holder.innerHTML=""),this.title&&this.title.parentNode&&this.title.parentNode.removeChild(this.title),this.error_holder&&this.error_holder.parentNode&&this.error_holder.parentNode.removeChild(this.error_holder),this.editors=null,this.cached_editors=null,this.editor_holder&&this.editor_holder.parentNode&&this.editor_holder.parentNode.removeChild(this.editor_holder),this.editor_holder=null,document.removeEventListener("click",this.onOutsideModalClickListener,!0),Ar(vr(l.prototype),"destroy",this).call(this)}},{key:"getValue",value:function(){if(this.dependenciesFulfilled){var t=Ar(vr(l.prototype),"getValue",this).call(this);return t&&(this.jsoneditor.options.remove_empty_properties||this.options.remove_empty_properties)&&Object.keys(t).forEach(function(e){var o;((o=t[e])===void 0||o===""||o===Object(o)&&Object.keys(o).length===0&&o.constructor===Object)&&delete t[e]}),t}}},{key:"refreshValue",value:function(){var t=this;this.value={},this.editors&&(Object.keys(this.editors).forEach(function(e){t.editors[e].isActive()&&(t.editors[e].refreshValue(),t.value[e]=t.editors[e].getValue())}),Object.keys(this.editors).forEach(function(e){t.editors[e].isActive()&&t.activateDependentRequired(t.editors[e].key)}),this.adding_property&&this.refreshAddProperties())}},{key:"activateDependentRequired",value:function(t){var e=this;this.getDependentRequired(t).forEach(function(o){var u;Object.entries(e.cached_editors).forEach(function(d){var x=En(d,2),P=(x[0],x[1]);P.key===o&&(u=P)}),u&&!u.isActive()&&u.activate()})}},{key:"getDependentRequired",value:function(t){return this.schema.dependentRequired&&S(this.schema.dependentRequired,t)?this.schema.dependentRequired[t]:[]}},{key:"refreshAddProperties",value:function(){var t=this;if(this.options.disable_properties||this.options.disable_properties!==!1&&this.jsoneditor.options.disable_properties)this.addproperty_button.style.display="none";else{var e,o=0,u=!1;Object.keys(this.editors).forEach(function(d){return o++}),e=this.canHaveAdditionalProperties()&&!(this.schema.maxProperties!==void 0&&o>=this.schema.maxProperties),this.addproperty_checkboxes&&(this.addproperty_list.innerHTML=""),this.addproperty_checkboxes={},Object.keys(this.cached_editors).forEach(function(d){t.addPropertyCheckbox(d),t.isRequiredObject(t.cached_editors[d])&&d in t.editors&&(t.addproperty_checkboxes[d].disabled=!0),t.schema.minProperties!==void 0&&o<=t.schema.minProperties?(t.addproperty_checkboxes[d].disabled=t.addproperty_checkboxes[d].checked,t.addproperty_checkboxes[d].checked||(u=!0)):d in t.editors?u=!0:e||S(t.schema.properties,d)?(t.addproperty_checkboxes[d].disabled=!1,u=!0):t.addproperty_checkboxes[d].disabled=!0}),this.canHaveAdditionalProperties()&&(u=!0),Object.keys(this.schema.properties).forEach(function(d){t.cached_editors[d]||(u=!0,t.addPropertyCheckbox(d))}),u?this.canHaveAdditionalProperties()?this.addproperty_add.disabled=!e:(this.addproperty_add.style.display="none",this.addproperty_input.style.display="none"):(this.hideAddProperty(),this.addproperty_button.style.display="none")}}},{key:"isRequiredObject",value:function(t){if(t)return typeof t.schema.required=="boolean"?t.schema.required:Array.isArray(this.schema.required)?this.schema.required.includes(t.key):!!this.jsoneditor.options.required_by_default}},{key:"setValue",value:function(t,e){var o=this;(Br(t=t||{})!=="object"||Array.isArray(t))&&(t={}),Object.entries(this.cached_editors).forEach(function(u){var d=En(u,2),x=d[0],P=d[1];t[x]!==void 0?(o.addObjectProperty(x),P.setValue(t[x],e),P.activate()):e||o.isRequiredObject(P)?P.setValue(P.getDefault(),e):o.jsoneditor.options.show_opt_in||o.options.show_opt_in?P.deactivate():o.removeObjectProperty(x)}),Object.entries(t).forEach(function(u){var d=En(u,2),x=d[0],P=d[1];o.cached_editors[x]||(o.addObjectProperty(x),o.editors[x]&&o.editors[x].setValue(P,e,!!o.editors[x].template))}),this.refreshValue(),this.layoutEditors(),this.onChange()}},{key:"showValidationErrors",value:function(t){var e=this,o=[],u=[];t.forEach(function(d){d.path===e.path?o.push(d):u.push(d)}),this.error_holder&&(o.length?(this.error_holder.innerHTML="",this.error_holder.style.display="",o.forEach(function(d){d.errorcount&&d.errorcount>1&&(d.message+=" (".concat(d.errorcount," errors)")),e.error_holder.appendChild(e.theme.getErrorMessage(d.message))})):this.error_holder.style.display="none"),this.options.table_row&&(o.length?this.theme.addTableRowError(this.container):this.theme.removeTableRowError(this.container)),Object.values(this.editors).forEach(function(d){d.showValidationErrors(u)})}}])&&ua(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Wn(c){return Wn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Wn(c)}function vl(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Wn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Wn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Wn(h)==="symbol"?h:String(h)),i)}var h}function Zn(){return Zn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=V(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Zn.apply(this,arguments)}function ha(c,n){return ha=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ha(c,n)}function V(c){return V=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},V(c)}bi.rules={".je-object__title":"display:inline-block",".je-object__controls":"margin:0%200%200%2010px",".je-object__container":"position:relative",".je-object__property-checkbox":"margin:0;height:auto",".property-selector":"width:295px;max-height:160px;padding:5px%200;overflow-y:auto;overflow-x:hidden;padding-left:5px",".property-selector-input":"width:220px;margin-bottom:0;display:inline-block",".json-editor-btntype-toggle":"margin:0%2010px%200%200",".je-edit-json--textarea":"height:170px;width:300px;display:block"};var at=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ha(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=V(i);if(h){var o=V(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Wn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"preBuild",value:function(){Zn(V(l.prototype),"preBuild",this).call(this)}},{key:"build",value:function(){var t=this;this.label="",this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.radioContainer=document.createElement("div"),this.radioGroup=[];for(var e=function(J){t.setValue(J.currentTarget.value),t.onChange(!0)},o=0;o<this.enum_values.length;o++){var u={id:"".concat(this.formname,"[").concat(o,"]"),value:this.enum_values[o]};this.jsoneditor.options.use_name_attributes&&(u.name=this.formname),this.input=this.theme.getFormRadio(u),this.setInputAttributes(["id","value","name"]),this.input.addEventListener("change",e,!1),this.radioGroup.push(this.input);var d=this.theme.getFormRadioLabel(this.enum_display[o]);d.htmlFor=this.input.id;var x=this.theme.getFormRadioControl(d,this.input,!(this.options.layout!=="horizontal"&&!this.options.compact));this.radioContainer.appendChild(x)}if(this.schema.readOnly||this.schema.readonly){this.disable(!0);for(var P=0;P<this.radioGroup.length;P++)this.radioGroup[P].disabled=!0;this.radioContainer.classList.add("readonly")}var D=this.theme.getContainer();D.appendChild(this.radioContainer),D.dataset.containerFor="radio",this.input=D,this.control=this.theme.getFormControl(this.label,D,this.description,this.infoButton),this.container.appendChild(this.control),window.requestAnimationFrame(function(){t.input.parentNode&&t.afterInputReady()})}},{key:"enable",value:function(){if(!this.always_disabled){for(var t=0;t<this.radioGroup.length;t++)this.radioGroup[t].disabled=!1;this.radioContainer.classList.remove("readonly"),Zn(V(l.prototype),"enable",this).call(this)}}},{key:"disable",value:function(t){t&&(this.always_disabled=!0);for(var e=0;e<this.radioGroup.length;e++)this.radioGroup[e].disabled=!0;this.radioContainer.classList.add("readonly"),Zn(V(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){this.radioContainer.parentNode&&this.radioContainer.parentNode.parentNode&&this.radioContainer.parentNode.parentNode.removeChild(this.radioContainer.parentNode),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),Zn(V(l.prototype),"destroy",this).call(this)}},{key:"getNumColumns",value:function(){return 2}},{key:"setValue",value:function(t){typeof t!="string"&&(t=String(t));for(var e=0;e<this.radioGroup.length;e++)if(this.radioGroup[e].value===t){this.radioGroup[e].checked=!0,this.value=t,this.onChange();break}}}])&&vl(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function Ot(c){return Ot=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ot(c)}function ve(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Ot(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Ot(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Ot(h)==="symbol"?h:String(h)),i)}var h}function we(){return we=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=He(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},we.apply(this,arguments)}function le(c,n){return le=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},le(c,n)}function He(c){return He=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},He(c)}var ao=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&le(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=He(i);if(h){var o=He(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Ot(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=we(He(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.sceditor_instance&&this.sceditor_instance.val(u.value)}},{key:"build",value:function(){this.options.format="textarea",we(He(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t=this;if(window.sceditor){var e=this.expandCallbacks("sceditor",k({},{format:this.input_type,emoticonsEnabled:!1,width:"100%",height:300,readOnly:this.schema.readOnly||this.schema.readonly||this.schema.template},this.defaults.options.sceditor||{},this.options.sceditor||{},{element:this.input})),o=window.sceditor.instance(this.input);o===void 0&&window.sceditor.create(this.input,e),this.sceditor_instance=o||window.sceditor.instance(this.input),this.sceditor_instance.blur(function(){t.value=t.sceditor_instance.val(),t.sceditor_instance.updateOriginal(),t.is_dirty=!0,t.onChange(!0)}),this.theme.afterInputReady(this.input)}else we(He(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.sceditor_instance&&this.sceditor_instance.readOnly(!1),we(He(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.sceditor_instance&&this.sceditor_instance.readOnly(!0),we(He(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.sceditor_instance&&(this.sceditor_instance.destroy(),this.sceditor_instance=null),we(He(l.prototype),"destroy",this).call(this)}}])&&ve(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function so(c){return so=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},so(c)}function Fp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(so(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(so(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),so(h)==="symbol"?h:String(h)),i)}var h}function vi(){return vi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=un(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},vi.apply(this,arguments)}function gl(c,n){return gl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},gl(c,n)}function un(c){return un=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},un(c)}var Vp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&gl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=un(i);if(h){var o=un(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(so(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){if(this.select2_instance){e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0);var o=this.updateValue(t);this.input.value=o,this.select2v4?this.select2_instance.val(o).trigger("change"):this.select2_instance.select2("val",o),this.onChange(!0)}else vi(un(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t=this;if(window.jQuery&&window.jQuery.fn&&window.jQuery.fn.select2&&!this.select2_instance){var e=this.expandCallbacks("select2",k({},this.defaults.options.select2||{},this.options.select2||{}));this.newEnumAllowed=e.tags=!!e.tags&&this.schema.type==="string",this.select2_instance=window.jQuery(this.input).select2(e),this.select2v4=S(this.select2_instance.select2,"amd"),this.selectChangeHandler=function(){var o=t.select2v4?t.select2_instance.val():t.select2_instance.select2("val");t.updateValue(o),t.onChange(!0)},this.select2_instance.on("change",this.selectChangeHandler),this.select2_instance.on("select2-blur",this.selectChangeHandler)}vi(un(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){var e=this.enum_values[0];return t=this.typecast(t||""),this.enum_values.includes(t)?e=t:this.newEnumAllowed&&(e=this.addNewOption(t)?t:e),this.value=e,e}},{key:"addNewOption",value:function(t){var e,o=this.typecast(t),u=!1;return this.enum_values.includes(o)||o===""||(this.enum_options.push("".concat(o)),this.enum_display.push("".concat(o)),this.enum_values.push(o),this.schema.enum.push(o),(e=this.input.querySelector('option[value="'.concat(o,'"]')))?e.removeAttribute("data-select2-tag"):this.input.appendChild(new Option(o,o,!1,!1)).trigger("change"),u=!0),u}},{key:"enable",value:function(){this.always_disabled||this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!1):this.select2_instance.select2("enable",!0)),vi(un(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!0):this.select2_instance.select2("enable",!1)),vi(un(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.select2_instance&&(this.select2_instance.select2("destroy"),this.select2_instance=null),vi(un(l.prototype),"destroy",this).call(this)}}])&&Fp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function lo(c){return lo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},lo(c)}function zp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(lo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(lo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),lo(h)==="symbol"?h:String(h)),i)}var h}function Jn(){return Jn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Kr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Jn.apply(this,arguments)}function wl(c,n){return wl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},wl(c,n)}function Kr(c){return Kr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Kr(c)}var Up=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&wl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Kr(i);if(h){var o=Kr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(lo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){if(this.selectize_instance){e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0);var o=this.updateValue(t);this.input.value=o,this.selectize_instance.clear(!0),this.selectize_instance.setValue(o),this.onChange(!0)}else Jn(Kr(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t=this;if(window.jQuery&&window.jQuery.fn&&window.jQuery.fn.selectize&&!this.selectize_instance){var e=this.expandCallbacks("selectize",k({},this.defaults.options.selectize||{},this.options.selectize||{}));this.newEnumAllowed=e.create=!!e.create&&this.schema.type==="string",this.selectize_instance=window.jQuery(this.input).selectize(e)[0].selectize,this.control.removeEventListener("change",this.multiselectChangeHandler),this.multiselectChangeHandler=function(o){t.updateValue(o),t.onChange(!0)},this.selectize_instance.on("change",this.multiselectChangeHandler)}Jn(Kr(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){var e=this.enum_values[0];return t=this.typecast(t||""),this.enum_values.includes(t)?e=t:this.newEnumAllowed&&(e=this.addNewOption(t)?t:e),this.value=e,e}},{key:"addNewOption",value:function(t){var e=this.typecast(t),o=!1;return this.enum_values.includes(e)||e===""||(this.enum_options.push("".concat(e)),this.enum_display.push("".concat(e)),this.enum_values.push(e),this.schema.enum.push(e),this.selectize_instance.addItem(e),this.selectize_instance.refreshOptions(!1),o=!0),o}},{key:"onWatchedFieldChange",value:function(){var t=this;Jn(Kr(l.prototype),"onWatchedFieldChange",this).call(this),this.selectize_instance&&(this.selectize_instance.clear(!0),this.selectize_instance.clearOptions(!0),this.enum_options.forEach(function(e,o){t.selectize_instance.addOption({value:e,text:t.enum_display[o]})}),this.selectize_instance.addItem("".concat(this.value),!0))}},{key:"enable",value:function(){!this.always_disabled&&this.selectize_instance&&this.selectize_instance.unlock(),Jn(Kr(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.selectize_instance&&this.selectize_instance.lock(),Jn(Kr(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.selectize_instance&&(this.selectize_instance.destroy(),this.selectize_instance=null),Jn(Kr(l.prototype),"destroy",this).call(this)}}])&&zp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function co(c){return co=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},co(c)}function qp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(co(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(co(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),co(h)==="symbol"?h:String(h)),i)}var h}function _l(c,n){return _l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},_l(c,n)}function ws(c){return ws=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ws(c)}var Gp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_l(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ws(i);if(h){var o=ws(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(co(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){var t=this;this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description)));var e=this.formname.replace(/\W/g,"");if(typeof SignaturePad=="function"){this.input=this.theme.getFormInputField("hidden"),this.container.appendChild(this.input);var o=document.createElement("div");o.classList.add("signature-container");var u=document.createElement("canvas");this.jsoneditor.options.use_name_attributes&&u.setAttribute("name",e),u.classList.add("signature"),o.appendChild(u),this.signaturePad=new window.SignaturePad(u),this.signaturePad.onEnd=function(){t.signaturePad.isEmpty()?t.input.value="":t.input.value=t.signaturePad.toDataURL(),t.is_dirty=!0,t.refreshValue(),t.watch_listener(),t.jsoneditor.notifyWatchers(t.path),t.parent?t.parent.onChildEditorChange(t):t.jsoneditor.onChange()};var d=document.createElement("div"),x=document.createElement("button");x.classList.add("tiny","button"),x.innerHTML="Clear signature",d.appendChild(x),o.appendChild(d),this.options.compact&&this.container.setAttribute("class","".concat(this.container.getAttribute("class")," compact")),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),Array.from(this.inputs).forEach(function(D){u.setAttribute("readOnly","readOnly"),D.disabled=!0})),x.addEventListener("click",function(D){D.preventDefault(),D.stopPropagation(),t.signaturePad.clear(),t.signaturePad.strokeEnd()}),this.control=this.theme.getFormControl(this.label,o,this.description),this.container.appendChild(this.control),this.refreshValue(),u.width=o.offsetWidth,this.options&&this.options.canvas_height?u.height=this.options.canvas_height:u.height="300"}else{var P=document.createElement("p");P.innerHTML="Signature pad is not available, please include SignaturePad from https://github.com/szimek/signature_pad",this.container.appendChild(P)}}},{key:"setValue",value:function(t){if(typeof SignaturePad=="function"){var e=this.sanitize(t);return this.value===e?void 0:(this.value=e,this.input.value=this.value,this.signaturePad.clear(),t&&t!==""&&this.signaturePad.fromDataURL(t),this.watch_listener(),this.jsoneditor.notifyWatchers(this.path),!1)}}},{key:"destroy",value:function(){this.signaturePad.off(),delete this.signaturePad}}])&&qp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function uo(c){return uo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},uo(c)}function Wp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(uo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(uo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),uo(h)==="symbol"?h:String(h)),i)}var h}function Yn(){return Yn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Qr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Yn.apply(this,arguments)}function xl(c,n){return xl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},xl(c,n)}function Qr(c){return Qr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qr(c)}_(2564);var Zp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&xl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Qr(i);if(h){var o=Qr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(uo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=Yn(Qr(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.simplemde_instance&&this.simplemde_instance.value(u.value)}},{key:"build",value:function(){this.options.format="textarea",Yn(Qr(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t,e=this;window.SimpleMDE?(t=this.expandCallbacks("simplemde",k({},{height:300},this.defaults.options.simplemde||{},this.options.simplemde||{},{element:this.input,forceSync:!0})),this.simplemde_instance=new window.SimpleMDE(t),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&(this.simplemde_instance.codemirror.options.readOnly=!0),this.simplemde_instance.codemirror.on("change",function(){e.value=e.simplemde_instance.value(),e.is_dirty=!0,e.onChange(!0)}),t.autorefresh&&this.startListening(this.simplemde_instance.codemirror,this.simplemde_instance.codemirror.state.autoRefresh={delay:250}),this.theme.afterInputReady(this.input)):Yn(Qr(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.simplemde_instance&&(this.simplemde_instance.codemirror.options.readOnly=!1),Yn(Qr(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.simplemde_instance&&(this.simplemde_instance.codemirror.options.readOnly=!0),Yn(Qr(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.simplemde_instance&&(this.simplemde_instance.toTextArea(),this.simplemde_instance=null),Yn(Qr(l.prototype),"destroy",this).call(this)}},{key:"startListening",value:function(t,e){function o(){t.display.wrapper.offsetHeight?(this.stopListening(t,e),t.display.lastWrapHeight!==t.display.wrapper.clientHeight&&t.refresh()):e.timeout=window.setTimeout(o,e.delay)}e.timeout=window.setTimeout(o,e.delay),e.hurry=function(){window.clearTimeout(e.timeout),e.timeout=window.setTimeout(o,50)},t.on(window,"mouseup",e.hurry),t.on(window,"keyup",e.hurry)}},{key:"stopListening",value:function(t,e){window.clearTimeout(e.timeout),t.off(window,"mouseup",e.hurry),t.off(window,"keyup",e.hurry)}}])&&Wp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function ho(c){return ho=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ho(c)}function Jp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ho(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ho(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ho(h)==="symbol"?h:String(h)),i)}var h}function kl(){return kl=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=po(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},kl.apply(this,arguments)}function jl(c,n){return jl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},jl(c,n)}function po(c){return po=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},po(c)}var Su=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&jl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=po(i);if(h){var o=po(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(ho(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){var t=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.ratingContainer=document.createElement("div"),this.ratingContainer.classList.add("starrating"),this.schema.enum===void 0){var e=this.schema.maximum?this.schema.maximum:5;this.schema.exclusiveMaximum&&e--,this.enum_values=[];for(var o=0;o<e;o++)this.enum_values.push(o+1)}else this.enum_values=this.schema.enum;this.radioGroup=[];for(var u=function(ut){ut.preventDefault(),ut.stopPropagation(),t.setValue(ut.currentTarget.value),t.onChange(!0)},d=this.enum_values.length-1;d>-1;d--){var x=this.formname+(d+1),P=this.theme.getFormInputField("radio");P.name="".concat(this.formname,"[starrating]"),P.value=this.enum_values[d],P.id=x,P.addEventListener("change",u,!1),this.radioGroup.push(P);var D=document.createElement("label");D.htmlFor=x,D.title=this.enum_values[d],this.options.displayValue&&D.classList.add("starrating-display-enabled"),this.ratingContainer.appendChild(P),this.ratingContainer.appendChild(D)}if(this.options.displayValue&&(this.displayRating=document.createElement("div"),this.displayRating.classList.add("starrating-display"),this.displayRating.innerText=this.enum_values[0],this.ratingContainer.appendChild(this.displayRating)),this.schema.readOnly||this.schema.readonly){this.disable(!0);for(var J=0;J<this.radioGroup.length;J++)this.radioGroup[J].disabled=!0;this.ratingContainer.classList.add("readonly")}var nt=this.theme.getContainer();nt.appendChild(this.ratingContainer),this.input=nt,this.control=this.theme.getFormControl(this.label,nt,this.description,this.infoButton),this.container.appendChild(this.control),this.refreshValue()}},{key:"enable",value:function(){if(!this.always_disabled){for(var t=0;t<this.radioGroup.length;t++)this.radioGroup[t].disabled=!1;this.ratingContainer.classList.remove("readonly"),this.disabled=!1}}},{key:"disable",value:function(t){t&&(this.always_disabled=!0);for(var e=0;e<this.radioGroup.length;e++)this.radioGroup[e].disabled=!0;this.ratingContainer.classList.add("readonly"),this.disabled=!0}},{key:"destroy",value:function(){this.ratingContainer.parentNode&&this.ratingContainer.parentNode.parentNode&&this.ratingContainer.parentNode.parentNode.removeChild(this.ratingContainer.parentNode),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),kl(po(l.prototype),"destroy",this).call(this)}},{key:"getNumColumns",value:function(){return 2}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.schema.type==="integer"?this.value===""?void 0:1*this.value:this.value}},{key:"setValue",value:function(t){for(var e=0;e<this.radioGroup.length;e++)if(this.radioGroup[e].value==="".concat(t)){this.radioGroup[e].checked=!0,this.value=t,this.options.displayValue&&(this.displayRating.innerHTML=this.value),this.onChange(!0);break}}}])&&Jp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function fo(c){return fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},fo(c)}function Yp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(fo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(fo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),fo(h)==="symbol"?h:String(h)),i)}var h}function da(){return da=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Xn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},da.apply(this,arguments)}function Ol(c,n){return Ol=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ol(c,n)}function Xn(c){return Xn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Xn(c)}Su.rules={".starrating":"direction:rtl;display:inline-block;white-space:nowrap",".starrating > input":"display:none",".starrating > label:before":"content:'%5C2606';margin:1px;font-size:18px;font-style:normal;font-weight:400;line-height:1;font-family:'Arial';display:inline-block",".starrating > label":"color:%23888;cursor:pointer;margin:8px%200%202px%200",".starrating > label.starrating-display-enabled":"margin:1px%200%200%200",".starrating > input:checked ~ label":"color:%23ffca08",".starrating:not(.readonly) > input:hover ~ label":"color:%23ffca08",".starrating > input:checked ~ label:before":"content:'%5C2605';text-shadow:0%200%201px%20rgba(0%2C20%2C20%2C1)",".starrating:not(.readonly) > input:hover ~ label:before":"content:'%5C2605';text-shadow:0%200%201px%20rgba(0%2C20%2C20%2C1)",".starrating .starrating-display":"position:relative;direction:rtl;text-align:center;font-size:10px;line-height:0px"};var Xp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ol(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Xn(i);if(h){var o=Xn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(fo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){da(Xn(l.prototype),"build",this).call(this),this.input.setAttribute("type","number"),this.input.getAttribute("step")||this.input.setAttribute("step","1");var t=this.theme.getStepperButtons(this.input);this.control.appendChild(t),this.stepperDown=this.control.querySelector(".stepper-down"),this.stepperUp=this.control.querySelector(".stepper-up")}},{key:"enable",value:function(){da(Xn(l.prototype),"enable",this).call(this),this.stepperDown.removeAttribute("disabled"),this.stepperUp.removeAttribute("disabled")}},{key:"disable",value:function(){da(Xn(l.prototype),"disable",this).call(this),this.stepperDown.setAttribute("disabled",!0),this.stepperUp.setAttribute("disabled",!0)}}])&&Yp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(bs);function mo(c){return mo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},mo(c)}function Kp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(mo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(mo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),mo(h)==="symbol"?h:String(h)),i)}var h}function gi(){return gi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=hn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},gi.apply(this,arguments)}function El(c,n){return El=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},El(c,n)}function hn(c){return hn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},hn(c)}var Qp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&El(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=hn(i);if(h){var o=hn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(mo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,f=[{key:"register",value:function(){if(gi(hn(l.prototype),"register",this).call(this),this.rows)for(var t=0;t<this.rows.length;t++)this.rows[t].register()}},{key:"unregister",value:function(){if(gi(hn(l.prototype),"unregister",this).call(this),this.rows)for(var t=0;t<this.rows.length;t++)this.rows[t].unregister()}},{key:"getNumColumns",value:function(){return Math.max(Math.min(12,this.width),3)}},{key:"preBuild",value:function(){var t=this.jsoneditor.expandRefs(this.schema.items||{});this.item_title=t.title||"row",this.item_default=t.default||null,this.item_has_child_editors=t.properties||t.items,this.width=12,this.array_controls_top=this.options.array_controls_top||this.jsoneditor.options.array_controls_top,gi(hn(l.prototype),"preBuild",this).call(this)}},{key:"build",value:function(){this.tableContainer=this.theme.getTableContainer(),this.table=this.theme.getTable(),this.tableContainer.appendChild(this.table),this.container.appendChild(this.tableContainer),this.thead=this.theme.getTableHead(),this.table.appendChild(this.thead),this.header_row=this.theme.getTableRow(),this.thead.appendChild(this.header_row),this.row_holder=this.theme.getTableBody(),this.table.appendChild(this.row_holder);var t=this.getElementEditor(0,!0);if(this.item_default=t.getDefault(),this.width=t.getNumColumns()+2,this.options.compact?(this.panel=document.createElement("div"),this.container.appendChild(this.panel)):(this.header=document.createElement("label"),this.header.textContent=this.getTitle(),this.title=this.theme.getHeader(this.header,this.getPathDepth()),this.container.appendChild(this.title),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText)),this.container.appendChild(this.infoButton)),this.title_controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.title_controls),this.schema.description&&(this.description=this.theme.getDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.description)),this.panel=this.theme.getIndentedPanel(),this.container.appendChild(this.panel),this.error_holder=document.createElement("div"),this.panel.appendChild(this.error_holder)),this.panel.appendChild(this.tableContainer),this.controls=this.theme.getButtonHolder(),this.array_controls_top?this.title.appendChild(this.controls):this.panel.appendChild(this.controls),this.item_has_child_editors)for(var e=t.getChildEditors(),o=t.property_order||Object.keys(e),u=0;u<o.length;u++){var d=this.theme.getTableHeaderCell(e[o[u]].getTitle());e[o[u]].options.hidden&&(d.style.display="none"),this.header_row.appendChild(d)}else this.header_row.appendChild(this.theme.getTableHeaderCell(this.item_title));t.destroy(),this.row_holder.innerHTML="",this.controls_header_cell=this.theme.getTableHeaderCell(" "),this.controls_header_cell.setAttribute("aria-hidden","true"),this.header_row.appendChild(this.controls_header_cell),this.addControls()}},{key:"onChildEditorChange",value:function(t){this.refreshValue(),gi(hn(l.prototype),"onChildEditorChange",this).call(this)}},{key:"getItemDefault",value:function(){return k({},{default:this.item_default}).default}},{key:"getItemTitle",value:function(){return this.item_title}},{key:"getElementEditor",value:function(t,e){var o=k({},this.schema.items),u=this.jsoneditor.getEditorClass(o,this.jsoneditor),d=this.row_holder.appendChild(this.theme.getTableRow()),x=d;this.item_has_child_editors||(x=this.theme.getTableCell(),d.appendChild(x));var P=this.jsoneditor.createEditor(u,{jsoneditor:this.jsoneditor,schema:o,container:x,path:"".concat(this.path,".").concat(t),parent:this,compact:!0,table_row:!0});return P.preBuild(),e||(P.build(),P.postBuild(),P.controls_cell=d.appendChild(this.theme.getTableCell()),P.row=d,P.table_controls=this.theme.getButtonHolder(),P.controls_cell.appendChild(P.table_controls),P.table_controls.style.margin=0,P.table_controls.style.padding=0),P}},{key:"destroy",value:function(){this.innerHTML="",this.checkParent(this.title)&&this.title.parentNode.removeChild(this.title),this.checkParent(this.description)&&this.description.parentNode.removeChild(this.description),this.checkParent(this.row_holder)&&this.row_holder.parentNode.removeChild(this.row_holder),this.checkParent(this.table)&&this.table.parentNode.removeChild(this.table),this.checkParent(this.panel)&&this.panel.parentNode.removeChild(this.panel),this.rows=this.title=this.description=this.row_holder=this.table=this.panel=null,gi(hn(l.prototype),"destroy",this).call(this)}},{key:"ensureArraySize",value:function(t){if(Array.isArray(t)||(t=[t]),this.schema.minItems)for(;t.length<this.schema.minItems;)t.push(this.getItemDefault());return this.schema.maxItems&&t.length>this.schema.maxItems&&(t=t.slice(0,this.schema.maxItems)),t}},{key:"setValue",value:function(){var t=this,e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],o=arguments.length>1?arguments[1]:void 0;if(e=this.ensureArraySize(e),JSON.stringify(e)!==this.serialized){var u=!1;e.forEach(function(P,D){t.rows[D]?t.rows[D].setValue(P):(t.addRow(P),u=!0)});for(var d=e.length;d<this.rows.length;d++){var x=this.rows[d].container;this.item_has_child_editors||this.rows[d].row.parentNode.removeChild(this.rows[d].row),this.rows[d].destroy(),x.parentNode&&x.parentNode.removeChild(x),this.rows[d]=null,u=!0}this.rows=this.rows.slice(0,e.length),this.refreshValue(),(u||o)&&this.refreshRowButtons(),this.onChange()}}},{key:"refreshRowButtons",value:function(){var t=this,e=this.schema.minItems&&this.schema.minItems>=this.rows.length,o=this.schema.maxItems&&this.schema.maxItems<=this.rows.length,u=[];this.rows.forEach(function(nt,ut){if(nt.delete_button){var dt=!e;t.setButtonState(nt.delete_button,dt),u.push(dt)}if(nt.copy_button){var kt=!o;t.setButtonState(nt.copy_button,kt),u.push(kt)}if(nt.moveup_button){var Ct=ut!==0;t.setButtonState(nt.moveup_button,Ct),u.push(Ct)}if(nt.movedown_button){var $t=ut!==t.rows.length-1;t.setButtonState(nt.movedown_button,$t),u.push($t)}});var d=u.some(function(nt){return nt});this.rows.forEach(function(nt){return t.setButtonState(nt.controls_cell,d)}),this.setButtonState(this.controls_header_cell,d),this.setButtonState(this.table,this.value.length);var x=!(o||this.hide_add_button);this.setButtonState(this.add_row_button,x);var P=!(!this.value.length||e||this.hide_delete_last_row_buttons);this.setButtonState(this.delete_last_row_button,P);var D=!(this.value.length<=1||e||this.hide_delete_all_rows_buttons);this.setButtonState(this.remove_all_rows_button,D);var J=x||P||D;this.setButtonState(this.controls,J)}},{key:"refreshValue",value:function(){var t=this;this.value=[],this.rows.forEach(function(e,o){t.value[o]=e.getValue()}),this.serialized=JSON.stringify(this.value)}},{key:"addRow",value:function(t){var e=this.rows.length;this.rows[e]=this.getElementEditor(e);var o=this.rows[e].table_controls;return this.hide_delete_buttons||(this.rows[e].delete_button=this._createDeleteButton(e,o)),this.show_copy_button&&(this.rows[e].copy_button=this._createCopyButton(e,o)),this.hide_move_buttons||(this.rows[e].moveup_button=this._createMoveUpButton(e,o)),this.hide_move_buttons||(this.rows[e].movedown_button=this._createMoveDownButton(e,o)),t!==void 0&&this.rows[e].setValue(t),this.rows[e]}},{key:"_createDeleteButton",value:function(t,e){var o=this,u=this.getButton("","delete","button_delete_row_title_short");return u.classList.add("delete","json-editor-btntype-delete"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){if(d.preventDefault(),d.stopPropagation(),!o.askConfirmation())return!1;var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue(),D=o.getValue()[x];P.splice(x,1),o.setValue(P),o.onChange(!0),o.jsoneditor.trigger("deleteRow",D)}),e.appendChild(u),u}},{key:"_createCopyButton",value:function(t,e){var o=this,u=this.getButton("","copy","button_copy_row_title_short"),d=this.schema;return u.classList.add("copy","json-editor-btntype-copy"),u.setAttribute("data-i",t),u.addEventListener("click",function(x){x.preventDefault(),x.stopPropagation();var P=1*x.currentTarget.getAttribute("data-i"),D=o.getValue(),J=D[P];d.items.type==="string"&&d.items.format==="uuid"?J=R():d.items.type==="object"&&d.items.properties&&D.forEach(function(nt,ut){if(P===ut)for(var dt=0,kt=Object.keys(nt);dt<kt.length;dt++){var Ct=kt[dt];d.items.properties&&d.items.properties[Ct]&&d.items.properties[Ct].format==="uuid"&&((J=Object.assign({},D[P]))[Ct]=R())}}),D.splice(P+1,0,J),o.setValue(D),o.onChange(!0),o.jsoneditor.trigger("copyRow",o.rows[P+1])}),e.appendChild(u),u}},{key:"_createMoveUpButton",value:function(t,e){var o=this,u=this.getButton("","moveup","button_move_up_title");return u.classList.add("moveup","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue();P.splice(x-1,0,P.splice(x,1)[0]),o.setValue(P),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x-1])}),e.appendChild(u),u}},{key:"_createMoveDownButton",value:function(t,e){var o=this,u=this.getButton("","movedown","button_move_down_title");return u.classList.add("movedown","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue();P.splice(x+1,0,P.splice(x,1)[0]),o.setValue(P),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x+1])}),e.appendChild(u),u}},{key:"addControls",value:function(){var t=this;this.collapsed=!1,this.toggle_button=this._createToggleButton(),this.title_controls&&(this.title.insertBefore(this.toggle_button,this.title.childNodes[0]),this.toggle_button.addEventListener("click",function(e){e.preventDefault(),e.stopPropagation(),t.setButtonState(t.panel,t.collapsed),t.collapsed?(t.collapsed=!1,t.setButtonText(e.currentTarget,"","collapse","button_collapse")):(t.collapsed=!0,t.setButtonText(e.currentTarget,"","expand","button_expand"))}),this.options.collapsed&&O(this.toggle_button,"click"),this.schema.options&&this.schema.options.disable_collapse!==void 0?this.schema.options.disable_collapse&&(this.toggle_button.style.display="none"):this.jsoneditor.options.disable_collapse&&(this.toggle_button.style.display="none")),this.add_row_button=this._createAddRowButton(),this.delete_last_row_button=this._createDeleteLastRowButton(),this.remove_all_rows_button=this._createRemoveAllRowsButton()}},{key:"_createToggleButton",value:function(){var t=this.getButton("","collapse","button_collapse");return t.classList.add("json-editor-btntype-toggle"),t}},{key:"_createAddRowButton",value:function(){var t=this,e=this.getButton(this.getItemTitle(),"add","button_add_row_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-add"),e.addEventListener("click",function(o){o.preventDefault(),o.stopPropagation();var u=t.addRow();t.refreshValue(),t.refreshRowButtons(),t.onChange(!0),t.jsoneditor.trigger("addRow",u)}),this.controls.appendChild(e),e}},{key:"_createDeleteLastRowButton",value:function(){var t=this,e=this.getButton("button_delete_last","subtract","button_delete_last_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-deletelast"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue(),d=u.pop();t.setValue(u),t.onChange(!0),t.jsoneditor.trigger("deleteRow",d)}),this.controls.appendChild(e),e}},{key:"_createRemoveAllRowsButton",value:function(){var t=this,e=this.getButton("button_delete_all","delete","button_delete_all_title");return e.classList.add("json-editor-btntype-deleteall"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue();t.setValue([]),t.onChange(!0),t.jsoneditor.trigger("deleteAllRows",u)}),this.controls.appendChild(e),e}}],f&&Kp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Ut);function yo(c){return yo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},yo(c)}function tf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(yo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(yo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),yo(h)==="symbol"?h:String(h)),i)}var h}function pa(){return pa=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Kn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},pa.apply(this,arguments)}function Cl(c,n){return Cl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Cl(c,n)}function Kn(c){return Kn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Kn(c)}function bo(c){return bo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},bo(c)}function ef(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(bo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(bo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),bo(h)==="symbol"?h:String(h)),i)}var h}function fa(){return fa=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Qn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},fa.apply(this,arguments)}function Sl(c,n){return Sl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Sl(c,n)}function Qn(c){return Qn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qn(c)}function vo(c){return vo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},vo(c)}function rf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(vo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(vo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),vo(h)==="symbol"?h:String(h)),i)}var h}function wi(){return wi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=dn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},wi.apply(this,arguments)}function Pl(c,n){return Pl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Pl(c,n)}function dn(c){return dn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},dn(c)}_(6977);var _s={ace:Et,array:Ut,arrayChoices:cr,arraySelect2:pr,arraySelectize:Ze,autocomplete:Dn,base64:Vi,button:hs,checkbox:ps,choices:rt,datetime:vt,describedBy:ir,enum:$e,hidden:fs,info:qi,integer:bs,ip:ra,jodit:vs,multiple:to,multiselect:qt,null:ca,number:ys,object:bi,radio:at,sceditor:ao,select:hi,select2:Vp,selectize:Up,signature:Gp,simplemde:Zp,starrating:Su,stepper:Xp,string:K,table:Qp,upload:function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Cl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Kn(i);if(h){var o=Kn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(yo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 4}},{key:"build",value:function(){var t=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.hidden&&(this.container.style.display="none"),this.options=this.expandCallbacks("upload",k({},{title:"Browse",icon:"",auto_upload:!1,hide_input:!1,enable_drag_drop:!1,drop_zone_text:"Drag & Drop file here",drop_zone_top:!1,alt_drop_zone:"",mime_type:"",max_upload_size:0,upload_handler:function(u,d,x,P){window.alert('No upload_handler defined for "'.concat(u.path,'". You must create your own handler to enable upload to server'))}},this.defaults.options.upload||{},this.options.upload||{})),this.options.mime_type=this.options.mime_type?[].concat(this.options.mime_type):[],this.input=this.theme.getFormInputField("hidden"),this.container.appendChild(this.input),!this.schema.readOnly&&!this.schema.readonly){if(typeof this.options.upload_handler!="function")throw new Error("Upload handler required for upload editor");if(this.uploader=this.theme.getFormInputField("file"),this.uploader.style.display="none",this.options.mime_type.length&&this.uploader.setAttribute("accept",this.options.mime_type),this.options.enable_drag_drop===!0&&this.options.hide_input===!0||(this.clickHandler=function(u){t.uploader.dispatchEvent(new window.MouseEvent("click",{view:window,bubbles:!0,cancelable:!1}))},this.browseButton=this.getButton(this.options.title,this.options.icon,this.options.title),this.browseButton.addEventListener("click",this.clickHandler),this.fileDisplay=this.theme.getFormInputField("input"),this.fileDisplay.setAttribute("readonly",!0),this.fileDisplay.value="No file selected.",this.fileDisplay.addEventListener("dblclick",this.clickHandler),this.fileUploadGroup=this.theme.getInputGroup(this.fileDisplay,[this.browseButton]),this.fileUploadGroup||(this.fileUploadGroup=document.createElement("div"),this.fileUploadGroup.appendChild(this.fileDisplay),this.fileUploadGroup.appendChild(this.browseButton))),this.options.enable_drag_drop===!0){if(this.options.alt_drop_zone!==""){if(this.altDropZone=document.querySelector(this.options.alt_drop_zone),!this.altDropZone)throw new Error('Error: alt_drop_zone selector "'.concat(this.options.alt_drop_zone,'" not found!'));this.dropZone=this.altDropZone}else this.dropZone=this.theme.getDropZone(this.options.drop_zone_text);this.dropZone&&(this.dropZone.classList.add("upload-dropzone"),this.dropZone.addEventListener("dblclick",this.clickHandler))}this.uploadHandler=function(u){u.preventDefault(),u.stopPropagation();var d=u.target.files||u.dataTransfer.files;if(d&&d.length)if(t.options.max_upload_size!==0&&d[0].size>t.options.max_upload_size)t.theme.addInputError(t.uploader,"".concat(t.translate("upload_max_size")," ").concat(t.options.max_upload_size));else if(t.options.mime_type.length===0||t.isValidMimeType(d[0].type,t.options.mime_type)){t.fileDisplay&&(t.fileDisplay.value=d[0].name);var x=new window.FileReader;x.onload=function(P){t.preview_value=P.target.result,t.refreshPreview(d),t.onChange(!0),x=null},x.readAsDataURL(d[0])}else t.theme.addInputError(t.uploader,"".concat(t.translate("upload_wrong_file_format")," ").concat(t.options.mime_type.toString()))},this.uploader.addEventListener("change",this.uploadHandler),this.dragHandler=function(u){var d=u.dataTransfer.items||u.dataTransfer.files,x=d&&d.length&&(t.options.mime_type.length===0||t.isValidMimeType(d[0].type,t.options.mime_type)),P=u.currentTarget.classList&&u.currentTarget.classList.contains("upload-dropzone")&&x;switch((u.currentTarget===window?"w_":"e_")+u.type){case"w_drop":case"w_dragover":P||(u.dataTransfer.dropEffect="none");break;case"e_dragenter":P?(t.dropZone.classList.add("valid-dropzone"),u.dataTransfer.dropEffect="copy"):t.dropZone.classList.add("invalid-dropzone");break;case"e_dragover":P&&(u.dataTransfer.dropEffect="copy");break;case"e_dragleave":t.dropZone.classList.remove("valid-dropzone","invalid-dropzone");break;case"e_drop":t.dropZone.classList.remove("valid-dropzone","invalid-dropzone"),P&&t.uploadHandler(u)}P||u.preventDefault()},this.options.enable_drag_drop===!0&&(["dragover","drop"].forEach(function(u){window.addEventListener(u,t.dragHandler,!0)}),["dragenter","dragover","dragleave","drop"].forEach(function(u){t.dropZone.addEventListener(u,t.dragHandler,!0)}))}this.preview=document.createElement("div"),this.control=this.input.controlgroup=this.theme.getFormControl(this.label,this.uploader||this.input,this.description,this.infoButton),this.uploader&&(this.uploader.controlgroup=this.control);var e=this.uploader||this.input,o=document.createElement("div");this.dropZone&&!this.altDropZone&&this.options.drop_zone_top===!0&&o.appendChild(this.dropZone),this.fileUploadGroup&&o.appendChild(this.fileUploadGroup),this.dropZone&&!this.altDropZone&&this.options.drop_zone_top!==!0&&o.appendChild(this.dropZone),o.appendChild(this.preview),e.parentNode.insertBefore(o,e.nextSibling),this.container.appendChild(this.control),window.requestAnimationFrame(function(){t.afterInputReady()})}},{key:"afterInputReady",value:function(){var t=this;if(this.value){var e=document.createElement("img");e.style.maxWidth="100%",e.style.maxHeight="100px",e.onload=function(o){t.preview.appendChild(e)},e.onerror=function(o){console.error("upload error",o,o.currentTarget)},e.src=this.container.querySelector("a").href}this.theme.afterInputReady(this.input)}},{key:"refreshPreview",value:function(t){var e=this;if(this.last_preview!==this.preview_value&&(this.last_preview=this.preview_value,this.preview.innerHTML="",this.preview_value)){var o=t[0],u=this.preview_value.match(/^data:([^;,]+)[;,]/);if(o.mimeType=u?u[1]:"unknown",o.size>0){var d=Math.floor(Math.log(o.size)/Math.log(1024));o.formattedSize="".concat(parseFloat((o.size/Math.pow(1024,d)).toFixed(2))," ").concat(["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][d])}else o.formattedSize="0 Bytes";var x=this.getButton("button_upload","upload","button_upload");x.addEventListener("click",function(P){P.preventDefault(),x.setAttribute("disabled","disabled"),e.theme.removeInputError(e.uploader),e.theme.getProgressBar&&(e.progressBar=e.theme.getProgressBar(),e.preview.appendChild(e.progressBar)),e.options.upload_handler(e.path,o,{success:function(D){e.setValue(D),e.parent?e.parent.onChildEditorChange(e):e.jsoneditor.onChange(),e.progressBar&&e.preview.removeChild(e.progressBar),x.removeAttribute("disabled")},failure:function(D){e.theme.addInputError(e.uploader,D),e.progressBar&&e.preview.removeChild(e.progressBar),x.removeAttribute("disabled")},updateProgress:function(D){e.progressBar&&(D?e.theme.updateProgressBar(e.progressBar,D):e.theme.updateProgressBarUnknown(e.progressBar))}})}),this.preview.appendChild(this.theme.getUploadPreview(o,x,this.preview_value)),this.options.auto_upload&&(x.dispatchEvent(new window.MouseEvent("click")),x.parentNode.removeChild(x))}}},{key:"enable",value:function(){this.always_disabled||(this.uploader&&(this.uploader.disabled=!1),pa(Kn(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.uploader&&(this.uploader.disabled=!0),pa(Kn(l.prototype),"disable",this).call(this)}},{key:"setValue",value:function(t){this.value!==t&&(this.value=t,this.input.value=this.value,this.onChange())}},{key:"destroy",value:function(){var t=this;this.options.enable_drag_drop===!0&&(["dragover","drop"].forEach(function(e){window.removeEventListener(e,t.dragHandler,!0)}),["dragenter","dragover","dragleave","drop"].forEach(function(e){t.dropZone.removeEventListener(e,t.dragHandler,!0)}),this.dropZone.removeEventListener("dblclick",this.clickHandler),this.dropZone&&this.dropZone.parentNode&&this.dropZone.parentNode.removeChild(this.dropZone)),this.uploader&&this.uploader.parentNode&&(this.uploader.removeEventListener("change",this.uploadHandler),this.uploader.parentNode.removeChild(this.uploader)),this.browseButton&&this.browseButton.parentNode&&(this.browseButton.removeEventListener("click",this.clickHandler),this.browseButton.parentNode.removeChild(this.browseButton)),this.fileDisplay&&this.fileDisplay.parentNode&&(this.fileDisplay.removeEventListener("dblclick",this.clickHandler),this.fileDisplay.parentNode.removeChild(this.fileDisplay)),this.fileUploadGroup&&this.fileUploadGroup.parentNode&&this.fileUploadGroup.parentNode.removeChild(this.fileUploadGroup),this.preview&&this.preview.parentNode&&this.preview.parentNode.removeChild(this.preview),this.header&&this.header.parentNode&&this.header.parentNode.removeChild(this.header),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),pa(Kn(l.prototype),"destroy",this).call(this)}},{key:"isValidMimeType",value:function(t,e){return e.reduce(function(o,u){return o||new RegExp(u.replace(/\*/g,".*"),"gi").test(t)},!1)}}])&&tf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F),uuid:function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Sl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Qn(i);if(h){var o=Qn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(bo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"preBuild",value:function(){fa(Qn(l.prototype),"preBuild",this).call(this),this.schema.default=this.uuid=this.getUuid(),this.schema.options||(this.schema.options={}),this.schema.options.cleave||(this.schema.options.cleave={delimiters:["-"],blocks:[8,4,4,4,12]})}},{key:"build",value:function(){fa(Qn(l.prototype),"build",this).call(this),this.disable(!0),this.input.setAttribute("readonly","true")}},{key:"sanitize",value:function(t){return this.testUuid(t)||(t=this.uuid),t}},{key:"setValue",value:function(t,e,o){this.testUuid(t)||(t=this.uuid),this.uuid=t,fa(Qn(l.prototype),"setValue",this).call(this,t,e,o)}},{key:"getUuid",value:function(){return R()}},{key:"testUuid",value:function(t){return/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(t)}}])&&ef(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K),colorpicker:function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Pl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=dn(i);if(h){var o=dn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(vo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"postBuild",value:function(){window.Picker&&(this.input.type="text"),this.input.style.padding="3px"}},{key:"setValue",value:function(t,e,o){var u=wi(dn(l.prototype),"setValue",this).call(this,t,e,o);return this.picker_instance&&this.picker_instance.domElement&&u&&u.changed&&this.picker_instance.setColor(u.value,!0),u}},{key:"getNumColumns",value:function(){return 2}},{key:"afterInputReady",value:function(){wi(dn(l.prototype),"afterInputReady",this).call(this),this.createPicker(!0)}},{key:"disable",value:function(){if(wi(dn(l.prototype),"disable",this).call(this),this.picker_instance&&this.picker_instance.domElement){this.picker_instance.domElement.style.pointerEvents="none";for(var t=this.picker_instance.domElement.querySelectorAll("button"),e=0;e<t.length;e++)t[e].disabled=!0}}},{key:"enable",value:function(){if(wi(dn(l.prototype),"enable",this).call(this),this.picker_instance&&this.picker_instance.domElement){this.picker_instance.domElement.style.pointerEvents="auto";for(var t=this.picker_instance.domElement.querySelectorAll("button"),e=0;e<t.length;e++)t[e].disabled=!1}}},{key:"destroy",value:function(){this.createPicker(!1),wi(dn(l.prototype),"destroy",this).call(this)}},{key:"createPicker",value:function(t){var e=this;if(t){if(window.Picker&&!this.picker_instance){var o=this.expandCallbacks("colorpicker",k({},{editor:!1,alpha:!1,color:this.value,popup:"bottom"},this.defaults.options.colorpicker||{},this.options.colorpicker||{},{parent:this.container})),u=function(d){var x=e.picker_instance.settings.editorFormat,P=e.picker_instance.settings.alpha;e.setValue(x==="hex"?P?d.hex:d.hex.slice(0,7):d["".concat(x+(P?"a":""),"String")])};o.popup||typeof o.onChange=="function"?o.popup&&typeof o.onDone!="function"&&(o.onDone=u):o.onChange=u,this.picker_instance=new window.Picker(o),o.popup||(this.input.style.display="none",this.theme.afterInputReady(this.picker_instance.domElement))}}else this.picker_instance&&(this.picker_instance.destroy(),this.picker_instance=null,this.input.style.display="")}}])&&rf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K)};function Pu(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}var Tu={},Tl="en",nf=Tl;Tu.en={error_notset:"Property must be set",error_notempty:"Value required",error_enum:"Value must be one of the enumerated values",error_const:"Value must be the constant value",error_anyOf:"Value must validate against at least one of the provided schemas",error_oneOf:"Value must validate against exactly one of the provided schemas. It currently validates against {{0}} of the schemas.",error_not:"Value must not validate against the provided schema",error_type_union:"Value must be one of the provided types",error_type:"Value must be of type {{0}}",error_disallow_union:"Value must not be one of the provided disallowed types",error_disallow:"Value must not be of type {{0}}",error_multipleOf:"Value must be a multiple of {{0}}",error_maximum_excl:"Value must be less than {{0}}",error_maximum_incl:"Value must be at most {{0}}",error_minimum_excl:"Value must be greater than {{0}}",error_minimum_incl:"Value must be at least {{0}}",error_maxLength:"Value must be at most {{0}} characters long",error_contains:"No items match contains",error_minContains:"Contains match count {{0}} is less than minimum contains count of {{1}}",error_maxContains:"Contains match count {{0}} exceeds maximum contains count of {{1}}",error_minLength:"Value must be at least {{0}} characters long",error_pattern:"Value must match the pattern {{0}}",error_additionalItems:"No additional items allowed in this array",error_maxItems:"Value must have at most {{0}} items",error_minItems:"Value must have at least {{0}} items",error_uniqueItems:"Array must have unique items",error_maxProperties:"Object must have at most {{0}} properties",error_minProperties:"Object must have at least {{0}} properties",error_required:"Object is missing the required property '{{0}}'",error_additional_properties:"No additional properties allowed, but property {{0}} is set",error_property_names_exceeds_maxlength:"Property name {{0}} exceeds maxLength",error_property_names_enum_mismatch:"Property name {{0}} does not match any enum values",error_property_names_const_mismatch:"Property name {{0}} does not match the const value",error_property_names_pattern_mismatch:"Property name {{0}} does not match pattern",error_property_names_false:"Property name {{0}} fails when propertyName is false",error_property_names_maxlength:"Property name {{0}} cannot match invalid maxLength",error_property_names_enum:"Property name {{0}} cannot match invalid enum",error_property_names_pattern:"Property name {{0}} cannot match invalid pattern",error_property_names_unsupported:"Unsupported propertyName {{0}}",error_dependency:"Must have property {{0}}",error_date:"Date must be in the format {{0}}",error_time:"Time must be in the format {{0}}",error_datetime_local:"Datetime must be in the format {{0}}",error_invalid_epoch:"Date must be greater than 1 January 1970",error_ipv4:"Value must be a valid IPv4 address in the form of 4 numbers between 0 and 255, separated by dots",error_ipv6:"Value must be a valid IPv6 address",error_hostname:"The hostname has the wrong format",upload_max_size:"Filesize too large. Max size is ",upload_wrong_file_format:"Wrong file format. Allowed format(s): ",button_save:"Save",button_copy:"Copy",button_cancel:"Cancel",button_add:"Add",button_delete_all:"All",button_delete_all_title:"Delete All",button_delete_last:"Last {{0}}",button_delete_last_title:"Delete Last {{0}}",button_add_row_title:"Add {{0}}",button_move_down_title:"Move down",button_move_up_title:"Move up",button_properties:"Properties",button_object_properties:"Object Properties",button_copy_row_title:"Copy {{0}}",button_delete_row_title:"Delete {{0}}",button_delete_row_title_short:"Delete",button_copy_row_title_short:"Copy",button_collapse:"Collapse",button_expand:"Expand",button_edit_json:"Edit JSON",button_upload:"Upload",flatpickr_toggle_button:"Toggle",flatpickr_clear_button:"Clear",choices_placeholder_text:"Start typing to add value",default_array_item_title:"item",button_delete_node_warning:"Are you sure you want to remove this item?"},Object.entries(_s).forEach(function(c){var n=function(h,a){return function(l){if(Array.isArray(l))return l}(h)||function(l,t){var e=l==null?null:typeof Symbol<"u"&&l[Symbol.iterator]||l["@@iterator"];if(e!=null){var o,u,d,x,P=[],D=!0,J=!1;try{if(d=(e=e.call(l)).next,t===0){if(Object(e)!==e)return;D=!1}else for(;!(D=(o=d.call(e)).done)&&(P.push(o.value),P.length!==t);D=!0);}catch(nt){J=!0,u=nt}finally{try{if(!D&&e.return!=null&&(x=e.return(),Object(x)!==x))return}finally{if(J)throw u}}return P}}(h,a)||function(l,t){if(l){if(typeof l=="string")return Pu(l,t);var e=Object.prototype.toString.call(l).slice(8,-1);return e==="Object"&&l.constructor&&(e=l.constructor.name),e==="Map"||e==="Set"?Array.from(l):e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?Pu(l,t):void 0}}(h,a)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
80
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}(c,2),f=n[0],i=n[1];_s[f].options=i.options||{}});var _i={options:{upload:function(c,n,f){console.log("Upload handler required for upload editor")},use_name_attributes:!0,prompt_before_delete:!0,use_default_values:!0,max_depth:0,button_state_mode:1,case_sensitive_property_search:!0},theme:"html",template:"default",themes:{},callbacks:{},templates:{},iconlibs:{},editors:_s,languages:Tu,resolvers:j,custom_validators:[],default_language:Tl,language:nf,translate:function(c,n,f){var i={};f&&f.options&&f.options.error_messages&&f.options.error_messages[_i.language]&&(i=f.options.error_messages[_i.language]);var h=_i.languages[_i.language];if(!h)throw new Error("Unknown language ".concat(_i.language));var a=i[c]||h[c]||_i.languages[Tl][c]||c;if(n)for(var l=0;l<n.length;l++)a=a.replace(new RegExp("\\{\\{".concat(l,"}}"),"g"),n[l]);return a},translateProperty:function(c,n){return c}};function xi(){xi=function(){return c};var c={},n=Object.prototype,f=n.hasOwnProperty,i=Object.defineProperty||function(W,G,Z){W[G]=Z.value},h=typeof Symbol=="function"?Symbol:{},a=h.iterator||"@@iterator",l=h.asyncIterator||"@@asyncIterator",t=h.toStringTag||"@@toStringTag";function e(W,G,Z){return Object.defineProperty(W,G,{value:Z,enumerable:!0,configurable:!0,writable:!0}),W[G]}try{e({},"")}catch{e=function(G,Z,pt){return G[Z]=pt}}function o(W,G,Z,pt){var et=G&&G.prototype instanceof x?G:x,Lt=Object.create(et.prototype),re=new gt(pt||[]);return i(Lt,"_invoke",{value
|
|
81
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Ru(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function ur(c){return ur=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ur(c)}function of(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ur(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ur(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ur(h)==="symbol"?h:String(h)),i)}var h}_(8733);var af=function(){function c(a){(function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")})(this,c),this.options=a||{},this.schema={},this.refs=this.options.refs||{},this.refs_with_info={},this.refs_prefix="#/counter/",this.refs_counter=1,this._subSchema1={type:function(l){ur(l.type)==="object"&&(l.type=this._expandSubSchema(l.type))},disallow:function(l){ur(l.disallow)==="object"&&(l.disallow=this._expandSubSchema(l.disallow))},anyOf:function(l){var t=this;Object.entries(l.anyOf).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];l.anyOf[u]=t.expandSchema(d)})},dependencies:function(l){var t=this;Object.entries(l.dependencies).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];ur(d)!=="object"||Array.isArray(d)||(l.dependencies[u]=t.expandSchema(d))})},not:function(l){l.not=this.expandSchema(l.not)}},this._subSchema2={allOf:function(l,t){var e=this,o=k({},t);return Object.entries(l.allOf).forEach(function(u){var d=ki(u,2),x=d[0],P=d[1];l.allOf[x]=e.expandRefs(P,!0),o=e.extendSchemas(o,e.expandSchema(P))}),delete o.allOf,o},extends:function(l,t){var e,o=this;return delete(e=Array.isArray(l.extends)?l.extends.reduce(function(u,d,x){return o.extendSchemas(u,o.expandSchema(d))},t):this.extendSchemas(t,this.expandSchema(l.extends))).extends,e},oneOf:function(l,t){var e=this,o=k({},t);return delete o.oneOf,l.oneOf.reduce(function(u,d,x){return u.oneOf[x]=e.extendSchemas(e.expandSchema(d),o),u},t),t}}}var n,f,i,h;return n=c,f=[{key:"load",value:(h=Lu(xi().mark(function a(l,t,e){return xi().wrap(function(o){for(;;)switch(o.prev=o.next){case 0:return this.schema=l,o.next=3,this._asyncloadExternalRefs(l,t,this._getFileBase(e),!0);case 3:return o.abrupt("return",this.expandRefs(l));case 4:case"end":return o.stop()}},a,this)})),function(a,l,t){return h.apply(this,arguments)})},{key:"expandRefs",value:function(a,l){var t=this,e=k({},a);if(!e.$ref)return e;var o=e.$ref.split("#");if(o.length===2&&!this.refs_with_info[e.$ref]){var u=this.expandRecursivePointer(this.schema,o[1]),d=this.extendSchemas(e,this.expandSchema(u));return delete d.$ref,d}var x=o.length>2?this.refs_with_info["#"+o[1]]:this.refs_with_info[e.$ref];delete e.$ref;var P=x.$ref.startsWith("#")?x.fetchUrl:"",D=this._getRef(P,x);if(this.refs[D]){if(l&&S(this.refs[D],"allOf")){var J=this.refs[D].allOf;Object.keys(J).forEach(function(nt){J[nt]=t.expandRefs(J[nt],!0)})}}else console.warn("reference:'".concat(D,"' not found!"));return o.length>2?this.extendSchemas(e,this.expandSchema(this.expandRecursivePointer(this.refs[D],o[2]))):this.extendSchemas(e,this.expandSchema(this.refs[D]))}},{key:"expandRecursivePointer",value:function(a,l){var t=a;return l.split("/").slice(1).forEach(function(e){t[e]&&(t=t[e])}),t.$refs&&t.$refs.startsWith("#")?this.expandRecursivePointer(a,t.$refs):t}},{key:"expandSchema",value:function(a){var l=this;Object.entries(this._subSchema1).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];a[u]&&d.call(l,a)});var t=k({},a);return Object.entries(this._subSchema2).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];a[u]&&(t=d.call(l,a,t))}),this.expandRefs(t)}},{key:"_getRef",value:function(a,l){var t=a+l;return this.refs[t]?t:a+decodeURIComponent(l.$ref)}},{key:"_expandSubSchema",value:function(a){var l=this;return Array.isArray(a)?a.map(function(t){return ur(t)==="object"?l.expandSchema(t):t}):this.expandSchema(a)}},{key:"_manageRecursivePointer",value:function(a,l){Object.keys(a).forEach(function(t){a[t].$ref&&a[t].$ref.indexOf("#")===0&&(a[t].$ref=l+a[t].$ref)})}},{key:"_getExternalRefs",value:function(a,l){var t=this,e=arguments.length>2&&arguments[2]!==void 0&&arguments[2];e||this._manageRecursivePointer(a,l);var o={},u=function(J){return Object.keys(J).forEach(function(nt){o[nt]=!0})};if(a.$ref&&ur(a.$ref)!=="object"&&(a.$ref.indexOf("#")!==0||!e)){var d=a.$ref,x="";d.indexOf("#")>0&&(d=d.substr(0,d.indexOf("#"))),d!==a.$ref&&(x=a.$ref.substr(a.$ref.indexOf("#")));var P=this.refs_prefix+this.refs_counter++,D=P+x;a.$ref.substr(0,1)==="#"||this.refs[a.$ref]||(o[d]=!0),this.refs_with_info[P]={fetchUrl:l,$ref:d},a.$ref=D}return Object.values(a).forEach(function(J){J&&ur(J)==="object"&&(Array.isArray(J)?Object.values(J).forEach(function(nt){nt&&ur(nt)==="object"&&u(t._getExternalRefs(nt,l,e))}):J.$ref&&typeof J.$ref=="string"&&J.$ref.startsWith("#")||u(t._getExternalRefs(J,l,e)))}),a.id&&typeof a.id=="string"&&a.id.substr(0,4)==="urn:"?this.refs[a.id]=a:a.$id&&typeof a.$id=="string"&&a.$id.substr(0,4)==="urn:"&&(this.refs[a.$id]=a),o}},{key:"_getFileBase",value:function(a){if(!a)return"/";var l=this.options.ajaxBase;return l===void 0?this._getFileBaseFromFileLocation(a):l}},{key:"_getFileBaseFromFileLocation",value:function(a){var l=a.split("/");return l.pop(),"".concat(l.join("/"),"/")}},{key:"_joinUrl",value:function(a,l){var t=a;return a.substr(0,7)!=="http://"&&a.substr(0,8)!=="https://"&&a.substr(0,5)!=="blob:"&&a.substr(0,5)!=="data:"&&a.substr(0,1)!=="#"&&a.substr(0,1)!=="/"&&(t=l+a),t.indexOf("#")>0&&(t=t.substr(0,t.indexOf("#"))),t}},{key:"_isUniformResourceName",value:function(a){return a.substr(0,4)==="urn:"}},{key:"_asyncloadExternalRefs",value:(i=Lu(xi().mark(function a(l,t,e){var o,u,d,x,P,D,J=this,nt=arguments;return xi().wrap(function(ut){for(;;)switch(ut.prev=ut.next){case 0:o=nt.length>3&&nt[3]!==void 0&&nt[3],u=this._getExternalRefs(l,t,o),d=0,x=xi().mark(function dt(){var kt,Ct,$t,ne,Re,Gt,gt,Zt,Ge,W,G;return xi().wrap(function(Z){for(;;)switch(Z.prev=Z.next){case 0:if((kt=D[P])!==void 0){Z.next=3;break}return Z.abrupt("return","continue");case 3:if(!J.refs[kt]){Z.next=5;break}return Z.abrupt("return","continue");case 5:if(!J._isUniformResourceName(kt)){Z.next=40;break}if(J.refs[kt]="loading",d++,Ct=J.options.urn_resolver,$t=kt,typeof Ct=="function"){Z.next=13;break}throw console.log('No "urn_resolver" callback defined to resolve "'.concat($t,'"')),new Error("Must set urn_resolver option to a callback to resolve ".concat($t));case 13:return $t.indexOf("#")>0&&($t=$t.substr(0,$t.indexOf("#"))),Z.prev=14,Z.next=17,Ct($t);case 17:ne=Z.sent,Z.prev=18,Re=JSON.parse(ne),Z.next=26;break;case 22:throw Z.prev=22,Z.t0=Z.catch(18),console.log(Z.t0),new Error("Failed to parse external ref ".concat($t));case 26:if(!(typeof Re!="boolean"&&ur(Re)!=="object"||Re===null||Array.isArray(Re))){Z.next=28;break}throw new Error("External ref does not contain a valid schema - ".concat($t));case 28:return J.refs[kt]=Re,Z.next=31,J._asyncloadExternalRefs(Re,kt,e);case 31:Z.next=37;break;case 33:throw Z.prev=33,Z.t1=Z.catch(14),console.log(Z.t1),new Error("Failed to parse external ref ".concat($t));case 37:if(typeof ne!="boolean"){Z.next=39;break}throw new Error("External ref does not contain a valid schema - ".concat($t));case 39:return Z.abrupt("return","continue");case 40:if(J.options.ajax){Z.next=42;break}throw new Error("Must set ajax option to true to load external ref ".concat(kt));case 42:if(d++,Gt=J._joinUrl(kt,e),J.options.ajax_cache_responses&&(Zt=J.cacheGet(Gt))&&(gt=Zt),gt){Z.next=61;break}return Z.next=48,new Promise(function(pt){var et=new XMLHttpRequest;J.options.ajaxCredentials&&(et.withCredentials=J.options.ajaxCredentials),et.overrideMimeType("application/json"),et.open("GET",Gt,!0),et.onload=function(){pt(et)},et.onerror=function(Lt){pt(void 0)},et.send()});case 48:if((Ge=Z.sent)!==void 0){Z.next=51;break}throw new Error("Failed to fetch ref via ajax - ".concat(kt));case 51:Z.prev=51,gt=JSON.parse(Ge.responseText),J.onSchemaLoaded({schema:gt,schemaUrl:Gt}),J.options.ajax_cache_responses&&J.cacheSet(Gt,gt),Z.next=61;break;case 57:throw Z.prev=57,Z.t2=Z.catch(51),console.log(Z.t2),new Error("Failed to parse external ref ".concat(Gt));case 61:if(!(typeof gt!="boolean"&&ur(gt)!=="object"||gt===null||Array.isArray(gt))){Z.next=63;break}throw new Error("External ref does not contain a valid schema - ".concat(Gt));case 63:return J.refs[kt]=gt,W=J._getFileBaseFromFileLocation(Gt),Gt!==kt&&(G=Gt.split("/"),Gt=(kt.substr(0,1)==="/"?"/":"")+G.pop()),Z.next=68,J._asyncloadExternalRefs(gt,Gt,W);case 68:case"end":return Z.stop()}},dt,null,[[14,33],[18,22],[51,57]])}),P=0,D=Object.keys(u);case 5:if(!(P<D.length)){ut.next=13;break}return ut.delegateYield(x(),"t0",7);case 7:if(ut.t0!=="continue"){ut.next=10;break}return ut.abrupt("continue",10);case 10:P++,ut.next=5;break;case 13:if(d){ut.next=15;break}return ut.abrupt("return",!0);case 15:this.onAllSchemasLoaded();case 16:case"end":return ut.stop()}},a,this)})),function(a,l,t){return i.apply(this,arguments)})},{key:"onSchemaLoaded",value:function(a){}},{key:"onAllSchemasLoaded",value:function(){}},{key:"extendSchemas",value:function(a,l){var t=this;a=k({},a),l=k({},l);var e={},o=function(u){typeof u=="string"&&(u=[u]),typeof l.type=="string"&&(l.type=[l.type]),l.type&&l.type.length?e.type=u.filter(function(d){return l.type.includes(d)}):e.type=u,e.type.length===1&&typeof e.type[0]=="string"?e.type=e.type[0]:e.type.length===0&&delete e.type};return Object.entries(a).forEach(function(u){var d=ki(u,2),x=d[0],P=d[1];l[x]!==void 0?function(D,J){(function(nt,ut){return(nt==="required"||nt==="defaultProperties")&&ur(ut)==="object"&&Array.isArray(ut)})(D,J)?e[D]=J.concat(l[D]).reduce(function(nt,ut){return nt.includes(ut)||nt.push(ut),nt},[]):D!=="type"||typeof J!="string"&&!Array.isArray(J)?ur(J)!=="object"||Array.isArray(J)||J===null?e[D]=J:e[D]=t.extendSchemas(J,l[D]):o(J)}(x,P):e[x]=P}),Object.entries(l).forEach(function(u){var d=ki(u,2),x=d[0],P=d[1];a[x]===void 0&&(e[x]=P)}),e}},{key:"getCacheKey",value:function(a){return["je-cache",a].join("::")}},{key:"getCacheBuster",value:function(){return this.options.ajax_cache_buster||new Date().toISOString().slice(0,10)}},{key:"cacheSet",value:function(a,l){try{window.localStorage.setItem(this.getCacheKey(a),JSON.stringify({cacheBuster:this.getCacheBuster(),schema:l}))}catch(t){console.error(t)}}},{key:"cacheGet",value:function(a){try{var l=window.localStorage.getItem(this.getCacheKey(a));if(l){var t=JSON.parse(l);if(t.cacheBuster&&t.schema&&t.cacheBuster===this.getCacheBuster())return t.schema;this.cacheDelete(a)}}catch(e){console.error(e)}}},{key:"cacheDelete",value:function(a){window.localStorage.removeItem(this.getCacheKey(a))}}],f&&of(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}(),sf=(_(3210),{default:function(){return{compile:function(c){var n=c.match(/{{\s*([a-zA-Z0-9\-_ .]+)\s*}}/g),f=n&&n.length;if(!f)return function(){return c};for(var i=[],h=function(l){var t,e,o=n[l].replace(/[{}]+/g,"").trim().split("."),u=o.length;u>1?t=function(d){for(e=d,l=0;l<u&&(e=e[o[l]]);l++);return e}:(o=o[0],t=function(d){return d[o]}),i.push({s:n[l],r:t})},a=0;a<f;a++)h(a);return function(l){var t,e="".concat(c);for(a=0;a<f;a++)t=i[a],e=e.replace(t.s,t.r(l));return e}}}},ejs:function(){return!!window.EJS&&{compile:function(c){var n=new window.EJS({text:c});return function(f){return n.render(f)}}}},handlebars:function(){return window.Handlebars},hogan:function(){return!!window.Hogan&&{compile:function(c){var n=window.Hogan.compile(c);return function(f){return n.render(f)}}}},lodash:function(){return!!window._&&{compile:function(c){return function(n){return window._.template(c)(n)}}}},markup:function(){return!(!window.Mark||!window.Mark.up)&&{compile:function(c){return function(n){return window.Mark.up(c,n)}}}},mustache:function(){return!!window.Mustache&&{compile:function(c){return function(n){return window.Mustache.render(c,n)}}}},swig:function(){return window.swig},underscore:function(){return!!window._&&{compile:function(c){return function(n){return window._.template(c)(n)}}}}});function ma(c){return ma=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ma(c)}function Al(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function lf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ma(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ma(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ma(h)==="symbol"?h:String(h)),i)}var h}var cf={collapse:"",expand:"",delete:"",edit:"",add:"",cancel:"",save:"",moveup:"",movedown:""},Cn=function(){function c(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:cf;(function(a,l){if(!(a instanceof l))throw new TypeError("Cannot call a class as a function")})(this,c),this.mapping=h,this.icon_prefix=i}var n,f;return n=c,(f=[{key:"getIconClass",value:function(i){return this.mapping[i]?this.icon_prefix+this.mapping[i]:this.icon_prefix+i}},{key:"getIcon",value:function(i){var h,a=this.getIconClass(i);if(!a)return null;var l,t=document.createElement("i");return(h=t.classList).add.apply(h,function(e){if(Array.isArray(e))return Al(e)}(l=a.split(" "))||function(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}(l)||function(e,o){if(e){if(typeof e=="string")return Al(e,o);var u=Object.prototype.toString.call(e).slice(8,-1);return u==="Object"&&e.constructor&&(u=e.constructor.name),u==="Map"||u==="Set"?Array.from(e):u==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(u)?Al(e,o):void 0}}(l)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
82
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()),t}}])&&lf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function Ll(c){return Ll=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ll(c)}function Rl(c,n){return Rl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Rl(c,n)}function xs(c){return xs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},xs(c)}var uf="glyphicon glyphicon-",hf={collapse:"chevron-down",expand:"chevron-right",delete:"trash",edit:"pencil",add:"plus",subtract:"minus",cancel:"floppy-remove",save:"floppy-saved",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"copy",clear:"remove-circle",time:"time",calendar:"calendar",edit_properties:"list"},df=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Rl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=xs(f);if(i){var e=xs(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Ll(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,uf,hf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Il(c){return Il=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Il(c)}function Bl(c,n){return Bl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Bl(c,n)}function ks(c){return ks=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ks(c)}var pf="icon-",ff={collapse:"chevron-down",expand:"chevron-right",delete:"trash",edit:"pencil",add:"plus",subtract:"minus",cancel:"ban-circle",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"copy",clear:"remove-circle",time:"time",calendar:"calendar",edit_properties:"list"},mf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Bl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=ks(f);if(i){var e=ks(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Il(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,pf,ff)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Dl(c){return Dl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Dl(c)}function Nl(c,n){return Nl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Nl(c,n)}function js(c){return js=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},js(c)}var yf="fa fa-",bf={collapse:"caret-square-o-down",expand:"caret-square-o-right",delete:"times",edit:"pencil",add:"plus",subtract:"minus",cancel:"ban",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"files-o",clear:"times-circle-o",time:"clock-o",calendar:"calendar",edit_properties:"list"},vf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Nl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=js(f);if(i){var e=js(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Dl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,yf,bf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function $l(c){return $l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},$l(c)}function Ml(c,n){return Ml=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ml(c,n)}function Os(c){return Os=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Os(c)}var gf="fas fa-",wf={collapse:"caret-down",expand:"caret-right",delete:"trash",edit:"pen",add:"plus",subtract:"minus",cancel:"ban",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"copy",clear:"times-circle",time:"clock",calendar:"calendar",edit_properties:"list"},_f=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Ml(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Os(f);if(i){var e=Os(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&($l(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,gf,wf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Hl(c){return Hl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Hl(c)}function Fl(c,n){return Fl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Fl(c,n)}function Es(c){return Es=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Es(c)}var xf="ui-icon ui-icon-",kf={collapse:"triangle-1-s",expand:"triangle-1-e",delete:"trash",edit:"pencil",add:"plusthick",subtract:"minusthick",cancel:"closethick",save:"disk",moveup:"arrowthick-1-n",moveright:"arrowthick-1-e",movedown:"arrowthick-1-s",moveleft:"arrowthick-1-w",copy:"copy",clear:"circle-close",time:"time",calendar:"calendar",edit_properties:"note"},jf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Fl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Es(f);if(i){var e=Es(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Hl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,xf,kf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Vl(c){return Vl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Vl(c)}function zl(c,n){return zl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},zl(c,n)}function Cs(c){return Cs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Cs(c)}var Of="oi oi-",Ef={collapse:"collapse-down",expand:"expand-right",delete:"trash",edit:"pencil",add:"plus",subtract:"minus",cancel:"ban",save:"file",moveup:"arrow-thick-top",moveright:"arrow-thick-right",movedown:"arrow-thick-bottom",moveleft:"arrow-thick-left",copy:"clipboard",clear:"circle-x",time:"clock",calendar:"calendar",edit_properties:"list"},Cf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&zl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Cs(f);if(i){var e=Cs(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Vl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,Of,Ef)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Ul(c){return Ul=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ul(c)}function ql(c,n){return ql=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ql(c,n)}function Ss(c){return Ss=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ss(c)}var Sf="icon icon-",Pf={collapse:"arrow-down",expand:"arrow-right",delete:"delete",edit:"edit",add:"plus",subtract:"minus",cancel:"cross",save:"check",moveup:"upward",moveright:"forward",movedown:"downward",moveleft:"back",copy:"copy",clear:"close",time:"time",calendar:"bookmark",edit_properties:"menu"},Tf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&ql(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Ss(f);if(i){var e=Ss(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Ul(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,Sf,Pf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Gl(c){return Gl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Gl(c)}function Wl(c,n){return Wl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Wl(c,n)}function Ps(c){return Ps=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ps(c)}var Af="bi bi-",Lf={collapse:"chevron-down",expand:"chevron-right",delete:"trash",edit:"pencil",add:"plus",subtract:"dash",cancel:"x-circle",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"clipboard",clear:"x-circle",time:"clock",calendar:"calendar",edit_properties:"list-ul"},Rf={bootstrap:function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Wl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Ps(f);if(i){var e=Ps(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Gl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,Af,Lf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn),bootstrap3:df,fontawesome3:mf,fontawesome4:vf,fontawesome5:_f,jqueryui:jf,openiconic:Cf,spectre:Tf};function ya(c){return ya=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ya(c)}function If(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ya(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ya(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ya(h)==="symbol"?h:String(h)),i)}var h}var Iu=["matches","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector"].find(function(c){return c in document.documentElement}),Sn=function(){function c(i){var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{disable_theme_rules:!1};(function(a,l){if(!(a instanceof l))throw new TypeError("Cannot call a class as a function")})(this,c),this.jsoneditor=i,Object.keys(h).forEach(function(a){i.options[a]!==void 0&&(h[a]=i.options[a])}),this.options=h}var n,f;return n=c,f=[{key:"getContainer",value:function(){return document.createElement("div")}},{key:"getFloatRightLinkHolder",value:function(){var i=document.createElement("div");return i.classList.add("je-float-right-linkholder"),i}},{key:"getModal",value:function(){var i=document.createElement("div");return i.style.display="none",i.classList.add("je-modal"),i}},{key:"getGridContainer",value:function(){return document.createElement("div")}},{key:"getGridRow",value:function(){var i=document.createElement("div");return i.classList.add("row"),i}},{key:"getGridColumn",value:function(){return document.createElement("div")}},{key:"setGridColumnSize",value:function(i,h){}},{key:"getLink",value:function(i){var h=document.createElement("a");return h.setAttribute("href","#"),h.appendChild(document.createTextNode(i)),h}},{key:"disableHeader",value:function(i){i.style.color="#ccc"}},{key:"disableLabel",value:function(i){i.style.color="#ccc"}},{key:"enableHeader",value:function(i){i.style.color=""}},{key:"enableLabel",value:function(i){i.style.color=""}},{key:"getInfoButton",value:function(i){var h=document.createElement("span");h.innerText="ⓘ",h.classList.add("je-infobutton-icon");var a=document.createElement("span");return a.classList.add("je-infobutton-tooltip"),a.innerText=i,h.onmouseover=function(){a.style.visibility="visible"},h.onmouseleave=function(){a.style.visibility="hidden"},h.appendChild(a),h}},{key:"getFormInputLabel",value:function(i,h){var a=document.createElement("label");return a.appendChild(document.createTextNode(i)),h&&a.classList.add("required"),a}},{key:"getHeader",value:function(i,h){var a=document.createElement("h3");return typeof i=="string"?a.textContent=i:a.appendChild(i),a.classList.add("je-header"),a}},{key:"getCheckbox",value:function(){var i=this.getFormInputField("checkbox");return i.classList.add("je-checkbox"),i}},{key:"getCheckboxLabel",value:function(i,h){var a=document.createElement("label");return a.appendChild(document.createTextNode(" ".concat(i))),h&&a.classList.add("required"),a}},{key:"getMultiCheckboxHolder",value:function(i,h,a,l){var t=document.createElement("div");return t.classList.add("control-group"),h&&(h.style.display="block",t.appendChild(h),l&&h.appendChild(l)),Object.values(i).forEach(function(e){e.style.display="inline-block",e.style.marginRight="20px",t.appendChild(e)}),a&&t.appendChild(a),t}},{key:"getFormCheckboxControl",value:function(i,h,a){var l=document.createElement("div");return l.appendChild(i),h.style.width="auto",i.insertBefore(h,i.firstChild),a&&l.classList.add("je-checkbox-control--compact"),l}},{key:"getFormRadio",value:function(i){var h=this.getFormInputField("radio");return Object.keys(i).forEach(function(a){return h.setAttribute(a,i[a])}),h.classList.add("je-radio"),h}},{key:"getFormRadioLabel",value:function(i,h){var a=document.createElement("label");return a.appendChild(document.createTextNode(" ".concat(i))),h&&a.classList.add("required"),a}},{key:"getFormRadioControl",value:function(i,h,a){var l=document.createElement("div");return l.appendChild(i),h.style.width="auto",i.insertBefore(h,i.firstChild),a&&l.classList.add("je-radio-control--compact"),l}},{key:"getSelectInput",value:function(i,h){var a=document.createElement("select");return i&&this.setSelectOptions(a,i),a}},{key:"getSwitcher",value:function(i){var h=this.getSelectInput(i,!1);return h.classList.add("je-switcher"),h}},{key:"getSwitcherOptions",value:function(i){return i.getElementsByTagName("option")}},{key:"setSwitcherOptions",value:function(i,h,a){this.setSelectOptions(i,h,a)}},{key:"setSelectOptions",value:function(i,h){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];i.innerHTML="";for(var l=0;l<h.length;l++){var t=document.createElement("option");t.setAttribute("value",h[l]),t.textContent=a[l]||h[l],i.appendChild(t)}}},{key:"getTextareaInput",value:function(){var i=document.createElement("textarea");return i.classList.add("je-textarea"),i}},{key:"getRangeInput",value:function(i,h,a){var l=this.getFormInputField("range");return l.setAttribute("min",i),l.setAttribute("max",h),l.setAttribute("step",a),l}},{key:"getStepperButtons",value:function(i){var h=document.createElement("div"),a=document.createElement("button");a.setAttribute("type","button"),a.classList.add("stepper-down");var l=document.createElement("button");l.setAttribute("type","button"),l.classList.add("stepper-up"),i.getAttribute("readonly")&&(a.setAttribute("disabled",!0),l.setAttribute("disabled",!0)),a.textContent="-",l.textContent="+";var t=function(u,d){u.value=Number(d||u.value),u.setAttribute("initialized","1")},e=i.getAttribute("min"),o=i.getAttribute("max");return a.addEventListener("click",function(){i.getAttribute("initialized")?e?Number(i.value)>Number(e)&&i.stepDown():i.stepDown():t(i,e),O(i,"change")}),l.addEventListener("click",function(){i.getAttribute("initialized")?o?Number(i.value)<Number(o)&&i.stepUp():i.stepUp():t(i,e),O(i,"change")}),h.appendChild(a),h.appendChild(l),h}},{key:"getRangeOutput",value:function(i,h){var a=document.createElement("output"),l=function(t){a.value=t.currentTarget.value};return i.addEventListener("change",l,!1),i.addEventListener("input",l,!1),a}},{key:"getRangeControl",value:function(i,h){var a=document.createElement("div");return a.classList.add("je-range-control"),h&&a.appendChild(h),a.appendChild(i),a}},{key:"getFormInputField",value:function(i){var h=document.createElement("input");return h.setAttribute("type",i),h}},{key:"afterInputReady",value:function(i){}},{key:"getFormControl",value:function(i,h,a,l,t){var e=document.createElement("div");return e.classList.add("form-control"),i&&(e.appendChild(i),t&&i.setAttribute("for",t)),h.type!=="checkbox"&&h.type!=="radio"||!i?(l&&i&&i.appendChild(l),e.appendChild(h)):(h.style.width="auto",i.insertBefore(h,i.firstChild),l&&i.appendChild(l)),a&&e.appendChild(a),e}},{key:"getIndentedPanel",value:function(){var i=document.createElement("div");return i.classList.add("je-indented-panel"),i}},{key:"getTopIndentedPanel",value:function(){var i=document.createElement("div");return i.classList.add("je-indented-panel--top"),i}},{key:"getChildEditorHolder",value:function(){return document.createElement("div")}},{key:"getDescription",value:function(i){var h=document.createElement("p");return window.DOMPurify?h.innerHTML=window.DOMPurify.sanitize(i):h.textContent=this.cleanText(i),h}},{key:"getCheckboxDescription",value:function(i){return this.getDescription(i)}},{key:"getFormInputDescription",value:function(i){return this.getDescription(i)}},{key:"getButtonHolder",value:function(){return document.createElement("span")}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getFormButtonHolder",value:function(i){return this.getButtonHolder()}},{key:"getButton",value:function(i,h,a){var l=document.createElement("button");return l.type="button",this.setButtonText(l,i,h,a),l}},{key:"getFormButton",value:function(i,h,a){return this.getButton(i,h,a)}},{key:"setButtonText",value:function(i,h,a,l){for(;i.firstChild;)i.removeChild(i.firstChild);if(a&&(i.appendChild(a),h=" ".concat(h)),!this.jsoneditor.options.iconlib||!this.jsoneditor.options.remove_button_labels||!a){var t=document.createElement("span");t.appendChild(document.createTextNode(h)),i.appendChild(t)}l&&i.setAttribute("title",l)}},{key:"getTableContainer",value:function(){return document.createElement("div")}},{key:"getTable",value:function(){return document.createElement("table")}},{key:"getTableRow",value:function(){return document.createElement("tr")}},{key:"getTableHead",value:function(){return document.createElement("thead")}},{key:"getTableBody",value:function(){return document.createElement("tbody")}},{key:"getTableHeaderCell",value:function(i){var h=document.createElement("th");return h.textContent=i,h}},{key:"getTableCell",value:function(){return document.createElement("td")}},{key:"getErrorMessage",value:function(i){var h=document.createElement("p");return h.style=h.style||{},h.style.color="red",h.appendChild(document.createTextNode(i)),h}},{key:"addInputError",value:function(i,h){}},{key:"removeInputError",value:function(i){}},{key:"addTableRowError",value:function(i){}},{key:"removeTableRowError",value:function(i){}},{key:"getTabHolder",value:function(i){var h=i===void 0?"":i,a=document.createElement("div");return a.innerHTML="<div class='je-tabholder tabs'></div><div class='content' id='".concat(h,"'></div><div class='je-tabholder--clear'></div>"),a}},{key:"getTopTabHolder",value:function(i){var h=i===void 0?"":i,a=document.createElement("div");return a.innerHTML="<div class='tabs je-tabholder--top'></div><div class='je-tabholder--clear'></div><div class='content' id='".concat(h,"'></div>"),a}},{key:"applyStyles",value:function(i,h){Object.keys(h).forEach(function(a){return i.style[a]=h[a]})}},{key:"closest",value:function(i,h){for(;i&&i!==document;){if(!i[Iu])return!1;if(i[Iu](h))return i;i=i.parentNode}return!1}},{key:"insertBasicTopTab",value:function(i,h){h.firstChild.insertBefore(i,h.firstChild.firstChild)}},{key:"getTab",value:function(i,h){var a=document.createElement("div");return a.appendChild(i),a.id=h,a.classList.add("je-tab"),a}},{key:"getTopTab",value:function(i,h){var a=document.createElement("div");return a.appendChild(i),a.id=h,a.classList.add("je-tab--top"),a}},{key:"getTabContentHolder",value:function(i){return i.children[1]}},{key:"getTopTabContentHolder",value:function(i){return i.children[1]}},{key:"getTabContent",value:function(){return this.getIndentedPanel()}},{key:"getTopTabContent",value:function(){return this.getTopIndentedPanel()}},{key:"markTabActive",value:function(i){this.applyStyles(i.tab,{opacity:1,background:"white"}),i.rowPane!==void 0?i.rowPane.style.display="":i.container.style.display=""}},{key:"markTabInactive",value:function(i){this.applyStyles(i.tab,{opacity:.5,background:""}),i.rowPane!==void 0?i.rowPane.style.display="none":i.container.style.display="none"}},{key:"addTab",value:function(i,h){i.children[0].appendChild(h)}},{key:"addTopTab",value:function(i,h){i.children[0].appendChild(h)}},{key:"getBlockLink",value:function(){var i=document.createElement("a");return i.classList.add("je-block-link"),i}},{key:"getBlockLinkHolder",value:function(){return document.createElement("div")}},{key:"getLinksHolder",value:function(){return document.createElement("div")}},{key:"createMediaLink",value:function(i,h,a){i.appendChild(h),a.classList.add("je-media"),i.appendChild(a)}},{key:"createImageLink",value:function(i,h,a){i.appendChild(h),h.appendChild(a)}},{key:"getFirstTab",value:function(i){return i.firstChild.firstChild}},{key:"getInputGroup",value:function(i,h){}},{key:"cleanText",value:function(i){var h=document.createElement("div");return h.innerHTML=i,h.textContent||h.innerText}},{key:"getDropZone",value:function(i){var h=document.createElement("div");return h.setAttribute("data-text",i),h.classList.add("je-dropzone"),h}},{key:"getUploadPreview",value:function(i,h,a){var l=document.createElement("div");if(l.classList.add("je-upload-preview"),i.mimeType.substr(0,5)==="image"){var t=document.createElement("img");t.src=a,l.appendChild(t)}var e=document.createElement("div");e.innerHTML+="<strong>Name:</strong> ".concat(i.name,"<br><strong>Type:</strong> ").concat(i.type,"<br><strong>Size:</strong> ").concat(i.formattedSize),l.appendChild(e),l.appendChild(h);var o=document.createElement("div");return o.style.clear="left",l.appendChild(o),l}},{key:"getProgressBar",value:function(){var i=document.createElement("progress");return i.setAttribute("max",100),i.setAttribute("value",0),i}},{key:"updateProgressBar",value:function(i,h){i&&i.setAttribute("value",h)}},{key:"updateProgressBarUnknown",value:function(i){i&&i.removeAttribute("value")}}],f&&If(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function go(c){return go=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},go(c)}function Bf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(go(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(go(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),go(h)==="symbol"?h:String(h)),i)}var h}function ji(){return ji=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=pn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},ji.apply(this,arguments)}function Zl(c,n){return Zl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Zl(c,n)}function pn(c){return pn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},pn(c)}var Bu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Zl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=pn(i);if(h){var o=pn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(go(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getFormInputLabel",value:function(t,e){var o=ji(pn(l.prototype),"getFormInputLabel",this).call(this,t,e);return o.classList.add("je-form-input-label"),o}},{key:"getFormInputDescription",value:function(t){var e=ji(pn(l.prototype),"getFormInputDescription",this).call(this,t);return e.classList.add("je-form-input-label"),e}},{key:"getIndentedPanel",value:function(){var t=ji(pn(l.prototype),"getIndentedPanel",this).call(this);return t.classList.add("je-indented-panel"),t}},{key:"getTopIndentedPanel",value:function(){return this.getIndentedPanel()}},{key:"getChildEditorHolder",value:function(){var t=ji(pn(l.prototype),"getChildEditorHolder",this).call(this);return t.classList.add("je-child-editor-holder"),t}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.classList.add("je-header-button-holder"),t}},{key:"getTable",value:function(){var t=ji(pn(l.prototype),"getTable",this).call(this);return t.classList.add("je-table"),t}},{key:"addInputError",value:function(t,e){var o=this.closest(t,".form-control")||t.controlgroup;t.errmsg?t.errmsg.style.display="block":(t.errmsg=document.createElement("div"),t.errmsg.setAttribute("class","errmsg"),t.errmsg.style=t.errmsg.style||{},t.errmsg.style.color="red",o.appendChild(t.errmsg)),t.errmsg.innerHTML="",t.errmsg.appendChild(document.createTextNode(e))}},{key:"removeInputError",value:function(t){t.style&&(t.style.borderColor=""),t.errmsg&&(t.errmsg.style.display="none")}}])&&Bf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function wo(c){return wo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},wo(c)}function Df(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(wo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(wo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),wo(h)==="symbol"?h:String(h)),i)}var h}function Oi(){return Oi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=fn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Oi.apply(this,arguments)}function Jl(c,n){return Jl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Jl(c,n)}function fn(c){return fn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},fn(c)}Bu.rules={".je-form-input-label":"display:block;margin-bottom:3px;font-weight:bold",".je-form-input-description":"display:inline-block;margin:0;font-size:0.8em;font-style:italic",".je-indented-panel":"padding:5px;margin:10px;border-radius:3px;border:1px%20solid%20%23ddd",".je-child-editor-holder":"margin-bottom:8px",".je-header-button-holder":"display:inline-block;margin-left:10px;font-size:0.8em;vertical-align:middle",".je-table":"margin-bottom:5px;border-bottom:1px%20solid%20%23ccc",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Du=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Jl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=fn(i);if(h){var o=fn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(wo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getSelectInput",value:function(t,e){var o=Oi(fn(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-control"),o}},{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-md-".concat(e)),o&&t.classList.add("col-md-offset-".concat(o))}},{key:"afterInputReady",value:function(t){if(!t.controlgroup&&(t.controlgroup=this.closest(t,".form-group"),this.closest(t,".compact")&&(t.controlgroup.style.marginBottom=0),this.queuedInputErrorText)){var e=this.queuedInputErrorText;delete this.queuedInputErrorText,this.addInputError(t,e)}}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-control"),t}},{key:"getRangeInput",value:function(t,e,o){return Oi(fn(l.prototype),"getRangeInput",this).call(this,t,e,o)}},{key:"getFormInputField",value:function(t){var e=Oi(fn(l.prototype),"getFormInputField",this).call(this,t);return t!=="checkbox"&&t!=="radio"&&e.classList.add("form-control"),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");return!t||e.type!=="checkbox"&&e.type!=="radio"?(d.classList.add("form-group"),t&&(t.classList.add("control-label"),d.appendChild(t),u&&t.appendChild(u)),d.appendChild(e)):(d.classList.add(e.type),u&&t.appendChild(u),t.insertBefore(e,t.firstChild),d.appendChild(t)),o&&d.appendChild(o),d}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("well","well-sm"),t.style.paddingBottom=0,t}},{key:"getInfoButton",value:function(t){var e=document.createElement("span");e.classList.add("glyphicon","glyphicon-info-sign","pull-right"),e.style.padding=".25rem",e.style.position="relative",e.style.display="inline-block";var o=document.createElement("span");return o.style["font-family"]="sans-serif",o.style.visibility="hidden",o.style["background-color"]="rgba(50, 50, 50, .75)",o.style.margin="0 .25rem",o.style.color="#FAFAFA",o.style.padding=".5rem 1rem",o.style["border-radius"]=".25rem",o.style.width="25rem",o.style.position="absolute",o.innerText=t,e.onmouseover=function(){o.style.visibility="visible"},e.onmouseleave=function(){o.style.visibility="hidden"},e.appendChild(o),e}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("p");return e.classList.add("help-block"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.style.marginLeft="10px",t}},{key:"getButtonHolder",value:function(){var t=document.createElement("span");return t.classList.add("btn-group"),t}},{key:"getButton",value:function(t,e,o){var u=Oi(fn(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-default"),u}},{key:"getTableContainer",value:function(){var t=Oi(fn(l.prototype),"getTableContainer",this).call(this);return t.classList.add("table-responsive"),t}},{key:"getTable",value:function(){var t=document.createElement("table");return t.classList.add("table","table-bordered"),t.style.width="auto",t.style.maxWidth="none",t}},{key:"addInputError",value:function(t,e){t.controlgroup?(t.controlgroup.classList.add("has-error"),t.errmsg?t.errmsg.style.display="":(t.errmsg=document.createElement("p"),t.errmsg.classList.add("help-block","errormsg"),t.controlgroup.appendChild(t.errmsg)),t.errmsg.textContent=e):this.queuedInputErrorText=e}},{key:"removeInputError",value:function(t){t.controlgroup||delete this.queuedInputErrorText,t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("has-error"))}},{key:"getTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML="<ul class='col-md-2 nav nav-pills nav-stacked' id='".concat(e,"' role='tablist'></ul><div class='col-md-10 tab-content active well well-small' id='").concat(e,"'></div>"),o}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML="<ul class='nav nav-tabs' id='".concat(e,"' role='tablist'></ul><div class='tab-content active well well-small' id='").concat(e,"'></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.setAttribute("role","presentation");var u=document.createElement("a");return u.setAttribute("href","#".concat(e)),u.appendChild(t),u.setAttribute("aria-controls",e),u.setAttribute("role","tab"),u.setAttribute("data-toggle","tab"),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.setAttribute("role","presentation");var u=document.createElement("a");return u.setAttribute("href","#".concat(e)),u.appendChild(t),u.setAttribute("aria-controls",e),u.setAttribute("role","tab"),u.setAttribute("data-toggle","tab"),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.classList.add("active"),t.rowPane!==void 0?t.rowPane.classList.add("active"):t.container.classList.add("active")}},{key:"markTabInactive",value:function(t){t.tab.classList.remove("active"),t.rowPane!==void 0?t.rowPane.classList.remove("active"):t.container.classList.remove("active")}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("progress-bar"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","progress-striped","active"),e.removeAttribute("aria-valuenow"),e.style.width="100%",e.innerHTML=""}}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);var u=document.createElement("div");u.classList.add("input-group-btn"),o.appendChild(u);for(var d=0;d<e.length;d++)u.appendChild(e[d]);return o}}}])&&Df(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function _o(c){return _o=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},_o(c)}function Nf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(_o(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(_o(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),_o(h)==="symbol"?h:String(h)),i)}var h}function Ei(){return Ei=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=mn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Ei.apply(this,arguments)}function Yl(c,n){return Yl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Yl(c,n)}function mn(c){return mn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},mn(c)}Du.rules={},_(3843);var $f={disable_theme_rules:!1,input_size:"normal",custom_forms:!1,object_indent:!0,object_background:"bg-light",object_text:"",table_border:!1,table_zebrastyle:!1,tooltip:"bootstrap"},Nu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Yl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=mn(i);if(h){var o=mn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(_o(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,$f)}return n=l,(f=[{key:"getSelectInput",value:function(t,e){var o=Ei(mn(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-control"),this.options.custom_forms===!1?(this.options.input_size==="small"&&o.classList.add("form-control-sm"),this.options.input_size==="large"&&o.classList.add("form-control-lg")):(o.classList.remove("form-control"),o.classList.add("custom-select"),this.options.input_size==="small"&&o.classList.add("custom-select-sm"),this.options.input_size==="large"&&o.classList.add("custom-select-lg")),o}},{key:"getContainer",value:function(){var t=document.createElement("div");return this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-md-".concat(e)),o&&t.classList.add("offset-md-".concat(o))}},{key:"afterInputReady",value:function(t){if(!t.controlgroup){var e=t.name;t.id=e;var o=t.parentNode.parentNode.getElementsByTagName("label")[0];o&&(o.htmlFor=e),t.controlgroup=this.closest(t,".form-group")}}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-control"),this.options.input_size==="small"&&t.classList.add("form-control-sm"),this.options.input_size==="large"&&t.classList.add("form-control-lg"),t}},{key:"getRangeInput",value:function(t,e,o){var u=Ei(mn(l.prototype),"getRangeInput",this).call(this,t,e,o);return this.options.custom_forms===!0&&(u.classList.remove("form-control"),u.classList.add("custom-range")),u}},{key:"getStepperButtons",value:function(t){var e=document.createElement("div"),o=document.createElement("div"),u=document.createElement("div"),d=document.createElement("button");d.setAttribute("type","button");var x=document.createElement("button");x.setAttribute("type","button"),e.appendChild(o),e.appendChild(t),e.appendChild(u),o.appendChild(d),u.appendChild(x),e.classList.add("input-group"),o.classList.add("input-group-prepend"),u.classList.add("input-group-append"),d.classList.add("btn"),d.classList.add("btn-secondary"),d.classList.add("stepper-down"),x.classList.add("btn"),x.classList.add("btn-secondary"),x.classList.add("stepper-up"),t.getAttribute("readonly")&&(d.setAttribute("disabled",!0),x.setAttribute("disabled",!0)),d.textContent="-",x.textContent="+";var P=function(nt,ut){nt.value=Number(ut||nt.value),nt.setAttribute("initialized","1")},D=t.getAttribute("min"),J=t.getAttribute("max");return t.addEventListener("change",function(){t.getAttribute("initialized")||t.setAttribute("initialized","1")}),d.addEventListener("click",function(){t.getAttribute("initialized")?D?Number(t.value)>Number(D)&&t.stepDown():t.stepDown():P(t,D),O(t,"change")}),x.addEventListener("click",function(){t.getAttribute("initialized")?J?Number(t.value)<Number(J)&&t.stepUp():t.stepUp():P(t,D),O(t,"change")}),e}},{key:"getFormInputField",value:function(t){var e=Ei(mn(l.prototype),"getFormInputField",this).call(this,t);return t!=="checkbox"&&t!=="radio"&&t!=="file"&&(e.classList.add("form-control"),this.options.input_size==="small"&&e.classList.add("form-control-sm"),this.options.input_size==="large"&&e.classList.add("form-control-lg")),t==="file"&&e.classList.add("form-control-file"),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");if(d.classList.add("form-group"),!t||e.type!=="checkbox"&&e.type!=="radio")t&&(d.appendChild(t),u&&d.appendChild(u)),d.appendChild(e);else{var x=document.createElement("div");this.options.custom_forms===!1?(x.classList.add("form-check"),e.classList.add("form-check-input"),t.classList.add("form-check-label")):(x.classList.add("custom-control"),e.classList.add("custom-control-input"),t.classList.add("custom-control-label"),e.type==="checkbox"?x.classList.add("custom-checkbox"):x.classList.add("custom-radio"));var P=(Date.now()*Math.random()).toFixed(0);e.setAttribute("id",P),t.setAttribute("for",P),x.appendChild(e),x.appendChild(t),u&&x.appendChild(u),d.appendChild(x)}return o&&d.appendChild(o),d}},{key:"getInfoButton",value:function(t){var e=document.createElement("button");e.type="button",e.classList.add("ml-3","jsoneditor-twbs4-text-button"),e.setAttribute("data-toggle","tooltip"),e.setAttribute("data-placement","auto"),e.title=t;var o=document.createTextNode("ⓘ");return e.appendChild(o),this.options.tooltip==="bootstrap"?window.jQuery&&window.jQuery().tooltip?window.jQuery(e).tooltip():console.warn("Could not find popper jQuery plugin of Bootstrap."):this.options.tooltip==="css"&&e.classList.add("je-tooltip"),e}},{key:"getCheckbox",value:function(){return this.getFormInputField("checkbox")}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){var d=document.createElement("div");d.classList.add("form-group"),e&&(d.appendChild(e),u&&e.appendChild(u));var x=document.createElement("div");return Object.values(t).forEach(function(P){var D=P.firstChild;x.appendChild(D)}),d.appendChild(x),o&&d.appendChild(o),d}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in t)e.setAttribute(o,t[o]);return this.options.custom_forms===!1?e.classList.add("form-check-input"):e.classList.add("custom-control-input"),e}},{key:"getFormRadioLabel",value:function(t,e){var o=document.createElement("label");return this.options.custom_forms===!1?o.classList.add("form-check-label"):o.classList.add("custom-control-label"),o.appendChild(document.createTextNode(t)),o}},{key:"getFormRadioControl",value:function(t,e,o){var u=document.createElement("div");return this.options.custom_forms===!1?u.classList.add("form-check"):u.classList.add("custom-control","custom-radio"),u.appendChild(e),u.appendChild(t),o&&(this.options.custom_forms===!1?u.classList.add("form-check-inline"):u.classList.add("custom-control-inline")),u}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("card","card-body","mb-3"),this.options.object_background&&t.classList.add(this.options.object_background),this.options.object_text&&t.classList.add(this.options.object_text),t}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("small");return e.classList.add("form-text"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getHeader",value:function(t,e){var o=document.createElement("h3");return o.classList.add("card-title"),o.classList.add("level-"+e),typeof t=="string"?o.textContent=t:o.appendChild(t),o.style.display="inline-block",o}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getButtonHolder",value:function(){var t=document.createElement("span");return t.classList.add("btn-group"),t}},{key:"getFormButtonHolder",value:function(t){var e=this.getButtonHolder();return e.classList.add("d-block"),t==="center"?e.classList.add("text-center"):t==="right"&&e.classList.add("text-right"),e}},{key:"getButton",value:function(t,e,o){var u=Ei(mn(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-secondary","btn-sm"),u}},{key:"getTableContainer",value:function(){var t=Ei(mn(l.prototype),"getTableContainer",this).call(this);return t.classList.add("table-responsive"),t}},{key:"getTable",value:function(){var t=document.createElement("table");return t.classList.add("table","table-sm"),this.options.table_border&&t.classList.add("table-bordered"),this.options.table_zebrastyle&&t.classList.add("table-striped"),t}},{key:"getErrorMessage",value:function(t){var e=document.createElement("div");return e.classList.add("alert","alert-danger"),e.setAttribute("role","alert"),e.appendChild(document.createTextNode(t)),e}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("is-invalid"),t.errmsg||(t.errmsg=document.createElement("p"),t.errmsg.classList.add("invalid-feedback"),t.controlgroup.appendChild(t.errmsg),t.errmsg.style.display="block"),t.errmsg.style.display="block",t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("is-invalid"))}},{key:"getTabHolder",value:function(t){var e=document.createElement("div"),o=t===void 0?"":t;return e.innerHTML="<div class='col-md-2' id='".concat(o,"'><ul class='nav flex-column nav-pills'></ul></div><div class='col-md-10'><div class='tab-content' id='").concat(o,"'></div></div>"),e.classList.add("row"),e}},{key:"addTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.classList.add("card"),o.innerHTML="<div class='card-header'><ul class='nav nav-tabs card-header-tabs' id='".concat(e,"'></ul></div><div class='card-body'><div class='tab-content' id='").concat(e,"'></div></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.firstChild.classList.add("active"),t.rowPane!==void 0?t.rowPane.classList.add("active"):t.container.classList.add("active")}},{key:"markTabInactive",value:function(t){t.tab.firstChild.classList.remove("active"),t.rowPane!==void 0?t.rowPane.classList.remove("active"):t.container.classList.remove("active")}},{key:"insertBasicTopTab",value:function(t,e){e.children[0].children[0].insertBefore(t,e.children[0].children[0].firstChild)}},{key:"addTopTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTopTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getFirstTab",value:function(t){return t.firstChild.firstChild.firstChild}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("progress-bar"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","progress-striped","active"),e.removeAttribute("aria-valuenow"),e.style.width="100%",e.innerHTML=""}}},{key:"getBlockLink",value:function(){var t=document.createElement("a");return t.classList.add("mb-3","d-inline-block"),t}},{key:"getLinksHolder",value:function(){return document.createElement("div")}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);var u=document.createElement("div");u.classList.add("input-group-append"),o.appendChild(u);for(var d=0;d<e.length;d++)e[d].classList.remove("mr-2","btn-secondary"),e[d].classList.add("btn-outline-secondary"),u.appendChild(e[d]);return o}}}])&&Nf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function xo(c){return xo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},xo(c)}function Mf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(xo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(xo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),xo(h)==="symbol"?h:String(h)),i)}var h}function Ci(){return Ci=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=yn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Ci.apply(this,arguments)}function Xl(c,n){return Xl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Xl(c,n)}function yn(c){return yn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},yn(c)}Nu.rules={".jsoneditor-twbs4-text-button":"background:none;padding:0;border:0;color:currentColor","td > .form-group":"margin-bottom:0",".json-editor-btn-upload":"margin-top:1rem",".je-noindent .card":"padding:0;border:0",".je-tooltip:hover::before":"display:block;position:absolute;font-size:0.8em;color:%23fff;border-radius:0.2em;content:attr(title);background-color:%23000;margin-top:-2.5em;padding:0.3em",".je-tooltip:hover::after":"display:block;position:absolute;font-size:0.8em;color:%23fff",".select2-container--default .select2-selection--single":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__arrow":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__rendered":"line-height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".selectize-control.form-control":"padding:0",".selectize-dropdown.form-control":"padding:0;height:auto",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Hf={disable_theme_rules:!1,input_size:"normal",object_indent:!0,object_background:"bg-light",object_text:"",table_border:!1,table_zebrastyle:!1,tooltip:"bootstrap"},$u=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Xl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=yn(i);if(h){var o=yn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(xo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,Hf)}return n=l,(f=[{key:"getSelectInput",value:function(t,e){var o=Ci(yn(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-control"),o.classList.add("form-select"),this.options.input_size==="small"&&o.classList.add("form-control-sm"),this.options.input_size==="large"&&o.classList.add("form-control-lg"),o}},{key:"getContainer",value:function(){var t=document.createElement("div");return this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-md-".concat(e)),o&&t.classList.add("offset-md-".concat(o))}},{key:"afterInputReady",value:function(t){if(!t.controlgroup){var e=t.name;t.id=e;var o=t.parentNode.parentNode.getElementsByTagName("label")[0];o&&(o.classList.add("form-label"),o.htmlFor=e),t.controlgroup=this.closest(t,".form-group")}}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-control"),this.options.input_size==="small"&&t.classList.add("form-control-sm"),this.options.input_size==="large"&&t.classList.add("form-control-lg"),t}},{key:"getRangeInput",value:function(t,e,o){var u=Ci(yn(l.prototype),"getRangeInput",this).call(this,t,e,o);return u.classList.remove("form-control"),u.classList.add("form-range"),u}},{key:"getStepperButtons",value:function(t){var e=document.createElement("div"),o=document.createElement("button");o.setAttribute("type","button");var u=document.createElement("button");u.setAttribute("type","button"),e.appendChild(o),e.appendChild(t),e.appendChild(u),e.classList.add("input-group"),o.classList.add("btn"),o.classList.add("btn-secondary"),o.classList.add("stepper-down"),u.classList.add("btn"),u.classList.add("btn-secondary"),u.classList.add("stepper-up"),t.getAttribute("readonly")&&(o.setAttribute("disabled",!0),u.setAttribute("disabled",!0)),o.textContent="-",u.textContent="+";var d=function(D,J){D.value=Number(J||D.value),D.setAttribute("initialized","1")},x=t.getAttribute("min"),P=t.getAttribute("max");return t.addEventListener("change",function(){t.getAttribute("initialized")||t.setAttribute("initialized","1")}),o.addEventListener("click",function(){t.getAttribute("initialized")?x?Number(t.value)>Number(x)&&t.stepDown():t.stepDown():d(t,x),O(t,"change")}),u.addEventListener("click",function(){t.getAttribute("initialized")?P?Number(t.value)<Number(P)&&t.stepUp():t.stepUp():d(t,x),O(t,"change")}),e}},{key:"getFormInputField",value:function(t){var e=Ci(yn(l.prototype),"getFormInputField",this).call(this,t);return t!=="checkbox"&&t!=="radio"&&(e.classList.add("form-control"),this.options.input_size==="small"&&e.classList.add("form-control-sm"),this.options.input_size==="large"&&e.classList.add("form-control-lg")),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");if(d.classList.add("form-group"),!t||e.type!=="checkbox"&&e.type!=="radio")t&&(t.classList.add("form-label"),d.appendChild(t),u&&d.appendChild(u)),d.appendChild(e);else{var x=document.createElement("div");x.classList.add("form-check"),e.classList.add("form-check-input"),t.classList.add("form-check-label");var P=(Date.now()*Math.random()).toFixed(0);e.setAttribute("id",P),t.setAttribute("for",P),x.appendChild(e),x.appendChild(t),u&&x.appendChild(u),d.appendChild(x)}return o&&d.appendChild(o),d}},{key:"getInfoButton",value:function(t){var e=document.createElement("button");e.type="button",e.classList.add("ms-3","jsoneditor-twbs5-text-button"),e.setAttribute("data-toggle","tooltip"),e.setAttribute("data-placement","auto"),e.title=t;var o=document.createTextNode("ⓘ");return e.appendChild(o),this.options.tooltip==="bootstrap"?window.jQuery&&window.jQuery().tooltip?window.jQuery(e).tooltip():console.warn("Could not find popper jQuery plugin of Bootstrap."):this.options.tooltip==="css"&&e.classList.add("je-tooltip"),e}},{key:"getCheckbox",value:function(){return this.getFormInputField("checkbox")}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){var d=document.createElement("div");d.classList.add("form-group"),e&&(d.appendChild(e),u&&e.appendChild(u));var x=document.createElement("div");return Object.values(t).forEach(function(P){var D=P.firstChild;x.appendChild(D)}),d.appendChild(x),o&&d.appendChild(o),d}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in t)e.setAttribute(o,t[o]);return e.classList.add("form-check-input"),e}},{key:"getFormRadioLabel",value:function(t,e){var o=document.createElement("label");return o.classList.add("form-check-label"),o.appendChild(document.createTextNode(t)),o}},{key:"getFormRadioControl",value:function(t,e,o){var u=document.createElement("div");return u.classList.add("form-check"),u.appendChild(e),u.appendChild(t),o&&u.classList.add("form-check-inline"),u}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("card","card-body","my-3"),this.options.object_background&&t.classList.add(this.options.object_background),this.options.object_text&&t.classList.add(this.options.object_text),t}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("small");return e.classList.add("form-text"),e.classList.add("d-block"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getHeader",value:function(t,e){var o=document.createElement("h3");return o.classList.add("card-title"),o.classList.add("level-"+e),typeof t=="string"?o.textContent=t:o.appendChild(t),o.style.display="inline-block",o}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getButtonHolder",value:function(){var t=document.createElement("span");return t.classList.add("btn-group"),t}},{key:"getFormButtonHolder",value:function(t){var e=this.getButtonHolder();return e.classList.add("d-block"),t==="center"?e.classList.add("text-center"):t==="right"&&e.classList.add("text-end"),e}},{key:"getButton",value:function(t,e,o){var u=Ci(yn(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-secondary","btn-sm"),u}},{key:"getTableContainer",value:function(){var t=Ci(yn(l.prototype),"getTableContainer",this).call(this);return t.classList.add("table-responsive"),t}},{key:"getTable",value:function(){var t=document.createElement("table");return t.classList.add("table","table-sm"),this.options.table_border&&t.classList.add("table-bordered"),this.options.table_zebrastyle&&t.classList.add("table-striped"),t}},{key:"getErrorMessage",value:function(t){var e=document.createElement("div");return e.classList.add("alert","alert-danger"),e.setAttribute("role","alert"),e.appendChild(document.createTextNode(t)),e}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("is-invalid"),t.errmsg||(t.errmsg=document.createElement("p"),t.errmsg.classList.add("invalid-feedback"),t.controlgroup.appendChild(t.errmsg),t.errmsg.style.display="block"),t.errmsg.style.display="block",t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("is-invalid"))}},{key:"getTabHolder",value:function(t){var e=document.createElement("div"),o=t===void 0?"":t;return e.innerHTML="<div class='col-md-2' id='".concat(o,"'><ul class='nav flex-column nav-pills'></ul></div><div class='col-md-10'><div class='tab-content' id='").concat(o,"'></div></div>"),e.classList.add("row"),e}},{key:"addTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.classList.add("card"),o.innerHTML="<div class='card-header'><ul class='nav nav-tabs card-header-tabs' id='".concat(e,"'></ul></div><div class='card-body'><div class='tab-content' id='").concat(e,"'></div></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.firstChild.classList.add("active"),t.rowPane!==void 0?t.rowPane.classList.add("active"):t.container.classList.add("active")}},{key:"markTabInactive",value:function(t){t.tab.firstChild.classList.remove("active"),t.rowPane!==void 0?t.rowPane.classList.remove("active"):t.container.classList.remove("active")}},{key:"insertBasicTopTab",value:function(t,e){e.children[0].children[0].insertBefore(t,e.children[0].children[0].firstChild)}},{key:"addTopTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTopTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getFirstTab",value:function(t){return t.firstChild.firstChild.firstChild}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("progress-bar"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","progress-striped","active"),e.removeAttribute("aria-valuenow"),e.style.width="100%",e.innerHTML=""}}},{key:"getBlockLink",value:function(){var t=document.createElement("a");return t.classList.add("mb-3","d-inline-block"),t}},{key:"getLinksHolder",value:function(){return document.createElement("div")}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);for(var u=0;u<e.length;u++)e[u].classList.remove("me-2","btn-secondary"),e[u].classList.add("btn-outline-secondary"),o.appendChild(e[u]);return o}}}])&&Mf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function ko(c){return ko=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ko(c)}function Ff(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ko(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ko(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ko(h)==="symbol"?h:String(h)),i)}var h}function jo(){return jo=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Pn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},jo.apply(this,arguments)}function Kl(c,n){return Kl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Kl(c,n)}function Pn(c){return Pn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Pn(c)}$u.rules={".form-group":"margin-bottom:1rem",".form-text":"display:block",".jsoneditor-twbs5-text-button":"background:none;padding:0;border:0;color:currentColor","td > .form-group":"margin-bottom:0",".json-editor-btn-upload":"margin-top:1rem",".je-noindent .card":"padding:0;border:0",".je-tooltip:hover::before":"display:block;position:absolute;font-size:0.8em;color:%23fff;border-radius:0.2em;content:attr(title);background-color:%23000;margin-top:-2.5em;padding:0.3em",".je-tooltip:hover::after":"display:block;position:absolute;font-size:0.8em;color:%23fff",".select2-container--default .select2-selection--single":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__arrow":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__rendered":"line-height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".selectize-control.form-control":"padding:0",".selectize-dropdown.form-control":"padding:0;height:auto",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Mu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Kl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Pn(i);if(h){var o=Pn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(ko(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getTable",value:function(){var t=jo(Pn(l.prototype),"getTable",this).call(this);return t.setAttribute("cellpadding",5),t.setAttribute("cellspacing",0),t}},{key:"getTableHeaderCell",value:function(t){var e=jo(Pn(l.prototype),"getTableHeaderCell",this).call(this,t);return e.classList.add("ui-state-active"),e.style.fontWeight="bold",e}},{key:"getTableCell",value:function(){var t=jo(Pn(l.prototype),"getTableCell",this).call(this);return t.classList.add("ui-widget-content"),t}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.style.marginLeft="10px",t.style.fontSize=".6em",t.style.display="inline-block",t}},{key:"getFormInputDescription",value:function(t){var e=this.getDescription(t);return e.style.marginLeft="10px",e.style.display="inline-block",e}},{key:"getFormControl",value:function(t,e,o,u){var d=jo(Pn(l.prototype),"getFormControl",this).call(this,t,e,o,u);return e.type==="checkbox"?(d.style.lineHeight="25px",d.style.padding="3px 0"):d.style.padding="4px 0 8px 0",d}},{key:"getDescription",value:function(t){var e=document.createElement("span");return e.style.fontSize=".8em",e.style.fontStyle="italic",window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getButtonHolder",value:function(){var t=document.createElement("div");return t.classList.add("ui-buttonset"),t.style.fontSize=".7em",t}},{key:"getFormInputLabel",value:function(t,e){var o=document.createElement("label");return o.style.fontWeight="bold",o.style.display="block",o.textContent=t,e&&o.classList.add("required"),o}},{key:"getButton",value:function(t,e,o){var u=document.createElement("button");u.classList.add("ui-button","ui-widget","ui-state-default","ui-corner-all"),e&&!t?(u.classList.add("ui-button-icon-only"),e.classList.add("ui-button-icon-primary","ui-icon-primary"),u.appendChild(e)):e?(u.classList.add("ui-button-text-icon-primary"),e.classList.add("ui-button-icon-primary","ui-icon-primary"),u.appendChild(e)):u.classList.add("ui-button-text-only");var d=document.createElement("span");return d.classList.add("ui-button-text"),d.textContent=t||o||".",u.appendChild(d),u.setAttribute("title",o),u}},{key:"setButtonText",value:function(t,e,o,u){t.innerHTML="",t.classList.add("ui-button","ui-widget","ui-state-default","ui-corner-all"),o&&!e?(t.classList.add("ui-button-icon-only"),o.classList.add("ui-button-icon-primary","ui-icon-primary"),t.appendChild(o)):o?(t.classList.add("ui-button-text-icon-primary"),o.classList.add("ui-button-icon-primary","ui-icon-primary"),t.appendChild(o)):t.classList.add("ui-button-text-only");var d=document.createElement("span");d.classList.add("ui-button-text"),d.textContent=e||u||".",t.appendChild(d),t.setAttribute("title",u)}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("ui-widget-content","ui-corner-all"),t.style.padding="1em 1.4em",t.style.marginBottom="20px",t}},{key:"afterInputReady",value:function(t){if(!t.controls&&(t.controls=this.closest(t,".form-control"),this.queuedInputErrorText)){var e=this.queuedInputErrorText;delete this.queuedInputErrorText,this.addInputError(t,e)}}},{key:"addInputError",value:function(t,e){t.controls?(t.errmsg?t.errmsg.style.display="":(t.errmsg=document.createElement("div"),t.errmsg.classList.add("ui-state-error"),t.controls.appendChild(t.errmsg)),t.errmsg.textContent=e):this.queuedInputErrorText=e}},{key:"removeInputError",value:function(t){t.controls||delete this.queuedInputErrorText,t.errmsg&&(t.errmsg.style.display="none")}},{key:"markTabActive",value:function(t){t.tab.classList.remove("ui-widget-header"),t.tab.classList.add("ui-state-active"),t.rowPane!==void 0?t.rowPane.style.display="":t.container.style.display=""}},{key:"markTabInactive",value:function(t){t.tab.classList.add("ui-widget-header"),t.tab.classList.remove("ui-state-active"),t.rowPane!==void 0?t.rowPane.style.display="none":t.container.style.display="none"}}])&&Ff(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function Oo(c){return Oo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Oo(c)}function Vf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Oo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Oo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Oo(h)==="symbol"?h:String(h)),i)}var h}function Ql(c,n){return Ql=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ql(c,n)}function Ts(c){return Ts=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ts(c)}Mu.rules={'div[data-schemaid="root"]:after':'position:relative;color:red;margin:10px 0;font-weight:600;display:block;width:100%;text-align:center;content:"This is an old JSON-Editor 1.x Theme and might not display elements correctly when used with the 2.x version"'};var Hu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ql(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Ts(i);if(h){var o=Ts(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Oo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"addInputError",value:function(t,e){if(t.errmsg)t.errmsg.style.display="block";else{var o=this.closest(t,".form-control");t.errmsg=document.createElement("div"),t.errmsg.setAttribute("class","errmsg"),o.nodeName&&o.appendChild(t.errmsg)}t.errmsg.innerHTML="",t.errmsg.appendChild(document.createTextNode(e))}},{key:"removeInputError",value:function(t){t.style&&(t.style.borderColor=""),t.errmsg&&(t.errmsg.style.display="none")}}])&&Vf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function Eo(c){return Eo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Eo(c)}function zf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Eo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Eo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Eo(h)==="symbol"?h:String(h)),i)}var h}function gr(){return gr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=tr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},gr.apply(this,arguments)}function tc(c,n){return tc=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},tc(c,n)}function tr(c){return tr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},tr(c)}Hu.rules={".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Uf={disable_theme_rules:!1,label_bold:!0,align_bottom:!1,object_indent:!1,object_border:!1,table_border:!1,table_zebrastyle:!1,input_size:"normal"},Fu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&tc(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=tr(i);if(h){var o=tr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Eo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,Uf)}return n=l,(f=[{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-".concat(e)),o&&t.classList.add("col-mx-auto")}},{key:"getGridContainer",value:function(){var t=document.createElement("div");return t.classList.add("container"),this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"getGridRow",value:function(){var t=document.createElement("div");return t.classList.add("columns"),t}},{key:"getGridColumn",value:function(){var t=document.createElement("div");return t.classList.add("column"),this.options.align_bottom&&t.classList.add("je-align-bottom"),t}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("je-panel"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getTopIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("je-panel-top"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getButtonHolder",value:function(){var t=gr(tr(l.prototype),"getButtonHolder",this).call(this);return t.classList.add("btn-group"),t}},{key:"getFormButtonHolder",value:function(t){var e=gr(tr(l.prototype),"getFormButtonHolder",this).call(this);return e.classList.remove("btn-group"),e.classList.add("d-block"),t==="center"?e.classList.add("text-center"):t==="right"?e.classList.add("text-right"):e.classList.add("text-left"),e}},{key:"getFormButton",value:function(t,e,o){var u=gr(tr(l.prototype),"getFormButton",this).call(this,t,e,o);return u.classList.add("btn","btn-primary","mx-2","my-1"),this.options.input_size!=="small"&&u.classList.remove("btn-sm"),this.options.input_size==="large"&&u.classList.add("btn-lg"),u}},{key:"getButton",value:function(t,e,o){var u=gr(tr(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-sm","btn-primary","mr-2","my-1"),u}},{key:"getHeader",value:function(t,e){var o=document.createElement("h4");return typeof t=="string"?o.textContent=t:o.appendChild(t),o.style.display="inline-block",o}},{key:"getFormInputDescription",value:function(t){var e=gr(tr(l.prototype),"getFormInputDescription",this).call(this,t);return e.classList.add("je-desc","hide-sm"),e}},{key:"getFormInputLabel",value:function(t,e){var o=gr(tr(l.prototype),"getFormInputLabel",this).call(this,t,e);return this.options.label_bold&&o.classList.add("je-label"),o}},{key:"getCheckbox",value:function(){return this.getFormInputField("checkbox")}},{key:"getCheckboxLabel",value:function(t,e){var o=gr(tr(l.prototype),"getCheckboxLabel",this).call(this,t,e),u=document.createElement("i");return u.classList.add("form-icon"),o.classList.add("form-checkbox","pr-0"),o.insertBefore(u,o.firstChild),o}},{key:"getFormCheckboxControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("form-inline"),t}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){return gr(tr(l.prototype),"getMultiCheckboxHolder",this).call(this,t,e,o,u)}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in t)e.setAttribute(o,t[o]);return e}},{key:"getFormRadioLabel",value:function(t,e){var o=gr(tr(l.prototype),"getFormRadioLabel",this).call(this,t,e),u=document.createElement("i");return u.classList.add("form-icon"),o.classList.add("form-radio"),o.insertBefore(u,o.firstChild),o}},{key:"getFormRadioControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("form-inline"),t}},{key:"getFormInputField",value:function(t){var e=gr(tr(l.prototype),"getFormInputField",this).call(this,t);return["checkbox","radio"].includes(t)||e.classList.add("form-input"),e}},{key:"getRangeInput",value:function(t,e,o){var u=this.getFormInputField("range");return u.classList.add("slider"),u.classList.remove("form-input"),u.setAttribute("oninput",'this.setAttribute("value", this.value)'),u.setAttribute("min",t),u.setAttribute("max",e),u.setAttribute("step",o),u}},{key:"getRangeControl",value:function(t,e){var o=gr(tr(l.prototype),"getRangeControl",this).call(this,t,e);return o.classList.add("text-center"),o}},{key:"getSelectInput",value:function(t,e){var o=gr(tr(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-select"),o}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-input"),t}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");return d.classList.add("form-group"),!t||e.type!=="checkbox"&&e.type!=="radio"?(t&&(t.classList.add("form-label"),d.appendChild(t),u&&t.appendChild(u)),d.appendChild(e)):(d.classList.add(e.type),u&&t.appendChild(u),t.insertBefore(e,t.firstChild),d.appendChild(t)),this.options.input_size==="small"?e.classList.add("input-sm","select-sm"):this.options.input_size==="large"&&e.classList.add("input-lg","select-lg"),e.type!=="checkbox"&&d.appendChild(e),o&&d.appendChild(o),d}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);for(var u=0;u<e.length;u++)e[u].classList.add("input-group-btn"),e[u].classList.remove("btn-sm","mr-2","my-1"),o.appendChild(e[u]);return o}}},{key:"getInfoButton",value:function(t){var e=document.createElement("div");e.classList.add("popover","popover-left","float-right");var o=document.createElement("button");o.classList.add("btn","btn-secondary","btn-info","btn-action","s-circle"),o.setAttribute("tabindex","-1"),e.appendChild(o);var u=document.createTextNode("I");o.appendChild(u);var d=document.createElement("div");d.classList.add("popover-container"),e.appendChild(d);var x=document.createElement("div");x.classList.add("card"),d.appendChild(x);var P=document.createElement("div");return P.classList.add("card-body"),P.innerHTML=t,x.appendChild(P),e}},{key:"getTable",value:function(){var t=gr(tr(l.prototype),"getTable",this).call(this);return t.classList.add("table","table-scroll"),this.options.table_border&&t.classList.add("je-table-border"),this.options.table_zebrastyle&&t.classList.add("table-striped"),t}},{key:"getProgressBar",value:function(){var t=gr(tr(l.prototype),"getProgressBar",this).call(this);return t.classList.add("progress"),t}},{key:"getTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.classList.add("columns"),o.innerHTML='<div class="column col-2"></div><div class="column col-10 content" id="'.concat(e,'"></div>'),o}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML='<ul class="tab"></ul><div class="content" id="'.concat(e,'"></div>'),o}},{key:"getTab",value:function(t,e){var o=document.createElement("a");return o.classList.add("btn","btn-secondary","btn-block"),o.setAttribute("href","#".concat(e)),o.appendChild(t),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.id=e,o.classList.add("tab-item");var u=document.createElement("a");return u.setAttribute("href","#".concat(e)),u.appendChild(t),o.appendChild(u),o}},{key:"markTabActive",value:function(t){t.tab.classList.add("active"),t.rowPane!==void 0?t.rowPane.style.display="":t.container.style.display=""}},{key:"markTabInactive",value:function(t){t.tab.classList.remove("active"),t.rowPane!==void 0?t.rowPane.style.display="none":t.container.style.display="none"}},{key:"afterInputReady",value:function(t){if(t.localName==="select"){if(t.classList.contains("selectized")){var e=t.nextSibling;e&&(e.classList.remove("form-select"),Array.from(e.querySelectorAll(".form-select")).forEach(function(u){u.classList.remove("form-select")}))}else if(t.classList.contains("select2-hidden-accessible")){var o=t.nextSibling;o&&o.querySelector(".select2-selection--single")&&o.classList.add("form-select")}}t.controlgroup||(t.controlgroup=this.closest(t,".form-group"),this.closest(t,".compact")&&(t.controlgroup.style.marginBottom=0))}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("has-error"),t.errmsg||(t.errmsg=document.createElement("p"),t.errmsg.classList.add("form-input-hint"),t.controlgroup.appendChild(t.errmsg)),t.errmsg.classList.remove("d-hide"),t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.classList.add("d-hide"),t.controlgroup.classList.remove("has-error"))}}])&&zf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function Co(c){return Co=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Co(c)}function qf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Co(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Co(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Co(h)==="symbol"?h:String(h)),i)}var h}function wr(){return wr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=er(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},wr.apply(this,arguments)}function ec(c,n){return ec=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ec(c,n)}function er(c){return er=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},er(c)}Fu.rules={"*":"--primary-color:%235755d9;--gray-color:%23bcc3ce;--light-color:%23fff",".slider:focus":"box-shadow:none","h4 > label + .btn-group":"margin-left:1rem",".text-right > button":"margin-right:0%20!important",".text-left > button":"margin-left:0%20!important",".property-selector":"font-size:0.7rem;font-weight:normal;max-height:260px%20!important;width:395px%20!important",".property-selector .form-checkbox":"margin:0",textarea:"width:100%25;min-height:2rem;resize:vertical",table:"border-collapse:collapse",".table td":"padding:0.4rem%200.4rem",".mr-5":"margin-right:1rem%20!important","div[data-schematype]:not([data-schematype='object'])":"transition:0.5s","div[data-schematype]:not([data-schematype='object']):hover":"background-color:%23eee",".je-table-border td":"border:0.05rem%20solid%20%23dadee4%20!important",".btn-info":"font-size:0.5rem;font-weight:bold;height:0.8rem;padding:0.15rem%200;line-height:0.8;margin:0.3rem%200%200.3rem%200.1rem",".je-label + select":"min-width:5rem",".je-label":"font-weight:600",".btn-action.btn-info":"width:0.8rem",".je-border":"border:0.05rem%20solid%20%23dadee4",".je-panel":"padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".je-panel-top":"padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".required:after":"content:%22%20*%22;color:red;font:inherit",".je-align-bottom":"margin-top:auto",".je-desc":"font-size:smaller;margin:0.2rem%200",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem;border:3px%20solid%20white;box-shadow:0px%200px%208px%20rgba(0%2C%200%2C%200%2C%200.3);box-sizing:border-box",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red",".columns .container.je-noindent":"padding-left:0;padding-right:0",".selectize-control.multi .item":"background:var(--primary-color)%20!important",".select2-container--default .select2-selection--single .select2-selection__arrow":"display:none",".select2-container--default .select2-selection--single":"border:none",".select2-container .select2-selection--single .select2-selection__rendered":"padding:0",".select2-container .select2-search--inline .select2-search__field":"margin-top:0",".select2-container--default.select2-container--focus .select2-selection--multiple":"border:0.05rem%20solid%20var(--gray-color)",".select2-container--default .select2-selection--multiple .select2-selection__choice":"margin:0.4rem%200.2rem%200.2rem%200;padding:2px%205px;background-color:var(--primary-color);color:var(--light-color)",".select2-container--default .select2-search--inline .select2-search__field":"line-height:normal",".choices":"margin-bottom:auto",".choices__list--multiple .choices__item":"border:none;background-color:var(--primary-color);color:var(--light-color)",".choices[data-type*='select-multiple'] .choices__button":"border-left:0.05rem%20solid%20%232826a6",".choices__inner":"font-size:inherit;min-height:20px;padding:4px%207.5px%204px%203.75px",".choices[data-type*='select-one'] .choices__inner":"padding-bottom:4px",".choices__list--dropdown .choices__item":"font-size:inherit"};var Gf={disable_theme_rules:!1,label_bold:!1,object_panel_default:!0,object_indent:!0,object_border:!1,table_border:!1,table_hdiv:!1,table_zebrastyle:!1,input_size:"small",enable_compact:!1},Vu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ec(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=er(i);if(h){var o=er(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Co(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,Gf)}return n=l,(f=[{key:"getGridContainer",value:function(){var t=document.createElement("div");return t.classList.add("flex","flex-col","w-full"),this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"getGridRow",value:function(){var t=document.createElement("div");return t.classList.add("flex","flex-wrap","w-full"),t}},{key:"getGridColumn",value:function(){var t=document.createElement("div");return t.classList.add("flex","flex-col"),t}},{key:"setGridColumnSize",value:function(t,e,o){e>0&&e<12?t.classList.add("w-".concat(e,"/12"),"px-1"):t.classList.add("w-full","px-1"),o&&(t.style.marginLeft="".concat(100/12*o,"%"))}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return this.options.object_panel_default?t.classList.add("w-full","p-1"):t.classList.add("relative","flex","flex-col","rounded","break-words","border","bg-white","border-0","border-blue-400","p-1","shadow-md"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getTopIndentedPanel",value:function(){var t=document.createElement("div");return this.options.object_panel_default?t.classList.add("w-full","m-2"):t.classList.add("relative","flex","flex-col","rounded","break-words","border","bg-white","border-0","border-blue-400","p-1","shadow-md"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getTitle",value:function(){return this.translateProperty(this.schema.title)}},{key:"getSelectInput",value:function(t,e){var o=wr(er(l.prototype),"getSelectInput",this).call(this,t);return e?o.classList.add("form-multiselect","block","py-0","h-auto","w-full","px-1","text-sm","text-black","leading-normal","bg-white","border","border-grey","rounded"):o.classList.add("form-select","block","py-0","h-6","w-full","px-1","text-sm","text-black","leading-normal","bg-white","border","border-grey","rounded"),this.options.enable_compact&&o.classList.add("compact"),o}},{key:"afterInputReady",value:function(t){t.controlgroup||(t.controlgroup=this.closest(t,".form-group"),this.closest(t,".compact")&&(t.controlgroup.style.marginBottom=0))}},{key:"getTextareaInput",value:function(){var t=wr(er(l.prototype),"getTextareaInput",this).call(this);return t.classList.add("block","w-full","px-1","text-sm","leading-normal","bg-white","text-black","border","border-grey","rounded"),this.options.enable_compact&&t.classList.add("compact"),t.style.height=0,t}},{key:"getRangeInput",value:function(t,e,o){var u=this.getFormInputField("range");return u.classList.add("slider"),this.options.enable_compact&&u.classList.add("compact"),u.setAttribute("oninput",'this.setAttribute("value", this.value)'),u.setAttribute("min",t),u.setAttribute("max",e),u.setAttribute("step",o),u}},{key:"getRangeControl",value:function(t,e){var o=wr(er(l.prototype),"getRangeControl",this).call(this,t,e);return o.classList.add("text-center","text-black"),o}},{key:"getCheckbox",value:function(){var t=this.getFormInputField("checkbox");return t.classList.add("form-checkbox","text-red-600"),t}},{key:"getCheckboxLabel",value:function(t,e){var o=wr(er(l.prototype),"getCheckboxLabel",this).call(this,t,e);return o.classList.add("inline-flex","items-center"),o}},{key:"getFormCheckboxControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("inline-flex flex-row"),t}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){var d=wr(er(l.prototype),"getMultiCheckboxHolder",this).call(this,t,e,o,u);return d.classList.add("inline-flex","flex-col"),d}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in e.classList.add("form-radio","text-red-600"),t)e.setAttribute(o,t[o]);return e}},{key:"getFormRadioLabel",value:function(t,e){var o=wr(er(l.prototype),"getFormRadioLabel",this).call(this,t,e);return o.classList.add("inline-flex","items-center","mr-2"),o}},{key:"getFormRadioControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("form-radio"),t}},{key:"getRadioHolder",value:function(t,e,o,u,d){var x=wr(er(l.prototype),"getRadioHolder",this).call(this,e,o,u,d);return t.options.layout==="h"?x.classList.add("inline-flex","flex-row"):x.classList.add("inline-flex","flex-col"),x}},{key:"getFormInputLabel",value:function(t,e){var o=wr(er(l.prototype),"getFormInputLabel",this).call(this,t,e);return this.options.label_bold?o.classList.add("font-bold"):o.classList.add("required"),o}},{key:"getFormInputField",value:function(t){var e=wr(er(l.prototype),"getFormInputField",this).call(this,t);return["checkbox","radio"].includes(t)||e.classList.add("block","w-full","px-1","text-black","text-sm","leading-normal","bg-white","border","border-grey","rounded"),this.options.enable_compact&&e.classList.add("compact"),e}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("p");return e.classList.add("block","mt-1","text-xs"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");return d.classList.add("form-group","mb-1","w-full"),t&&(t.classList.add("text-xs"),e.type==="checkbox"&&(e.classList.add("form-checkbox","text-xs","text-red-600","mr-1"),t.classList.add("items-center","flex"),t=this.getFormCheckboxControl(t,e,!1,u)),e.type==="radio"&&(e.classList.add("form-radio","text-red-600","mr-1"),t.classList.add("items-center","flex"),t=this.getFormRadioControl(t,e,!1,u)),d.appendChild(t),!["checkbox","radio"].includes(e.type)&&u&&d.appendChild(u)),["checkbox","radio"].includes(e.type)||(this.options.input_size==="small"?e.classList.add("text-xs"):this.options.input_size==="normal"?e.classList.add("text-base"):this.options.input_size==="large"&&e.classList.add("text-xl"),d.appendChild(e)),o&&d.appendChild(o),d}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.classList.add("text-sm"),t}},{key:"getButtonHolder",value:function(){var t=document.createElement("div");return t.classList.add("flex","relative","inline-flex","align-middle"),t}},{key:"getButton",value:function(t,e,o){var u=wr(er(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("inline-block","align-middle","text-center","text-sm","bg-blue-700","text-white","py-1","pr-1","m-2","shadow","select-none","whitespace-no-wrap","rounded"),u}},{key:"getInfoButton",value:function(t){var e=document.createElement("a");e.classList.add("tooltips","float-right"),e.innerHTML="ⓘ";var o=document.createElement("span");return o.innerHTML=t,e.appendChild(o),e}},{key:"getTable",value:function(){var t=wr(er(l.prototype),"getTable",this).call(this);return this.options.table_border?t.classList.add("je-table-border"):t.classList.add("table","border","p-0"),t}},{key:"getTableRow",value:function(){var t=wr(er(l.prototype),"getTableRow",this).call(this);return this.options.table_border&&t.classList.add("je-table-border"),this.options.table_zebrastyle&&t.classList.add("je-table-zebra"),t}},{key:"getTableHeaderCell",value:function(t){var e=wr(er(l.prototype),"getTableHeaderCell",this).call(this,t);return this.options.table_border?e.classList.add("je-table-border"):this.options.table_hdiv?e.classList.add("je-table-hdiv"):e.classList.add("text-xs","border","p-0","m-0"),e}},{key:"getTableCell",value:function(){var t=wr(er(l.prototype),"getTableCell",this).call(this);return this.options.table_border?t.classList.add("je-table-border"):this.options.table_hdiv?t.classList.add("je-table-hdiv"):t.classList.add("border-0","p-0","m-0"),t}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("has-error"),t.controlgroup.classList.add("text-red-600"),t.errmsg?t.errmsg.style.display="":(t.errmsg=document.createElement("p"),t.errmsg.classList.add("block","mt-1","text-xs","text-red"),t.controlgroup.appendChild(t.errmsg)),t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("text-red-600"),t.controlgroup.classList.remove("has-error"))}},{key:"getTabHolder",value:function(t){var e=document.createElement("div"),o=t===void 0?"":t;return e.innerHTML="<div class='w-2/12' id='".concat(o,"'><ul class='list-reset pl-0 mb-0'></ul></div><div class='w-10/12' id='").concat(o,"'></div>"),e.classList.add("flex"),e}},{key:"addTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML="<ul class='nav-tabs flex list-reset pl-0 mb-0 border-b border-grey-light' id='".concat(e,"'></ul><div class='p-6 block' id='").concat(e,"'></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item","flex-col","text-center","text-white","bg-blue-500","shadow-md","border","p-2","mb-2","mr-2","hover:bg-blue-400","rounded");var u=document.createElement("a");return u.classList.add("nav-link","text-center"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item","flex","border-l","border-t","border-r");var u=document.createElement("a");return u.classList.add("nav-link","-mb-px","flex-row","text-center","bg-white","p-2","hover:bg-blue-400","rounded-t"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.firstChild.classList.add("block"),t.tab.firstChild.classList.contains("border-b")===!0?(t.tab.firstChild.classList.add("border-b-0"),t.tab.firstChild.classList.remove("border-b")):t.tab.firstChild.classList.add("border-b-0"),t.container.classList.contains("hidden")===!0&&t.container.classList.remove("hidden"),t.container.classList.add("block")}},{key:"markTabInactive",value:function(t){t.tab.firstChild.classList.contains("border-b-0")===!0?(t.tab.firstChild.classList.add("border-b"),t.tab.firstChild.classList.remove("border-b-0")):t.tab.firstChild.classList.add("border-b"),t.container.classList.contains("block")===!0&&(t.container.classList.remove("block"),t.container.classList.add("hidden"))}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("bg-blue","leading-none","py-1","text-xs","text-center","text-white"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","bg-blue","leading-none","py-1","text-xs","text-center","text-white","block"),e.removeAttribute("aria-valuenow"),e.classList.add("w-full"),e.innerHTML=""}}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("relative","items-stretch","w-full"),o.appendChild(t);var u=document.createElement("div");u.classList.add("-mr-1"),o.appendChild(u);for(var d=0;d<e.length;d++)u.appendChild(e[d]);return o}}}])&&qf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);Vu.rules={".slider":"-webkit-appearance:none;-moz-appearance:none;appearance:none;background:transparent;display:block;border:none;height:1.2rem;width:100%25",".slider:focus":"box-shadow:0%200%200%200%20rgba(87%2C%2085%2C%20217%2C%200.2);outline:none",".slider.tooltip:not([data-tooltip])::after":"content:attr(value)",".slider::-webkit-slider-thumb":"-webkit-appearance:none;background:%23f17405;border-radius:100%25;height:0.6rem;margin-top:-0.25rem;transition:transform%200.2s;width:0.6rem",".slider:active::-webkit-slider-thumb":"transform:scale(1.25);outline:none",".slider::-webkit-slider-runnable-track":"background:%23b2b4b6;border-radius:0.1rem;height:0.1rem;width:100%25","a.tooltips":"position:relative;display:inline","a.tooltips span":"position:absolute;white-space:nowrap;width:auto;padding-left:1rem;padding-right:1rem;color:%23ffffff;background:rgba(56%2C%2056%2C%2056%2C%200.85);height:1.5rem;line-height:1.5rem;text-align:center;visibility:hidden;border-radius:3px","a.tooltips span:after":"content:%22%22;position:absolute;top:50%25;left:100%25;margin-top:-5px;width:0;height:0;border-left:5px%20solid%20rgba(56%2C%2056%2C%2056%2C%200.85);border-top:5px%20solid%20transparent;border-bottom:5px%20solid%20transparent","a:hover.tooltips span":"visibility:visible;opacity:0.9;font-size:0.8rem;right:100%25;top:50%25;margin-top:-12px;margin-right:10px;z-index:999",".json-editor-btntype-properties + div":"font-size:0.8rem;font-weight:normal",textarea:"width:100%25;min-height:2rem;resize:vertical",table:"width:100%25;border-collapse:collapse",".table td":"padding:0rem%200rem","div[data-schematype]:not([data-schematype='object'])":"transition:0.5s","div[data-schematype]:not([data-schematype='object']):hover":"background-color:%23e6f4fe","div[data-schemaid='root']":"position:relative;width:inherit;display:inherit;overflow-x:hidden;z-index:10","select[multiple]":"height:auto","select[multiple].from-select":"height:auto",".je-table-zebra:nth-child(even)":"background-color:%23f2f2f2",".je-table-border":"border:0.5px%20solid%20black",".je-table-hdiv":"border-bottom:1px%20solid%20black",".je-border":"border:0.05rem%20solid%20%233182ce",".je-panel":"width:inherit;padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".je-panel-top":"width:100%25;padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".required:after":"content:%22%20*%22;color:red;font:inherit;font-weight:bold",".je-desc":"font-size:smaller;margin:0.2rem%200",".container-xl.je-noindent":"padding-left:0;padding-right:0",".json-editor-btntype-add":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%234299e1;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btntype-deletelast":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%23e53e3e;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btntype-deleteall":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%23000000;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btn-save":"float:right;color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%232b6cb0;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btn-back":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%232b6cb0;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btntype-delete":"color:%23e53e3e;background-color:rgba(218%2C%20222%2C%20228%2C%200.1);margin:0.03rem;padding:0.1rem",".json-editor-btntype-move":"color:%23000000;background-color:rgba(218%2C%20222%2C%20228%2C%200.1);margin:0.03rem;padding:0.1rem",".json-editor-btn-collapse":"padding:0em%200.8rem;font-size:1.3rem;color:%23e53e3e;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Wf={html:Bu,bootstrap3:Du,bootstrap4:Nu,bootstrap5:$u,jqueryui:Mu,barebones:Hu,spectre:Fu,tailwind:Vu};const Zf={".je-float-right-linkholder":"float:right;margin-left:10px",".je-modal":"background-color:white;border:1px%20solid%20black;box-shadow:3px%203px%20black;position:absolute;z-index:10",".je-infobutton-icon":"font-size:16px;font-weight:bold;padding:0.25rem;position:relative;display:inline-block",".je-infobutton-tooltip":"font-size:12px;font-weight:normal;font-family:sans-serif;visibility:hidden;background-color:rgba(50%2C%2050%2C%2050%2C%200.75);margin:0%200.25rem;color:%23fafafa;padding:0.5rem%201rem;border-radius:0.25rem;width:20rem;position:absolute",".je-not-loaded":"pointer-events:none",".je-header":"display:inline-block",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-checkbox":"display:inline-block;width:auto",".je-checkbox-control--compact":"display:inline-block;margin-right:1rem",".je-radio":"display:inline-block;width:auto",".je-radio-control--compact":"display:inline-block;margin-right:1rem",".je-switcher":"background-color:transparent;display:inline-block;font-style:italic;font-weight:normal;height:auto;width:auto;margin-bottom:0;margin-left:5px;padding:0%200%200%203px",".je-textarea":"width:100%25;height:300px;box-sizing:border-box",".je-range-control":"text-align:center",".je-indented-panel":"padding-left:10px;margin-left:10px;border-left:1px%20solid%20%23ccc",".je-indented-panel--top":"padding-left:10px;margin-left:10px",".je-tabholder":"float:left;width:130px",".je-tabholder .content":"margin-left:120px",".je-tabholder--top":"margin-left:10px",".je-tabholder--clear":"clear:both",".je-tab":"border:1px%20solid%20%23ccc;border-width:1px%200%201px%201px;text-align:center;line-height:30px;border-radius:5px;border-bottom-right-radius:0;border-top-right-radius:0;font-weight:bold;cursor:pointer",".je-tab--top":"float:left;border:1px%20solid%20%23ccc;border-width:1px%201px%200px%201px;text-align:center;line-height:30px;border-radius:5px;padding-left:5px;padding-right:5px;border-bottom-right-radius:0;border-bottom-left-radius:0;font-weight:bold;cursor:pointer",".je-block-link":"display:block",".je-media":"width:100%25"};function So(c){return So=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},So(c)}function rc(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function nc(){nc=function(){return c};var c={},n=Object.prototype,f=n.hasOwnProperty,i=Object.defineProperty||function(W,G,Z){W[G]=Z.value},h=typeof Symbol=="function"?Symbol:{},a=h.iterator||"@@iterator",l=h.asyncIterator||"@@asyncIterator",t=h.toStringTag||"@@toStringTag";function e(W,G,Z){return Object.defineProperty(W,G,{value:Z,enumerable:!0,configurable:!0,writable:!0}),W[G]}try{e({},"")}catch{e=function(G,Z,pt){return G[Z]=pt}}function o(W,G,Z,pt){var et=G&&G.prototype instanceof x?G:x,Lt=Object.create(et.prototype),re=new gt(pt||[]);return i(Lt,"_invoke",{value:$t(W,Z,re)}),Lt}function u(W,G,Z){try{return{type:"normal",arg:W.call(G,Z)}}catch(pt){return{type:"throw",arg:pt}}}c.wrap=o;var d={};function x(){}function P(){}function D(){}var J={};e(J,a,function(){return this});var nt=Object.getPrototypeOf,ut=nt&&nt(nt(Zt([])));ut&&ut!==n&&f.call(ut,a)&&(J=ut);var dt=D.prototype=x.prototype=Object.create(J);function kt(W){["next","throw","return"].forEach(function(G){e(W,G,function(Z){return this._invoke(G,Z)})})}function Ct(W,G){function Z(et,Lt,re,Pe){var Te=u(W[et],W,Lt);if(Te.type!=="throw"){var Dr=Te.arg,tn=Dr.value;return tn&&So(tn)=="object"&&f.call(tn,"__await")?G.resolve(tn.__await).then(function(kr){Z("next",kr,re,Pe)},function(kr){Z("throw",kr,re,Pe)}):G.resolve(tn).then(function(kr){Dr.value=kr,re(Dr)},function(kr){return Z("throw",kr,re,Pe)})}Pe(Te.arg)}var pt;i(this,"_invoke",{value:function(et,Lt){function re(){return new G(function(Pe,Te){Z(et,Lt,Pe,Te)})}return pt=pt?pt.then(re,re):re()}})}function $t(W,G,Z){var pt="suspendedStart";return function(et,Lt){if(pt==="executing")throw new Error("Generator is already running");if(pt==="completed"){if(et==="throw")throw Lt;return{value:void 0,done:!0}}for(Z.method=et,Z.arg=Lt;;){var re=Z.delegate;if(re){var Pe=ne(re,Z);if(Pe){if(Pe===d)continue;return Pe}}if(Z.method==="next")Z.sent=Z._sent=Z.arg;else if(Z.method==="throw"){if(pt==="suspendedStart")throw pt="completed",Z.arg;Z.dispatchException(Z.arg)}else Z.method==="return"&&Z.abrupt("return",Z.arg);pt="executing";var Te=u(W,G,Z);if(Te.type==="normal"){if(pt=Z.done?"completed":"suspendedYield",Te.arg===d)continue;return{value:Te.arg,done:Z.done}}Te.type==="throw"&&(pt="completed",Z.method="throw",Z.arg=Te.arg)}}}function ne(W,G){var Z=G.method,pt=W.iterator[Z];if(pt===void 0)return G.delegate=null,Z==="throw"&&W.iterator.return&&(G.method="return",G.arg=void 0,ne(W,G),G.method==="throw")||Z!=="return"&&(G.method="throw",G.arg=new TypeError("The iterator does not provide a '"+Z+"' method")),d;var et=u(pt,W.iterator,G.arg);if(et.type==="throw")return G.method="throw",G.arg=et.arg,G.delegate=null,d;var Lt=et.arg;return Lt?Lt.done?(G[W.resultName]=Lt.value,G.next=W.nextLoc,G.method!=="return"&&(G.method="next",G.arg=void 0),G.delegate=null,d):Lt:(G.method="throw",G.arg=new TypeError("iterator result is not an object"),G.delegate=null,d)}function Re(W){var G={tryLoc:W[0]};1 in W&&(G.catchLoc=W[1]),2 in W&&(G.finallyLoc=W[2],G.afterLoc=W[3]),this.tryEntries.push(G)}function Gt(W){var G=W.completion||{};G.type="normal",delete G.arg,W.completion=G}function gt(W){this.tryEntries=[{tryLoc:"root"}],W.forEach(Re,this),this.reset(!0)}function Zt(W){if(W){var G=W[a];if(G)return G.call(W);if(typeof W.next=="function")return W;if(!isNaN(W.length)){var Z=-1,pt=function et(){for(;++Z<W.length;)if(f.call(W,Z))return et.value=W[Z],et.done=!1,et;return et.value=void 0,et.done=!0,et};return pt.next=pt}}return{next:Ge}}function Ge(){return{value:void 0,done:!0}}return P.prototype=D,i(dt,"constructor",{value:D,configurable:!0}),i(D,"constructor",{value:P,configurable:!0}),P.displayName=e(D,t,"GeneratorFunction"),c.isGeneratorFunction=function(W){var G=typeof W=="function"&&W.constructor;return!!G&&(G===P||(G.displayName||G.name)==="GeneratorFunction")},c.mark=function(W){return Object.setPrototypeOf?Object.setPrototypeOf(W,D):(W.__proto__=D,e(W,t,"GeneratorFunction")),W.prototype=Object.create(dt),W},c.awrap=function(W){return{__await:W}},kt(Ct.prototype),e(Ct.prototype,l,function(){return this}),c.AsyncIterator=Ct,c.async=function(W,G,Z,pt,et){et===void 0&&(et=Promise);var Lt=new Ct(o(W,G,Z,pt),et);return c.isGeneratorFunction(G)?Lt:Lt.next().then(function(re){return re.done?re.value:Lt.next()})},kt(dt),e(dt,t,"Generator"),e(dt,a,function(){return this}),e(dt,"toString",function(){return"[object Generator]"}),c.keys=function(W){var G=Object(W),Z=[];for(var pt in G)Z.push(pt);return Z.reverse(),function et(){for(;Z.length;){var Lt=Z.pop();if(Lt in G)return et.value=Lt,et.done=!1,et}return et.done=!0,et}},c.values=Zt,gt.prototype={constructor:gt,reset:function(W){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(Gt),!W)for(var G in this)G.charAt(0)==="t"&&f.call(this,G)&&!isNaN(+G.slice(1))&&(this[G]=void 0)},stop:function(){this.done=!0;var W=this.tryEntries[0].completion;if(W.type==="throw")throw W.arg;return this.rval},dispatchException:function(W){if(this.done)throw W;var G=this;function Z(Te,Dr){return Lt.type="throw",Lt.arg=W,G.next=Te,Dr&&(G.method="next",G.arg=void 0),!!Dr}for(var pt=this.tryEntries.length-1;pt>=0;--pt){var et=this.tryEntries[pt],Lt=et.completion;if(et.tryLoc==="root")return Z("end");if(et.tryLoc<=this.prev){var re=f.call(et,"catchLoc"),Pe=f.call(et,"finallyLoc");if(re&&Pe){if(this.prev<et.catchLoc)return Z(et.catchLoc,!0);if(this.prev<et.finallyLoc)return Z(et.finallyLoc)}else if(re){if(this.prev<et.catchLoc)return Z(et.catchLoc,!0)}else{if(!Pe)throw new Error("try statement without catch or finally");if(this.prev<et.finallyLoc)return Z(et.finallyLoc)}}}},abrupt:function(W,G){for(var Z=this.tryEntries.length-1;Z>=0;--Z){var pt=this.tryEntries[Z];if(pt.tryLoc<=this.prev&&f.call(pt,"finallyLoc")&&this.prev<pt.finallyLoc){var et=pt;break}}et&&(W==="break"||W==="continue")&&et.tryLoc<=G&&G<=et.finallyLoc&&(et=null);var Lt=et?et.completion:{};return Lt.type=W,Lt.arg=G,et?(this.method="next",this.next=et.finallyLoc,d):this.complete(Lt)},complete:function(W,G){if(W.type==="throw")throw W.arg;return W.type==="break"||W.type==="continue"?this.next=W.arg:W.type==="return"?(this.rval=this.arg=W.arg,this.method="return",this.next="end"):W.type==="normal"&&G&&(this.next=G),d},finish:function(W){for(var G=this.tryEntries.length-1;G>=0;--G){var Z=this.tryEntries[G];if(Z.finallyLoc===W)return this.complete(Z.completion,Z.afterLoc),Gt(Z),d}},catch:function(W){for(var G=this.tryEntries.length-1;G>=0;--G){var Z=this.tryEntries[G];if(Z.tryLoc===W){var pt=Z.completion;if(pt.type==="throw"){var et=pt.arg;Gt(Z)}return et}}throw new Error("illegal catch attempt")},delegateYield:function(W,G,Z){return this.delegate={iterator:Zt(W),resultName:G,nextLoc:Z},this.method==="next"&&(this.arg=void 0),d}},c}function zu(c,n,f,i,h,a,l){try{var t=c[a](l),e=t.value}catch(o){return void f(o)}t.done?n(e):Promise.resolve(e).then(i,h)}function Jf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(So(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(So(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),So(h)==="symbol"?h:String(h)),i)}var h}var Tn=function(){function c(a){var l=this,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(function(D,J){if(!(D instanceof J))throw new TypeError("Cannot call a class as a function")}(this,c),!(a instanceof Element))throw new Error("element should be an instance of Element");this.element=a,this.options=k({},c.defaults.options,t),this.ready=!1,this.copyClipboard=null,this.schema=this.options.schema,this.template=this.options.template,this.translate=this.options.translate||c.defaults.translate,this.translateProperty=this.options.translateProperty||c.defaults.translateProperty,this.uuid=0,this.__data={};var e=this.options.theme||c.defaults.theme,o=c.defaults.themes[e];if(!o)throw new Error("Unknown theme ".concat(e));this.element.setAttribute("data-theme",e),this.element.classList.add("je-not-loaded"),this.element.classList.remove("je-ready"),this.theme=new o(this);var u=k(Zf,this.getEditorsRules()),d=function(D,J,nt){return nt?l.addNewStyleRulesToShadowRoot(D,J,nt):l.addNewStyleRules(D,J)};if(!this.theme.options.disable_theme_rules){var x=C(this.element);d("default",u,x),o.rules!==void 0&&d(e,o.rules,x)}var P=c.defaults.iconlibs[this.options.iconlib||c.defaults.iconlib];P&&(this.iconlib=new P),this.root_container=this.theme.getContainer(),this.element.appendChild(this.root_container),this.promise=this.load()}var n,f,i,h;return n=c,f=[{key:"load",value:(i=nc().mark(function a(){var l,t,e,o,u,d,x=this;return nc().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:return l=document.location.origin+document.location.pathname.toString(),(t=new af(this.options)).onSchemaLoaded=function(D){x.trigger("schemaLoaded",D)},t.onAllSchemasLoaded=function(){x.trigger("allSchemasLoaded")},this.expandSchema=function(D){return t.expandSchema(D)},this.expandRefs=function(D,J){return t.expandRefs(D,J)},e=document.location.toString(),P.next=9,t.load(this.schema,l,e);case 9:o=P.sent,u=this.options.custom_validators?{custom_validators:this.options.custom_validators}:{},this.validator=new Qi(this,null,u,c.defaults),d=this.getEditorClass(o),this.root=this.createEditor(d,{jsoneditor:this,schema:o,required:!0,container:this.root_container}),this.root.preBuild(),this.root.build(),this.root.postBuild(),S(this.options,"startval")&&this.root.setValue(this.options.startval),this.validation_results=this.validator.validate(this.root.getValue()),this.root.showValidationErrors(this.validation_results),this.ready=!0,this.element.classList.remove("je-not-loaded"),this.element.classList.add("je-ready"),window.requestAnimationFrame(function(){x.ready&&(x.validation_results=x.validator.validate(x.root.getValue()),x.root.showValidationErrors(x.validation_results),x.trigger("ready"),x.trigger("change"))});case 24:case"end":return P.stop()}},a,this)}),h=function(){var a=this,l=arguments;return new Promise(function(t,e){var o=i.apply(a,l);function u(x){zu(o,t,e,u,d,"next",x)}function d(x){zu(o,t,e,u,d,"throw",x)}u(void 0)})},function(){return h.apply(this,arguments)})},{key:"getValue",value:function(){if(!this.ready)throw new Error("JSON Editor not ready yet. Make sure the load method is complete");return this.root.getValue()}},{key:"setValue",value:function(a){if(!this.ready)throw new Error("JSON Editor not ready yet. Make sure the load method is complete");return this.root.setValue(a),this}},{key:"validate",value:function(a){if(!this.ready)throw new Error("JSON Editor not ready yet. Make sure the load method is complete");return arguments.length===1?this.validator.validate(a):this.validation_results}},{key:"destroy",value:function(){this.destroyed||this.ready&&(this.schema=null,this.options=null,this.root.destroy(),this.root=null,this.root_container=null,this.validator=null,this.validation_results=null,this.theme=null,this.iconlib=null,this.template=null,this.__data=null,this.ready=!1,this.element.innerHTML="",this.element.removeAttribute("data-theme"),this.destroyed=!0)}},{key:"on",value:function(a,l){return this.callbacks=this.callbacks||{},this.callbacks[a]=this.callbacks[a]||[],this.callbacks[a].push(l),this}},{key:"off",value:function(a,l){if(a&&l){this.callbacks=this.callbacks||{},this.callbacks[a]=this.callbacks[a]||[];for(var t=[],e=0;e<this.callbacks[a].length;e++)this.callbacks[a][e]!==l&&t.push(this.callbacks[a][e]);this.callbacks[a]=t}else a?(this.callbacks=this.callbacks||{},this.callbacks[a]=[]):this.callbacks={};return this}},{key:"trigger",value:function(a,l){if(this.callbacks&&this.callbacks[a]&&this.callbacks[a].length)for(var t=0;t<this.callbacks[a].length;t++)this.callbacks[a][t].apply(this,[l]);return this}},{key:"setOption",value:function(a,l){if(a!=="show_errors")throw new Error("Option ".concat(a," must be set during instantiation and cannot be changed later"));return this.options.show_errors=l,this.onChange(),this}},{key:"getEditorsRules",value:function(){return Object.values(c.defaults.editors).reduce(function(a,l){return l.rules?k(a,l.rules):a},{})}},{key:"getEditorClass",value:function(a){var l,t=this;if(a=this.expandSchema(a),c.defaults.resolvers.find(function(e){return(l=e(a,t))&&c.defaults.editors[l]}),!l)throw new Error("Unknown editor for schema ".concat(JSON.stringify(a)));if(!c.defaults.editors[l])throw new Error("Unknown editor ".concat(l));return c.defaults.editors[l]}},{key:"createEditor",value:function(a,l){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return new a(l=k({},a.options||{},l),c.defaults,t)}},{key:"onChange",value:function(){var a=this;if(this.ready&&!this.firing_change)return this.firing_change=!0,window.requestAnimationFrame(function(){a.firing_change=!1,a.ready&&(a.validation_results=a.validator.validate(a.root.getValue()),a.options.show_errors!=="never"?a.root.showValidationErrors(a.validation_results):a.root.showValidationErrors([]),a.trigger("change"))}),this}},{key:"compileTemplate",value:function(a){var l,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:c.defaults.template;if(typeof t=="string"){if(!c.defaults.templates[t])throw new Error("Unknown template engine ".concat(t));if(!(l=c.defaults.templates[t]()))throw new Error("Template engine ".concat(t," missing required library."))}else l=t;if(!l)throw new Error("No template engine set");if(!l.compile)throw new Error("Invalid template engine set");return l.compile(a)}},{key:"_data",value:function(a,l,t){if(arguments.length!==3)return a.hasAttribute("data-jsoneditor-".concat(l))?this.__data[a.getAttribute("data-jsoneditor-".concat(l))]:null;var e;a.hasAttribute("data-jsoneditor-".concat(l))?e=a.getAttribute("data-jsoneditor-".concat(l)):(e=this.uuid++,a.setAttribute("data-jsoneditor-".concat(l),e)),this.__data[e]=t}},{key:"registerEditor",value:function(a){return this.editors=this.editors||{},this.editors[a.path]=a,this}},{key:"unregisterEditor",value:function(a){return this.editors=this.editors||{},this.editors[a.path]=null,this}},{key:"getEditor",value:function(a){if(this.editors)return this.editors[a]}},{key:"watch",value:function(a,l){return this.watchlist=this.watchlist||{},this.watchlist[a]=this.watchlist[a]||[],this.watchlist[a].push(l),this}},{key:"unwatch",value:function(a,l){if(!this.watchlist||!this.watchlist[a])return this;if(!l)return this.watchlist[a]=null,this;for(var t=[],e=0;e<this.watchlist[a].length;e++)this.watchlist[a][e]!==l&&t.push(this.watchlist[a][e]);return this.watchlist[a]=t.length?t:null,this}},{key:"notifyWatchers",value:function(a){if(!this.watchlist||!this.watchlist[a])return this;for(var l=0;l<this.watchlist[a].length;l++)this.watchlist[a][l]()}},{key:"isEnabled",value:function(){return!this.root||this.root.isEnabled()}},{key:"enable",value:function(){this.root.enable()}},{key:"disable",value:function(){this.root.disable()}},{key:"setCopyClipboardContents",value:function(a){this.copyClipboard=a}},{key:"getCopyClipboardContents",value:function(){return this.copyClipboard}},{key:"addNewStyleRules",value:function(a,l){var t=document.querySelector("#theme-".concat(a));t||((t=document.createElement("style")).setAttribute("id","theme-".concat(a)),t.appendChild(document.createTextNode("")),document.head.appendChild(t));for(var e=t.sheet?t.sheet:t.styleSheet,o=this.element.nodeName.toLowerCase();e.cssRules.length>0;)e.deleteRule(0);Object.keys(l).forEach(function(u){var d=a==="default"?u:"".concat(o,'[data-theme="').concat(a,'"] ').concat(u);e.insertRule?e.insertRule(d+" {"+decodeURIComponent(l[u])+"}",0):e.addRule&&e.addRule(d,decodeURIComponent(l[u]),0)})}},{key:"addNewStyleRulesToShadowRoot",value:function(a,l,t){var e=this.element.nodeName.toLowerCase(),o="";Object.keys(l).forEach(function(x){var P=a==="default"?x:"".concat(e,'[data-theme="').concat(a,'"] ').concat(x);o+=P+" {"+decodeURIComponent(l[x])+`}
|
|
73
|
+
\v\f\r \u2028\u2029\uFEFF`},2222:(y,j,r)=>{var v=r(2109),g=r(7293),w=r(3157),k=r(111),O=r(7908),C=r(6244),S=r(7207),T=r(6135),A=r(5417),R=r(1194),I=r(5112),$=r(7392),M=I("isConcatSpreadable"),B=$>=51||!g(function(){var F=[];return F[M]=!1,F.concat()[0]!==F}),q=function(F){if(!k(F))return!1;var N=F[M];return N!==void 0?!!N:w(F)};v({target:"Array",proto:!0,arity:1,forced:!B||!R("concat")},{concat:function(F){var N,U,H,X,Y,K=O(this),tt=A(K,0),it=0;for(N=-1,H=arguments.length;N<H;N++)if(q(Y=N===-1?K:arguments[N]))for(X=C(Y),S(it+X),U=0;U<X;U++,it++)U in Y&&T(tt,it,Y[U]);else S(it+1),T(tt,it++,Y);return tt.length=it,tt}})},6541:(y,j,r)=>{var v=r(2109),g=r(2092).every;v({target:"Array",proto:!0,forced:!r(9341)("every")},{every:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},7327:(y,j,r)=>{var v=r(2109),g=r(2092).filter;v({target:"Array",proto:!0,forced:!r(1194)("filter")},{filter:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},9826:(y,j,r)=>{var v=r(2109),g=r(2092).find,w=r(1223),k="find",O=!0;k in[]&&Array(1)[k](function(){O=!1}),v({target:"Array",proto:!0,forced:O},{find:function(C){return g(this,C,arguments.length>1?arguments[1]:void 0)}}),w(k)},9554:(y,j,r)=>{var v=r(2109),g=r(8533);v({target:"Array",proto:!0,forced:[].forEach!=g},{forEach:g})},1038:(y,j,r)=>{var v=r(2109),g=r(8457);v({target:"Array",stat:!0,forced:!r(7072)(function(w){Array.from(w)})},{from:g})},6699:(y,j,r)=>{var v=r(2109),g=r(1318).includes,w=r(7293),k=r(1223);v({target:"Array",proto:!0,forced:w(function(){return!Array(1).includes()})},{includes:function(O){return g(this,O,arguments.length>1?arguments[1]:void 0)}}),k("includes")},2772:(y,j,r)=>{var v=r(2109),g=r(1470),w=r(1318).indexOf,k=r(9341),O=g([].indexOf),C=!!O&&1/O([1],1,-0)<0;v({target:"Array",proto:!0,forced:C||!k("indexOf")},{indexOf:function(S){var T=arguments.length>1?arguments[1]:void 0;return C?O(this,S,T)||0:w(this,S,T)}})},9753:(y,j,r)=>{r(2109)({target:"Array",stat:!0},{isArray:r(3157)})},6992:(y,j,r)=>{var v=r(5656),g=r(1223),w=r(7497),k=r(9909),O=r(3070).f,C=r(1656),S=r(6178),T=r(1913),A=r(9781),R="Array Iterator",I=k.set,$=k.getterFor(R);y.exports=C(Array,"Array",function(B,q){I(this,{type:R,target:v(B),index:0,kind:q})},function(){var B=$(this),q=B.target,F=B.kind,N=B.index++;return!q||N>=q.length?(B.target=void 0,S(void 0,!0)):S(F=="keys"?N:F=="values"?q[N]:[N,q[N]],!1)},"values");var M=w.Arguments=w.Array;if(g("keys"),g("values"),g("entries"),!T&&A&&M.name!=="values")try{O(M,"name",{value:"values"})}catch{}},9600:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(8361),k=r(5656),O=r(9341),C=g([].join);v({target:"Array",proto:!0,forced:w!=Object||!O("join",",")},{join:function(S){return C(k(this),S===void 0?",":S)}})},1249:(y,j,r)=>{var v=r(2109),g=r(2092).map;v({target:"Array",proto:!0,forced:!r(1194)("map")},{map:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},5827:(y,j,r)=>{var v=r(2109),g=r(3671).left,w=r(9341),k=r(7392);v({target:"Array",proto:!0,forced:!r(5268)&&k>79&&k<83||!w("reduce")},{reduce:function(O){var C=arguments.length;return g(this,O,C,C>1?arguments[1]:void 0)}})},5069:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(3157),k=g([].reverse),O=[1,2];v({target:"Array",proto:!0,forced:String(O)===String(O.reverse())},{reverse:function(){return w(this)&&(this.length=this.length),k(this)}})},7042:(y,j,r)=>{var v=r(2109),g=r(3157),w=r(4411),k=r(111),O=r(1400),C=r(6244),S=r(5656),T=r(6135),A=r(5112),R=r(1194),I=r(206),$=R("slice"),M=A("species"),B=Array,q=Math.max;v({target:"Array",proto:!0,forced:!$},{slice:function(F,N){var U,H,X,Y=S(this),K=C(Y),tt=O(F,K),it=O(N===void 0?K:N,K);if(g(Y)&&(U=Y.constructor,(w(U)&&(U===B||g(U.prototype))||k(U)&&(U=U[M])===null)&&(U=void 0),U===B||U===void 0))return I(Y,tt,it);for(H=new(U===void 0?B:U)(q(it-tt,0)),X=0;tt<it;tt++,X++)tt in Y&&T(H,X,Y[tt]);return H.length=X,H}})},5212:(y,j,r)=>{var v=r(2109),g=r(2092).some;v({target:"Array",proto:!0,forced:!r(9341)("some")},{some:function(w){return g(this,w,arguments.length>1?arguments[1]:void 0)}})},2707:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(9662),k=r(7908),O=r(6244),C=r(5117),S=r(1340),T=r(7293),A=r(4362),R=r(9341),I=r(8886),$=r(256),M=r(7392),B=r(8008),q=[],F=g(q.sort),N=g(q.push),U=T(function(){q.sort(void 0)}),H=T(function(){q.sort(null)}),X=R("sort"),Y=!T(function(){if(M)return M<70;if(!(I&&I>3)){if($)return!0;if(B)return B<603;var K,tt,it,st,yt="";for(K=65;K<76;K++){switch(tt=String.fromCharCode(K),K){case 66:case 69:case 70:case 72:it=3;break;case 68:case 71:it=4;break;default:it=2}for(st=0;st<47;st++)q.push({k:tt+st,v:it})}for(q.sort(function(ct,Et){return Et.v-ct.v}),st=0;st<q.length;st++)tt=q[st].k.charAt(0),yt.charAt(yt.length-1)!==tt&&(yt+=tt);return yt!=="DGBEFHACIJK"}});v({target:"Array",proto:!0,forced:U||!H||!X||!Y},{sort:function(K){K!==void 0&&w(K);var tt=k(this);if(Y)return K===void 0?F(tt):F(tt,K);var it,st,yt=[],ct=O(tt);for(st=0;st<ct;st++)st in tt&&N(yt,tt[st]);for(A(yt,function(Et){return function(At,Vt){return Vt===void 0?-1:At===void 0?1:Et!==void 0?+Et(At,Vt)||0:S(At)>S(Vt)?1:-1}}(K)),it=O(yt),st=0;st<it;)tt[st]=yt[st++];for(;st<ct;)C(tt,st++);return tt}})},561:(y,j,r)=>{var v=r(2109),g=r(7908),w=r(1400),k=r(9303),O=r(6244),C=r(3658),S=r(7207),T=r(5417),A=r(6135),R=r(5117),I=r(1194)("splice"),$=Math.max,M=Math.min;v({target:"Array",proto:!0,forced:!I},{splice:function(B,q){var F,N,U,H,X,Y,K=g(this),tt=O(K),it=w(B,tt),st=arguments.length;for(st===0?F=N=0:st===1?(F=0,N=tt-it):(F=st-2,N=M($(k(q),0),tt-it)),S(tt+F-N),U=T(K,N),H=0;H<N;H++)(X=it+H)in K&&A(U,H,K[X]);if(U.length=N,F<N){for(H=it;H<tt-N;H++)Y=H+F,(X=H+N)in K?K[Y]=K[X]:R(K,Y);for(H=tt;H>tt-N+F;H--)R(K,H-1)}else if(F>N)for(H=tt-N;H>it;H--)Y=H+F-1,(X=H+N-1)in K?K[Y]=K[X]:R(K,Y);for(H=0;H<F;H++)K[H+it]=arguments[H+2];return C(K,tt-N+F),U}})},3843:(y,j,r)=>{var v=r(2109),g=r(1702),w=Date,k=g(w.prototype.getTime);v({target:"Date",stat:!0},{now:function(){return k(new w)}})},8733:(y,j,r)=>{var v=r(2109),g=r(5573);v({target:"Date",proto:!0,forced:Date.prototype.toISOString!==g},{toISOString:g})},6078:(y,j,r)=>{var v=r(2597),g=r(8052),w=r(8709),k=r(5112)("toPrimitive"),O=Date.prototype;v(O,k)||g(O,k,w)},3710:(y,j,r)=>{var v=r(1702),g=r(8052),w=Date.prototype,k="Invalid Date",O="toString",C=v(w[O]),S=v(w.getTime);String(new Date(NaN))!=k&&g(w,O,function(){var T=S(this);return T==T?C(this):k})},4812:(y,j,r)=>{var v=r(2109),g=r(7065);v({target:"Function",proto:!0,forced:Function.bind!==g},{bind:g})},8309:(y,j,r)=>{var v=r(9781),g=r(6530).EXISTS,w=r(1702),k=r(7045),O=Function.prototype,C=w(O.toString),S=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,T=w(S.exec);v&&!g&&k(O,"name",{configurable:!0,get:function(){try{return T(S,C(this))[1]}catch{return""}}})},8862:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(2104),k=r(6916),O=r(1702),C=r(7293),S=r(614),T=r(2190),A=r(206),R=r(8044),I=r(6293),$=String,M=g("JSON","stringify"),B=O(/./.exec),q=O("".charAt),F=O("".charCodeAt),N=O("".replace),U=O(1 .toString),H=/[\uD800-\uDFFF]/g,X=/^[\uD800-\uDBFF]$/,Y=/^[\uDC00-\uDFFF]$/,K=!I||C(function(){var yt=g("Symbol")();return M([yt])!="[null]"||M({a:yt})!="{}"||M(Object(yt))!="{}"}),tt=C(function(){return M("\uDF06\uD834")!=='"\\udf06\\ud834"'||M("\uDEAD")!=='"\\udead"'}),it=function(yt,ct){var Et=A(arguments),At=R(ct);if(S(At)||yt!==void 0&&!T(yt))return Et[1]=function(Vt,lt){if(S(At)&&(lt=k(At,this,$(Vt),lt)),!T(lt))return lt},w(M,null,Et)},st=function(yt,ct,Et){var At=q(Et,ct-1),Vt=q(Et,ct+1);return B(X,yt)&&!B(Y,Vt)||B(Y,yt)&&!B(X,At)?"\\u"+U(F(yt,0),16):yt};M&&v({target:"JSON",stat:!0,arity:3,forced:K||tt},{stringify:function(yt,ct,Et){var At=A(arguments),Vt=w(K?it:M,null,At);return tt&&typeof Vt=="string"?N(Vt,H,st):Vt}})},3706:(y,j,r)=>{var v=r(7854);r(8003)(v.JSON,"JSON",!0)},2703:(y,j,r)=>{r(8003)(Math,"Math",!0)},9653:(y,j,r)=>{var v=r(2109),g=r(1913),w=r(9781),k=r(7854),O=r(857),C=r(1702),S=r(4705),T=r(2597),A=r(9587),R=r(7976),I=r(2190),$=r(7593),M=r(7293),B=r(8006).f,q=r(1236).f,F=r(3070).f,N=r(863),U=r(3111).trim,H="Number",X=k[H],Y=O[H],K=X.prototype,tt=k.TypeError,it=C("".slice),st=C("".charCodeAt),yt=function(wt){var _t=$(wt,"number");return typeof _t=="bigint"?_t:ct(_t)},ct=function(wt){var _t,Ut,Kt,fe,St,jt,It,qt,xt=$(wt,"number");if(I(xt))throw tt("Cannot convert a Symbol value to a number");if(typeof xt=="string"&&xt.length>2){if(xt=U(xt),(_t=st(xt,0))===43||_t===45){if((Ut=st(xt,2))===88||Ut===120)return NaN}else if(_t===48){switch(st(xt,1)){case 66:case 98:Kt=2,fe=49;break;case 79:case 111:Kt=8,fe=55;break;default:return+xt}for(jt=(St=it(xt,2)).length,It=0;It<jt;It++)if((qt=st(St,It))<48||qt>fe)return NaN;return parseInt(St,Kt)}}return+xt},Et=S(H,!X(" 0o1")||!X("0b1")||X("+0x1")),At=function(wt){return R(K,wt)&&M(function(){N(wt)})},Vt=function(wt){var _t=arguments.length<1?0:X(yt(wt));return At(this)?A(Object(_t),this,Vt):_t};Vt.prototype=K,Et&&!g&&(K.constructor=Vt),v({global:!0,constructor:!0,wrap:!0,forced:Et},{Number:Vt});var lt=function(wt,_t){for(var Ut,Kt=w?B(_t):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range".split(","),fe=0;Kt.length>fe;fe++)T(_t,Ut=Kt[fe])&&!T(wt,Ut)&&F(wt,Ut,q(_t,Ut))};g&&Y&<(O[H],Y),(Et||g)&<(O[H],X)},6977:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(9303),k=r(863),O=r(8415),C=r(7293),S=RangeError,T=String,A=Math.floor,R=g(O),I=g("".slice),$=g(1 .toFixed),M=function(N,U,H){return U===0?H:U%2==1?M(N,U-1,H*N):M(N*N,U/2,H)},B=function(N,U,H){for(var X=-1,Y=H;++X<6;)Y+=U*N[X],N[X]=Y%1e7,Y=A(Y/1e7)},q=function(N,U){for(var H=6,X=0;--H>=0;)X+=N[H],N[H]=A(X/U),X=X%U*1e7},F=function(N){for(var U=6,H="";--U>=0;)if(H!==""||U===0||N[U]!==0){var X=T(N[U]);H=H===""?X:H+R("0",7-X.length)+X}return H};v({target:"Number",proto:!0,forced:C(function(){return $(8e-5,3)!=="0.000"||$(.9,0)!=="1"||$(1.255,2)!=="1.25"||$(0xde0b6b3a7640080,0)!=="1000000000000000128"})||!C(function(){$({})})},{toFixed:function(N){var U,H,X,Y,K=k(this),tt=w(N),it=[0,0,0,0,0,0],st="",yt="0";if(tt<0||tt>20)throw S("Incorrect fraction digits");if(K!=K)return"NaN";if(K<=-1e21||K>=1e21)return T(K);if(K<0&&(st="-",K=-K),K>1e-21)if(H=(U=function(ct){for(var Et=0,At=ct;At>=4096;)Et+=12,At/=4096;for(;At>=2;)Et+=1,At/=2;return Et}(K*M(2,69,1))-69)<0?K*M(2,-U,1):K/M(2,U,1),H*=4503599627370496,(U=52-U)>0){for(B(it,0,H),X=tt;X>=7;)B(it,1e7,0),X-=7;for(B(it,M(10,X,1),0),X=U-1;X>=23;)q(it,8388608),X-=23;q(it,1<<X),B(it,1,1),q(it,2),yt=F(it)}else B(it,0,H),B(it,1<<-U,0),yt=F(it)+R("0",tt);return tt>0?st+((Y=yt.length)<=tt?"0."+R("0",tt-Y)+yt:I(yt,0,Y-tt)+"."+I(yt,Y-tt)):st+yt}})},9601:(y,j,r)=>{var v=r(2109),g=r(1574);v({target:"Object",stat:!0,arity:2,forced:Object.assign!==g},{assign:g})},8011:(y,j,r)=>{r(2109)({target:"Object",stat:!0,sham:!r(9781)},{create:r(30)})},3321:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(6048).f;v({target:"Object",stat:!0,forced:Object.defineProperties!==w,sham:!g},{defineProperties:w})},9070:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(3070).f;v({target:"Object",stat:!0,forced:Object.defineProperty!==w,sham:!g},{defineProperty:w})},9720:(y,j,r)=>{var v=r(2109),g=r(4699).entries;v({target:"Object",stat:!0},{entries:function(w){return g(w)}})},5003:(y,j,r)=>{var v=r(2109),g=r(7293),w=r(5656),k=r(1236).f,O=r(9781);v({target:"Object",stat:!0,forced:!O||g(function(){k(1)}),sham:!O},{getOwnPropertyDescriptor:function(C,S){return k(w(C),S)}})},9337:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(3887),k=r(5656),O=r(1236),C=r(6135);v({target:"Object",stat:!0,sham:!g},{getOwnPropertyDescriptors:function(S){for(var T,A,R=k(S),I=O.f,$=w(R),M={},B=0;$.length>B;)(A=I(R,T=$[B++]))!==void 0&&C(M,T,A);return M}})},9660:(y,j,r)=>{var v=r(2109),g=r(6293),w=r(7293),k=r(5181),O=r(7908);v({target:"Object",stat:!0,forced:!g||w(function(){k.f(1)})},{getOwnPropertySymbols:function(C){var S=k.f;return S?S(O(C)):[]}})},489:(y,j,r)=>{var v=r(2109),g=r(7293),w=r(7908),k=r(9518),O=r(8544);v({target:"Object",stat:!0,forced:g(function(){k(1)}),sham:!O},{getPrototypeOf:function(C){return k(w(C))}})},7941:(y,j,r)=>{var v=r(2109),g=r(7908),w=r(1956);v({target:"Object",stat:!0,forced:r(7293)(function(){w(1)})},{keys:function(k){return w(g(k))}})},8304:(y,j,r)=>{r(2109)({target:"Object",stat:!0},{setPrototypeOf:r(7674)})},1539:(y,j,r)=>{var v=r(1694),g=r(8052),w=r(288);v||g(Object.prototype,"toString",w,{unsafe:!0})},6833:(y,j,r)=>{var v=r(2109),g=r(4699).values;v({target:"Object",stat:!0},{values:function(w){return g(w)}})},4678:(y,j,r)=>{var v=r(2109),g=r(2814);v({global:!0,forced:parseFloat!=g},{parseFloat:g})},1058:(y,j,r)=>{var v=r(2109),g=r(3009);v({global:!0,forced:parseInt!=g},{parseInt:g})},821:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(9662),k=r(8523),O=r(2534),C=r(408);v({target:"Promise",stat:!0,forced:r(612)},{all:function(S){var T=this,A=k.f(T),R=A.resolve,I=A.reject,$=O(function(){var M=w(T.resolve),B=[],q=0,F=1;C(S,function(N){var U=q++,H=!1;F++,g(M,T,N).then(function(X){H||(H=!0,B[U]=X,--F||R(B))},I)}),--F||R(B)});return $.error&&I($.value),A.promise}})},4164:(y,j,r)=>{var v=r(2109),g=r(1913),w=r(3702).CONSTRUCTOR,k=r(2492),O=r(5005),C=r(614),S=r(8052),T=k&&k.prototype;if(v({target:"Promise",proto:!0,forced:w,real:!0},{catch:function(R){return this.then(void 0,R)}}),!g&&C(k)){var A=O("Promise").prototype.catch;T.catch!==A&&S(T,"catch",A,{unsafe:!0})}},3401:(y,j,r)=>{var v,g,w,k=r(2109),O=r(1913),C=r(5268),S=r(7854),T=r(6916),A=r(8052),R=r(7674),I=r(8003),$=r(6340),M=r(9662),B=r(614),q=r(111),F=r(5787),N=r(6707),U=r(261).set,H=r(5948),X=r(842),Y=r(2534),K=r(8572),tt=r(9909),it=r(2492),st=r(3702),yt=r(8523),ct="Promise",Et=st.CONSTRUCTOR,At=st.REJECTION_EVENT,Vt=st.SUBCLASSING,lt=tt.getterFor(ct),wt=tt.set,_t=it&&it.prototype,Ut=it,Kt=_t,fe=S.TypeError,St=S.document,jt=S.process,It=yt.f,qt=It,xt=!!(St&&St.createEvent&&S.dispatchEvent),lr="unhandledrejection",de=function(ot){var bt;return!(!q(ot)||!B(bt=ot.then))&&bt},Ne=function(ot,bt){var Mt,$t,Qt,Ze=bt.value,Ke=bt.state==1,xr=Ke?ot.ok:ot.fail,Qe=ot.resolve,fr=ot.reject,Se=ot.domain;try{xr?(Ke||(bt.rejection===2&&Le(bt),bt.rejection=1),xr===!0?Mt=Ze:(Se&&Se.enter(),Mt=xr(Ze),Se&&(Se.exit(),Qt=!0)),Mt===ot.promise?fr(fe("Promise-chain cycle")):($t=de(Mt))?T($t,Mt,Qe,fr):Qe(Mt)):fr(Ze)}catch(Dn){Se&&!Qt&&Se.exit(),fr(Dn)}},ge=function(ot,bt){ot.notified||(ot.notified=!0,H(function(){for(var Mt,$t=ot.reactions;Mt=$t.get();)Ne(Mt,ot);ot.notified=!1,bt&&!ot.rejection&&Ae(ot)}))},cr=function(ot,bt,Mt){var $t,Qt;xt?(($t=St.createEvent("Event")).promise=bt,$t.reason=Mt,$t.initEvent(ot,!1,!0),S.dispatchEvent($t)):$t={promise:bt,reason:Mt},!At&&(Qt=S["on"+ot])?Qt($t):ot===lr&&X("Unhandled promise rejection",Mt)},Ae=function(ot){T(U,S,function(){var bt,Mt=ot.facade,$t=ot.value;if(dr(ot)&&(bt=Y(function(){C?jt.emit("unhandledRejection",$t,Mt):cr(lr,Mt,$t)}),ot.rejection=C||dr(ot)?2:1,bt.error))throw bt.value})},dr=function(ot){return ot.rejection!==1&&!ot.parent},Le=function(ot){T(U,S,function(){var bt=ot.facade;C?jt.emit("rejectionHandled",bt):cr("rejectionhandled",bt,ot.value)})},We=function(ot,bt,Mt){return function($t){ot(bt,$t,Mt)}},Ce=function(ot,bt,Mt){ot.done||(ot.done=!0,Mt&&(ot=Mt),ot.value=bt,ot.state=2,ge(ot,!0))},pr=function(ot,bt,Mt){if(!ot.done){ot.done=!0,Mt&&(ot=Mt);try{if(ot.facade===bt)throw fe("Promise can't be resolved itself");var $t=de(bt);$t?H(function(){var Qt={done:!1};try{T($t,bt,We(pr,Qt,ot),We(Ce,Qt,ot))}catch(Ze){Ce(Qt,Ze,ot)}}):(ot.value=bt,ot.state=1,ge(ot,!1))}catch(Qt){Ce({done:!1},Qt,ot)}}};if(Et&&(Kt=(Ut=function(ot){F(this,Kt),M(ot),T(v,this);var bt=lt(this);try{ot(We(pr,bt),We(Ce,bt))}catch(Mt){Ce(bt,Mt)}}).prototype,(v=function(ot){wt(this,{type:ct,done:!1,notified:!1,parent:!1,reactions:new K,rejection:!1,state:0,value:void 0})}).prototype=A(Kt,"then",function(ot,bt){var Mt=lt(this),$t=It(N(this,Ut));return Mt.parent=!0,$t.ok=!B(ot)||ot,$t.fail=B(bt)&&bt,$t.domain=C?jt.domain:void 0,Mt.state==0?Mt.reactions.add($t):H(function(){Ne($t,Mt)}),$t.promise}),g=function(){var ot=new v,bt=lt(ot);this.promise=ot,this.resolve=We(pr,bt),this.reject=We(Ce,bt)},yt.f=It=function(ot){return ot===Ut||ot===void 0?new g(ot):qt(ot)},!O&&B(it)&&_t!==Object.prototype)){w=_t.then,Vt||A(_t,"then",function(ot,bt){var Mt=this;return new Ut(function($t,Qt){T(w,Mt,$t,Qt)}).then(ot,bt)},{unsafe:!0});try{delete _t.constructor}catch{}R&&R(_t,Kt)}k({global:!0,constructor:!0,wrap:!0,forced:Et},{Promise:Ut}),I(Ut,ct,!1,!0),$(ct)},8674:(y,j,r)=>{r(3401),r(821),r(4164),r(6027),r(683),r(6294)},6027:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(9662),k=r(8523),O=r(2534),C=r(408);v({target:"Promise",stat:!0,forced:r(612)},{race:function(S){var T=this,A=k.f(T),R=A.reject,I=O(function(){var $=w(T.resolve);C(S,function(M){g($,T,M).then(A.resolve,R)})});return I.error&&R(I.value),A.promise}})},683:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(8523);v({target:"Promise",stat:!0,forced:r(3702).CONSTRUCTOR},{reject:function(k){var O=w.f(this);return g(O.reject,void 0,k),O.promise}})},6294:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(1913),k=r(2492),O=r(3702).CONSTRUCTOR,C=r(9478),S=g("Promise"),T=w&&!O;v({target:"Promise",stat:!0,forced:w||O},{resolve:function(A){return C(T&&this===S?k:this,A)}})},2419:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(2104),k=r(7065),O=r(9483),C=r(9670),S=r(111),T=r(30),A=r(7293),R=g("Reflect","construct"),I=Object.prototype,$=[].push,M=A(function(){function F(){}return!(R(function(){},[],F)instanceof F)}),B=!A(function(){R(function(){})}),q=M||B;v({target:"Reflect",stat:!0,forced:q,sham:q},{construct:function(F,N){O(F),C(N);var U=arguments.length<3?F:O(arguments[2]);if(B&&!M)return R(F,N,U);if(F==U){switch(N.length){case 0:return new F;case 1:return new F(N[0]);case 2:return new F(N[0],N[1]);case 3:return new F(N[0],N[1],N[2]);case 4:return new F(N[0],N[1],N[2],N[3])}var H=[null];return w($,H,N),new(w(k,F,H))}var X=U.prototype,Y=T(S(X)?X:I),K=w(F,Y,N);return S(K)?K:Y}})},4819:(y,j,r)=>{var v=r(2109),g=r(6916),w=r(111),k=r(9670),O=r(5032),C=r(1236),S=r(9518);v({target:"Reflect",stat:!0},{get:function T(A,R){var I,$,M=arguments.length<3?A:arguments[2];return k(A)===M?A[R]:(I=C.f(A,R))?O(I)?I.value:I.get===void 0?void 0:g(I.get,M):w($=S(A))?T($,R,M):void 0}})},4603:(y,j,r)=>{var v=r(9781),g=r(7854),w=r(1702),k=r(4705),O=r(9587),C=r(8880),S=r(8006).f,T=r(7976),A=r(7850),R=r(1340),I=r(4706),$=r(2999),M=r(2626),B=r(8052),q=r(7293),F=r(2597),N=r(9909).enforce,U=r(6340),H=r(5112),X=r(9441),Y=r(7168),K=H("match"),tt=g.RegExp,it=tt.prototype,st=g.SyntaxError,yt=w(it.exec),ct=w("".charAt),Et=w("".replace),At=w("".indexOf),Vt=w("".slice),lt=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,wt=/a/g,_t=/a/g,Ut=new tt(wt)!==wt,Kt=$.MISSED_STICKY,fe=$.UNSUPPORTED_Y;if(k("RegExp",v&&(!Ut||Kt||X||Y||q(function(){return _t[K]=!1,tt(wt)!=wt||tt(_t)==_t||tt(wt,"i")!="/a/i"})))){for(var St=function(qt,xt){var lr,de,Ne,ge,cr,Ae,dr=T(it,this),Le=A(qt),We=xt===void 0,Ce=[],pr=qt;if(!dr&&Le&&We&&qt.constructor===St)return qt;if((Le||T(it,qt))&&(qt=qt.source,We&&(xt=I(pr))),qt=qt===void 0?"":R(qt),xt=xt===void 0?"":R(xt),pr=qt,X&&"dotAll"in wt&&(de=!!xt&&At(xt,"s")>-1)&&(xt=Et(xt,/s/g,"")),lr=xt,Kt&&"sticky"in wt&&(Ne=!!xt&&At(xt,"y")>-1)&&fe&&(xt=Et(xt,/y/g,"")),Y&&(ge=function(ot){for(var bt,Mt=ot.length,$t=0,Qt="",Ze=[],Ke={},xr=!1,Qe=!1,fr=0,Se="";$t<=Mt;$t++){if((bt=ct(ot,$t))==="\\")bt+=ct(ot,++$t);else if(bt==="]")xr=!1;else if(!xr)switch(!0){case bt==="[":xr=!0;break;case bt==="(":yt(lt,Vt(ot,$t+1))&&($t+=2,Qe=!0),Qt+=bt,fr++;continue;case(bt===">"&&Qe):if(Se===""||F(Ke,Se))throw new st("Invalid capture group name");Ke[Se]=!0,Ze[Ze.length]=[Se,fr],Qe=!1,Se="";continue}Qe?Se+=bt:Qt+=bt}return[Qt,Ze]}(qt),qt=ge[0],Ce=ge[1]),cr=O(tt(qt,xt),dr?this:it,St),(de||Ne||Ce.length)&&(Ae=N(cr),de&&(Ae.dotAll=!0,Ae.raw=St(function(ot){for(var bt,Mt=ot.length,$t=0,Qt="",Ze=!1;$t<=Mt;$t++)(bt=ct(ot,$t))!=="\\"?Ze||bt!=="."?(bt==="["?Ze=!0:bt==="]"&&(Ze=!1),Qt+=bt):Qt+="[\\s\\S]":Qt+=bt+ct(ot,++$t);return Qt}(qt),lr)),Ne&&(Ae.sticky=!0),Ce.length&&(Ae.groups=Ce)),qt!==pr)try{C(cr,"source",pr===""?"(?:)":pr)}catch{}return cr},jt=S(tt),It=0;jt.length>It;)M(St,tt,jt[It++]);it.constructor=St,St.prototype=it,B(g,"RegExp",St,{constructor:!0})}U("RegExp")},4916:(y,j,r)=>{var v=r(2109),g=r(2261);v({target:"RegExp",proto:!0,forced:/./.exec!==g},{exec:g})},9714:(y,j,r)=>{var v=r(6530).PROPER,g=r(8052),w=r(9670),k=r(1340),O=r(7293),C=r(4706),S="toString",T=RegExp.prototype[S],A=O(function(){return T.call({source:"a",flags:"b"})!="/a/b"}),R=v&&T.name!=S;(A||R)&&g(RegExp.prototype,S,function(){var I=w(this);return"/"+k(I.source)+"/"+k(C(I))},{unsafe:!0})},2023:(y,j,r)=>{var v=r(2109),g=r(1702),w=r(3929),k=r(4488),O=r(1340),C=r(4964),S=g("".indexOf);v({target:"String",proto:!0,forced:!C("includes")},{includes:function(T){return!!~S(O(k(this)),O(w(T)),arguments.length>1?arguments[1]:void 0)}})},8783:(y,j,r)=>{var v=r(8710).charAt,g=r(1340),w=r(9909),k=r(1656),O=r(6178),C="String Iterator",S=w.set,T=w.getterFor(C);k(String,"String",function(A){S(this,{type:C,string:g(A),index:0})},function(){var A,R=T(this),I=R.string,$=R.index;return $>=I.length?O(void 0,!0):(A=v(I,$),R.index+=A.length,O(A,!1))})},4723:(y,j,r)=>{var v=r(6916),g=r(7007),w=r(9670),k=r(8554),O=r(7466),C=r(1340),S=r(4488),T=r(8173),A=r(1530),R=r(7651);g("match",function(I,$,M){return[function(B){var q=S(this),F=k(B)?void 0:T(B,I);return F?v(F,B,q):new RegExp(B)[I](C(q))},function(B){var q=w(this),F=C(B),N=M($,q,F);if(N.done)return N.value;if(!q.global)return R(q,F);var U=q.unicode;q.lastIndex=0;for(var H,X=[],Y=0;(H=R(q,F))!==null;){var K=C(H[0]);X[Y]=K,K===""&&(q.lastIndex=A(F,O(q.lastIndex),U)),Y++}return Y===0?null:X}]})},5306:(y,j,r)=>{var v=r(2104),g=r(6916),w=r(1702),k=r(7007),O=r(7293),C=r(9670),S=r(614),T=r(8554),A=r(9303),R=r(7466),I=r(1340),$=r(4488),M=r(1530),B=r(8173),q=r(647),F=r(7651),N=r(5112)("replace"),U=Math.max,H=Math.min,X=w([].concat),Y=w([].push),K=w("".indexOf),tt=w("".slice),it="a".replace(/./,"$0")==="$0",st=!!/./[N]&&/./[N]("a","$0")==="";k("replace",function(yt,ct,Et){var At=st?"$":"$0";return[function(Vt,lt){var wt=$(this),_t=T(Vt)?void 0:B(Vt,N);return _t?g(_t,Vt,wt,lt):g(ct,I(wt),Vt,lt)},function(Vt,lt){var wt=C(this),_t=I(Vt);if(typeof lt=="string"&&K(lt,At)===-1&&K(lt,"$<")===-1){var Ut=Et(ct,wt,_t,lt);if(Ut.done)return Ut.value}var Kt=S(lt);Kt||(lt=I(lt));var fe=wt.global;if(fe){var St=wt.unicode;wt.lastIndex=0}for(var jt=[];;){var It=F(wt,_t);if(It===null||(Y(jt,It),!fe))break;I(It[0])===""&&(wt.lastIndex=M(_t,R(wt.lastIndex),St))}for(var qt,xt="",lr=0,de=0;de<jt.length;de++){for(var Ne=I((It=jt[de])[0]),ge=U(H(A(It.index),_t.length),0),cr=[],Ae=1;Ae<It.length;Ae++)Y(cr,(qt=It[Ae])===void 0?qt:String(qt));var dr=It.groups;if(Kt){var Le=X([Ne],cr,ge,_t);dr!==void 0&&Y(Le,dr);var We=I(v(lt,void 0,Le))}else We=q(Ne,_t,ge,cr,dr,lt);ge>=lr&&(xt+=tt(_t,lr,ge)+We,lr=ge+Ne.length)}return xt+tt(_t,lr)}]},!!O(function(){var yt=/./;return yt.exec=function(){var ct=[];return ct.groups={a:"7"},ct},"".replace(yt,"$<a>")!=="7"})||!it||st)},6755:(y,j,r)=>{var v,g=r(2109),w=r(1470),k=r(1236).f,O=r(7466),C=r(1340),S=r(3929),T=r(4488),A=r(4964),R=r(1913),I=w("".startsWith),$=w("".slice),M=Math.min,B=A("startsWith");g({target:"String",proto:!0,forced:!(!R&&!B&&(v=k(String.prototype,"startsWith"),v&&!v.writable)||B)},{startsWith:function(q){var F=C(T(this));S(q);var N=O(M(arguments.length>1?arguments[1]:void 0,F.length)),U=C(q);return I?I(F,U,N):$(F,N,N+U.length)===U}})},3210:(y,j,r)=>{var v=r(2109),g=r(3111).trim;v({target:"String",proto:!0,forced:r(6091)("trim")},{trim:function(){return g(this)}})},2443:(y,j,r)=>{r(6800)("asyncIterator")},4032:(y,j,r)=>{var v=r(2109),g=r(7854),w=r(6916),k=r(1702),O=r(1913),C=r(9781),S=r(6293),T=r(7293),A=r(2597),R=r(7976),I=r(9670),$=r(5656),M=r(4948),B=r(1340),q=r(9114),F=r(30),N=r(1956),U=r(8006),H=r(1156),X=r(5181),Y=r(1236),K=r(3070),tt=r(6048),it=r(5296),st=r(8052),yt=r(7045),ct=r(2309),Et=r(6200),At=r(3501),Vt=r(9711),lt=r(5112),wt=r(6061),_t=r(6800),Ut=r(6532),Kt=r(8003),fe=r(9909),St=r(2092).forEach,jt=Et("hidden"),It="Symbol",qt="prototype",xt=fe.set,lr=fe.getterFor(It),de=Object[qt],Ne=g.Symbol,ge=Ne&&Ne[qt],cr=g.TypeError,Ae=g.QObject,dr=Y.f,Le=K.f,We=H.f,Ce=it.f,pr=k([].push),ot=ct("symbols"),bt=ct("op-symbols"),Mt=ct("wks"),$t=!Ae||!Ae[qt]||!Ae[qt].findChild,Qt=C&&T(function(){return F(Le({},"a",{get:function(){return Le(this,"a",{value:7}).a}})).a!=7})?function(Dt,te,Xt){var ce=dr(de,te);ce&&delete de[te],Le(Dt,te,Xt),ce&&Dt!==de&&Le(de,te,ce)}:Le,Ze=function(Dt,te){var Xt=ot[Dt]=F(ge);return xt(Xt,{type:It,tag:Dt,description:te}),C||(Xt.description=te),Xt},Ke=function(Dt,te,Xt){Dt===de&&Ke(bt,te,Xt),I(Dt);var ce=M(te);return I(Xt),A(ot,ce)?(Xt.enumerable?(A(Dt,jt)&&Dt[jt][ce]&&(Dt[jt][ce]=!1),Xt=F(Xt,{enumerable:q(0,!1)})):(A(Dt,jt)||Le(Dt,jt,q(1,{})),Dt[jt][ce]=!0),Qt(Dt,ce,Xt)):Le(Dt,ce,Xt)},xr=function(Dt,te){I(Dt);var Xt=$(te),ce=N(Xt).concat(Dn(Xt));return St(ce,function(ze){C&&!w(Qe,Xt,ze)||Ke(Dt,ze,Xt[ze])}),Dt},Qe=function(Dt){var te=M(Dt),Xt=w(Ce,this,te);return!(this===de&&A(ot,te)&&!A(bt,te))&&(!(Xt||!A(this,te)||!A(ot,te)||A(this,jt)&&this[jt][te])||Xt)},fr=function(Dt,te){var Xt=$(Dt),ce=M(te);if(Xt!==de||!A(ot,ce)||A(bt,ce)){var ze=dr(Xt,ce);return!ze||!A(ot,ce)||A(Xt,jt)&&Xt[jt][ce]||(ze.enumerable=!0),ze}},Se=function(Dt){var te=We($(Dt)),Xt=[];return St(te,function(ce){A(ot,ce)||A(At,ce)||pr(Xt,ce)}),Xt},Dn=function(Dt){var te=Dt===de,Xt=We(te?bt:$(Dt)),ce=[];return St(Xt,function(ze){!A(ot,ze)||te&&!A(de,ze)||pr(ce,ot[ze])}),ce};S||(st(ge=(Ne=function(){if(R(ge,this))throw cr("Symbol is not a constructor");var Dt=arguments.length&&arguments[0]!==void 0?B(arguments[0]):void 0,te=Vt(Dt),Xt=function(ce){this===de&&w(Xt,bt,ce),A(this,jt)&&A(this[jt],te)&&(this[jt][te]=!1),Qt(this,te,q(1,ce))};return C&&$t&&Qt(de,te,{configurable:!0,set:Xt}),Ze(te,Dt)})[qt],"toString",function(){return lr(this).tag}),st(Ne,"withoutSetter",function(Dt){return Ze(Vt(Dt),Dt)}),it.f=Qe,K.f=Ke,tt.f=xr,Y.f=fr,U.f=H.f=Se,X.f=Dn,wt.f=function(Dt){return Ze(lt(Dt),Dt)},C&&(yt(ge,"description",{configurable:!0,get:function(){return lr(this).description}}),O||st(de,"propertyIsEnumerable",Qe,{unsafe:!0}))),v({global:!0,constructor:!0,wrap:!0,forced:!S,sham:!S},{Symbol:Ne}),St(N(Mt),function(Dt){_t(Dt)}),v({target:It,stat:!0,forced:!S},{useSetter:function(){$t=!0},useSimple:function(){$t=!1}}),v({target:"Object",stat:!0,forced:!S,sham:!C},{create:function(Dt,te){return te===void 0?F(Dt):xr(F(Dt),te)},defineProperty:Ke,defineProperties:xr,getOwnPropertyDescriptor:fr}),v({target:"Object",stat:!0,forced:!S},{getOwnPropertyNames:Se}),Ut(),Kt(Ne,It),At[jt]=!0},1817:(y,j,r)=>{var v=r(2109),g=r(9781),w=r(7854),k=r(1702),O=r(2597),C=r(614),S=r(7976),T=r(1340),A=r(7045),R=r(9920),I=w.Symbol,$=I&&I.prototype;if(g&&C(I)&&(!("description"in $)||I().description!==void 0)){var M={},B=function(){var Y=arguments.length<1||arguments[0]===void 0?void 0:T(arguments[0]),K=S($,this)?new I(Y):Y===void 0?I():I(Y);return Y===""&&(M[K]=!0),K};R(B,I),B.prototype=$,$.constructor=B;var q=String(I("test"))=="Symbol(test)",F=k($.valueOf),N=k($.toString),U=/^Symbol\((.*)\)[^)]+$/,H=k("".replace),X=k("".slice);A($,"description",{configurable:!0,get:function(){var Y=F(this);if(O(M,Y))return"";var K=N(Y),tt=q?X(K,7,-1):H(K,U,"$1");return tt===""?void 0:tt}}),v({global:!0,constructor:!0,forced:!0},{Symbol:B})}},763:(y,j,r)=>{var v=r(2109),g=r(5005),w=r(2597),k=r(1340),O=r(2309),C=r(2015),S=O("string-to-symbol-registry"),T=O("symbol-to-string-registry");v({target:"Symbol",stat:!0,forced:!C},{for:function(A){var R=k(A);if(w(S,R))return S[R];var I=g("Symbol")(R);return S[R]=I,T[I]=R,I}})},2165:(y,j,r)=>{r(6800)("iterator")},2526:(y,j,r)=>{r(4032),r(763),r(6620),r(8862),r(9660)},6620:(y,j,r)=>{var v=r(2109),g=r(2597),w=r(2190),k=r(6330),O=r(2309),C=r(2015),S=O("symbol-to-string-registry");v({target:"Symbol",stat:!0,forced:!C},{keyFor:function(T){if(!w(T))throw TypeError(k(T)+" is not a symbol");if(g(S,T))return S[T]}})},6649:(y,j,r)=>{var v=r(6800),g=r(6532);v("toPrimitive"),g()},3680:(y,j,r)=>{var v=r(5005),g=r(6800),w=r(8003);g("toStringTag"),w(v("Symbol"),"Symbol")},4747:(y,j,r)=>{var v=r(7854),g=r(8324),w=r(8509),k=r(8533),O=r(8880),C=function(T){if(T&&T.forEach!==k)try{O(T,"forEach",k)}catch{T.forEach=k}};for(var S in g)g[S]&&C(v[S]&&v[S].prototype);C(w)},3948:(y,j,r)=>{var v=r(7854),g=r(8324),w=r(8509),k=r(6992),O=r(8880),C=r(5112),S=C("iterator"),T=C("toStringTag"),A=k.values,R=function($,M){if($){if($[S]!==A)try{O($,S,A)}catch{$[S]=A}if($[T]||O($,T,M),g[M]){for(var B in k)if($[B]!==k[B])try{O($,B,k[B])}catch{$[B]=k[B]}}}};for(var I in g)R(v[I]&&v[I].prototype,I);R(w,"DOMTokenList")},6815:(y,j,r)=>{var v=r(2109),g=r(7854),w=r(7152)(g.setInterval,!0);v({global:!0,bind:!0,forced:g.setInterval!==w},{setInterval:w})},8417:(y,j,r)=>{var v=r(2109),g=r(7854),w=r(7152)(g.setTimeout,!0);v({global:!0,bind:!0,forced:g.setTimeout!==w},{setTimeout:w})},2564:(y,j,r)=>{r(6815),r(8417)}},b={};function _(y){var j=b[y];if(j!==void 0)return j.exports;var r=b[y]={exports:{}};return p[y](r,r.exports,_),r.exports}_.d=(y,j)=>{for(var r in j)_.o(j,r)&&!_.o(y,r)&&Object.defineProperty(y,r,{enumerable:!0,get:j[r]})},_.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch{if(typeof window=="object")return window}}(),_.o=(y,j)=>Object.prototype.hasOwnProperty.call(y,j),_.r=y=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(y,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(y,"__esModule",{value:!0})};var E={};return(()=>{_.r(E),_.d(E,{JSONEditor:()=>Tn}),_(3710),_(1539),_(9714),_(5827),_(6833),_(9826),_(9554),_(4747),_(7941),_(2222),_(9601),_(6649),_(6078),_(2526),_(1817),_(9653),_(9070),_(8674),_(2165),_(6992),_(8783),_(3948),_(2443),_(3680),_(3706),_(2703),_(8011),_(489),_(8309),_(8304),_(5069),_(7042),_(9753),_(1038),_(4916),_(9720),_(5306),_(4603),_(6699);var y=["actionscript","batchfile","c","c++","cpp","coffee","csharp","css","dart","django","ejs","erlang","golang","groovy","handlebars","haskell","haxe","html","ini","jade","java","javascript","json","less","lisp","lua","makefile","matlab","mysql","objectivec","pascal","perl","pgsql","php","python","prql","r","ruby","rust","sass","scala","scss","sh","smarty","sql","sqlserver","stylus","svg","typescript","twig","vbscript","xml","yaml","zig"],j=[function(c){return c.type==="string"&&c.format==="color"&&"colorpicker"},function(c){return c.type==="string"&&["ip","ipv4","ipv6","hostname"].includes(c.format)&&"ip"},function(c){return c.type==="string"&&y.includes(c.format)&&"ace"},function(c){return c.type==="string"&&["xhtml","bbcode"].includes(c.format)&&"sceditor"},function(c){return c.type==="string"&&c.format==="markdown"&&"simplemde"},function(c){return c.type==="string"&&c.format==="jodit"&&"jodit"},function(c){return c.type==="string"&&c.format==="autocomplete"&&"autocomplete"},function(c){return c.type==="string"&&c.format==="uuid"&&"uuid"},function(c){return c.format==="info"&&"info"},function(c){return c.format==="button"&&"button"},function(c){if((c.type==="integer"||c.type==="number")&&c.format==="stepper")return"stepper"},function(c){if(c.links){for(var n=0;n<c.links.length;n++)if(c.links[n].rel&&c.links[n].rel.toLowerCase()==="describedby")return"describedBy"}},function(c){return["string","integer"].includes(c.type)&&["starrating","rating"].includes(c.format)&&"starrating"},function(c){return["string","integer"].includes(c.type)&&["date","time","datetime-local"].includes(c.format)&&"datetime"},function(c){return(c.oneOf||c.anyOf)&&"multiple"},function(c){return c.if&&"multiple"},function(c,n){if(c.items&&(c.items=n.expandSchema(c.items)),c.type==="array"&&c.items&&!Array.isArray(c.items)&&["string","number","integer"].includes(c.items.type)){if(c.format==="choices")return"arrayChoices";if(c.uniqueItems){if(c.format==="selectize")return"arraySelectize";if(c.format==="select2")return"arraySelect2";if(c.items.enum)return"multiselect"}}},function(c){if(c.enum){if(c.type==="array"||c.type==="object")return"enum";if(c.type==="number"||c.type==="integer"||c.type==="string")return c.format==="radio"?"radio":c.format==="select2"?"select2":c.format==="selectize"?"selectize":c.format==="choices"?"choices":"select"}},function(c){if(c.enumSource)return c.format==="radio"?"radio":c.format==="select2"?"select2":c.format==="selectize"?"selectize":c.format==="choices"?"choices":"select"},function(c){return c.type==="array"&&c.format==="table"&&"table"},function(c){return c.type==="string"&&c.format==="url"&&window.FileReader&&c.options&&c.options.upload===Object(c.options.upload)&&"upload"},function(c){return c.type==="string"&&c.media&&c.media.binaryEncoding==="base64"&&"base64"},function(c){return c.type==="any"&&"multiple"},function(c){if(c.type==="boolean")return c.format==="checkbox"||c.options&&c.options.checkbox?"checkbox":c.format==="select2"?"select2":c.format==="selectize"?"selectize":c.format==="choices"?"choices":"select"},function(c){return c.type==="string"&&c.format==="signature"&&"signature"},function(c){return typeof c.type=="string"&&["string","number","integer","boolean","null","array","object"].includes(c.type)&&c.type},function(c){return!c.type&&c.properties&&"object"},function(c){return typeof c.type!="string"&&"multiple"},function(c){return typeof c.type=="string"&&"string"}];function r(c,n,f){return(n=function(i){var h=function(a,l){if(v(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(v(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i);return v(h)==="symbol"?h:String(h)}(n))in c?Object.defineProperty(c,n,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[n]=f,c}function v(c){return v=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},v(c)}function g(c){return!(c===null||v(c)!=="object"||c.nodeType||c===c.window||c.constructor&&!S(c.constructor.prototype,"isPrototypeOf"))}function w(c){return g(c)?k({},c):Array.isArray(c)?c.map(w):c}function k(c){for(var n=arguments.length,f=new Array(n>1?n-1:0),i=1;i<n;i++)f[i-1]=arguments[i];return f.forEach(function(h){h&&Object.keys(h).forEach(function(a){h[a]&&g(h[a])?(S(c,a)||(c[a]={}),k(c[a],h[a])):Array.isArray(h[a])?c[a]=w(h[a]):c[a]=h[a]})}),c}function O(c,n){var f=document.createEvent("HTMLEvents");f.initEvent(n,!0,!0),c.dispatchEvent(f)}function C(c){return c&&(c.toString()==="[object ShadowRoot]"?c:C(c.parentNode))}function S(c,n){return c&&Object.prototype.hasOwnProperty.call(c,n)}_(4812),_(2419),_(4819),_(5003),_(4723),_(2023),_(9600),_(6755),_(5212),_(2772),_(1249),_(4678),_(1058);var T=/^\s*(-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,A=/^\s*(-|\+)?(\d+)\s*$/;function R(){var c=new Date().getTime();return typeof performance<"u"&&typeof performance.now=="function"&&(c+=performance.now()),"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(n){var f=(c+16*Math.random())%16|0;return c=Math.floor(c/16),(n==="x"?f:3&f|8).toString(16)})}function I(c){return c&&v(c)==="object"&&!Array.isArray(c)}function $(c){for(var n=arguments.length,f=new Array(n>1?n-1:0),i=1;i<n;i++)f[i-1]=arguments[i];if(!f.length)return c;var h=f.shift();if(I(c)&&I(h))for(var a in h)I(h[a])?(c[a]||Object.assign(c,r({},a,{})),$(c[a],h[a])):Object.assign(c,r({},a,h[a]));return $.apply(void 0,[c].concat(f))}function M(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function B(c){return B=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},B(c)}function q(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(B(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(B(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),B(h)==="symbol"?h:String(h)),i)}var h}var F=function(){function c(i,h){(function(a,l){if(!(a instanceof l))throw new TypeError("Cannot call a class as a function")})(this,c),this.defaults=h,this.jsoneditor=i.jsoneditor,this.theme=this.jsoneditor.theme,this.template_engine=this.jsoneditor.template,this.iconlib=this.jsoneditor.iconlib,this.translate=this.jsoneditor.translate||this.defaults.translate,this.translateProperty=this.jsoneditor.translateProperty||this.defaults.translateProperty,this.original_schema=i.schema,this.schema=this.jsoneditor.expandSchema(this.original_schema),this.active=!0,this.options=k({},this.options||{},this.schema.options||{},i.schema.options||{},i),this.formname=this.jsoneditor.options.form_name_root||"root",i.path||this.schema.id||(this.schema.id=this.formname),this.path=i.path||this.formname,this.formname=i.formname||this.path.replace(/\.([^.]+)/g,"[$1]"),this.parent=i.parent,this.key=this.parent!==void 0?this.path.split(".").slice(this.parent.path.split(".").length).join("."):this.path,this.link_watchers=[],this.watchLoop=!1,i.container&&this.setContainer(i.container),this.registerDependencies()}var n,f;return n=c,f=[{key:"onChildEditorChange",value:function(i){this.onChange(!0)}},{key:"notify",value:function(){this.path&&this.jsoneditor.notifyWatchers(this.path)}},{key:"change",value:function(){this.parent?this.parent.onChildEditorChange(this):this.jsoneditor&&this.jsoneditor.onChange()}},{key:"onChange",value:function(i){this.notify(),this.watch_listener&&this.watch_listener(),i&&this.change()}},{key:"register",value:function(){this.jsoneditor.registerEditor(this),this.onChange()}},{key:"unregister",value:function(){this.jsoneditor&&this.jsoneditor.unregisterEditor(this)}},{key:"getNumColumns",value:function(){return 12}},{key:"isActive",value:function(){return this.active}},{key:"activate",value:function(){this.active=!0,this.optInCheckbox.checked=!0,this.enable(),this.change()}},{key:"deactivate",value:function(){this.isRequired()||(this.active=!1,this.optInCheckbox.checked=!1,this.disable(),this.change())}},{key:"registerDependencies",value:function(){var i=this;this.dependenciesFulfilled=!0;var h=this.options.dependencies;h&&Object.keys(h).forEach(function(a){var l;a.startsWith(i.jsoneditor.root.path)?l=a:((l=i.path.split("."))[l.length-1]=a,l=l.join(".")),i.jsoneditor.watch(l,function(){i.evaluateDependencies()})})}},{key:"evaluateDependencies",value:function(){var i=this,h=this.container||this.control;if(h&&this.jsoneditor!==null){var a=this.options.dependencies;if(a){var l=this.dependenciesFulfilled;this.dependenciesFulfilled=!0,Object.keys(a).forEach(function(e){var o;e.startsWith(i.jsoneditor.root.path)?o=e:((o=i.path.split("."))[o.length-1]=e,o=o.join("."));var u=a[e];i.checkDependency(o,u)}),this.dependenciesFulfilled!==l&&this.notify();var t=this.dependenciesFulfilled?"block":"none";this.options.hidden&&(t="none"),h.tagName==="TD"?Object.keys(h.childNodes).forEach(function(e){return h.childNodes[e].style.display=t}):h.style.display=t}}}},{key:"checkDependency",value:function(i,h){var a=this;if(this.path!==i&&this.jsoneditor!==null){var l=this.jsoneditor.getEditor(i),t=l?l.getValue():void 0;l&&l.dependenciesFulfilled?Array.isArray(h)?this.dependenciesFulfilled=h.some(function(e){if(JSON.stringify(t)===JSON.stringify(e))return!0}):B(h)==="object"?B(t)!=="object"?this.dependenciesFulfilled=h===t:Object.keys(h).some(function(e){return!!S(h,e)&&(S(t,e)&&h[e]===t[e]?void 0:(a.dependenciesFulfilled=!1,!0))}):typeof h=="string"||typeof h=="number"?this.dependenciesFulfilled=this.dependenciesFulfilled&&t===h:typeof h=="boolean"&&(this.dependenciesFulfilled=h?this.dependenciesFulfilled&&(t||t.length>0):this.dependenciesFulfilled&&(!t||t.length===0)):this.dependenciesFulfilled=!1}}},{key:"setContainer",value:function(i){this.container=i,this.setContainerAttributes(),this.schema.id&&this.container.setAttribute("data-schemaid",this.schema.id),this.schema.type&&typeof this.schema.type=="string"&&this.container.setAttribute("data-schematype",this.schema.type),this.container.setAttribute("data-schemapath",this.path)}},{key:"setOptInCheckbox",value:function(i){var h=this;this.optInCheckbox=document.createElement("input"),this.optInCheckbox.setAttribute("type","checkbox"),this.optInCheckbox.setAttribute("style","margin: 0 10px 0 0;"),this.optInCheckbox.classList.add("json-editor-opt-in"),this.optInCheckbox.addEventListener("click",function(){h.isActive()?h.deactivate():h.activate()});var a=this.jsoneditor.options.show_opt_in,l=this.parent.options.show_opt_in!==void 0,t=l&&this.parent.options.show_opt_in===!0,e=l&&this.parent.options.show_opt_in===!1;(t||!e&&a||!l&&a)&&this.parent&&this.parent.schema.type==="object"&&!this.isRequired()&&this.header&&(this.header.appendChild(this.optInCheckbox),this.header.insertBefore(this.optInCheckbox,this.header.firstChild))}},{key:"preBuild",value:function(){}},{key:"build",value:function(){}},{key:"postBuild",value:function(){this.setupWatchListeners(),this.addLinks(),this.register(),this.setValue(this.getDefault(),!0),this.updateHeaderText(),this.onWatchedFieldChange()}},{key:"setupWatchListeners",value:function(){var i=this;if(this.watched={},this.schema.vars&&(this.schema.watch=this.schema.vars),this.watched_values={},this.watch_listener=function(){i.refreshWatchedFieldValues()&&i.onWatchedFieldChange()},S(this.schema,"watch")){var h,a,l,t,e,o=this.container.getAttribute("data-schemapath");Object.keys(this.schema.watch).forEach(function(u){if(h=i.schema.watch[u],Array.isArray(h)){if(h.length<2)return;a=[h[0]].concat(h[1].split("."))}else a=h.split("."),i.theme.closest(i.container,'[data-schemaid="'.concat(a[0],'"]'))||a.unshift("#");if((l=a.shift())==="#"&&(l=i.jsoneditor.schema.id||i.jsoneditor.root.formname),!(t=i.theme.closest(i.container,'[data-schemaid="'.concat(l,'"]'))))throw new Error("Could not find ancestor node with id ".concat(l));e="".concat(t.getAttribute("data-schemapath"),".").concat(a.join(".")),o.startsWith(e)&&(i.watchLoop=!0),i.jsoneditor.watch(e,i.watch_listener),i.watched[u]=e})}this.schema.headerTemplate&&(this.header_template=this.jsoneditor.compileTemplate(this.schema.headerTemplate,this.template_engine))}},{key:"addLinks",value:function(){if(!this.no_link_holder&&(this.link_holder=this.theme.getLinksHolder(),this.description!==void 0?this.description.parentNode.insertBefore(this.link_holder,this.description):this.container.appendChild(this.link_holder),this.schema.links))for(var i=0;i<this.schema.links.length;i++)this.addLink(this.getLink(this.schema.links[i]))}},{key:"onMove",value:function(){}},{key:"getButton",value:function(i,h,a){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[],t="json-editor-btn-".concat(h);h=this.iconlib?this.iconlib.getIcon(h):null,i=this.translate(i,l),a=this.translate(a,l),!h&&a&&(i=a,a=null);var e=this.theme.getButton(i,h,a);return e.classList.add(t),e}},{key:"setButtonText",value:function(i,h,a,l){var t=arguments.length>4&&arguments[4]!==void 0?arguments[4]:[];return a=this.iconlib?this.iconlib.getIcon(a):null,h=this.translate(h,t),l=this.translate(l,t),!a&&l&&(h=l,l=null),this.theme.setButtonText(i,h,a,l)}},{key:"addLink",value:function(i){this.link_holder&&this.link_holder.appendChild(i)}},{key:"getLink",value:function(i){var h,a,l=(i.mediaType||"application/javascript").split("/")[0],t=this.jsoneditor.compileTemplate(i.href,this.template_engine),e=this.jsoneditor.compileTemplate(i.rel?i.rel:i.href,this.template_engine),o=null;if(i.download&&(o=i.download),o&&o!==!0&&(o=this.jsoneditor.compileTemplate(o,this.template_engine)),l==="image"){h=this.theme.getBlockLinkHolder(),(a=document.createElement("a")).setAttribute("target","_blank");var u=document.createElement("img");this.theme.createImageLink(h,a,u),this.link_watchers.push(function(x){var P=t(x),D=e(x);a.setAttribute("href",P),a.setAttribute("title",D||P),u.setAttribute("src",P)})}else if(["audio","video"].includes(l)){h=this.theme.getBlockLinkHolder(),(a=this.theme.getBlockLink()).setAttribute("target","_blank");var d=document.createElement(l);d.setAttribute("controls","controls"),this.theme.createMediaLink(h,a,d),this.link_watchers.push(function(x){var P=t(x),D=e(x);a.setAttribute("href",P),a.textContent=D||P,d.setAttribute("src",P)})}else a=h=this.theme.getBlockLink(),h.setAttribute("target","_blank"),h.textContent=i.rel,h.style.display="none",this.link_watchers.push(function(x){var P=t(x),D=e(x);P&&(h.style.display=""),h.setAttribute("href",P),h.textContent=D||P});return o&&a&&(o===!0?a.setAttribute("download",""):this.link_watchers.push(function(x){a.setAttribute("download",o(x))})),i.class&&a.classList.add(i.class),h}},{key:"refreshWatchedFieldValues",value:function(){var i=this;if(this.watched_values){var h={},a=!1;return this.watched&&Object.keys(this.watched).forEach(function(l){var t=i.jsoneditor.getEditor(i.watched[l]),e=t?t.getValue():null;i.watched_values[l]!==e&&(a=!0),h[l]=e}),h.self=this.getValue(),this.watched_values.self!==h.self&&(a=!0),this.watched_values=h,a}}},{key:"getWatchedFieldValues",value:function(){return this.watched_values}},{key:"updateHeaderText",value:function(){if(this.header){var i=this.getHeaderText();if(this.header.children.length){for(var h=0;h<this.header.childNodes.length;h++)if(this.header.childNodes[h].nodeType===3){this.header.childNodes[h].nodeValue=this.cleanText(i);break}}else window.DOMPurify?this.header.innerHTML=window.DOMPurify.sanitize(i):this.header.textContent=this.cleanText(i)}}},{key:"getHeaderText",value:function(i){return this.header_text?this.header_text:i?this.translateProperty(this.schema.title):this.getTitle()}},{key:"getPathDepth",value:function(){return this.path.split(".").length}},{key:"cleanText",value:function(i){var h=document.createElement("div");return h.innerHTML=i,h.textContent||h.innerText}},{key:"onWatchedFieldChange",value:function(){var i,h=this;if(this.header_template){i=k(this.getWatchedFieldValues(),{key:this.key,i:this.key,i0:1*this.key,i1:1*this.key+1,title:this.getTitle()}),Object.keys(this.editors).length&&(i.properties={},Object.keys(this.editors).forEach(function(t){var e=h.editors[t];if(e.schema&&e.schema.enum&&e.schema.options&&e.schema.options.enum_titles){var o=e.schema.enum.indexOf(e.value),u=e.options.enum_titles[o];i.properties[t]={enumTitle:u}}}));var a=this.header_template(i);a!==this.header_text&&(this.header_text=a,this.updateHeaderText(),this.notify())}if(this.link_watchers.length){i=this.getWatchedFieldValues();for(var l=0;l<this.link_watchers.length;l++)this.link_watchers[l](i)}}},{key:"setValue",value:function(i){this.value=i}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.value}},{key:"refreshValue",value:function(){}},{key:"getChildEditors",value:function(){return!1}},{key:"destroy",value:function(){var i=this;this.unregister(this),this.watched&&Object.values(this.watched).forEach(function(h){return i.jsoneditor.unwatch(h,i.watch_listener)}),this.watched=null,this.watched_values=null,this.watch_listener=null,this.header_text=null,this.header_template=null,this.value=null,this.container&&this.container.parentNode&&this.container.parentNode.removeChild(this.container),this.container=null,this.jsoneditor=null,this.schema=null,this.path=null,this.key=null,this.parent=null}},{key:"isDefaultRequired",value:function(){return this.isRequired()||!!this.jsoneditor.options.use_default_values}},{key:"getDefault",value:function(){if(this.schema.default!==void 0)return this.schema.default;if(this.schema.enum!==void 0)return this.schema.enum[0];var i=this.schema.type||this.schema.oneOf;if(i&&Array.isArray(i)&&(i=i[0]),i&&B(i)==="object"&&(i=i.type),i&&Array.isArray(i)&&(i=i[0]),typeof i=="string"){if(i==="number")return this.isDefaultRequired()?0:void 0;if(i==="boolean")return!this.isDefaultRequired()&&void 0;if(i==="integer")return this.isDefaultRequired()?0:void 0;if(i==="string")return this.isDefaultRequired()?"":void 0;if(i==="null")return null;if(i==="object")return{};if(i==="array")return[]}}},{key:"getTitle",value:function(){return this.translateProperty(this.schema.title||this.key)}},{key:"enable",value:function(){this.disabled=!1}},{key:"disable",value:function(){this.disabled=!0}},{key:"isEnabled",value:function(){return!this.disabled}},{key:"isRequired",value:function(){return typeof this.schema.required=="boolean"?this.schema.required:this.parent&&this.parent.schema&&Array.isArray(this.parent.schema.required)?this.parent.schema.required.includes(this.key):!!this.jsoneditor.options.required_by_default}},{key:"getDisplayText",value:function(i){var h=[],a={};i.forEach(function(t){t.title&&(a[t.title]=a[t.title]||0,a[t.title]++),t.description&&(a[t.description]=a[t.description]||0,a[t.description]++),t.format&&(a[t.format]=a[t.format]||0,a[t.format]++),t.type&&(a[t.type]=a[t.type]||0,a[t.type]++)}),i.forEach(function(t){var e;e=typeof t=="string"?t:t.title&&a[t.title]<=1?t.title:t.format&&a[t.format]<=1?t.format:t.type&&a[t.type]<=1?t.type:t.description&&a[t.description]<=1?t.description:t.title?t.title:t.format?t.format:t.type?t.type:t.description?t.description:JSON.stringify(t).length<500?JSON.stringify(t):"type",h.push(e)});var l={};return h.forEach(function(t,e){l[t]=l[t]||0,l[t]++,a[t]>1&&(h[e]="".concat(t," ").concat(l[t]))}),h}},{key:"getValidId",value:function(i){return(i=i===void 0?"":i.toString()).replace(/\s+/g,"-")}},{key:"setInputAttributes",value:function(i){var h=this;if(this.schema.options&&this.schema.options.inputAttributes){var a=this.schema.options.inputAttributes,l=["name","type"].concat(i);Object.keys(a).forEach(function(t){l.includes(t.toLowerCase())||h.input.setAttribute(t,a[t])})}}},{key:"setContainerAttributes",value:function(){var i=this;if(this.schema.options&&this.schema.options.containerAttributes){var h=this.schema.options.containerAttributes,a=["data-schemapath","data-schematype","data-schemaid"];Object.keys(h).forEach(function(l){a.includes(l.toLowerCase())||i.container.setAttribute(l,h[l])})}}},{key:"expandCallbacks",value:function(i,h){var a=this,l=this.defaults.callbacks[i];return Object.entries(h).forEach(function(t){var e,o,u=(o=2,function(P){if(Array.isArray(P))return P}(e=t)||function(P,D){var J=P==null?null:typeof Symbol<"u"&&P[Symbol.iterator]||P["@@iterator"];if(J!=null){var nt,ut,dt,kt,Ct=[],Nt=!0,ne=!1;try{if(dt=(J=J.call(P)).next,D===0){if(Object(J)!==J)return;Nt=!1}else for(;!(Nt=(nt=dt.call(J)).done)&&(Ct.push(nt.value),Ct.length!==D);Nt=!0);}catch(Re){ne=!0,ut=Re}finally{try{if(!Nt&&J.return!=null&&(kt=J.return(),Object(kt)!==kt))return}finally{if(ne)throw ut}}return Ct}}(e,o)||function(P,D){if(P){if(typeof P=="string")return M(P,D);var J=Object.prototype.toString.call(P).slice(8,-1);return J==="Object"&&P.constructor&&(J=P.constructor.name),J==="Map"||J==="Set"?Array.from(P):J==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(J)?M(P,D):void 0}}(e,o)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
74
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()),d=u[0],x=u[1];x===Object(x)?h[d]=a.expandCallbacks(i,x):typeof x=="string"&&B(l)==="object"&&typeof l[x]=="function"&&(h[d]=l[x].bind(null,a))}),h}},{key:"showValidationErrors",value:function(i){}}],f&&q(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function N(c){return N=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},N(c)}function U(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(N(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(N(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),N(h)==="symbol"?h:String(h)),i)}var h}function H(){return H=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Y(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},H.apply(this,arguments)}function X(c,n){return X=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},X(c,n)}function Y(c){return Y=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Y(c)}var K=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&X(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Y(i);if(h){var o=Y(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(N(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){H(Y(l.prototype),"register",this).call(this),this.input&&(this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname),this.input.setAttribute("aria-label",this.formname))}},{key:"unregister",value:function(){H(Y(l.prototype),"unregister",this).call(this),this.input&&(this.input.removeAttribute("name"),this.input.removeAttribute("aria-label"))}},{key:"setValue",value:function(t,e,o){if((!this.template||o)&&(this.shouldBeUnset()||t!=null?N(t)==="object"?t=JSON.stringify(t):this.shouldBeUnset()||typeof t=="string"||(t="".concat(t)):t="",t!==this.serialized)){var u=this.sanitize(t);if(this.input.value!==u){if(this.setValueToInputField(u),this.format==="range"){var d=this.control.querySelector("output");d&&(d.value=u)}var x=o||this.getValue()!==t;return this.refreshValue(),e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.adjust_height&&this.adjust_height(this.input),this.onChange(x),{changed:x,value:u}}}}},{key:"setValueToInputField",value:function(t){this.input.value=t===void 0?"":t}},{key:"getNumColumns",value:function(){var t,e=Math.ceil(Math.max(this.getTitle().length,this.schema.maxLength||0,this.schema.minLength||0)/5);return t=this.input_type==="textarea"?6:["text","email"].includes(this.input_type)?4:2,Math.min(12,Math.max(e,t))}},{key:"build",value:function(){var t=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.format=this.schema.format,!this.format&&this.schema.media&&this.schema.media.type&&(this.format=this.schema.media.type.replace(/(^(application|text)\/(x-)?(script\.)?)|(-source$)/g,"")),!this.format&&this.options.default_format&&(this.format=this.options.default_format),this.options.format&&(this.format=this.options.format),this.format)if(this.format==="textarea")this.input_type="textarea",this.input=this.theme.getTextareaInput();else if(this.format==="range"){this.input_type="range";var e=this.schema.minimum||0,o=this.schema.maximum||Math.max(100,e+1),u=1;this.schema.multipleOf&&(e%this.schema.multipleOf&&(e=Math.ceil(e/this.schema.multipleOf)*this.schema.multipleOf),o%this.schema.multipleOf&&(o=Math.floor(o/this.schema.multipleOf)*this.schema.multipleOf),u=this.schema.multipleOf),this.input=this.theme.getRangeInput(e,o,u)}else this.input_type="text",["button","checkbox","color","date","datetime-local","email","file","hidden","image","month","number","password","radio","reset","search","submit","tel","text","time","url","week"].includes(this.format)&&(this.input_type=this.format),this.input=this.theme.getFormInputField(this.input_type);else this.input_type="text",this.input=this.theme.getFormInputField(this.input_type);this.schema.maxLength!==void 0&&this.input.setAttribute("maxlength",this.schema.maxLength),this.schema.pattern!==void 0?this.input.setAttribute("pattern",this.schema.pattern):this.schema.minLength!==void 0&&this.input.setAttribute("pattern",".{".concat(this.schema.minLength,",}")),this.options.compact?this.container.classList.add("compact"):this.options.input_width&&(this.input.style.width=this.options.input_width),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&(this.disable(!0),this.input.setAttribute("readonly","true")),this.setInputAttributes(["maxlength","pattern","readonly","min","max","step"]),this.input.addEventListener("change",function(P){if(P.preventDefault(),P.stopPropagation(),t.schema.template)P.currentTarget.value=t.value;else{var D=P.currentTarget.value,J=t.sanitize(D);D!==J&&(P.currentTarget.value=J),t.is_dirty=!0,t.refreshValue(),t.onChange(!0)}}),this.options.input_height&&(this.input.style.height=this.options.input_height),this.options.expand_height&&(this.adjust_height=function(P){if(P){var D,J=P.offsetHeight;if(P.offsetHeight<P.scrollHeight)for(D=0;P.offsetHeight<P.scrollHeight+3&&!(D>100);)D++,J++,P.style.height="".concat(J,"px");else{for(D=0;P.offsetHeight>=P.scrollHeight+3&&!(D>100);)D++,J--,P.style.height="".concat(J,"px");P.style.height="".concat(J+1,"px")}}},this.input.addEventListener("keyup",function(P){t.adjust_height(P.currentTarget)}),this.input.addEventListener("change",function(P){t.adjust_height(P.currentTarget)}),this.adjust_height()),this.format&&this.input.setAttribute("data-schemaformat",this.format);var d=this.input;if(this.format==="range"&&(d=this.theme.getRangeControl(this.input,this.theme.getRangeOutput(this.input,this.schema.default||Math.max(this.schema.minimum||0,0)))),this.control=this.theme.getFormControl(this.label,d,this.description,this.infoButton,this.formname),this.container.appendChild(this.control),window.requestAnimationFrame(function(){t.input.parentNode&&t.afterInputReady(),t.adjust_height&&t.adjust_height(t.input),t.format==="range"&&(t.control.querySelector("output").value=t.input.value)}),this.schema.template){var x=this.expandCallbacks("template",{template:this.schema.template});typeof x.template=="function"?this.template=x.template:this.template=this.jsoneditor.compileTemplate(this.schema.template,this.template_engine),this.refreshValue()}else this.refreshValue()}},{key:"setupCleave",value:function(t){var e=this.expandCallbacks("cleave",k({},this.defaults.options.cleave||{},this.options.cleave||{}));N(e)==="object"&&Object.keys(e).length>0&&(this.cleave_instance=new window.Cleave(t,e))}},{key:"setupImask",value:function(t){var e=this.expandCallbacks("imask",k({},this.defaults.options.imask||{},this.options.imask||{}));N(e)==="object"&&Object.keys(e).length>0&&(this.imask_instance=window.IMask(t,this.ajustIMaskOptions(e)))}},{key:"ajustIMaskOptions",value:function(t){var e=this;return Object.keys(t).forEach(function(o){if(t[o]===Object(t[o]))t[o]=e.ajustIMaskOptions(t[o]);else if(o==="mask")if(t[o].substr(0,6)==="regex:"){var u=t[o].match(/^regex:\/(.*)\/([gimsuy]*)$/);if(u!==null)try{t[o]=new RegExp(u[1],u[2])}catch{}}else t[o]=e.getGlobalPropertyFromString(t[o])}),t}},{key:"getGlobalPropertyFromString",value:function(t){if(t.includes(".")){var e=t.split("."),o=e[0],u=e[1];if(window[o]!==void 0&&window[o][u]!==void 0)return window[o][u]}else if(window[t]!==void 0)return window[t];return t}},{key:"shouldBeUnset",value:function(){return!this.jsoneditor.options.use_default_values&&!this.is_dirty}},{key:"getValue",value:function(){var t=!(!this.input||!this.input.value);if(!this.shouldBeUnset()||t)return this.imask_instance&&this.dependenciesFulfilled&&this.options.imask.returnUnmasked?this.imask_instance.unmaskedValue:H(Y(l.prototype),"getValue",this).call(this)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,H(Y(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,H(Y(l.prototype),"disable",this).call(this)}},{key:"afterInputReady",value:function(){this.theme.afterInputReady(this.input),window.Cleave&&!this.cleave_instance?this.setupCleave(this.input):window.IMask&&!this.imask_instance&&this.setupImask(this.input)}},{key:"refreshValue",value:function(){this.input&&(this.value=this.input.value,typeof this.value=="string"||this.shouldBeUnset()||(this.value=""),this.serialized=this.value)}},{key:"destroy",value:function(){this.cleave_instance&&this.cleave_instance.destroy(),this.imask_instance&&this.imask_instance.destroy(),this.template=null,this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),H(Y(l.prototype),"destroy",this).call(this)}},{key:"sanitize",value:function(t){return t}},{key:"onWatchedFieldChange",value:function(){var t;this.template&&(t=this.getWatchedFieldValues(),this.setValue(this.template(t),!1,!0)),H(Y(l.prototype),"onWatchedFieldChange",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;if(this.jsoneditor.options.show_errors!=="always"){if(!this.is_dirty&&this.previous_error_setting===this.jsoneditor.options.show_errors)return}this.previous_error_setting=this.jsoneditor.options.show_errors;var o=t.reduce(function(u,d){return d.path===e.path&&u.push(d.message),u},[]);o.length?this.theme.addInputError(this.input,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input)}}])&&U(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function tt(c){return tt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},tt(c)}function it(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(tt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(tt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),tt(h)==="symbol"?h:String(h)),i)}var h}function st(){return st=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ct(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},st.apply(this,arguments)}function yt(c,n){return yt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},yt(c,n)}function ct(c){return ct=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ct(c)}var Et=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&yt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ct(i);if(h){var o=ct(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(tt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=st(ct(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.ace_editor_instance&&(this.ace_editor_instance.setValue(u.value),this.ace_editor_instance.session.getSelection().clearSelection(),this.ace_editor_instance.resize())}},{key:"build",value:function(){this.options.format="textarea",st(ct(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t,e=this;if(window.ace){var o=this.input_type;o!=="cpp"&&o!=="c++"&&o!=="c"||(o="c_cpp"),t=this.expandCallbacks("ace",k({},{selectionStyle:"text",minLines:30,maxLines:30},this.defaults.options.ace||{},this.options.ace||{},{mode:"ace/mode/".concat(o)})),this.ace_container=document.createElement("div"),this.ace_container.style.width="100%",this.ace_container.style.position="relative",this.input.parentNode.insertBefore(this.ace_container,this.input),this.input.style.display="none",this.ace_editor_instance=window.ace.edit(this.ace_container,t),this.ace_editor_instance.setValue(this.getValue()),this.ace_editor_instance.session.getSelection().clearSelection(),this.ace_editor_instance.resize(),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&this.ace_editor_instance.setReadOnly(!0),this.ace_editor_instance.on("change",function(){e.input.value=e.ace_editor_instance.getValue(),e.refreshValue(),e.is_dirty=!0,e.onChange(!0)}),this.theme.afterInputReady(this.input)}else st(ct(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.ace_editor_instance&&this.ace_editor_instance.setReadOnly(!1),st(ct(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.ace_editor_instance&&this.ace_editor_instance.setReadOnly(!0),st(ct(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.ace_editor_instance&&(this.ace_editor_instance.destroy(),this.ace_editor_instance=null),st(ct(l.prototype),"destroy",this).call(this)}}])&&it(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function At(c){return At=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},At(c)}function Vt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(At(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(At(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),At(h)==="symbol"?h:String(h)),i)}var h}function lt(){return lt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=_t(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},lt.apply(this,arguments)}function wt(c,n){return wt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},wt(c,n)}function _t(c){return _t=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},_t(c)}_(7327);var Ut=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&wt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=_t(i);if(h){var o=_t(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(At(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,f=[{key:"askConfirmation",value:function(){return this.jsoneditor.options.prompt_before_delete!==!0||window.confirm(this.translate("button_delete_node_warning"))!==!1}},{key:"getDefault",value:function(){return this.schema.default||[]}},{key:"register",value:function(){lt(_t(l.prototype),"register",this).call(this),this.rows&&this.rows.forEach(function(t){return t.register()})}},{key:"unregister",value:function(){lt(_t(l.prototype),"unregister",this).call(this),this.rows&&this.rows.forEach(function(t){return t.unregister()})}},{key:"getNumColumns",value:function(){var t=this.getItemInfo(0);return this.tabs_holder&&this.schema.format!=="tabs-top"?Math.max(Math.min(12,t.width+2),4):t.width}},{key:"enable",value:function(){var t=this;this.always_disabled||(this.setAvailability(this,!1),this.rows&&this.rows.forEach(function(e){e.enable(),t.setAvailability(e,!1)}),lt(_t(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){var e=this;t&&(this.always_disabled=!0),this.setAvailability(this,!0),this.rows&&this.rows.forEach(function(o){o.disable(t),e.setAvailability(o,!0)}),lt(_t(l.prototype),"disable",this).call(this)}},{key:"setAvailability",value:function(t,e){t.add_row_button&&(t.add_row_button.disabled=e),t.remove_all_rows_button&&(t.remove_all_rows_button.disabled=e),t.delete_last_row_button&&(t.delete_last_row_button.disabled=e),t.copy_button&&(t.copy_button.disabled=e),t.delete_button&&(t.delete_button.disabled=e),t.moveup_button&&(t.moveup_button.disabled=e),t.movedown_button&&(t.movedown_button.disabled=e)}},{key:"preBuild",value:function(){lt(_t(l.prototype),"preBuild",this).call(this),this.rows=[],this.row_cache=[],this.hide_delete_buttons=this.options.disable_array_delete||this.jsoneditor.options.disable_array_delete,this.hide_delete_all_rows_buttons=this.hide_delete_buttons||this.options.disable_array_delete_all_rows||this.jsoneditor.options.disable_array_delete_all_rows,this.hide_delete_last_row_buttons=this.hide_delete_buttons||this.options.disable_array_delete_last_row||this.jsoneditor.options.disable_array_delete_last_row,this.hide_move_buttons=this.options.disable_array_reorder||this.jsoneditor.options.disable_array_reorder,this.hide_add_button=this.options.disable_array_add||this.jsoneditor.options.disable_array_add,this.show_copy_button=this.options.enable_array_copy||this.jsoneditor.options.enable_array_copy,this.array_controls_top=this.options.array_controls_top||this.jsoneditor.options.array_controls_top}},{key:"build",value:function(){this.options.compact?(this.title=this.theme.getHeader("",this.getPathDepth()),this.container.appendChild(this.title),this.panel=this.theme.getIndentedPanel(),this.container.appendChild(this.panel),this.title_controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.title_controls),this.controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.controls),this.row_holder=document.createElement("div"),this.panel.appendChild(this.row_holder)):(this.header=document.createElement("label"),this.header.textContent=this.getTitle(),this.title=this.theme.getHeader(this.header,this.getPathDepth()),this.container.appendChild(this.title),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText)),this.container.appendChild(this.infoButton)),this.title_controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.title_controls),this.schema.description&&(this.description=this.theme.getDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.description)),this.error_holder=document.createElement("div"),this.container.appendChild(this.error_holder),this.schema.format==="tabs-top"?(this.controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.controls),this.tabs_holder=this.theme.getTopTabHolder(this.getValidId(this.getItemTitle())),this.container.appendChild(this.tabs_holder),this.row_holder=this.theme.getTopTabContentHolder(this.tabs_holder),this.active_tab=null):this.schema.format==="tabs"?(this.controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.controls),this.tabs_holder=this.theme.getTabHolder(this.getValidId(this.getItemTitle())),this.container.appendChild(this.tabs_holder),this.row_holder=this.theme.getTabContentHolder(this.tabs_holder),this.active_tab=null):(this.panel=this.theme.getIndentedPanel(),this.container.appendChild(this.panel),this.row_holder=document.createElement("div"),this.panel.appendChild(this.row_holder),this.controls=this.theme.getButtonHolder(),this.array_controls_top?this.title.appendChild(this.controls):this.panel.appendChild(this.controls))),this.addControls()}},{key:"onChildEditorChange",value:function(t){this.refreshValue(),this.refreshTabs(!0),lt(_t(l.prototype),"onChildEditorChange",this).call(this,t)}},{key:"getItemTitle",value:function(){if(!this.item_title)if(this.schema.items&&!Array.isArray(this.schema.items)){var t=this.jsoneditor.expandRefs(this.schema.items);this.item_title=this.translateProperty(t.title)||this.translate("default_array_item_title")}else this.item_title=this.translate("default_array_item_title");return this.cleanText(this.item_title)}},{key:"getItemSchema",value:function(t){return Array.isArray(this.schema.items)?t>=this.schema.items.length?this.schema.additionalItems===!0?{}:this.schema.additionalItems?k({},this.schema.additionalItems):void 0:k({},this.schema.items[t]):this.schema.items?k({},this.schema.items):{}}},{key:"getItemInfo",value:function(t){var e=this.getItemSchema(t);this.item_info=this.item_info||{};var o=JSON.stringify(e);return this.item_info[o]!==void 0||(e=this.jsoneditor.expandRefs(e),this.item_info[o]={title:this.translateProperty(e.title)||this.translate("default_array_item_title"),default:e.default,width:12,child_editors:e.properties||e.items}),this.item_info[o]}},{key:"getElementEditor",value:function(t){var e=this.getItemInfo(t),o=this.getItemSchema(t);(o=this.jsoneditor.expandRefs(o)).title="".concat(e.title," ").concat(t+1);var u,d=this.jsoneditor.getEditorClass(o);this.tabs_holder?(u=this.schema.format==="tabs-top"?this.theme.getTopTabContent():this.theme.getTabContent()).id="".concat(this.path,".").concat(t):u=e.child_editors?this.theme.getChildEditorHolder():this.theme.getIndentedPanel(),this.row_holder.appendChild(u);var x=this.jsoneditor.createEditor(d,{jsoneditor:this.jsoneditor,schema:o,container:u,path:"".concat(this.path,".").concat(t),parent:this,required:!0});return x.preBuild(),x.build(),x.postBuild(),x.title_controls||(x.array_controls=this.theme.getButtonHolder(),u.appendChild(x.array_controls)),x}},{key:"checkParent",value:function(t){return t&&t.parentNode}},{key:"destroy",value:function(){this.empty(!0),this.checkParent(this.title)&&this.title.parentNode.removeChild(this.title),this.checkParent(this.description)&&this.description.parentNode.removeChild(this.description),this.checkParent(this.row_holder)&&this.row_holder.parentNode.removeChild(this.row_holder),this.checkParent(this.controls)&&this.controls.parentNode.removeChild(this.controls),this.checkParent(this.panel)&&this.panel.parentNode.removeChild(this.panel),this.rows=this.row_cache=this.title=this.description=this.row_holder=this.panel=this.controls=null,lt(_t(l.prototype),"destroy",this).call(this)}},{key:"empty",value:function(t){var e=this;this.rows&&(this.rows.forEach(function(o,u){t&&(e.checkParent(o.tab)&&o.tab.parentNode.removeChild(o.tab),e.destroyRow(o,!0),e.row_cache[u]=null),e.rows[u]=null}),this.rows=[],t&&(this.row_cache=[]))}},{key:"destroyRow",value:function(t,e){var o=t.container;e?(t.destroy(),o.parentNode&&o.parentNode.removeChild(o),this.checkParent(t.tab)&&t.tab.parentNode.removeChild(t.tab)):(t.tab&&(t.tab.style.display="none"),o.style.display="none",t.unregister())}},{key:"getMax",value:function(){return Array.isArray(this.schema.items)&&this.schema.additionalItems===!1?Math.min(this.schema.items.length,this.schema.maxItems||1/0):this.schema.maxItems||1/0}},{key:"refreshTabs",value:function(t){var e=this;this.rows.forEach(function(o){o.tab&&(t?o.tab_text.textContent=o.getHeaderText():o.tab===e.active_tab?e.theme.markTabActive(o):e.theme.markTabInactive(o))})}},{key:"ensureArraySize",value:function(t){if(Array.isArray(t)||(t=[t]),this.schema.minItems)for(;t.length<this.schema.minItems;)t.push(this.getItemInfo(t.length).default);return this.getMax()&&t.length>this.getMax()&&(t=t.slice(0,this.getMax())),t}},{key:"setValue",value:function(){var t=this,e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],o=arguments.length>1?arguments[1]:void 0;if(e=this.ensureArraySize(e),JSON.stringify(e)!==this.serialized){e.forEach(function(P,D){if(t.rows[D])t.rows[D].setValue(P,o);else if(t.row_cache[D])t.rows[D]=t.row_cache[D],t.rows[D].setValue(P,o),t.rows[D].container.style.display="",t.rows[D].tab&&(t.rows[D].tab.style.display=""),t.rows[D].register(),t.jsoneditor.trigger("addRow",t.rows[D]);else{var J=t.addRow(P,o);t.jsoneditor.trigger("addRow",J)}});for(var u=e.length;u<this.rows.length;u++)this.destroyRow(this.rows[u]),this.rows[u]=null;this.rows=this.rows.slice(0,e.length);var d=this.rows.find(function(P){return P.tab===t.active_tab}),x=d!==void 0?d.tab:null;!x&&this.rows.length&&(x=this.rows[0].tab),this.active_tab=x,this.refreshValue(o),this.refreshTabs(!0),this.refreshTabs(),this.onChange()}}},{key:"setButtonState",value:function(t,e){switch(this.options.button_state_mode||this.jsoneditor.options.button_state_mode){case 1:default:t.style.display=e?"":"none";break;case 2:t.disabled=!e}}},{key:"setupButtons",value:function(t){var e=[];if(this.value.length)if(this.value.length===1){this.setButtonState(this.remove_all_rows_button,!1);var o=!(t||this.hide_delete_last_row_buttons);this.setButtonState(this.delete_last_row_button,o),e.push(o)}else{var u=!(t||this.hide_delete_last_row_buttons);this.setButtonState(this.delete_last_row_button,u),e.push(u);var d=!(t||this.hide_delete_all_rows_buttons);this.setButtonState(this.remove_all_rows_button,d),e.push(d)}else this.setButtonState(this.delete_last_row_button,!1),this.setButtonState(this.remove_all_rows_button,!1);var x=!(this.getMax()&&this.getMax()<=this.rows.length||this.hide_add_button);return this.setButtonState(this.add_row_button,x),e.push(x),e.some(function(P){return P})}},{key:"refreshValue",value:function(t){var e=this,o=this.value?this.value.length:0;if(this.value=this.rows.map(function(d){return d.getValue()}),o!==this.value.length||t){var u=this.schema.minItems&&this.schema.minItems>=this.rows.length;this.rows.forEach(function(d,x){if(d.movedown_button){var P=x!==e.rows.length-1;e.setButtonState(d.movedown_button,P)}d.delete_button&&e.setButtonState(d.delete_button,!u),e.value[x]=d.getValue()}),!this.collapsed&&this.setupButtons(u)?this.controls.style.display="inline-block":this.controls.style.display="none"}this.serialized=JSON.stringify(this.value)}},{key:"addRow",value:function(t,e){var o=this,u=this.rows.length;this.rows[u]=this.getElementEditor(u),this.row_cache[u]=this.rows[u],this.tabs_holder&&(this.rows[u].tab_text=document.createElement("span"),this.rows[u].tab_text.textContent=this.rows[u].getHeaderText(),this.schema.format==="tabs-top"?(this.rows[u].tab=this.theme.getTopTab(this.rows[u].tab_text,this.getValidId(this.rows[u].path)),this.theme.addTopTab(this.tabs_holder,this.rows[u].tab)):(this.rows[u].tab=this.theme.getTab(this.rows[u].tab_text,this.getValidId(this.rows[u].path)),this.theme.addTab(this.tabs_holder,this.rows[u].tab)),this.rows[u].tab.addEventListener("click",function(x){o.active_tab=o.rows[u].tab,o.refreshTabs(),x.preventDefault(),x.stopPropagation()}));var d=this.rows[u].title_controls||this.rows[u].array_controls;return this.hide_delete_buttons||(this.rows[u].delete_button=this._createDeleteButton(u,d)),this.show_copy_button&&(this.rows[u].copy_button=this._createCopyButton(u,d)),u&&!this.hide_move_buttons&&(this.rows[u].moveup_button=this._createMoveUpButton(u,d)),this.hide_move_buttons||(this.rows[u].movedown_button=this._createMoveDownButton(u,d)),t!==void 0&&this.rows[u].setValue(t,e),this.refreshTabs(),this.rows[u]}},{key:"_createDeleteButton",value:function(t,e){var o=this,u=this.getButton(this.getItemTitle(),"delete","button_delete_row_title",[this.getItemTitle()]);return u.classList.add("delete","json-editor-btntype-delete"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){if(d.preventDefault(),d.stopPropagation(),!o.askConfirmation())return!1;var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue().filter(function(nt,ut){return ut!==x}),D=null,J=o.rows[x].getValue();o.setValue(P),o.rows[x]?D=o.rows[x].tab:o.rows[x-1]&&(D=o.rows[x-1].tab),D&&(o.active_tab=D,o.refreshTabs()),o.onChange(!0),o.jsoneditor.trigger("deleteRow",J)}),e&&e.appendChild(u),u}},{key:"_createCopyButton",value:function(t,e){var o=this,u=this.getButton(this.getItemTitle(),"copy","button_copy_row_title",[this.getItemTitle()]),d=this.schema;return u.classList.add("copy","json-editor-btntype-copy"),u.setAttribute("data-i",t),u.addEventListener("click",function(x){var P=o.getValue();x.preventDefault(),x.stopPropagation();var D=1*x.currentTarget.getAttribute("data-i");P.forEach(function(J,nt){if(nt===D){if(d.items.type==="string"&&d.items.format==="uuid")J=R();else if(d.items.type==="object"&&d.items.properties)for(var ut=0,dt=Object.keys(J);ut<dt.length;ut++){var kt=dt[ut];d.items.properties&&d.items.properties[kt]&&d.items.properties[kt].format==="uuid"&&(J[kt]=R())}P.push(J)}}),o.setValue(P),o.refreshValue(!0),o.onChange(!0)}),e.appendChild(u),u}},{key:"_createMoveUpButton",value:function(t,e){var o=this,u=this.getButton("",this.schema.format==="tabs-top"?"moveleft":"moveup","button_move_up_title");return u.classList.add("moveup","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i");if(!(x<=0)){var P=o.getValue(),D=P[x-1];P[x-1]=P[x],P[x]=D,o.setValue(P),o.active_tab=o.rows[x-1].tab,o.refreshTabs(),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x-1])}}),e&&e.appendChild(u),u}},{key:"_createMoveDownButton",value:function(t,e){var o=this,u=this.getButton("",this.schema.format==="tabs-top"?"moveright":"movedown","button_move_down_title");return u.classList.add("movedown","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue();if(!(x>=P.length-1)){var D=P[x+1];P[x+1]=P[x],P[x]=D,o.setValue(P),o.active_tab=o.rows[x+1].tab,o.refreshTabs(),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x+1])}}),e&&e.appendChild(u),u}},{key:"addControls",value:function(){this.collapsed=!1,this.toggle_button=this._createToggleButton(),this.options.collapsed&&O(this.toggle_button,"click"),this.schema.options&&this.schema.options.disable_collapse!==void 0?this.schema.options.disable_collapse&&(this.toggle_button.style.display="none"):this.jsoneditor.options.disable_collapse&&(this.toggle_button.style.display="none"),this.add_row_button=this._createAddRowButton(),this.delete_last_row_button=this._createDeleteLastRowButton(),this.remove_all_rows_button=this._createRemoveAllRowsButton(),this.tabs&&(this.add_row_button.classList.add("je-array-control-btn"),this.delete_last_row_button.classList.add("je-array-control-btn"),this.remove_all_rows_button.classList.add("je-array-control-btn"))}},{key:"_createToggleButton",value:function(){var t=this,e=this.getButton("","collapse","button_collapse");e.classList.add("json-editor-btntype-toggle"),this.title.insertBefore(e,this.title.childNodes[0]);var o=this.row_holder.style.display,u=this.controls.style.display;return e.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation(),t.panel&&t.setButtonState(t.panel,t.collapsed),t.tabs_holder&&t.setButtonState(t.tabs_holder,t.collapsed),t.collapsed?(t.collapsed=!1,t.row_holder.style.display=o,t.controls.style.display=u,t.setButtonText(d.currentTarget,"","collapse","button_collapse")):(t.collapsed=!0,t.row_holder.style.display="none",t.controls.style.display="none",t.setButtonText(d.currentTarget,"","expand","button_expand"))}),e}},{key:"_createAddRowButton",value:function(){var t=this,e=this.getButton(this.getItemTitle(),"add","button_add_row_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-add"),e.addEventListener("click",function(o){o.preventDefault(),o.stopPropagation();var u,d=t.rows.length;t.row_cache[d]?(u=t.rows[d]=t.row_cache[d],t.rows[d].setValue(t.rows[d].getDefault(),!0),t.rows[d].container.style.display="",t.rows[d].tab&&(t.rows[d].tab.style.display=""),t.rows[d].register()):u=t.addRow(),t.active_tab=t.rows[d].tab,t.refreshTabs(),t.refreshValue(),t.onChange(!0),t.jsoneditor.trigger("addRow",u)}),this.controls.appendChild(e),e}},{key:"_createDeleteLastRowButton",value:function(){var t=this,e=this.getButton("button_delete_last","subtract","button_delete_last_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-deletelast"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue(),d=null,x=u.pop();t.setValue(u),t.rows[t.rows.length-1]&&(d=t.rows[t.rows.length-1].tab),d&&(t.active_tab=d,t.refreshTabs()),t.onChange(!0),t.jsoneditor.trigger("deleteRow",x)}),this.controls.appendChild(e),e}},{key:"_createRemoveAllRowsButton",value:function(){var t=this,e=this.getButton("button_delete_all","delete","button_delete_all_title");return e.classList.add("json-editor-btntype-deleteall"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue();t.empty(!0),t.setValue([]),t.onChange(!0),t.jsoneditor.trigger("deleteAllRows",u)}),this.controls.appendChild(e),e}},{key:"showValidationErrors",value:function(t){var e=this,o=[],u=[];t.forEach(function(d){d.path===e.path?o.push(d):u.push(d)}),this.error_holder&&(o.length?(this.error_holder.innerHTML="",this.error_holder.style.display="",o.forEach(function(d){e.error_holder.appendChild(e.theme.getErrorMessage(d.message))})):this.error_holder.style.display="none"),this.rows.forEach(function(d){return d.showValidationErrors(u)})}}],f&&Vt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Kt(c){return Kt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Kt(c)}function fe(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Kt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Kt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Kt(h)==="symbol"?h:String(h)),i)}var h}function St(){return St=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=It(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},St.apply(this,arguments)}function jt(c,n){return jt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},jt(c,n)}function It(c){return It=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},It(c)}Ut.rules={".json-editor-btntype-toggle":"margin:0%2010px%200%200",".je-array-control-btn":"width:100%25;text-align:left;margin-bottom:3px"};var qt=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&jt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=It(i);if(h){var o=It(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Kt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"onInputChange",value:function(){this.value=this.input.value,this.onChange(!0)}},{key:"register",value:function(){St(It(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){St(It(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"getNumColumns",value:function(){var t=this,e=this.getTitle().length;return Object.keys(this.select_values).forEach(function(o){return e=Math.max(e,"".concat(t.select_values[o]).length+4)}),Math.min(12,Math.max(e/7,2))}},{key:"preBuild",value:function(){var t;St(It(l.prototype),"preBuild",this).call(this),this.select_options={},this.select_values={},this.option_titles=[],this.option_keys=[],this.option_enum=[];var e=this.jsoneditor.expandRefs(this.schema.items||{}),o=e.enum||[],u=e.options&&e.options.enum||[],d=e.options&&e.options.enum_titles||[];for(t=0;t<o.length;t++)if(this.sanitize(o[t])===o[t]){var x=u[t]||{};"title"in x||(x.title="".concat(d[t]||o[t])),this.option_keys.push("".concat(o[t])),this.option_enum.push(x),this.select_values["".concat(o[t])]=o[t]}}},{key:"build",value:function(){var t,e=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),!this.schema.format&&this.option_keys.length<8||this.schema.format==="checkbox"){for(this.input_type="checkboxes",this.inputs={},this.controls={},t=0;t<this.option_keys.length;t++){var o=this.formname+t.toString();this.inputs[this.option_keys[t]]=this.theme.getCheckbox(),this.inputs[this.option_keys[t]].id=o,this.select_options[this.option_keys[t]]=this.inputs[this.option_keys[t]];var u=this.theme.getCheckboxLabel(this.option_enum[t].title);if(u.htmlFor=o,this.option_enum[t].infoText){var d=this.theme.getInfoButton(this.translateProperty(this.option_enum[t].infoText));u.appendChild(d)}this.controls["_"+this.option_keys[t]]=this.theme.getFormControl(u,this.inputs[this.option_keys[t]])}this.control=this.theme.getMultiCheckboxHolder(this.controls,this.label,this.description,this.infoButton),this.inputs.controlgroup=this.inputs.controls=this.control}else{for(this.input_type="select",this.input=this.theme.getSelectInput(this.option_keys,!0),this.theme.setSelectOptions(this.input,this.option_keys,this.option_enum.map(function(x){return x.title})),this.input.setAttribute("multiple","multiple"),this.input.size=Math.min(10,this.option_keys.length),t=0;t<this.option_keys.length;t++)this.select_options[this.option_keys[t]]=this.input.children[t];this.control=this.theme.getFormControl(this.label,this.input,this.description,this.infoButton)}(this.schema.readOnly||this.schema.readonly)&&this.disable(!0),this.container.appendChild(this.control),this.multiselectChangeHandler=function(x){var P=[];for(t=0;t<e.option_keys.length;t++)e.select_options[e.option_keys[t]]&&(e.select_options[e.option_keys[t]].selected||e.select_options[e.option_keys[t]].checked)&&P.push(e.select_values[e.option_keys[t]]);e.updateValue(P),e.onChange(!0)},this.control.addEventListener("change",this.multiselectChangeHandler,!1),window.requestAnimationFrame(function(){e.afterInputReady()})}},{key:"postBuild",value:function(){St(It(l.prototype),"postBuild",this).call(this)}},{key:"afterInputReady",value:function(){this.theme.afterInputReady(this.input||this.inputs)}},{key:"setValue",value:function(t,e){var o=this;t=t||[],Array.isArray(t)||(t=[t]),t=t.map(function(u){return"".concat(u)}),Object.keys(this.select_options).forEach(function(u){o.select_options[u][o.input_type==="select"?"selected":"checked"]=t.includes(u)}),this.updateValue(t),this.onChange(!0)}},{key:"removeValue",value:function(t){t=[].concat(t),this.setValue(this.getValue().filter(function(e){return!t.includes(e)}))}},{key:"addValue",value:function(t){this.setValue(this.getValue().concat(t))}},{key:"updateValue",value:function(t){for(var e=!1,o=[],u=0;u<t.length;u++)if(this.select_options["".concat(t[u])]){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}else e=!0;return this.value=o,e}},{key:"sanitize",value:function(t){return this.schema.items.type==="boolean"?!!t:this.schema.items.type==="number"?1*t||0:this.schema.items.type==="integer"?Math.floor(1*t||0):"".concat(t)}},{key:"enable",value:function(){var t=this;this.always_disabled||(this.input?this.input.disabled=!1:this.inputs&&Object.keys(this.inputs).forEach(function(e){return t.inputs[e].disabled=!1}),St(It(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){var e=this;t&&(this.always_disabled=!0),this.input?this.input.disabled=!0:this.inputs&&Object.keys(this.inputs).forEach(function(o){return e.inputs[o].disabled=!0}),St(It(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){St(It(l.prototype),"destroy",this).call(this)}},{key:"escapeRegExp",value:function(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}},{key:"showValidationErrors",value:function(t){var e=new RegExp("^".concat(this.escapeRegExp(this.path),"(\\.\\d+)?$")),o=t.reduce(function(u,d){return d.path.match(e)&&u.push(d.message),u},[]);o.length?this.theme.addInputError(this.input||this.inputs,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input||this.inputs)}}])&&fe(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function xt(c){return xt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},xt(c)}function lr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(xt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(xt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),xt(h)==="symbol"?h:String(h)),i)}var h}function de(){return de=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ge(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},de.apply(this,arguments)}function Ne(c,n){return Ne=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ne(c,n)}function ge(c){return ge=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ge(c)}var cr=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ne(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ge(i);if(h){var o=ge(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(xt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){this.choices_instance?(t=[].concat(t).map(function(o){return"".concat(o)}),this.updateValue(t),this.choices_instance.removeActiveItems(),this.choices_instance.setChoiceByValue(this.value),this.onChange(!0)):de(ge(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t=this;if(window.Choices&&!this.choices_instance){var e=this.expandCallbacks("choices",k({},{removeItems:!0,removeItemButton:!0},this.defaults.options.choices||{},this.options.choices||{},{addItems:!0,editItems:!1,duplicateItemsAllowed:!1}));this.newEnumAllowed=!1,this.choices_instance=new window.Choices(this.input,e),this.control.removeEventListener("change",this.multiselectChangeHandler),this.multiselectChangeHandler=function(o){var u=t.choices_instance.getValue(!0);t.updateValue(u),t.onChange(!0)},this.control.addEventListener("change",this.multiselectChangeHandler,!1)}de(ge(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){t=[].concat(t);for(var e=!1,o=[],u=0;u<t.length;u++)if(!(!this.select_values["".concat(t[u])]&&(e=!0,!this.newEnumAllowed||!this.addNewOption(t[u])))){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}return this.value=o,e}},{key:"addNewOption",value:function(t){return this.option_keys.push("".concat(t)),this.option_titles.push("".concat(t)),this.select_values["".concat(t)]=t,this.schema.items.enum.push(t),this.choices_instance.setChoices([{value:"".concat(t),label:"".concat(t)}],"value","label",!1),!0}},{key:"enable",value:function(){!this.always_disabled&&this.choices_instance&&this.choices_instance.enable(),de(ge(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.choices_instance&&this.choices_instance.disable(),de(ge(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.choices_instance&&(this.choices_instance.destroy(),this.choices_instance=null),de(ge(l.prototype),"destroy",this).call(this)}}])&&lr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(qt);function Ae(c){return Ae=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ae(c)}function dr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Ae(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Ae(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Ae(h)==="symbol"?h:String(h)),i)}var h}function Le(){return Le=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Ce(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Le.apply(this,arguments)}function We(c,n){return We=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},We(c,n)}function Ce(c){return Ce=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ce(c)}var pr=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&We(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Ce(i);if(h){var o=Ce(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Ae(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){this.select2_instance?(t=[].concat(t).map(function(o){return"".concat(o)}),this.updateValue(t),this.select2v4?this.select2_instance.val(this.value).change():this.select2_instance.select2("val",this.value),this.onChange(!0)):Le(Ce(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t,e=this;window.jQuery&&window.jQuery.fn&&window.jQuery.fn.select2&&!this.select2_instance&&(t=this.expandCallbacks("select2",k({},{tags:!0,width:"100%"},this.defaults.options.select2||{},this.options.select2||{})),this.newEnumAllowed=t.tags=!!t.tags&&this.schema.items&&this.schema.items.type==="string",this.select2_instance=window.jQuery(this.input).select2(t),this.select2v4=S(this.select2_instance.select2,"amd"),this.selectChangeHandler=function(){var o=e.select2v4?e.select2_instance.val():e.select2_instance.select2("val");e.updateValue(o),e.onChange(!0)},this.select2_instance.on("select2-blur",this.selectChangeHandler),this.select2_instance.on("change",this.selectChangeHandler)),Le(Ce(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){t=[].concat(t);for(var e=!1,o=[],u=0;u<t.length;u++)if(!(!this.select_values["".concat(t[u])]&&(e=!0,!this.newEnumAllowed||!this.addNewOption(t[u])))){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}return this.value=o,e}},{key:"addNewOption",value:function(t){this.option_keys.push("".concat(t)),this.option_titles.push("".concat(t)),this.select_values["".concat(t)]=t,this.schema.items.enum.push(t);var e=this.input.querySelector('option[value="'.concat(t,'"]'));return e?e.removeAttribute("data-select2-tag"):this.input.appendChild(new Option(t,t,!1,!1)).trigger("change"),!0}},{key:"enable",value:function(){!this.always_disabled&&this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!1):this.select2_instance.select2("enable",!0)),Le(Ce(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!0):this.select2_instance.select2("enable",!1)),Le(Ce(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){this.select2_instance&&(this.select2_instance.select2("destroy"),this.select2_instance=null),Le(Ce(l.prototype),"destroy",this).call(this)}}])&&dr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(qt);function ot(c){return ot=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ot(c)}function bt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ot(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ot(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ot(h)==="symbol"?h:String(h)),i)}var h}function Mt(){return Mt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Qt(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Mt.apply(this,arguments)}function $t(c,n){return $t=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},$t(c,n)}function Qt(c){return Qt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qt(c)}var Ze=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&$t(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Qt(i);if(h){var o=Qt(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(ot(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){this.selectize_instance?(t=[].concat(t).map(function(o){return"".concat(o)}),this.updateValue(t),this.selectize_instance.setValue(this.value),this.onChange(!0)):Mt(Qt(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t,e=this;window.jQuery&&window.jQuery.fn&&window.jQuery.fn.selectize&&!this.selectize_instance&&(t=this.expandCallbacks("selectize",k({},{plugins:["remove_button"],delimiter:!1,createOnBlur:!0,create:!0},this.defaults.options.selectize||{},this.options.selectize||{})),this.newEnumAllowed=t.create=!!t.create&&this.schema.items&&this.schema.items.type==="string",this.selectize_instance=window.jQuery(this.input).selectize(t)[0].selectize,this.control.removeEventListener("change",this.multiselectChangeHandler),this.multiselectChangeHandler=function(o){var u=e.selectize_instance.getValue();e.updateValue(u),e.onChange(!0)},this.selectize_instance.on("change",this.multiselectChangeHandler)),Mt(Qt(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){t=[].concat(t);for(var e=!1,o=[],u=0;u<t.length;u++)if(!(!this.select_values["".concat(t[u])]&&(e=!0,!this.newEnumAllowed||!this.addNewOption(t[u])))){var d=this.sanitize(this.select_values[t[u]]);o.push(d),d!==t[u]&&(e=!0)}return this.value=o,e}},{key:"addNewOption",value:function(t){return this.option_keys.push("".concat(t)),this.option_titles.push("".concat(t)),this.select_values["".concat(t)]=t,this.selectize_instance.addOption({text:t,value:t}),!0}},{key:"enable",value:function(){!this.always_disabled&&this.selectize_instance&&this.selectize_instance.unlock(),Mt(Qt(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.selectize_instance&&this.selectize_instance.lock(),Mt(Qt(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.selectize_instance&&(this.selectize_instance.destroy(),this.selectize_instance=null),Mt(Qt(l.prototype),"destroy",this).call(this)}}])&&bt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(qt);function Ke(c){return Ke=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ke(c)}function xr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Ke(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Ke(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Ke(h)==="symbol"?h:String(h)),i)}var h}function Qe(){return Qe=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Se(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Qe.apply(this,arguments)}function fr(c,n){return fr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},fr(c,n)}function Se(c){return Se=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Se(c)}var Dn=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&fr(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Se(i);if(h){var o=Se(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Ke(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"postBuild",value:function(){window.Autocomplete&&(this.autocomplete_wrapper=document.createElement("div"),this.input.parentNode.insertBefore(this.autocomplete_wrapper,this.input.nextSibling),this.autocomplete_wrapper.appendChild(this.input),this.autocomplete_dropdown=document.createElement("ul"),this.input.parentNode.insertBefore(this.autocomplete_dropdown,this.input.nextSibling)),Qe(Se(l.prototype),"postBuild",this).call(this)}},{key:"afterInputReady",value:function(){var t,e=this;window.Autocomplete&&!this.autocomplete_instance&&(t=this.expandCallbacks("autocomplete",k({},{search:function(o){return console.log('No "search" callback defined for autocomplete in property "'.concat(o.key,'"')),[]},onSubmit:function(){e.input.blur()},baseClass:"autocomplete"},this.defaults.options.autocomplete||{},this.options.autocomplete||{})),this.autocomplete_wrapper.classList.add(t.baseClass),this.autocomplete_dropdown.classList.add("".concat(t.baseClass,"-result-list")),this.autocomplete_instance=new window.Autocomplete(this.autocomplete_wrapper,t)),Qe(Se(l.prototype),"afterInputReady",this).call(this)}},{key:"destroy",value:function(){this.autocomplete_instance&&(this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.autocomplete_dropdown&&this.autocomplete_dropdown.parentNode&&this.autocomplete_dropdown.parentNode.removeChild(this.autocomplete_dropdown),this.autocomplete_wrapper&&this.autocomplete_wrapper.parentNode&&this.autocomplete_wrapper.parentNode.removeChild(this.autocomplete_wrapper),this.autocomplete_instance=null),Qe(Se(l.prototype),"destroy",this).call(this)}}])&&xr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function Dt(c){return Dt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Dt(c)}function te(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Dt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Dt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Dt(h)==="symbol"?h:String(h)),i)}var h}function Xt(){return Xt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ze(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Xt.apply(this,arguments)}function ce(c,n){return ce=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ce(c,n)}function ze(c){return ze=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ze(c)}_(561);var Vi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ce(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ze(i);if(h){var o=ze(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Dt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 4}},{key:"setFileReaderListener",value:function(t){var e=this;t.addEventListener("load",function(o){if(e.count===e.current_item_index)e.value[e.count][e.key]=o.target.result;else{var u={};for(var d in e.parent.schema.properties)u[d]="";u[e.key]=o.target.result,e.value.splice(e.count,0,u)}e.count+=1,e.count===e.total+e.current_item_index&&e.arrayEditor.setValue(e.value)})}},{key:"build",value:function(){var t=this;if(this.options.compact||(this.title=this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.input=this.theme.getFormInputField("hidden"),this.container.appendChild(this.input),!this.schema.readOnly&&!this.schema.readonly){if(!window.FileReader)throw new Error("FileReader required for base64 editor");this.uploader=this.theme.getFormInputField("file"),this.uploader.style.display="none",this.schema.options&&this.schema.options.multiple&&this.schema.options.multiple===!0&&this.parent&&this.parent.schema.type==="object"&&this.parent.parent&&this.parent.parent.schema.type==="array"&&this.uploader.setAttribute("multiple",""),this.uploader.addEventListener("change",function(o){if(o.preventDefault(),o.stopPropagation(),o.currentTarget.files&&o.currentTarget.files.length)if(o.currentTarget.files.length>1&&t.schema.options&&t.schema.options.multiple&&t.schema.options.multiple===!0&&t.parent&&t.parent.schema.type==="object"&&t.parent.parent&&t.parent.parent.schema.type==="array"){t.arrayEditor=t.jsoneditor.getEditor(t.parent.parent.path),t.value=t.arrayEditor.getValue(),t.total=o.currentTarget.files.length,t.current_item_index=parseInt(t.parent.key),t.count=t.current_item_index;for(var u=0;u<t.total;u++){var d=new FileReader;t.setFileReaderListener(d),d.readAsDataURL(o.currentTarget.files[u])}}else{var x=new FileReader;x.onload=function(P){t.value=P.target.result,t.refreshPreview(),t.onChange(!0),x=null},x.readAsDataURL(o.currentTarget.files[0])}})}this.preview=this.theme.getFormInputDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.preview),this.control=this.theme.getFormControl(this.label,this.uploader||this.input,this.preview,this.infoButton),this.container.appendChild(this.control);var e=this.getButton("button_upload","upload","button_upload");e.addEventListener("click",function(){t.uploader.click()}),this.control.appendChild(e)}},{key:"refreshPreview",value:function(){if(this.last_preview!==this.value&&(this.last_preview=this.value,this.preview.innerHTML="",this.value)){var t=this.value.match(/^data:([^;,]+)[;,]/);if(t&&(t=t[1]),t){if(this.preview.innerHTML="<strong>Type:</strong> ".concat(t,", <strong>Size:</strong> ").concat(Math.floor((this.value.length-this.value.split(",")[0].length-1)/1.33333)," bytes"),t.substr(0,5)==="image"){this.preview.innerHTML+="<br>";var e=document.createElement("img");e.style.maxWidth="100%",e.style.maxHeight="100px",e.src=this.value,this.preview.appendChild(e)}}else this.preview.innerHTML="<em>Invalid data URI</em>"}}},{key:"enable",value:function(){this.always_disabled||(this.uploader&&(this.uploader.disabled=!1),Xt(ze(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.uploader&&(this.uploader.disabled=!0),Xt(ze(l.prototype),"disable",this).call(this)}},{key:"setValue",value:function(t){this.value!==t&&(this.schema.readOnly&&this.schema.enum&&!this.schema.enum.includes(t)?this.value=this.schema.enum[0]:this.value=t,this.input.value=this.value,this.refreshPreview(),this.onChange())}},{key:"destroy",value:function(){this.preview&&this.preview.parentNode&&this.preview.parentNode.removeChild(this.preview),this.title&&this.title.parentNode&&this.title.parentNode.removeChild(this.title),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.uploader&&this.uploader.parentNode&&this.uploader.parentNode.removeChild(this.uploader),Xt(ze(l.prototype),"destroy",this).call(this)}}])&&te(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Nn(c){return Nn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Nn(c)}function us(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Nn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Nn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Nn(h)==="symbol"?h:String(h)),i)}var h}function ui(){return ui=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Zr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},ui.apply(this,arguments)}function on(c,n){return on=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},on(c,n)}function Zr(c){return Zr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Zr(c)}var hs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&on(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Zr(i);if(h){var o=Zr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Nn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t,e){var o;return function(u,d){if(!(u instanceof d))throw new TypeError("Cannot call a class as a function")}(this,l),(o=a.call(this,t,e)).active=!1,o.parent&&o.parent.schema&&(Array.isArray(o.parent.schema.required)?o.parent.schema.required.includes(o.key)||o.parent.schema.required.push(o.key):o.parent.schema.required=[o.key]),o}return n=l,(f=[{key:"build",value:function(){var t=this;this.options.compact=!0;var e=this.expandCallbacks("button",k({},{icon:"",validated:!1,align:"left",action:function(u,d){window.alert('No button action defined for "'.concat(u.path,'"'))}},this.defaults.options.button||{},this.options.button||{})),o=this.translateProperty(e.text||this.schema.title)||this.key;this.input=this.getButton(o,e.icon,o),typeof e.action!="function"?window.alert('No button action defined for "'.concat(this.path,'"')):this.input.addEventListener("click",e.action,!1),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&(this.disable(!0),this.input.setAttribute("readonly","true")),this.setInputAttributes(["readonly"]),this.control=this.theme.getFormButtonHolder(e.align),this.control.appendChild(this.input),this.container.appendChild(this.control),this.changeHandler=function(){t.jsoneditor.validate(t.jsoneditor.getValue()).length>0?t.disable():t.enable()},e.validated&&this.jsoneditor.on("change",this.changeHandler)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,ui(Zr(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,ui(Zr(l.prototype),"disable",this).call(this)}},{key:"getNumColumns",value:function(){return 2}},{key:"activate",value:function(){this.active=!1,this.enable()}},{key:"deactivate",value:function(){this.isRequired()||(this.active=!1,this.disable())}},{key:"destroy",value:function(){this.jsoneditor.off("change",this.changeHandler),this.changeHandler=null,ui(Zr(l.prototype),"destroy",this).call(this)}}])&&us(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function $n(c){return $n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},$n(c)}function ds(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if($n(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if($n(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),$n(h)==="symbol"?h:String(h)),i)}var h}function kn(){return kn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Mr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},kn.apply(this,arguments)}function zi(c,n){return zi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},zi(c,n)}function Mr(c){return Mr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Mr(c)}var ps=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&zi(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Mr(i);if(h){var o=Mr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&($n(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){t=!!t;var o=this.getValue()!==t;this.value=t,this.input.checked=this.value,this.onChange(o)}},{key:"register",value:function(){kn(Mr(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){kn(Mr(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"getNumColumns",value:function(){return Math.min(12,Math.max(this.getTitle().length/7,2))}},{key:"build",value:function(){var t=this;this.parent.options.table_row||(this.label=this.header=this.theme.getCheckboxLabel(this.getTitle(),this.isRequired()),this.label.htmlFor=this.formname),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&!this.options.compact&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.input=this.theme.getCheckbox(),this.input.id=this.formname,this.control=this.theme.getFormControl(this.label,this.input,this.description,this.infoButton),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),this.input.disabled=!0),this.input.addEventListener("change",function(e){e.preventDefault(),e.stopPropagation(),t.value=e.currentTarget.checked,t.onChange(!0)}),this.container.appendChild(this.control)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,kn(Mr(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,kn(Mr(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),kn(Mr(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;this.previous_error_setting=this.jsoneditor.options.show_errors;var o=t.reduce(function(u,d){return d.path===e.path&&u.push(d.message),u},[]);this.input.controlgroup=this.control,o.length?this.theme.addInputError(this.input,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input)}}])&&ds(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Mn(c){return Mn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Mn(c)}function ea(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Mn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Mn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Mn(h)==="symbol"?h:String(h)),i)}var h}function Cr(){return Cr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Sr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Cr.apply(this,arguments)}function an(c,n){return an=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},an(c,n)}function Sr(c){return Sr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Sr(c)}_(2707);var hi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&an(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Sr(i);if(h){var o=Sr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Mn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){var o=this.typecast(t),u=!!this.jsoneditor.options.use_default_values||this.schema.default!==void 0;(this.enum_options.length>0&&!this.enum_values.includes(o)||e&&!this.isRequired()&&!u)&&(o=this.enum_values[0]),this.value!==o&&(e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.input.value=this.enum_options[this.enum_values.indexOf(o)],this.value=o,this.onChange(),this.change())}},{key:"register",value:function(){Cr(Sr(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){Cr(Sr(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"getNumColumns",value:function(){if(!this.enum_options)return 3;for(var t=this.getTitle().length,e=0;e<this.enum_options.length;e++)t=Math.max(t,this.enum_options[e].length+4);return Math.min(12,Math.max(t/7,2))}},{key:"typecast",value:function(t){return this.schema.type==="boolean"?t==="undefined"||t===void 0?void 0:!!t:this.schema.type==="number"?1*t||0:this.schema.type==="integer"?Math.floor(1*t||0):this.schema.enum&&t===void 0?void 0:"".concat(t)}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.typecast(this.value)}},{key:"preBuild",value:function(){var t,e,o=this;if(this.input_type="select",this.enum_options=[],this.enum_values=[],this.enum_display=[],this.schema.enum){var u=this.schema.options&&this.schema.options.enum_titles||[];this.schema.enum.forEach(function(d,x){o.enum_options[x]="".concat(d),o.enum_display[x]="".concat(o.translateProperty(u[x])||d),o.enum_values[x]=o.typecast(d)})}else if(this.schema.type==="boolean")this.enum_display=this.schema.options&&this.schema.options.enum_titles||["true","false"],this.enum_options=["1",""],this.enum_values=[!0,!1],this.isRequired()||(this.enum_display.unshift(" "),this.enum_options.unshift("undefined"),this.enum_values.unshift(void 0));else{if(!this.schema.enumSource)throw new Error("'select' editor requires the enum property to be set.");if(this.enumSource=[],this.enum_display=[],this.enum_options=[],this.enum_values=[],Array.isArray(this.schema.enumSource))for(t=0;t<this.schema.enumSource.length;t++)typeof this.schema.enumSource[t]=="string"?this.enumSource[t]={source:this.schema.enumSource[t]}:Array.isArray(this.schema.enumSource[t])?this.enumSource[t]=this.schema.enumSource[t]:this.enumSource[t]=k({},this.schema.enumSource[t]);else this.schema.enumValue?this.enumSource=[{source:this.schema.enumSource,value:this.schema.enumValue}]:this.enumSource=[{source:this.schema.enumSource}];for(t=0;t<this.enumSource.length;t++)this.enumSource[t].value&&(typeof(e=this.expandCallbacks("template",{template:this.enumSource[t].value})).template=="function"?this.enumSource[t].value=e.template:this.enumSource[t].value=this.jsoneditor.compileTemplate(this.enumSource[t].value,this.template_engine)),this.enumSource[t].title&&(typeof(e=this.expandCallbacks("template",{template:this.enumSource[t].title})).template=="function"?this.enumSource[t].title=e.template:this.enumSource[t].title=this.jsoneditor.compileTemplate(this.enumSource[t].title,this.template_engine)),this.enumSource[t].filter&&this.enumSource[t].value&&(typeof(e=this.expandCallbacks("template",{template:this.enumSource[t].filter})).template=="function"?this.enumSource[t].filter=e.template:this.enumSource[t].filter=this.jsoneditor.compileTemplate(this.enumSource[t].filter,this.template_engine))}}},{key:"build",value:function(){var t=this;this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.input=this.theme.getSelectInput(this.enum_options,!1),this.theme.setSelectOptions(this.input,this.enum_options,this.enum_display),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),this.input.disabled=!0),this.setInputAttributes([]),this.input.addEventListener("change",function(e){e.preventDefault(),e.stopPropagation(),t.onInputChange()}),this.control=this.theme.getFormControl(this.label,this.input,this.description,this.infoButton),this.container.appendChild(this.control),this.value=this.enum_values[0],window.requestAnimationFrame(function(){t.input.parentNode&&t.afterInputReady()})}},{key:"afterInputReady",value:function(){this.theme.afterInputReady(this.input)}},{key:"onInputChange",value:function(){var t,e=this.typecast(this.input.value);(t=this.enum_values.includes(e)?this.enum_values[this.enum_values.indexOf(e)]:this.enum_values[0])!==this.value&&(this.is_dirty=!0,this.value=t,this.onChange(!0))}},{key:"onWatchedFieldChange",value:function(){var t,e,o=[],u=[];if(this.enumSource){t=this.getWatchedFieldValues();for(var d=0;d<this.enumSource.length;d++)if(Array.isArray(this.enumSource[d]))o=o.concat(this.enumSource[d]),u=u.concat(this.enumSource[d]);else{var x=[];if(x=Array.isArray(this.enumSource[d].source)?this.enumSource[d].source:t[this.enumSource[d].source]){if(this.enumSource[d].slice&&(x=Array.prototype.slice.apply(x,this.enumSource[d].slice)),this.enumSource[d].filter){var P=[];for(e=0;e<x.length;e++)this.enumSource[d].filter({i:e,item:x[e],watched:t})&&P.push(x[e]);x=P}var D=[],J=[];for(e=0;e<x.length;e++){var nt=x[e];this.enumSource[d].value?J[e]=this.typecast(this.enumSource[d].value({i:e,item:nt})):J[e]=x[e],this.enumSource[d].title?D[e]=this.enumSource[d].title({i:e,item:nt}):D[e]=J[e]}this.enumSource[d].sort&&(function(dt,kt,Ct){dt.map(function(Nt,ne){return{v:Nt,t:kt[ne]}}).sort(function(Nt,ne){return Nt.v<ne.v?-Ct:Nt.v===ne.v?0:Ct}).forEach(function(Nt,ne){dt[ne]=Nt.v,kt[ne]=Nt.t})}).bind(null,J,D,this.enumSource[d].sort==="desc"?1:-1)(),o=o.concat(J),u=u.concat(D)}}var ut=this.value;this.theme.setSelectOptions(this.input,o,u),this.enum_options=o,this.enum_display=u,this.enum_values=o,o.includes(ut)||this.jsoneditor.options.enum_source_value_auto_select!==!1?(this.input.value=ut,this.value=ut):(this.input.value=o[0],this.value=this.typecast(o[0]||""),this.parent&&!this.watchLoop?this.parent.onChildEditorChange(this):this.jsoneditor.onChange(),this.jsoneditor.notifyWatchers(this.path))}Cr(Sr(l.prototype),"onWatchedFieldChange",this).call(this)}},{key:"enable",value:function(){this.always_disabled||(this.input.disabled=!1,Cr(Sr(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.input.disabled=!0,Cr(Sr(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),Cr(Sr(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;this.previous_error_setting=this.jsoneditor.options.show_errors;var o=t.reduce(function(u,d){return d.path===e.path&&u.push(d.message),u},[]);o.length?this.theme.addInputError(this.input,"".concat(o.join(". "),".")):this.theme.removeInputError(this.input)}}])&&ea(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Hn(c){return Hn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Hn(c)}function ml(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Hn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Hn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Hn(h)==="symbol"?h:String(h)),i)}var h}function Hr(){return Hr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=z(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Hr.apply(this,arguments)}function L(c,n){return L=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},L(c,n)}function z(c){return z=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},z(c)}var rt=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&L(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=z(i);if(h){var o=z(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Hn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){if(this.choices_instance){var o=this.typecast(t||"");if(this.enum_values.includes(o)||(o=this.enum_values[0]),this.value===o)return;e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.input.value=this.enum_options[this.enum_values.indexOf(o)],this.choices_instance.setChoiceByValue(this.input.value),this.value=o,this.onChange()}else Hr(z(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){if(window.Choices&&!this.choices_instance){var t=this.expandCallbacks("choices",k({},this.defaults.options.choices||{},this.options.choices||{}));this.choices_instance=new window.Choices(this.input,t)}Hr(z(l.prototype),"afterInputReady",this).call(this)}},{key:"onWatchedFieldChange",value:function(){var t=this;if(Hr(z(l.prototype),"onWatchedFieldChange",this).call(this),this.choices_instance){var e=this.enum_options.map(function(o,u){return{value:o,label:t.enum_display[u]}});this.choices_instance.setChoices(e,"value","label",!0),this.choices_instance.setChoiceByValue("".concat(this.value))}}},{key:"enable",value:function(){!this.always_disabled&&this.choices_instance&&this.choices_instance.enable(),Hr(z(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.choices_instance&&this.choices_instance.disable(),Hr(z(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.choices_instance&&(this.choices_instance.destroy(),this.choices_instance=null),Hr(z(l.prototype),"destroy",this).call(this)}}])&&ml(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function Q(c){return Q=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Q(c)}function mt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Q(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Q(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Q(h)==="symbol"?h:String(h)),i)}var h}function Bt(){return Bt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=ft(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Bt.apply(this,arguments)}function Yt(c,n){return Yt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Yt(c,n)}function ft(c){return ft=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ft(c)}rt.rules={".choices > *":"box-sizing:border-box"};var vt=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Yt(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ft(i);if(h){var o=ft(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Q(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){if(Bt(ft(l.prototype),"build",this).call(this),this.input&&(this.schema.max&&typeof this.schema.max=="string"&&this.input.setAttribute("max",this.schema.max),this.schema.min&&typeof this.schema.max=="string"&&this.input.setAttribute("min",this.schema.min),window.flatpickr&&Q(this.options.flatpickr)==="object")){this.options.flatpickr.enableTime=this.schema.format!=="date",this.options.flatpickr.noCalendar=this.schema.format==="time",this.schema.type==="integer"&&(this.options.flatpickr.mode="single"),this.input.setAttribute("data-input","");var t=this.input;if(this.options.flatpickr.wrap===!0){var e=[];if(this.options.flatpickr.showToggleButton!==!1){var o=this.getButton("",this.schema.format==="time"?"time":"calendar","flatpickr_toggle_button");o.setAttribute("data-toggle",""),e.push(o)}if(this.options.flatpickr.showClearButton!==!1){var u=this.getButton("","clear","flatpickr_clear_button");u.setAttribute("data-clear",""),e.push(u)}var d=this.input.parentNode,x=this.input.nextSibling,P=this.theme.getInputGroup(this.input,e);P!==void 0?(this.options.flatpickr.inline=!1,d.insertBefore(P,x),t=P):this.options.flatpickr.wrap=!1}this.flatpickr=window.flatpickr(t,this.options.flatpickr),this.options.flatpickr.inline===!0&&this.options.flatpickr.inlineHideInput===!0&&this.input.setAttribute("type","hidden")}}},{key:"getValue",value:function(){if(this.dependenciesFulfilled){if(this.schema.type==="string")return this.value;if(this.value!==""&&this.value!==void 0){var t=this.schema.format==="time"?"1970-01-01 ".concat(this.value):this.value;return parseInt(new Date(t).getTime()/1e3)}}}},{key:"setValue",value:function(t,e,o){if(this.schema.type==="string")Bt(ft(l.prototype),"setValue",this).call(this,t,e,o),this.flatpickr&&this.flatpickr.setDate(t);else if(t>0){var u=new Date(1e3*t),d=u.getFullYear(),x=this.zeroPad(u.getMonth()+1),P=this.zeroPad(u.getDate()),D=this.zeroPad(u.getHours()),J=this.zeroPad(u.getMinutes()),nt=this.zeroPad(u.getSeconds()),ut=[d,x,P].join("-"),dt=[D,J,nt].join(":"),kt="".concat(ut,"T").concat(dt);this.schema.format==="date"?kt=ut:this.schema.format==="time"&&(kt=dt),this.input.value=kt,this.refreshValue(),this.flatpickr&&this.flatpickr.setDate(kt)}}},{key:"destroy",value:function(){this.flatpickr&&this.flatpickr.destroy(),this.flatpickr=null,Bt(ft(l.prototype),"destroy",this).call(this)}},{key:"zeroPad",value:function(t){return"0".concat(t).slice(-2)}}])&&mt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function Zt(c){return Zt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Zt(c)}function oe(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Zt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Zt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Zt(h)==="symbol"?h:String(h)),i)}var h}function Tt(){return Tt=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Be(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Tt.apply(this,arguments)}function ue(c,n){return ue=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ue(c,n)}function Be(c){return Be=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Be(c)}var ir=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ue(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Be(i);if(h){var o=Be(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Zt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){if(this.editors){for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister();this.editors[this.currentEditor]&&this.editors[this.currentEditor].register()}Tt(Be(l.prototype),"register",this).call(this)}},{key:"unregister",value:function(){if(Tt(Be(l.prototype),"unregister",this).call(this),this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister()}},{key:"getNumColumns",value:function(){return this.editors[this.currentEditor]?Math.max(this.editors[this.currentEditor].getNumColumns(),4):4}},{key:"enable",value:function(){if(this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].enable();Tt(Be(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(){if(this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].disable();Tt(Be(l.prototype),"disable",this).call(this)}},{key:"switchEditor",value:function(){var t=this,e=this.getWatchedFieldValues();if(e){var o=document.location.origin+document.location.pathname+this.template(e);this.editors[this.refs[o]]||this.buildChildEditor(o),this.currentEditor=this.refs[o],this.register(),this.editors.forEach(function(u,d){u&&(t.currentEditor===d?u.container.style.display="":u.container.style.display="none")}),this.refreshValue(),this.onChange(!0)}}},{key:"buildChildEditor",value:function(t){this.refs[t]=this.editors.length;var e=this.theme.getChildEditorHolder();this.editor_holder.appendChild(e);var o=k({},this.schema,this.jsoneditor.refs[t]),u=this.jsoneditor.getEditorClass(o,this.jsoneditor),d=this.jsoneditor.createEditor(u,{jsoneditor:this.jsoneditor,schema:o,container:e,path:this.path,parent:this,required:!0});this.editors.push(d),d.preBuild(),d.build(),d.postBuild()}},{key:"preBuild",value:function(){var t;for(this.refs={},this.editors=[],this.currentEditor="",t=0;t<this.schema.links.length;t++)if(this.schema.links[t].rel.toLowerCase()==="describedby"){this.template=this.jsoneditor.compileTemplate(this.schema.links[t].href,this.template_engine);break}this.schema.links=this.schema.links.slice(0,t).concat(this.schema.links.slice(t+1)),this.schema.links.length===0&&delete this.schema.links,this.baseSchema=k({},this.schema)}},{key:"build",value:function(){this.editor_holder=document.createElement("div"),this.container.appendChild(this.editor_holder),this.switchEditor()}},{key:"onWatchedFieldChange",value:function(){this.switchEditor()}},{key:"onChildEditorChange",value:function(t){this.editors[this.currentEditor]&&this.refreshValue(),Tt(Be(l.prototype),"onChildEditorChange",this).call(this,t)}},{key:"refreshValue",value:function(){this.editors[this.currentEditor]&&(this.value=this.editors[this.currentEditor].getValue())}},{key:"setValue",value:function(t,e){this.editors[this.currentEditor]&&(this.editors[this.currentEditor].setValue(t,e),this.refreshValue(),this.onChange())}},{key:"destroy",value:function(){this.editors.forEach(function(t){t&&t.destroy()}),this.editor_holder&&this.editor_holder.parentNode&&this.editor_holder.parentNode.removeChild(this.editor_holder),Tt(Be(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){this.editors.forEach(function(e){e&&e.showValidationErrors(t)})}}])&&oe(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Rt(c){return Rt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Rt(c)}function ee(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function zt(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Rt(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Rt(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Rt(h)==="symbol"?h:String(h)),i)}var h}function me(){return me=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Oe(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},me.apply(this,arguments)}function Ue(c,n){return Ue=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ue(c,n)}function Oe(c){return Oe=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Oe(c)}var $e=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ue(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Oe(i);if(h){var o=Oe(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Rt(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 4}},{key:"build",value:function(){var t=this;this.title=this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired()),this.container.appendChild(this.title),this.options.enum_titles=this.options.enum_titles||[],this.enum=this.schema.enum,this.selected=0,this.select_options=[],this.html_values=[];for(var e=0;e<this.enum.length;e++)this.select_options[e]=this.options.enum_titles[e]||"Value ".concat(e+1),this.html_values[e]=this.getHTML(this.enum[e]);this.switcher=this.theme.getSwitcher(this.select_options),this.container.appendChild(this.switcher),this.display_area=this.theme.getIndentedPanel(),this.container.appendChild(this.display_area),this.options.hide_display&&(this.display_area.style.display="none"),this.switcher.addEventListener("change",function(o){t.selected=t.select_options.indexOf(o.currentTarget.value),t.value=t.enum[t.selected],t.refreshValue(),t.onChange(!0)}),this.value=this.enum[0],this.refreshValue(),this.enum.length===1&&(this.switcher.style.display="none")}},{key:"refreshValue",value:function(){var t=this;this.selected=-1;var e=JSON.stringify(this.value);this.enum.forEach(function(o,u){if(e===JSON.stringify(o))return t.selected=u,!1}),this.selected<0?this.setValue(this.enum[0]):(this.switcher.value=this.select_options[this.selected],this.display_area.innerHTML=this.html_values[this.selected])}},{key:"enable",value:function(){this.always_disabled||(this.switcher.disabled=!1,me(Oe(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.switcher.disabled=!0,me(Oe(l.prototype),"disable",this).call(this)}},{key:"getHTML",value:function(t){var e,o,u=this;if(t===null)return"<em>null</em>";if(Rt(t)==="object"){var d="";return e=t,o=function(x,P){var D=u.getHTML(P);Array.isArray(t)||(D="<div><em>".concat(x,"</em>: ").concat(D,"</div>")),d+="<li>".concat(D,"</li>")},Array.isArray(e)||typeof e.length=="number"&&e.length>0&&e.length-1 in e?Array.from(e).forEach(function(x,P){return o(P,x)}):Object.entries(e).forEach(function(x){var P,D,J=(D=2,function(dt){if(Array.isArray(dt))return dt}(P=x)||function(dt,kt){var Ct=dt==null?null:typeof Symbol<"u"&&dt[Symbol.iterator]||dt["@@iterator"];if(Ct!=null){var Nt,ne,Re,Gt,gt=[],Jt=!0,Ge=!1;try{if(Re=(Ct=Ct.call(dt)).next,kt===0){if(Object(Ct)!==Ct)return;Jt=!1}else for(;!(Jt=(Nt=Re.call(Ct)).done)&&(gt.push(Nt.value),gt.length!==kt);Jt=!0);}catch(W){Ge=!0,ne=W}finally{try{if(!Jt&&Ct.return!=null&&(Gt=Ct.return(),Object(Gt)!==Gt))return}finally{if(Ge)throw ne}}return gt}}(P,D)||function(dt,kt){if(dt){if(typeof dt=="string")return ee(dt,kt);var Ct=Object.prototype.toString.call(dt).slice(8,-1);return Ct==="Object"&&dt.constructor&&(Ct=dt.constructor.name),Ct==="Map"||Ct==="Set"?Array.from(dt):Ct==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Ct)?ee(dt,kt):void 0}}(P,D)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
75
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()),nt=J[0],ut=J[1];return o(nt,ut)}),d=Array.isArray(t)?"<ol>".concat(d,"</ol>"):"<ul style='margin-top:0;margin-bottom:0;padding-top:0;padding-bottom:0;'>".concat(d,"</ul>")}return typeof t=="boolean"?t?"true":"false":typeof t=="string"?t.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"):t}},{key:"setValue",value:function(t){this.value!==t&&(this.value=t,this.refreshValue(),this.onChange())}},{key:"destroy",value:function(){this.display_area&&this.display_area.parentNode&&this.display_area.parentNode.removeChild(this.display_area),this.title&&this.title.parentNode&&this.title.parentNode.removeChild(this.title),this.switcher&&this.switcher.parentNode&&this.switcher.parentNode.removeChild(this.switcher),me(Oe(l.prototype),"destroy",this).call(this)}}])&&zt(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function xe(c){return xe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},xe(c)}function mr(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(xe(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(xe(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),xe(h)==="symbol"?h:String(h)),i)}var h}function Me(){return Me=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Pr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Me.apply(this,arguments)}function Fr(c,n){return Fr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Fr(c,n)}function Pr(c){return Pr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Pr(c)}var fs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Fr(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Pr(i);if(h){var o=Pr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(xe(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){Me(Pr(l.prototype),"register",this).call(this),this.input&&this.jsoneditor.options.use_name_attributes&&this.input.setAttribute("name",this.formname)}},{key:"unregister",value:function(){Me(Pr(l.prototype),"unregister",this).call(this),this.input&&this.input.removeAttribute("name")}},{key:"setValue",value:function(t,e,o){if((!this.template||o)&&(t==null?t="":xe(t)==="object"?t=JSON.stringify(t):typeof t!="string"&&(t="".concat(t)),t!==this.serialized)){var u=this.sanitize(t);if(this.input.value!==u){this.input.value=u;var d=o||this.getValue()!==t;this.refreshValue(),e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0),this.adjust_height&&this.adjust_height(this.input),this.onChange(d)}}}},{key:"getNumColumns",value:function(){return 2}},{key:"enable",value:function(){Me(Pr(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(){Me(Pr(l.prototype),"disable",this).call(this)}},{key:"refreshValue",value:function(){this.value=this.input.value,typeof this.value!="string"&&(this.value=""),this.serialized=this.value}},{key:"destroy",value:function(){this.template=null,this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),Me(Pr(l.prototype),"destroy",this).call(this)}},{key:"sanitize",value:function(t){return t}},{key:"onWatchedFieldChange",value:function(){var t;this.template&&(t=this.getWatchedFieldValues(),this.setValue(this.template(t),!1,!0)),Me(Pr(l.prototype),"onWatchedFieldChange",this).call(this)}},{key:"build",value:function(){if(this.format=this.schema.format,!this.format&&this.options.default_format&&(this.format=this.options.default_format),this.options.format&&(this.format=this.options.format),this.input_type="hidden",this.input=this.theme.getFormInputField(this.input_type),this.format&&this.input.setAttribute("data-schemaformat",this.format),this.container.appendChild(this.input),this.schema.template){var t=this.expandCallbacks("template",{template:this.schema.template});typeof t.template=="function"?this.template=t.template:this.template=this.jsoneditor.compileTemplate(this.schema.template,this.template_engine),this.refreshValue()}else this.refreshValue()}}])&&mr(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Jr(c){return Jr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Jr(c)}function yl(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Jr(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Jr(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Jr(h)==="symbol"?h:String(h)),i)}var h}function Ui(c,n){return Ui=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ui(c,n)}function Vr(c){return Vr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Vr(c)}var qi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ui(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Vr(i);if(h){var o=Vr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Jr(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){this.options.compact=!1,this.header=this.label=this.theme.getFormInputLabel(this.getTitle()),this.description=this.theme.getDescription(this.schema.description||""),this.control=this.theme.getFormControl(this.label,this.description,null),this.container.appendChild(this.control)}},{key:"getTitle",value:function(){return this.translateProperty(this.schema.title)}},{key:"getNumColumns",value:function(){return 12}}])&&yl(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hs);function jn(c){return jn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},jn(c)}function ms(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(jn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(jn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),jn(h)==="symbol"?h:String(h)),i)}var h}function Gi(){return Gi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Fn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Gi.apply(this,arguments)}function Wi(c,n){return Wi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Wi(c,n)}function Fn(c){return Fn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Fn(c)}var ys=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Wi(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Fn(i);if(h){var o=Fn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(jn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){if(Gi(Fn(l.prototype),"build",this).call(this),this.schema.minimum!==void 0){var t=this.schema.minimum;this.schema.exclusiveMinimum!==void 0&&(t+=1),this.input.setAttribute("min",t)}if(this.schema.maximum!==void 0){var e=this.schema.maximum;this.schema.exclusiveMaximum!==void 0&&(e-=1),this.input.setAttribute("max",e)}if(this.schema.step!==void 0){var o=this.schema.step||1;this.input.setAttribute("step",o)}this.setInputAttributes(["maxlength","pattern","readonly","min","max","step"])}},{key:"getNumColumns",value:function(){return 2}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.schema.default||this.jsoneditor.options.use_default_values||this.value!==""?function(t){if(t==null)return!1;var e=t.match(T),o=parseFloat(t);return e!==null&&!isNaN(o)&&isFinite(o)}(this.value)?parseFloat(this.value):this.value:void(this.shouldBeUnset()&&(this.input.value=""))}}])&&ms(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function zr(c){return zr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},zr(c)}function di(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(zr(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(zr(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),zr(h)==="symbol"?h:String(h)),i)}var h}function Yr(c,n){return Yr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Yr(c,n)}function Zi(c){return Zi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Zi(c)}var bs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Yr(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Zi(i);if(h){var o=Zi(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(zr(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 2}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.schema.default||this.jsoneditor.options.use_default_values||this.value!==""?function(t){if(t==null)return!1;var e=t.match(A),o=parseInt(t);return e!==null&&!isNaN(o)&&isFinite(o)}(this.value)?parseInt(this.value):this.value:void this.shouldBeUnset()}}])&&di(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(ys);function Vn(c){return Vn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Vn(c)}function Ji(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Vn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Vn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Vn(h)==="symbol"?h:String(h)),i)}var h}function sn(){return sn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Xr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},sn.apply(this,arguments)}function zn(c,n){return zn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},zn(c,n)}function Xr(c){return Xr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Xr(c)}var ra=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&zn(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Xr(i);if(h){var o=Xr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Vn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"preBuild",value:function(){if(sn(Xr(l.prototype),"preBuild",this).call(this),this.schema.options||(this.schema.options={}),!this.schema.options.cleave)switch(this.format){case"ipv6":this.schema.options.cleave={delimiters:[":"],blocks:[4,4,4,4,4,4,4,4],uppercase:!0};break;case"ipv4":this.schema.options.cleave={delimiters:["."],blocks:[3,3,3,3],numericOnly:!0}}this.options=k(this.options,this.schema.options||{})}}])&&Ji(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function Un(c){return Un=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Un(c)}function bl(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Un(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Un(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Un(h)==="symbol"?h:String(h)),i)}var h}function Kr(){return Kr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Tr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Kr.apply(this,arguments)}function Yi(c,n){return Yi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Yi(c,n)}function Tr(c){return Tr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Tr(c)}var vs=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Yi(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Tr(i);if(h){var o=Tr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Un(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=Kr(Tr(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.jodit_instance&&this.jodit_instance.setEditorValue(u.value)}},{key:"build",value:function(){this.options.format="textarea",Kr(Tr(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t,e=this;window.Jodit?(t=this.expandCallbacks("jodit",k({},{height:300},this.defaults.options.jodit||{},this.options.jodit||{})),this.jodit_instance=new window.Jodit(this.input,t),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&this.jodit_instance.setReadOnly(!0),this.jodit_instance.events.on("change",function(){e.value=e.jodit_instance.getEditorValue(),e.is_dirty=!0,e.onChange(!0)}),this.theme.afterInputReady(this.input)):Kr(Tr(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.jodit_instance&&this.jodit_instance.setReadOnly(!1),Kr(Tr(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.jodit_instance&&this.jodit_instance.setReadOnly(!0),Kr(Tr(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.jodit_instance&&(this.jodit_instance.destruct(),this.jodit_instance=null),Kr(Tr(l.prototype),"destroy",this).call(this)}}])&&bl(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K),gs=(_(6541),_(9337),_(3321),function(c){var n=c.split(".");if(n.length!==4)throw new Error("error_ipv4");n.forEach(function(f){if(isNaN(+f)||+f<0||+f>255)throw new Error("error_ipv4")})}),na=function(c){if(!c.match("^(?:(?:(?:[a-fA-F0-9]{1,4}:){6}|(?=(?:[a-fA-F0-9]{0,4}:){2,6}(?:[0-9]{1,3}.){3}[0-9]{1,3}$)(([0-9a-fA-F]{1,4}:){1,5}|:)((:[0-9a-fA-F]{1,4}){1,5}:|:)|::(?:[a-fA-F0-9]{1,4}:){5})(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9])|(?:[a-fA-F0-9]{1,4}:){7}[a-fA-F0-9]{1,4}|(?=(?:[a-fA-F0-9]{0,4}:){0,7}[a-fA-F0-9]{0,4}$)(([0-9a-fA-F]{1,4}:){1,7}|:)((:[0-9a-fA-F]{1,4}){1,7}|:)|(?:[a-fA-F0-9]{1,4}:){7}:|:(:[a-fA-F0-9]{1,4}){7})$"))throw new Error("error_ipv6")},ia=function(c){if(!c.match("(?=^.{4,253}$)(^((?!-)[a-zA-Z0-9-]{0,62}[a-zA-Z0-9].)+[a-zA-Z]{2,63}$)"))throw new Error("error_hostname")};function oa(c,n,f,i){try{switch(c.format){case"ipv4":gs(n);break;case"ipv6":na(n);break;case"hostname":ia(n)}return[]}catch(h){return[{path:f,property:"format",message:i(h.message)}]}}function Xi(c,n){var f=Object.keys(c);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(c);n&&(i=i.filter(function(h){return Object.getOwnPropertyDescriptor(c,h).enumerable})),f.push.apply(f,i)}return f}function aa(c,n,f){return(n=Ki(n))in c?Object.defineProperty(c,n,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[n]=f,c}function pi(c,n){return function(f){if(Array.isArray(f))return f}(c)||function(f,i){var h=f==null?null:typeof Symbol<"u"&&f[Symbol.iterator]||f["@@iterator"];if(h!=null){var a,l,t,e,o=[],u=!0,d=!1;try{if(t=(h=h.call(f)).next,i===0){if(Object(h)!==h)return;u=!1}else for(;!(u=(a=t.call(h)).done)&&(o.push(a.value),o.length!==i);u=!0);}catch(x){d=!0,l=x}finally{try{if(!u&&h.return!=null&&(e=h.return(),Object(e)!==e))return}finally{if(d)throw l}}return o}}(c,n)||fi(c,n)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
76
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function yr(c){return yr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},yr(c)}function ke(c){return function(n){if(Array.isArray(n))return mi(n)}(c)||function(n){if(typeof Symbol<"u"&&n[Symbol.iterator]!=null||n["@@iterator"]!=null)return Array.from(n)}(c)||fi(c)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
77
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function fi(c,n){if(c){if(typeof c=="string")return mi(c,n);var f=Object.prototype.toString.call(c).slice(8,-1);return f==="Object"&&c.constructor&&(f=c.constructor.name),f==="Map"||f==="Set"?Array.from(c):f==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(f)?mi(c,n):void 0}}function mi(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function sa(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,Ki(i.key),i)}}function Ki(c){var n=function(f,i){if(yr(f)!=="object"||f===null)return f;var h=f[Symbol.toPrimitive];if(h!==void 0){var a=h.call(f,"string");if(yr(a)!=="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(f)}(c);return yr(n)==="symbol"?n:String(n)}var Qi=function(){function c(i,h,a,l){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,c),this.jsoneditor=i,this.schema=h||this.jsoneditor.schema,this.options=a||{},this.translate=this.jsoneditor.translate||l.translate,this.translateProperty=this.jsoneditor.translateProperty||l.translateProperty,this.defaults=l,this._validateSubSchema={dependentRequired:function(t,e,o){var u=[];if(t.dependentRequired!==void 0){var d=[];Object.keys(t.dependentRequired).forEach(function(x){if(e[x]!==void 0){var P=t.dependentRequired[x];d=P.filter(function(D){return!S(e,D)})}}),d.length>0&&u.push({message:"Must have the required properties: "+d.join(", "),path:o})}return u},dependentSchemas:function(t,e,o){var u=this,d=[];return Object.keys(t.dependentSchemas).forEach(function(x){if(e[x]!==void 0){var P=t.dependentSchemas[x],D=u._validateSchema(P,e,o);d=[].concat(ke(d),ke(D))}}),d},contains:function(t,e,o){var u=this,d=[],x=0;e.forEach(function(D){u._validateSchema(t.contains,D,o).length===0&&x++});var P=x===0;return t.minContains!==void 0?x<t.minContains&&d.push({message:this.translate("error_minContains",[x,t.minContains],t),path:o}):P&&d.push({message:this.translate("error_contains",null,t),path:o}),t.maxContains!==void 0&&x>t.maxContains&&d.push({message:this.translate("error_maxContains",[x,t.maxContains],t),path:o}),d},if:function(t,e,o){if(t.then===void 0&&t.else===void 0)return[];var u=this._validateSchema(t.if,e,o),d=[],x=[];return t.then!==void 0&&(d=this._validateSchema(t.then,e,o)),t.else!==void 0&&(x=this._validateSchema(t.else,e,o)),t.if===!0?d:t.if===!1?x:u.length===0?d:u.length>0?x:[]},const:function(t,e,o){return JSON.stringify(t.const)!==JSON.stringify(e)||Array.isArray(e)||yr(e)==="object"?[{path:o,property:"const",message:this.translate("error_const",null,t)}]:[]},enum:function(t,e,o){var u=JSON.stringify(e);return t.enum.some(function(d){return u===JSON.stringify(d)})?[]:[{path:o,property:"enum",message:this.translate("error_enum",null,t)}]},extends:function(t,e,o){var u=this;return t.extends.reduce(function(d,x){return d.push.apply(d,ke(u._validateSchema(x,e,o))),d},[])},allOf:function(t,e,o){var u=this;return t.allOf.reduce(function(d,x){return d.push.apply(d,ke(u._validateSchema(x,e,o))),d},[])},anyOf:function(t,e,o){var u=this;return t.anyOf.some(function(d){return!u._validateSchema(d,e,o).length})?[]:[{path:o,property:"anyOf",message:this.translate("error_anyOf",null,t)}]},oneOf:function(t,e,o){var u=this,d=0,x=[];t.oneOf.forEach(function(D,J){var nt=u._validateSchema(D,e,o);nt.length||d++,nt.forEach(function(ut){ut.path="".concat(o,".oneOf[").concat(J,"]").concat(ut.path.substr(o.length))}),x.push.apply(x,ke(nt))});var P=[];return d!==1&&(P.push({path:o,property:"oneOf",message:this.translate("error_oneOf",[d],t)}),P.push.apply(P,x)),P},not:function(t,e,o){return this._validateSchema(t.not,e,o).length?[]:[{path:o,property:"not",message:this.translate("error_not",null,t)}]},type:function(t,e,o){var u=this;if(Array.isArray(t.type)){if(!t.type.some(function(d){return u._checkType(d,e)}))return[{path:o,property:"type",message:this.translate("error_type_union",null,t)}]}else if(["date","time","datetime-local"].includes(t.format)&&t.type==="integer"){if(!this._checkType("string","".concat(e)))return[{path:o,property:"type",message:this.translate("error_type",[t.format],t)}]}else if(!this._checkType(t.type,e))return[{path:o,property:"type",message:this.translate("error_type",[t.type],t)}];return[]},disallow:function(t,e,o){var u=this;if(Array.isArray(t.disallow)){if(t.disallow.some(function(d){return u._checkType(d,e)}))return[{path:o,property:"disallow",message:this.translate("error_disallow_union",null,t)}]}else if(this._checkType(t.disallow,e))return[{path:o,property:"disallow",message:this.translate("error_disallow",[t.disallow],t)}];return[]}},this._validateNumberSubSchema={multipleOf:function(t,e,o){return this._validateNumberSubSchemaMultipleDivisible(t,e,o)},divisibleBy:function(t,e,o){return this._validateNumberSubSchemaMultipleDivisible(t,e,o)},maximum:function(t,e,o){var u=t.exclusiveMaximum?e<t.maximum:e<=t.maximum;return window.math?u=window.math[t.exclusiveMaximum?"smaller":"smallerEq"](window.math.bignumber(e),window.math.bignumber(t.maximum)):window.Decimal&&(u=new window.Decimal(e)[t.exclusiveMaximum?"lt":"lte"](new window.Decimal(t.maximum))),u?[]:[{path:o,property:"maximum",message:this.translate(t.exclusiveMaximum?"error_maximum_excl":"error_maximum_incl",[t.maximum],t)}]},minimum:function(t,e,o){var u=t.exclusiveMinimum?e>t.minimum:e>=t.minimum;return window.math?u=window.math[t.exclusiveMinimum?"larger":"largerEq"](window.math.bignumber(e),window.math.bignumber(t.minimum)):window.Decimal&&(u=new window.Decimal(e)[t.exclusiveMinimum?"gt":"gte"](new window.Decimal(t.minimum))),u?[]:[{path:o,property:"minimum",message:this.translate(t.exclusiveMinimum?"error_minimum_excl":"error_minimum_incl",[t.minimum],t)}]}},this._validateStringSubSchema={maxLength:function(t,e,o){var u=[];return"".concat(e).length>t.maxLength&&u.push({path:o,property:"maxLength",message:this.translate("error_maxLength",[t.maxLength],t)}),u},minLength:function(t,e,o){return"".concat(e).length<t.minLength?[{path:o,property:"minLength",message:this.translate(t.minLength===1?"error_notempty":"error_minLength",[t.minLength],t)}]:[]},pattern:function(t,e,o){return new RegExp(t.pattern).test(e)?[]:[{path:o,property:"pattern",message:t.options&&t.options.patternmessage?t.options.patternmessage:this.translate("error_pattern",[t.pattern],t)}]}},this._validateArraySubSchema={items:function(t,e,o){var u=this,d=[];if(Array.isArray(t.items))for(var x=0;x<e.length;x++)if(t.items[x])d.push.apply(d,ke(this._validateSchema(t.items[x],e[x],"".concat(o,".").concat(x))));else{if(t.additionalItems===!0)break;if(!t.additionalItems){if(t.additionalItems===!1){d.push({path:o,property:"additionalItems",message:this.translate("error_additionalItems",null,t)});break}break}d.push.apply(d,ke(this._validateSchema(t.additionalItems,e[x],"".concat(o,".").concat(x))))}else e.forEach(function(P,D){d.push.apply(d,ke(u._validateSchema(t.items,P,"".concat(o,".").concat(D))))});return d},maxItems:function(t,e,o){return e.length>t.maxItems?[{path:o,property:"maxItems",message:this.translate("error_maxItems",[t.maxItems],t)}]:[]},minItems:function(t,e,o){return e.length<t.minItems?[{path:o,property:"minItems",message:this.translate("error_minItems",[t.minItems],t)}]:[]},uniqueItems:function(t,e,o){for(var u={},d=0;d<e.length;d++){var x=JSON.stringify(e[d]);if(u[x])return[{path:o,property:"uniqueItems",message:this.translate("error_uniqueItems",null,t)}];u[x]=!0}return[]}},this._validateObjectSubSchema={maxProperties:function(t,e,o){return Object.keys(e).length>t.maxProperties?[{path:o,property:"maxProperties",message:this.translate("error_maxProperties",[t.maxProperties],t)}]:[]},minProperties:function(t,e,o){return Object.keys(e).length<t.minProperties?[{path:o,property:"minProperties",message:this.translate("error_minProperties",[t.minProperties],t)}]:[]},required:function(t,e,o){var u=this,d=[];return Array.isArray(t.required)&&t.required.forEach(function(x){if(e[x]===void 0){var P=u.jsoneditor.getEditor("".concat(o,".").concat(x));P&&P.dependenciesFulfilled===!1||P&&["button","info"].includes(P.schema.format||P.schema.type)||d.push({path:o,property:"required",message:u.translate("error_required",[t&&t.properties&&t.properties[x]&&t.properties[x].title?t.properties[x].title:x],t)})}}),d},properties:function(t,e,o,u){var d=this,x=[];return Object.entries(t.properties).forEach(function(P){var D=pi(P,2),J=D[0],nt=D[1];u[J]=!0,x.push.apply(x,ke(d._validateSchema(nt,e[J],"".concat(o,".").concat(J))))}),x},patternProperties:function(t,e,o,u){var d=this,x=[];return Object.entries(t.patternProperties).forEach(function(P){var D=pi(P,2),J=D[0],nt=D[1],ut=new RegExp(J);Object.entries(e).forEach(function(dt){var kt=pi(dt,2),Ct=kt[0],Nt=kt[1];ut.test(Ct)&&(u[Ct]=!0,x.push.apply(x,ke(d._validateSchema(nt,Nt,"".concat(o,".").concat(Ct)))))})}),x}},this._validateObjectSubSchema2={propertyNames:function(t,e,o,u){for(var d=this,x=[],P=Object.keys(e),D=null,J=function(){var dt="";return D=P[nt],typeof t.propertyNames=="boolean"?t.propertyNames===!0?"continue":(x.push({path:o,property:"propertyNames",message:d.translate("error_property_names_false",[D],t)}),"break"):Object.entries(t.propertyNames).every(function(kt){var Ct=pi(kt,2),Nt=Ct[0],ne=Ct[1],Re=!1;switch(Nt){case"maxLength":if(typeof ne!="number"){dt="error_property_names_maxlength";break}if(D.length>ne){dt="error_property_names_exceeds_maxlength";break}return!0;case"const":if(ne!==D){dt="error_property_names_const_mismatch";break}return!0;case"enum":if(!Array.isArray(ne)){dt="error_property_names_enum";break}if(ne.forEach(function(Gt){Gt===D&&(Re=!0)}),!Re){dt="error_property_names_enum_mismatch";break}return!0;case"pattern":if(typeof ne!="string"){dt="error_property_names_pattern";break}if(!new RegExp(ne).test(D)){dt="error_property_names_pattern_mismatch";break}return!0;default:return x.push({path:o,property:"propertyNames",message:d.translate("error_property_names_unsupported",[Nt],t)}),!1}return x.push({path:o,property:"propertyNames",message:d.translate(dt,[D],t)}),!1})?void 0:"break"},nt=0;nt<P.length;nt++){var ut=J();if(ut!=="continue"&&ut==="break")break}return x},additionalProperties:function(t,e,o,u){for(var d=[],x=Object.keys(e),P=0;P<x.length;P++){var D=x[P];if(!u[D]){if(!t.additionalProperties){d.push({path:o,property:"additionalProperties",message:this.translate("error_additional_properties",[D],t)});break}if(t.additionalProperties===!0)break;d.push.apply(d,ke(this._validateSchema(t.additionalProperties,e[D],"".concat(o,".").concat(D))))}}return d},dependencies:function(t,e,o){var u=this,d=[];return Object.entries(t.dependencies).forEach(function(x){var P=pi(x,2),D=P[0],J=P[1];e[D]!==void 0&&(Array.isArray(J)?J.forEach(function(nt){e[nt]===void 0&&d.push({path:o,property:"dependencies",message:u.translate("error_dependency",[nt],t)})}):d.push.apply(d,ke(u._validateSchema(J,e,o))))}),d}}}var n,f;return n=c,f=[{key:"fitTest",value:function(i,h){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1e7,l={match:0,extra:0};if(yr(i)==="object"&&i!==null){var t=this._getSchema(h);if(t.anyOf){var e,o=function(nt){for(var ut=1;ut<arguments.length;ut++){var dt=arguments[ut]!=null?arguments[ut]:{};ut%2?Xi(Object(dt),!0).forEach(function(kt){aa(nt,kt,dt[kt])}):Object.getOwnPropertyDescriptors?Object.defineProperties(nt,Object.getOwnPropertyDescriptors(dt)):Xi(Object(dt)).forEach(function(kt){Object.defineProperty(nt,kt,Object.getOwnPropertyDescriptor(dt,kt))})}return nt}({},l),u=function(nt,ut){var dt=typeof Symbol<"u"&&nt[Symbol.iterator]||nt["@@iterator"];if(!dt){if(Array.isArray(nt)||(dt=fi(nt))){dt&&(nt=dt);var kt=0,Ct=function(){};return{s:Ct,n:function(){return kt>=nt.length?{done:!0}:{done:!1,value:nt[kt++]}},e:function(Gt){throw Gt},f:Ct}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
78
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Nt,ne=!0,Re=!1;return{s:function(){dt=dt.call(nt)},n:function(){var Gt=dt.next();return ne=Gt.done,Gt},e:function(Gt){Re=!0,Nt=Gt},f:function(){try{ne||dt.return==null||dt.return()}finally{if(Re)throw Nt}}}}(t.anyOf);try{for(u.s();!(e=u.n()).done;){var d=e.value,x=this.fitTest(i,d,a);(x.match>o.match||x.match===o.match&&x.extra<o.extra)&&(o=x)}}catch(nt){u.e(nt)}finally{u.f()}return o}var P=this._getSchema(h).properties;for(var D in P)if(S(P,D)){if(yr(i[D])==="object"&&yr(P[D])==="object"&&yr(P[D].properties)==="object"){var J=this.fitTest(i[D],P[D],a/100);l.match+=J.match,l.extra+=J.extra}i[D]!==void 0&&(l.match+=a)}else l.extra+=a}return l}},{key:"_getSchema",value:function(i){return i===void 0?k({},this.jsoneditor.expandRefs(this.schema)):i}},{key:"validate",value:function(i){return this._validateSchema(this.schema,i)}},{key:"_validateSchema",value:function(i,h,a){var l=this,t=[];return a=a||this.jsoneditor.root.formname,i=k({},this.jsoneditor.expandRefs(i)),h===void 0?this._validateV3Required(i,h,a):(Object.keys(i).forEach(function(e){l._validateSubSchema[e]&&t.push.apply(t,ke(l._validateSubSchema[e].call(l,i,h,a)))}),t.push.apply(t,ke(this._validateByValueType(i,h,a))),i.links&&i.links.forEach(function(e,o){e.rel&&e.rel.toLowerCase()==="describedby"&&(i=l._expandSchemaLink(i,o),t.push.apply(t,ke(l._validateSchema(i,h,a,l.translate))))}),["date","time","datetime-local"].includes(i.format)&&t.push.apply(t,ke(this._validateDateTimeSubSchema(i,h,a))),["uuid"].includes(i.format)&&t.push.apply(t,ke(this._validateUUIDSchema(i,h,a))),t.push.apply(t,ke(this._validateCustomValidator(i,h,a))),this._removeDuplicateErrors(t))}},{key:"_expandSchemaLink",value:function(i,h){var a=i.links[h].href,l=this.jsoneditor.root.getValue(),t=this.jsoneditor.compileTemplate(a,this.jsoneditor.template),e=document.location.origin+document.location.pathname+t(l);return i.links=i.links.slice(0,h).concat(i.links.slice(h+1)),k({},i,this.jsoneditor.refs[e])}},{key:"_validateV3Required",value:function(i,h,a){return(i.required!==void 0&&i.required===!0||i.required===void 0&&this.jsoneditor.options.required_by_default===!0)&&i.type!=="info"?[{path:a,property:"required",message:this.translate("error_notset",null,i)}]:[]}},{key:"_validateByValueType",value:function(i,h,a){var l=this,t=[];if(h===null)return t;if(typeof h=="number")Object.keys(i).forEach(function(o){l._validateNumberSubSchema[o]&&t.push.apply(t,ke(l._validateNumberSubSchema[o].call(l,i,h,a)))});else if(typeof h=="string")Object.keys(i).forEach(function(o){l._validateStringSubSchema[o]&&t.push.apply(t,ke(l._validateStringSubSchema[o].call(l,i,h,a)))});else if(Array.isArray(h))Object.keys(i).forEach(function(o){l._validateArraySubSchema[o]&&t.push.apply(t,ke(l._validateArraySubSchema[o].call(l,i,h,a)))});else if(yr(h)==="object"){var e={};Object.keys(i).forEach(function(o){l._validateObjectSubSchema[o]&&t.push.apply(t,ke(l._validateObjectSubSchema[o].call(l,i,h,a,e)))}),i.additionalProperties!==void 0||!this.jsoneditor.options.no_additional_properties||i.oneOf||i.anyOf||i.allOf||(i.additionalProperties=!1),Object.keys(i).forEach(function(o){l._validateObjectSubSchema2[o]!==void 0&&t.push.apply(t,ke(l._validateObjectSubSchema2[o].call(l,i,h,a,e)))})}return t}},{key:"_validateUUIDSchema",value:function(i,h,a){return/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(h)?[]:[{path:a,property:"format",message:this.translate("error_pattern",["^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-5][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"],i)}]}},{key:"_validateNumberSubSchemaMultipleDivisible",value:function(i,h,a){var l=i.multipleOf||i.divisibleBy,t=h/l===Math.floor(h/l);return window.math?t=window.math.mod(window.math.bignumber(h),window.math.bignumber(l)).equals(0):window.Decimal&&(t=new window.Decimal(h).mod(new window.Decimal(l)).equals(0)),t?[]:[{path:a,property:i.multipleOf?"multipleOf":"divisibleBy",message:this.translate("error_multipleOf",[l],i)}]}},{key:"_validateDateTimeSubSchema",value:function(i,h,a){var l=this,t=this.jsoneditor.getEditor(a),e=t&&t.flatpickr?t.flatpickr.config.dateFormat:{date:'"YYYY-MM-DD"',time:'"HH:MM"',"datetime-local":'"YYYY-MM-DD HH:MM"'}[i.format];if(i.type==="integer")return function(o,u,d){return 1*u<1?[{path:d,property:"format",message:l.translate("error_invalid_epoch",null,o)}]:u!==Math.abs(parseInt(u))?[{path:d,property:"format",message:l.translate("error_".concat(o.format.replace(/-/g,"_")),[e],o)}]:[]}(i,h,a);if(t&&t.flatpickr){if(t)return function(o,u,d,x){if(u!==""){var P;if(x.flatpickr.config.mode!=="single"){var D=x.flatpickr.config.mode==="range"?x.flatpickr.l10n.rangeSeparator:", ";P=x.flatpickr.selectedDates.map(function(nt){return x.flatpickr.formatDate(nt,x.flatpickr.config.dateFormat)}).join(D)}try{if(P){if(P!==u)throw new Error("".concat(x.flatpickr.config.mode," mismatch"))}else if(x.flatpickr.formatDate(x.flatpickr.parseDate(u,x.flatpickr.config.dateFormat),x.flatpickr.config.dateFormat)!==u)throw new Error("mismatch")}catch{var J=x.flatpickr.config.errorDateFormat!==void 0?x.flatpickr.config.errorDateFormat:x.flatpickr.config.dateFormat;return[{path:d,property:"format",message:l.translate("error_".concat(x.format.replace(/-/g,"_")),[J],o)}]}}return[]}(i,h,a,t)}else if(!{date:/^(\d{4}\D\d{2}\D\d{2})?$/,time:/^(\d{2}:\d{2}(?::\d{2})?)?$/,"datetime-local":/^(\d{4}\D\d{2}\D\d{2}[ T]\d{2}:\d{2}(?::\d{2})?)?$/}[i.format].test(h))return[{path:a,property:"format",message:this.translate("error_".concat(i.format.replace(/-/g,"_")),[e],i)}];return[]}},{key:"_validateCustomValidator",value:function(i,h,a){var l=this,t=[];t.push.apply(t,ke(oa.call(this,i,h,a,this.translate)));var e=function(o){t.push.apply(t,ke(o.call(l,i,h,a)))};return this.defaults.custom_validators.forEach(e),this.options.custom_validators&&this.options.custom_validators.forEach(e),t}},{key:"_removeDuplicateErrors",value:function(i){return i.reduce(function(h,a){var l=!0;return h||(h=[]),h.forEach(function(t){t.message===a.message&&t.path===a.path&&t.property===a.property&&(t.errorcount++,l=!1)}),l&&(a.errorcount=1,h.push(a)),h},[])}},{key:"_checkType",value:function(i,h){var a={string:function(l){return typeof l=="string"},number:function(l){return typeof l=="number"},integer:function(l){return typeof l=="number"&&l===Math.floor(l)},boolean:function(l){return typeof l=="boolean"},array:function(l){return Array.isArray(l)},object:function(l){return l!==null&&!Array.isArray(l)&&yr(l)==="object"},null:function(l){return l===null}};return typeof i=="string"?!a[i]||a[i](h):!this._validateSchema(i,h).length}}],f&&sa(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function qe(c){return qe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},qe(c)}function Ur(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(qe(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(qe(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),qe(h)==="symbol"?h:String(h)),i)}var h}function ln(){return ln=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=br(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},ln.apply(this,arguments)}function la(c,n){return la=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},la(c,n)}function br(c){return br=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},br(c)}var to=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&la(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=br(i);if(h){var o=br(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(qe(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"register",value:function(){if(this.editors){for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister();this.editors[this.type]&&this.editors[this.type].register()}ln(br(l.prototype),"register",this).call(this)}},{key:"unregister",value:function(){if(ln(br(l.prototype),"unregister",this).call(this),this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].unregister()}},{key:"getNumColumns",value:function(){return this.editors[this.type]?Math.max(this.editors[this.type].getNumColumns(),4):4}},{key:"enable",value:function(){if(!this.always_disabled){if(this.editors)for(var t=0;t<this.editors.length;t++)this.editors[t]&&this.editors[t].enable();this.switcher.disabled=!1,ln(br(l.prototype),"enable",this).call(this)}}},{key:"disable",value:function(t){if(t&&(this.always_disabled=!0),this.editors)for(var e=0;e<this.editors.length;e++)this.editors[e]&&this.editors[e].disable(t);this.switcher.disabled=!0,ln(br(l.prototype),"disable",this).call(this)}},{key:"switchEditor",value:function(t){var e=this;this.lastType=this.type,this.editors[t]||this.buildChildEditor(t);var o=this.getValue();this.type=t,this.register(),this.editors.forEach(function(u,d){var x,P;u&&(e.type===d?(e.keep_only_existing_values&&(x=u.getValue(),P=o,Object.keys(P).forEach(function(D){D in x&&(x[D]=P[D])}),o=x),(e.keep_values||e.if)&&u.setValue(o,!0),u.container.style.display=""):u.container.style.display="none")}),this.refreshValue(),this.refreshHeaderText()}},{key:"buildChildEditor",value:function(t){var e,o=this,u=this.types[t],d=this.theme.getChildEditorHolder();this.editor_holder.appendChild(d),typeof u=="string"?(e=k({},this.schema)).type=u:(e=k({},this.schema,u),e=this.jsoneditor.expandRefs(e),u&&u.required&&Array.isArray(u.required)&&this.schema.required&&Array.isArray(this.schema.required)&&(e.required=this.schema.required.concat(u.required)));var x=this.jsoneditor.getEditorClass(e);this.editors[t]=this.jsoneditor.createEditor(x,{jsoneditor:this.jsoneditor,schema:e,container:d,path:this.path,parent:this,required:!0}),this.editors[t].preBuild(),this.editors[t].build(),this.editors[t].postBuild(),this.editors[t].header&&(this.editors[t].header.style.display="none"),this.editors[t].option=this.switcher_options[t],d.addEventListener("change_header_text",function(){o.refreshHeaderText()}),t!==this.type&&(d.style.display="none")}},{key:"preBuild",value:function(){if(this.types=[],this.type=0,this.editors=[],this.validators=[],this.keep_values=!0,this.jsoneditor.options.keep_oneof_values!==void 0&&(this.keep_values=this.jsoneditor.options.keep_oneof_values),this.options.keep_oneof_values!==void 0&&(this.keep_values=this.options.keep_oneof_values),this.keep_only_existing_values=!1,this.jsoneditor.options.keep_only_existing_values!==void 0&&(this.keep_only_existing_values=this.jsoneditor.options.keep_only_existing_values),this.options.keep_only_existing_values!==void 0&&(this.keep_only_existing_values=this.options.keep_only_existing_values),this.schema.oneOf)this.oneOf=!0,this.types=this.schema.oneOf,delete this.schema.oneOf;else if(this.schema.anyOf)this.anyOf=!0,this.types=this.schema.anyOf,delete this.schema.anyOf;else if(this.schema.if)this.if=!0,this.ifSchema=JSON.parse(JSON.stringify(this.schema.if)),this.thenSchema={title:"then"},this.elseSchema={title:"else"},this.types=[],this.schema.then&&$(this.thenSchema,this.schema,this.schema.then),this.schema.else&&$(this.elseSchema,this.schema,this.schema.else),this.types.push(this.thenSchema),this.types.push(this.elseSchema),this.types.forEach(function(o){delete o.if,delete o.then,delete o.else}),delete this.schema.if;else{if(this.schema.type&&this.schema.type!=="any")Array.isArray(this.schema.type)?this.types=this.schema.type:this.types=[this.schema.type];else if(this.types=["string","number","integer","boolean","object","array","null"],this.schema.disallow){var t=this.schema.disallow;qe(t)==="object"&&Array.isArray(t)||(t=[t]);var e=[];this.types.forEach(function(o){t.includes(o)||e.push(o)}),this.types=e}delete this.schema.type}this.display_text=this.getDisplayText(this.types)}},{key:"build",value:function(){var t=this,e=this.container;this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired()),this.switcher=this.theme.getSwitcher(this.display_text),this.if||(this.container.appendChild(this.header),e.appendChild(this.switcher)),this.switcher.addEventListener("change",function(u){u.preventDefault(),u.stopPropagation(),t.switchEditor(t.display_text.indexOf(u.currentTarget.value)),t.onChange(!0)}),this.editor_holder=document.createElement("div"),e.appendChild(this.editor_holder);var o={};this.jsoneditor.options.custom_validators&&(o.custom_validators=this.jsoneditor.options.custom_validators),this.switcher_options=this.theme.getSwitcherOptions(this.switcher),this.types.forEach(function(u,d){var x;t.editors[d]=!1,typeof u=="string"?(x=k({},t.schema)).type=u:(x=k({},t.schema,u),u.required&&Array.isArray(u.required)&&t.schema.required&&Array.isArray(t.schema.required)&&(x.required=t.schema.required.concat(u.required))),t.validators[d]=new Qi(t.jsoneditor,x,o,t.defaults)}),this.jsoneditor.on("change",function(){t.switchIf()}),this.switchEditor(0)}},{key:"onChildEditorChange",value:function(t){this.editors[this.type]&&(this.refreshValue(),this.refreshHeaderText()),ln(br(l.prototype),"onChildEditorChange",this).call(this)}},{key:"refreshHeaderText",value:function(){var t=this.getDisplayText(this.types);Array.from(this.switcher_options).forEach(function(e,o){e.textContent=t[o]})}},{key:"refreshValue",value:function(){this.editors[this.type]&&(this.value=this.editors[this.type].getValue())}},{key:"switchIf",value:function(){if(this.ifSchema&&this.value){var t=this.getIfType(this.value);this.lastType!==t&&(this.switchEditor(t),this.editors[this.type].setValue(this.value,!0)),this.switcher.value=this.display_text[this.type]}}},{key:"getIfType",value:function(t){return this.jsoneditor.validator._validateSchema(this.ifSchema,t).length===0?0:1}},{key:"setValue",value:function(t,e){var o=this,u=this.type,d={match:0,extra:0,i:this.type},x={match:0,i:null};this.validators.forEach(function(J,nt){var ut=null;o.anyOf!==void 0&&o.anyOf&&(ut=J.fitTest(t),(d.match<ut.match||d.match===ut.match&&d.extra>ut.extra)&&((d=ut).i=nt)),J.validate(t).length||x.i!==null?d=x:(x.i=nt,ut!==null&&(x.match=ut.match))});var P=x.i;this.anyOf!==void 0&&this.anyOf&&x.match<d.match&&(P=d.i),this.if&&(P=this.getIfType(t)),P===null&&(P=this.type),this.type=P,this.switcher.value=this.display_text[P];var D=this.type!==u;D&&(this.switchEditor(this.type),this.editors[this.type].setValue(t,e)),t!==void 0&&this.editors[this.type].setValue(t,e),this.refreshValue(),this.onChange(D)}},{key:"destroy",value:function(){this.editors.forEach(function(t){t&&t.destroy()}),this.editor_holder&&this.editor_holder.parentNode&&this.editor_holder.parentNode.removeChild(this.editor_holder),this.switcher&&this.switcher.parentNode&&this.switcher.parentNode.removeChild(this.switcher),ln(br(l.prototype),"destroy",this).call(this)}},{key:"showValidationErrors",value:function(t){var e=this;if(this.oneOf||this.anyOf){var o=this.oneOf?"oneOf":"anyOf";this.editors.forEach(function(u,d){if(u){var x="".concat(e.path,".").concat(o,"[").concat(d,"]");u.showValidationErrors(t.reduce(function(P,D){if(D.path.startsWith(x)||D.path===x.substr(0,D.path.length)){var J=k({},D);D.path.startsWith(x)&&(J.path=e.path+J.path.substr(x.length)),P.push(J)}return P},[]))}})}else this.editors.forEach(function(u){u&&u.showValidationErrors(t)})}},{key:"addLinks",value:function(){}}])&&Ur(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function On(c){return On=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},On(c)}function eo(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(On(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(On(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),On(h)==="symbol"?h:String(h)),i)}var h}function qn(c,n){return qn=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},qn(c,n)}function Gn(c){return Gn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Gn(c)}var ca=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&qn(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Gn(i);if(h){var o=Gn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(On(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getValue",value:function(){if(this.dependenciesFulfilled)return null}},{key:"setValue",value:function(){this.onChange()}},{key:"getNumColumns",value:function(){return 2}}])&&eo(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function ro(c,n){var f=Object.keys(c);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(c);n&&(i=i.filter(function(h){return Object.getOwnPropertyDescriptor(c,h).enumerable})),f.push.apply(f,i)}return f}function cn(c){for(var n=1;n<arguments.length;n++){var f=arguments[n]!=null?arguments[n]:{};n%2?ro(Object(f),!0).forEach(function(i){yi(c,i,f[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(c,Object.getOwnPropertyDescriptors(f)):ro(Object(f)).forEach(function(i){Object.defineProperty(c,i,Object.getOwnPropertyDescriptor(f,i))})}return c}function yi(c,n,f){return(n=io(n))in c?Object.defineProperty(c,n,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[n]=f,c}function En(c,n){return function(f){if(Array.isArray(f))return f}(c)||function(f,i){var h=f==null?null:typeof Symbol<"u"&&f[Symbol.iterator]||f["@@iterator"];if(h!=null){var a,l,t,e,o=[],u=!0,d=!1;try{if(t=(h=h.call(f)).next,i===0){if(Object(h)!==h)return;u=!1}else for(;!(u=(a=t.call(h)).done)&&(o.push(a.value),o.length!==i);u=!0);}catch(x){d=!0,l=x}finally{try{if(!u&&h.return!=null&&(e=h.return(),Object(e)!==e))return}finally{if(d)throw l}}return o}}(c,n)||function(f,i){if(f){if(typeof f=="string")return no(f,i);var h=Object.prototype.toString.call(f).slice(8,-1);return h==="Object"&&f.constructor&&(h=f.constructor.name),h==="Map"||h==="Set"?Array.from(f):h==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(h)?no(f,i):void 0}}(c,n)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
79
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function no(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function Br(c){return Br=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Br(c)}function ua(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,io(i.key),i)}}function io(c){var n=function(f,i){if(Br(f)!=="object"||f===null)return f;var h=f[Symbol.toPrimitive];if(h!==void 0){var a=h.call(f,"string");if(Br(a)!=="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(f)}(c);return Br(n)==="symbol"?n:String(n)}function Ar(){return Ar=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=vr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Ar.apply(this,arguments)}function oo(c,n){return oo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},oo(c,n)}function vr(c){return vr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},vr(c)}var bi=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&oo(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=vr(i);if(h){var o=vr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Br(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t,e,o){var u;return function(d,x){if(!(d instanceof x))throw new TypeError("Cannot call a class as a function")}(this,l),(u=a.call(this,t,e)).currentDepth=o,u}return n=l,(f=[{key:"getDefault",value:function(){return k({},this.schema.default||{})}},{key:"getChildEditors",value:function(){return this.editors}},{key:"register",value:function(){Ar(vr(l.prototype),"register",this).call(this),this.editors&&Object.values(this.editors).forEach(function(t){return t.register()})}},{key:"unregister",value:function(){Ar(vr(l.prototype),"unregister",this).call(this),this.editors&&Object.values(this.editors).forEach(function(t){return t.unregister()})}},{key:"getNumColumns",value:function(){return Math.max(Math.min(12,this.maxwidth),3)}},{key:"enable",value:function(){this.always_disabled||(this.editjson_control&&(this.editjson_control.disabled=!1),this.addproperty_button&&(this.addproperty_button.disabled=!1),Ar(vr(l.prototype),"enable",this).call(this),this.editors&&Object.values(this.editors).forEach(function(t){t.isActive()&&t.enable(),t.optInCheckbox.disabled=!1}))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.editjson_control&&(this.editjson_control.disabled=!0),this.addproperty_button&&(this.addproperty_button.disabled=!0),this.hideEditJSON(),Ar(vr(l.prototype),"disable",this).call(this),this.editors&&Object.values(this.editors).forEach(function(e){e.isActive()&&e.disable(t),e.optInCheckbox.disabled=!0})}},{key:"layoutEditors",value:function(){var t,e,o=this;if(this.row_container){var u;this.property_order=Object.keys(this.editors),this.property_order=this.property_order.sort(function(Gt,gt){var Jt=o.editors[Gt].schema.propertyOrder,Ge=o.editors[gt].schema.propertyOrder;return typeof Jt!="number"&&(Jt=1e3),typeof Ge!="number"&&(Ge=1e3),Jt-Ge});var d,x=this.format==="categories",P=[],D=null,J=null;if(this.format==="grid-strict"){var nt=0;if(d=[],this.property_order.forEach(function(Gt){var gt=o.editors[Gt];if(!gt.property_removed){var Jt=gt.options.hidden?0:gt.options.grid_columns||gt.getNumColumns(),Ge=gt.options.hidden?0:gt.options.grid_offset||0,W=!gt.options.hidden&&(gt.options.grid_break||!1),G={key:Gt,width:Jt,offset:Ge,height:gt.options.hidden?0:gt.container.offsetHeight};d.push(G),P[nt]=d,W&&(nt++,d=[])}}),this.layout===JSON.stringify(P))return!1;for(this.layout=JSON.stringify(P),u=document.createElement("div"),t=0;t<P.length;t++)for(d=this.theme.getGridRow(),u.appendChild(d),e=0;e<P[t].length;e++)D=P[t][e].key,(J=this.editors[D]).options.hidden?J.container.style.display="none":this.theme.setGridColumnSize(J.container,P[t][e].width,P[t][e].offset),d.appendChild(J.container)}else if(this.format==="grid"){for(this.property_order.forEach(function(Gt){var gt=o.editors[Gt];if(!gt.property_removed){for(var Jt=!1,Ge=gt.options.hidden?0:gt.options.grid_columns||gt.getNumColumns(),W=gt.options.hidden?0:gt.container.offsetHeight,G=0;G<P.length;G++)P[G].width+Ge<=12&&(!W||.5*P[G].minh<W&&2*P[G].maxh>W)&&(Jt=G);Jt===!1&&(P.push({width:0,minh:999999,maxh:0,editors:[]}),Jt=P.length-1),P[Jt].editors.push({key:Gt,width:Ge,height:W}),P[Jt].width+=Ge,P[Jt].minh=Math.min(P[Jt].minh,W),P[Jt].maxh=Math.max(P[Jt].maxh,W)}}),t=0;t<P.length;t++)if(P[t].width<12){var ut=!1,dt=0;for(e=0;e<P[t].editors.length;e++)(ut===!1||P[t].editors[e].width>P[t].editors[ut].width)&&(ut=e),P[t].editors[e].width*=12/P[t].width,P[t].editors[e].width=Math.floor(P[t].editors[e].width),dt+=P[t].editors[e].width;dt<12&&(P[t].editors[ut].width+=12-dt),P[t].width=12}if(this.layout===JSON.stringify(P))return!1;for(this.layout=JSON.stringify(P),u=document.createElement("div"),t=0;t<P.length;t++)for(d=this.theme.getGridRow(),u.appendChild(d),e=0;e<P[t].editors.length;e++)D=P[t].editors[e].key,(J=this.editors[D]).options.hidden?J.container.style.display="none":this.theme.setGridColumnSize(J.container,P[t].editors[e].width),d.appendChild(J.container)}else{if(u=document.createElement("div"),x){var kt=document.createElement("div"),Ct=this.theme.getTopTabHolder(this.translateProperty(this.schema.title)),Nt=this.theme.getTopTabContentHolder(Ct);for(this.property_order.forEach(function(Gt){var gt=o.editors[Gt];if(!gt.property_removed){var Jt=o.theme.getTabContent(),Ge=gt.schema&&(gt.schema.type==="object"||gt.schema.type==="array");Jt.isObjOrArray=Ge;var W=o.theme.getGridRow();gt.tab||(o.basicPane===void 0?o.addRow(gt,Ct,Jt):o.addRow(gt,Ct,o.basicPane)),Jt.id=o.getValidId(gt.tab_text.textContent),Ge?(Jt.appendChild(W),Nt.appendChild(Jt),o.theme.addTopTab(Ct,gt.tab)):(kt.appendChild(W),Nt.childElementCount>0?Nt.firstChild.isObjOrArray&&(Jt.appendChild(kt),Nt.insertBefore(Jt,Nt.firstChild),o.theme.insertBasicTopTab(gt.tab,Ct),gt.basicPane=Jt):(Jt.appendChild(kt),Nt.appendChild(Jt),o.theme.addTopTab(Ct,gt.tab),gt.basicPane=Jt)),gt.options.hidden?gt.container.style.display="none":o.theme.setGridColumnSize(gt.container,12),W.appendChild(gt.container),gt.rowPane=Jt}});this.tabPanesContainer.firstChild;)this.tabPanesContainer.removeChild(this.tabPanesContainer.firstChild);var ne=this.tabs_holder.parentNode;ne.removeChild(ne.firstChild),ne.appendChild(Ct),this.tabPanesContainer=Nt,this.tabs_holder=Ct;var Re=this.theme.getFirstTab(this.tabs_holder);return void(Re&&O(Re,"click"))}this.property_order.forEach(function(Gt){var gt=o.editors[Gt];gt.property_removed||(d=o.theme.getGridRow(),u.appendChild(d),gt.options.hidden?gt.container.style.display="none":o.theme.setGridColumnSize(gt.container,12),d.appendChild(gt.container))})}for(;this.row_container.firstChild;)this.row_container.removeChild(this.row_container.firstChild);this.row_container.appendChild(u)}}},{key:"getPropertySchema",value:function(t){var e=this,o=this.schema.properties[t]||{};o=k({},o);var u=!!this.schema.properties[t];return this.schema.patternProperties&&Object.keys(this.schema.patternProperties).forEach(function(d){new RegExp(d).test(t)&&(o.allOf=o.allOf||[],o.allOf.push(e.schema.patternProperties[d]),u=!0)}),!u&&this.schema.additionalProperties&&Br(this.schema.additionalProperties)==="object"&&(o=k({},this.schema.additionalProperties)),o}},{key:"preBuild",value:function(){var t=this;if(Ar(vr(l.prototype),"preBuild",this).call(this),this.editors={},this.cached_editors={},this.format=this.options.layout||this.options.object_layout||this.schema.format||this.jsoneditor.options.object_layout||"normal",this.schema.properties=this.schema.properties||{},this.minwidth=0,this.maxwidth=0,this.options.table_row)Object.entries(this.schema.properties).forEach(function(e){var o=En(e,2),u=o[0],d=o[1],x=t.jsoneditor.getEditorClass(d);t.editors[u]=t.jsoneditor.createEditor(x,{jsoneditor:t.jsoneditor,schema:d,path:"".concat(t.path,".").concat(u),parent:t,compact:!0,required:!0},t.currentDepth+1),t.editors[u].preBuild();var P=t.editors[u].options.hidden?0:t.editors[u].options.grid_columns||t.editors[u].getNumColumns();t.minwidth+=P,t.maxwidth+=P}),this.no_link_holder=!0;else{if(this.options.table)throw new Error("Not supported yet");this.schema.defaultProperties||(this.jsoneditor.options.display_required_only||this.options.display_required_only?this.schema.defaultProperties=Object.keys(this.schema.properties).filter(function(e){return t.isRequiredObject({key:e,schema:t.schema.properties[e]})}):this.schema.defaultProperties=Object.keys(this.schema.properties)),this.maxwidth+=1,Array.isArray(this.schema.defaultProperties)&&this.schema.defaultProperties.forEach(function(e){t.addObjectProperty(e,!0),t.editors[e]&&(t.minwidth=Math.max(t.minwidth,t.editors[e].options.grid_columns||t.editors[e].getNumColumns()),t.maxwidth+=t.editors[e].options.grid_columns||t.editors[e].getNumColumns())})}this.property_order=Object.keys(this.editors),this.property_order=this.property_order.sort(function(e,o){var u=t.editors[e].schema.propertyOrder,d=t.editors[o].schema.propertyOrder;return typeof u!="number"&&(u=1e3),typeof d!="number"&&(d=1e3),u-d})}},{key:"addTab",value:function(t){var e=this,o=this.rows[t].schema&&(this.rows[t].schema.type==="object"||this.rows[t].schema.type==="array");this.tabs_holder&&(this.rows[t].tab_text=document.createElement("span"),this.rows[t].tab_text.textContent=o?this.rows[t].getHeaderText():this.schema.basicCategoryTitle===void 0?"Basic":this.schema.basicCategoryTitle,this.rows[t].tab=this.theme.getTopTab(this.rows[t].tab_text,this.getValidId(this.rows[t].tab_text.textContent)),this.rows[t].tab.addEventListener("click",function(u){e.active_tab=e.rows[t].tab,e.refreshTabs(),u.preventDefault(),u.stopPropagation()}))}},{key:"addRow",value:function(t,e,o){var u=this.rows.length,d=t.schema.type==="object"||t.schema.type==="array";this.rows[u]=t,this.rows[u].rowPane=o,d?(this.addTab(u),this.theme.addTopTab(e,this.rows[u].tab)):this.basicTab===void 0?(this.addTab(u),this.basicTab=u,this.basicPane=o,this.theme.addTopTab(e,this.rows[u].tab)):(this.rows[u].tab=this.rows[this.basicTab].tab,this.rows[u].tab_text=this.rows[this.basicTab].tab_text,this.rows[u].rowPane=this.rows[this.basicTab].rowPane)}},{key:"refreshTabs",value:function(t){var e=this,o=this.basicTab!==void 0,u=!1;this.rows.forEach(function(d){d.tab&&d.rowPane&&d.rowPane.parentNode&&(o&&d.tab===e.rows[e.basicTab].tab&&u||(t?d.tab_text.textContent=d.getHeaderText():(o&&d.tab===e.rows[e.basicTab].tab&&(u=!0),d.tab===e.active_tab?e.theme.markTabActive(d):e.theme.markTabInactive(d))))})}},{key:"build",value:function(){var t=this,e=this.format==="categories";if(this.rows=[],this.active_tab=null,this.options.table_row)this.editor_holder=this.container,Object.entries(this.editors).forEach(function(u){var d=En(u,2),x=d[0],P=d[1],D=t.theme.getTableCell();t.editor_holder.appendChild(D),P.setContainer(D),P.build(),P.postBuild(),P.setOptInCheckbox(P.header),P.setValue(P.getDefault(),!0),t.editors[x].options.hidden&&(D.style.display="none"),t.editors[x].options.input_width&&(D.style.width=t.editors[x].options.input_width)});else{if(this.options.table)throw new Error("Not supported yet");this.header="",this.options.compact||(this.header=document.createElement("label"),this.header.textContent=this.getTitle()),this.title=this.theme.getHeader(this.header,this.getPathDepth()),this.title.classList.add("je-object__title"),this.controls=this.theme.getButtonHolder(),this.controls.classList.add("je-object__controls"),this.container.appendChild(this.title),this.container.appendChild(this.controls),this.container.classList.add("je-object__container"),this.editjson_holder=this.theme.getModal(),this.editjson_textarea=this.theme.getTextareaInput(),this.editjson_textarea.classList.add("je-edit-json--textarea"),this.editjson_save=this.getButton("button_save","save","button_save"),this.editjson_save.classList.add("json-editor-btntype-save"),this.editjson_save.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.saveJSON()}),this.editjson_copy=this.getButton("button_copy","copy","button_copy"),this.editjson_copy.classList.add("json-editor-btntype-copy"),this.editjson_copy.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.copyJSON()}),this.editjson_cancel=this.getButton("button_cancel","cancel","button_cancel"),this.editjson_cancel.classList.add("json-editor-btntype-cancel"),this.editjson_cancel.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.hideEditJSON()}),this.editjson_holder.appendChild(this.editjson_textarea),this.editjson_holder.appendChild(this.editjson_save),this.editjson_holder.appendChild(this.editjson_copy),this.editjson_holder.appendChild(this.editjson_cancel),this.addproperty_holder=this.theme.getModal(),this.addproperty_list=document.createElement("div"),this.addproperty_list.classList.add("property-selector"),this.addproperty_add=this.getButton("button_add","add","button_add"),this.addproperty_add.classList.add("json-editor-btntype-add"),this.addproperty_input=this.theme.getFormInputField("text"),this.addproperty_input.setAttribute("placeholder","Property name..."),this.addproperty_input.classList.add("property-selector-input"),this.addproperty_add.addEventListener("click",function(u){if(u.preventDefault(),u.stopPropagation(),t.addproperty_input.value){if(t.editors[t.addproperty_input.value])return void window.alert("there is already a property with that name");t.addObjectProperty(t.addproperty_input.value),t.editors[t.addproperty_input.value]&&t.editors[t.addproperty_input.value].disable(),t.onChange(!0)}}),this.addproperty_input.addEventListener("input",function(u){u.target.previousSibling.childNodes.forEach(function(d){var x=d.innerText,P=u.target.value;t.options.case_sensitive_property_search||t.jsoneditor.options.case_sensitive_property_search||(x=x.toLowerCase(),P=P.toLowerCase()),x.includes(P)?d.style.display="":d.style.display="none"})}),this.addproperty_holder.appendChild(this.addproperty_list),this.addproperty_holder.appendChild(this.addproperty_input),this.addproperty_holder.appendChild(this.addproperty_add);var o=document.createElement("div");o.style.clear="both",this.addproperty_holder.appendChild(o),this.onOutsideModalClickListener=this.onOutsideModalClick.bind(this),document.addEventListener("click",this.onOutsideModalClickListener,!0),this.schema.description&&(this.description=this.theme.getDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.description)),this.error_holder=document.createElement("div"),this.container.appendChild(this.error_holder),this.editor_holder=this.theme.getIndentedPanel(),this.container.appendChild(this.editor_holder),this.row_container=this.theme.getGridContainer(),e?(this.tabs_holder=this.theme.getTopTabHolder(this.getValidId(this.translateProperty(this.schema.title))),this.tabPanesContainer=this.theme.getTopTabContentHolder(this.tabs_holder),this.editor_holder.appendChild(this.tabs_holder)):(this.tabs_holder=this.theme.getTabHolder(this.getValidId(this.translateProperty(this.schema.title))),this.tabPanesContainer=this.theme.getTabContentHolder(this.tabs_holder),this.editor_holder.appendChild(this.row_container)),Object.values(this.editors).forEach(function(u){var d=t.theme.getTabContent(),x=t.theme.getGridColumn(),P=!(!u.schema||u.schema.type!=="object"&&u.schema.type!=="array");if(d.isObjOrArray=P,e){if(P){var D=t.theme.getGridContainer();D.appendChild(x),d.appendChild(D),t.tabPanesContainer.appendChild(d),t.row_container=D}else t.row_container_basic===void 0&&(t.row_container_basic=t.theme.getGridContainer(),d.appendChild(t.row_container_basic),t.tabPanesContainer.childElementCount===0?t.tabPanesContainer.appendChild(d):t.tabPanesContainer.insertBefore(d,t.tabPanesContainer.childNodes[1])),t.row_container_basic.appendChild(x);t.addRow(u,t.tabs_holder,d),d.id=t.getValidId(u.schema.title)}else t.row_container.appendChild(x);u.setContainer(x),u.build(),u.postBuild(),u.setOptInCheckbox(u.header)}),this.rows[0]&&O(this.rows[0].tab,"click"),this.collapsed=!1,this.collapse_control=this.getButton("","collapse","button_collapse"),this.collapse_control.classList.add("json-editor-btntype-toggle"),this.title.insertBefore(this.collapse_control,this.title.childNodes[0]),this.collapse_control.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.collapsed?(t.editor_holder.style.display="",t.collapsed=!1,t.setButtonText(t.collapse_control,"","collapse","button_collapse")):(t.editor_holder.style.display="none",t.collapsed=!0,t.setButtonText(t.collapse_control,"","expand","button_expand"))}),this.options.collapsed&&O(this.collapse_control,"click"),this.schema.options&&this.schema.options.disable_collapse!==void 0?this.schema.options.disable_collapse&&(this.collapse_control.style.display="none"):this.jsoneditor.options.disable_collapse&&(this.collapse_control.style.display="none"),this.editjson_control=this.getButton("JSON","edit","button_edit_json"),this.editjson_control.classList.add("json-editor-btntype-editjson"),this.editjson_control.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.toggleEditJSON()}),this.controls.appendChild(this.editjson_control),this.controls.insertBefore(this.editjson_holder,this.controls.childNodes[0]),this.schema.options&&this.schema.options.disable_edit_json!==void 0?this.schema.options.disable_edit_json&&(this.editjson_control.style.display="none"):this.jsoneditor.options.disable_edit_json&&(this.editjson_control.style.display="none"),this.addproperty_button=this.getButton("properties","edit_properties","button_object_properties"),this.addproperty_button.classList.add("json-editor-btntype-properties"),this.addproperty_button.addEventListener("click",function(u){u.preventDefault(),u.stopPropagation(),t.toggleAddProperty()}),this.controls.appendChild(this.addproperty_button),this.controls.insertBefore(this.addproperty_holder,this.controls.childNodes[1]),this.refreshAddProperties(),this.deactivateNonRequiredProperties()}this.options.table_row?(this.editor_holder=this.container,this.property_order.forEach(function(u){t.editor_holder.appendChild(t.editors[u].container)})):(this.layoutEditors(),this.layoutEditors())}},{key:"deactivateNonRequiredProperties",value:function(){var t=this,e=this.jsoneditor.options.show_opt_in,o=this.options.show_opt_in!==void 0,u=o&&this.options.show_opt_in===!0,d=o&&this.options.show_opt_in===!1;(u||!d&&e||!o&&e)&&Object.entries(this.editors).forEach(function(x){var P=En(x,2),D=P[0],J=P[1];t.isRequiredObject(J)||t.editors[D].deactivate()})}},{key:"showEditJSON",value:function(){this.editjson_holder&&(this.hideAddProperty(),this.editjson_holder.style.left="".concat(this.editjson_control.offsetLeft,"px"),this.editjson_holder.style.top="".concat(this.editjson_control.offsetTop+this.editjson_control.offsetHeight,"px"),this.editjson_textarea.value=JSON.stringify(this.getValue(),null,2),this.disable(),this.editjson_holder.style.display="",this.editjson_control.disabled=!1,this.editing_json=!0)}},{key:"hideEditJSON",value:function(){this.editjson_holder&&this.editing_json&&(this.editjson_holder.style.display="none",this.enable(),this.editing_json=!1)}},{key:"copyJSON",value:function(){if(this.editjson_holder){var t=document.createElement("textarea");t.value=this.editjson_textarea.value,t.setAttribute("readonly",""),t.style.position="absolute",t.style.left="-9999px",document.body.appendChild(t),t.select(),document.execCommand("copy"),document.body.removeChild(t)}}},{key:"saveJSON",value:function(){if(this.editjson_holder)try{var t=JSON.parse(this.editjson_textarea.value);this.setValue(t),this.hideEditJSON(),this.onChange(!0)}catch(e){throw window.alert("invalid JSON"),e}}},{key:"toggleEditJSON",value:function(){this.editing_json?this.hideEditJSON():this.showEditJSON()}},{key:"insertPropertyControlUsingPropertyOrder",value:function(t,e,o){var u;this.schema.properties[t]&&(u=this.schema.properties[t].propertyOrder),typeof u!="number"&&(u=1e3),e.propertyOrder=u;for(var d=0;d<o.childNodes.length;d++){var x=o.childNodes[d];if(e.propertyOrder<x.propertyOrder){this.addproperty_list.insertBefore(e,x),e=null;break}}e&&this.addproperty_list.appendChild(e)}},{key:"addPropertyCheckbox",value:function(t){var e,o=this,u=this.theme.getCheckbox();e=this.schema.properties[t]&&this.schema.properties[t].title?this.schema.properties[t].title:t;var d=this.theme.getCheckboxLabel(e),x=this.theme.getFormControl(d,u);return x.style.paddingBottom=x.style.marginBottom=x.style.paddingTop=x.style.marginTop=0,x.style.height="auto",this.insertPropertyControlUsingPropertyOrder(t,x,this.addproperty_list),u.checked=t in this.editors,u.addEventListener("change",function(){u.checked?o.addObjectProperty(t):o.removeObjectProperty(t),o.onChange(!0)}),this.addproperty_checkboxes[t]=u,u}},{key:"showAddProperty",value:function(){this.addproperty_holder&&(this.hideEditJSON(),this.addproperty_holder.style.left="".concat(this.addproperty_button.offsetLeft,"px"),this.addproperty_holder.style.top="".concat(this.addproperty_button.offsetTop+this.addproperty_button.offsetHeight,"px"),this.disable(),this.adding_property=!0,this.addproperty_button.disabled=!1,this.addproperty_holder.style.display="",this.refreshAddProperties())}},{key:"hideAddProperty",value:function(){this.addproperty_holder&&this.adding_property&&(this.addproperty_holder.style.display="none",this.enable(),this.adding_property=!1)}},{key:"toggleAddProperty",value:function(){this.adding_property?this.hideAddProperty():this.showAddProperty()}},{key:"removeObjectProperty",value:function(t){this.editors[t]&&(this.editors[t].unregister(),delete this.editors[t],this.refreshValue(),this.layoutEditors())}},{key:"getSchemaOnMaxDepth",value:function(t){return Object.keys(t).reduce(function(e,o){switch(o){case"$ref":return e;case"properties":case"items":return cn(cn({},e),{},yi({},o,{}));case"additionalProperties":case"propertyNames":return cn(cn({},e),{},yi({},o,!0));default:return cn(cn({},e),{},yi({},o,t[o]))}},{})}},{key:"addObjectProperty",value:function(t,e){if(!this.editors[t]){if(this.cached_editors[t]){if(this.editors[t]=this.cached_editors[t],e)return;this.editors[t].register()}else{if(!(this.canHaveAdditionalProperties()||this.schema.properties&&this.schema.properties[t]||this.schema.patternProperties&&Object.keys(this.schema.patternProperties).find(function(P){return new RegExp(P).test(t)})))return;var o=this.getPropertySchema(t);typeof o.propertyOrder!="number"&&(o.propertyOrder=Object.keys(this.editors).length+1e3);var u=this.jsoneditor.getEditorClass(o),d=this.jsoneditor.options.max_depth;if(this.editors[t]=this.jsoneditor.createEditor(u,{jsoneditor:this.jsoneditor,schema:d&&this.currentDepth>=d?this.getSchemaOnMaxDepth(o):o,path:"".concat(this.path,".").concat(t),parent:this},this.currentDepth+1),this.editors[t].preBuild(),!e){var x=this.theme.getChildEditorHolder();this.editor_holder.appendChild(x),this.editors[t].setContainer(x),this.editors[t].build(),this.editors[t].postBuild(),this.editors[t].setOptInCheckbox(u.header),this.editors[t].activate()}this.cached_editors[t]=this.editors[t]}e||(this.refreshValue(),this.layoutEditors())}}},{key:"onOutsideModalClick",value:function(t){var e=t.path||t.composedPath&&t.composedPath();this.addproperty_holder&&!this.addproperty_holder.contains(e[0])&&this.adding_property&&(t.preventDefault(),t.stopPropagation(),this.toggleAddProperty())}},{key:"onChildEditorChange",value:function(t){this.refreshValue(),Ar(vr(l.prototype),"onChildEditorChange",this).call(this,t)}},{key:"canHaveAdditionalProperties",value:function(){return typeof this.schema.additionalProperties=="boolean"?this.schema.additionalProperties:Br(this.schema.additionalProperties)==="object"&&this.schema.additionalProperties!==null||(typeof this.options.no_additional_properties=="boolean"?!this.options.no_additional_properties:typeof this.jsoneditor.options.no_additional_properties!="boolean"||!this.jsoneditor.options.no_additional_properties)}},{key:"destroy",value:function(){Object.values(this.cached_editors).forEach(function(t){return t.destroy()}),this.editor_holder&&(this.editor_holder.innerHTML=""),this.title&&this.title.parentNode&&this.title.parentNode.removeChild(this.title),this.error_holder&&this.error_holder.parentNode&&this.error_holder.parentNode.removeChild(this.error_holder),this.editors=null,this.cached_editors=null,this.editor_holder&&this.editor_holder.parentNode&&this.editor_holder.parentNode.removeChild(this.editor_holder),this.editor_holder=null,document.removeEventListener("click",this.onOutsideModalClickListener,!0),Ar(vr(l.prototype),"destroy",this).call(this)}},{key:"getValue",value:function(){if(this.dependenciesFulfilled){var t=Ar(vr(l.prototype),"getValue",this).call(this);return t&&(this.jsoneditor.options.remove_empty_properties||this.options.remove_empty_properties)&&Object.keys(t).forEach(function(e){var o;((o=t[e])===void 0||o===""||o===Object(o)&&Object.keys(o).length===0&&o.constructor===Object)&&delete t[e]}),t}}},{key:"refreshValue",value:function(){var t=this;this.value={},this.editors&&(Object.keys(this.editors).forEach(function(e){t.editors[e].isActive()&&(t.editors[e].refreshValue(),t.value[e]=t.editors[e].getValue())}),Object.keys(this.editors).forEach(function(e){t.editors[e].isActive()&&t.activateDependentRequired(t.editors[e].key)}),this.adding_property&&this.refreshAddProperties())}},{key:"activateDependentRequired",value:function(t){var e=this;this.getDependentRequired(t).forEach(function(o){var u;Object.entries(e.cached_editors).forEach(function(d){var x=En(d,2),P=(x[0],x[1]);P.key===o&&(u=P)}),u&&!u.isActive()&&u.activate()})}},{key:"getDependentRequired",value:function(t){return this.schema.dependentRequired&&S(this.schema.dependentRequired,t)?this.schema.dependentRequired[t]:[]}},{key:"refreshAddProperties",value:function(){var t=this;if(this.options.disable_properties||this.options.disable_properties!==!1&&this.jsoneditor.options.disable_properties)this.addproperty_button.style.display="none";else{var e,o=0,u=!1;Object.keys(this.editors).forEach(function(d){return o++}),e=this.canHaveAdditionalProperties()&&!(this.schema.maxProperties!==void 0&&o>=this.schema.maxProperties),this.addproperty_checkboxes&&(this.addproperty_list.innerHTML=""),this.addproperty_checkboxes={},Object.keys(this.cached_editors).forEach(function(d){t.addPropertyCheckbox(d),t.isRequiredObject(t.cached_editors[d])&&d in t.editors&&(t.addproperty_checkboxes[d].disabled=!0),t.schema.minProperties!==void 0&&o<=t.schema.minProperties?(t.addproperty_checkboxes[d].disabled=t.addproperty_checkboxes[d].checked,t.addproperty_checkboxes[d].checked||(u=!0)):d in t.editors?u=!0:e||S(t.schema.properties,d)?(t.addproperty_checkboxes[d].disabled=!1,u=!0):t.addproperty_checkboxes[d].disabled=!0}),this.canHaveAdditionalProperties()&&(u=!0),Object.keys(this.schema.properties).forEach(function(d){t.cached_editors[d]||(u=!0,t.addPropertyCheckbox(d))}),u?this.canHaveAdditionalProperties()?this.addproperty_add.disabled=!e:(this.addproperty_add.style.display="none",this.addproperty_input.style.display="none"):(this.hideAddProperty(),this.addproperty_button.style.display="none")}}},{key:"isRequiredObject",value:function(t){if(t)return typeof t.schema.required=="boolean"?t.schema.required:Array.isArray(this.schema.required)?this.schema.required.includes(t.key):!!this.jsoneditor.options.required_by_default}},{key:"setValue",value:function(t,e){var o=this;(Br(t=t||{})!=="object"||Array.isArray(t))&&(t={}),Object.entries(this.cached_editors).forEach(function(u){var d=En(u,2),x=d[0],P=d[1];t[x]!==void 0?(o.addObjectProperty(x),P.setValue(t[x],e),P.activate()):e||o.isRequiredObject(P)?P.setValue(P.getDefault(),e):o.jsoneditor.options.show_opt_in||o.options.show_opt_in?P.deactivate():o.removeObjectProperty(x)}),Object.entries(t).forEach(function(u){var d=En(u,2),x=d[0],P=d[1];o.cached_editors[x]||(o.addObjectProperty(x),o.editors[x]&&o.editors[x].setValue(P,e,!!o.editors[x].template))}),this.refreshValue(),this.layoutEditors(),this.onChange()}},{key:"showValidationErrors",value:function(t){var e=this,o=[],u=[];t.forEach(function(d){d.path===e.path?o.push(d):u.push(d)}),this.error_holder&&(o.length?(this.error_holder.innerHTML="",this.error_holder.style.display="",o.forEach(function(d){d.errorcount&&d.errorcount>1&&(d.message+=" (".concat(d.errorcount," errors)")),e.error_holder.appendChild(e.theme.getErrorMessage(d.message))})):this.error_holder.style.display="none"),this.options.table_row&&(o.length?this.theme.addTableRowError(this.container):this.theme.removeTableRowError(this.container)),Object.values(this.editors).forEach(function(d){d.showValidationErrors(u)})}}])&&ua(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F);function Wn(c){return Wn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Wn(c)}function vl(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Wn(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Wn(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Wn(h)==="symbol"?h:String(h)),i)}var h}function Zn(){return Zn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=V(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Zn.apply(this,arguments)}function ha(c,n){return ha=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ha(c,n)}function V(c){return V=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},V(c)}bi.rules={".je-object__title":"display:inline-block",".je-object__controls":"margin:0%200%200%2010px",".je-object__container":"position:relative",".je-object__property-checkbox":"margin:0;height:auto",".property-selector":"width:295px;max-height:160px;padding:5px%200;overflow-y:auto;overflow-x:hidden;padding-left:5px",".property-selector-input":"width:220px;margin-bottom:0;display:inline-block",".json-editor-btntype-toggle":"margin:0%2010px%200%200",".je-edit-json--textarea":"height:170px;width:300px;display:block"};var at=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ha(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=V(i);if(h){var o=V(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Wn(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"preBuild",value:function(){Zn(V(l.prototype),"preBuild",this).call(this)}},{key:"build",value:function(){var t=this;this.label="",this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.radioContainer=document.createElement("div"),this.radioGroup=[];for(var e=function(J){t.setValue(J.currentTarget.value),t.onChange(!0)},o=0;o<this.enum_values.length;o++){var u={id:"".concat(this.formname,"[").concat(o,"]"),value:this.enum_values[o]};this.jsoneditor.options.use_name_attributes&&(u.name=this.formname),this.input=this.theme.getFormRadio(u),this.setInputAttributes(["id","value","name"]),this.input.addEventListener("change",e,!1),this.radioGroup.push(this.input);var d=this.theme.getFormRadioLabel(this.enum_display[o]);d.htmlFor=this.input.id;var x=this.theme.getFormRadioControl(d,this.input,!(this.options.layout!=="horizontal"&&!this.options.compact));this.radioContainer.appendChild(x)}if(this.schema.readOnly||this.schema.readonly){this.disable(!0);for(var P=0;P<this.radioGroup.length;P++)this.radioGroup[P].disabled=!0;this.radioContainer.classList.add("readonly")}var D=this.theme.getContainer();D.appendChild(this.radioContainer),D.dataset.containerFor="radio",this.input=D,this.control=this.theme.getFormControl(this.label,D,this.description,this.infoButton),this.container.appendChild(this.control),window.requestAnimationFrame(function(){t.input.parentNode&&t.afterInputReady()})}},{key:"enable",value:function(){if(!this.always_disabled){for(var t=0;t<this.radioGroup.length;t++)this.radioGroup[t].disabled=!1;this.radioContainer.classList.remove("readonly"),Zn(V(l.prototype),"enable",this).call(this)}}},{key:"disable",value:function(t){t&&(this.always_disabled=!0);for(var e=0;e<this.radioGroup.length;e++)this.radioGroup[e].disabled=!0;this.radioContainer.classList.add("readonly"),Zn(V(l.prototype),"disable",this).call(this)}},{key:"destroy",value:function(){this.radioContainer.parentNode&&this.radioContainer.parentNode.parentNode&&this.radioContainer.parentNode.parentNode.removeChild(this.radioContainer.parentNode),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),Zn(V(l.prototype),"destroy",this).call(this)}},{key:"getNumColumns",value:function(){return 2}},{key:"setValue",value:function(t){typeof t!="string"&&(t=String(t));for(var e=0;e<this.radioGroup.length;e++)if(this.radioGroup[e].value===t){this.radioGroup[e].checked=!0,this.value=t,this.onChange();break}}}])&&vl(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function Ot(c){return Ot=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ot(c)}function ve(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Ot(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Ot(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Ot(h)==="symbol"?h:String(h)),i)}var h}function we(){return we=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=He(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},we.apply(this,arguments)}function le(c,n){return le=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},le(c,n)}function He(c){return He=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},He(c)}var ao=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&le(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=He(i);if(h){var o=He(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Ot(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=we(He(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.sceditor_instance&&this.sceditor_instance.val(u.value)}},{key:"build",value:function(){this.options.format="textarea",we(He(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t=this;if(window.sceditor){var e=this.expandCallbacks("sceditor",k({},{format:this.input_type,emoticonsEnabled:!1,width:"100%",height:300,readOnly:this.schema.readOnly||this.schema.readonly||this.schema.template},this.defaults.options.sceditor||{},this.options.sceditor||{},{element:this.input})),o=window.sceditor.instance(this.input);o===void 0&&window.sceditor.create(this.input,e),this.sceditor_instance=o||window.sceditor.instance(this.input),this.sceditor_instance.blur(function(){t.value=t.sceditor_instance.val(),t.sceditor_instance.updateOriginal(),t.is_dirty=!0,t.onChange(!0)}),this.theme.afterInputReady(this.input)}else we(He(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.sceditor_instance&&this.sceditor_instance.readOnly(!1),we(He(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.sceditor_instance&&this.sceditor_instance.readOnly(!0),we(He(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.sceditor_instance&&(this.sceditor_instance.destroy(),this.sceditor_instance=null),we(He(l.prototype),"destroy",this).call(this)}}])&&ve(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function so(c){return so=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},so(c)}function Fp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(so(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(so(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),so(h)==="symbol"?h:String(h)),i)}var h}function vi(){return vi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=un(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},vi.apply(this,arguments)}function gl(c,n){return gl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},gl(c,n)}function un(c){return un=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},un(c)}var Vp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&gl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=un(i);if(h){var o=un(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(so(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){if(this.select2_instance){e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0);var o=this.updateValue(t);this.input.value=o,this.select2v4?this.select2_instance.val(o).trigger("change"):this.select2_instance.select2("val",o),this.onChange(!0)}else vi(un(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t=this;if(window.jQuery&&window.jQuery.fn&&window.jQuery.fn.select2&&!this.select2_instance){var e=this.expandCallbacks("select2",k({},this.defaults.options.select2||{},this.options.select2||{}));this.newEnumAllowed=e.tags=!!e.tags&&this.schema.type==="string",this.select2_instance=window.jQuery(this.input).select2(e),this.select2v4=S(this.select2_instance.select2,"amd"),this.selectChangeHandler=function(){var o=t.select2v4?t.select2_instance.val():t.select2_instance.select2("val");t.updateValue(o),t.onChange(!0)},this.select2_instance.on("change",this.selectChangeHandler),this.select2_instance.on("select2-blur",this.selectChangeHandler)}vi(un(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){var e=this.enum_values[0];return t=this.typecast(t||""),this.enum_values.includes(t)?e=t:this.newEnumAllowed&&(e=this.addNewOption(t)?t:e),this.value=e,e}},{key:"addNewOption",value:function(t){var e,o=this.typecast(t),u=!1;return this.enum_values.includes(o)||o===""||(this.enum_options.push("".concat(o)),this.enum_display.push("".concat(o)),this.enum_values.push(o),this.schema.enum.push(o),(e=this.input.querySelector('option[value="'.concat(o,'"]')))?e.removeAttribute("data-select2-tag"):this.input.appendChild(new Option(o,o,!1,!1)).trigger("change"),u=!0),u}},{key:"enable",value:function(){this.always_disabled||this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!1):this.select2_instance.select2("enable",!0)),vi(un(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.select2_instance&&(this.select2v4?this.select2_instance.prop("disabled",!0):this.select2_instance.select2("enable",!1)),vi(un(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.select2_instance&&(this.select2_instance.select2("destroy"),this.select2_instance=null),vi(un(l.prototype),"destroy",this).call(this)}}])&&Fp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function lo(c){return lo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},lo(c)}function zp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(lo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(lo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),lo(h)==="symbol"?h:String(h)),i)}var h}function Jn(){return Jn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Qr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Jn.apply(this,arguments)}function wl(c,n){return wl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},wl(c,n)}function Qr(c){return Qr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qr(c)}var Up=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&wl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Qr(i);if(h){var o=Qr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(lo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e){if(this.selectize_instance){e?this.is_dirty=!1:this.jsoneditor.options.show_errors==="change"&&(this.is_dirty=!0);var o=this.updateValue(t);this.input.value=o,this.selectize_instance.clear(!0),this.selectize_instance.setValue(o),this.onChange(!0)}else Jn(Qr(l.prototype),"setValue",this).call(this,t,e)}},{key:"afterInputReady",value:function(){var t=this;if(window.jQuery&&window.jQuery.fn&&window.jQuery.fn.selectize&&!this.selectize_instance){var e=this.expandCallbacks("selectize",k({},this.defaults.options.selectize||{},this.options.selectize||{}));this.newEnumAllowed=e.create=!!e.create&&this.schema.type==="string",this.selectize_instance=window.jQuery(this.input).selectize(e)[0].selectize,this.control.removeEventListener("change",this.multiselectChangeHandler),this.multiselectChangeHandler=function(o){t.updateValue(o),t.onChange(!0)},this.selectize_instance.on("change",this.multiselectChangeHandler)}Jn(Qr(l.prototype),"afterInputReady",this).call(this)}},{key:"updateValue",value:function(t){var e=this.enum_values[0];return t=this.typecast(t||""),this.enum_values.includes(t)?e=t:this.newEnumAllowed&&(e=this.addNewOption(t)?t:e),this.value=e,e}},{key:"addNewOption",value:function(t){var e=this.typecast(t),o=!1;return this.enum_values.includes(e)||e===""||(this.enum_options.push("".concat(e)),this.enum_display.push("".concat(e)),this.enum_values.push(e),this.schema.enum.push(e),this.selectize_instance.addItem(e),this.selectize_instance.refreshOptions(!1),o=!0),o}},{key:"onWatchedFieldChange",value:function(){var t=this;Jn(Qr(l.prototype),"onWatchedFieldChange",this).call(this),this.selectize_instance&&(this.selectize_instance.clear(!0),this.selectize_instance.clearOptions(!0),this.enum_options.forEach(function(e,o){t.selectize_instance.addOption({value:e,text:t.enum_display[o]})}),this.selectize_instance.addItem("".concat(this.value),!0))}},{key:"enable",value:function(){!this.always_disabled&&this.selectize_instance&&this.selectize_instance.unlock(),Jn(Qr(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.selectize_instance&&this.selectize_instance.lock(),Jn(Qr(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.selectize_instance&&(this.selectize_instance.destroy(),this.selectize_instance=null),Jn(Qr(l.prototype),"destroy",this).call(this)}}])&&zp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(hi);function co(c){return co=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},co(c)}function qp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(co(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(co(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),co(h)==="symbol"?h:String(h)),i)}var h}function _l(c,n){return _l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},_l(c,n)}function ws(c){return ws=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ws(c)}var Gp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&_l(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=ws(i);if(h){var o=ws(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(co(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){var t=this;this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description)));var e=this.formname.replace(/\W/g,"");if(typeof SignaturePad=="function"){this.input=this.theme.getFormInputField("hidden"),this.container.appendChild(this.input);var o=document.createElement("div");o.classList.add("signature-container");var u=document.createElement("canvas");this.jsoneditor.options.use_name_attributes&&u.setAttribute("name",e),u.classList.add("signature"),o.appendChild(u),this.signaturePad=new window.SignaturePad(u),this.signaturePad.onEnd=function(){t.signaturePad.isEmpty()?t.input.value="":t.input.value=t.signaturePad.toDataURL(),t.is_dirty=!0,t.refreshValue(),t.watch_listener(),t.jsoneditor.notifyWatchers(t.path),t.parent?t.parent.onChildEditorChange(t):t.jsoneditor.onChange()};var d=document.createElement("div"),x=document.createElement("button");x.classList.add("tiny","button"),x.innerHTML="Clear signature",d.appendChild(x),o.appendChild(d),this.options.compact&&this.container.setAttribute("class","".concat(this.container.getAttribute("class")," compact")),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),Array.from(this.inputs).forEach(function(D){u.setAttribute("readOnly","readOnly"),D.disabled=!0})),x.addEventListener("click",function(D){D.preventDefault(),D.stopPropagation(),t.signaturePad.clear(),t.signaturePad.strokeEnd()}),this.control=this.theme.getFormControl(this.label,o,this.description),this.container.appendChild(this.control),this.refreshValue(),u.width=o.offsetWidth,this.options&&this.options.canvas_height?u.height=this.options.canvas_height:u.height="300"}else{var P=document.createElement("p");P.innerHTML="Signature pad is not available, please include SignaturePad from https://github.com/szimek/signature_pad",this.container.appendChild(P)}}},{key:"setValue",value:function(t){if(typeof SignaturePad=="function"){var e=this.sanitize(t);return this.value===e?void 0:(this.value=e,this.input.value=this.value,this.signaturePad.clear(),t&&t!==""&&this.signaturePad.fromDataURL(t),this.watch_listener(),this.jsoneditor.notifyWatchers(this.path),!1)}}},{key:"destroy",value:function(){this.signaturePad.off(),delete this.signaturePad}}])&&qp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function uo(c){return uo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},uo(c)}function Wp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(uo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(uo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),uo(h)==="symbol"?h:String(h)),i)}var h}function Yn(){return Yn=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=tn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Yn.apply(this,arguments)}function xl(c,n){return xl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},xl(c,n)}function tn(c){return tn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},tn(c)}_(2564);var Zp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&xl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=tn(i);if(h){var o=tn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(uo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"setValue",value:function(t,e,o){var u=Yn(tn(l.prototype),"setValue",this).call(this,t,e,o);u!==void 0&&u.changed&&this.simplemde_instance&&this.simplemde_instance.value(u.value)}},{key:"build",value:function(){this.options.format="textarea",Yn(tn(l.prototype),"build",this).call(this),this.input_type=this.schema.format,this.input.setAttribute("data-schemaformat",this.input_type)}},{key:"afterInputReady",value:function(){var t,e=this;window.SimpleMDE?(t=this.expandCallbacks("simplemde",k({},{height:300},this.defaults.options.simplemde||{},this.options.simplemde||{},{element:this.input,forceSync:!0})),this.simplemde_instance=new window.SimpleMDE(t),(this.schema.readOnly||this.schema.readonly||this.schema.template)&&(this.simplemde_instance.codemirror.options.readOnly=!0),this.simplemde_instance.codemirror.on("change",function(){e.value=e.simplemde_instance.value(),e.is_dirty=!0,e.onChange(!0)}),t.autorefresh&&this.startListening(this.simplemde_instance.codemirror,this.simplemde_instance.codemirror.state.autoRefresh={delay:250}),this.theme.afterInputReady(this.input)):Yn(tn(l.prototype),"afterInputReady",this).call(this)}},{key:"getNumColumns",value:function(){return 6}},{key:"enable",value:function(){!this.always_disabled&&this.simplemde_instance&&(this.simplemde_instance.codemirror.options.readOnly=!1),Yn(tn(l.prototype),"enable",this).call(this)}},{key:"disable",value:function(t){this.simplemde_instance&&(this.simplemde_instance.codemirror.options.readOnly=!0),Yn(tn(l.prototype),"disable",this).call(this,t)}},{key:"destroy",value:function(){this.simplemde_instance&&(this.simplemde_instance.toTextArea(),this.simplemde_instance=null),Yn(tn(l.prototype),"destroy",this).call(this)}},{key:"startListening",value:function(t,e){function o(){t.display.wrapper.offsetHeight?(this.stopListening(t,e),t.display.lastWrapHeight!==t.display.wrapper.clientHeight&&t.refresh()):e.timeout=window.setTimeout(o,e.delay)}e.timeout=window.setTimeout(o,e.delay),e.hurry=function(){window.clearTimeout(e.timeout),e.timeout=window.setTimeout(o,50)},t.on(window,"mouseup",e.hurry),t.on(window,"keyup",e.hurry)}},{key:"stopListening",value:function(t,e){window.clearTimeout(e.timeout),t.off(window,"mouseup",e.hurry),t.off(window,"keyup",e.hurry)}}])&&Wp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function ho(c){return ho=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ho(c)}function Jp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ho(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ho(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ho(h)==="symbol"?h:String(h)),i)}var h}function kl(){return kl=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=po(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},kl.apply(this,arguments)}function jl(c,n){return jl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},jl(c,n)}function po(c){return po=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},po(c)}var Su=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&jl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=po(i);if(h){var o=po(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(ho(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){var t=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.compact&&this.container.classList.add("compact"),this.ratingContainer=document.createElement("div"),this.ratingContainer.classList.add("starrating"),this.schema.enum===void 0){var e=this.schema.maximum?this.schema.maximum:5;this.schema.exclusiveMaximum&&e--,this.enum_values=[];for(var o=0;o<e;o++)this.enum_values.push(o+1)}else this.enum_values=this.schema.enum;this.radioGroup=[];for(var u=function(ut){ut.preventDefault(),ut.stopPropagation(),t.setValue(ut.currentTarget.value),t.onChange(!0)},d=this.enum_values.length-1;d>-1;d--){var x=this.formname+(d+1),P=this.theme.getFormInputField("radio");P.name="".concat(this.formname,"[starrating]"),P.value=this.enum_values[d],P.id=x,P.addEventListener("change",u,!1),this.radioGroup.push(P);var D=document.createElement("label");D.htmlFor=x,D.title=this.enum_values[d],this.options.displayValue&&D.classList.add("starrating-display-enabled"),this.ratingContainer.appendChild(P),this.ratingContainer.appendChild(D)}if(this.options.displayValue&&(this.displayRating=document.createElement("div"),this.displayRating.classList.add("starrating-display"),this.displayRating.innerText=this.enum_values[0],this.ratingContainer.appendChild(this.displayRating)),this.schema.readOnly||this.schema.readonly){this.disable(!0);for(var J=0;J<this.radioGroup.length;J++)this.radioGroup[J].disabled=!0;this.ratingContainer.classList.add("readonly")}var nt=this.theme.getContainer();nt.appendChild(this.ratingContainer),this.input=nt,this.control=this.theme.getFormControl(this.label,nt,this.description,this.infoButton),this.container.appendChild(this.control),this.refreshValue()}},{key:"enable",value:function(){if(!this.always_disabled){for(var t=0;t<this.radioGroup.length;t++)this.radioGroup[t].disabled=!1;this.ratingContainer.classList.remove("readonly"),this.disabled=!1}}},{key:"disable",value:function(t){t&&(this.always_disabled=!0);for(var e=0;e<this.radioGroup.length;e++)this.radioGroup[e].disabled=!0;this.ratingContainer.classList.add("readonly"),this.disabled=!0}},{key:"destroy",value:function(){this.ratingContainer.parentNode&&this.ratingContainer.parentNode.parentNode&&this.ratingContainer.parentNode.parentNode.removeChild(this.ratingContainer.parentNode),this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),kl(po(l.prototype),"destroy",this).call(this)}},{key:"getNumColumns",value:function(){return 2}},{key:"getValue",value:function(){if(this.dependenciesFulfilled)return this.schema.type==="integer"?this.value===""?void 0:1*this.value:this.value}},{key:"setValue",value:function(t){for(var e=0;e<this.radioGroup.length;e++)if(this.radioGroup[e].value==="".concat(t)){this.radioGroup[e].checked=!0,this.value=t,this.options.displayValue&&(this.displayRating.innerHTML=this.value),this.onChange(!0);break}}}])&&Jp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K);function fo(c){return fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},fo(c)}function Yp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(fo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(fo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),fo(h)==="symbol"?h:String(h)),i)}var h}function da(){return da=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Xn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},da.apply(this,arguments)}function Ol(c,n){return Ol=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ol(c,n)}function Xn(c){return Xn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Xn(c)}Su.rules={".starrating":"direction:rtl;display:inline-block;white-space:nowrap",".starrating > input":"display:none",".starrating > label:before":"content:'%5C2606';margin:1px;font-size:18px;font-style:normal;font-weight:400;line-height:1;font-family:'Arial';display:inline-block",".starrating > label":"color:%23888;cursor:pointer;margin:8px%200%202px%200",".starrating > label.starrating-display-enabled":"margin:1px%200%200%200",".starrating > input:checked ~ label":"color:%23ffca08",".starrating:not(.readonly) > input:hover ~ label":"color:%23ffca08",".starrating > input:checked ~ label:before":"content:'%5C2605';text-shadow:0%200%201px%20rgba(0%2C20%2C20%2C1)",".starrating:not(.readonly) > input:hover ~ label:before":"content:'%5C2605';text-shadow:0%200%201px%20rgba(0%2C20%2C20%2C1)",".starrating .starrating-display":"position:relative;direction:rtl;text-align:center;font-size:10px;line-height:0px"};var Xp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ol(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Xn(i);if(h){var o=Xn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(fo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"build",value:function(){da(Xn(l.prototype),"build",this).call(this),this.input.setAttribute("type","number"),this.input.getAttribute("step")||this.input.setAttribute("step","1");var t=this.theme.getStepperButtons(this.input);this.control.appendChild(t),this.stepperDown=this.control.querySelector(".stepper-down"),this.stepperUp=this.control.querySelector(".stepper-up")}},{key:"enable",value:function(){da(Xn(l.prototype),"enable",this).call(this),this.stepperDown.removeAttribute("disabled"),this.stepperUp.removeAttribute("disabled")}},{key:"disable",value:function(){da(Xn(l.prototype),"disable",this).call(this),this.stepperDown.setAttribute("disabled",!0),this.stepperUp.setAttribute("disabled",!0)}}])&&Yp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(bs);function mo(c){return mo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},mo(c)}function Kp(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(mo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(mo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),mo(h)==="symbol"?h:String(h)),i)}var h}function gi(){return gi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=hn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},gi.apply(this,arguments)}function El(c,n){return El=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},El(c,n)}function hn(c){return hn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},hn(c)}var Qp=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&El(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=hn(i);if(h){var o=hn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(mo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,f=[{key:"register",value:function(){if(gi(hn(l.prototype),"register",this).call(this),this.rows)for(var t=0;t<this.rows.length;t++)this.rows[t].register()}},{key:"unregister",value:function(){if(gi(hn(l.prototype),"unregister",this).call(this),this.rows)for(var t=0;t<this.rows.length;t++)this.rows[t].unregister()}},{key:"getNumColumns",value:function(){return Math.max(Math.min(12,this.width),3)}},{key:"preBuild",value:function(){var t=this.jsoneditor.expandRefs(this.schema.items||{});this.item_title=t.title||"row",this.item_default=t.default||null,this.item_has_child_editors=t.properties||t.items,this.width=12,this.array_controls_top=this.options.array_controls_top||this.jsoneditor.options.array_controls_top,gi(hn(l.prototype),"preBuild",this).call(this)}},{key:"build",value:function(){this.tableContainer=this.theme.getTableContainer(),this.table=this.theme.getTable(),this.tableContainer.appendChild(this.table),this.container.appendChild(this.tableContainer),this.thead=this.theme.getTableHead(),this.table.appendChild(this.thead),this.header_row=this.theme.getTableRow(),this.thead.appendChild(this.header_row),this.row_holder=this.theme.getTableBody(),this.table.appendChild(this.row_holder);var t=this.getElementEditor(0,!0);if(this.item_default=t.getDefault(),this.width=t.getNumColumns()+2,this.options.compact?(this.panel=document.createElement("div"),this.container.appendChild(this.panel)):(this.header=document.createElement("label"),this.header.textContent=this.getTitle(),this.title=this.theme.getHeader(this.header,this.getPathDepth()),this.container.appendChild(this.title),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText)),this.container.appendChild(this.infoButton)),this.title_controls=this.theme.getHeaderButtonHolder(),this.title.appendChild(this.title_controls),this.schema.description&&(this.description=this.theme.getDescription(this.translateProperty(this.schema.description)),this.container.appendChild(this.description)),this.panel=this.theme.getIndentedPanel(),this.container.appendChild(this.panel),this.error_holder=document.createElement("div"),this.panel.appendChild(this.error_holder)),this.panel.appendChild(this.tableContainer),this.controls=this.theme.getButtonHolder(),this.array_controls_top?this.title.appendChild(this.controls):this.panel.appendChild(this.controls),this.item_has_child_editors)for(var e=t.getChildEditors(),o=t.property_order||Object.keys(e),u=0;u<o.length;u++){var d=this.theme.getTableHeaderCell(e[o[u]].getTitle());e[o[u]].options.hidden&&(d.style.display="none"),this.header_row.appendChild(d)}else this.header_row.appendChild(this.theme.getTableHeaderCell(this.item_title));t.destroy(),this.row_holder.innerHTML="",this.controls_header_cell=this.theme.getTableHeaderCell(" "),this.controls_header_cell.setAttribute("aria-hidden","true"),this.header_row.appendChild(this.controls_header_cell),this.addControls()}},{key:"onChildEditorChange",value:function(t){this.refreshValue(),gi(hn(l.prototype),"onChildEditorChange",this).call(this)}},{key:"getItemDefault",value:function(){return k({},{default:this.item_default}).default}},{key:"getItemTitle",value:function(){return this.item_title}},{key:"getElementEditor",value:function(t,e){var o=k({},this.schema.items),u=this.jsoneditor.getEditorClass(o,this.jsoneditor),d=this.row_holder.appendChild(this.theme.getTableRow()),x=d;this.item_has_child_editors||(x=this.theme.getTableCell(),d.appendChild(x));var P=this.jsoneditor.createEditor(u,{jsoneditor:this.jsoneditor,schema:o,container:x,path:"".concat(this.path,".").concat(t),parent:this,compact:!0,table_row:!0});return P.preBuild(),e||(P.build(),P.postBuild(),P.controls_cell=d.appendChild(this.theme.getTableCell()),P.row=d,P.table_controls=this.theme.getButtonHolder(),P.controls_cell.appendChild(P.table_controls),P.table_controls.style.margin=0,P.table_controls.style.padding=0),P}},{key:"destroy",value:function(){this.innerHTML="",this.checkParent(this.title)&&this.title.parentNode.removeChild(this.title),this.checkParent(this.description)&&this.description.parentNode.removeChild(this.description),this.checkParent(this.row_holder)&&this.row_holder.parentNode.removeChild(this.row_holder),this.checkParent(this.table)&&this.table.parentNode.removeChild(this.table),this.checkParent(this.panel)&&this.panel.parentNode.removeChild(this.panel),this.rows=this.title=this.description=this.row_holder=this.table=this.panel=null,gi(hn(l.prototype),"destroy",this).call(this)}},{key:"ensureArraySize",value:function(t){if(Array.isArray(t)||(t=[t]),this.schema.minItems)for(;t.length<this.schema.minItems;)t.push(this.getItemDefault());return this.schema.maxItems&&t.length>this.schema.maxItems&&(t=t.slice(0,this.schema.maxItems)),t}},{key:"setValue",value:function(){var t=this,e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],o=arguments.length>1?arguments[1]:void 0;if(e=this.ensureArraySize(e),JSON.stringify(e)!==this.serialized){var u=!1;e.forEach(function(P,D){t.rows[D]?t.rows[D].setValue(P):(t.addRow(P),u=!0)});for(var d=e.length;d<this.rows.length;d++){var x=this.rows[d].container;this.item_has_child_editors||this.rows[d].row.parentNode.removeChild(this.rows[d].row),this.rows[d].destroy(),x.parentNode&&x.parentNode.removeChild(x),this.rows[d]=null,u=!0}this.rows=this.rows.slice(0,e.length),this.refreshValue(),(u||o)&&this.refreshRowButtons(),this.onChange()}}},{key:"refreshRowButtons",value:function(){var t=this,e=this.schema.minItems&&this.schema.minItems>=this.rows.length,o=this.schema.maxItems&&this.schema.maxItems<=this.rows.length,u=[];this.rows.forEach(function(nt,ut){if(nt.delete_button){var dt=!e;t.setButtonState(nt.delete_button,dt),u.push(dt)}if(nt.copy_button){var kt=!o;t.setButtonState(nt.copy_button,kt),u.push(kt)}if(nt.moveup_button){var Ct=ut!==0;t.setButtonState(nt.moveup_button,Ct),u.push(Ct)}if(nt.movedown_button){var Nt=ut!==t.rows.length-1;t.setButtonState(nt.movedown_button,Nt),u.push(Nt)}});var d=u.some(function(nt){return nt});this.rows.forEach(function(nt){return t.setButtonState(nt.controls_cell,d)}),this.setButtonState(this.controls_header_cell,d),this.setButtonState(this.table,this.value.length);var x=!(o||this.hide_add_button);this.setButtonState(this.add_row_button,x);var P=!(!this.value.length||e||this.hide_delete_last_row_buttons);this.setButtonState(this.delete_last_row_button,P);var D=!(this.value.length<=1||e||this.hide_delete_all_rows_buttons);this.setButtonState(this.remove_all_rows_button,D);var J=x||P||D;this.setButtonState(this.controls,J)}},{key:"refreshValue",value:function(){var t=this;this.value=[],this.rows.forEach(function(e,o){t.value[o]=e.getValue()}),this.serialized=JSON.stringify(this.value)}},{key:"addRow",value:function(t){var e=this.rows.length;this.rows[e]=this.getElementEditor(e);var o=this.rows[e].table_controls;return this.hide_delete_buttons||(this.rows[e].delete_button=this._createDeleteButton(e,o)),this.show_copy_button&&(this.rows[e].copy_button=this._createCopyButton(e,o)),this.hide_move_buttons||(this.rows[e].moveup_button=this._createMoveUpButton(e,o)),this.hide_move_buttons||(this.rows[e].movedown_button=this._createMoveDownButton(e,o)),t!==void 0&&this.rows[e].setValue(t),this.rows[e]}},{key:"_createDeleteButton",value:function(t,e){var o=this,u=this.getButton("","delete","button_delete_row_title_short");return u.classList.add("delete","json-editor-btntype-delete"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){if(d.preventDefault(),d.stopPropagation(),!o.askConfirmation())return!1;var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue(),D=o.getValue()[x];P.splice(x,1),o.setValue(P),o.onChange(!0),o.jsoneditor.trigger("deleteRow",D)}),e.appendChild(u),u}},{key:"_createCopyButton",value:function(t,e){var o=this,u=this.getButton("","copy","button_copy_row_title_short"),d=this.schema;return u.classList.add("copy","json-editor-btntype-copy"),u.setAttribute("data-i",t),u.addEventListener("click",function(x){x.preventDefault(),x.stopPropagation();var P=1*x.currentTarget.getAttribute("data-i"),D=o.getValue(),J=D[P];d.items.type==="string"&&d.items.format==="uuid"?J=R():d.items.type==="object"&&d.items.properties&&D.forEach(function(nt,ut){if(P===ut)for(var dt=0,kt=Object.keys(nt);dt<kt.length;dt++){var Ct=kt[dt];d.items.properties&&d.items.properties[Ct]&&d.items.properties[Ct].format==="uuid"&&((J=Object.assign({},D[P]))[Ct]=R())}}),D.splice(P+1,0,J),o.setValue(D),o.onChange(!0),o.jsoneditor.trigger("copyRow",o.rows[P+1])}),e.appendChild(u),u}},{key:"_createMoveUpButton",value:function(t,e){var o=this,u=this.getButton("","moveup","button_move_up_title");return u.classList.add("moveup","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue();P.splice(x-1,0,P.splice(x,1)[0]),o.setValue(P),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x-1])}),e.appendChild(u),u}},{key:"_createMoveDownButton",value:function(t,e){var o=this,u=this.getButton("","movedown","button_move_down_title");return u.classList.add("movedown","json-editor-btntype-move"),u.setAttribute("data-i",t),u.addEventListener("click",function(d){d.preventDefault(),d.stopPropagation();var x=1*d.currentTarget.getAttribute("data-i"),P=o.getValue();P.splice(x+1,0,P.splice(x,1)[0]),o.setValue(P),o.onChange(!0),o.jsoneditor.trigger("moveRow",o.rows[x+1])}),e.appendChild(u),u}},{key:"addControls",value:function(){var t=this;this.collapsed=!1,this.toggle_button=this._createToggleButton(),this.title_controls&&(this.title.insertBefore(this.toggle_button,this.title.childNodes[0]),this.toggle_button.addEventListener("click",function(e){e.preventDefault(),e.stopPropagation(),t.setButtonState(t.panel,t.collapsed),t.collapsed?(t.collapsed=!1,t.setButtonText(e.currentTarget,"","collapse","button_collapse")):(t.collapsed=!0,t.setButtonText(e.currentTarget,"","expand","button_expand"))}),this.options.collapsed&&O(this.toggle_button,"click"),this.schema.options&&this.schema.options.disable_collapse!==void 0?this.schema.options.disable_collapse&&(this.toggle_button.style.display="none"):this.jsoneditor.options.disable_collapse&&(this.toggle_button.style.display="none")),this.add_row_button=this._createAddRowButton(),this.delete_last_row_button=this._createDeleteLastRowButton(),this.remove_all_rows_button=this._createRemoveAllRowsButton()}},{key:"_createToggleButton",value:function(){var t=this.getButton("","collapse","button_collapse");return t.classList.add("json-editor-btntype-toggle"),t}},{key:"_createAddRowButton",value:function(){var t=this,e=this.getButton(this.getItemTitle(),"add","button_add_row_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-add"),e.addEventListener("click",function(o){o.preventDefault(),o.stopPropagation();var u=t.addRow();t.refreshValue(),t.refreshRowButtons(),t.onChange(!0),t.jsoneditor.trigger("addRow",u)}),this.controls.appendChild(e),e}},{key:"_createDeleteLastRowButton",value:function(){var t=this,e=this.getButton("button_delete_last","subtract","button_delete_last_title",[this.getItemTitle()]);return e.classList.add("json-editor-btntype-deletelast"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue(),d=u.pop();t.setValue(u),t.onChange(!0),t.jsoneditor.trigger("deleteRow",d)}),this.controls.appendChild(e),e}},{key:"_createRemoveAllRowsButton",value:function(){var t=this,e=this.getButton("button_delete_all","delete","button_delete_all_title");return e.classList.add("json-editor-btntype-deleteall"),e.addEventListener("click",function(o){if(o.preventDefault(),o.stopPropagation(),!t.askConfirmation())return!1;var u=t.getValue();t.setValue([]),t.onChange(!0),t.jsoneditor.trigger("deleteAllRows",u)}),this.controls.appendChild(e),e}}],f&&Kp(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Ut);function yo(c){return yo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},yo(c)}function tf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(yo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(yo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),yo(h)==="symbol"?h:String(h)),i)}var h}function pa(){return pa=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Kn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},pa.apply(this,arguments)}function Cl(c,n){return Cl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Cl(c,n)}function Kn(c){return Kn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Kn(c)}function bo(c){return bo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},bo(c)}function ef(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(bo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(bo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),bo(h)==="symbol"?h:String(h)),i)}var h}function fa(){return fa=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Qn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},fa.apply(this,arguments)}function Sl(c,n){return Sl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Sl(c,n)}function Qn(c){return Qn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Qn(c)}function vo(c){return vo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},vo(c)}function rf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(vo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(vo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),vo(h)==="symbol"?h:String(h)),i)}var h}function wi(){return wi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=dn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},wi.apply(this,arguments)}function Pl(c,n){return Pl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Pl(c,n)}function dn(c){return dn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},dn(c)}_(6977);var _s={ace:Et,array:Ut,arrayChoices:cr,arraySelect2:pr,arraySelectize:Ze,autocomplete:Dn,base64:Vi,button:hs,checkbox:ps,choices:rt,datetime:vt,describedBy:ir,enum:$e,hidden:fs,info:qi,integer:bs,ip:ra,jodit:vs,multiple:to,multiselect:qt,null:ca,number:ys,object:bi,radio:at,sceditor:ao,select:hi,select2:Vp,selectize:Up,signature:Gp,simplemde:Zp,starrating:Su,stepper:Xp,string:K,table:Qp,upload:function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Cl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Kn(i);if(h){var o=Kn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(yo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getNumColumns",value:function(){return 4}},{key:"build",value:function(){var t=this;if(this.options.compact||(this.header=this.label=this.theme.getFormInputLabel(this.getTitle(),this.isRequired())),this.schema.description&&(this.description=this.theme.getFormInputDescription(this.translateProperty(this.schema.description))),this.options.infoText&&(this.infoButton=this.theme.getInfoButton(this.translateProperty(this.options.infoText))),this.options.hidden&&(this.container.style.display="none"),this.options=this.expandCallbacks("upload",k({},{title:"Browse",icon:"",auto_upload:!1,hide_input:!1,enable_drag_drop:!1,drop_zone_text:"Drag & Drop file here",drop_zone_top:!1,alt_drop_zone:"",mime_type:"",max_upload_size:0,upload_handler:function(u,d,x,P){window.alert('No upload_handler defined for "'.concat(u.path,'". You must create your own handler to enable upload to server'))}},this.defaults.options.upload||{},this.options.upload||{})),this.options.mime_type=this.options.mime_type?[].concat(this.options.mime_type):[],this.input=this.theme.getFormInputField("hidden"),this.container.appendChild(this.input),!this.schema.readOnly&&!this.schema.readonly){if(typeof this.options.upload_handler!="function")throw new Error("Upload handler required for upload editor");if(this.uploader=this.theme.getFormInputField("file"),this.uploader.style.display="none",this.options.mime_type.length&&this.uploader.setAttribute("accept",this.options.mime_type),this.options.enable_drag_drop===!0&&this.options.hide_input===!0||(this.clickHandler=function(u){t.uploader.dispatchEvent(new window.MouseEvent("click",{view:window,bubbles:!0,cancelable:!1}))},this.browseButton=this.getButton(this.options.title,this.options.icon,this.options.title),this.browseButton.addEventListener("click",this.clickHandler),this.fileDisplay=this.theme.getFormInputField("input"),this.fileDisplay.setAttribute("readonly",!0),this.fileDisplay.value="No file selected.",this.fileDisplay.addEventListener("dblclick",this.clickHandler),this.fileUploadGroup=this.theme.getInputGroup(this.fileDisplay,[this.browseButton]),this.fileUploadGroup||(this.fileUploadGroup=document.createElement("div"),this.fileUploadGroup.appendChild(this.fileDisplay),this.fileUploadGroup.appendChild(this.browseButton))),this.options.enable_drag_drop===!0){if(this.options.alt_drop_zone!==""){if(this.altDropZone=document.querySelector(this.options.alt_drop_zone),!this.altDropZone)throw new Error('Error: alt_drop_zone selector "'.concat(this.options.alt_drop_zone,'" not found!'));this.dropZone=this.altDropZone}else this.dropZone=this.theme.getDropZone(this.options.drop_zone_text);this.dropZone&&(this.dropZone.classList.add("upload-dropzone"),this.dropZone.addEventListener("dblclick",this.clickHandler))}this.uploadHandler=function(u){u.preventDefault(),u.stopPropagation();var d=u.target.files||u.dataTransfer.files;if(d&&d.length)if(t.options.max_upload_size!==0&&d[0].size>t.options.max_upload_size)t.theme.addInputError(t.uploader,"".concat(t.translate("upload_max_size")," ").concat(t.options.max_upload_size));else if(t.options.mime_type.length===0||t.isValidMimeType(d[0].type,t.options.mime_type)){t.fileDisplay&&(t.fileDisplay.value=d[0].name);var x=new window.FileReader;x.onload=function(P){t.preview_value=P.target.result,t.refreshPreview(d),t.onChange(!0),x=null},x.readAsDataURL(d[0])}else t.theme.addInputError(t.uploader,"".concat(t.translate("upload_wrong_file_format")," ").concat(t.options.mime_type.toString()))},this.uploader.addEventListener("change",this.uploadHandler),this.dragHandler=function(u){var d=u.dataTransfer.items||u.dataTransfer.files,x=d&&d.length&&(t.options.mime_type.length===0||t.isValidMimeType(d[0].type,t.options.mime_type)),P=u.currentTarget.classList&&u.currentTarget.classList.contains("upload-dropzone")&&x;switch((u.currentTarget===window?"w_":"e_")+u.type){case"w_drop":case"w_dragover":P||(u.dataTransfer.dropEffect="none");break;case"e_dragenter":P?(t.dropZone.classList.add("valid-dropzone"),u.dataTransfer.dropEffect="copy"):t.dropZone.classList.add("invalid-dropzone");break;case"e_dragover":P&&(u.dataTransfer.dropEffect="copy");break;case"e_dragleave":t.dropZone.classList.remove("valid-dropzone","invalid-dropzone");break;case"e_drop":t.dropZone.classList.remove("valid-dropzone","invalid-dropzone"),P&&t.uploadHandler(u)}P||u.preventDefault()},this.options.enable_drag_drop===!0&&(["dragover","drop"].forEach(function(u){window.addEventListener(u,t.dragHandler,!0)}),["dragenter","dragover","dragleave","drop"].forEach(function(u){t.dropZone.addEventListener(u,t.dragHandler,!0)}))}this.preview=document.createElement("div"),this.control=this.input.controlgroup=this.theme.getFormControl(this.label,this.uploader||this.input,this.description,this.infoButton),this.uploader&&(this.uploader.controlgroup=this.control);var e=this.uploader||this.input,o=document.createElement("div");this.dropZone&&!this.altDropZone&&this.options.drop_zone_top===!0&&o.appendChild(this.dropZone),this.fileUploadGroup&&o.appendChild(this.fileUploadGroup),this.dropZone&&!this.altDropZone&&this.options.drop_zone_top!==!0&&o.appendChild(this.dropZone),o.appendChild(this.preview),e.parentNode.insertBefore(o,e.nextSibling),this.container.appendChild(this.control),window.requestAnimationFrame(function(){t.afterInputReady()})}},{key:"afterInputReady",value:function(){var t=this;if(this.value){var e=document.createElement("img");e.style.maxWidth="100%",e.style.maxHeight="100px",e.onload=function(o){t.preview.appendChild(e)},e.onerror=function(o){console.error("upload error",o,o.currentTarget)},e.src=this.container.querySelector("a").href}this.theme.afterInputReady(this.input)}},{key:"refreshPreview",value:function(t){var e=this;if(this.last_preview!==this.preview_value&&(this.last_preview=this.preview_value,this.preview.innerHTML="",this.preview_value)){var o=t[0],u=this.preview_value.match(/^data:([^;,]+)[;,]/);if(o.mimeType=u?u[1]:"unknown",o.size>0){var d=Math.floor(Math.log(o.size)/Math.log(1024));o.formattedSize="".concat(parseFloat((o.size/Math.pow(1024,d)).toFixed(2))," ").concat(["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][d])}else o.formattedSize="0 Bytes";var x=this.getButton("button_upload","upload","button_upload");x.addEventListener("click",function(P){P.preventDefault(),x.setAttribute("disabled","disabled"),e.theme.removeInputError(e.uploader),e.theme.getProgressBar&&(e.progressBar=e.theme.getProgressBar(),e.preview.appendChild(e.progressBar)),e.options.upload_handler(e.path,o,{success:function(D){e.setValue(D),e.parent?e.parent.onChildEditorChange(e):e.jsoneditor.onChange(),e.progressBar&&e.preview.removeChild(e.progressBar),x.removeAttribute("disabled")},failure:function(D){e.theme.addInputError(e.uploader,D),e.progressBar&&e.preview.removeChild(e.progressBar),x.removeAttribute("disabled")},updateProgress:function(D){e.progressBar&&(D?e.theme.updateProgressBar(e.progressBar,D):e.theme.updateProgressBarUnknown(e.progressBar))}})}),this.preview.appendChild(this.theme.getUploadPreview(o,x,this.preview_value)),this.options.auto_upload&&(x.dispatchEvent(new window.MouseEvent("click")),x.parentNode.removeChild(x))}}},{key:"enable",value:function(){this.always_disabled||(this.uploader&&(this.uploader.disabled=!1),pa(Kn(l.prototype),"enable",this).call(this))}},{key:"disable",value:function(t){t&&(this.always_disabled=!0),this.uploader&&(this.uploader.disabled=!0),pa(Kn(l.prototype),"disable",this).call(this)}},{key:"setValue",value:function(t){this.value!==t&&(this.value=t,this.input.value=this.value,this.onChange())}},{key:"destroy",value:function(){var t=this;this.options.enable_drag_drop===!0&&(["dragover","drop"].forEach(function(e){window.removeEventListener(e,t.dragHandler,!0)}),["dragenter","dragover","dragleave","drop"].forEach(function(e){t.dropZone.removeEventListener(e,t.dragHandler,!0)}),this.dropZone.removeEventListener("dblclick",this.clickHandler),this.dropZone&&this.dropZone.parentNode&&this.dropZone.parentNode.removeChild(this.dropZone)),this.uploader&&this.uploader.parentNode&&(this.uploader.removeEventListener("change",this.uploadHandler),this.uploader.parentNode.removeChild(this.uploader)),this.browseButton&&this.browseButton.parentNode&&(this.browseButton.removeEventListener("click",this.clickHandler),this.browseButton.parentNode.removeChild(this.browseButton)),this.fileDisplay&&this.fileDisplay.parentNode&&(this.fileDisplay.removeEventListener("dblclick",this.clickHandler),this.fileDisplay.parentNode.removeChild(this.fileDisplay)),this.fileUploadGroup&&this.fileUploadGroup.parentNode&&this.fileUploadGroup.parentNode.removeChild(this.fileUploadGroup),this.preview&&this.preview.parentNode&&this.preview.parentNode.removeChild(this.preview),this.header&&this.header.parentNode&&this.header.parentNode.removeChild(this.header),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),pa(Kn(l.prototype),"destroy",this).call(this)}},{key:"isValidMimeType",value:function(t,e){return e.reduce(function(o,u){return o||new RegExp(u.replace(/\*/g,".*"),"gi").test(t)},!1)}}])&&tf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(F),uuid:function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Sl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Qn(i);if(h){var o=Qn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(bo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"preBuild",value:function(){fa(Qn(l.prototype),"preBuild",this).call(this),this.schema.default=this.uuid=this.getUuid(),this.schema.options||(this.schema.options={}),this.schema.options.cleave||(this.schema.options.cleave={delimiters:["-"],blocks:[8,4,4,4,12]})}},{key:"build",value:function(){fa(Qn(l.prototype),"build",this).call(this),this.disable(!0),this.input.setAttribute("readonly","true")}},{key:"sanitize",value:function(t){return this.testUuid(t)||(t=this.uuid),t}},{key:"setValue",value:function(t,e,o){this.testUuid(t)||(t=this.uuid),this.uuid=t,fa(Qn(l.prototype),"setValue",this).call(this,t,e,o)}},{key:"getUuid",value:function(){return R()}},{key:"testUuid",value:function(t){return/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(t)}}])&&ef(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K),colorpicker:function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Pl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=dn(i);if(h){var o=dn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(vo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"postBuild",value:function(){window.Picker&&(this.input.type="text"),this.input.style.padding="3px"}},{key:"setValue",value:function(t,e,o){var u=wi(dn(l.prototype),"setValue",this).call(this,t,e,o);return this.picker_instance&&this.picker_instance.domElement&&u&&u.changed&&this.picker_instance.setColor(u.value,!0),u}},{key:"getNumColumns",value:function(){return 2}},{key:"afterInputReady",value:function(){wi(dn(l.prototype),"afterInputReady",this).call(this),this.createPicker(!0)}},{key:"disable",value:function(){if(wi(dn(l.prototype),"disable",this).call(this),this.picker_instance&&this.picker_instance.domElement){this.picker_instance.domElement.style.pointerEvents="none";for(var t=this.picker_instance.domElement.querySelectorAll("button"),e=0;e<t.length;e++)t[e].disabled=!0}}},{key:"enable",value:function(){if(wi(dn(l.prototype),"enable",this).call(this),this.picker_instance&&this.picker_instance.domElement){this.picker_instance.domElement.style.pointerEvents="auto";for(var t=this.picker_instance.domElement.querySelectorAll("button"),e=0;e<t.length;e++)t[e].disabled=!1}}},{key:"destroy",value:function(){this.createPicker(!1),wi(dn(l.prototype),"destroy",this).call(this)}},{key:"createPicker",value:function(t){var e=this;if(t){if(window.Picker&&!this.picker_instance){var o=this.expandCallbacks("colorpicker",k({},{editor:!1,alpha:!1,color:this.value,popup:"bottom"},this.defaults.options.colorpicker||{},this.options.colorpicker||{},{parent:this.container})),u=function(d){var x=e.picker_instance.settings.editorFormat,P=e.picker_instance.settings.alpha;e.setValue(x==="hex"?P?d.hex:d.hex.slice(0,7):d["".concat(x+(P?"a":""),"String")])};o.popup||typeof o.onChange=="function"?o.popup&&typeof o.onDone!="function"&&(o.onDone=u):o.onChange=u,this.picker_instance=new window.Picker(o),o.popup||(this.input.style.display="none",this.theme.afterInputReady(this.picker_instance.domElement))}}else this.picker_instance&&(this.picker_instance.destroy(),this.picker_instance=null,this.input.style.display="")}}])&&rf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(K)};function Pu(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}var Tu={},Tl="en",nf=Tl;Tu.en={error_notset:"Property must be set",error_notempty:"Value required",error_enum:"Value must be one of the enumerated values",error_const:"Value must be the constant value",error_anyOf:"Value must validate against at least one of the provided schemas",error_oneOf:"Value must validate against exactly one of the provided schemas. It currently validates against {{0}} of the schemas.",error_not:"Value must not validate against the provided schema",error_type_union:"Value must be one of the provided types",error_type:"Value must be of type {{0}}",error_disallow_union:"Value must not be one of the provided disallowed types",error_disallow:"Value must not be of type {{0}}",error_multipleOf:"Value must be a multiple of {{0}}",error_maximum_excl:"Value must be less than {{0}}",error_maximum_incl:"Value must be at most {{0}}",error_minimum_excl:"Value must be greater than {{0}}",error_minimum_incl:"Value must be at least {{0}}",error_maxLength:"Value must be at most {{0}} characters long",error_contains:"No items match contains",error_minContains:"Contains match count {{0}} is less than minimum contains count of {{1}}",error_maxContains:"Contains match count {{0}} exceeds maximum contains count of {{1}}",error_minLength:"Value must be at least {{0}} characters long",error_pattern:"Value must match the pattern {{0}}",error_additionalItems:"No additional items allowed in this array",error_maxItems:"Value must have at most {{0}} items",error_minItems:"Value must have at least {{0}} items",error_uniqueItems:"Array must have unique items",error_maxProperties:"Object must have at most {{0}} properties",error_minProperties:"Object must have at least {{0}} properties",error_required:"Object is missing the required property '{{0}}'",error_additional_properties:"No additional properties allowed, but property {{0}} is set",error_property_names_exceeds_maxlength:"Property name {{0}} exceeds maxLength",error_property_names_enum_mismatch:"Property name {{0}} does not match any enum values",error_property_names_const_mismatch:"Property name {{0}} does not match the const value",error_property_names_pattern_mismatch:"Property name {{0}} does not match pattern",error_property_names_false:"Property name {{0}} fails when propertyName is false",error_property_names_maxlength:"Property name {{0}} cannot match invalid maxLength",error_property_names_enum:"Property name {{0}} cannot match invalid enum",error_property_names_pattern:"Property name {{0}} cannot match invalid pattern",error_property_names_unsupported:"Unsupported propertyName {{0}}",error_dependency:"Must have property {{0}}",error_date:"Date must be in the format {{0}}",error_time:"Time must be in the format {{0}}",error_datetime_local:"Datetime must be in the format {{0}}",error_invalid_epoch:"Date must be greater than 1 January 1970",error_ipv4:"Value must be a valid IPv4 address in the form of 4 numbers between 0 and 255, separated by dots",error_ipv6:"Value must be a valid IPv6 address",error_hostname:"The hostname has the wrong format",upload_max_size:"Filesize too large. Max size is ",upload_wrong_file_format:"Wrong file format. Allowed format(s): ",button_save:"Save",button_copy:"Copy",button_cancel:"Cancel",button_add:"Add",button_delete_all:"All",button_delete_all_title:"Delete All",button_delete_last:"Last {{0}}",button_delete_last_title:"Delete Last {{0}}",button_add_row_title:"Add {{0}}",button_move_down_title:"Move down",button_move_up_title:"Move up",button_properties:"Properties",button_object_properties:"Object Properties",button_copy_row_title:"Copy {{0}}",button_delete_row_title:"Delete {{0}}",button_delete_row_title_short:"Delete",button_copy_row_title_short:"Copy",button_collapse:"Collapse",button_expand:"Expand",button_edit_json:"Edit JSON",button_upload:"Upload",flatpickr_toggle_button:"Toggle",flatpickr_clear_button:"Clear",choices_placeholder_text:"Start typing to add value",default_array_item_title:"item",button_delete_node_warning:"Are you sure you want to remove this item?"},Object.entries(_s).forEach(function(c){var n=function(h,a){return function(l){if(Array.isArray(l))return l}(h)||function(l,t){var e=l==null?null:typeof Symbol<"u"&&l[Symbol.iterator]||l["@@iterator"];if(e!=null){var o,u,d,x,P=[],D=!0,J=!1;try{if(d=(e=e.call(l)).next,t===0){if(Object(e)!==e)return;D=!1}else for(;!(D=(o=d.call(e)).done)&&(P.push(o.value),P.length!==t);D=!0);}catch(nt){J=!0,u=nt}finally{try{if(!D&&e.return!=null&&(x=e.return(),Object(x)!==x))return}finally{if(J)throw u}}return P}}(h,a)||function(l,t){if(l){if(typeof l=="string")return Pu(l,t);var e=Object.prototype.toString.call(l).slice(8,-1);return e==="Object"&&l.constructor&&(e=l.constructor.name),e==="Map"||e==="Set"?Array.from(l):e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?Pu(l,t):void 0}}(h,a)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
80
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}(c,2),f=n[0],i=n[1];_s[f].options=i.options||{}});var _i={options:{upload:function(c,n,f){console.log("Upload handler required for upload editor")},use_name_attributes:!0,prompt_before_delete:!0,use_default_values:!0,max_depth:0,button_state_mode:1,case_sensitive_property_search:!0},theme:"html",template:"default",themes:{},callbacks:{},templates:{},iconlibs:{},editors:_s,languages:Tu,resolvers:j,custom_validators:[],default_language:Tl,language:nf,translate:function(c,n,f){var i={};f&&f.options&&f.options.error_messages&&f.options.error_messages[_i.language]&&(i=f.options.error_messages[_i.language]);var h=_i.languages[_i.language];if(!h)throw new Error("Unknown language ".concat(_i.language));var a=i[c]||h[c]||_i.languages[Tl][c]||c;if(n)for(var l=0;l<n.length;l++)a=a.replace(new RegExp("\\{\\{".concat(l,"}}"),"g"),n[l]);return a},translateProperty:function(c,n){return c}};function xi(){xi=function(){return c};var c={},n=Object.prototype,f=n.hasOwnProperty,i=Object.defineProperty||function(W,G,Z){W[G]=Z.value},h=typeof Symbol=="function"?Symbol:{},a=h.iterator||"@@iterator",l=h.asyncIterator||"@@asyncIterator",t=h.toStringTag||"@@toStringTag";function e(W,G,Z){return Object.defineProperty(W,G,{value:Z,enumerable:!0,configurable:!0,writable:!0}),W[G]}try{e({},"")}catch{e=function(G,Z,pt){return G[Z]=pt}}function o(W,G,Z,pt){var et=G&&G.prototype instanceof x?G:x,Lt=Object.create(et.prototype),re=new gt(pt||[]);return i(Lt,"_invoke",{value:Nt(W,Z,re)}),Lt}function u(W,G,Z){try{return{type:"normal",arg:W.call(G,Z)}}catch(pt){return{type:"throw",arg:pt}}}c.wrap=o;var d={};function x(){}function P(){}function D(){}var J={};e(J,a,function(){return this});var nt=Object.getPrototypeOf,ut=nt&&nt(nt(Jt([])));ut&&ut!==n&&f.call(ut,a)&&(J=ut);var dt=D.prototype=x.prototype=Object.create(J);function kt(W){["next","throw","return"].forEach(function(G){e(W,G,function(Z){return this._invoke(G,Z)})})}function Ct(W,G){function Z(et,Lt,re,Pe){var Te=u(W[et],W,Lt);if(Te.type!=="throw"){var Dr=Te.arg,en=Dr.value;return en&&ur(en)=="object"&&f.call(en,"__await")?G.resolve(en.__await).then(function(kr){Z("next",kr,re,Pe)},function(kr){Z("throw",kr,re,Pe)}):G.resolve(en).then(function(kr){Dr.value=kr,re(Dr)},function(kr){return Z("throw",kr,re,Pe)})}Pe(Te.arg)}var pt;i(this,"_invoke",{value:function(et,Lt){function re(){return new G(function(Pe,Te){Z(et,Lt,Pe,Te)})}return pt=pt?pt.then(re,re):re()}})}function Nt(W,G,Z){var pt="suspendedStart";return function(et,Lt){if(pt==="executing")throw new Error("Generator is already running");if(pt==="completed"){if(et==="throw")throw Lt;return{value:void 0,done:!0}}for(Z.method=et,Z.arg=Lt;;){var re=Z.delegate;if(re){var Pe=ne(re,Z);if(Pe){if(Pe===d)continue;return Pe}}if(Z.method==="next")Z.sent=Z._sent=Z.arg;else if(Z.method==="throw"){if(pt==="suspendedStart")throw pt="completed",Z.arg;Z.dispatchException(Z.arg)}else Z.method==="return"&&Z.abrupt("return",Z.arg);pt="executing";var Te=u(W,G,Z);if(Te.type==="normal"){if(pt=Z.done?"completed":"suspendedYield",Te.arg===d)continue;return{value:Te.arg,done:Z.done}}Te.type==="throw"&&(pt="completed",Z.method="throw",Z.arg=Te.arg)}}}function ne(W,G){var Z=G.method,pt=W.iterator[Z];if(pt===void 0)return G.delegate=null,Z==="throw"&&W.iterator.return&&(G.method="return",G.arg=void 0,ne(W,G),G.method==="throw")||Z!=="return"&&(G.method="throw",G.arg=new TypeError("The iterator does not provide a '"+Z+"' method")),d;var et=u(pt,W.iterator,G.arg);if(et.type==="throw")return G.method="throw",G.arg=et.arg,G.delegate=null,d;var Lt=et.arg;return Lt?Lt.done?(G[W.resultName]=Lt.value,G.next=W.nextLoc,G.method!=="return"&&(G.method="next",G.arg=void 0),G.delegate=null,d):Lt:(G.method="throw",G.arg=new TypeError("iterator result is not an object"),G.delegate=null,d)}function Re(W){var G={tryLoc:W[0]};1 in W&&(G.catchLoc=W[1]),2 in W&&(G.finallyLoc=W[2],G.afterLoc=W[3]),this.tryEntries.push(G)}function Gt(W){var G=W.completion||{};G.type="normal",delete G.arg,W.completion=G}function gt(W){this.tryEntries=[{tryLoc:"root"}],W.forEach(Re,this),this.reset(!0)}function Jt(W){if(W){var G=W[a];if(G)return G.call(W);if(typeof W.next=="function")return W;if(!isNaN(W.length)){var Z=-1,pt=function et(){for(;++Z<W.length;)if(f.call(W,Z))return et.value=W[Z],et.done=!1,et;return et.value=void 0,et.done=!0,et};return pt.next=pt}}return{next:Ge}}function Ge(){return{value:void 0,done:!0}}return P.prototype=D,i(dt,"constructor",{value:D,configurable:!0}),i(D,"constructor",{value:P,configurable:!0}),P.displayName=e(D,t,"GeneratorFunction"),c.isGeneratorFunction=function(W){var G=typeof W=="function"&&W.constructor;return!!G&&(G===P||(G.displayName||G.name)==="GeneratorFunction")},c.mark=function(W){return Object.setPrototypeOf?Object.setPrototypeOf(W,D):(W.__proto__=D,e(W,t,"GeneratorFunction")),W.prototype=Object.create(dt),W},c.awrap=function(W){return{__await:W}},kt(Ct.prototype),e(Ct.prototype,l,function(){return this}),c.AsyncIterator=Ct,c.async=function(W,G,Z,pt,et){et===void 0&&(et=Promise);var Lt=new Ct(o(W,G,Z,pt),et);return c.isGeneratorFunction(G)?Lt:Lt.next().then(function(re){return re.done?re.value:Lt.next()})},kt(dt),e(dt,t,"Generator"),e(dt,a,function(){return this}),e(dt,"toString",function(){return"[object Generator]"}),c.keys=function(W){var G=Object(W),Z=[];for(var pt in G)Z.push(pt);return Z.reverse(),function et(){for(;Z.length;){var Lt=Z.pop();if(Lt in G)return et.value=Lt,et.done=!1,et}return et.done=!0,et}},c.values=Jt,gt.prototype={constructor:gt,reset:function(W){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(Gt),!W)for(var G in this)G.charAt(0)==="t"&&f.call(this,G)&&!isNaN(+G.slice(1))&&(this[G]=void 0)},stop:function(){this.done=!0;var W=this.tryEntries[0].completion;if(W.type==="throw")throw W.arg;return this.rval},dispatchException:function(W){if(this.done)throw W;var G=this;function Z(Te,Dr){return Lt.type="throw",Lt.arg=W,G.next=Te,Dr&&(G.method="next",G.arg=void 0),!!Dr}for(var pt=this.tryEntries.length-1;pt>=0;--pt){var et=this.tryEntries[pt],Lt=et.completion;if(et.tryLoc==="root")return Z("end");if(et.tryLoc<=this.prev){var re=f.call(et,"catchLoc"),Pe=f.call(et,"finallyLoc");if(re&&Pe){if(this.prev<et.catchLoc)return Z(et.catchLoc,!0);if(this.prev<et.finallyLoc)return Z(et.finallyLoc)}else if(re){if(this.prev<et.catchLoc)return Z(et.catchLoc,!0)}else{if(!Pe)throw new Error("try statement without catch or finally");if(this.prev<et.finallyLoc)return Z(et.finallyLoc)}}}},abrupt:function(W,G){for(var Z=this.tryEntries.length-1;Z>=0;--Z){var pt=this.tryEntries[Z];if(pt.tryLoc<=this.prev&&f.call(pt,"finallyLoc")&&this.prev<pt.finallyLoc){var et=pt;break}}et&&(W==="break"||W==="continue")&&et.tryLoc<=G&&G<=et.finallyLoc&&(et=null);var Lt=et?et.completion:{};return Lt.type=W,Lt.arg=G,et?(this.method="next",this.next=et.finallyLoc,d):this.complete(Lt)},complete:function(W,G){if(W.type==="throw")throw W.arg;return W.type==="break"||W.type==="continue"?this.next=W.arg:W.type==="return"?(this.rval=this.arg=W.arg,this.method="return",this.next="end"):W.type==="normal"&&G&&(this.next=G),d},finish:function(W){for(var G=this.tryEntries.length-1;G>=0;--G){var Z=this.tryEntries[G];if(Z.finallyLoc===W)return this.complete(Z.completion,Z.afterLoc),Gt(Z),d}},catch:function(W){for(var G=this.tryEntries.length-1;G>=0;--G){var Z=this.tryEntries[G];if(Z.tryLoc===W){var pt=Z.completion;if(pt.type==="throw"){var et=pt.arg;Gt(Z)}return et}}throw new Error("illegal catch attempt")},delegateYield:function(W,G,Z){return this.delegate={iterator:Jt(W),resultName:G,nextLoc:Z},this.method==="next"&&(this.arg=void 0),d}},c}function Au(c,n,f,i,h,a,l){try{var t=c[a](l),e=t.value}catch(o){return void f(o)}t.done?n(e):Promise.resolve(e).then(i,h)}function Lu(c){return function(){var n=this,f=arguments;return new Promise(function(i,h){var a=c.apply(n,f);function l(e){Au(a,i,h,l,t,"next",e)}function t(e){Au(a,i,h,l,t,"throw",e)}l(void 0)})}}function ki(c,n){return function(f){if(Array.isArray(f))return f}(c)||function(f,i){var h=f==null?null:typeof Symbol<"u"&&f[Symbol.iterator]||f["@@iterator"];if(h!=null){var a,l,t,e,o=[],u=!0,d=!1;try{if(t=(h=h.call(f)).next,i===0){if(Object(h)!==h)return;u=!1}else for(;!(u=(a=t.call(h)).done)&&(o.push(a.value),o.length!==i);u=!0);}catch(x){d=!0,l=x}finally{try{if(!u&&h.return!=null&&(e=h.return(),Object(e)!==e))return}finally{if(d)throw l}}return o}}(c,n)||function(f,i){if(f){if(typeof f=="string")return Ru(f,i);var h=Object.prototype.toString.call(f).slice(8,-1);return h==="Object"&&f.constructor&&(h=f.constructor.name),h==="Map"||h==="Set"?Array.from(f):h==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(h)?Ru(f,i):void 0}}(c,n)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
81
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Ru(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function ur(c){return ur=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ur(c)}function of(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ur(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ur(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ur(h)==="symbol"?h:String(h)),i)}var h}_(8733);var af=function(){function c(a){(function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")})(this,c),this.options=a||{},this.schema={},this.refs=this.options.refs||{},this.refs_with_info={},this.refs_prefix="#/counter/",this.refs_counter=1,this._subSchema1={type:function(l){ur(l.type)==="object"&&(l.type=this._expandSubSchema(l.type))},disallow:function(l){ur(l.disallow)==="object"&&(l.disallow=this._expandSubSchema(l.disallow))},anyOf:function(l){var t=this;Object.entries(l.anyOf).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];l.anyOf[u]=t.expandSchema(d)})},dependencies:function(l){var t=this;Object.entries(l.dependencies).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];ur(d)!=="object"||Array.isArray(d)||(l.dependencies[u]=t.expandSchema(d))})},not:function(l){l.not=this.expandSchema(l.not)}},this._subSchema2={allOf:function(l,t){var e=this,o=k({},t);return Object.entries(l.allOf).forEach(function(u){var d=ki(u,2),x=d[0],P=d[1];l.allOf[x]=e.expandRefs(P,!0),o=e.extendSchemas(o,e.expandSchema(P))}),delete o.allOf,o},extends:function(l,t){var e,o=this;return delete(e=Array.isArray(l.extends)?l.extends.reduce(function(u,d,x){return o.extendSchemas(u,o.expandSchema(d))},t):this.extendSchemas(t,this.expandSchema(l.extends))).extends,e},oneOf:function(l,t){var e=this,o=k({},t);return delete o.oneOf,l.oneOf.reduce(function(u,d,x){return u.oneOf[x]=e.extendSchemas(e.expandSchema(d),o),u},t),t}}}var n,f,i,h;return n=c,f=[{key:"load",value:(h=Lu(xi().mark(function a(l,t,e){return xi().wrap(function(o){for(;;)switch(o.prev=o.next){case 0:return this.schema=l,o.next=3,this._asyncloadExternalRefs(l,t,this._getFileBase(e),!0);case 3:return o.abrupt("return",this.expandRefs(l));case 4:case"end":return o.stop()}},a,this)})),function(a,l,t){return h.apply(this,arguments)})},{key:"expandRefs",value:function(a,l){var t=this,e=k({},a);if(!e.$ref)return e;var o=e.$ref.split("#");if(o.length===2&&!this.refs_with_info[e.$ref]){var u=this.expandRecursivePointer(this.schema,o[1]),d=this.extendSchemas(e,this.expandSchema(u));return delete d.$ref,d}var x=o.length>2?this.refs_with_info["#"+o[1]]:this.refs_with_info[e.$ref];delete e.$ref;var P=x.$ref.startsWith("#")?x.fetchUrl:"",D=this._getRef(P,x);if(this.refs[D]){if(l&&S(this.refs[D],"allOf")){var J=this.refs[D].allOf;Object.keys(J).forEach(function(nt){J[nt]=t.expandRefs(J[nt],!0)})}}else console.warn("reference:'".concat(D,"' not found!"));return o.length>2?this.extendSchemas(e,this.expandSchema(this.expandRecursivePointer(this.refs[D],o[2]))):this.extendSchemas(e,this.expandSchema(this.refs[D]))}},{key:"expandRecursivePointer",value:function(a,l){var t=a;return l.split("/").slice(1).forEach(function(e){t[e]&&(t=t[e])}),t.$refs&&t.$refs.startsWith("#")?this.expandRecursivePointer(a,t.$refs):t}},{key:"expandSchema",value:function(a){var l=this;Object.entries(this._subSchema1).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];a[u]&&d.call(l,a)});var t=k({},a);return Object.entries(this._subSchema2).forEach(function(e){var o=ki(e,2),u=o[0],d=o[1];a[u]&&(t=d.call(l,a,t))}),this.expandRefs(t)}},{key:"_getRef",value:function(a,l){var t=a+l;return this.refs[t]?t:a+decodeURIComponent(l.$ref)}},{key:"_expandSubSchema",value:function(a){var l=this;return Array.isArray(a)?a.map(function(t){return ur(t)==="object"?l.expandSchema(t):t}):this.expandSchema(a)}},{key:"_manageRecursivePointer",value:function(a,l){Object.keys(a).forEach(function(t){a[t].$ref&&a[t].$ref.indexOf("#")===0&&(a[t].$ref=l+a[t].$ref)})}},{key:"_getExternalRefs",value:function(a,l){var t=this,e=arguments.length>2&&arguments[2]!==void 0&&arguments[2];e||this._manageRecursivePointer(a,l);var o={},u=function(J){return Object.keys(J).forEach(function(nt){o[nt]=!0})};if(a.$ref&&ur(a.$ref)!=="object"&&(a.$ref.indexOf("#")!==0||!e)){var d=a.$ref,x="";d.indexOf("#")>0&&(d=d.substr(0,d.indexOf("#"))),d!==a.$ref&&(x=a.$ref.substr(a.$ref.indexOf("#")));var P=this.refs_prefix+this.refs_counter++,D=P+x;a.$ref.substr(0,1)==="#"||this.refs[a.$ref]||(o[d]=!0),this.refs_with_info[P]={fetchUrl:l,$ref:d},a.$ref=D}return Object.values(a).forEach(function(J){J&&ur(J)==="object"&&(Array.isArray(J)?Object.values(J).forEach(function(nt){nt&&ur(nt)==="object"&&u(t._getExternalRefs(nt,l,e))}):J.$ref&&typeof J.$ref=="string"&&J.$ref.startsWith("#")||u(t._getExternalRefs(J,l,e)))}),a.id&&typeof a.id=="string"&&a.id.substr(0,4)==="urn:"?this.refs[a.id]=a:a.$id&&typeof a.$id=="string"&&a.$id.substr(0,4)==="urn:"&&(this.refs[a.$id]=a),o}},{key:"_getFileBase",value:function(a){if(!a)return"/";var l=this.options.ajaxBase;return l===void 0?this._getFileBaseFromFileLocation(a):l}},{key:"_getFileBaseFromFileLocation",value:function(a){var l=a.split("/");return l.pop(),"".concat(l.join("/"),"/")}},{key:"_joinUrl",value:function(a,l){var t=a;return a.substr(0,7)!=="http://"&&a.substr(0,8)!=="https://"&&a.substr(0,5)!=="blob:"&&a.substr(0,5)!=="data:"&&a.substr(0,1)!=="#"&&a.substr(0,1)!=="/"&&(t=l+a),t.indexOf("#")>0&&(t=t.substr(0,t.indexOf("#"))),t}},{key:"_isUniformResourceName",value:function(a){return a.substr(0,4)==="urn:"}},{key:"_asyncloadExternalRefs",value:(i=Lu(xi().mark(function a(l,t,e){var o,u,d,x,P,D,J=this,nt=arguments;return xi().wrap(function(ut){for(;;)switch(ut.prev=ut.next){case 0:o=nt.length>3&&nt[3]!==void 0&&nt[3],u=this._getExternalRefs(l,t,o),d=0,x=xi().mark(function dt(){var kt,Ct,Nt,ne,Re,Gt,gt,Jt,Ge,W,G;return xi().wrap(function(Z){for(;;)switch(Z.prev=Z.next){case 0:if((kt=D[P])!==void 0){Z.next=3;break}return Z.abrupt("return","continue");case 3:if(!J.refs[kt]){Z.next=5;break}return Z.abrupt("return","continue");case 5:if(!J._isUniformResourceName(kt)){Z.next=40;break}if(J.refs[kt]="loading",d++,Ct=J.options.urn_resolver,Nt=kt,typeof Ct=="function"){Z.next=13;break}throw console.log('No "urn_resolver" callback defined to resolve "'.concat(Nt,'"')),new Error("Must set urn_resolver option to a callback to resolve ".concat(Nt));case 13:return Nt.indexOf("#")>0&&(Nt=Nt.substr(0,Nt.indexOf("#"))),Z.prev=14,Z.next=17,Ct(Nt);case 17:ne=Z.sent,Z.prev=18,Re=JSON.parse(ne),Z.next=26;break;case 22:throw Z.prev=22,Z.t0=Z.catch(18),console.log(Z.t0),new Error("Failed to parse external ref ".concat(Nt));case 26:if(!(typeof Re!="boolean"&&ur(Re)!=="object"||Re===null||Array.isArray(Re))){Z.next=28;break}throw new Error("External ref does not contain a valid schema - ".concat(Nt));case 28:return J.refs[kt]=Re,Z.next=31,J._asyncloadExternalRefs(Re,kt,e);case 31:Z.next=37;break;case 33:throw Z.prev=33,Z.t1=Z.catch(14),console.log(Z.t1),new Error("Failed to parse external ref ".concat(Nt));case 37:if(typeof ne!="boolean"){Z.next=39;break}throw new Error("External ref does not contain a valid schema - ".concat(Nt));case 39:return Z.abrupt("return","continue");case 40:if(J.options.ajax){Z.next=42;break}throw new Error("Must set ajax option to true to load external ref ".concat(kt));case 42:if(d++,Gt=J._joinUrl(kt,e),J.options.ajax_cache_responses&&(Jt=J.cacheGet(Gt))&&(gt=Jt),gt){Z.next=61;break}return Z.next=48,new Promise(function(pt){var et=new XMLHttpRequest;J.options.ajaxCredentials&&(et.withCredentials=J.options.ajaxCredentials),et.overrideMimeType("application/json"),et.open("GET",Gt,!0),et.onload=function(){pt(et)},et.onerror=function(Lt){pt(void 0)},et.send()});case 48:if((Ge=Z.sent)!==void 0){Z.next=51;break}throw new Error("Failed to fetch ref via ajax - ".concat(kt));case 51:Z.prev=51,gt=JSON.parse(Ge.responseText),J.onSchemaLoaded({schema:gt,schemaUrl:Gt}),J.options.ajax_cache_responses&&J.cacheSet(Gt,gt),Z.next=61;break;case 57:throw Z.prev=57,Z.t2=Z.catch(51),console.log(Z.t2),new Error("Failed to parse external ref ".concat(Gt));case 61:if(!(typeof gt!="boolean"&&ur(gt)!=="object"||gt===null||Array.isArray(gt))){Z.next=63;break}throw new Error("External ref does not contain a valid schema - ".concat(Gt));case 63:return J.refs[kt]=gt,W=J._getFileBaseFromFileLocation(Gt),Gt!==kt&&(G=Gt.split("/"),Gt=(kt.substr(0,1)==="/"?"/":"")+G.pop()),Z.next=68,J._asyncloadExternalRefs(gt,Gt,W);case 68:case"end":return Z.stop()}},dt,null,[[14,33],[18,22],[51,57]])}),P=0,D=Object.keys(u);case 5:if(!(P<D.length)){ut.next=13;break}return ut.delegateYield(x(),"t0",7);case 7:if(ut.t0!=="continue"){ut.next=10;break}return ut.abrupt("continue",10);case 10:P++,ut.next=5;break;case 13:if(d){ut.next=15;break}return ut.abrupt("return",!0);case 15:this.onAllSchemasLoaded();case 16:case"end":return ut.stop()}},a,this)})),function(a,l,t){return i.apply(this,arguments)})},{key:"onSchemaLoaded",value:function(a){}},{key:"onAllSchemasLoaded",value:function(){}},{key:"extendSchemas",value:function(a,l){var t=this;a=k({},a),l=k({},l);var e={},o=function(u){typeof u=="string"&&(u=[u]),typeof l.type=="string"&&(l.type=[l.type]),l.type&&l.type.length?e.type=u.filter(function(d){return l.type.includes(d)}):e.type=u,e.type.length===1&&typeof e.type[0]=="string"?e.type=e.type[0]:e.type.length===0&&delete e.type};return Object.entries(a).forEach(function(u){var d=ki(u,2),x=d[0],P=d[1];l[x]!==void 0?function(D,J){(function(nt,ut){return(nt==="required"||nt==="defaultProperties")&&ur(ut)==="object"&&Array.isArray(ut)})(D,J)?e[D]=J.concat(l[D]).reduce(function(nt,ut){return nt.includes(ut)||nt.push(ut),nt},[]):D!=="type"||typeof J!="string"&&!Array.isArray(J)?ur(J)!=="object"||Array.isArray(J)||J===null?e[D]=J:e[D]=t.extendSchemas(J,l[D]):o(J)}(x,P):e[x]=P}),Object.entries(l).forEach(function(u){var d=ki(u,2),x=d[0],P=d[1];a[x]===void 0&&(e[x]=P)}),e}},{key:"getCacheKey",value:function(a){return["je-cache",a].join("::")}},{key:"getCacheBuster",value:function(){return this.options.ajax_cache_buster||new Date().toISOString().slice(0,10)}},{key:"cacheSet",value:function(a,l){try{window.localStorage.setItem(this.getCacheKey(a),JSON.stringify({cacheBuster:this.getCacheBuster(),schema:l}))}catch(t){console.error(t)}}},{key:"cacheGet",value:function(a){try{var l=window.localStorage.getItem(this.getCacheKey(a));if(l){var t=JSON.parse(l);if(t.cacheBuster&&t.schema&&t.cacheBuster===this.getCacheBuster())return t.schema;this.cacheDelete(a)}}catch(e){console.error(e)}}},{key:"cacheDelete",value:function(a){window.localStorage.removeItem(this.getCacheKey(a))}}],f&&of(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}(),sf=(_(3210),{default:function(){return{compile:function(c){var n=c.match(/{{\s*([a-zA-Z0-9\-_ .]+)\s*}}/g),f=n&&n.length;if(!f)return function(){return c};for(var i=[],h=function(l){var t,e,o=n[l].replace(/[{}]+/g,"").trim().split("."),u=o.length;u>1?t=function(d){for(e=d,l=0;l<u&&(e=e[o[l]]);l++);return e}:(o=o[0],t=function(d){return d[o]}),i.push({s:n[l],r:t})},a=0;a<f;a++)h(a);return function(l){var t,e="".concat(c);for(a=0;a<f;a++)t=i[a],e=e.replace(t.s,t.r(l));return e}}}},ejs:function(){return!!window.EJS&&{compile:function(c){var n=new window.EJS({text:c});return function(f){return n.render(f)}}}},handlebars:function(){return window.Handlebars},hogan:function(){return!!window.Hogan&&{compile:function(c){var n=window.Hogan.compile(c);return function(f){return n.render(f)}}}},lodash:function(){return!!window._&&{compile:function(c){return function(n){return window._.template(c)(n)}}}},markup:function(){return!(!window.Mark||!window.Mark.up)&&{compile:function(c){return function(n){return window.Mark.up(c,n)}}}},mustache:function(){return!!window.Mustache&&{compile:function(c){return function(n){return window.Mustache.render(c,n)}}}},swig:function(){return window.swig},underscore:function(){return!!window._&&{compile:function(c){return function(n){return window._.template(c)(n)}}}}});function ma(c){return ma=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ma(c)}function Al(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function lf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ma(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ma(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ma(h)==="symbol"?h:String(h)),i)}var h}var cf={collapse:"",expand:"",delete:"",edit:"",add:"",cancel:"",save:"",moveup:"",movedown:""},Cn=function(){function c(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:cf;(function(a,l){if(!(a instanceof l))throw new TypeError("Cannot call a class as a function")})(this,c),this.mapping=h,this.icon_prefix=i}var n,f;return n=c,(f=[{key:"getIconClass",value:function(i){return this.mapping[i]?this.icon_prefix+this.mapping[i]:this.icon_prefix+i}},{key:"getIcon",value:function(i){var h,a=this.getIconClass(i);if(!a)return null;var l,t=document.createElement("i");return(h=t.classList).add.apply(h,function(e){if(Array.isArray(e))return Al(e)}(l=a.split(" "))||function(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}(l)||function(e,o){if(e){if(typeof e=="string")return Al(e,o);var u=Object.prototype.toString.call(e).slice(8,-1);return u==="Object"&&e.constructor&&(u=e.constructor.name),u==="Map"||u==="Set"?Array.from(e):u==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(u)?Al(e,o):void 0}}(l)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
82
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()),t}}])&&lf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function Ll(c){return Ll=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ll(c)}function Rl(c,n){return Rl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Rl(c,n)}function xs(c){return xs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},xs(c)}var uf="glyphicon glyphicon-",hf={collapse:"chevron-down",expand:"chevron-right",delete:"trash",edit:"pencil",add:"plus",subtract:"minus",cancel:"floppy-remove",save:"floppy-saved",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"copy",clear:"remove-circle",time:"time",calendar:"calendar",edit_properties:"list"},df=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Rl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=xs(f);if(i){var e=xs(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Ll(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,uf,hf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Il(c){return Il=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Il(c)}function Bl(c,n){return Bl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Bl(c,n)}function ks(c){return ks=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ks(c)}var pf="icon-",ff={collapse:"chevron-down",expand:"chevron-right",delete:"trash",edit:"pencil",add:"plus",subtract:"minus",cancel:"ban-circle",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"copy",clear:"remove-circle",time:"time",calendar:"calendar",edit_properties:"list"},mf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Bl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=ks(f);if(i){var e=ks(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Il(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,pf,ff)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Dl(c){return Dl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Dl(c)}function Nl(c,n){return Nl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Nl(c,n)}function js(c){return js=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},js(c)}var yf="fa fa-",bf={collapse:"caret-square-o-down",expand:"caret-square-o-right",delete:"times",edit:"pencil",add:"plus",subtract:"minus",cancel:"ban",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"files-o",clear:"times-circle-o",time:"clock-o",calendar:"calendar",edit_properties:"list"},vf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Nl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=js(f);if(i){var e=js(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Dl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,yf,bf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function $l(c){return $l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},$l(c)}function Ml(c,n){return Ml=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ml(c,n)}function Os(c){return Os=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Os(c)}var gf="fas fa-",wf={collapse:"caret-down",expand:"caret-right",delete:"trash",edit:"pen",add:"plus",subtract:"minus",cancel:"ban",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"copy",clear:"times-circle",time:"clock",calendar:"calendar",edit_properties:"list"},_f=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Ml(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Os(f);if(i){var e=Os(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&($l(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,gf,wf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Hl(c){return Hl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Hl(c)}function Fl(c,n){return Fl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Fl(c,n)}function Es(c){return Es=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Es(c)}var xf="ui-icon ui-icon-",kf={collapse:"triangle-1-s",expand:"triangle-1-e",delete:"trash",edit:"pencil",add:"plusthick",subtract:"minusthick",cancel:"closethick",save:"disk",moveup:"arrowthick-1-n",moveright:"arrowthick-1-e",movedown:"arrowthick-1-s",moveleft:"arrowthick-1-w",copy:"copy",clear:"circle-close",time:"time",calendar:"calendar",edit_properties:"note"},jf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Fl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Es(f);if(i){var e=Es(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Hl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,xf,kf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Vl(c){return Vl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Vl(c)}function zl(c,n){return zl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},zl(c,n)}function Cs(c){return Cs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Cs(c)}var Of="oi oi-",Ef={collapse:"collapse-down",expand:"expand-right",delete:"trash",edit:"pencil",add:"plus",subtract:"minus",cancel:"ban",save:"file",moveup:"arrow-thick-top",moveright:"arrow-thick-right",movedown:"arrow-thick-bottom",moveleft:"arrow-thick-left",copy:"clipboard",clear:"circle-x",time:"clock",calendar:"calendar",edit_properties:"list"},Cf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&zl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Cs(f);if(i){var e=Cs(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Vl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,Of,Ef)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Ul(c){return Ul=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Ul(c)}function ql(c,n){return ql=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ql(c,n)}function Ss(c){return Ss=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ss(c)}var Sf="icon icon-",Pf={collapse:"arrow-down",expand:"arrow-right",delete:"delete",edit:"edit",add:"plus",subtract:"minus",cancel:"cross",save:"check",moveup:"upward",moveright:"forward",movedown:"downward",moveleft:"back",copy:"copy",clear:"close",time:"time",calendar:"bookmark",edit_properties:"menu"},Tf=function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&ql(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Ss(f);if(i){var e=Ss(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Ul(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,Sf,Pf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn);function Gl(c){return Gl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Gl(c)}function Wl(c,n){return Wl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Wl(c,n)}function Ps(c){return Ps=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ps(c)}var Af="bi bi-",Lf={collapse:"chevron-down",expand:"chevron-right",delete:"trash",edit:"pencil",add:"plus",subtract:"dash",cancel:"x-circle",save:"save",moveup:"arrow-up",moveright:"arrow-right",movedown:"arrow-down",moveleft:"arrow-left",copy:"clipboard",clear:"x-circle",time:"clock",calendar:"calendar",edit_properties:"list-ul"},Rf={bootstrap:function(c){(function(l,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");l.prototype=Object.create(t&&t.prototype,{constructor:{value:l,writable:!0,configurable:!0}}),Object.defineProperty(l,"prototype",{writable:!1}),t&&Wl(l,t)})(a,c);var n,f,i,h=(f=a,i=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var l,t=Ps(f);if(i){var e=Ps(this).constructor;l=Reflect.construct(t,arguments,e)}else l=t.apply(this,arguments);return function(o,u){if(u&&(Gl(u)==="object"||typeof u=="function"))return u;if(u!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(d){if(d===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d}(o)}(this,l)});function a(){return function(l,t){if(!(l instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),h.call(this,Af,Lf)}return n=a,Object.defineProperty(n,"prototype",{writable:!1}),n}(Cn),bootstrap3:df,fontawesome3:mf,fontawesome4:vf,fontawesome5:_f,jqueryui:jf,openiconic:Cf,spectre:Tf};function ya(c){return ya=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ya(c)}function If(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ya(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ya(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ya(h)==="symbol"?h:String(h)),i)}var h}var Iu=["matches","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector"].find(function(c){return c in document.documentElement}),Sn=function(){function c(i){var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{disable_theme_rules:!1};(function(a,l){if(!(a instanceof l))throw new TypeError("Cannot call a class as a function")})(this,c),this.jsoneditor=i,Object.keys(h).forEach(function(a){i.options[a]!==void 0&&(h[a]=i.options[a])}),this.options=h}var n,f;return n=c,f=[{key:"getContainer",value:function(){return document.createElement("div")}},{key:"getFloatRightLinkHolder",value:function(){var i=document.createElement("div");return i.classList.add("je-float-right-linkholder"),i}},{key:"getModal",value:function(){var i=document.createElement("div");return i.style.display="none",i.classList.add("je-modal"),i}},{key:"getGridContainer",value:function(){return document.createElement("div")}},{key:"getGridRow",value:function(){var i=document.createElement("div");return i.classList.add("row"),i}},{key:"getGridColumn",value:function(){return document.createElement("div")}},{key:"setGridColumnSize",value:function(i,h){}},{key:"getLink",value:function(i){var h=document.createElement("a");return h.setAttribute("href","#"),h.appendChild(document.createTextNode(i)),h}},{key:"disableHeader",value:function(i){i.style.color="#ccc"}},{key:"disableLabel",value:function(i){i.style.color="#ccc"}},{key:"enableHeader",value:function(i){i.style.color=""}},{key:"enableLabel",value:function(i){i.style.color=""}},{key:"getInfoButton",value:function(i){var h=document.createElement("span");h.innerText="ⓘ",h.classList.add("je-infobutton-icon");var a=document.createElement("span");return a.classList.add("je-infobutton-tooltip"),a.innerText=i,h.onmouseover=function(){a.style.visibility="visible"},h.onmouseleave=function(){a.style.visibility="hidden"},h.appendChild(a),h}},{key:"getFormInputLabel",value:function(i,h){var a=document.createElement("label");return a.appendChild(document.createTextNode(i)),h&&a.classList.add("required"),a}},{key:"getHeader",value:function(i,h){var a=document.createElement("h3");return typeof i=="string"?a.textContent=i:a.appendChild(i),a.classList.add("je-header"),a}},{key:"getCheckbox",value:function(){var i=this.getFormInputField("checkbox");return i.classList.add("je-checkbox"),i}},{key:"getCheckboxLabel",value:function(i,h){var a=document.createElement("label");return a.appendChild(document.createTextNode(" ".concat(i))),h&&a.classList.add("required"),a}},{key:"getMultiCheckboxHolder",value:function(i,h,a,l){var t=document.createElement("div");return t.classList.add("control-group"),h&&(h.style.display="block",t.appendChild(h),l&&h.appendChild(l)),Object.values(i).forEach(function(e){e.style.display="inline-block",e.style.marginRight="20px",t.appendChild(e)}),a&&t.appendChild(a),t}},{key:"getFormCheckboxControl",value:function(i,h,a){var l=document.createElement("div");return l.appendChild(i),h.style.width="auto",i.insertBefore(h,i.firstChild),a&&l.classList.add("je-checkbox-control--compact"),l}},{key:"getFormRadio",value:function(i){var h=this.getFormInputField("radio");return Object.keys(i).forEach(function(a){return h.setAttribute(a,i[a])}),h.classList.add("je-radio"),h}},{key:"getFormRadioLabel",value:function(i,h){var a=document.createElement("label");return a.appendChild(document.createTextNode(" ".concat(i))),h&&a.classList.add("required"),a}},{key:"getFormRadioControl",value:function(i,h,a){var l=document.createElement("div");return l.appendChild(i),h.style.width="auto",i.insertBefore(h,i.firstChild),a&&l.classList.add("je-radio-control--compact"),l}},{key:"getSelectInput",value:function(i,h){var a=document.createElement("select");return i&&this.setSelectOptions(a,i),a}},{key:"getSwitcher",value:function(i){var h=this.getSelectInput(i,!1);return h.classList.add("je-switcher"),h}},{key:"getSwitcherOptions",value:function(i){return i.getElementsByTagName("option")}},{key:"setSwitcherOptions",value:function(i,h,a){this.setSelectOptions(i,h,a)}},{key:"setSelectOptions",value:function(i,h){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];i.innerHTML="";for(var l=0;l<h.length;l++){var t=document.createElement("option");t.setAttribute("value",h[l]),t.textContent=a[l]||h[l],i.appendChild(t)}}},{key:"getTextareaInput",value:function(){var i=document.createElement("textarea");return i.classList.add("je-textarea"),i}},{key:"getRangeInput",value:function(i,h,a){var l=this.getFormInputField("range");return l.setAttribute("min",i),l.setAttribute("max",h),l.setAttribute("step",a),l}},{key:"getStepperButtons",value:function(i){var h=document.createElement("div"),a=document.createElement("button");a.setAttribute("type","button"),a.classList.add("stepper-down");var l=document.createElement("button");l.setAttribute("type","button"),l.classList.add("stepper-up"),i.getAttribute("readonly")&&(a.setAttribute("disabled",!0),l.setAttribute("disabled",!0)),a.textContent="-",l.textContent="+";var t=function(u,d){u.value=Number(d||u.value),u.setAttribute("initialized","1")},e=i.getAttribute("min"),o=i.getAttribute("max");return a.addEventListener("click",function(){i.getAttribute("initialized")?e?Number(i.value)>Number(e)&&i.stepDown():i.stepDown():t(i,e),O(i,"change")}),l.addEventListener("click",function(){i.getAttribute("initialized")?o?Number(i.value)<Number(o)&&i.stepUp():i.stepUp():t(i,e),O(i,"change")}),h.appendChild(a),h.appendChild(l),h}},{key:"getRangeOutput",value:function(i,h){var a=document.createElement("output"),l=function(t){a.value=t.currentTarget.value};return i.addEventListener("change",l,!1),i.addEventListener("input",l,!1),a}},{key:"getRangeControl",value:function(i,h){var a=document.createElement("div");return a.classList.add("je-range-control"),h&&a.appendChild(h),a.appendChild(i),a}},{key:"getFormInputField",value:function(i){var h=document.createElement("input");return h.setAttribute("type",i),h}},{key:"afterInputReady",value:function(i){}},{key:"getFormControl",value:function(i,h,a,l,t){var e=document.createElement("div");return e.classList.add("form-control"),i&&(e.appendChild(i),t&&i.setAttribute("for",t)),h.type!=="checkbox"&&h.type!=="radio"||!i?(l&&i&&i.appendChild(l),e.appendChild(h)):(h.style.width="auto",i.insertBefore(h,i.firstChild),l&&i.appendChild(l)),a&&e.appendChild(a),e}},{key:"getIndentedPanel",value:function(){var i=document.createElement("div");return i.classList.add("je-indented-panel"),i}},{key:"getTopIndentedPanel",value:function(){var i=document.createElement("div");return i.classList.add("je-indented-panel--top"),i}},{key:"getChildEditorHolder",value:function(){return document.createElement("div")}},{key:"getDescription",value:function(i){var h=document.createElement("p");return window.DOMPurify?h.innerHTML=window.DOMPurify.sanitize(i):h.textContent=this.cleanText(i),h}},{key:"getCheckboxDescription",value:function(i){return this.getDescription(i)}},{key:"getFormInputDescription",value:function(i){return this.getDescription(i)}},{key:"getButtonHolder",value:function(){return document.createElement("span")}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getFormButtonHolder",value:function(i){return this.getButtonHolder()}},{key:"getButton",value:function(i,h,a){var l=document.createElement("button");return l.type="button",this.setButtonText(l,i,h,a),l}},{key:"getFormButton",value:function(i,h,a){return this.getButton(i,h,a)}},{key:"setButtonText",value:function(i,h,a,l){for(;i.firstChild;)i.removeChild(i.firstChild);if(a&&(i.appendChild(a),h=" ".concat(h)),!this.jsoneditor.options.iconlib||!this.jsoneditor.options.remove_button_labels||!a){var t=document.createElement("span");t.appendChild(document.createTextNode(h)),i.appendChild(t)}l&&i.setAttribute("title",l)}},{key:"getTableContainer",value:function(){return document.createElement("div")}},{key:"getTable",value:function(){return document.createElement("table")}},{key:"getTableRow",value:function(){return document.createElement("tr")}},{key:"getTableHead",value:function(){return document.createElement("thead")}},{key:"getTableBody",value:function(){return document.createElement("tbody")}},{key:"getTableHeaderCell",value:function(i){var h=document.createElement("th");return h.textContent=i,h}},{key:"getTableCell",value:function(){return document.createElement("td")}},{key:"getErrorMessage",value:function(i){var h=document.createElement("p");return h.style=h.style||{},h.style.color="red",h.appendChild(document.createTextNode(i)),h}},{key:"addInputError",value:function(i,h){}},{key:"removeInputError",value:function(i){}},{key:"addTableRowError",value:function(i){}},{key:"removeTableRowError",value:function(i){}},{key:"getTabHolder",value:function(i){var h=i===void 0?"":i,a=document.createElement("div");return a.innerHTML="<div class='je-tabholder tabs'></div><div class='content' id='".concat(h,"'></div><div class='je-tabholder--clear'></div>"),a}},{key:"getTopTabHolder",value:function(i){var h=i===void 0?"":i,a=document.createElement("div");return a.innerHTML="<div class='tabs je-tabholder--top'></div><div class='je-tabholder--clear'></div><div class='content' id='".concat(h,"'></div>"),a}},{key:"applyStyles",value:function(i,h){Object.keys(h).forEach(function(a){return i.style[a]=h[a]})}},{key:"closest",value:function(i,h){for(;i&&i!==document;){if(!i[Iu])return!1;if(i[Iu](h))return i;i=i.parentNode}return!1}},{key:"insertBasicTopTab",value:function(i,h){h.firstChild.insertBefore(i,h.firstChild.firstChild)}},{key:"getTab",value:function(i,h){var a=document.createElement("div");return a.appendChild(i),a.id=h,a.classList.add("je-tab"),a}},{key:"getTopTab",value:function(i,h){var a=document.createElement("div");return a.appendChild(i),a.id=h,a.classList.add("je-tab--top"),a}},{key:"getTabContentHolder",value:function(i){return i.children[1]}},{key:"getTopTabContentHolder",value:function(i){return i.children[1]}},{key:"getTabContent",value:function(){return this.getIndentedPanel()}},{key:"getTopTabContent",value:function(){return this.getTopIndentedPanel()}},{key:"markTabActive",value:function(i){this.applyStyles(i.tab,{opacity:1,background:"white"}),i.rowPane!==void 0?i.rowPane.style.display="":i.container.style.display=""}},{key:"markTabInactive",value:function(i){this.applyStyles(i.tab,{opacity:.5,background:""}),i.rowPane!==void 0?i.rowPane.style.display="none":i.container.style.display="none"}},{key:"addTab",value:function(i,h){i.children[0].appendChild(h)}},{key:"addTopTab",value:function(i,h){i.children[0].appendChild(h)}},{key:"getBlockLink",value:function(){var i=document.createElement("a");return i.classList.add("je-block-link"),i}},{key:"getBlockLinkHolder",value:function(){return document.createElement("div")}},{key:"getLinksHolder",value:function(){return document.createElement("div")}},{key:"createMediaLink",value:function(i,h,a){i.appendChild(h),a.classList.add("je-media"),i.appendChild(a)}},{key:"createImageLink",value:function(i,h,a){i.appendChild(h),h.appendChild(a)}},{key:"getFirstTab",value:function(i){return i.firstChild.firstChild}},{key:"getInputGroup",value:function(i,h){}},{key:"cleanText",value:function(i){var h=document.createElement("div");return h.innerHTML=i,h.textContent||h.innerText}},{key:"getDropZone",value:function(i){var h=document.createElement("div");return h.setAttribute("data-text",i),h.classList.add("je-dropzone"),h}},{key:"getUploadPreview",value:function(i,h,a){var l=document.createElement("div");if(l.classList.add("je-upload-preview"),i.mimeType.substr(0,5)==="image"){var t=document.createElement("img");t.src=a,l.appendChild(t)}var e=document.createElement("div");e.innerHTML+="<strong>Name:</strong> ".concat(i.name,"<br><strong>Type:</strong> ").concat(i.type,"<br><strong>Size:</strong> ").concat(i.formattedSize),l.appendChild(e),l.appendChild(h);var o=document.createElement("div");return o.style.clear="left",l.appendChild(o),l}},{key:"getProgressBar",value:function(){var i=document.createElement("progress");return i.setAttribute("max",100),i.setAttribute("value",0),i}},{key:"updateProgressBar",value:function(i,h){i&&i.setAttribute("value",h)}},{key:"updateProgressBarUnknown",value:function(i){i&&i.removeAttribute("value")}}],f&&If(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();function go(c){return go=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},go(c)}function Bf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(go(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(go(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),go(h)==="symbol"?h:String(h)),i)}var h}function ji(){return ji=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=pn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},ji.apply(this,arguments)}function Zl(c,n){return Zl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Zl(c,n)}function pn(c){return pn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},pn(c)}var Bu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Zl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=pn(i);if(h){var o=pn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(go(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getFormInputLabel",value:function(t,e){var o=ji(pn(l.prototype),"getFormInputLabel",this).call(this,t,e);return o.classList.add("je-form-input-label"),o}},{key:"getFormInputDescription",value:function(t){var e=ji(pn(l.prototype),"getFormInputDescription",this).call(this,t);return e.classList.add("je-form-input-label"),e}},{key:"getIndentedPanel",value:function(){var t=ji(pn(l.prototype),"getIndentedPanel",this).call(this);return t.classList.add("je-indented-panel"),t}},{key:"getTopIndentedPanel",value:function(){return this.getIndentedPanel()}},{key:"getChildEditorHolder",value:function(){var t=ji(pn(l.prototype),"getChildEditorHolder",this).call(this);return t.classList.add("je-child-editor-holder"),t}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.classList.add("je-header-button-holder"),t}},{key:"getTable",value:function(){var t=ji(pn(l.prototype),"getTable",this).call(this);return t.classList.add("je-table"),t}},{key:"addInputError",value:function(t,e){var o=this.closest(t,".form-control")||t.controlgroup;t.errmsg?t.errmsg.style.display="block":(t.errmsg=document.createElement("div"),t.errmsg.setAttribute("class","errmsg"),t.errmsg.style=t.errmsg.style||{},t.errmsg.style.color="red",o.appendChild(t.errmsg)),t.errmsg.innerHTML="",t.errmsg.appendChild(document.createTextNode(e))}},{key:"removeInputError",value:function(t){t.style&&(t.style.borderColor=""),t.errmsg&&(t.errmsg.style.display="none")}}])&&Bf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function wo(c){return wo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},wo(c)}function Df(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(wo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(wo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),wo(h)==="symbol"?h:String(h)),i)}var h}function Oi(){return Oi=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=fn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Oi.apply(this,arguments)}function Jl(c,n){return Jl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Jl(c,n)}function fn(c){return fn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},fn(c)}Bu.rules={".je-form-input-label":"display:block;margin-bottom:3px;font-weight:bold",".je-form-input-description":"display:inline-block;margin:0;font-size:0.8em;font-style:italic",".je-indented-panel":"padding:5px;margin:10px;border-radius:3px;border:1px%20solid%20%23ddd",".je-child-editor-holder":"margin-bottom:8px",".je-header-button-holder":"display:inline-block;margin-left:10px;font-size:0.8em;vertical-align:middle",".je-table":"margin-bottom:5px;border-bottom:1px%20solid%20%23ccc",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Du=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Jl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=fn(i);if(h){var o=fn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(wo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getSelectInput",value:function(t,e){var o=Oi(fn(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-control"),o}},{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-md-".concat(e)),o&&t.classList.add("col-md-offset-".concat(o))}},{key:"afterInputReady",value:function(t){if(!t.controlgroup&&(t.controlgroup=this.closest(t,".form-group"),this.closest(t,".compact")&&(t.controlgroup.style.marginBottom=0),this.queuedInputErrorText)){var e=this.queuedInputErrorText;delete this.queuedInputErrorText,this.addInputError(t,e)}}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-control"),t}},{key:"getRangeInput",value:function(t,e,o){return Oi(fn(l.prototype),"getRangeInput",this).call(this,t,e,o)}},{key:"getFormInputField",value:function(t){var e=Oi(fn(l.prototype),"getFormInputField",this).call(this,t);return t!=="checkbox"&&t!=="radio"&&e.classList.add("form-control"),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");return!t||e.type!=="checkbox"&&e.type!=="radio"?(d.classList.add("form-group"),t&&(t.classList.add("control-label"),d.appendChild(t),u&&t.appendChild(u)),d.appendChild(e)):(d.classList.add(e.type),u&&t.appendChild(u),t.insertBefore(e,t.firstChild),d.appendChild(t)),o&&d.appendChild(o),d}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("well","well-sm"),t.style.paddingBottom=0,t}},{key:"getInfoButton",value:function(t){var e=document.createElement("span");e.classList.add("glyphicon","glyphicon-info-sign","pull-right"),e.style.padding=".25rem",e.style.position="relative",e.style.display="inline-block";var o=document.createElement("span");return o.style["font-family"]="sans-serif",o.style.visibility="hidden",o.style["background-color"]="rgba(50, 50, 50, .75)",o.style.margin="0 .25rem",o.style.color="#FAFAFA",o.style.padding=".5rem 1rem",o.style["border-radius"]=".25rem",o.style.width="25rem",o.style.position="absolute",o.innerText=t,e.onmouseover=function(){o.style.visibility="visible"},e.onmouseleave=function(){o.style.visibility="hidden"},e.appendChild(o),e}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("p");return e.classList.add("help-block"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.style.marginLeft="10px",t}},{key:"getButtonHolder",value:function(){var t=document.createElement("span");return t.classList.add("btn-group"),t}},{key:"getButton",value:function(t,e,o){var u=Oi(fn(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-default"),u}},{key:"getTableContainer",value:function(){var t=Oi(fn(l.prototype),"getTableContainer",this).call(this);return t.classList.add("table-responsive"),t}},{key:"getTable",value:function(){var t=document.createElement("table");return t.classList.add("table","table-bordered"),t.style.width="auto",t.style.maxWidth="none",t}},{key:"addInputError",value:function(t,e){t.controlgroup?(t.controlgroup.classList.add("has-error"),t.errmsg?t.errmsg.style.display="":(t.errmsg=document.createElement("p"),t.errmsg.classList.add("help-block","errormsg"),t.controlgroup.appendChild(t.errmsg)),t.errmsg.textContent=e):this.queuedInputErrorText=e}},{key:"removeInputError",value:function(t){t.controlgroup||delete this.queuedInputErrorText,t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("has-error"))}},{key:"getTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML="<ul class='col-md-2 nav nav-pills nav-stacked' id='".concat(e,"' role='tablist'></ul><div class='col-md-10 tab-content active well well-small' id='").concat(e,"'></div>"),o}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML="<ul class='nav nav-tabs' id='".concat(e,"' role='tablist'></ul><div class='tab-content active well well-small' id='").concat(e,"'></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.setAttribute("role","presentation");var u=document.createElement("a");return u.setAttribute("href","#".concat(e)),u.appendChild(t),u.setAttribute("aria-controls",e),u.setAttribute("role","tab"),u.setAttribute("data-toggle","tab"),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.setAttribute("role","presentation");var u=document.createElement("a");return u.setAttribute("href","#".concat(e)),u.appendChild(t),u.setAttribute("aria-controls",e),u.setAttribute("role","tab"),u.setAttribute("data-toggle","tab"),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.classList.add("active"),t.rowPane!==void 0?t.rowPane.classList.add("active"):t.container.classList.add("active")}},{key:"markTabInactive",value:function(t){t.tab.classList.remove("active"),t.rowPane!==void 0?t.rowPane.classList.remove("active"):t.container.classList.remove("active")}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("progress-bar"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","progress-striped","active"),e.removeAttribute("aria-valuenow"),e.style.width="100%",e.innerHTML=""}}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);var u=document.createElement("div");u.classList.add("input-group-btn"),o.appendChild(u);for(var d=0;d<e.length;d++)u.appendChild(e[d]);return o}}}])&&Df(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function _o(c){return _o=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},_o(c)}function Nf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(_o(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(_o(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),_o(h)==="symbol"?h:String(h)),i)}var h}function Ei(){return Ei=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=mn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Ei.apply(this,arguments)}function Yl(c,n){return Yl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Yl(c,n)}function mn(c){return mn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},mn(c)}Du.rules={},_(3843);var $f={disable_theme_rules:!1,input_size:"normal",custom_forms:!1,object_indent:!0,object_background:"bg-light",object_text:"",table_border:!1,table_zebrastyle:!1,tooltip:"bootstrap"},Nu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Yl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=mn(i);if(h){var o=mn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(_o(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,$f)}return n=l,(f=[{key:"getSelectInput",value:function(t,e){var o=Ei(mn(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-control"),this.options.custom_forms===!1?(this.options.input_size==="small"&&o.classList.add("form-control-sm"),this.options.input_size==="large"&&o.classList.add("form-control-lg")):(o.classList.remove("form-control"),o.classList.add("custom-select"),this.options.input_size==="small"&&o.classList.add("custom-select-sm"),this.options.input_size==="large"&&o.classList.add("custom-select-lg")),o}},{key:"getContainer",value:function(){var t=document.createElement("div");return this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-md-".concat(e)),o&&t.classList.add("offset-md-".concat(o))}},{key:"afterInputReady",value:function(t){if(!t.controlgroup){var e=t.name;t.id=e;var o=t.parentNode.parentNode.getElementsByTagName("label")[0];o&&(o.htmlFor=e),t.controlgroup=this.closest(t,".form-group")}}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-control"),this.options.input_size==="small"&&t.classList.add("form-control-sm"),this.options.input_size==="large"&&t.classList.add("form-control-lg"),t}},{key:"getRangeInput",value:function(t,e,o){var u=Ei(mn(l.prototype),"getRangeInput",this).call(this,t,e,o);return this.options.custom_forms===!0&&(u.classList.remove("form-control"),u.classList.add("custom-range")),u}},{key:"getStepperButtons",value:function(t){var e=document.createElement("div"),o=document.createElement("div"),u=document.createElement("div"),d=document.createElement("button");d.setAttribute("type","button");var x=document.createElement("button");x.setAttribute("type","button"),e.appendChild(o),e.appendChild(t),e.appendChild(u),o.appendChild(d),u.appendChild(x),e.classList.add("input-group"),o.classList.add("input-group-prepend"),u.classList.add("input-group-append"),d.classList.add("btn"),d.classList.add("btn-secondary"),d.classList.add("stepper-down"),x.classList.add("btn"),x.classList.add("btn-secondary"),x.classList.add("stepper-up"),t.getAttribute("readonly")&&(d.setAttribute("disabled",!0),x.setAttribute("disabled",!0)),d.textContent="-",x.textContent="+";var P=function(nt,ut){nt.value=Number(ut||nt.value),nt.setAttribute("initialized","1")},D=t.getAttribute("min"),J=t.getAttribute("max");return t.addEventListener("change",function(){t.getAttribute("initialized")||t.setAttribute("initialized","1")}),d.addEventListener("click",function(){t.getAttribute("initialized")?D?Number(t.value)>Number(D)&&t.stepDown():t.stepDown():P(t,D),O(t,"change")}),x.addEventListener("click",function(){t.getAttribute("initialized")?J?Number(t.value)<Number(J)&&t.stepUp():t.stepUp():P(t,D),O(t,"change")}),e}},{key:"getFormInputField",value:function(t){var e=Ei(mn(l.prototype),"getFormInputField",this).call(this,t);return t!=="checkbox"&&t!=="radio"&&t!=="file"&&(e.classList.add("form-control"),this.options.input_size==="small"&&e.classList.add("form-control-sm"),this.options.input_size==="large"&&e.classList.add("form-control-lg")),t==="file"&&e.classList.add("form-control-file"),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");if(d.classList.add("form-group"),!t||e.type!=="checkbox"&&e.type!=="radio")t&&(d.appendChild(t),u&&d.appendChild(u)),d.appendChild(e);else{var x=document.createElement("div");this.options.custom_forms===!1?(x.classList.add("form-check"),e.classList.add("form-check-input"),t.classList.add("form-check-label")):(x.classList.add("custom-control"),e.classList.add("custom-control-input"),t.classList.add("custom-control-label"),e.type==="checkbox"?x.classList.add("custom-checkbox"):x.classList.add("custom-radio"));var P=(Date.now()*Math.random()).toFixed(0);e.setAttribute("id",P),t.setAttribute("for",P),x.appendChild(e),x.appendChild(t),u&&x.appendChild(u),d.appendChild(x)}return o&&d.appendChild(o),d}},{key:"getInfoButton",value:function(t){var e=document.createElement("button");e.type="button",e.classList.add("ml-3","jsoneditor-twbs4-text-button"),e.setAttribute("data-toggle","tooltip"),e.setAttribute("data-placement","auto"),e.title=t;var o=document.createTextNode("ⓘ");return e.appendChild(o),this.options.tooltip==="bootstrap"?window.jQuery&&window.jQuery().tooltip?window.jQuery(e).tooltip():console.warn("Could not find popper jQuery plugin of Bootstrap."):this.options.tooltip==="css"&&e.classList.add("je-tooltip"),e}},{key:"getCheckbox",value:function(){return this.getFormInputField("checkbox")}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){var d=document.createElement("div");d.classList.add("form-group"),e&&(d.appendChild(e),u&&e.appendChild(u));var x=document.createElement("div");return Object.values(t).forEach(function(P){var D=P.firstChild;x.appendChild(D)}),d.appendChild(x),o&&d.appendChild(o),d}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in t)e.setAttribute(o,t[o]);return this.options.custom_forms===!1?e.classList.add("form-check-input"):e.classList.add("custom-control-input"),e}},{key:"getFormRadioLabel",value:function(t,e){var o=document.createElement("label");return this.options.custom_forms===!1?o.classList.add("form-check-label"):o.classList.add("custom-control-label"),o.appendChild(document.createTextNode(t)),o}},{key:"getFormRadioControl",value:function(t,e,o){var u=document.createElement("div");return this.options.custom_forms===!1?u.classList.add("form-check"):u.classList.add("custom-control","custom-radio"),u.appendChild(e),u.appendChild(t),o&&(this.options.custom_forms===!1?u.classList.add("form-check-inline"):u.classList.add("custom-control-inline")),u}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("card","card-body","mb-3"),this.options.object_background&&t.classList.add(this.options.object_background),this.options.object_text&&t.classList.add(this.options.object_text),t}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("small");return e.classList.add("form-text"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getHeader",value:function(t,e){var o=document.createElement("h3");return o.classList.add("card-title"),o.classList.add("level-"+e),typeof t=="string"?o.textContent=t:o.appendChild(t),o.style.display="inline-block",o}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getButtonHolder",value:function(){var t=document.createElement("span");return t.classList.add("btn-group"),t}},{key:"getFormButtonHolder",value:function(t){var e=this.getButtonHolder();return e.classList.add("d-block"),t==="center"?e.classList.add("text-center"):t==="right"&&e.classList.add("text-right"),e}},{key:"getButton",value:function(t,e,o){var u=Ei(mn(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-secondary","btn-sm"),u}},{key:"getTableContainer",value:function(){var t=Ei(mn(l.prototype),"getTableContainer",this).call(this);return t.classList.add("table-responsive"),t}},{key:"getTable",value:function(){var t=document.createElement("table");return t.classList.add("table","table-sm"),this.options.table_border&&t.classList.add("table-bordered"),this.options.table_zebrastyle&&t.classList.add("table-striped"),t}},{key:"getErrorMessage",value:function(t){var e=document.createElement("div");return e.classList.add("alert","alert-danger"),e.setAttribute("role","alert"),e.appendChild(document.createTextNode(t)),e}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("is-invalid"),t.errmsg||(t.errmsg=document.createElement("p"),t.errmsg.classList.add("invalid-feedback"),t.controlgroup.appendChild(t.errmsg),t.errmsg.style.display="block"),t.errmsg.style.display="block",t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("is-invalid"))}},{key:"getTabHolder",value:function(t){var e=document.createElement("div"),o=t===void 0?"":t;return e.innerHTML="<div class='col-md-2' id='".concat(o,"'><ul class='nav flex-column nav-pills'></ul></div><div class='col-md-10'><div class='tab-content' id='").concat(o,"'></div></div>"),e.classList.add("row"),e}},{key:"addTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.classList.add("card"),o.innerHTML="<div class='card-header'><ul class='nav nav-tabs card-header-tabs' id='".concat(e,"'></ul></div><div class='card-body'><div class='tab-content' id='").concat(e,"'></div></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.firstChild.classList.add("active"),t.rowPane!==void 0?t.rowPane.classList.add("active"):t.container.classList.add("active")}},{key:"markTabInactive",value:function(t){t.tab.firstChild.classList.remove("active"),t.rowPane!==void 0?t.rowPane.classList.remove("active"):t.container.classList.remove("active")}},{key:"insertBasicTopTab",value:function(t,e){e.children[0].children[0].insertBefore(t,e.children[0].children[0].firstChild)}},{key:"addTopTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTopTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getFirstTab",value:function(t){return t.firstChild.firstChild.firstChild}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("progress-bar"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","progress-striped","active"),e.removeAttribute("aria-valuenow"),e.style.width="100%",e.innerHTML=""}}},{key:"getBlockLink",value:function(){var t=document.createElement("a");return t.classList.add("mb-3","d-inline-block"),t}},{key:"getLinksHolder",value:function(){return document.createElement("div")}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);var u=document.createElement("div");u.classList.add("input-group-append"),o.appendChild(u);for(var d=0;d<e.length;d++)e[d].classList.remove("mr-2","btn-secondary"),e[d].classList.add("btn-outline-secondary"),u.appendChild(e[d]);return o}}}])&&Nf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function xo(c){return xo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},xo(c)}function Mf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(xo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(xo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),xo(h)==="symbol"?h:String(h)),i)}var h}function Ci(){return Ci=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=yn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},Ci.apply(this,arguments)}function Xl(c,n){return Xl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Xl(c,n)}function yn(c){return yn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},yn(c)}Nu.rules={".jsoneditor-twbs4-text-button":"background:none;padding:0;border:0;color:currentColor","td > .form-group":"margin-bottom:0",".json-editor-btn-upload":"margin-top:1rem",".je-noindent .card":"padding:0;border:0",".je-tooltip:hover::before":"display:block;position:absolute;font-size:0.8em;color:%23fff;border-radius:0.2em;content:attr(title);background-color:%23000;margin-top:-2.5em;padding:0.3em",".je-tooltip:hover::after":"display:block;position:absolute;font-size:0.8em;color:%23fff",".select2-container--default .select2-selection--single":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__arrow":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__rendered":"line-height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".selectize-control.form-control":"padding:0",".selectize-dropdown.form-control":"padding:0;height:auto",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Hf={disable_theme_rules:!1,input_size:"normal",object_indent:!0,object_background:"bg-light",object_text:"",table_border:!1,table_zebrastyle:!1,tooltip:"bootstrap"},$u=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Xl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=yn(i);if(h){var o=yn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(xo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,Hf)}return n=l,(f=[{key:"getSelectInput",value:function(t,e){var o=Ci(yn(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-control"),o.classList.add("form-select"),this.options.input_size==="small"&&o.classList.add("form-control-sm"),this.options.input_size==="large"&&o.classList.add("form-control-lg"),o}},{key:"getContainer",value:function(){var t=document.createElement("div");return this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-md-".concat(e)),o&&t.classList.add("offset-md-".concat(o))}},{key:"afterInputReady",value:function(t){if(!t.controlgroup){var e=t.name;t.id=e;var o=t.parentNode.parentNode.getElementsByTagName("label")[0];o&&(o.classList.add("form-label"),o.htmlFor=e),t.controlgroup=this.closest(t,".form-group")}}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-control"),this.options.input_size==="small"&&t.classList.add("form-control-sm"),this.options.input_size==="large"&&t.classList.add("form-control-lg"),t}},{key:"getRangeInput",value:function(t,e,o){var u=Ci(yn(l.prototype),"getRangeInput",this).call(this,t,e,o);return u.classList.remove("form-control"),u.classList.add("form-range"),u}},{key:"getStepperButtons",value:function(t){var e=document.createElement("div"),o=document.createElement("button");o.setAttribute("type","button");var u=document.createElement("button");u.setAttribute("type","button"),e.appendChild(o),e.appendChild(t),e.appendChild(u),e.classList.add("input-group"),o.classList.add("btn"),o.classList.add("btn-secondary"),o.classList.add("stepper-down"),u.classList.add("btn"),u.classList.add("btn-secondary"),u.classList.add("stepper-up"),t.getAttribute("readonly")&&(o.setAttribute("disabled",!0),u.setAttribute("disabled",!0)),o.textContent="-",u.textContent="+";var d=function(D,J){D.value=Number(J||D.value),D.setAttribute("initialized","1")},x=t.getAttribute("min"),P=t.getAttribute("max");return t.addEventListener("change",function(){t.getAttribute("initialized")||t.setAttribute("initialized","1")}),o.addEventListener("click",function(){t.getAttribute("initialized")?x?Number(t.value)>Number(x)&&t.stepDown():t.stepDown():d(t,x),O(t,"change")}),u.addEventListener("click",function(){t.getAttribute("initialized")?P?Number(t.value)<Number(P)&&t.stepUp():t.stepUp():d(t,x),O(t,"change")}),e}},{key:"getFormInputField",value:function(t){var e=Ci(yn(l.prototype),"getFormInputField",this).call(this,t);return t!=="checkbox"&&t!=="radio"&&(e.classList.add("form-control"),this.options.input_size==="small"&&e.classList.add("form-control-sm"),this.options.input_size==="large"&&e.classList.add("form-control-lg")),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");if(d.classList.add("form-group"),!t||e.type!=="checkbox"&&e.type!=="radio")t&&(t.classList.add("form-label"),d.appendChild(t),u&&d.appendChild(u)),d.appendChild(e);else{var x=document.createElement("div");x.classList.add("form-check"),e.classList.add("form-check-input"),t.classList.add("form-check-label");var P=(Date.now()*Math.random()).toFixed(0);e.setAttribute("id",P),t.setAttribute("for",P),x.appendChild(e),x.appendChild(t),u&&x.appendChild(u),d.appendChild(x)}return o&&d.appendChild(o),d}},{key:"getInfoButton",value:function(t){var e=document.createElement("button");e.type="button",e.classList.add("ms-3","jsoneditor-twbs5-text-button"),e.setAttribute("data-toggle","tooltip"),e.setAttribute("data-placement","auto"),e.title=t;var o=document.createTextNode("ⓘ");return e.appendChild(o),this.options.tooltip==="bootstrap"?window.jQuery&&window.jQuery().tooltip?window.jQuery(e).tooltip():console.warn("Could not find popper jQuery plugin of Bootstrap."):this.options.tooltip==="css"&&e.classList.add("je-tooltip"),e}},{key:"getCheckbox",value:function(){return this.getFormInputField("checkbox")}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){var d=document.createElement("div");d.classList.add("form-group"),e&&(d.appendChild(e),u&&e.appendChild(u));var x=document.createElement("div");return Object.values(t).forEach(function(P){var D=P.firstChild;x.appendChild(D)}),d.appendChild(x),o&&d.appendChild(o),d}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in t)e.setAttribute(o,t[o]);return e.classList.add("form-check-input"),e}},{key:"getFormRadioLabel",value:function(t,e){var o=document.createElement("label");return o.classList.add("form-check-label"),o.appendChild(document.createTextNode(t)),o}},{key:"getFormRadioControl",value:function(t,e,o){var u=document.createElement("div");return u.classList.add("form-check"),u.appendChild(e),u.appendChild(t),o&&u.classList.add("form-check-inline"),u}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("card","card-body","my-3"),this.options.object_background&&t.classList.add(this.options.object_background),this.options.object_text&&t.classList.add(this.options.object_text),t}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("small");return e.classList.add("form-text"),e.classList.add("d-block"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getHeader",value:function(t,e){var o=document.createElement("h3");return o.classList.add("card-title"),o.classList.add("level-"+e),typeof t=="string"?o.textContent=t:o.appendChild(t),o.style.display="inline-block",o}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getButtonHolder",value:function(){var t=document.createElement("span");return t.classList.add("btn-group"),t}},{key:"getFormButtonHolder",value:function(t){var e=this.getButtonHolder();return e.classList.add("d-block"),t==="center"?e.classList.add("text-center"):t==="right"&&e.classList.add("text-end"),e}},{key:"getButton",value:function(t,e,o){var u=Ci(yn(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-secondary","btn-sm"),u}},{key:"getTableContainer",value:function(){var t=Ci(yn(l.prototype),"getTableContainer",this).call(this);return t.classList.add("table-responsive"),t}},{key:"getTable",value:function(){var t=document.createElement("table");return t.classList.add("table","table-sm"),this.options.table_border&&t.classList.add("table-bordered"),this.options.table_zebrastyle&&t.classList.add("table-striped"),t}},{key:"getErrorMessage",value:function(t){var e=document.createElement("div");return e.classList.add("alert","alert-danger"),e.setAttribute("role","alert"),e.appendChild(document.createTextNode(t)),e}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("is-invalid"),t.errmsg||(t.errmsg=document.createElement("p"),t.errmsg.classList.add("invalid-feedback"),t.controlgroup.appendChild(t.errmsg),t.errmsg.style.display="block"),t.errmsg.style.display="block",t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("is-invalid"))}},{key:"getTabHolder",value:function(t){var e=document.createElement("div"),o=t===void 0?"":t;return e.innerHTML="<div class='col-md-2' id='".concat(o,"'><ul class='nav flex-column nav-pills'></ul></div><div class='col-md-10'><div class='tab-content' id='").concat(o,"'></div></div>"),e.classList.add("row"),e}},{key:"addTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.classList.add("card"),o.innerHTML="<div class='card-header'><ul class='nav nav-tabs card-header-tabs' id='".concat(e,"'></ul></div><div class='card-body'><div class='tab-content' id='").concat(e,"'></div></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item");var u=document.createElement("a");return u.classList.add("nav-link"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.classList.add("tab-pane"),t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.firstChild.classList.add("active"),t.rowPane!==void 0?t.rowPane.classList.add("active"):t.container.classList.add("active")}},{key:"markTabInactive",value:function(t){t.tab.firstChild.classList.remove("active"),t.rowPane!==void 0?t.rowPane.classList.remove("active"):t.container.classList.remove("active")}},{key:"insertBasicTopTab",value:function(t,e){e.children[0].children[0].insertBefore(t,e.children[0].children[0].firstChild)}},{key:"addTopTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTopTabContentHolder",value:function(t){return t.children[1].children[0]}},{key:"getFirstTab",value:function(t){return t.firstChild.firstChild.firstChild}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("progress-bar"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","progress-striped","active"),e.removeAttribute("aria-valuenow"),e.style.width="100%",e.innerHTML=""}}},{key:"getBlockLink",value:function(){var t=document.createElement("a");return t.classList.add("mb-3","d-inline-block"),t}},{key:"getLinksHolder",value:function(){return document.createElement("div")}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);for(var u=0;u<e.length;u++)e[u].classList.remove("me-2","btn-secondary"),e[u].classList.add("btn-outline-secondary"),o.appendChild(e[u]);return o}}}])&&Mf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function ko(c){return ko=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},ko(c)}function Ff(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(ko(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(ko(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),ko(h)==="symbol"?h:String(h)),i)}var h}function jo(){return jo=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=Pn(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},jo.apply(this,arguments)}function Kl(c,n){return Kl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Kl(c,n)}function Pn(c){return Pn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Pn(c)}$u.rules={".form-group":"margin-bottom:1rem",".form-text":"display:block",".jsoneditor-twbs5-text-button":"background:none;padding:0;border:0;color:currentColor","td > .form-group":"margin-bottom:0",".json-editor-btn-upload":"margin-top:1rem",".je-noindent .card":"padding:0;border:0",".je-tooltip:hover::before":"display:block;position:absolute;font-size:0.8em;color:%23fff;border-radius:0.2em;content:attr(title);background-color:%23000;margin-top:-2.5em;padding:0.3em",".je-tooltip:hover::after":"display:block;position:absolute;font-size:0.8em;color:%23fff",".select2-container--default .select2-selection--single":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__arrow":"height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".select2-container--default .select2-selection--single .select2-selection__rendered":"line-height:calc(1.5em%20%2B%200.75rem%20%2B%202px)",".selectize-control.form-control":"padding:0",".selectize-dropdown.form-control":"padding:0;height:auto",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Mu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Kl(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Pn(i);if(h){var o=Pn(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(ko(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"getTable",value:function(){var t=jo(Pn(l.prototype),"getTable",this).call(this);return t.setAttribute("cellpadding",5),t.setAttribute("cellspacing",0),t}},{key:"getTableHeaderCell",value:function(t){var e=jo(Pn(l.prototype),"getTableHeaderCell",this).call(this,t);return e.classList.add("ui-state-active"),e.style.fontWeight="bold",e}},{key:"getTableCell",value:function(){var t=jo(Pn(l.prototype),"getTableCell",this).call(this);return t.classList.add("ui-widget-content"),t}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.style.marginLeft="10px",t.style.fontSize=".6em",t.style.display="inline-block",t}},{key:"getFormInputDescription",value:function(t){var e=this.getDescription(t);return e.style.marginLeft="10px",e.style.display="inline-block",e}},{key:"getFormControl",value:function(t,e,o,u){var d=jo(Pn(l.prototype),"getFormControl",this).call(this,t,e,o,u);return e.type==="checkbox"?(d.style.lineHeight="25px",d.style.padding="3px 0"):d.style.padding="4px 0 8px 0",d}},{key:"getDescription",value:function(t){var e=document.createElement("span");return e.style.fontSize=".8em",e.style.fontStyle="italic",window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getButtonHolder",value:function(){var t=document.createElement("div");return t.classList.add("ui-buttonset"),t.style.fontSize=".7em",t}},{key:"getFormInputLabel",value:function(t,e){var o=document.createElement("label");return o.style.fontWeight="bold",o.style.display="block",o.textContent=t,e&&o.classList.add("required"),o}},{key:"getButton",value:function(t,e,o){var u=document.createElement("button");u.classList.add("ui-button","ui-widget","ui-state-default","ui-corner-all"),e&&!t?(u.classList.add("ui-button-icon-only"),e.classList.add("ui-button-icon-primary","ui-icon-primary"),u.appendChild(e)):e?(u.classList.add("ui-button-text-icon-primary"),e.classList.add("ui-button-icon-primary","ui-icon-primary"),u.appendChild(e)):u.classList.add("ui-button-text-only");var d=document.createElement("span");return d.classList.add("ui-button-text"),d.textContent=t||o||".",u.appendChild(d),u.setAttribute("title",o),u}},{key:"setButtonText",value:function(t,e,o,u){t.innerHTML="",t.classList.add("ui-button","ui-widget","ui-state-default","ui-corner-all"),o&&!e?(t.classList.add("ui-button-icon-only"),o.classList.add("ui-button-icon-primary","ui-icon-primary"),t.appendChild(o)):o?(t.classList.add("ui-button-text-icon-primary"),o.classList.add("ui-button-icon-primary","ui-icon-primary"),t.appendChild(o)):t.classList.add("ui-button-text-only");var d=document.createElement("span");d.classList.add("ui-button-text"),d.textContent=e||u||".",t.appendChild(d),t.setAttribute("title",u)}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("ui-widget-content","ui-corner-all"),t.style.padding="1em 1.4em",t.style.marginBottom="20px",t}},{key:"afterInputReady",value:function(t){if(!t.controls&&(t.controls=this.closest(t,".form-control"),this.queuedInputErrorText)){var e=this.queuedInputErrorText;delete this.queuedInputErrorText,this.addInputError(t,e)}}},{key:"addInputError",value:function(t,e){t.controls?(t.errmsg?t.errmsg.style.display="":(t.errmsg=document.createElement("div"),t.errmsg.classList.add("ui-state-error"),t.controls.appendChild(t.errmsg)),t.errmsg.textContent=e):this.queuedInputErrorText=e}},{key:"removeInputError",value:function(t){t.controls||delete this.queuedInputErrorText,t.errmsg&&(t.errmsg.style.display="none")}},{key:"markTabActive",value:function(t){t.tab.classList.remove("ui-widget-header"),t.tab.classList.add("ui-state-active"),t.rowPane!==void 0?t.rowPane.style.display="":t.container.style.display=""}},{key:"markTabInactive",value:function(t){t.tab.classList.add("ui-widget-header"),t.tab.classList.remove("ui-state-active"),t.rowPane!==void 0?t.rowPane.style.display="none":t.container.style.display="none"}}])&&Ff(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function Oo(c){return Oo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Oo(c)}function Vf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Oo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Oo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Oo(h)==="symbol"?h:String(h)),i)}var h}function Ql(c,n){return Ql=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},Ql(c,n)}function Ts(c){return Ts=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ts(c)}Mu.rules={'div[data-schemaid="root"]:after':'position:relative;color:red;margin:10px 0;font-weight:600;display:block;width:100%;text-align:center;content:"This is an old JSON-Editor 1.x Theme and might not display elements correctly when used with the 2.x version"'};var Hu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Ql(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=Ts(i);if(h){var o=Ts(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Oo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,l),a.apply(this,arguments)}return n=l,(f=[{key:"addInputError",value:function(t,e){if(t.errmsg)t.errmsg.style.display="block";else{var o=this.closest(t,".form-control");t.errmsg=document.createElement("div"),t.errmsg.setAttribute("class","errmsg"),o.nodeName&&o.appendChild(t.errmsg)}t.errmsg.innerHTML="",t.errmsg.appendChild(document.createTextNode(e))}},{key:"removeInputError",value:function(t){t.style&&(t.style.borderColor=""),t.errmsg&&(t.errmsg.style.display="none")}}])&&Vf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function Eo(c){return Eo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Eo(c)}function zf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Eo(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Eo(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Eo(h)==="symbol"?h:String(h)),i)}var h}function gr(){return gr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=tr(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},gr.apply(this,arguments)}function tc(c,n){return tc=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},tc(c,n)}function tr(c){return tr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},tr(c)}Hu.rules={".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Uf={disable_theme_rules:!1,label_bold:!0,align_bottom:!1,object_indent:!1,object_border:!1,table_border:!1,table_zebrastyle:!1,input_size:"normal"},Fu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&tc(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=tr(i);if(h){var o=tr(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Eo(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,Uf)}return n=l,(f=[{key:"setGridColumnSize",value:function(t,e,o){t.classList.add("col-".concat(e)),o&&t.classList.add("col-mx-auto")}},{key:"getGridContainer",value:function(){var t=document.createElement("div");return t.classList.add("container"),this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"getGridRow",value:function(){var t=document.createElement("div");return t.classList.add("columns"),t}},{key:"getGridColumn",value:function(){var t=document.createElement("div");return t.classList.add("column"),this.options.align_bottom&&t.classList.add("je-align-bottom"),t}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("je-panel"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getTopIndentedPanel",value:function(){var t=document.createElement("div");return t.classList.add("je-panel-top"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getHeaderButtonHolder",value:function(){return this.getButtonHolder()}},{key:"getButtonHolder",value:function(){var t=gr(tr(l.prototype),"getButtonHolder",this).call(this);return t.classList.add("btn-group"),t}},{key:"getFormButtonHolder",value:function(t){var e=gr(tr(l.prototype),"getFormButtonHolder",this).call(this);return e.classList.remove("btn-group"),e.classList.add("d-block"),t==="center"?e.classList.add("text-center"):t==="right"?e.classList.add("text-right"):e.classList.add("text-left"),e}},{key:"getFormButton",value:function(t,e,o){var u=gr(tr(l.prototype),"getFormButton",this).call(this,t,e,o);return u.classList.add("btn","btn-primary","mx-2","my-1"),this.options.input_size!=="small"&&u.classList.remove("btn-sm"),this.options.input_size==="large"&&u.classList.add("btn-lg"),u}},{key:"getButton",value:function(t,e,o){var u=gr(tr(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("btn","btn-sm","btn-primary","mr-2","my-1"),u}},{key:"getHeader",value:function(t,e){var o=document.createElement("h4");return typeof t=="string"?o.textContent=t:o.appendChild(t),o.style.display="inline-block",o}},{key:"getFormInputDescription",value:function(t){var e=gr(tr(l.prototype),"getFormInputDescription",this).call(this,t);return e.classList.add("je-desc","hide-sm"),e}},{key:"getFormInputLabel",value:function(t,e){var o=gr(tr(l.prototype),"getFormInputLabel",this).call(this,t,e);return this.options.label_bold&&o.classList.add("je-label"),o}},{key:"getCheckbox",value:function(){return this.getFormInputField("checkbox")}},{key:"getCheckboxLabel",value:function(t,e){var o=gr(tr(l.prototype),"getCheckboxLabel",this).call(this,t,e),u=document.createElement("i");return u.classList.add("form-icon"),o.classList.add("form-checkbox","pr-0"),o.insertBefore(u,o.firstChild),o}},{key:"getFormCheckboxControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("form-inline"),t}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){return gr(tr(l.prototype),"getMultiCheckboxHolder",this).call(this,t,e,o,u)}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in t)e.setAttribute(o,t[o]);return e}},{key:"getFormRadioLabel",value:function(t,e){var o=gr(tr(l.prototype),"getFormRadioLabel",this).call(this,t,e),u=document.createElement("i");return u.classList.add("form-icon"),o.classList.add("form-radio"),o.insertBefore(u,o.firstChild),o}},{key:"getFormRadioControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("form-inline"),t}},{key:"getFormInputField",value:function(t){var e=gr(tr(l.prototype),"getFormInputField",this).call(this,t);return["checkbox","radio"].includes(t)||e.classList.add("form-input"),e}},{key:"getRangeInput",value:function(t,e,o){var u=this.getFormInputField("range");return u.classList.add("slider"),u.classList.remove("form-input"),u.setAttribute("oninput",'this.setAttribute("value", this.value)'),u.setAttribute("min",t),u.setAttribute("max",e),u.setAttribute("step",o),u}},{key:"getRangeControl",value:function(t,e){var o=gr(tr(l.prototype),"getRangeControl",this).call(this,t,e);return o.classList.add("text-center"),o}},{key:"getSelectInput",value:function(t,e){var o=gr(tr(l.prototype),"getSelectInput",this).call(this,t);return o.classList.add("form-select"),o}},{key:"getTextareaInput",value:function(){var t=document.createElement("textarea");return t.classList.add("form-input"),t}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");return d.classList.add("form-group"),!t||e.type!=="checkbox"&&e.type!=="radio"?(t&&(t.classList.add("form-label"),d.appendChild(t),u&&t.appendChild(u)),d.appendChild(e)):(d.classList.add(e.type),u&&t.appendChild(u),t.insertBefore(e,t.firstChild),d.appendChild(t)),this.options.input_size==="small"?e.classList.add("input-sm","select-sm"):this.options.input_size==="large"&&e.classList.add("input-lg","select-lg"),e.type!=="checkbox"&&d.appendChild(e),o&&d.appendChild(o),d}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("input-group"),o.appendChild(t);for(var u=0;u<e.length;u++)e[u].classList.add("input-group-btn"),e[u].classList.remove("btn-sm","mr-2","my-1"),o.appendChild(e[u]);return o}}},{key:"getInfoButton",value:function(t){var e=document.createElement("div");e.classList.add("popover","popover-left","float-right");var o=document.createElement("button");o.classList.add("btn","btn-secondary","btn-info","btn-action","s-circle"),o.setAttribute("tabindex","-1"),e.appendChild(o);var u=document.createTextNode("I");o.appendChild(u);var d=document.createElement("div");d.classList.add("popover-container"),e.appendChild(d);var x=document.createElement("div");x.classList.add("card"),d.appendChild(x);var P=document.createElement("div");return P.classList.add("card-body"),P.innerHTML=t,x.appendChild(P),e}},{key:"getTable",value:function(){var t=gr(tr(l.prototype),"getTable",this).call(this);return t.classList.add("table","table-scroll"),this.options.table_border&&t.classList.add("je-table-border"),this.options.table_zebrastyle&&t.classList.add("table-striped"),t}},{key:"getProgressBar",value:function(){var t=gr(tr(l.prototype),"getProgressBar",this).call(this);return t.classList.add("progress"),t}},{key:"getTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.classList.add("columns"),o.innerHTML='<div class="column col-2"></div><div class="column col-10 content" id="'.concat(e,'"></div>'),o}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML='<ul class="tab"></ul><div class="content" id="'.concat(e,'"></div>'),o}},{key:"getTab",value:function(t,e){var o=document.createElement("a");return o.classList.add("btn","btn-secondary","btn-block"),o.setAttribute("href","#".concat(e)),o.appendChild(t),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.id=e,o.classList.add("tab-item");var u=document.createElement("a");return u.setAttribute("href","#".concat(e)),u.appendChild(t),o.appendChild(u),o}},{key:"markTabActive",value:function(t){t.tab.classList.add("active"),t.rowPane!==void 0?t.rowPane.style.display="":t.container.style.display=""}},{key:"markTabInactive",value:function(t){t.tab.classList.remove("active"),t.rowPane!==void 0?t.rowPane.style.display="none":t.container.style.display="none"}},{key:"afterInputReady",value:function(t){if(t.localName==="select"){if(t.classList.contains("selectized")){var e=t.nextSibling;e&&(e.classList.remove("form-select"),Array.from(e.querySelectorAll(".form-select")).forEach(function(u){u.classList.remove("form-select")}))}else if(t.classList.contains("select2-hidden-accessible")){var o=t.nextSibling;o&&o.querySelector(".select2-selection--single")&&o.classList.add("form-select")}}t.controlgroup||(t.controlgroup=this.closest(t,".form-group"),this.closest(t,".compact")&&(t.controlgroup.style.marginBottom=0))}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("has-error"),t.errmsg||(t.errmsg=document.createElement("p"),t.errmsg.classList.add("form-input-hint"),t.controlgroup.appendChild(t.errmsg)),t.errmsg.classList.remove("d-hide"),t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.classList.add("d-hide"),t.controlgroup.classList.remove("has-error"))}}])&&zf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);function Co(c){return Co=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},Co(c)}function qf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(Co(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(Co(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),Co(h)==="symbol"?h:String(h)),i)}var h}function wr(){return wr=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(c,n,f){var i=function(a,l){for(;!Object.prototype.hasOwnProperty.call(a,l)&&(a=er(a))!==null;);return a}(c,n);if(i){var h=Object.getOwnPropertyDescriptor(i,n);return h.get?h.get.call(arguments.length<3?c:f):h.value}},wr.apply(this,arguments)}function ec(c,n){return ec=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(f,i){return f.__proto__=i,f},ec(c,n)}function er(c){return er=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},er(c)}Fu.rules={"*":"--primary-color:%235755d9;--gray-color:%23bcc3ce;--light-color:%23fff",".slider:focus":"box-shadow:none","h4 > label + .btn-group":"margin-left:1rem",".text-right > button":"margin-right:0%20!important",".text-left > button":"margin-left:0%20!important",".property-selector":"font-size:0.7rem;font-weight:normal;max-height:260px%20!important;width:395px%20!important",".property-selector .form-checkbox":"margin:0",textarea:"width:100%25;min-height:2rem;resize:vertical",table:"border-collapse:collapse",".table td":"padding:0.4rem%200.4rem",".mr-5":"margin-right:1rem%20!important","div[data-schematype]:not([data-schematype='object'])":"transition:0.5s","div[data-schematype]:not([data-schematype='object']):hover":"background-color:%23eee",".je-table-border td":"border:0.05rem%20solid%20%23dadee4%20!important",".btn-info":"font-size:0.5rem;font-weight:bold;height:0.8rem;padding:0.15rem%200;line-height:0.8;margin:0.3rem%200%200.3rem%200.1rem",".je-label + select":"min-width:5rem",".je-label":"font-weight:600",".btn-action.btn-info":"width:0.8rem",".je-border":"border:0.05rem%20solid%20%23dadee4",".je-panel":"padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".je-panel-top":"padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".required:after":"content:%22%20*%22;color:red;font:inherit",".je-align-bottom":"margin-top:auto",".je-desc":"font-size:smaller;margin:0.2rem%200",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem;border:3px%20solid%20white;box-shadow:0px%200px%208px%20rgba(0%2C%200%2C%200%2C%200.3);box-sizing:border-box",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red",".columns .container.je-noindent":"padding-left:0;padding-right:0",".selectize-control.multi .item":"background:var(--primary-color)%20!important",".select2-container--default .select2-selection--single .select2-selection__arrow":"display:none",".select2-container--default .select2-selection--single":"border:none",".select2-container .select2-selection--single .select2-selection__rendered":"padding:0",".select2-container .select2-search--inline .select2-search__field":"margin-top:0",".select2-container--default.select2-container--focus .select2-selection--multiple":"border:0.05rem%20solid%20var(--gray-color)",".select2-container--default .select2-selection--multiple .select2-selection__choice":"margin:0.4rem%200.2rem%200.2rem%200;padding:2px%205px;background-color:var(--primary-color);color:var(--light-color)",".select2-container--default .select2-search--inline .select2-search__field":"line-height:normal",".choices":"margin-bottom:auto",".choices__list--multiple .choices__item":"border:none;background-color:var(--primary-color);color:var(--light-color)",".choices[data-type*='select-multiple'] .choices__button":"border-left:0.05rem%20solid%20%232826a6",".choices__inner":"font-size:inherit;min-height:20px;padding:4px%207.5px%204px%203.75px",".choices[data-type*='select-one'] .choices__inner":"padding-bottom:4px",".choices__list--dropdown .choices__item":"font-size:inherit"};var Gf={disable_theme_rules:!1,label_bold:!1,object_panel_default:!0,object_indent:!0,object_border:!1,table_border:!1,table_hdiv:!1,table_zebrastyle:!1,input_size:"small",enable_compact:!1},Vu=function(c){(function(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&ec(t,e)})(l,c);var n,f,i,h,a=(i=l,h=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var t,e=er(i);if(h){var o=er(this).constructor;t=Reflect.construct(e,arguments,o)}else t=e.apply(this,arguments);return function(u,d){if(d&&(Co(d)==="object"||typeof d=="function"))return d;if(d!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(x){if(x===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x}(u)}(this,t)});function l(t){return function(e,o){if(!(e instanceof o))throw new TypeError("Cannot call a class as a function")}(this,l),a.call(this,t,Gf)}return n=l,(f=[{key:"getGridContainer",value:function(){var t=document.createElement("div");return t.classList.add("flex","flex-col","w-full"),this.options.object_indent||t.classList.add("je-noindent"),t}},{key:"getGridRow",value:function(){var t=document.createElement("div");return t.classList.add("flex","flex-wrap","w-full"),t}},{key:"getGridColumn",value:function(){var t=document.createElement("div");return t.classList.add("flex","flex-col"),t}},{key:"setGridColumnSize",value:function(t,e,o){e>0&&e<12?t.classList.add("w-".concat(e,"/12"),"px-1"):t.classList.add("w-full","px-1"),o&&(t.style.marginLeft="".concat(100/12*o,"%"))}},{key:"getIndentedPanel",value:function(){var t=document.createElement("div");return this.options.object_panel_default?t.classList.add("w-full","p-1"):t.classList.add("relative","flex","flex-col","rounded","break-words","border","bg-white","border-0","border-blue-400","p-1","shadow-md"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getTopIndentedPanel",value:function(){var t=document.createElement("div");return this.options.object_panel_default?t.classList.add("w-full","m-2"):t.classList.add("relative","flex","flex-col","rounded","break-words","border","bg-white","border-0","border-blue-400","p-1","shadow-md"),this.options.object_border&&t.classList.add("je-border"),t}},{key:"getTitle",value:function(){return this.translateProperty(this.schema.title)}},{key:"getSelectInput",value:function(t,e){var o=wr(er(l.prototype),"getSelectInput",this).call(this,t);return e?o.classList.add("form-multiselect","block","py-0","h-auto","w-full","px-1","text-sm","text-black","leading-normal","bg-white","border","border-grey","rounded"):o.classList.add("form-select","block","py-0","h-6","w-full","px-1","text-sm","text-black","leading-normal","bg-white","border","border-grey","rounded"),this.options.enable_compact&&o.classList.add("compact"),o}},{key:"afterInputReady",value:function(t){t.controlgroup||(t.controlgroup=this.closest(t,".form-group"),this.closest(t,".compact")&&(t.controlgroup.style.marginBottom=0))}},{key:"getTextareaInput",value:function(){var t=wr(er(l.prototype),"getTextareaInput",this).call(this);return t.classList.add("block","w-full","px-1","text-sm","leading-normal","bg-white","text-black","border","border-grey","rounded"),this.options.enable_compact&&t.classList.add("compact"),t.style.height=0,t}},{key:"getRangeInput",value:function(t,e,o){var u=this.getFormInputField("range");return u.classList.add("slider"),this.options.enable_compact&&u.classList.add("compact"),u.setAttribute("oninput",'this.setAttribute("value", this.value)'),u.setAttribute("min",t),u.setAttribute("max",e),u.setAttribute("step",o),u}},{key:"getRangeControl",value:function(t,e){var o=wr(er(l.prototype),"getRangeControl",this).call(this,t,e);return o.classList.add("text-center","text-black"),o}},{key:"getCheckbox",value:function(){var t=this.getFormInputField("checkbox");return t.classList.add("form-checkbox","text-red-600"),t}},{key:"getCheckboxLabel",value:function(t,e){var o=wr(er(l.prototype),"getCheckboxLabel",this).call(this,t,e);return o.classList.add("inline-flex","items-center"),o}},{key:"getFormCheckboxControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("inline-flex flex-row"),t}},{key:"getMultiCheckboxHolder",value:function(t,e,o,u){var d=wr(er(l.prototype),"getMultiCheckboxHolder",this).call(this,t,e,o,u);return d.classList.add("inline-flex","flex-col"),d}},{key:"getFormRadio",value:function(t){var e=this.getFormInputField("radio");for(var o in e.classList.add("form-radio","text-red-600"),t)e.setAttribute(o,t[o]);return e}},{key:"getFormRadioLabel",value:function(t,e){var o=wr(er(l.prototype),"getFormRadioLabel",this).call(this,t,e);return o.classList.add("inline-flex","items-center","mr-2"),o}},{key:"getFormRadioControl",value:function(t,e,o){return t.insertBefore(e,t.firstChild),o&&t.classList.add("form-radio"),t}},{key:"getRadioHolder",value:function(t,e,o,u,d){var x=wr(er(l.prototype),"getRadioHolder",this).call(this,e,o,u,d);return t.options.layout==="h"?x.classList.add("inline-flex","flex-row"):x.classList.add("inline-flex","flex-col"),x}},{key:"getFormInputLabel",value:function(t,e){var o=wr(er(l.prototype),"getFormInputLabel",this).call(this,t,e);return this.options.label_bold?o.classList.add("font-bold"):o.classList.add("required"),o}},{key:"getFormInputField",value:function(t){var e=wr(er(l.prototype),"getFormInputField",this).call(this,t);return["checkbox","radio"].includes(t)||e.classList.add("block","w-full","px-1","text-black","text-sm","leading-normal","bg-white","border","border-grey","rounded"),this.options.enable_compact&&e.classList.add("compact"),e}},{key:"getFormInputDescription",value:function(t){var e=document.createElement("p");return e.classList.add("block","mt-1","text-xs"),window.DOMPurify?e.innerHTML=window.DOMPurify.sanitize(t):e.textContent=this.cleanText(t),e}},{key:"getFormControl",value:function(t,e,o,u){var d=document.createElement("div");return d.classList.add("form-group","mb-1","w-full"),t&&(t.classList.add("text-xs"),e.type==="checkbox"&&(e.classList.add("form-checkbox","text-xs","text-red-600","mr-1"),t.classList.add("items-center","flex"),t=this.getFormCheckboxControl(t,e,!1,u)),e.type==="radio"&&(e.classList.add("form-radio","text-red-600","mr-1"),t.classList.add("items-center","flex"),t=this.getFormRadioControl(t,e,!1,u)),d.appendChild(t),!["checkbox","radio"].includes(e.type)&&u&&d.appendChild(u)),["checkbox","radio"].includes(e.type)||(this.options.input_size==="small"?e.classList.add("text-xs"):this.options.input_size==="normal"?e.classList.add("text-base"):this.options.input_size==="large"&&e.classList.add("text-xl"),d.appendChild(e)),o&&d.appendChild(o),d}},{key:"getHeaderButtonHolder",value:function(){var t=this.getButtonHolder();return t.classList.add("text-sm"),t}},{key:"getButtonHolder",value:function(){var t=document.createElement("div");return t.classList.add("flex","relative","inline-flex","align-middle"),t}},{key:"getButton",value:function(t,e,o){var u=wr(er(l.prototype),"getButton",this).call(this,t,e,o);return u.classList.add("inline-block","align-middle","text-center","text-sm","bg-blue-700","text-white","py-1","pr-1","m-2","shadow","select-none","whitespace-no-wrap","rounded"),u}},{key:"getInfoButton",value:function(t){var e=document.createElement("a");e.classList.add("tooltips","float-right"),e.innerHTML="ⓘ";var o=document.createElement("span");return o.innerHTML=t,e.appendChild(o),e}},{key:"getTable",value:function(){var t=wr(er(l.prototype),"getTable",this).call(this);return this.options.table_border?t.classList.add("je-table-border"):t.classList.add("table","border","p-0"),t}},{key:"getTableRow",value:function(){var t=wr(er(l.prototype),"getTableRow",this).call(this);return this.options.table_border&&t.classList.add("je-table-border"),this.options.table_zebrastyle&&t.classList.add("je-table-zebra"),t}},{key:"getTableHeaderCell",value:function(t){var e=wr(er(l.prototype),"getTableHeaderCell",this).call(this,t);return this.options.table_border?e.classList.add("je-table-border"):this.options.table_hdiv?e.classList.add("je-table-hdiv"):e.classList.add("text-xs","border","p-0","m-0"),e}},{key:"getTableCell",value:function(){var t=wr(er(l.prototype),"getTableCell",this).call(this);return this.options.table_border?t.classList.add("je-table-border"):this.options.table_hdiv?t.classList.add("je-table-hdiv"):t.classList.add("border-0","p-0","m-0"),t}},{key:"addInputError",value:function(t,e){t.controlgroup&&(t.controlgroup.classList.add("has-error"),t.controlgroup.classList.add("text-red-600"),t.errmsg?t.errmsg.style.display="":(t.errmsg=document.createElement("p"),t.errmsg.classList.add("block","mt-1","text-xs","text-red"),t.controlgroup.appendChild(t.errmsg)),t.errmsg.textContent=e)}},{key:"removeInputError",value:function(t){t.errmsg&&(t.errmsg.style.display="none",t.controlgroup.classList.remove("text-red-600"),t.controlgroup.classList.remove("has-error"))}},{key:"getTabHolder",value:function(t){var e=document.createElement("div"),o=t===void 0?"":t;return e.innerHTML="<div class='w-2/12' id='".concat(o,"'><ul class='list-reset pl-0 mb-0'></ul></div><div class='w-10/12' id='").concat(o,"'></div>"),e.classList.add("flex"),e}},{key:"addTab",value:function(t,e){t.children[0].children[0].appendChild(e)}},{key:"getTopTabHolder",value:function(t){var e=t===void 0?"":t,o=document.createElement("div");return o.innerHTML="<ul class='nav-tabs flex list-reset pl-0 mb-0 border-b border-grey-light' id='".concat(e,"'></ul><div class='p-6 block' id='").concat(e,"'></div>"),o}},{key:"getTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item","flex-col","text-center","text-white","bg-blue-500","shadow-md","border","p-2","mb-2","mr-2","hover:bg-blue-400","rounded");var u=document.createElement("a");return u.classList.add("nav-link","text-center"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTopTab",value:function(t,e){var o=document.createElement("li");o.classList.add("nav-item","flex","border-l","border-t","border-r");var u=document.createElement("a");return u.classList.add("nav-link","-mb-px","flex-row","text-center","bg-white","p-2","hover:bg-blue-400","rounded-t"),u.setAttribute("href","#".concat(e)),u.setAttribute("data-toggle","tab"),u.appendChild(t),o.appendChild(u),o}},{key:"getTabContent",value:function(){var t=document.createElement("div");return t.setAttribute("role","tabpanel"),t}},{key:"getTopTabContent",value:function(){var t=document.createElement("div");return t.setAttribute("role","tabpanel"),t}},{key:"markTabActive",value:function(t){t.tab.firstChild.classList.add("block"),t.tab.firstChild.classList.contains("border-b")===!0?(t.tab.firstChild.classList.add("border-b-0"),t.tab.firstChild.classList.remove("border-b")):t.tab.firstChild.classList.add("border-b-0"),t.container.classList.contains("hidden")===!0&&t.container.classList.remove("hidden"),t.container.classList.add("block")}},{key:"markTabInactive",value:function(t){t.tab.firstChild.classList.contains("border-b-0")===!0?(t.tab.firstChild.classList.add("border-b"),t.tab.firstChild.classList.remove("border-b-0")):t.tab.firstChild.classList.add("border-b"),t.container.classList.contains("block")===!0&&(t.container.classList.remove("block"),t.container.classList.add("hidden"))}},{key:"getProgressBar",value:function(){var t=document.createElement("div");t.classList.add("progress");var e=document.createElement("div");return e.classList.add("bg-blue","leading-none","py-1","text-xs","text-center","text-white"),e.setAttribute("role","progressbar"),e.setAttribute("aria-valuenow",0),e.setAttribute("aria-valuemin",0),e.setAttribute("aria-valuenax",100),e.innerHTML="".concat(0,"%"),t.appendChild(e),t}},{key:"updateProgressBar",value:function(t,e){if(t){var o=t.firstChild,u="".concat(e,"%");o.setAttribute("aria-valuenow",e),o.style.width=u,o.innerHTML=u}}},{key:"updateProgressBarUnknown",value:function(t){if(t){var e=t.firstChild;t.classList.add("progress","bg-blue","leading-none","py-1","text-xs","text-center","text-white","block"),e.removeAttribute("aria-valuenow"),e.classList.add("w-full"),e.innerHTML=""}}},{key:"getInputGroup",value:function(t,e){if(t){var o=document.createElement("div");o.classList.add("relative","items-stretch","w-full"),o.appendChild(t);var u=document.createElement("div");u.classList.add("-mr-1"),o.appendChild(u);for(var d=0;d<e.length;d++)u.appendChild(e[d]);return o}}}])&&qf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),l}(Sn);Vu.rules={".slider":"-webkit-appearance:none;-moz-appearance:none;appearance:none;background:transparent;display:block;border:none;height:1.2rem;width:100%25",".slider:focus":"box-shadow:0%200%200%200%20rgba(87%2C%2085%2C%20217%2C%200.2);outline:none",".slider.tooltip:not([data-tooltip])::after":"content:attr(value)",".slider::-webkit-slider-thumb":"-webkit-appearance:none;background:%23f17405;border-radius:100%25;height:0.6rem;margin-top:-0.25rem;transition:transform%200.2s;width:0.6rem",".slider:active::-webkit-slider-thumb":"transform:scale(1.25);outline:none",".slider::-webkit-slider-runnable-track":"background:%23b2b4b6;border-radius:0.1rem;height:0.1rem;width:100%25","a.tooltips":"position:relative;display:inline","a.tooltips span":"position:absolute;white-space:nowrap;width:auto;padding-left:1rem;padding-right:1rem;color:%23ffffff;background:rgba(56%2C%2056%2C%2056%2C%200.85);height:1.5rem;line-height:1.5rem;text-align:center;visibility:hidden;border-radius:3px","a.tooltips span:after":"content:%22%22;position:absolute;top:50%25;left:100%25;margin-top:-5px;width:0;height:0;border-left:5px%20solid%20rgba(56%2C%2056%2C%2056%2C%200.85);border-top:5px%20solid%20transparent;border-bottom:5px%20solid%20transparent","a:hover.tooltips span":"visibility:visible;opacity:0.9;font-size:0.8rem;right:100%25;top:50%25;margin-top:-12px;margin-right:10px;z-index:999",".json-editor-btntype-properties + div":"font-size:0.8rem;font-weight:normal",textarea:"width:100%25;min-height:2rem;resize:vertical",table:"width:100%25;border-collapse:collapse",".table td":"padding:0rem%200rem","div[data-schematype]:not([data-schematype='object'])":"transition:0.5s","div[data-schematype]:not([data-schematype='object']):hover":"background-color:%23e6f4fe","div[data-schemaid='root']":"position:relative;width:inherit;display:inherit;overflow-x:hidden;z-index:10","select[multiple]":"height:auto","select[multiple].from-select":"height:auto",".je-table-zebra:nth-child(even)":"background-color:%23f2f2f2",".je-table-border":"border:0.5px%20solid%20black",".je-table-hdiv":"border-bottom:1px%20solid%20black",".je-border":"border:0.05rem%20solid%20%233182ce",".je-panel":"width:inherit;padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".je-panel-top":"width:100%25;padding:0.2rem;margin:0.2rem;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".required:after":"content:%22%20*%22;color:red;font:inherit;font-weight:bold",".je-desc":"font-size:smaller;margin:0.2rem%200",".container-xl.je-noindent":"padding-left:0;padding-right:0",".json-editor-btntype-add":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%234299e1;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btntype-deletelast":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%23e53e3e;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btntype-deleteall":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%23000000;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btn-save":"float:right;color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%232b6cb0;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btn-back":"color:white;margin:0.3rem;padding:0.3rem%200.8rem;background-color:%232b6cb0;box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-webkit-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2);-moz-box-shadow:3px%203px%205px%201px%20rgba(4%2C%204%2C%204%2C%200.2)",".json-editor-btntype-delete":"color:%23e53e3e;background-color:rgba(218%2C%20222%2C%20228%2C%200.1);margin:0.03rem;padding:0.1rem",".json-editor-btntype-move":"color:%23000000;background-color:rgba(218%2C%20222%2C%20228%2C%200.1);margin:0.03rem;padding:0.1rem",".json-editor-btn-collapse":"padding:0em%200.8rem;font-size:1.3rem;color:%23e53e3e;background-color:rgba(218%2C%20222%2C%20228%2C%200.1)",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-dropzone":"position:relative;margin:0.5rem%200;border:2px%20dashed%20black;width:100%25;height:60px;background:teal;transition:all%200.5s",".je-dropzone:before":"position:absolute;content:attr(data-text);color:rgba(0%2C%200%2C%200%2C%200.6);left:50%25;top:50%25;transform:translate(-50%25%2C%20-50%25)",".je-dropzone.valid-dropzone":"background:green",".je-dropzone.invalid-dropzone":"background:red"};var Wf={html:Bu,bootstrap3:Du,bootstrap4:Nu,bootstrap5:$u,jqueryui:Mu,barebones:Hu,spectre:Fu,tailwind:Vu};const Zf={".je-float-right-linkholder":"float:right;margin-left:10px",".je-modal":"background-color:white;border:1px%20solid%20black;box-shadow:3px%203px%20black;position:absolute;z-index:10",".je-infobutton-icon":"font-size:16px;font-weight:bold;padding:0.25rem;position:relative;display:inline-block",".je-infobutton-tooltip":"font-size:12px;font-weight:normal;font-family:sans-serif;visibility:hidden;background-color:rgba(50%2C%2050%2C%2050%2C%200.75);margin:0%200.25rem;color:%23fafafa;padding:0.5rem%201rem;border-radius:0.25rem;width:20rem;position:absolute",".je-not-loaded":"pointer-events:none",".je-header":"display:inline-block",".je-upload-preview img":"float:left;margin:0%200.5rem%200.5rem%200;max-width:100%25;max-height:5rem",".je-checkbox":"display:inline-block;width:auto",".je-checkbox-control--compact":"display:inline-block;margin-right:1rem",".je-radio":"display:inline-block;width:auto",".je-radio-control--compact":"display:inline-block;margin-right:1rem",".je-switcher":"background-color:transparent;display:inline-block;font-style:italic;font-weight:normal;height:auto;width:auto;margin-bottom:0;margin-left:5px;padding:0%200%200%203px",".je-textarea":"width:100%25;height:300px;box-sizing:border-box",".je-range-control":"text-align:center",".je-indented-panel":"padding-left:10px;margin-left:10px;border-left:1px%20solid%20%23ccc",".je-indented-panel--top":"padding-left:10px;margin-left:10px",".je-tabholder":"float:left;width:130px",".je-tabholder .content":"margin-left:120px",".je-tabholder--top":"margin-left:10px",".je-tabholder--clear":"clear:both",".je-tab":"border:1px%20solid%20%23ccc;border-width:1px%200%201px%201px;text-align:center;line-height:30px;border-radius:5px;border-bottom-right-radius:0;border-top-right-radius:0;font-weight:bold;cursor:pointer",".je-tab--top":"float:left;border:1px%20solid%20%23ccc;border-width:1px%201px%200px%201px;text-align:center;line-height:30px;border-radius:5px;padding-left:5px;padding-right:5px;border-bottom-right-radius:0;border-bottom-left-radius:0;font-weight:bold;cursor:pointer",".je-block-link":"display:block",".je-media":"width:100%25"};function So(c){return So=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},So(c)}function rc(c,n){(n==null||n>c.length)&&(n=c.length);for(var f=0,i=new Array(n);f<n;f++)i[f]=c[f];return i}function nc(){nc=function(){return c};var c={},n=Object.prototype,f=n.hasOwnProperty,i=Object.defineProperty||function(W,G,Z){W[G]=Z.value},h=typeof Symbol=="function"?Symbol:{},a=h.iterator||"@@iterator",l=h.asyncIterator||"@@asyncIterator",t=h.toStringTag||"@@toStringTag";function e(W,G,Z){return Object.defineProperty(W,G,{value:Z,enumerable:!0,configurable:!0,writable:!0}),W[G]}try{e({},"")}catch{e=function(G,Z,pt){return G[Z]=pt}}function o(W,G,Z,pt){var et=G&&G.prototype instanceof x?G:x,Lt=Object.create(et.prototype),re=new gt(pt||[]);return i(Lt,"_invoke",{value:Nt(W,Z,re)}),Lt}function u(W,G,Z){try{return{type:"normal",arg:W.call(G,Z)}}catch(pt){return{type:"throw",arg:pt}}}c.wrap=o;var d={};function x(){}function P(){}function D(){}var J={};e(J,a,function(){return this});var nt=Object.getPrototypeOf,ut=nt&&nt(nt(Jt([])));ut&&ut!==n&&f.call(ut,a)&&(J=ut);var dt=D.prototype=x.prototype=Object.create(J);function kt(W){["next","throw","return"].forEach(function(G){e(W,G,function(Z){return this._invoke(G,Z)})})}function Ct(W,G){function Z(et,Lt,re,Pe){var Te=u(W[et],W,Lt);if(Te.type!=="throw"){var Dr=Te.arg,en=Dr.value;return en&&So(en)=="object"&&f.call(en,"__await")?G.resolve(en.__await).then(function(kr){Z("next",kr,re,Pe)},function(kr){Z("throw",kr,re,Pe)}):G.resolve(en).then(function(kr){Dr.value=kr,re(Dr)},function(kr){return Z("throw",kr,re,Pe)})}Pe(Te.arg)}var pt;i(this,"_invoke",{value:function(et,Lt){function re(){return new G(function(Pe,Te){Z(et,Lt,Pe,Te)})}return pt=pt?pt.then(re,re):re()}})}function Nt(W,G,Z){var pt="suspendedStart";return function(et,Lt){if(pt==="executing")throw new Error("Generator is already running");if(pt==="completed"){if(et==="throw")throw Lt;return{value:void 0,done:!0}}for(Z.method=et,Z.arg=Lt;;){var re=Z.delegate;if(re){var Pe=ne(re,Z);if(Pe){if(Pe===d)continue;return Pe}}if(Z.method==="next")Z.sent=Z._sent=Z.arg;else if(Z.method==="throw"){if(pt==="suspendedStart")throw pt="completed",Z.arg;Z.dispatchException(Z.arg)}else Z.method==="return"&&Z.abrupt("return",Z.arg);pt="executing";var Te=u(W,G,Z);if(Te.type==="normal"){if(pt=Z.done?"completed":"suspendedYield",Te.arg===d)continue;return{value:Te.arg,done:Z.done}}Te.type==="throw"&&(pt="completed",Z.method="throw",Z.arg=Te.arg)}}}function ne(W,G){var Z=G.method,pt=W.iterator[Z];if(pt===void 0)return G.delegate=null,Z==="throw"&&W.iterator.return&&(G.method="return",G.arg=void 0,ne(W,G),G.method==="throw")||Z!=="return"&&(G.method="throw",G.arg=new TypeError("The iterator does not provide a '"+Z+"' method")),d;var et=u(pt,W.iterator,G.arg);if(et.type==="throw")return G.method="throw",G.arg=et.arg,G.delegate=null,d;var Lt=et.arg;return Lt?Lt.done?(G[W.resultName]=Lt.value,G.next=W.nextLoc,G.method!=="return"&&(G.method="next",G.arg=void 0),G.delegate=null,d):Lt:(G.method="throw",G.arg=new TypeError("iterator result is not an object"),G.delegate=null,d)}function Re(W){var G={tryLoc:W[0]};1 in W&&(G.catchLoc=W[1]),2 in W&&(G.finallyLoc=W[2],G.afterLoc=W[3]),this.tryEntries.push(G)}function Gt(W){var G=W.completion||{};G.type="normal",delete G.arg,W.completion=G}function gt(W){this.tryEntries=[{tryLoc:"root"}],W.forEach(Re,this),this.reset(!0)}function Jt(W){if(W){var G=W[a];if(G)return G.call(W);if(typeof W.next=="function")return W;if(!isNaN(W.length)){var Z=-1,pt=function et(){for(;++Z<W.length;)if(f.call(W,Z))return et.value=W[Z],et.done=!1,et;return et.value=void 0,et.done=!0,et};return pt.next=pt}}return{next:Ge}}function Ge(){return{value:void 0,done:!0}}return P.prototype=D,i(dt,"constructor",{value:D,configurable:!0}),i(D,"constructor",{value:P,configurable:!0}),P.displayName=e(D,t,"GeneratorFunction"),c.isGeneratorFunction=function(W){var G=typeof W=="function"&&W.constructor;return!!G&&(G===P||(G.displayName||G.name)==="GeneratorFunction")},c.mark=function(W){return Object.setPrototypeOf?Object.setPrototypeOf(W,D):(W.__proto__=D,e(W,t,"GeneratorFunction")),W.prototype=Object.create(dt),W},c.awrap=function(W){return{__await:W}},kt(Ct.prototype),e(Ct.prototype,l,function(){return this}),c.AsyncIterator=Ct,c.async=function(W,G,Z,pt,et){et===void 0&&(et=Promise);var Lt=new Ct(o(W,G,Z,pt),et);return c.isGeneratorFunction(G)?Lt:Lt.next().then(function(re){return re.done?re.value:Lt.next()})},kt(dt),e(dt,t,"Generator"),e(dt,a,function(){return this}),e(dt,"toString",function(){return"[object Generator]"}),c.keys=function(W){var G=Object(W),Z=[];for(var pt in G)Z.push(pt);return Z.reverse(),function et(){for(;Z.length;){var Lt=Z.pop();if(Lt in G)return et.value=Lt,et.done=!1,et}return et.done=!0,et}},c.values=Jt,gt.prototype={constructor:gt,reset:function(W){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(Gt),!W)for(var G in this)G.charAt(0)==="t"&&f.call(this,G)&&!isNaN(+G.slice(1))&&(this[G]=void 0)},stop:function(){this.done=!0;var W=this.tryEntries[0].completion;if(W.type==="throw")throw W.arg;return this.rval},dispatchException:function(W){if(this.done)throw W;var G=this;function Z(Te,Dr){return Lt.type="throw",Lt.arg=W,G.next=Te,Dr&&(G.method="next",G.arg=void 0),!!Dr}for(var pt=this.tryEntries.length-1;pt>=0;--pt){var et=this.tryEntries[pt],Lt=et.completion;if(et.tryLoc==="root")return Z("end");if(et.tryLoc<=this.prev){var re=f.call(et,"catchLoc"),Pe=f.call(et,"finallyLoc");if(re&&Pe){if(this.prev<et.catchLoc)return Z(et.catchLoc,!0);if(this.prev<et.finallyLoc)return Z(et.finallyLoc)}else if(re){if(this.prev<et.catchLoc)return Z(et.catchLoc,!0)}else{if(!Pe)throw new Error("try statement without catch or finally");if(this.prev<et.finallyLoc)return Z(et.finallyLoc)}}}},abrupt:function(W,G){for(var Z=this.tryEntries.length-1;Z>=0;--Z){var pt=this.tryEntries[Z];if(pt.tryLoc<=this.prev&&f.call(pt,"finallyLoc")&&this.prev<pt.finallyLoc){var et=pt;break}}et&&(W==="break"||W==="continue")&&et.tryLoc<=G&&G<=et.finallyLoc&&(et=null);var Lt=et?et.completion:{};return Lt.type=W,Lt.arg=G,et?(this.method="next",this.next=et.finallyLoc,d):this.complete(Lt)},complete:function(W,G){if(W.type==="throw")throw W.arg;return W.type==="break"||W.type==="continue"?this.next=W.arg:W.type==="return"?(this.rval=this.arg=W.arg,this.method="return",this.next="end"):W.type==="normal"&&G&&(this.next=G),d},finish:function(W){for(var G=this.tryEntries.length-1;G>=0;--G){var Z=this.tryEntries[G];if(Z.finallyLoc===W)return this.complete(Z.completion,Z.afterLoc),Gt(Z),d}},catch:function(W){for(var G=this.tryEntries.length-1;G>=0;--G){var Z=this.tryEntries[G];if(Z.tryLoc===W){var pt=Z.completion;if(pt.type==="throw"){var et=pt.arg;Gt(Z)}return et}}throw new Error("illegal catch attempt")},delegateYield:function(W,G,Z){return this.delegate={iterator:Jt(W),resultName:G,nextLoc:Z},this.method==="next"&&(this.arg=void 0),d}},c}function zu(c,n,f,i,h,a,l){try{var t=c[a](l),e=t.value}catch(o){return void f(o)}t.done?n(e):Promise.resolve(e).then(i,h)}function Jf(c,n){for(var f=0;f<n.length;f++){var i=n[f];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(c,(h=function(a,l){if(So(a)!=="object"||a===null)return a;var t=a[Symbol.toPrimitive];if(t!==void 0){var e=t.call(a,"string");if(So(e)!=="object")return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(a)}(i.key),So(h)==="symbol"?h:String(h)),i)}var h}var Tn=function(){function c(a){var l=this,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(function(D,J){if(!(D instanceof J))throw new TypeError("Cannot call a class as a function")}(this,c),!(a instanceof Element))throw new Error("element should be an instance of Element");this.element=a,this.options=k({},c.defaults.options,t),this.ready=!1,this.copyClipboard=null,this.schema=this.options.schema,this.template=this.options.template,this.translate=this.options.translate||c.defaults.translate,this.translateProperty=this.options.translateProperty||c.defaults.translateProperty,this.uuid=0,this.__data={};var e=this.options.theme||c.defaults.theme,o=c.defaults.themes[e];if(!o)throw new Error("Unknown theme ".concat(e));this.element.setAttribute("data-theme",e),this.element.classList.add("je-not-loaded"),this.element.classList.remove("je-ready"),this.theme=new o(this);var u=k(Zf,this.getEditorsRules()),d=function(D,J,nt){return nt?l.addNewStyleRulesToShadowRoot(D,J,nt):l.addNewStyleRules(D,J)};if(!this.theme.options.disable_theme_rules){var x=C(this.element);d("default",u,x),o.rules!==void 0&&d(e,o.rules,x)}var P=c.defaults.iconlibs[this.options.iconlib||c.defaults.iconlib];P&&(this.iconlib=new P),this.root_container=this.theme.getContainer(),this.element.appendChild(this.root_container),this.promise=this.load()}var n,f,i,h;return n=c,f=[{key:"load",value:(i=nc().mark(function a(){var l,t,e,o,u,d,x=this;return nc().wrap(function(P){for(;;)switch(P.prev=P.next){case 0:return l=document.location.origin+document.location.pathname.toString(),(t=new af(this.options)).onSchemaLoaded=function(D){x.trigger("schemaLoaded",D)},t.onAllSchemasLoaded=function(){x.trigger("allSchemasLoaded")},this.expandSchema=function(D){return t.expandSchema(D)},this.expandRefs=function(D,J){return t.expandRefs(D,J)},e=document.location.toString(),P.next=9,t.load(this.schema,l,e);case 9:o=P.sent,u=this.options.custom_validators?{custom_validators:this.options.custom_validators}:{},this.validator=new Qi(this,null,u,c.defaults),d=this.getEditorClass(o),this.root=this.createEditor(d,{jsoneditor:this,schema:o,required:!0,container:this.root_container}),this.root.preBuild(),this.root.build(),this.root.postBuild(),S(this.options,"startval")&&this.root.setValue(this.options.startval),this.validation_results=this.validator.validate(this.root.getValue()),this.root.showValidationErrors(this.validation_results),this.ready=!0,this.element.classList.remove("je-not-loaded"),this.element.classList.add("je-ready"),window.requestAnimationFrame(function(){x.ready&&(x.validation_results=x.validator.validate(x.root.getValue()),x.root.showValidationErrors(x.validation_results),x.trigger("ready"),x.trigger("change"))});case 24:case"end":return P.stop()}},a,this)}),h=function(){var a=this,l=arguments;return new Promise(function(t,e){var o=i.apply(a,l);function u(x){zu(o,t,e,u,d,"next",x)}function d(x){zu(o,t,e,u,d,"throw",x)}u(void 0)})},function(){return h.apply(this,arguments)})},{key:"getValue",value:function(){if(!this.ready)throw new Error("JSON Editor not ready yet. Make sure the load method is complete");return this.root.getValue()}},{key:"setValue",value:function(a){if(!this.ready)throw new Error("JSON Editor not ready yet. Make sure the load method is complete");return this.root.setValue(a),this}},{key:"validate",value:function(a){if(!this.ready)throw new Error("JSON Editor not ready yet. Make sure the load method is complete");return arguments.length===1?this.validator.validate(a):this.validation_results}},{key:"destroy",value:function(){this.destroyed||this.ready&&(this.schema=null,this.options=null,this.root.destroy(),this.root=null,this.root_container=null,this.validator=null,this.validation_results=null,this.theme=null,this.iconlib=null,this.template=null,this.__data=null,this.ready=!1,this.element.innerHTML="",this.element.removeAttribute("data-theme"),this.destroyed=!0)}},{key:"on",value:function(a,l){return this.callbacks=this.callbacks||{},this.callbacks[a]=this.callbacks[a]||[],this.callbacks[a].push(l),this}},{key:"off",value:function(a,l){if(a&&l){this.callbacks=this.callbacks||{},this.callbacks[a]=this.callbacks[a]||[];for(var t=[],e=0;e<this.callbacks[a].length;e++)this.callbacks[a][e]!==l&&t.push(this.callbacks[a][e]);this.callbacks[a]=t}else a?(this.callbacks=this.callbacks||{},this.callbacks[a]=[]):this.callbacks={};return this}},{key:"trigger",value:function(a,l){if(this.callbacks&&this.callbacks[a]&&this.callbacks[a].length)for(var t=0;t<this.callbacks[a].length;t++)this.callbacks[a][t].apply(this,[l]);return this}},{key:"setOption",value:function(a,l){if(a!=="show_errors")throw new Error("Option ".concat(a," must be set during instantiation and cannot be changed later"));return this.options.show_errors=l,this.onChange(),this}},{key:"getEditorsRules",value:function(){return Object.values(c.defaults.editors).reduce(function(a,l){return l.rules?k(a,l.rules):a},{})}},{key:"getEditorClass",value:function(a){var l,t=this;if(a=this.expandSchema(a),c.defaults.resolvers.find(function(e){return(l=e(a,t))&&c.defaults.editors[l]}),!l)throw new Error("Unknown editor for schema ".concat(JSON.stringify(a)));if(!c.defaults.editors[l])throw new Error("Unknown editor ".concat(l));return c.defaults.editors[l]}},{key:"createEditor",value:function(a,l){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return new a(l=k({},a.options||{},l),c.defaults,t)}},{key:"onChange",value:function(){var a=this;if(this.ready&&!this.firing_change)return this.firing_change=!0,window.requestAnimationFrame(function(){a.firing_change=!1,a.ready&&(a.validation_results=a.validator.validate(a.root.getValue()),a.options.show_errors!=="never"?a.root.showValidationErrors(a.validation_results):a.root.showValidationErrors([]),a.trigger("change"))}),this}},{key:"compileTemplate",value:function(a){var l,t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:c.defaults.template;if(typeof t=="string"){if(!c.defaults.templates[t])throw new Error("Unknown template engine ".concat(t));if(!(l=c.defaults.templates[t]()))throw new Error("Template engine ".concat(t," missing required library."))}else l=t;if(!l)throw new Error("No template engine set");if(!l.compile)throw new Error("Invalid template engine set");return l.compile(a)}},{key:"_data",value:function(a,l,t){if(arguments.length!==3)return a.hasAttribute("data-jsoneditor-".concat(l))?this.__data[a.getAttribute("data-jsoneditor-".concat(l))]:null;var e;a.hasAttribute("data-jsoneditor-".concat(l))?e=a.getAttribute("data-jsoneditor-".concat(l)):(e=this.uuid++,a.setAttribute("data-jsoneditor-".concat(l),e)),this.__data[e]=t}},{key:"registerEditor",value:function(a){return this.editors=this.editors||{},this.editors[a.path]=a,this}},{key:"unregisterEditor",value:function(a){return this.editors=this.editors||{},this.editors[a.path]=null,this}},{key:"getEditor",value:function(a){if(this.editors)return this.editors[a]}},{key:"watch",value:function(a,l){return this.watchlist=this.watchlist||{},this.watchlist[a]=this.watchlist[a]||[],this.watchlist[a].push(l),this}},{key:"unwatch",value:function(a,l){if(!this.watchlist||!this.watchlist[a])return this;if(!l)return this.watchlist[a]=null,this;for(var t=[],e=0;e<this.watchlist[a].length;e++)this.watchlist[a][e]!==l&&t.push(this.watchlist[a][e]);return this.watchlist[a]=t.length?t:null,this}},{key:"notifyWatchers",value:function(a){if(!this.watchlist||!this.watchlist[a])return this;for(var l=0;l<this.watchlist[a].length;l++)this.watchlist[a][l]()}},{key:"isEnabled",value:function(){return!this.root||this.root.isEnabled()}},{key:"enable",value:function(){this.root.enable()}},{key:"disable",value:function(){this.root.disable()}},{key:"setCopyClipboardContents",value:function(a){this.copyClipboard=a}},{key:"getCopyClipboardContents",value:function(){return this.copyClipboard}},{key:"addNewStyleRules",value:function(a,l){var t=document.querySelector("#theme-".concat(a));t||((t=document.createElement("style")).setAttribute("id","theme-".concat(a)),t.appendChild(document.createTextNode("")),document.head.appendChild(t));for(var e=t.sheet?t.sheet:t.styleSheet,o=this.element.nodeName.toLowerCase();e.cssRules.length>0;)e.deleteRule(0);Object.keys(l).forEach(function(u){var d=a==="default"?u:"".concat(o,'[data-theme="').concat(a,'"] ').concat(u);e.insertRule?e.insertRule(d+" {"+decodeURIComponent(l[u])+"}",0):e.addRule&&e.addRule(d,decodeURIComponent(l[u]),0)})}},{key:"addNewStyleRulesToShadowRoot",value:function(a,l,t){var e=this.element.nodeName.toLowerCase(),o="";Object.keys(l).forEach(function(x){var P=a==="default"?x:"".concat(e,'[data-theme="').concat(a,'"] ').concat(x);o+=P+" {"+decodeURIComponent(l[x])+`}
|
|
83
83
|
`});var u,d=new CSSStyleSheet;d.replaceSync(o),t.adoptedStyleSheets=[].concat(function(x){if(Array.isArray(x))return rc(x)}(u=t.adoptedStyleSheets)||function(x){if(typeof Symbol<"u"&&x[Symbol.iterator]!=null||x["@@iterator"]!=null)return Array.from(x)}(u)||function(x,P){if(x){if(typeof x=="string")return rc(x,P);var D=Object.prototype.toString.call(x).slice(8,-1);return D==="Object"&&x.constructor&&(D=x.constructor.name),D==="Map"||D==="Set"?Array.from(x):D==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(D)?rc(x,P):void 0}}(u)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
84
84
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}(),[d])}}],f&&Jf(n.prototype,f),Object.defineProperty(n,"prototype",{writable:!1}),c}();Tn.defaults=_i,Tn.AbstractEditor=F,Tn.AbstractTheme=Sn,Tn.AbstractIconLib=Cn,Object.assign(Tn.defaults.themes,Wf),Object.assign(Tn.defaults.editors,_s),Object.assign(Tn.defaults.templates,sf),Object.assign(Tn.defaults.iconlibs,Rf)})(),E})())})(uu);var Na=uu.exports;const tp=`
|
|
85
85
|
* {
|
|
@@ -281,7 +281,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
281
281
|
margin: 0 0.5rem;
|
|
282
282
|
white-space: nowrap;
|
|
283
283
|
}
|
|
284
|
-
`,destroy:$}};window.tcRangeSliderPlugins.push(_)})(),(()=>{var m=Object.defineProperty,s=Math.pow,p=(L,z,rt)=>z in L?m(L,z,{enumerable:!0,configurable:!0,writable:!0,value:rt}):L[z]=rt,b=(L,z,rt)=>(p(L,typeof z!="symbol"?z+"":z,rt),rt),_=(L,z)=>` ${z&&z.length>0?z.map(rt=>`<link rel="stylesheet" href="${rt}" />`).join(""):""} <style> ${L} </style> <div class="range-slider-box"> <div class="row"> <div id="range-slider" class="range-slider"> <div class="container"> <div class="panel"></div> <div class="panel-fill"></div> <div class="container"> <div class="pointer" tabindex="0" role="slider"> <div class="pointer-shape"></div> </div> </div> </div> </div> </div> </div>`,E=":host{--width:300px;--height:.25rem;--opacity:.4;--panel-bg:#cbd5e1;--panel-bg-hover:#94a3b8;--panel-bg-fill:#475569;--panel-bg-border-radius:1rem;--pointer-width:1rem;--pointer-height:1rem;--pointer-bg:#fff;--pointer-bg-hover:#dcdcdc;--pointer-bg-focus:#dcdcdc;--pointer-shadow:0 0 2px rgba(0,0,0,0.8);--pointer-shadow-hover:0 0 2px #000;--pointer-shadow-focus:var(--pointer-shadow-hover);--pointer-border:1px solid hsla(0,0%,88%,0.5);--pointer-border-hover:1px solid #94a3b8;--pointer-border-focus:var(--pointer-border-hover);--pointer-border-radius:100%;--animate-onclick:.3s}:host{max-width:100%}.range-slider-box{display:flex;position:relative;flex-direction:column}.range-slider{position:relative;width:var(--width,100%);height:var(--height,0.25rem);touch-action:none;max-width:100%;box-sizing:border-box;cursor:pointer}.row{width:100%;display:flex;align-items:center}.range-slider.disabled{opacity:var(--opacity,0.4);cursor:default}.pointer.disabled{-webkit-filter:brightness(0.8);filter:brightness(0.8);cursor:default}.range-slider *{box-sizing:border-box}.container{position:absolute;width:100%;height:100%}.panel{position:absolute;z-index:10;width:100%;height:100%;background:var(--panel-bg,#2d4373);border-radius:var(--panel-bg-border-radius,1rem);overflow:hidden;transition:.3s all ease}.panel-fill{background:var(--panel-bg-fill,#000);border-radius:var(--panel-bg-border-radius,1rem);overflow:hidden;height:100%;position:absolute;z-index:10}.panel:hover{background:var(--panel-bg-hover,#5f79b7)}.disabled .panel:hover{background:var(--panel-bg,#5f79b7)}.pointer{position:absolute;z-index:20;outline:0;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.pointer-shape{background:var(--pointer-bg,#fff);background-size:contain;box-shadow:var(--pointer-shadow);border:var(--pointer-border);border-radius:var(--pointer-border-radius,100%);-webkit-transform:translateX(-50%);transform:translateX(-50%);width:var(--pointer-width,15px);height:var(--pointer-height,15px);transition:.3s all ease}.pointer-shape:hover{background:var(--pointer-bg-hover,#fff);background-size:contain;border:var(--pointer-border-hover);box-shadow:var(--pointer-shadow-hover)}.disabled .pointer-shape:hover{background:var(--pointer-bg,#fff);background-size:contain;border:var(--pointer-border);box-shadow:var(--pointer-shadow)}.pointer:focus .pointer-shape{background:var(--pointer-bg-focus,#fff);background-size:contain;border:var(--pointer-border-focus);box-shadow:var(--pointer-shadow-focus)}.disabled .pointer:focus .pointer-shape{background:var(--pointer-bg,#fff);background-size:contain;border:var(--pointer-border);box-shadow:var(--pointer-shadow)}.type-vertical .range-slider{--width:.25rem;--height:300px;max-height:100%}.type-vertical .range-slider .pointer{left:50%}.type-vertical .range-slider .panel-fill{width:100%}.type-vertical.range-slider-box{flex-direction:row}.type-vertical .row{flex-direction:column}.animate-on-click .pointer,.animate-on-click .panel-fill{transition:all var(--animate-onclick)}.range-dragging .panel-fill{cursor:move}",y="pointers-overlap",j="pointers-min-distance",r="pointers-max-distance",v="range-dragging",g="data",w="min",k="max",O="step",C="round",S="type",T="theme",A="rtl",R="btt",I="disabled",$="keyboard-disabled",M="mousewheel-disabled",B="slider-width",q="slider-height",F="slider-radius",N="slider-bg",U="slider-bg-hover",H="slider-bg-fill",X="pointer-width",Y="pointer-height",K="pointer-radius",tt="pointer-bg",it="pointer-bg-hover",st="pointer-bg-focus",yt="pointer-shadow",ct="pointer-shadow-hover",Et="pointer-shadow-focus",At="pointer-border",Vt="pointer-border-hover",lt="pointer-border-focus",wt="animate-onclick",_t="css-links",Ut="vertical",Kt="horizontal",fe=(L,z,rt,Q,mt)=>{let Dt=z-L;return Dt===0?rt:(Q-rt)*(mt-L)/Dt+rt},St=L=>!isNaN(parseFloat(L))&&isFinite(L),jt=(L,z)=>St(L)?Number(L):z,Bt=(L,z)=>z===0?0:Math.round(L/z)*z,qt=(L,z=1/0)=>{if(z===1/0)return L;let rt=s(10,z);return Math.round(L*rt)/rt},xt=L=>L==null?!1:typeof L=="boolean"?L:L.trim().toLowerCase()==="true",lr=(L,z)=>{L.dispatchEvent(new CustomEvent("onPointerClicked",{detail:{$pointer:z}}))},de=(L,z)=>{L.dispatchEvent(new CustomEvent("onMouseDown",{detail:{nativeEvent:z}}))},Ne=(L,z)=>{L.dispatchEvent(new CustomEvent("onMouseUp",{detail:{nativeEvent:z}}))},ge=(L,z)=>{L.dispatchEvent(new CustomEvent("onKeyDown",{detail:{nativeEvent:z}}))},cr=(L,z)=>{if(!z||z.length<=0)return;let rt=z.map(mt=>St(mt)?jt(mt,mt):mt),Q={values:rt||[]};Q.value=rt[0],Q.value0=rt[0],Q.value1=rt[0];for(let mt=1;mt<rt.length;mt++)Q[`value${mt+1}`]=rt[mt];L.dispatchEvent(new CustomEvent("change",{detail:Q}))},Ae=(L,z,rt)=>{let Q=0,mt,Dt,Jt,ft,vt=!1,Wt=(zt,me,Ue,Oe,$e,_e)=>{let mr=Q;Ue!==void 0&&zt>Ue&&(zt=Ue),me!==void 0&&zt<me&&(zt=me),Q=zt;let Me=Q;return(Oe===Ut&&_e||Oe===Kt&&$e)&&(Me=100-Me),Oe===Ut?z.style.top=`${Me}%`:z.style.left=`${Me}%`,mr!==Q},oe=zt=>zt===z||z.contains(zt),Tt=(zt,me,Ue,Oe)=>{mt=zt,Dt=me,Jt=Ue,ft=Oe},ue=zt=>{vt=zt,z.classList.toggle("disabled",vt),vt?z.setAttribute("aria-disabled","true"):z.hasAttribute("aria-disabled")&&z.removeAttribute("aria-disabled")},Be=(zt,me)=>{me==null?z.removeAttribute(zt):z.setAttribute(zt,me)},ir=zt=>z.getAttribute(zt),It=zt=>{if(!vt){switch(zt.key){case"ArrowLeft":{zt.preventDefault(),typeof mt=="function"&&mt(rt);break}case"ArrowRight":{zt.preventDefault(),typeof Dt=="function"&&Dt(rt);break}case"ArrowUp":{zt.preventDefault(),typeof Jt=="function"&&Jt(rt);break}case"ArrowDown":{zt.preventDefault(),typeof ft=="function"&&ft(rt);break}}ge(L,zt)}},ee=()=>{vt||lr(L,z)};return z.className=`pointer pointer-${rt}`,z.addEventListener("keydown",It),z.addEventListener("click",ee),{$pointer:z,get percent(){return Q},get disabled(){return vt},set disabled(zt){ue(zt)},updatePosition:Wt,isClicked:oe,setCallbacks:Tt,setAttr:Be,getAttr:ir,destroy:()=>{z.removeEventListener("keydown",It),z.removeEventListener("click",ee),z.remove()}}},dr=L=>{if(L==null)return;if(Array.isArray(L))return L;if(L.trim()==="")return;let z=L.split(","),rt=[],Q=!0;for(let mt=0;mt<z.length;mt++){let Dt=z[mt].trim();Dt!==""&&(rt.push(Dt),St(Dt)||(Q=!1))}return Q?rt.map(mt=>Number(mt)):rt},Le=(L,z)=>z?z.findIndex(rt=>rt===L||rt.toString().trim()===L.toString().trim()):-1,We=L=>({updatePosition:(z,rt,Q,mt)=>{if(rt.length<=0)return;let Dt=rt.length===1,Jt=rt[0],ft=rt[rt.length-1];z===Ut?(L.style.removeProperty("width"),L.style.removeProperty("right"),L.style.removeProperty("left"),Dt?L.style.height=`${Jt}%`:L.style.height=`${Math.abs(Jt-ft)}%`,mt?(L.style.bottom="0%",Dt?L.style.top="auto":L.style.top=`${Math.min(100-ft,100-Jt)}%`):(L.style.bottom="auto",Dt?L.style.top="0%":L.style.top=`${Math.min(Jt,ft)}%`)):(L.style.removeProperty("height"),L.style.removeProperty("top"),L.style.removeProperty("bottom"),Dt?L.style.width=`${Jt}%`:L.style.width=`${Math.abs(Jt-ft)}%`,Q?(L.style.right="0%",Dt?L.style.left="auto":L.style.left=`${Math.min(100-ft,100-Jt)}%`):(L.style.right="auto",Dt?L.style.left="0%":L.style.left=`${Math.min(Jt,ft)}%`))}}),Ce="--animate-onclick",pr="--width",ot="--height",bt="--panel-bg-border-radius",Ht="--panel-bg",Mt="--panel-bg-hover",Qt="--panel-bg-fill",Ze="--pointer-width",Ke="--pointer-height",xr="--pointer-border-radius",Qe="--pointer-bg",fr="--pointer-bg-hover",Se="--pointer-bg-focus",Dn="--pointer-shadow",Nt="--pointer-shadow-hover",te="--pointer-shadow-focus",Xt="--pointer-border",ce="--pointer-border-hover",ze="--pointer-border-focus",Vi=(L,z,rt)=>{let Q=new Map;for(let mt of L.attributes){let Dt=mt.nodeName.trim().toLowerCase();if(!z.test(Dt))continue;let Jt=Dt.replace(/\D/g,"").trim(),ft=Jt===""||Jt==="0"||Jt==="1"?0:jt(Jt,0)-1,vt=rt&&typeof rt=="function"?rt(mt.value):mt.value;Q.set(ft,vt)}return Q},Nn=L=>{if(!L)return null;let z=L.getAttribute(_t);if(!z)return null;let rt=z.split(";"),Q=[];for(let mt of rt)mt.trim()!==""&&Q.push(mt.trim());return Q},us=[[pr,B,"sliderWidth",null],[ot,q,"sliderHeight",null],[bt,F,"sliderRadius",null],[Ht,N,"sliderBg",null],[Mt,U,"sliderBgHover",null],[Qt,H,"sliderBgFill",null],[Ze,X,"pointer#Width",/^pointer([0-9]*)-width$/],[Ke,Y,"pointer#Height",/^pointer([0-9]*)-height$/],[xr,K,"pointer#Radius",/^pointer([0-9]*)-radius$/],[Qe,tt,"pointer#Bg",/^pointer([0-9]*)-bg$/],[fr,it,"pointer#BgHover",/^pointer([0-9]*)-bg-hover$/],[Se,st,"pointer#BgFocus",/^pointer([0-9]*)-bg-focus$/],[Dn,yt,"pointer#Shadow",/^pointer([0-9]*)-shadow$/],[Nt,ct,"pointer#ShadowHover",/^pointer([0-9]*)-shadow-hover$/],[te,Et,"pointer#ShadowFocus",/^pointer([0-9]*)-shadow-focus$/],[Xt,At,"pointer#Border",/^pointer([0-9]*)-border$/],[ce,Vt,"pointer#BorderHover",/^pointer([0-9]*)-border-hover$/],[ze,lt,"pointer#BorderFocus",/^pointer([0-9]*)-border-focus$/]],ui=(L,z,rt)=>{let Q=null,mt=[],Dt=new Map,Jt=(It,ee=z)=>{let zt=[...ee.classList];for(let me of zt)me.startsWith(It)&&z.classList.remove(me)},ft=()=>{Jt("shape");let It=z.querySelectorAll(".pointer");for(let ee of It)Jt("shape",ee)},vt=It=>{Q=It,Jt("theme-"),typeof It=="string"&&z.classList.add(`theme-${It}`)},Wt=()=>{if(ft(),!(mt.length<=0)){z.classList.add("shape",`shape-${mt[0]}`);for(let It=1;It<mt.length;It++){let ee=mt[It];if(!ee)continue;let zt=z.querySelector(`.pointer-${It}`);!zt||zt.classList.add("shape",`shape-${ee}`)}}},oe=(It,ee)=>{mt[It]=ee,Wt()},Tt=()=>{ft();let It=Vi(L,/^pointer([0-9]*)-shape$/);if(!(It.size<=0)){for(let ee of It){let zt=ee[0];mt[zt]=ee[1]}Wt()}},ue=(It,ee)=>`${It}-${ee}`,Be=(It,ee,zt)=>{let me=rt[zt];if(!me)return;let Ue=zt===0?z:me.$pointer;if(ee==null){Dt.has(ue(It,zt))&&Dt.delete(ue(It,zt)),Ue.style.removeProperty(It);return}Dt.set(ue(It,zt),ee),Ue.style.setProperty(It,ee)},ir=(It,ee)=>Dt.get(ue(It,ee));return(()=>{for(let It of us){let[ee,zt,me,Ue]=It;if(Ue){let $e=Vi(L,Ue);for(let _e of $e){let mr=_e[0],Me=_e[1];Be(ee,Me,mr)}}else{let $e=L.getAttribute(zt);Be(ee,$e,0)}let Oe=[];if(me.indexOf("#")===-1)Oe.push([me,0]);else{Oe.push([me.replace("#",""),0]),Oe.push([me.replace("#","0"),0]),Oe.push([me.replace("#","1"),0]);for(let $e=1;$e<rt.length;$e++)Oe.push([me.replace("#",($e+1).toString()),$e])}for(let $e of Oe)try{let _e=$e[0],mr=$e[1];Object.prototype.hasOwnProperty.call(L,_e)||Object.defineProperty(L,_e,{get(){return ir(ee,mr)},set:Me=>{Be(ee,Me,mr)}})}catch(_e){console.error(_e)}}vt(L.getAttribute(T)),Tt()})(),{setStyle:Be,getStyle:ir,get theme(){return Q},set theme(It){vt(It)},get pointerShapes(){return mt},setPointerShape:oe}},on="animate-on-click",Wr="range-dragging",hs=(L,z,rt,Q)=>{let mt=[],Dt=oe=>{for(let Tt of mt)Tt.update&&typeof Tt.update=="function"&&Tt.update(oe)},Jt=()=>{for(let oe of mt)oe.destroy&&typeof oe.destroy=="function"&&oe.destroy()},ft=(oe,Tt)=>{for(let ue of mt)ue.onAttrChange&&typeof ue.onAttrChange=="function"&&ue.onAttrChange(oe,Tt)},vt=oe=>{if(oe.gettersAndSetters){for(let Tt of oe.gettersAndSetters)if(!(!Tt.name||!Tt.attributes))try{Object.prototype.hasOwnProperty.call(L,Tt.name)||Object.defineProperty(L,Tt.name,Tt.attributes)}catch(ue){console.error("defineSettersGetters error:",ue)}}},Wt=oe=>{var Tt;if(!oe.css)return;let ue=(Tt=L.shadowRoot)==null?void 0:Tt.querySelector("style");!ue||(ue.innerHTML+=oe.css)};return{init:()=>{if(window.tcRangeSliderPlugins)for(let oe of window.tcRangeSliderPlugins){let Tt=oe();mt.push(Tt),Tt.init&&typeof Tt.init=="function"&&(Tt.init(L,z,rt,Q),vt(Tt),Wt(Tt))}},update:Dt,onAttrChange:ft,destroy:Jt}},$n=10,ds=20,kn=(L,z)=>{let rt=new Map,Q=/^value([0-9]*)$/;for(let ft of L.attributes){let vt=ft.nodeName.trim().toLowerCase();if(!Q.test(vt))continue;let Wt=vt.replace("value","").trim(),oe=Wt===""||Wt==="0"||Wt==="1"?0:jt(Wt,0)-1,Tt=St(ft.value)?jt(ft.value,0):ft.value;rt.set(oe,Tt)}let mt=Math.max(...Array.from(rt.keys())),Dt=[];Dt.push([Ae(L,z,0),rt.get(0)]);let Jt=z;for(let ft=1;ft<=mt;ft++){let vt=z.cloneNode(!0);Jt.after(vt),Jt=vt,Dt.push([Ae(L,vt,ft),rt.get(ft)])}return Dt},zi=(L,z,rt,Q,mt,Dt,Jt)=>{try{Object.defineProperty(L,Q,{configurable:!0,get(){if(!z)return;let ft=z.pointers[rt];if(!ft)return;let vt=z.getTextValue(ft.percent);return St(vt)?jt(vt,vt):vt},set:ft=>{z.pointers[rt]?z==null||z.setValue(ft,rt):z==null||z.addPointer(ft)}}),Object.defineProperty(L,mt,{configurable:!0,get(){var ft,vt;return(vt=(ft=z==null?void 0:z.pointers[rt])==null?void 0:ft.getAttr("aria-label"))!=null?vt:void 0},set:ft=>{!z||z.setAriaLabel(rt,ft)}}),Object.defineProperty(L,Dt,{configurable:!0,get(){var ft,vt;return(vt=(ft=z==null?void 0:z.styles)==null?void 0:ft.pointerShapes[rt])!=null?vt:null},set:ft=>{!z||!z.styles||z.styles.setPointerShape(rt,ft)}}),Object.defineProperty(L,Jt,{configurable:!0,get(){var ft;return(ft=z==null?void 0:z.pointers[rt].disabled)!=null?ft:!1},set:ft=>{if(!z)return;let vt=z==null?void 0:z.pointers[rt];!vt||(vt.disabled=ft)}})}catch(ft){console.error(ft)}},Mr=(L,z)=>{let rt=[["value","ariaLabel","pointerShape","pointerDisabled",0],["value0","ariaLabel0","pointerShape0","pointer0Disabled",0],["value1","ariaLabel1","pointerShape1","pointer1Disabled",0]];for(let Q=2;Q<$n;Q++)rt.push([`value${Q}`,`ariaLabel${Q}`,`pointer${Q}Shape`,`pointer${Q}Disabled`,Q-1]);for(let Q of rt)zi(L,z,Q[4],Q[0],Q[1],Q[2],Q[3])},ps=(L,z,rt)=>{var Q;let mt=(Q=rt.shadowRoot)==null?void 0:Q.querySelector(".container");if(mt)for(let Dt of L)z?mt.prepend(Dt.$pointer):mt.append(Dt.$pointer)},Mn=(L,z)=>{if(!(!z||L.length<=1)){for(let rt of L)rt.$pointer.style.zIndex=ds.toString();z.$pointer.style.zIndex=(ds*2).toString()}},ea=0,Cr=100,an=2,Sr="0.3s",hi=(L,z,rt)=>{let Q=rt.map(V=>V[0]),mt=null,Dt=null,Jt=null,ft=null,vt=ea,Wt=Cr,oe,Tt,ue=Kt,Be=an,ir=!1,It=!1,ee=!1,zt=0,me=1/0,Ue=!1,Oe,$e,_e=!1,mr=!1,Me=!1,Fr=Sr,Pr=[],fs=V=>{_e||(V.preventDefault&&V.preventDefault(),Vr(V),window.addEventListener("mousemove",Vr),window.addEventListener("mouseup",Zr),de(L,V))},Zr=V=>{_e||(Oe=void 0,$e=void 0,window.removeEventListener("mousemove",Vr),window.removeEventListener("mouseup",Zr),Fr&&z.classList.add(on),Ne(L,V))},yl=(V,at)=>{if(Q.length<=0)return;if(Q.length===1)return Q[0].isClicked(V)&&Fr&&z.classList.remove(on),Q[0];let Ot=ys(V);if(Ue){let le=at,He=Ji(le);He!==void 0&&(le=Bt(le,He)),Ot?(Oe=le,$e=0,Fr&&z.classList.remove(on)):Oe!==void 0&&($e=le-Oe,Oe=le)}if(!Fn(V)&&!Ot){for(let le of Q)if(!(!le.isClicked(V)||le.disabled))return Fr&&z.classList.remove(on),le;for(let le of Q)if(mt===le)return le}let ve=1/0,we=null;for(let le of Q){if(le.disabled)continue;let He=Math.abs(at-le.percent);He<ve&&(ve=He,we=le)}return we},Ui=()=>Q.findIndex(V=>mt===V&&!V.disabled),Vr=V=>{let at;if(ue===Ut){let{height:ve,top:we}=z.getBoundingClientRect(),le=V.type.indexOf("mouse")!==-1?V.clientY:V.touches[0].clientY;at=Math.min(Math.max(0,le-we),ve)*100/ve}else{let{width:ve,left:we}=z.getBoundingClientRect(),le=V.type.indexOf("mouse")!==-1?V.clientX:V.touches[0].clientX;at=Math.min(Math.max(0,le-we),ve)*100/ve}if((ir||It)&&(at=100-at),mt=yl(V.target,at),mt&&Mn(Q,mt),Ue&&Q.length>1&&$e!==void 0){let ve=Q[0],we=Q[Q.length-1],le=ve.percent+$e<0,He=we.percent+$e>100;if(le||He)return;for(let ao=0;ao<Q.length;ao++)qe(ao,Q[ao].percent+$e);return}let Ot=Ui();Ot!==-1&&(qe(Ot,at),mt==null||mt.$pointer.focus())},qi=V=>{if(_e||document.activeElement!==L||mt!=null&&mt.disabled)return;V.stopPropagation(),V.preventDefault();let at=V.deltaY<0,Ot=ir||It,ve=at?!Ot:Ot,we=Ui();we!==-1&&(ve?zr(we,Q[we].percent):di(we,Q[we].percent))},jn=V=>{_e||mr||(ue===Ut?It?qe(V,100):qe(V,0):ir?di(V,Q[V].percent):zr(V,Q[V].percent))},ms=V=>{_e||mr||(ue===Ut?It?qe(V,0):qe(V,100):ir?zr(V,Q[V].percent):di(V,Q[V].percent))},Gi=V=>{_e||mr||(ue===Ut?It?di(V,Q[V].percent):zr(V,Q[V].percent):ir?qe(V,100):qe(V,0))},Wi=V=>{_e||mr||(ue===Ut?It?zr(V,Q[V].percent):di(V,Q[V].percent):ir?qe(V,0):qe(V,100))},Fn=V=>V.classList.contains("panel"),ys=V=>V.classList.contains("panel-fill"),zr=(V,at)=>{if(at===void 0)return;let Ot=Ji(at);Ot==null&&(Ot=1),at-=Ot,at<0&&(at=0),qe(V,at)},di=(V,at)=>{if(at===void 0)return;let Ot=Ji(at);Ot==null&&(Ot=1),at+=Ot,at>100&&(at=100),qe(V,at)},Jr=()=>{!ft||ft.update({percents:Xr(),values:Yi(),$pointers:Tr(),min:vs(),max:gs(),data:na(),step:ra(),round:oa(),type:ia(),textMin:zn(),textMax:Yr(),rightToLeft:yr(),bottomToTop:xe(),pointersOverlap:Ki(),pointersMinDistance:Xi(),pointersMaxDistance:aa(),rangeDragging:Qi(),disabled:fi(),keyboardDisabled:mi(),mousewheelDisabled:sa()})},Zi=()=>{Jr()},bs=V=>{if(!(ee||Q.length<=1||Wt===vt))if(V===0){let at=me*100/(Wt-vt);return Math.max(0,Q[V+1].percent-at)}else{let at=zt*100/(Wt-vt);return Math.min(Q[V-1].percent+at,100)}},Vn=V=>{if(!(ee||Q.length<=1||Wt===vt))if(V===Q.length-1){let at=me*100/(Wt-vt);return Math.min(Q[V-1].percent+at,100)}else{let at=zt*100/(Wt-vt);return Math.max(0,Q[V+1].percent-at)}},Ji=V=>{let at;if(typeof oe=="function"){let Ot=fe(0,100,vt,Wt,V);at=oe(Ot,V)}else at=oe;if(St(at)){let Ot=Wt-vt;return at=Ot===0?0:at*100/Ot,at}},sn=V=>{if(V===void 0)return;let at=fe(0,100,vt,Wt,V);return Tt!==void 0?Tt[Math.round(at)]:qt(at,Be)},zn=()=>Tt!==void 0?Tt[vt]:vt,Yr=()=>Tt!==void 0?Tt[Wt]:Wt,ra=()=>oe,Un=V=>{var at;return V<=0||ee?zn():(at=sn(Q[V-1].percent))!=null?at:""},bl=V=>{var at;return Q.length<=1||V>=Q.length-1||ee?Yr():(at=sn(Q[V+1].percent))!=null?at:""},Xr=()=>Q.map(V=>V.percent),Yi=()=>Q.map(V=>sn(V.percent)),Tr=()=>Q.map(V=>V.$pointer),vs=()=>vt,gs=()=>Wt,na=()=>Tt,ia=()=>ue,oa=()=>Be,Xi=()=>zt,aa=()=>me,pi=V=>Pr[V],yr=()=>ir,xe=()=>It,fi=()=>_e,mi=()=>mr,sa=()=>Me,Ki=()=>ee,Qi=()=>Ue,qe=(V,at)=>{if(at===void 0)return;let Ot=Ji(at);Ot!==void 0&&(at=Bt(at,Ot));let ve=Q[V];if(!ve)return;let we=ve.updatePosition(at,bs(V),Vn(V),ue,ir,It);Dt==null||Dt.updatePosition(ue,Q.map(le=>le.percent),ir,It),Jr();for(let le of Q){let He=sn(le.percent);He!==void 0&&(le.setAttr("aria-valuenow",He.toString()),le.setAttr("aria-valuetext",He.toString()))}la(),we&&cr(L,Q.map(le=>sn(le.percent)))},Ur=()=>{for(let V=0;V<Q.length;V++)qe(V,Q[V].percent)},ln=(V,at)=>{vt=Tt!==void 0?0:jt(V,ea),Wt=Tt!==void 0?Tt.length-1:jt(at,Cr),br(vt),to(Wt)},la=()=>{var V,at;for(let Ot=0;Ot<Q.length;Ot++){let ve=Q[Ot];ve.setAttr("aria-valuemin",((V=Un(Ot))!=null?V:"").toString()),ve.setAttr("aria-valuemax",((at=bl(Ot))!=null?at:"").toString())}},br=V=>{vt=jt(V,ea),vt>Wt&&(Wt=vt+Cr),Ur()},to=V=>{Wt=jt(V,Cr),Wt<vt&&(Wt=vt+Cr),Ur()},On=V=>{ee=!0;for(let at=0;at<V.length;at++)eo(V[at],at);ee=!1;for(let at=0;at<V.length;at++)eo(V[at],at)},eo=(V,at)=>{let Ot;Tt!==void 0?(Ot=V==null?0:Le(V,Tt),Ot===-1&&(Ot=0)):(Ot=jt(V,vt),Ot<vt&&(Ot=vt),Ot>Wt&&(Ot=Wt));let ve=fe(vt,Wt,0,100,Ot);qe(at,ve)},qn=V=>{if(V==null){oe=void 0;return}if(typeof V=="function"){oe=V,Ur();return}if(St(V)){oe=jt(V,1);let at=Math.abs(Wt-vt);oe>at&&(oe=void 0),Ur();return}oe=void 0},Gn=V=>{ee=V,Ur()},ca=V=>{(!St(V)||V<0)&&(V=0),zt=V},ro=V=>{(!St(V)||V<0)&&(V=1/0),me=V},cn=V=>{_e=V,z.classList.toggle("disabled",_e),_e?z.setAttribute("aria-disabled","true"):z.hasAttribute("aria-disabled")&&z.removeAttribute("aria-disabled")},yi=V=>{mr=V},En=V=>{Me=V,Me?document.removeEventListener("wheel",qi):document.addEventListener("wheel",qi,{passive:!1})},no=V=>{if(V==null){Tt=void 0;return}if(Tt=dr(V),Tt===void 0||Tt.length<=0){Tt=void 0;return}br(0),to(Tt.length-1),oe===void 0&&qn(1)},Br=V=>{var at;typeof V=="string"?ue=V.trim().toLowerCase()===Ut?Ut:Kt:ue=Kt;let Ot=(at=L.shadowRoot)==null?void 0:at.querySelector(".range-slider-box");if(!Ot)return;Ot.className=`range-slider-box type-${ue}`,Ur();let ve=ue===Ut?"vertical":"horizontal";for(let we of Q)we.setAttr("aria-orientation",ve)},ua=V=>{ir=V,Q.length>1&&ps(Q,ir,L),Ur(),Jr()},io=V=>{It=V,Q.length>1&&ps(Q,It,L),Ur(),Jr()},Ar=V=>{Be=jt(V,an),Be<0&&(Be=an),Jr()},oo=V=>{V==null||V.toString().trim().toLowerCase()==="false"?(Fr=void 0,z.style.removeProperty(Ce),z.classList.remove(on)):(Fr=V.toString(),z.style.setProperty(Ce,Fr),z.classList.add(on))},vr=(V,at)=>{let Ot=Q[V];!Ot||(Ot.setAttr("aria-label",at),Pr[V]=at)},bi=V=>{if(Oe=void 0,Q.length<=1){Ue=!1,z.classList.remove(Wr);return}Ue=V,z.classList.toggle(Wr,Ue)},Wn=()=>{cn(xt(L.getAttribute(I))),mr=xt(L.getAttribute($)),Me=xt(L.getAttribute(M));let V=Vi(L,/^pointer([0-9]*)-disabled$/,at=>xt(at));for(let at of V){let Ot=at[0];!Q[Ot]||(Q[Ot].disabled=at[1])}},vl=()=>{let V=Vi(L,/^aria-label([0-9]*)$/);for(let at of V){let Ot=at[0];vr(Ot,at[1])}},Zn=V=>{let at=Q.length,Ot=Q[at-1].$pointer,ve=Ot.cloneNode(!0);Ot.after(ve);let we=Ae(L,ve,at);return we.setCallbacks(jn,ms,Gi,Wi),Q.push(we),eo(V,at),Ur(),Jr(),at},ha=()=>{let V=Q.length,at=Q[V-1];return at?(at.destroy(),Q.pop(),Q.length<=1&&bi(!1),Ur(),Jr(),V-1):-1};return(()=>{var V,at;for(let ve of Q)ve.setCallbacks(jn,ms,Gi,Wi);let Ot=(V=L.shadowRoot)==null?void 0:V.querySelector(".panel-fill");Ot&&(Dt=We(Ot)),Br(L.getAttribute(S)),ua(xt(L.getAttribute(A))),io(xt(L.getAttribute(R))),ln(L.getAttribute(w),L.getAttribute(k)),qn(L.getAttribute(O)),no(L.getAttribute(g)),On(rt.map(ve=>ve[1])),Gn(xt(L.getAttribute(y))),ca(jt(L.getAttribute(j),0)),ro(jt(L.getAttribute(r),1/0)),bi(xt(L.getAttribute(v))),Ar(jt(L.getAttribute(C),an)),Wn(),vl(),Jt=ui(L,z,Q),oo((at=L.getAttribute(wt))!=null?at:Sr),z.addEventListener("mousedown",fs),z.addEventListener("mouseup",Zr),z.addEventListener("touchmove",Vr),z.addEventListener("touchstart",Vr),Me||document.addEventListener("wheel",qi,{passive:!1}),ft=hs(L,Zi,{setValues:On,setMin:br,setMax:to,setStep:qn,setPointersOverlap:Gn,setPointersMinDistance:ca,setPointersMaxDistance:ro,setDisabled:cn,setType:Br,setRightToLeft:ua,setBottomToTop:io,setRound:Ar,setKeyboardDisabled:yi,setMousewheelDisabled:En,setRangeDragging:bi,setData:no},{getPercents:Xr,getValues:Yi,getPointerElements:Tr,getMin:vs,getMax:gs,getStep:ra,getData:na,getType:ia,getRound:oa,getTextMin:zn,getTextMax:Yr,isRightToLeft:yr,isBottomToTop:xe,isDisabled:fi,isKeyboardDisabled:mi,isMousewheelDisabled:sa,isPointersOverlap:Ki,isRangeDraggingEnabled:Qi,getPointersMinDistance:Xi,getPointersMaxDistance:aa}),ft.init()})(),{get pointers(){return Q},get styles(){return Jt},get pluginsManager(){return ft},get min(){return zn()},get max(){return Yr()},get step(){return ra()},get pointersOverlap(){return Ki()},set pointersOverlap(V){Gn(V)},get pointersMinDistance(){return Xi()},set pointersMinDistance(V){ca(V)},get pointersMaxDistance(){return aa()},set pointersMaxDistance(V){ro(V)},get disabled(){return fi()},set disabled(V){cn(V)},get data(){return na()},get type(){return ia()},set type(V){Br(V)},get rightToLeft(){return yr()},set rightToLeft(V){ua(V)},get bottomToTop(){return xe()},set bottomToTop(V){io(V)},get round(){return oa()},set round(V){Ar(V)},get animateOnClick(){return Fr},set animateOnClick(V){oo(V)},get keyboardDisabled(){return mi()},set keyboardDisabled(V){yi(V)},get mousewheelDisabled(){return sa()},set mousewheelDisabled(V){En(V)},get rangeDragging(){return Qi()},set rangeDragging(V){bi(V)},setMin:br,setMax:to,setValue:eo,setStep:qn,setData:no,getTextValue:sn,setAriaLabel:vr,getAriaLabel:pi,addPointer:Zn,removePointer:ha,destroy:()=>{z.removeEventListener("mousedown",fs),z.removeEventListener("mouseup",Zr),z.removeEventListener("touchmove",Vr),z.removeEventListener("touchstart",Vr),document.removeEventListener("wheel",qi);for(let V of Q)V.destroy();ft==null||ft.destroy()}}},Hn=(L,z,rt)=>{let Q=us.find(([ft,vt,Wt,oe])=>vt.replace("#","")===z.replace(/\d+/g,""));if(Q&&L.styles){let[ft,vt,Wt,oe]=Q,Tt=z.replace(/\D/g,"").trim(),ue=Tt===""||Tt==="0"||Tt==="1"?0:jt(Tt,0)-1;L.styles.setStyle(ft,rt,ue);return}switch(L&&L.pluginsManager&&L.pluginsManager.onAttrChange(z,rt),z){case w:{L.setMin(rt);break}case k:{L.setMax(rt);break}case O:{L.setStep(rt);break}case y:{L.pointersOverlap=xt(rt);break}case j:{L.pointersMinDistance=jt(rt,0);break}case v:{L.rangeDragging=xt(rt);break}case r:{L.pointersMaxDistance=jt(rt,1/0);break}case I:{L.disabled=xt(rt);break}case $:{L.keyboardDisabled=xt(rt);break}case M:{L.mousewheelDisabled=xt(rt);break}case g:{L.setData(rt);break}case S:{L.type=rt;break}case A:{L.rightToLeft=xt(rt);break}case R:{L.bottomToTop=xt(rt);break}case C:{L.round=jt(rt,an);break}case T:{L.styles&&(L.styles.theme=rt);break}case wt:{L.animateOnClick=rt;break}}let mt=null;if(/^value([0-9]*)$/.test(z)&&(mt="value"),/^pointer([0-9]*)-disabled$/.test(z)&&(mt="pointer-disabled"),/^aria-label([0-9]*)$/.test(z)&&(mt="aria-label"),/^pointer([0-9]*)-shape$/.test(z)&&(mt="pointer-shape"),!mt)return;let Dt=z.replace(/\D/g,"").trim(),Jt=Dt===""||Dt==="0"||Dt==="1"?0:jt(Dt,0)-1;switch(mt){case"value":{L.setValue(rt,Jt);break}case"pointer-disabled":{let ft=L==null?void 0:L.pointers[Jt];if(!ft)return;ft.disabled=xt(rt);break}case"aria-label":{L.setAriaLabel(Jt,rt);break}case"pointer-shape":{L.styles&&L.styles.setPointerShape(Jt,rt);break}}},ml=class extends HTMLElement{constructor(){super(),b(this,"slider"),b(this,"_externalCSSList",[]),b(this,"_observer",null),this.attachShadow({mode:"open"})}set step(L){this.slider&&this.slider.setStep(L)}get step(){var L;return(L=this.slider)==null?void 0:L.step}set disabled(L){this.slider&&(this.slider.disabled=L)}get disabled(){var L,z;return(z=(L=this.slider)==null?void 0:L.disabled)!=null?z:!1}set data(L){var z;(z=this.slider)==null||z.setData(L)}get data(){var L;return(L=this.slider)==null?void 0:L.data}set min(L){var z;(z=this.slider)==null||z.setMin(L)}get min(){var L;return(L=this.slider)==null?void 0:L.min}set max(L){var z;(z=this.slider)==null||z.setMax(L)}get max(){var L;return(L=this.slider)==null?void 0:L.max}set round(L){!this.slider||(this.slider.round=L)}get round(){var L,z;return(z=(L=this.slider)==null?void 0:L.round)!=null?z:an}set type(L){!this.slider||(this.slider.type=L??Kt)}get type(){var L;return((L=this.slider)==null?void 0:L.type)||Kt}set pointersOverlap(L){!this.slider||(this.slider.pointersOverlap=L)}get pointersOverlap(){var L,z;return(z=(L=this.slider)==null?void 0:L.pointersOverlap)!=null?z:!1}set pointersMinDistance(L){!this.slider||(this.slider.pointersMinDistance=L)}get pointersMinDistance(){var L,z;return(z=(L=this.slider)==null?void 0:L.pointersMinDistance)!=null?z:0}set pointersMaxDistance(L){!this.slider||(this.slider.pointersMaxDistance=L)}get pointersMaxDistance(){var L,z;return(z=(L=this.slider)==null?void 0:L.pointersMaxDistance)!=null?z:1/0}set theme(L){!this.slider||!this.slider.styles||(this.slider.styles.theme=L)}get theme(){var L,z,rt;return(rt=(z=(L=this.slider)==null?void 0:L.styles)==null?void 0:z.theme)!=null?rt:null}set rtl(L){!this.slider||(this.slider.rightToLeft=L)}get rtl(){var L,z;return(z=(L=this.slider)==null?void 0:L.rightToLeft)!=null?z:!1}set btt(L){!this.slider||(this.slider.bottomToTop=L)}get btt(){var L,z;return(z=(L=this.slider)==null?void 0:L.bottomToTop)!=null?z:!1}set keyboardDisabled(L){!this.slider||(this.slider.keyboardDisabled=L)}get keyboardDisabled(){var L,z;return(z=(L=this.slider)==null?void 0:L.keyboardDisabled)!=null?z:!1}set mousewheelDisabled(L){!this.slider||(this.slider.mousewheelDisabled=L)}get mousewheelDisabled(){var L,z;return(z=(L=this.slider)==null?void 0:L.mousewheelDisabled)!=null?z:!1}set animateOnClick(L){!this.slider||(this.slider.animateOnClick=L)}get animateOnClick(){var L;return(L=this.slider)==null?void 0:L.animateOnClick}get rangeDragging(){var L,z;return(z=(L=this.slider)==null?void 0:L.rangeDragging)!=null?z:!1}set rangeDragging(L){this.slider&&(this.slider.rangeDragging=xt(L))}get externalCSSList(){return this._externalCSSList}addPointer(L){var z,rt;if(!this.slider)return;let Q=(rt=(z=this.slider)==null?void 0:z.addPointer(L))!=null?rt:0;zi(this,this.slider,Q,`value${Q+1}`,`ariaLabel${Q+1}`,`pointerShape${Q+1}`,`pointer${Q+1}Disabled`)}removePointer(){var L;!this.slider||(L=this.slider)==null||L.removePointer()}addCSS(L){if(!this.shadowRoot)return;let z=document.createElement("style");z.textContent=L,this.shadowRoot.appendChild(z)}connectedCallback(){var L,z;if(!this.shadowRoot)return;this._externalCSSList=Nn(this),this.shadowRoot.innerHTML=_(E,this._externalCSSList);let rt=(L=this.shadowRoot)==null?void 0:L.querySelector(".pointer");if(!rt)return;let Q=(z=this.shadowRoot)==null?void 0:z.getElementById("range-slider");if(!Q)return;let mt=kn(this,rt);this.slider=hi(this,Q,mt),Mr(this,this.slider),this._observer=new MutationObserver(Dt=>{Dt.forEach(Jt=>{var ft;if(!this.slider||Jt.type!=="attributes")return;let vt=Jt.attributeName;!vt||Hn(this.slider,vt,(ft=this.getAttribute(vt))!=null?ft:"")})}),this._observer.observe(this,{attributes:!0})}disconnectedCallback(){this._observer&&this._observer.disconnect(),this.slider&&this.slider.destroy()}},Hr=ml;window.tcRangeSlider=Hr,customElements.get("toolcool-range-slider")||customElements.define("toolcool-range-slider",Hr),customElements.get("tc-range-slider")||customElements.define("tc-range-slider",class extends Hr{})})();function np(m,s){Object.keys(s).forEach(p=>{m.setAttribute(p,s[p])})}class ip extends rp{register(){super.register()}unregister(){super.unregister()}build(){const s=this.schema.properties,p=this.options,b=this.schema.description,_=this.theme,E=this.defaults.startVals[this.key];p.compact||(this.header=this.label=_.getFormInputLabel(this.getTitle(),this.isRequired())),b&&(this.description=_.getFormInputDescription(this.translateProperty(b))),p.infoText&&(this.infoButton=_.getInfoButton(this.translateProperty(p.infoText)));const y=document.createElement("tc-range-slider"),j=Object.keys(s).find(g=>g.includes("min")),r=Object.keys(s).find(g=>g.includes("max")),v={min:s[j].minimum,max:s[r].maximum,value1:(E==null?void 0:E[j])||s[j].default,value2:(E==null?void 0:E[r])||s[r].default,"slider-bg-fill":"#004170","generate-labels":"true","slider-width":"100%","range-dragging":"false"};np(y,v),this.input=y,this.input.id=this.formname,this.control=_.getFormControl(this.label,this.input,this.description,this.infoButton),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),this.input.disabled=!0),this.input.addEventListener("change",g=>{g.preventDefault(),g.stopPropagation(),this.value={[j]:g.detail.value1,[r]:g.detail.value2},this.onChange(!0)}),this.container.appendChild(this.control)}destroy(){this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),super.destroy()}}const op=[{type:"object",format:"minmax",func:ip}],ap=m=>{op.map(({type:s,format:p,func:b})=>{Na.JSONEditor.defaults.startVals=m,Na.JSONEditor.defaults.editors[p]=b,Na.JSONEditor.defaults.resolvers.unshift(_=>{if(_.type===s&&_.format===p)return p})})};class mu extends jr{constructor(){super();se(this,Ma);se(this,Ha);se(this,$i,{});se(this,ci,null);this.schema,this.startVals,this.options={show_opt_in:!1,disable_collapse:!0,disable_edit_json:!0,disable_properties:!0,disable_array_delete_all_rows:!0,disable_array_delete_last_row:!0,array_controls_top:!0},this.unstyled=!1}getSchema(){return this.schema}setSchema(p){this.schema=p}getDefaultValues(){return this.startVals}setDefaultValues(p){this.startVals=p}getValues(){return Ee(this,$i)}firstUpdated(){if(!Ee(this,ci)){ap(this.startVals||{});const p=this.renderRoot.querySelector("form");Si(this,ci,new Na.JSONEditor(p,{schema:this.schema,...this.startVals?{startval:this.startVals}:{},theme:"html",ajax:!0,...this.options})),rr(this,Ha,qu).call(this)}}render(){return ae`
|
|
284
|
+
`,destroy:$}};window.tcRangeSliderPlugins.push(_)})(),(()=>{var m=Object.defineProperty,s=Math.pow,p=(L,z,rt)=>z in L?m(L,z,{enumerable:!0,configurable:!0,writable:!0,value:rt}):L[z]=rt,b=(L,z,rt)=>(p(L,typeof z!="symbol"?z+"":z,rt),rt),_=(L,z)=>` ${z&&z.length>0?z.map(rt=>`<link rel="stylesheet" href="${rt}" />`).join(""):""} <style> ${L} </style> <div class="range-slider-box"> <div class="row"> <div id="range-slider" class="range-slider"> <div class="container"> <div class="panel"></div> <div class="panel-fill"></div> <div class="container"> <div class="pointer" tabindex="0" role="slider"> <div class="pointer-shape"></div> </div> </div> </div> </div> </div> </div>`,E=":host{--width:300px;--height:.25rem;--opacity:.4;--panel-bg:#cbd5e1;--panel-bg-hover:#94a3b8;--panel-bg-fill:#475569;--panel-bg-border-radius:1rem;--pointer-width:1rem;--pointer-height:1rem;--pointer-bg:#fff;--pointer-bg-hover:#dcdcdc;--pointer-bg-focus:#dcdcdc;--pointer-shadow:0 0 2px rgba(0,0,0,0.8);--pointer-shadow-hover:0 0 2px #000;--pointer-shadow-focus:var(--pointer-shadow-hover);--pointer-border:1px solid hsla(0,0%,88%,0.5);--pointer-border-hover:1px solid #94a3b8;--pointer-border-focus:var(--pointer-border-hover);--pointer-border-radius:100%;--animate-onclick:.3s}:host{max-width:100%}.range-slider-box{display:flex;position:relative;flex-direction:column}.range-slider{position:relative;width:var(--width,100%);height:var(--height,0.25rem);touch-action:none;max-width:100%;box-sizing:border-box;cursor:pointer}.row{width:100%;display:flex;align-items:center}.range-slider.disabled{opacity:var(--opacity,0.4);cursor:default}.pointer.disabled{-webkit-filter:brightness(0.8);filter:brightness(0.8);cursor:default}.range-slider *{box-sizing:border-box}.container{position:absolute;width:100%;height:100%}.panel{position:absolute;z-index:10;width:100%;height:100%;background:var(--panel-bg,#2d4373);border-radius:var(--panel-bg-border-radius,1rem);overflow:hidden;transition:.3s all ease}.panel-fill{background:var(--panel-bg-fill,#000);border-radius:var(--panel-bg-border-radius,1rem);overflow:hidden;height:100%;position:absolute;z-index:10}.panel:hover{background:var(--panel-bg-hover,#5f79b7)}.disabled .panel:hover{background:var(--panel-bg,#5f79b7)}.pointer{position:absolute;z-index:20;outline:0;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.pointer-shape{background:var(--pointer-bg,#fff);background-size:contain;box-shadow:var(--pointer-shadow);border:var(--pointer-border);border-radius:var(--pointer-border-radius,100%);-webkit-transform:translateX(-50%);transform:translateX(-50%);width:var(--pointer-width,15px);height:var(--pointer-height,15px);transition:.3s all ease}.pointer-shape:hover{background:var(--pointer-bg-hover,#fff);background-size:contain;border:var(--pointer-border-hover);box-shadow:var(--pointer-shadow-hover)}.disabled .pointer-shape:hover{background:var(--pointer-bg,#fff);background-size:contain;border:var(--pointer-border);box-shadow:var(--pointer-shadow)}.pointer:focus .pointer-shape{background:var(--pointer-bg-focus,#fff);background-size:contain;border:var(--pointer-border-focus);box-shadow:var(--pointer-shadow-focus)}.disabled .pointer:focus .pointer-shape{background:var(--pointer-bg,#fff);background-size:contain;border:var(--pointer-border);box-shadow:var(--pointer-shadow)}.type-vertical .range-slider{--width:.25rem;--height:300px;max-height:100%}.type-vertical .range-slider .pointer{left:50%}.type-vertical .range-slider .panel-fill{width:100%}.type-vertical.range-slider-box{flex-direction:row}.type-vertical .row{flex-direction:column}.animate-on-click .pointer,.animate-on-click .panel-fill{transition:all var(--animate-onclick)}.range-dragging .panel-fill{cursor:move}",y="pointers-overlap",j="pointers-min-distance",r="pointers-max-distance",v="range-dragging",g="data",w="min",k="max",O="step",C="round",S="type",T="theme",A="rtl",R="btt",I="disabled",$="keyboard-disabled",M="mousewheel-disabled",B="slider-width",q="slider-height",F="slider-radius",N="slider-bg",U="slider-bg-hover",H="slider-bg-fill",X="pointer-width",Y="pointer-height",K="pointer-radius",tt="pointer-bg",it="pointer-bg-hover",st="pointer-bg-focus",yt="pointer-shadow",ct="pointer-shadow-hover",Et="pointer-shadow-focus",At="pointer-border",Vt="pointer-border-hover",lt="pointer-border-focus",wt="animate-onclick",_t="css-links",Ut="vertical",Kt="horizontal",fe=(L,z,rt,Q,mt)=>{let Bt=z-L;return Bt===0?rt:(Q-rt)*(mt-L)/Bt+rt},St=L=>!isNaN(parseFloat(L))&&isFinite(L),jt=(L,z)=>St(L)?Number(L):z,It=(L,z)=>z===0?0:Math.round(L/z)*z,qt=(L,z=1/0)=>{if(z===1/0)return L;let rt=s(10,z);return Math.round(L*rt)/rt},xt=L=>L==null?!1:typeof L=="boolean"?L:L.trim().toLowerCase()==="true",lr=(L,z)=>{L.dispatchEvent(new CustomEvent("onPointerClicked",{detail:{$pointer:z}}))},de=(L,z)=>{L.dispatchEvent(new CustomEvent("onMouseDown",{detail:{nativeEvent:z}}))},Ne=(L,z)=>{L.dispatchEvent(new CustomEvent("onMouseUp",{detail:{nativeEvent:z}}))},ge=(L,z)=>{L.dispatchEvent(new CustomEvent("onKeyDown",{detail:{nativeEvent:z}}))},cr=(L,z)=>{if(!z||z.length<=0)return;let rt=z.map(mt=>St(mt)?jt(mt,mt):mt),Q={values:rt||[]};Q.value=rt[0],Q.value0=rt[0],Q.value1=rt[0];for(let mt=1;mt<rt.length;mt++)Q[`value${mt+1}`]=rt[mt];L.dispatchEvent(new CustomEvent("change",{detail:Q}))},Ae=(L,z,rt)=>{let Q=0,mt,Bt,Yt,ft,vt=!1,Zt=(zt,me,Ue,Oe,$e,xe)=>{let mr=Q;Ue!==void 0&&zt>Ue&&(zt=Ue),me!==void 0&&zt<me&&(zt=me),Q=zt;let Me=Q;return(Oe===Ut&&xe||Oe===Kt&&$e)&&(Me=100-Me),Oe===Ut?z.style.top=`${Me}%`:z.style.left=`${Me}%`,mr!==Q},oe=zt=>zt===z||z.contains(zt),Tt=(zt,me,Ue,Oe)=>{mt=zt,Bt=me,Yt=Ue,ft=Oe},ue=zt=>{vt=zt,z.classList.toggle("disabled",vt),vt?z.setAttribute("aria-disabled","true"):z.hasAttribute("aria-disabled")&&z.removeAttribute("aria-disabled")},Be=(zt,me)=>{me==null?z.removeAttribute(zt):z.setAttribute(zt,me)},ir=zt=>z.getAttribute(zt),Rt=zt=>{if(!vt){switch(zt.key){case"ArrowLeft":{zt.preventDefault(),typeof mt=="function"&&mt(rt);break}case"ArrowRight":{zt.preventDefault(),typeof Bt=="function"&&Bt(rt);break}case"ArrowUp":{zt.preventDefault(),typeof Yt=="function"&&Yt(rt);break}case"ArrowDown":{zt.preventDefault(),typeof ft=="function"&&ft(rt);break}}ge(L,zt)}},ee=()=>{vt||lr(L,z)};return z.className=`pointer pointer-${rt}`,z.addEventListener("keydown",Rt),z.addEventListener("click",ee),{$pointer:z,get percent(){return Q},get disabled(){return vt},set disabled(zt){ue(zt)},updatePosition:Zt,isClicked:oe,setCallbacks:Tt,setAttr:Be,getAttr:ir,destroy:()=>{z.removeEventListener("keydown",Rt),z.removeEventListener("click",ee),z.remove()}}},dr=L=>{if(L==null)return;if(Array.isArray(L))return L;if(L.trim()==="")return;let z=L.split(","),rt=[],Q=!0;for(let mt=0;mt<z.length;mt++){let Bt=z[mt].trim();Bt!==""&&(rt.push(Bt),St(Bt)||(Q=!1))}return Q?rt.map(mt=>Number(mt)):rt},Le=(L,z)=>z?z.findIndex(rt=>rt===L||rt.toString().trim()===L.toString().trim()):-1,We=L=>({updatePosition:(z,rt,Q,mt)=>{if(rt.length<=0)return;let Bt=rt.length===1,Yt=rt[0],ft=rt[rt.length-1];z===Ut?(L.style.removeProperty("width"),L.style.removeProperty("right"),L.style.removeProperty("left"),Bt?L.style.height=`${Yt}%`:L.style.height=`${Math.abs(Yt-ft)}%`,mt?(L.style.bottom="0%",Bt?L.style.top="auto":L.style.top=`${Math.min(100-ft,100-Yt)}%`):(L.style.bottom="auto",Bt?L.style.top="0%":L.style.top=`${Math.min(Yt,ft)}%`)):(L.style.removeProperty("height"),L.style.removeProperty("top"),L.style.removeProperty("bottom"),Bt?L.style.width=`${Yt}%`:L.style.width=`${Math.abs(Yt-ft)}%`,Q?(L.style.right="0%",Bt?L.style.left="auto":L.style.left=`${Math.min(100-ft,100-Yt)}%`):(L.style.right="auto",Bt?L.style.left="0%":L.style.left=`${Math.min(Yt,ft)}%`))}}),Ce="--animate-onclick",pr="--width",ot="--height",bt="--panel-bg-border-radius",Mt="--panel-bg",$t="--panel-bg-hover",Qt="--panel-bg-fill",Ze="--pointer-width",Ke="--pointer-height",xr="--pointer-border-radius",Qe="--pointer-bg",fr="--pointer-bg-hover",Se="--pointer-bg-focus",Dn="--pointer-shadow",Dt="--pointer-shadow-hover",te="--pointer-shadow-focus",Xt="--pointer-border",ce="--pointer-border-hover",ze="--pointer-border-focus",Vi=(L,z,rt)=>{let Q=new Map;for(let mt of L.attributes){let Bt=mt.nodeName.trim().toLowerCase();if(!z.test(Bt))continue;let Yt=Bt.replace(/\D/g,"").trim(),ft=Yt===""||Yt==="0"||Yt==="1"?0:jt(Yt,0)-1,vt=rt&&typeof rt=="function"?rt(mt.value):mt.value;Q.set(ft,vt)}return Q},Nn=L=>{if(!L)return null;let z=L.getAttribute(_t);if(!z)return null;let rt=z.split(";"),Q=[];for(let mt of rt)mt.trim()!==""&&Q.push(mt.trim());return Q},us=[[pr,B,"sliderWidth",null],[ot,q,"sliderHeight",null],[bt,F,"sliderRadius",null],[Mt,N,"sliderBg",null],[$t,U,"sliderBgHover",null],[Qt,H,"sliderBgFill",null],[Ze,X,"pointer#Width",/^pointer([0-9]*)-width$/],[Ke,Y,"pointer#Height",/^pointer([0-9]*)-height$/],[xr,K,"pointer#Radius",/^pointer([0-9]*)-radius$/],[Qe,tt,"pointer#Bg",/^pointer([0-9]*)-bg$/],[fr,it,"pointer#BgHover",/^pointer([0-9]*)-bg-hover$/],[Se,st,"pointer#BgFocus",/^pointer([0-9]*)-bg-focus$/],[Dn,yt,"pointer#Shadow",/^pointer([0-9]*)-shadow$/],[Dt,ct,"pointer#ShadowHover",/^pointer([0-9]*)-shadow-hover$/],[te,Et,"pointer#ShadowFocus",/^pointer([0-9]*)-shadow-focus$/],[Xt,At,"pointer#Border",/^pointer([0-9]*)-border$/],[ce,Vt,"pointer#BorderHover",/^pointer([0-9]*)-border-hover$/],[ze,lt,"pointer#BorderFocus",/^pointer([0-9]*)-border-focus$/]],ui=(L,z,rt)=>{let Q=null,mt=[],Bt=new Map,Yt=(Rt,ee=z)=>{let zt=[...ee.classList];for(let me of zt)me.startsWith(Rt)&&z.classList.remove(me)},ft=()=>{Yt("shape");let Rt=z.querySelectorAll(".pointer");for(let ee of Rt)Yt("shape",ee)},vt=Rt=>{Q=Rt,Yt("theme-"),typeof Rt=="string"&&z.classList.add(`theme-${Rt}`)},Zt=()=>{if(ft(),!(mt.length<=0)){z.classList.add("shape",`shape-${mt[0]}`);for(let Rt=1;Rt<mt.length;Rt++){let ee=mt[Rt];if(!ee)continue;let zt=z.querySelector(`.pointer-${Rt}`);!zt||zt.classList.add("shape",`shape-${ee}`)}}},oe=(Rt,ee)=>{mt[Rt]=ee,Zt()},Tt=()=>{ft();let Rt=Vi(L,/^pointer([0-9]*)-shape$/);if(!(Rt.size<=0)){for(let ee of Rt){let zt=ee[0];mt[zt]=ee[1]}Zt()}},ue=(Rt,ee)=>`${Rt}-${ee}`,Be=(Rt,ee,zt)=>{let me=rt[zt];if(!me)return;let Ue=zt===0?z:me.$pointer;if(ee==null){Bt.has(ue(Rt,zt))&&Bt.delete(ue(Rt,zt)),Ue.style.removeProperty(Rt);return}Bt.set(ue(Rt,zt),ee),Ue.style.setProperty(Rt,ee)},ir=(Rt,ee)=>Bt.get(ue(Rt,ee));return(()=>{for(let Rt of us){let[ee,zt,me,Ue]=Rt;if(Ue){let $e=Vi(L,Ue);for(let xe of $e){let mr=xe[0],Me=xe[1];Be(ee,Me,mr)}}else{let $e=L.getAttribute(zt);Be(ee,$e,0)}let Oe=[];if(me.indexOf("#")===-1)Oe.push([me,0]);else{Oe.push([me.replace("#",""),0]),Oe.push([me.replace("#","0"),0]),Oe.push([me.replace("#","1"),0]);for(let $e=1;$e<rt.length;$e++)Oe.push([me.replace("#",($e+1).toString()),$e])}for(let $e of Oe)try{let xe=$e[0],mr=$e[1];Object.prototype.hasOwnProperty.call(L,xe)||Object.defineProperty(L,xe,{get(){return ir(ee,mr)},set:Me=>{Be(ee,Me,mr)}})}catch(xe){console.error(xe)}}vt(L.getAttribute(T)),Tt()})(),{setStyle:Be,getStyle:ir,get theme(){return Q},set theme(Rt){vt(Rt)},get pointerShapes(){return mt},setPointerShape:oe}},on="animate-on-click",Zr="range-dragging",hs=(L,z,rt,Q)=>{let mt=[],Bt=oe=>{for(let Tt of mt)Tt.update&&typeof Tt.update=="function"&&Tt.update(oe)},Yt=()=>{for(let oe of mt)oe.destroy&&typeof oe.destroy=="function"&&oe.destroy()},ft=(oe,Tt)=>{for(let ue of mt)ue.onAttrChange&&typeof ue.onAttrChange=="function"&&ue.onAttrChange(oe,Tt)},vt=oe=>{if(oe.gettersAndSetters){for(let Tt of oe.gettersAndSetters)if(!(!Tt.name||!Tt.attributes))try{Object.prototype.hasOwnProperty.call(L,Tt.name)||Object.defineProperty(L,Tt.name,Tt.attributes)}catch(ue){console.error("defineSettersGetters error:",ue)}}},Zt=oe=>{var Tt;if(!oe.css)return;let ue=(Tt=L.shadowRoot)==null?void 0:Tt.querySelector("style");!ue||(ue.innerHTML+=oe.css)};return{init:()=>{if(window.tcRangeSliderPlugins)for(let oe of window.tcRangeSliderPlugins){let Tt=oe();mt.push(Tt),Tt.init&&typeof Tt.init=="function"&&(Tt.init(L,z,rt,Q),vt(Tt),Zt(Tt))}},update:Bt,onAttrChange:ft,destroy:Yt}},$n=10,ds=20,kn=(L,z)=>{let rt=new Map,Q=/^value([0-9]*)$/;for(let ft of L.attributes){let vt=ft.nodeName.trim().toLowerCase();if(!Q.test(vt))continue;let Zt=vt.replace("value","").trim(),oe=Zt===""||Zt==="0"||Zt==="1"?0:jt(Zt,0)-1,Tt=St(ft.value)?jt(ft.value,0):ft.value;rt.set(oe,Tt)}let mt=Math.max(...Array.from(rt.keys())),Bt=[];Bt.push([Ae(L,z,0),rt.get(0)]);let Yt=z;for(let ft=1;ft<=mt;ft++){let vt=z.cloneNode(!0);Yt.after(vt),Yt=vt,Bt.push([Ae(L,vt,ft),rt.get(ft)])}return Bt},zi=(L,z,rt,Q,mt,Bt,Yt)=>{try{Object.defineProperty(L,Q,{configurable:!0,get(){if(!z)return;let ft=z.pointers[rt];if(!ft)return;let vt=z.getTextValue(ft.percent);return St(vt)?jt(vt,vt):vt},set:ft=>{z.pointers[rt]?z==null||z.setValue(ft,rt):z==null||z.addPointer(ft)}}),Object.defineProperty(L,mt,{configurable:!0,get(){var ft,vt;return(vt=(ft=z==null?void 0:z.pointers[rt])==null?void 0:ft.getAttr("aria-label"))!=null?vt:void 0},set:ft=>{!z||z.setAriaLabel(rt,ft)}}),Object.defineProperty(L,Bt,{configurable:!0,get(){var ft,vt;return(vt=(ft=z==null?void 0:z.styles)==null?void 0:ft.pointerShapes[rt])!=null?vt:null},set:ft=>{!z||!z.styles||z.styles.setPointerShape(rt,ft)}}),Object.defineProperty(L,Yt,{configurable:!0,get(){var ft;return(ft=z==null?void 0:z.pointers[rt].disabled)!=null?ft:!1},set:ft=>{if(!z)return;let vt=z==null?void 0:z.pointers[rt];!vt||(vt.disabled=ft)}})}catch(ft){console.error(ft)}},Mr=(L,z)=>{let rt=[["value","ariaLabel","pointerShape","pointerDisabled",0],["value0","ariaLabel0","pointerShape0","pointer0Disabled",0],["value1","ariaLabel1","pointerShape1","pointer1Disabled",0]];for(let Q=2;Q<$n;Q++)rt.push([`value${Q}`,`ariaLabel${Q}`,`pointer${Q}Shape`,`pointer${Q}Disabled`,Q-1]);for(let Q of rt)zi(L,z,Q[4],Q[0],Q[1],Q[2],Q[3])},ps=(L,z,rt)=>{var Q;let mt=(Q=rt.shadowRoot)==null?void 0:Q.querySelector(".container");if(mt)for(let Bt of L)z?mt.prepend(Bt.$pointer):mt.append(Bt.$pointer)},Mn=(L,z)=>{if(!(!z||L.length<=1)){for(let rt of L)rt.$pointer.style.zIndex=ds.toString();z.$pointer.style.zIndex=(ds*2).toString()}},ea=0,Cr=100,an=2,Sr="0.3s",hi=(L,z,rt)=>{let Q=rt.map(V=>V[0]),mt=null,Bt=null,Yt=null,ft=null,vt=ea,Zt=Cr,oe,Tt,ue=Kt,Be=an,ir=!1,Rt=!1,ee=!1,zt=0,me=1/0,Ue=!1,Oe,$e,xe=!1,mr=!1,Me=!1,Fr=Sr,Pr=[],fs=V=>{xe||(V.preventDefault&&V.preventDefault(),Vr(V),window.addEventListener("mousemove",Vr),window.addEventListener("mouseup",Jr),de(L,V))},Jr=V=>{xe||(Oe=void 0,$e=void 0,window.removeEventListener("mousemove",Vr),window.removeEventListener("mouseup",Jr),Fr&&z.classList.add(on),Ne(L,V))},yl=(V,at)=>{if(Q.length<=0)return;if(Q.length===1)return Q[0].isClicked(V)&&Fr&&z.classList.remove(on),Q[0];let Ot=ys(V);if(Ue){let le=at,He=Ji(le);He!==void 0&&(le=It(le,He)),Ot?(Oe=le,$e=0,Fr&&z.classList.remove(on)):Oe!==void 0&&($e=le-Oe,Oe=le)}if(!Fn(V)&&!Ot){for(let le of Q)if(!(!le.isClicked(V)||le.disabled))return Fr&&z.classList.remove(on),le;for(let le of Q)if(mt===le)return le}let ve=1/0,we=null;for(let le of Q){if(le.disabled)continue;let He=Math.abs(at-le.percent);He<ve&&(ve=He,we=le)}return we},Ui=()=>Q.findIndex(V=>mt===V&&!V.disabled),Vr=V=>{let at;if(ue===Ut){let{height:ve,top:we}=z.getBoundingClientRect(),le=V.type.indexOf("mouse")!==-1?V.clientY:V.touches[0].clientY;at=Math.min(Math.max(0,le-we),ve)*100/ve}else{let{width:ve,left:we}=z.getBoundingClientRect(),le=V.type.indexOf("mouse")!==-1?V.clientX:V.touches[0].clientX;at=Math.min(Math.max(0,le-we),ve)*100/ve}if((ir||Rt)&&(at=100-at),mt=yl(V.target,at),mt&&Mn(Q,mt),Ue&&Q.length>1&&$e!==void 0){let ve=Q[0],we=Q[Q.length-1],le=ve.percent+$e<0,He=we.percent+$e>100;if(le||He)return;for(let ao=0;ao<Q.length;ao++)qe(ao,Q[ao].percent+$e);return}let Ot=Ui();Ot!==-1&&(qe(Ot,at),mt==null||mt.$pointer.focus())},qi=V=>{if(xe||document.activeElement!==L||mt!=null&&mt.disabled)return;V.stopPropagation(),V.preventDefault();let at=V.deltaY<0,Ot=ir||Rt,ve=at?!Ot:Ot,we=Ui();we!==-1&&(ve?zr(we,Q[we].percent):di(we,Q[we].percent))},jn=V=>{xe||mr||(ue===Ut?Rt?qe(V,100):qe(V,0):ir?di(V,Q[V].percent):zr(V,Q[V].percent))},ms=V=>{xe||mr||(ue===Ut?Rt?qe(V,0):qe(V,100):ir?zr(V,Q[V].percent):di(V,Q[V].percent))},Gi=V=>{xe||mr||(ue===Ut?Rt?di(V,Q[V].percent):zr(V,Q[V].percent):ir?qe(V,100):qe(V,0))},Wi=V=>{xe||mr||(ue===Ut?Rt?zr(V,Q[V].percent):di(V,Q[V].percent):ir?qe(V,0):qe(V,100))},Fn=V=>V.classList.contains("panel"),ys=V=>V.classList.contains("panel-fill"),zr=(V,at)=>{if(at===void 0)return;let Ot=Ji(at);Ot==null&&(Ot=1),at-=Ot,at<0&&(at=0),qe(V,at)},di=(V,at)=>{if(at===void 0)return;let Ot=Ji(at);Ot==null&&(Ot=1),at+=Ot,at>100&&(at=100),qe(V,at)},Yr=()=>{!ft||ft.update({percents:Kr(),values:Yi(),$pointers:Tr(),min:vs(),max:gs(),data:na(),step:ra(),round:oa(),type:ia(),textMin:zn(),textMax:Xr(),rightToLeft:yr(),bottomToTop:ke(),pointersOverlap:Ki(),pointersMinDistance:Xi(),pointersMaxDistance:aa(),rangeDragging:Qi(),disabled:fi(),keyboardDisabled:mi(),mousewheelDisabled:sa()})},Zi=()=>{Yr()},bs=V=>{if(!(ee||Q.length<=1||Zt===vt))if(V===0){let at=me*100/(Zt-vt);return Math.max(0,Q[V+1].percent-at)}else{let at=zt*100/(Zt-vt);return Math.min(Q[V-1].percent+at,100)}},Vn=V=>{if(!(ee||Q.length<=1||Zt===vt))if(V===Q.length-1){let at=me*100/(Zt-vt);return Math.min(Q[V-1].percent+at,100)}else{let at=zt*100/(Zt-vt);return Math.max(0,Q[V+1].percent-at)}},Ji=V=>{let at;if(typeof oe=="function"){let Ot=fe(0,100,vt,Zt,V);at=oe(Ot,V)}else at=oe;if(St(at)){let Ot=Zt-vt;return at=Ot===0?0:at*100/Ot,at}},sn=V=>{if(V===void 0)return;let at=fe(0,100,vt,Zt,V);return Tt!==void 0?Tt[Math.round(at)]:qt(at,Be)},zn=()=>Tt!==void 0?Tt[vt]:vt,Xr=()=>Tt!==void 0?Tt[Zt]:Zt,ra=()=>oe,Un=V=>{var at;return V<=0||ee?zn():(at=sn(Q[V-1].percent))!=null?at:""},bl=V=>{var at;return Q.length<=1||V>=Q.length-1||ee?Xr():(at=sn(Q[V+1].percent))!=null?at:""},Kr=()=>Q.map(V=>V.percent),Yi=()=>Q.map(V=>sn(V.percent)),Tr=()=>Q.map(V=>V.$pointer),vs=()=>vt,gs=()=>Zt,na=()=>Tt,ia=()=>ue,oa=()=>Be,Xi=()=>zt,aa=()=>me,pi=V=>Pr[V],yr=()=>ir,ke=()=>Rt,fi=()=>xe,mi=()=>mr,sa=()=>Me,Ki=()=>ee,Qi=()=>Ue,qe=(V,at)=>{if(at===void 0)return;let Ot=Ji(at);Ot!==void 0&&(at=It(at,Ot));let ve=Q[V];if(!ve)return;let we=ve.updatePosition(at,bs(V),Vn(V),ue,ir,Rt);Bt==null||Bt.updatePosition(ue,Q.map(le=>le.percent),ir,Rt),Yr();for(let le of Q){let He=sn(le.percent);He!==void 0&&(le.setAttr("aria-valuenow",He.toString()),le.setAttr("aria-valuetext",He.toString()))}la(),we&&cr(L,Q.map(le=>sn(le.percent)))},Ur=()=>{for(let V=0;V<Q.length;V++)qe(V,Q[V].percent)},ln=(V,at)=>{vt=Tt!==void 0?0:jt(V,ea),Zt=Tt!==void 0?Tt.length-1:jt(at,Cr),br(vt),to(Zt)},la=()=>{var V,at;for(let Ot=0;Ot<Q.length;Ot++){let ve=Q[Ot];ve.setAttr("aria-valuemin",((V=Un(Ot))!=null?V:"").toString()),ve.setAttr("aria-valuemax",((at=bl(Ot))!=null?at:"").toString())}},br=V=>{vt=jt(V,ea),vt>Zt&&(Zt=vt+Cr),Ur()},to=V=>{Zt=jt(V,Cr),Zt<vt&&(Zt=vt+Cr),Ur()},On=V=>{ee=!0;for(let at=0;at<V.length;at++)eo(V[at],at);ee=!1;for(let at=0;at<V.length;at++)eo(V[at],at)},eo=(V,at)=>{let Ot;Tt!==void 0?(Ot=V==null?0:Le(V,Tt),Ot===-1&&(Ot=0)):(Ot=jt(V,vt),Ot<vt&&(Ot=vt),Ot>Zt&&(Ot=Zt));let ve=fe(vt,Zt,0,100,Ot);qe(at,ve)},qn=V=>{if(V==null){oe=void 0;return}if(typeof V=="function"){oe=V,Ur();return}if(St(V)){oe=jt(V,1);let at=Math.abs(Zt-vt);oe>at&&(oe=void 0),Ur();return}oe=void 0},Gn=V=>{ee=V,Ur()},ca=V=>{(!St(V)||V<0)&&(V=0),zt=V},ro=V=>{(!St(V)||V<0)&&(V=1/0),me=V},cn=V=>{xe=V,z.classList.toggle("disabled",xe),xe?z.setAttribute("aria-disabled","true"):z.hasAttribute("aria-disabled")&&z.removeAttribute("aria-disabled")},yi=V=>{mr=V},En=V=>{Me=V,Me?document.removeEventListener("wheel",qi):document.addEventListener("wheel",qi,{passive:!1})},no=V=>{if(V==null){Tt=void 0;return}if(Tt=dr(V),Tt===void 0||Tt.length<=0){Tt=void 0;return}br(0),to(Tt.length-1),oe===void 0&&qn(1)},Br=V=>{var at;typeof V=="string"?ue=V.trim().toLowerCase()===Ut?Ut:Kt:ue=Kt;let Ot=(at=L.shadowRoot)==null?void 0:at.querySelector(".range-slider-box");if(!Ot)return;Ot.className=`range-slider-box type-${ue}`,Ur();let ve=ue===Ut?"vertical":"horizontal";for(let we of Q)we.setAttr("aria-orientation",ve)},ua=V=>{ir=V,Q.length>1&&ps(Q,ir,L),Ur(),Yr()},io=V=>{Rt=V,Q.length>1&&ps(Q,Rt,L),Ur(),Yr()},Ar=V=>{Be=jt(V,an),Be<0&&(Be=an),Yr()},oo=V=>{V==null||V.toString().trim().toLowerCase()==="false"?(Fr=void 0,z.style.removeProperty(Ce),z.classList.remove(on)):(Fr=V.toString(),z.style.setProperty(Ce,Fr),z.classList.add(on))},vr=(V,at)=>{let Ot=Q[V];!Ot||(Ot.setAttr("aria-label",at),Pr[V]=at)},bi=V=>{if(Oe=void 0,Q.length<=1){Ue=!1,z.classList.remove(Zr);return}Ue=V,z.classList.toggle(Zr,Ue)},Wn=()=>{cn(xt(L.getAttribute(I))),mr=xt(L.getAttribute($)),Me=xt(L.getAttribute(M));let V=Vi(L,/^pointer([0-9]*)-disabled$/,at=>xt(at));for(let at of V){let Ot=at[0];!Q[Ot]||(Q[Ot].disabled=at[1])}},vl=()=>{let V=Vi(L,/^aria-label([0-9]*)$/);for(let at of V){let Ot=at[0];vr(Ot,at[1])}},Zn=V=>{let at=Q.length,Ot=Q[at-1].$pointer,ve=Ot.cloneNode(!0);Ot.after(ve);let we=Ae(L,ve,at);return we.setCallbacks(jn,ms,Gi,Wi),Q.push(we),eo(V,at),Ur(),Yr(),at},ha=()=>{let V=Q.length,at=Q[V-1];return at?(at.destroy(),Q.pop(),Q.length<=1&&bi(!1),Ur(),Yr(),V-1):-1};return(()=>{var V,at;for(let ve of Q)ve.setCallbacks(jn,ms,Gi,Wi);let Ot=(V=L.shadowRoot)==null?void 0:V.querySelector(".panel-fill");Ot&&(Bt=We(Ot)),Br(L.getAttribute(S)),ua(xt(L.getAttribute(A))),io(xt(L.getAttribute(R))),ln(L.getAttribute(w),L.getAttribute(k)),qn(L.getAttribute(O)),no(L.getAttribute(g)),On(rt.map(ve=>ve[1])),Gn(xt(L.getAttribute(y))),ca(jt(L.getAttribute(j),0)),ro(jt(L.getAttribute(r),1/0)),bi(xt(L.getAttribute(v))),Ar(jt(L.getAttribute(C),an)),Wn(),vl(),Yt=ui(L,z,Q),oo((at=L.getAttribute(wt))!=null?at:Sr),z.addEventListener("mousedown",fs),z.addEventListener("mouseup",Jr),z.addEventListener("touchmove",Vr),z.addEventListener("touchstart",Vr),Me||document.addEventListener("wheel",qi,{passive:!1}),ft=hs(L,Zi,{setValues:On,setMin:br,setMax:to,setStep:qn,setPointersOverlap:Gn,setPointersMinDistance:ca,setPointersMaxDistance:ro,setDisabled:cn,setType:Br,setRightToLeft:ua,setBottomToTop:io,setRound:Ar,setKeyboardDisabled:yi,setMousewheelDisabled:En,setRangeDragging:bi,setData:no},{getPercents:Kr,getValues:Yi,getPointerElements:Tr,getMin:vs,getMax:gs,getStep:ra,getData:na,getType:ia,getRound:oa,getTextMin:zn,getTextMax:Xr,isRightToLeft:yr,isBottomToTop:ke,isDisabled:fi,isKeyboardDisabled:mi,isMousewheelDisabled:sa,isPointersOverlap:Ki,isRangeDraggingEnabled:Qi,getPointersMinDistance:Xi,getPointersMaxDistance:aa}),ft.init()})(),{get pointers(){return Q},get styles(){return Yt},get pluginsManager(){return ft},get min(){return zn()},get max(){return Xr()},get step(){return ra()},get pointersOverlap(){return Ki()},set pointersOverlap(V){Gn(V)},get pointersMinDistance(){return Xi()},set pointersMinDistance(V){ca(V)},get pointersMaxDistance(){return aa()},set pointersMaxDistance(V){ro(V)},get disabled(){return fi()},set disabled(V){cn(V)},get data(){return na()},get type(){return ia()},set type(V){Br(V)},get rightToLeft(){return yr()},set rightToLeft(V){ua(V)},get bottomToTop(){return ke()},set bottomToTop(V){io(V)},get round(){return oa()},set round(V){Ar(V)},get animateOnClick(){return Fr},set animateOnClick(V){oo(V)},get keyboardDisabled(){return mi()},set keyboardDisabled(V){yi(V)},get mousewheelDisabled(){return sa()},set mousewheelDisabled(V){En(V)},get rangeDragging(){return Qi()},set rangeDragging(V){bi(V)},setMin:br,setMax:to,setValue:eo,setStep:qn,setData:no,getTextValue:sn,setAriaLabel:vr,getAriaLabel:pi,addPointer:Zn,removePointer:ha,destroy:()=>{z.removeEventListener("mousedown",fs),z.removeEventListener("mouseup",Jr),z.removeEventListener("touchmove",Vr),z.removeEventListener("touchstart",Vr),document.removeEventListener("wheel",qi);for(let V of Q)V.destroy();ft==null||ft.destroy()}}},Hn=(L,z,rt)=>{let Q=us.find(([ft,vt,Zt,oe])=>vt.replace("#","")===z.replace(/\d+/g,""));if(Q&&L.styles){let[ft,vt,Zt,oe]=Q,Tt=z.replace(/\D/g,"").trim(),ue=Tt===""||Tt==="0"||Tt==="1"?0:jt(Tt,0)-1;L.styles.setStyle(ft,rt,ue);return}switch(L&&L.pluginsManager&&L.pluginsManager.onAttrChange(z,rt),z){case w:{L.setMin(rt);break}case k:{L.setMax(rt);break}case O:{L.setStep(rt);break}case y:{L.pointersOverlap=xt(rt);break}case j:{L.pointersMinDistance=jt(rt,0);break}case v:{L.rangeDragging=xt(rt);break}case r:{L.pointersMaxDistance=jt(rt,1/0);break}case I:{L.disabled=xt(rt);break}case $:{L.keyboardDisabled=xt(rt);break}case M:{L.mousewheelDisabled=xt(rt);break}case g:{L.setData(rt);break}case S:{L.type=rt;break}case A:{L.rightToLeft=xt(rt);break}case R:{L.bottomToTop=xt(rt);break}case C:{L.round=jt(rt,an);break}case T:{L.styles&&(L.styles.theme=rt);break}case wt:{L.animateOnClick=rt;break}}let mt=null;if(/^value([0-9]*)$/.test(z)&&(mt="value"),/^pointer([0-9]*)-disabled$/.test(z)&&(mt="pointer-disabled"),/^aria-label([0-9]*)$/.test(z)&&(mt="aria-label"),/^pointer([0-9]*)-shape$/.test(z)&&(mt="pointer-shape"),!mt)return;let Bt=z.replace(/\D/g,"").trim(),Yt=Bt===""||Bt==="0"||Bt==="1"?0:jt(Bt,0)-1;switch(mt){case"value":{L.setValue(rt,Yt);break}case"pointer-disabled":{let ft=L==null?void 0:L.pointers[Yt];if(!ft)return;ft.disabled=xt(rt);break}case"aria-label":{L.setAriaLabel(Yt,rt);break}case"pointer-shape":{L.styles&&L.styles.setPointerShape(Yt,rt);break}}},ml=class extends HTMLElement{constructor(){super(),b(this,"slider"),b(this,"_externalCSSList",[]),b(this,"_observer",null),this.attachShadow({mode:"open"})}set step(L){this.slider&&this.slider.setStep(L)}get step(){var L;return(L=this.slider)==null?void 0:L.step}set disabled(L){this.slider&&(this.slider.disabled=L)}get disabled(){var L,z;return(z=(L=this.slider)==null?void 0:L.disabled)!=null?z:!1}set data(L){var z;(z=this.slider)==null||z.setData(L)}get data(){var L;return(L=this.slider)==null?void 0:L.data}set min(L){var z;(z=this.slider)==null||z.setMin(L)}get min(){var L;return(L=this.slider)==null?void 0:L.min}set max(L){var z;(z=this.slider)==null||z.setMax(L)}get max(){var L;return(L=this.slider)==null?void 0:L.max}set round(L){!this.slider||(this.slider.round=L)}get round(){var L,z;return(z=(L=this.slider)==null?void 0:L.round)!=null?z:an}set type(L){!this.slider||(this.slider.type=L??Kt)}get type(){var L;return((L=this.slider)==null?void 0:L.type)||Kt}set pointersOverlap(L){!this.slider||(this.slider.pointersOverlap=L)}get pointersOverlap(){var L,z;return(z=(L=this.slider)==null?void 0:L.pointersOverlap)!=null?z:!1}set pointersMinDistance(L){!this.slider||(this.slider.pointersMinDistance=L)}get pointersMinDistance(){var L,z;return(z=(L=this.slider)==null?void 0:L.pointersMinDistance)!=null?z:0}set pointersMaxDistance(L){!this.slider||(this.slider.pointersMaxDistance=L)}get pointersMaxDistance(){var L,z;return(z=(L=this.slider)==null?void 0:L.pointersMaxDistance)!=null?z:1/0}set theme(L){!this.slider||!this.slider.styles||(this.slider.styles.theme=L)}get theme(){var L,z,rt;return(rt=(z=(L=this.slider)==null?void 0:L.styles)==null?void 0:z.theme)!=null?rt:null}set rtl(L){!this.slider||(this.slider.rightToLeft=L)}get rtl(){var L,z;return(z=(L=this.slider)==null?void 0:L.rightToLeft)!=null?z:!1}set btt(L){!this.slider||(this.slider.bottomToTop=L)}get btt(){var L,z;return(z=(L=this.slider)==null?void 0:L.bottomToTop)!=null?z:!1}set keyboardDisabled(L){!this.slider||(this.slider.keyboardDisabled=L)}get keyboardDisabled(){var L,z;return(z=(L=this.slider)==null?void 0:L.keyboardDisabled)!=null?z:!1}set mousewheelDisabled(L){!this.slider||(this.slider.mousewheelDisabled=L)}get mousewheelDisabled(){var L,z;return(z=(L=this.slider)==null?void 0:L.mousewheelDisabled)!=null?z:!1}set animateOnClick(L){!this.slider||(this.slider.animateOnClick=L)}get animateOnClick(){var L;return(L=this.slider)==null?void 0:L.animateOnClick}get rangeDragging(){var L,z;return(z=(L=this.slider)==null?void 0:L.rangeDragging)!=null?z:!1}set rangeDragging(L){this.slider&&(this.slider.rangeDragging=xt(L))}get externalCSSList(){return this._externalCSSList}addPointer(L){var z,rt;if(!this.slider)return;let Q=(rt=(z=this.slider)==null?void 0:z.addPointer(L))!=null?rt:0;zi(this,this.slider,Q,`value${Q+1}`,`ariaLabel${Q+1}`,`pointerShape${Q+1}`,`pointer${Q+1}Disabled`)}removePointer(){var L;!this.slider||(L=this.slider)==null||L.removePointer()}addCSS(L){if(!this.shadowRoot)return;let z=document.createElement("style");z.textContent=L,this.shadowRoot.appendChild(z)}connectedCallback(){var L,z;if(!this.shadowRoot)return;this._externalCSSList=Nn(this),this.shadowRoot.innerHTML=_(E,this._externalCSSList);let rt=(L=this.shadowRoot)==null?void 0:L.querySelector(".pointer");if(!rt)return;let Q=(z=this.shadowRoot)==null?void 0:z.getElementById("range-slider");if(!Q)return;let mt=kn(this,rt);this.slider=hi(this,Q,mt),Mr(this,this.slider),this._observer=new MutationObserver(Bt=>{Bt.forEach(Yt=>{var ft;if(!this.slider||Yt.type!=="attributes")return;let vt=Yt.attributeName;!vt||Hn(this.slider,vt,(ft=this.getAttribute(vt))!=null?ft:"")})}),this._observer.observe(this,{attributes:!0})}disconnectedCallback(){this._observer&&this._observer.disconnect(),this.slider&&this.slider.destroy()}},Hr=ml;window.tcRangeSlider=Hr,customElements.get("toolcool-range-slider")||customElements.define("toolcool-range-slider",Hr),customElements.get("tc-range-slider")||customElements.define("tc-range-slider",class extends Hr{})})();function np(m,s){Object.keys(s).forEach(p=>{m.setAttribute(p,s[p])})}class ip extends rp{register(){super.register()}unregister(){super.unregister()}build(){const s=this.schema.properties,p=this.options,b=this.schema.description,_=this.theme,E=this.defaults.startVals[this.key];p.compact||(this.header=this.label=_.getFormInputLabel(this.getTitle(),this.isRequired())),b&&(this.description=_.getFormInputDescription(this.translateProperty(b))),p.infoText&&(this.infoButton=_.getInfoButton(this.translateProperty(p.infoText)));const y=document.createElement("tc-range-slider"),j=Object.keys(s).find(g=>g.includes("min")),r=Object.keys(s).find(g=>g.includes("max")),v={min:s[j].minimum,max:s[r].maximum,value1:(E==null?void 0:E[j])||s[j].default,value2:(E==null?void 0:E[r])||s[r].default,"slider-bg-fill":"#004170","generate-labels":"true","slider-width":"100%","range-dragging":"false"};np(y,v),this.input=y,this.input.id=this.formname,this.control=_.getFormControl(this.label,this.input,this.description,this.infoButton),(this.schema.readOnly||this.schema.readonly)&&(this.disable(!0),this.input.disabled=!0),this.input.addEventListener("change",g=>{g.preventDefault(),g.stopPropagation(),this.value={[j]:g.detail.value1,[r]:g.detail.value2},this.onChange(!0)}),this.container.appendChild(this.control)}destroy(){this.label&&this.label.parentNode&&this.label.parentNode.removeChild(this.label),this.description&&this.description.parentNode&&this.description.parentNode.removeChild(this.description),this.input&&this.input.parentNode&&this.input.parentNode.removeChild(this.input),super.destroy()}}const op=[{type:"object",format:"minmax",func:ip}],ap=m=>{op.map(({type:s,format:p,func:b})=>{Na.JSONEditor.defaults.startVals=m,Na.JSONEditor.defaults.editors[p]=b,Na.JSONEditor.defaults.resolvers.unshift(_=>{if(_.type===s&&_.format===p)return p})})};class mu extends jr{constructor(){super();se(this,Ma);se(this,Ha);se(this,$i,{});se(this,ci,null);this.schema,this.startVals,this.options={show_opt_in:!1,disable_collapse:!0,disable_edit_json:!0,disable_properties:!0,disable_array_delete_all_rows:!0,disable_array_delete_last_row:!0,array_controls_top:!0},this.unstyled=!1}getSchema(){return this.schema}setSchema(p){this.schema=p}getDefaultValues(){return this.startVals}setDefaultValues(p){this.startVals=p}getValues(){return Ee(this,$i)}firstUpdated(){if(!Ee(this,ci)){ap(this.startVals||{});const p=this.renderRoot.querySelector("form");Si(this,ci,new Na.JSONEditor(p,{schema:this.schema,...this.startVals?{startval:this.startVals}:{},theme:"html",ajax:!0,...this.options})),rr(this,Ha,qu).call(this)}}render(){return ae`
|
|
285
285
|
<style>
|
|
286
286
|
${tp}
|
|
287
287
|
${!this.unstyled&&ep}
|
|
@@ -385,7 +385,8 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
385
385
|
</figure>
|
|
386
386
|
</div>
|
|
387
387
|
`}}Qo=new WeakMap,Ua=new WeakMap,qa=new WeakMap,Xe(bu,"properties",{actions:{attribute:!1},selectedTab:{state:!0},tabs:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean}}),customElements.define("eox-layercontrol-tabs",bu);const lp=`
|
|
388
|
-
button
|
|
388
|
+
button,
|
|
389
|
+
.button {
|
|
389
390
|
/* TODO: why does this only work here and not from :root? */
|
|
390
391
|
--primary-color: #004170;
|
|
391
392
|
--primary-color-hover: #004170CC;
|
|
@@ -412,31 +413,37 @@ button {
|
|
|
412
413
|
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
413
414
|
}
|
|
414
415
|
|
|
415
|
-
button:hover:not([disabled]):not(.icon)
|
|
416
|
+
button:hover:not([disabled]):not(.icon),
|
|
417
|
+
.button:hover:not([disabled]):not(.icon) {
|
|
416
418
|
box-shadow: 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12);
|
|
417
419
|
background: var(--primary-color-hover);
|
|
418
420
|
}
|
|
419
421
|
|
|
420
|
-
button, button:active
|
|
422
|
+
button, button:active,
|
|
423
|
+
.button, .button:active {
|
|
421
424
|
background: var(--primary-color);
|
|
422
425
|
}
|
|
423
426
|
|
|
424
|
-
button[disabled]
|
|
427
|
+
button[disabled],
|
|
428
|
+
.button[disabled] {
|
|
425
429
|
opacity: 0.5;
|
|
426
430
|
}
|
|
427
431
|
|
|
428
|
-
button.outline
|
|
432
|
+
button.outline,
|
|
433
|
+
.button.outline {
|
|
429
434
|
background: transparent;
|
|
430
435
|
box-shadow: none;
|
|
431
436
|
color: var(--primary-color);
|
|
432
437
|
outline: 1px solid var(--primary-color);
|
|
433
438
|
}
|
|
434
439
|
|
|
435
|
-
button.outline:hover
|
|
440
|
+
button.outline:hover,
|
|
441
|
+
.button.outline:hover {
|
|
436
442
|
background: transparent;
|
|
437
443
|
}
|
|
438
444
|
|
|
439
|
-
button.icon
|
|
445
|
+
button.icon,
|
|
446
|
+
.button.icon {
|
|
440
447
|
background: transparent;
|
|
441
448
|
border: none;
|
|
442
449
|
box-shadow: none;
|
|
@@ -447,38 +454,43 @@ button.icon {
|
|
|
447
454
|
text-indent: -9999px;
|
|
448
455
|
}
|
|
449
456
|
|
|
450
|
-
button.icon-text
|
|
457
|
+
button.icon-text,
|
|
458
|
+
.button.icon-text {
|
|
451
459
|
text-indent: 26px;
|
|
452
460
|
}
|
|
453
461
|
|
|
454
|
-
button.icon:before, button.icon-text:before
|
|
462
|
+
button.icon:before, button.icon-text:before,
|
|
463
|
+
.button.icon:before, .button.icon-text:before {
|
|
455
464
|
position: absolute;
|
|
456
465
|
text-indent: 0;
|
|
457
466
|
line-height: initial;
|
|
458
467
|
}
|
|
459
468
|
|
|
460
|
-
button.icon:before
|
|
469
|
+
button.icon:before,
|
|
470
|
+
.button.icon:before {
|
|
461
471
|
width: 24px;
|
|
462
472
|
height: 24px;
|
|
463
473
|
margin-right: 0;
|
|
464
474
|
}
|
|
465
475
|
|
|
466
|
-
button.icon-text:before
|
|
476
|
+
button.icon-text:before,
|
|
477
|
+
.button.icon-text:before {
|
|
467
478
|
width: 18px;
|
|
468
479
|
height: 18px;
|
|
469
480
|
}
|
|
470
481
|
|
|
471
|
-
button.small
|
|
482
|
+
button.small,
|
|
483
|
+
.button.small {
|
|
472
484
|
height: 28px;
|
|
473
485
|
padding: 12.4px;
|
|
474
486
|
font-size: .75rem;
|
|
475
487
|
}
|
|
476
|
-
`;class vu extends jr{constructor(){super();Xe(this,"_removeButton",Yd(this));Xe(this,"_sortButton",Xd(this.unstyled));Xe(this,"_button",p=>Jd(p,this.unstyled));se(this,Ga,"");se(this,Wa,`
|
|
488
|
+
`;class vu extends jr{constructor(){super();Xe(this,"_removeButton",()=>Yd(this));Xe(this,"_sortButton",()=>Xd(this.unstyled));Xe(this,"_button",p=>Jd(p,this.unstyled));se(this,Ga,"");se(this,Wa,`
|
|
477
489
|
${lp}
|
|
478
490
|
${hu}
|
|
479
491
|
${hl}
|
|
480
492
|
${du}
|
|
481
|
-
|
|
493
|
+
.drag-handle {
|
|
482
494
|
cursor: n-resize;
|
|
483
495
|
}
|
|
484
496
|
.single-action-container,
|
|
@@ -535,11 +547,13 @@ button.small {
|
|
|
535
547
|
height: 16px;
|
|
536
548
|
width: 16px;
|
|
537
549
|
}
|
|
538
|
-
eox-layercontrol-tabs button.icon
|
|
550
|
+
eox-layercontrol-tabs button.icon,
|
|
551
|
+
eox-layercontrol-tabs .button.icon {
|
|
539
552
|
display: flex;
|
|
540
553
|
justify-content: center;
|
|
541
554
|
}
|
|
542
|
-
eox-layercontrol-tabs .icon::before
|
|
555
|
+
eox-layercontrol-tabs button.icon::before,
|
|
556
|
+
eox-layercontrol-tabs .button.icon::before {
|
|
543
557
|
width: 16px;
|
|
544
558
|
height: 16px;
|
|
545
559
|
}
|
|
@@ -560,14 +574,14 @@ button.small {
|
|
|
560
574
|
content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23ff0000' viewBox='0 0 24 24'%3E%3Ctitle%3Edelete-outline%3C/title%3E%3Cpath d='M6,19A2,2 0 0,0 8,21H16A2,2 0 0,0 18,19V7H6V19M8,9H16V19H8V9M15.5,4L14.5,3H9.5L8.5,4H5V6H19V4H15.5Z' /%3E%3C/svg%3E");
|
|
561
575
|
}
|
|
562
576
|
.single-action .sort-icon::before,
|
|
563
|
-
[slot=sort-icon] button.icon::before {
|
|
577
|
+
[slot=sort-icon] .button.icon::before {
|
|
564
578
|
content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23004170' viewBox='0 0 24 24'%3E%3Ctitle%3Edrag-horizontal-variant%3C/title%3E%3Cpath d='M21 11H3V9H21V11M21 13H3V15H21V13Z' /%3E%3C/svg%3E");
|
|
565
579
|
}
|
|
566
580
|
[slot=info-content],
|
|
567
581
|
[slot=opacity-content] {
|
|
568
582
|
padding: 12px 6px;
|
|
569
583
|
}
|
|
570
|
-
`);this.layer=null,this.tools=[],this.unstyled=!1,this.noShadow=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){var r;const p=Wd(this.tools,this.layer),b=Zd(this.tools,this.layer),_=this[`_${p==null?void 0:p[0]}Button`],E=((r=this.tools)==null?void 0:r.length)===1?`${this.tools[0]}-icon`:"",y=p==null?void 0:p.length,j=b==null?void 0:b.length;return ae`
|
|
584
|
+
`);this.layer=null,this.tools=[],this.unstyled=!1,this.noShadow=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){var r;const p=Wd(this.tools,this.layer),b=Zd(this.tools,this.layer),_=this[`_${p==null?void 0:p[0]}Button`]?this[`_${p==null?void 0:p[0]}Button`]():_e,E=((r=this.tools)==null?void 0:r.length)===1?`${this.tools[0]}-icon`:"",y=p==null?void 0:p.length,j=b==null?void 0:b.length;return ae`
|
|
571
585
|
<style>
|
|
572
586
|
${Ee(this,Ga)}
|
|
573
587
|
${!this.unstyled&&Ee(this,Wa)}
|
|
@@ -580,7 +594,7 @@ button.small {
|
|
|
580
594
|
`,()=>{var v;return ae`
|
|
581
595
|
<details
|
|
582
596
|
class="tools"
|
|
583
|
-
open=${this.layer.get("layerControlToolsExpand")||
|
|
597
|
+
open=${this.layer.get("layerControlToolsExpand")||_e}
|
|
584
598
|
>
|
|
585
599
|
<summary>
|
|
586
600
|
<button class="icon ${E}">Tools</button>
|
|
@@ -619,8 +633,8 @@ button.small {
|
|
|
619
633
|
@changed=${()=>this.requestUpdate()}
|
|
620
634
|
></eox-layercontrol-layerconfig>
|
|
621
635
|
</div>
|
|
622
|
-
<div slot="remove-icon">${this._removeButton}</div>
|
|
623
|
-
<div slot="sort-icon">${this._sortButton}</div>
|
|
636
|
+
<div slot="remove-icon">${this._removeButton()}</div>
|
|
637
|
+
<div slot="sort-icon">${this._sortButton()}</div>
|
|
624
638
|
</eox-layercontrol-tabs>
|
|
625
639
|
</details>
|
|
626
640
|
`})}
|
|
@@ -674,7 +688,7 @@ button.small {
|
|
|
674
688
|
${qr(this.layer,()=>ae`
|
|
675
689
|
<!-- Render the layer -->
|
|
676
690
|
<div class="layer ${b} ${_}">
|
|
677
|
-
<label class="${E}">
|
|
691
|
+
<label class="drag-handle ${E}">
|
|
678
692
|
<!-- Input element for layer visibility -->
|
|
679
693
|
<input
|
|
680
694
|
type=${y}
|
|
@@ -753,7 +767,7 @@ button.small {
|
|
|
753
767
|
></eox-layercontrol-layer-list>
|
|
754
768
|
</details>
|
|
755
769
|
`)}
|
|
756
|
-
`}}Xa=new WeakMap,Ka=new WeakMap,Xe(wu,"properties",{group:{attribute:!1},idProperty:{attribute:"id-property"},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean}}),customElements.define("eox-layercontrol-layer-group",wu);const hp=m=>{const{layers:s,idProperty:p,titleProperty:b,renderRoot:_}=m;if(s){const E=_.querySelector("ul");zd(s,p,b),Vd(E,s,p,m)}};var dp="Expected a function",_u=NaN,pp="[object Symbol]",fp=/^\s+|\s+$/g,mp=/^[-+]0x[0-9a-f]+$/i,yp=/^0b[01]+$/i,bp=/^0o[0-7]+$/i,vp=parseInt,gp=typeof Da=="object"&&Da&&Da.Object===Object&&Da,wp=typeof self=="object"&&self&&self.Object===Object&&self,_p=gp||wp||Function("return this")(),xp=Object.prototype,kp=xp.toString,jp=Math.max,Op=Math.min,dl=function(){return _p.Date.now()};function Ep(m,s,p){var b,_,E,y,j,r,v=0,g=!1,w=!1,k=!0;if(typeof m!="function")throw new TypeError(dp);s=xu(s)||0,pl(p)&&(g=!!p.leading,w="maxWait"in p,E=w?jp(xu(p.maxWait)||0,s):E,k="trailing"in p?!!p.trailing:k);function O(B){var q=b,F=_;return b=_=void 0,v=B,y=m.apply(F,q),y}function C(B){return v=B,j=setTimeout(A,s),g?O(B):y}function S(B){var q=B-r,F=B-v,N=s-q;return w?Op(N,E-F):N}function T(B){var q=B-r,F=B-v;return r===void 0||q>=s||q<0||w&&F>=E}function A(){var B=dl();if(T(B))return R(B);j=setTimeout(A,S(B))}function R(B){return j=void 0,k&&b?O(B):(b=_=void 0,y)}function I(){j!==void 0&&clearTimeout(j),v=0,b=r=_=j=void 0}function $(){return j===void 0?y:R(dl())}function M(){var B=dl(),q=T(B);if(b=arguments,_=this,r=B,q){if(j===void 0)return C(r);if(w)return j=setTimeout(A,s),O(r)}return j===void 0&&(j=setTimeout(A,s)),y}return M.cancel=I,M.flush=$,M}function pl(m){var s=typeof m;return!!m&&(s=="object"||s=="function")}function Cp(m){return!!m&&typeof m=="object"}function Sp(m){return typeof m=="symbol"||Cp(m)&&kp.call(m)==pp}function xu(m){if(typeof m=="number")return m;if(Sp(m))return _u;if(pl(m)){var s=typeof m.valueOf=="function"?m.valueOf():m;m=pl(s)?s+"":s}if(typeof m!="string")return m===0?m:+m;m=m.replace(fp,"");var p=yp.test(m);return p||bp.test(m)?vp(m.slice(2),p?2:8):mp.test(m)?_u:+m}var Pp=Ep;const Tp=Qd(Pp),Ap=m=>{const{layers:s}=m,p=Tp(()=>{m.requestUpdate(),m.dispatchEvent(new CustomEvent("changed",{bubbles:!0}))},50),b=()=>p();s&&(s.hasListener("change:length")&&(s==null||s.un("change:length",b)),s.on("change:length",b))};class ku extends jr{constructor(){super();se(this,Qa,"");se(this,ts,`
|
|
770
|
+
`}}Xa=new WeakMap,Ka=new WeakMap,Xe(wu,"properties",{group:{attribute:!1},idProperty:{attribute:"id-property"},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean}}),customElements.define("eox-layercontrol-layer-group",wu);const hp=m=>{const{layers:s,idProperty:p,titleProperty:b,renderRoot:_}=m;if(s){const E=_.querySelector("ul");zd(s,p,b,m),Vd(E,s,p,m)}};var dp="Expected a function",_u=NaN,pp="[object Symbol]",fp=/^\s+|\s+$/g,mp=/^[-+]0x[0-9a-f]+$/i,yp=/^0b[01]+$/i,bp=/^0o[0-7]+$/i,vp=parseInt,gp=typeof Da=="object"&&Da&&Da.Object===Object&&Da,wp=typeof self=="object"&&self&&self.Object===Object&&self,_p=gp||wp||Function("return this")(),xp=Object.prototype,kp=xp.toString,jp=Math.max,Op=Math.min,dl=function(){return _p.Date.now()};function Ep(m,s,p){var b,_,E,y,j,r,v=0,g=!1,w=!1,k=!0;if(typeof m!="function")throw new TypeError(dp);s=xu(s)||0,pl(p)&&(g=!!p.leading,w="maxWait"in p,E=w?jp(xu(p.maxWait)||0,s):E,k="trailing"in p?!!p.trailing:k);function O(B){var q=b,F=_;return b=_=void 0,v=B,y=m.apply(F,q),y}function C(B){return v=B,j=setTimeout(A,s),g?O(B):y}function S(B){var q=B-r,F=B-v,N=s-q;return w?Op(N,E-F):N}function T(B){var q=B-r,F=B-v;return r===void 0||q>=s||q<0||w&&F>=E}function A(){var B=dl();if(T(B))return R(B);j=setTimeout(A,S(B))}function R(B){return j=void 0,k&&b?O(B):(b=_=void 0,y)}function I(){j!==void 0&&clearTimeout(j),v=0,b=r=_=j=void 0}function $(){return j===void 0?y:R(dl())}function M(){var B=dl(),q=T(B);if(b=arguments,_=this,r=B,q){if(j===void 0)return C(r);if(w)return j=setTimeout(A,s),O(r)}return j===void 0&&(j=setTimeout(A,s)),y}return M.cancel=I,M.flush=$,M}function pl(m){var s=typeof m;return!!m&&(s=="object"||s=="function")}function Cp(m){return!!m&&typeof m=="object"}function Sp(m){return typeof m=="symbol"||Cp(m)&&kp.call(m)==pp}function xu(m){if(typeof m=="number")return m;if(Sp(m))return _u;if(pl(m)){var s=typeof m.valueOf=="function"?m.valueOf():m;m=pl(s)?s+"":s}if(typeof m!="string")return m===0?m:+m;m=m.replace(fp,"");var p=yp.test(m);return p||bp.test(m)?vp(m.slice(2),p?2:8):mp.test(m)?_u:+m}var Pp=Ep;const Tp=Qd(Pp),Ap=m=>{const{layers:s}=m,p=Tp(()=>{m.requestUpdate(),m.dispatchEvent(new CustomEvent("changed",{bubbles:!0}))},50),b=()=>p();s&&(s.hasListener("change:length")&&(s==null||s.un("change:length",b)),s.on("change:length",b))};class ku extends jr{constructor(){super();se(this,Qa,"");se(this,ts,`
|
|
757
771
|
ul {
|
|
758
772
|
padding: 0;
|
|
759
773
|
margin: 0;
|
|
@@ -839,7 +853,14 @@ button.small {
|
|
|
839
853
|
|
|
840
854
|
<!-- Button to handle adding layers -->
|
|
841
855
|
<button @click="${rr(this,es,Zu)}">add</button>
|
|
842
|
-
`}}es=new WeakSet,Zu=function(){Lp(this)},Xe(ju,"properties",{idProperty:{attribute:"id-property"},layers:{attribute:!1},titleProperty:{attribute:"title-property",type:String},unstyled:{type:Boolean},noShadow:{type:Boolean}}),customElements.define("eox-layercontrol-optional-list",ju);const Rp=(m,s)=>{s.jsonInput=m.target.value,s.requestUpdate()},Ou=m=>{const s=JSON.parse(`{"data":${Nc(m.jsonInput)}}`);Array.isArray(s.data)?s.data.forEach(p=>{m.eoxMap.addOrUpdateLayer(p)}):m.eoxMap.addOrUpdateLayer(s.data),m.jsonInput=null,m.requestUpdate()},Ip=(m,s)=>{s.urlInput=m.target.value,s.requestUpdate()};async function Bp(m){const s=m.urlInput;if(m.wmsCapabilities=null,m.searchLoad=!0,m.requestUpdate(),!s)return!1;if(Gs(s)==="XYZ")return{Name:s};try{const p=await ud(s);m.wmsCapabilities=p}catch{}finally{m.searchLoad=!1,m.requestUpdate()}return!1}const Dp=(m,s)=>{const{Name:p}=m,b=Gs(s.urlInput)||"XYZ",_={type:"Tile",properties:{id:p,title:p},source:{type:b,url:s.urlInput,params:{LAYERS:p}}};s.jsonInput=JSON.stringify(_)},Np=(m,s)=>{s.open=m||null,s.urlInput=null,s.jsonInput=null,s.wmsCapabilities=null,s.requestUpdate()};class Eu extends jr{constructor(){super();se(this,rs);se(this,ns);se(this,ta);se(this,is);se(this,os);se(this,Hi);Xe(this,"urlInput",null);Xe(this,"jsonInput",null);Xe(this,"open",null);Xe(this,"searchLoad",!1);Xe(this,"wmsCapabilities",null);se(this,as
|
|
856
|
+
`}}es=new WeakSet,Zu=function(){Lp(this)},Xe(ju,"properties",{idProperty:{attribute:"id-property"},layers:{attribute:!1},titleProperty:{attribute:"title-property",type:String},unstyled:{type:Boolean},noShadow:{type:Boolean}}),customElements.define("eox-layercontrol-optional-list",ju);const Rp=(m,s)=>{s.jsonInput=m.target.value,s.requestUpdate()},Ou=m=>{const s=JSON.parse(`{"data":${Nc(m.jsonInput)}}`);Array.isArray(s.data)?s.data.forEach(p=>{m.eoxMap.addOrUpdateLayer(p)}):m.eoxMap.addOrUpdateLayer(s.data),m.jsonInput=null,m.requestUpdate()},Ip=(m,s)=>{s.urlInput=m.target.value,s.requestUpdate()};async function Bp(m){const s=m.urlInput;if(m.wmsCapabilities=null,m.searchLoad=!0,m.requestUpdate(),!s)return!1;if(Gs(s)==="XYZ")return{Name:s};try{const p=await ud(s);m.wmsCapabilities=p}catch{}finally{m.searchLoad=!1,m.requestUpdate()}return!1}const Dp=(m,s)=>{const{Name:p}=m,b=Gs(s.urlInput)||"XYZ",_={type:"Tile",properties:{id:p,title:p},source:{type:b,url:s.urlInput,params:{LAYERS:p}}};s.jsonInput=JSON.stringify(_)},Np=(m,s)=>{s.open=m||null,s.urlInput=null,s.jsonInput=null,s.wmsCapabilities=null,s.requestUpdate()};class Eu extends jr{constructor(){super();se(this,rs);se(this,ns);se(this,ta);se(this,is);se(this,os);se(this,Hi);Xe(this,"urlInput",null);Xe(this,"jsonInput",null);Xe(this,"open",null);Xe(this,"searchLoad",!1);Xe(this,"wmsCapabilities",null);se(this,as,`
|
|
857
|
+
.eox-add-layer-main .open {
|
|
858
|
+
position: relative;
|
|
859
|
+
}
|
|
860
|
+
.eox-add-layer-main .close {
|
|
861
|
+
display: none;
|
|
862
|
+
}
|
|
863
|
+
`);se(this,ss,`
|
|
843
864
|
.eox-add {
|
|
844
865
|
background: #f0f2f5;
|
|
845
866
|
border-top: 1px solid #0041701a;
|
|
@@ -972,7 +993,7 @@ button.small {
|
|
|
972
993
|
font-weight: bold;
|
|
973
994
|
display: inline-block;
|
|
974
995
|
}
|
|
975
|
-
`);this.eoxMap=null,this.unstyled=!1,this.noShadow=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const p=this.open?"open":"close",b=this.open==="url",_=this.open==="json",E=!hd(this.urlInput)||this.searchLoad?!0:
|
|
996
|
+
`);this.eoxMap=null,this.unstyled=!1,this.noShadow=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const p=this.open?"open":"close",b=this.open==="url",_=this.open==="json",E=!hd(this.urlInput)||this.searchLoad?!0:_e;return ae`
|
|
976
997
|
<style>
|
|
977
998
|
${Ee(this,as)}
|
|
978
999
|
${!this.unstyled&&Ee(this,ss)}
|
|
@@ -999,7 +1020,9 @@ button.small {
|
|
|
999
1020
|
<button
|
|
1000
1021
|
class="add-icon icon"
|
|
1001
1022
|
@click=${()=>rr(this,Hi,Ls).call(this,this.open?null:"url")}
|
|
1002
|
-
|
|
1023
|
+
>
|
|
1024
|
+
${this.unstyled?"Add Layer":""}
|
|
1025
|
+
</button>
|
|
1003
1026
|
</div>
|
|
1004
1027
|
<div class="eox-add ${p}">
|
|
1005
1028
|
${b?ae`
|
|
@@ -1019,6 +1042,7 @@ button.small {
|
|
|
1019
1042
|
disabled=${E}
|
|
1020
1043
|
@click=${rr(this,ns,Yu)}
|
|
1021
1044
|
>
|
|
1045
|
+
${this.unstyled?"Search":""}
|
|
1022
1046
|
</button>
|
|
1023
1047
|
</div>
|
|
1024
1048
|
|
|
@@ -1031,10 +1055,12 @@ button.small {
|
|
|
1031
1055
|
<button
|
|
1032
1056
|
class="add-layer-icon icon"
|
|
1033
1057
|
@click=${()=>rr(this,ta,oc).call(this,y)}
|
|
1034
|
-
|
|
1058
|
+
>
|
|
1059
|
+
${this.unstyled?"+":""}
|
|
1060
|
+
</button>
|
|
1035
1061
|
</li>
|
|
1036
1062
|
`})}
|
|
1037
|
-
</ul>`:
|
|
1063
|
+
</ul>`:_e}
|
|
1038
1064
|
`:ae`
|
|
1039
1065
|
<!-- Textarea for JSON input -->
|
|
1040
1066
|
<textarea
|
|
@@ -1047,9 +1073,11 @@ button.small {
|
|
|
1047
1073
|
<!-- Button to add JSON layer -->
|
|
1048
1074
|
<button
|
|
1049
1075
|
class="add-layer-icon json-add-layer"
|
|
1050
|
-
disabled=${dd(this.jsonInput)?
|
|
1076
|
+
disabled=${dd(this.jsonInput)?_e:!0}
|
|
1051
1077
|
@click=${rr(this,is,Xu)}
|
|
1052
|
-
|
|
1078
|
+
>
|
|
1079
|
+
${this.unstyled?"Add JSON":""}
|
|
1080
|
+
</button>
|
|
1053
1081
|
`}
|
|
1054
1082
|
</div>
|
|
1055
1083
|
</div>
|
|
@@ -1094,4 +1122,4 @@ button.small {
|
|
|
1094
1122
|
@changed=${()=>this.requestUpdate()}
|
|
1095
1123
|
></eox-layercontrol-optional-list>
|
|
1096
1124
|
`)}
|
|
1097
|
-
`}}Fi=new WeakMap,ls=new WeakSet,Qu=function(p){$p(p,this)},cs=new WeakMap,Xe(fl,"properties",{for:{type:String},idProperty:{attribute:"id-property"},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},addExternalLayers:{attribute:!1},unstyled:{type:Boolean},styleOverride:{type:String}}),customElements.define("eox-layercontrol",fl),
|
|
1125
|
+
`}}Fi=new WeakMap,ls=new WeakSet,Qu=function(p){$p(p,this)},cs=new WeakMap,Xe(fl,"properties",{for:{type:String},idProperty:{attribute:"id-property"},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},addExternalLayers:{attribute:!1},unstyled:{type:Boolean},styleOverride:{type:String}}),customElements.define("eox-layercontrol",fl),je.EOxLayerControl=fl,Object.defineProperty(je,Symbol.toStringTag,{value:"Module"})});
|