cocoda-sdk 3.3.1 → 3.3.3
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.
package/dist/cocoda-sdk.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* cocoda-sdk v3.3.
|
|
2
|
+
* cocoda-sdk v3.3.3
|
|
3
3
|
* Copyright (c) 2021 Verbundzentrale des GBV (VZG)
|
|
4
4
|
* @license MIT
|
|
5
5
|
*
|
|
6
6
|
* For dependency license information, please see ./dist/cocoda-sdk.js.LICENSES.txt.
|
|
7
7
|
*/
|
|
8
|
-
var CDK=(()=>{var
|
|
9
|
-
`),function(u){if(s=u.indexOf(":"),i=nn.trim(u.substr(0,s)).toLowerCase(),n=nn.trim(u.substr(s+1)),i){if(t[i]&&Em.indexOf(i)>=0)return;i==="set-cookie"?t[i]=(t[i]?t[i]:[]).concat([n]):t[i]=t[i]?t[i]+", "+n:n}}),t}});var da=g((FE,pa)=>{"use strict";var ha=Be();pa.exports=ha.isStandardBrowserEnv()?function(){var e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a"),i;function n(s){var a=s;return e&&(t.setAttribute("href",a),a=t.href),t.setAttribute("href",a),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:t.pathname.charAt(0)==="/"?t.pathname:"/"+t.pathname}}return i=n(window.location.href),function(a){var u=ha.isString(a)?n(a):a;return u.protocol===i.protocol&&u.host===i.host}}():function(){return function(){return!0}}()});var wt=g((BE,ma)=>{"use strict";function sn(r){this.message=r}sn.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")};sn.prototype.__CANCEL__=!0;ma.exports=sn});var on=g((kE,ga)=>{"use strict";var Zt=Be(),Im=ra(),Tm=ia(),Pm=Qi(),Mm=fa(),Rm=la(),Lm=da(),an=tn(),jm=rn(),Nm=wt();ga.exports=function(e){return new Promise(function(i,n){var s=e.data,a=e.headers,u=e.responseType,o;function l(){e.cancelToken&&e.cancelToken.unsubscribe(o),e.signal&&e.signal.removeEventListener("abort",o)}Zt.isFormData(s)&&delete a["Content-Type"];var p=new XMLHttpRequest;if(e.auth){var w=e.auth.username||"",b=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";a.Authorization="Basic "+btoa(w+":"+b)}var q=Mm(e.baseURL,e.url);p.open(e.method.toUpperCase(),Pm(q,e.params,e.paramsSerializer),!0),p.timeout=e.timeout;function y(){if(!!p){var H="getAllResponseHeaders"in p?Rm(p.getAllResponseHeaders()):null,K=!u||u==="text"||u==="json"?p.responseText:p.response,Q={data:K,status:p.status,statusText:p.statusText,headers:H,config:e,request:p};Im(function(Z){i(Z),l()},function(Z){n(Z),l()},Q),p=null}}if("onloadend"in p?p.onloadend=y:p.onreadystatechange=function(){!p||p.readyState!==4||p.status===0&&!(p.responseURL&&p.responseURL.indexOf("file:")===0)||setTimeout(y)},p.onabort=function(){!p||(n(an("Request aborted",e,"ECONNABORTED",p)),p=null)},p.onerror=function(){n(an("Network Error",e,null,p)),p=null},p.ontimeout=function(){var K=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded",Q=e.transitional||jm;e.timeoutErrorMessage&&(K=e.timeoutErrorMessage),n(an(K,e,Q.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",p)),p=null},Zt.isStandardBrowserEnv()){var P=(e.withCredentials||Lm(q))&&e.xsrfCookieName?Tm.read(e.xsrfCookieName):void 0;P&&(a[e.xsrfHeaderName]=P)}"setRequestHeader"in p&&Zt.forEach(a,function(K,Q){typeof s=="undefined"&&Q.toLowerCase()==="content-type"?delete a[Q]:p.setRequestHeader(Q,K)}),Zt.isUndefined(e.withCredentials)||(p.withCredentials=!!e.withCredentials),u&&u!=="json"&&(p.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&p.addEventListener("progress",e.onDownloadProgress),typeof e.onUploadProgress=="function"&&p.upload&&p.upload.addEventListener("progress",e.onUploadProgress),(e.cancelToken||e.signal)&&(o=function(H){!p||(n(!H||H&&H.type?new Nm("canceled"):H),p.abort(),p=null)},e.cancelToken&&e.cancelToken.subscribe(o),e.signal&&(e.signal.aborted?o():e.signal.addEventListener("abort",o))),s||(s=null),p.send(s)})}});var ei=g(($E,_a)=>{"use strict";var Me=Be(),va=Ys(),Um=en(),Dm=rn(),Fm={"Content-Type":"application/x-www-form-urlencoded"};function ya(r,e){!Me.isUndefined(r)&&Me.isUndefined(r["Content-Type"])&&(r["Content-Type"]=e)}function Bm(){var r;return typeof XMLHttpRequest!="undefined"?r=on():typeof process!="undefined"&&Object.prototype.toString.call(process)==="[object process]"&&(r=on()),r}function km(r,e,t){if(Me.isString(r))try{return(e||JSON.parse)(r),Me.trim(r)}catch(i){if(i.name!=="SyntaxError")throw i}return(t||JSON.stringify)(r)}var Qt={transitional:Dm,adapter:Bm(),transformRequest:[function(e,t){return va(t,"Accept"),va(t,"Content-Type"),Me.isFormData(e)||Me.isArrayBuffer(e)||Me.isBuffer(e)||Me.isStream(e)||Me.isFile(e)||Me.isBlob(e)?e:Me.isArrayBufferView(e)?e.buffer:Me.isURLSearchParams(e)?(ya(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):Me.isObject(e)||t&&t["Content-Type"]==="application/json"?(ya(t,"application/json"),km(e)):e}],transformResponse:[function(e){var t=this.transitional||Qt.transitional,i=t&&t.silentJSONParsing,n=t&&t.forcedJSONParsing,s=!i&&this.responseType==="json";if(s||n&&Me.isString(e)&&e.length)try{return JSON.parse(e)}catch(a){if(s)throw a.name==="SyntaxError"?Um(a,this,"E_JSON_PARSE"):a}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Me.forEach(["delete","get","head"],function(e){Qt.headers[e]={}});Me.forEach(["post","put","patch"],function(e){Qt.headers[e]=Me.merge(Fm)});_a.exports=Qt});var ba=g((zE,wa)=>{"use strict";var $m=Be(),zm=ei();wa.exports=function(e,t,i){var n=this||zm;return $m.forEach(i,function(a){e=a.call(n,e,t)}),e}});var un=g((WE,xa)=>{"use strict";xa.exports=function(e){return!!(e&&e.__CANCEL__)}});var Oa=g((HE,Aa)=>{"use strict";var Sa=Be(),fn=ba(),Wm=un(),Hm=ei(),Gm=wt();function cn(r){if(r.cancelToken&&r.cancelToken.throwIfRequested(),r.signal&&r.signal.aborted)throw new Gm("canceled")}Aa.exports=function(e){cn(e),e.headers=e.headers||{},e.data=fn.call(e,e.data,e.headers,e.transformRequest),e.headers=Sa.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),Sa.forEach(["delete","get","head","post","put","patch","common"],function(n){delete e.headers[n]});var t=e.adapter||Hm.adapter;return t(e).then(function(n){return cn(e),n.data=fn.call(e,n.data,n.headers,e.transformResponse),n},function(n){return Wm(n)||(cn(e),n&&n.response&&(n.response.data=fn.call(e,n.response.data,n.response.headers,e.transformResponse))),Promise.reject(n)})}});var ln=g((GE,qa)=>{"use strict";var We=Be();qa.exports=function(e,t){t=t||{};var i={};function n(p,w){return We.isPlainObject(p)&&We.isPlainObject(w)?We.merge(p,w):We.isPlainObject(w)?We.merge({},w):We.isArray(w)?w.slice():w}function s(p){if(We.isUndefined(t[p])){if(!We.isUndefined(e[p]))return n(void 0,e[p])}else return n(e[p],t[p])}function a(p){if(!We.isUndefined(t[p]))return n(void 0,t[p])}function u(p){if(We.isUndefined(t[p])){if(!We.isUndefined(e[p]))return n(void 0,e[p])}else return n(void 0,t[p])}function o(p){if(p in t)return n(e[p],t[p]);if(p in e)return n(void 0,e[p])}var l={url:a,method:a,data:a,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,responseEncoding:u,validateStatus:o};return We.forEach(Object.keys(e).concat(Object.keys(t)),function(w){var b=l[w]||s,q=b(w);We.isUndefined(q)&&b!==o||(i[w]=q)}),i}});var hn=g((KE,Ca)=>{Ca.exports={version:"0.26.1"}});var Ta=g((JE,Ia)=>{"use strict";var Km=hn().version,pn={};["object","boolean","number","function","string","symbol"].forEach(function(r,e){pn[r]=function(i){return typeof i===r||"a"+(e<1?"n ":" ")+r}});var Ea={};pn.transitional=function(e,t,i){function n(s,a){return"[Axios v"+Km+"] Transitional option '"+s+"'"+a+(i?". "+i:"")}return function(s,a,u){if(e===!1)throw new Error(n(a," has been removed"+(t?" in "+t:"")));return t&&!Ea[a]&&(Ea[a]=!0,console.warn(n(a," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(s,a,u):!0}};function Jm(r,e,t){if(typeof r!="object")throw new TypeError("options must be an object");for(var i=Object.keys(r),n=i.length;n-- >0;){var s=i[n],a=e[s];if(a){var u=r[s],o=u===void 0||a(u,s,r);if(o!==!0)throw new TypeError("option "+s+" must be "+o);continue}if(t!==!0)throw Error("Unknown option "+s)}}Ia.exports={assertOptions:Jm,validators:pn}});var Na=g((VE,ja)=>{"use strict";var Ra=Be(),Vm=Qi(),Pa=Js(),Ma=Oa(),ri=ln(),La=Ta(),Gr=La.validators;function bt(r){this.defaults=r,this.interceptors={request:new Pa,response:new Pa}}bt.prototype.request=function(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=ri(this.defaults,t),t.method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var i=t.transitional;i!==void 0&&La.assertOptions(i,{silentJSONParsing:Gr.transitional(Gr.boolean),forcedJSONParsing:Gr.transitional(Gr.boolean),clarifyTimeoutError:Gr.transitional(Gr.boolean)},!1);var n=[],s=!0;this.interceptors.request.forEach(function(q){typeof q.runWhen=="function"&&q.runWhen(t)===!1||(s=s&&q.synchronous,n.unshift(q.fulfilled,q.rejected))});var a=[];this.interceptors.response.forEach(function(q){a.push(q.fulfilled,q.rejected)});var u;if(!s){var o=[Ma,void 0];for(Array.prototype.unshift.apply(o,n),o=o.concat(a),u=Promise.resolve(t);o.length;)u=u.then(o.shift(),o.shift());return u}for(var l=t;n.length;){var p=n.shift(),w=n.shift();try{l=p(l)}catch(b){w(b);break}}try{u=Ma(l)}catch(b){return Promise.reject(b)}for(;a.length;)u=u.then(a.shift(),a.shift());return u};bt.prototype.getUri=function(e){return e=ri(this.defaults,e),Vm(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")};Ra.forEach(["delete","get","head","options"],function(e){bt.prototype[e]=function(t,i){return this.request(ri(i||{},{method:e,url:t,data:(i||{}).data}))}});Ra.forEach(["post","put","patch"],function(e){bt.prototype[e]=function(t,i,n){return this.request(ri(n||{},{method:e,url:t,data:i}))}});ja.exports=bt});var Da=g((YE,Ua)=>{"use strict";var Ym=wt();function Kr(r){if(typeof r!="function")throw new TypeError("executor must be a function.");var e;this.promise=new Promise(function(n){e=n});var t=this;this.promise.then(function(i){if(!!t._listeners){var n,s=t._listeners.length;for(n=0;n<s;n++)t._listeners[n](i);t._listeners=null}}),this.promise.then=function(i){var n,s=new Promise(function(a){t.subscribe(a),n=a}).then(i);return s.cancel=function(){t.unsubscribe(n)},s},r(function(n){t.reason||(t.reason=new Ym(n),e(t.reason))})}Kr.prototype.throwIfRequested=function(){if(this.reason)throw this.reason};Kr.prototype.subscribe=function(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]};Kr.prototype.unsubscribe=function(e){if(!!this._listeners){var t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}};Kr.source=function(){var e,t=new Kr(function(n){e=n});return{token:t,cancel:e}};Ua.exports=Kr});var Ba=g((XE,Fa)=>{"use strict";Fa.exports=function(e){return function(i){return e.apply(null,i)}}});var $a=g((ZE,ka)=>{"use strict";var Xm=Be();ka.exports=function(e){return Xm.isObject(e)&&e.isAxiosError===!0}});var Ha=g((QE,dn)=>{"use strict";var za=Be(),Zm=Ji(),ti=Na(),Qm=ln(),eg=ei();function Wa(r){var e=new ti(r),t=Zm(ti.prototype.request,e);return za.extend(t,ti.prototype,e),za.extend(t,e),t.create=function(n){return Wa(Qm(r,n))},t}var er=Wa(eg);er.Axios=ti;er.Cancel=wt();er.CancelToken=Da();er.isCancel=un();er.VERSION=hn().version;er.all=function(e){return Promise.all(e)};er.spread=Ba();er.isAxiosError=$a();dn.exports=er;dn.exports.default=er});var ii=g((eI,Ga)=>{Ga.exports=Ha()});var ke=g((rI,Ka)=>{var rg=Array.isArray;Ka.exports=rg});var mn=g((tI,Ja)=>{var tg=typeof global=="object"&&global&&global.Object===Object&&global;Ja.exports=tg});var Ve=g((iI,Va)=>{var ig=mn(),ng=typeof self=="object"&&self&&self.Object===Object&&self,sg=ig||ng||Function("return this")();Va.exports=sg});var Mr=g((nI,Ya)=>{var ag=Ve(),og=ag.Symbol;Ya.exports=og});var eo=g((sI,Qa)=>{var Xa=Mr(),Za=Object.prototype,ug=Za.hasOwnProperty,fg=Za.toString,xt=Xa?Xa.toStringTag:void 0;function cg(r){var e=ug.call(r,xt),t=r[xt];try{r[xt]=void 0;var i=!0}catch(s){}var n=fg.call(r);return i&&(e?r[xt]=t:delete r[xt]),n}Qa.exports=cg});var to=g((aI,ro)=>{var lg=Object.prototype,hg=lg.toString;function pg(r){return hg.call(r)}ro.exports=pg});var dr=g((oI,so)=>{var io=Mr(),dg=eo(),mg=to(),gg="[object Null]",vg="[object Undefined]",no=io?io.toStringTag:void 0;function yg(r){return r==null?r===void 0?vg:gg:no&&no in Object(r)?dg(r):mg(r)}so.exports=yg});var Ye=g((uI,ao)=>{function _g(r){return r!=null&&typeof r=="object"}ao.exports=_g});var ni=g((fI,oo)=>{var wg=dr(),bg=Ye(),xg="[object Symbol]";function Sg(r){return typeof r=="symbol"||bg(r)&&wg(r)==xg}oo.exports=Sg});var fo=g((cI,uo)=>{var Ag=ke(),Og=ni(),qg=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Cg=/^\w*$/;function Eg(r,e){if(Ag(r))return!1;var t=typeof r;return t=="number"||t=="symbol"||t=="boolean"||r==null||Og(r)?!0:Cg.test(r)||!qg.test(r)||e!=null&&r in Object(e)}uo.exports=Eg});var Xe=g((lI,co)=>{function Ig(r){var e=typeof r;return r!=null&&(e=="object"||e=="function")}co.exports=Ig});var si=g((hI,lo)=>{var Tg=dr(),Pg=Xe(),Mg="[object AsyncFunction]",Rg="[object Function]",Lg="[object GeneratorFunction]",jg="[object Proxy]";function Ng(r){if(!Pg(r))return!1;var e=Tg(r);return e==Rg||e==Lg||e==Mg||e==jg}lo.exports=Ng});var po=g((pI,ho)=>{var Ug=Ve(),Dg=Ug["__core-js_shared__"];ho.exports=Dg});var vo=g((dI,go)=>{var gn=po(),mo=function(){var r=/[^.]+$/.exec(gn&&gn.keys&&gn.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""}();function Fg(r){return!!mo&&mo in r}go.exports=Fg});var vn=g((mI,yo)=>{var Bg=Function.prototype,kg=Bg.toString;function $g(r){if(r!=null){try{return kg.call(r)}catch(e){}try{return r+""}catch(e){}}return""}yo.exports=$g});var wo=g((gI,_o)=>{var zg=si(),Wg=vo(),Hg=Xe(),Gg=vn(),Kg=/[\\^$.*+?()[\]{}|]/g,Jg=/^\[object .+?Constructor\]$/,Vg=Function.prototype,Yg=Object.prototype,Xg=Vg.toString,Zg=Yg.hasOwnProperty,Qg=RegExp("^"+Xg.call(Zg).replace(Kg,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function ev(r){if(!Hg(r)||Wg(r))return!1;var e=zg(r)?Qg:Jg;return e.test(Gg(r))}_o.exports=ev});var xo=g((vI,bo)=>{function rv(r,e){return r==null?void 0:r[e]}bo.exports=rv});var mr=g((yI,So)=>{var tv=wo(),iv=xo();function nv(r,e){var t=iv(r,e);return tv(t)?t:void 0}So.exports=nv});var St=g((_I,Ao)=>{var sv=mr(),av=sv(Object,"create");Ao.exports=av});var Co=g((wI,qo)=>{var Oo=St();function ov(){this.__data__=Oo?Oo(null):{},this.size=0}qo.exports=ov});var Io=g((bI,Eo)=>{function uv(r){var e=this.has(r)&&delete this.__data__[r];return this.size-=e?1:0,e}Eo.exports=uv});var Po=g((xI,To)=>{var fv=St(),cv="__lodash_hash_undefined__",lv=Object.prototype,hv=lv.hasOwnProperty;function pv(r){var e=this.__data__;if(fv){var t=e[r];return t===cv?void 0:t}return hv.call(e,r)?e[r]:void 0}To.exports=pv});var Ro=g((SI,Mo)=>{var dv=St(),mv=Object.prototype,gv=mv.hasOwnProperty;function vv(r){var e=this.__data__;return dv?e[r]!==void 0:gv.call(e,r)}Mo.exports=vv});var jo=g((AI,Lo)=>{var yv=St(),_v="__lodash_hash_undefined__";function wv(r,e){var t=this.__data__;return this.size+=this.has(r)?0:1,t[r]=yv&&e===void 0?_v:e,this}Lo.exports=wv});var Uo=g((OI,No)=>{var bv=Co(),xv=Io(),Sv=Po(),Av=Ro(),Ov=jo();function Jr(r){var e=-1,t=r==null?0:r.length;for(this.clear();++e<t;){var i=r[e];this.set(i[0],i[1])}}Jr.prototype.clear=bv;Jr.prototype.delete=xv;Jr.prototype.get=Sv;Jr.prototype.has=Av;Jr.prototype.set=Ov;No.exports=Jr});var Fo=g((qI,Do)=>{function qv(){this.__data__=[],this.size=0}Do.exports=qv});var Vr=g((CI,Bo)=>{function Cv(r,e){return r===e||r!==r&&e!==e}Bo.exports=Cv});var At=g((EI,ko)=>{var Ev=Vr();function Iv(r,e){for(var t=r.length;t--;)if(Ev(r[t][0],e))return t;return-1}ko.exports=Iv});var zo=g((II,$o)=>{var Tv=At(),Pv=Array.prototype,Mv=Pv.splice;function Rv(r){var e=this.__data__,t=Tv(e,r);if(t<0)return!1;var i=e.length-1;return t==i?e.pop():Mv.call(e,t,1),--this.size,!0}$o.exports=Rv});var Ho=g((TI,Wo)=>{var Lv=At();function jv(r){var e=this.__data__,t=Lv(e,r);return t<0?void 0:e[t][1]}Wo.exports=jv});var Ko=g((PI,Go)=>{var Nv=At();function Uv(r){return Nv(this.__data__,r)>-1}Go.exports=Uv});var Vo=g((MI,Jo)=>{var Dv=At();function Fv(r,e){var t=this.__data__,i=Dv(t,r);return i<0?(++this.size,t.push([r,e])):t[i][1]=e,this}Jo.exports=Fv});var Ot=g((RI,Yo)=>{var Bv=Fo(),kv=zo(),$v=Ho(),zv=Ko(),Wv=Vo();function Yr(r){var e=-1,t=r==null?0:r.length;for(this.clear();++e<t;){var i=r[e];this.set(i[0],i[1])}}Yr.prototype.clear=Bv;Yr.prototype.delete=kv;Yr.prototype.get=$v;Yr.prototype.has=zv;Yr.prototype.set=Wv;Yo.exports=Yr});var ai=g((LI,Xo)=>{var Hv=mr(),Gv=Ve(),Kv=Hv(Gv,"Map");Xo.exports=Kv});var eu=g((jI,Qo)=>{var Zo=Uo(),Jv=Ot(),Vv=ai();function Yv(){this.size=0,this.__data__={hash:new Zo,map:new(Vv||Jv),string:new Zo}}Qo.exports=Yv});var tu=g((NI,ru)=>{function Xv(r){var e=typeof r;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?r!=="__proto__":r===null}ru.exports=Xv});var qt=g((UI,iu)=>{var Zv=tu();function Qv(r,e){var t=r.__data__;return Zv(e)?t[typeof e=="string"?"string":"hash"]:t.map}iu.exports=Qv});var su=g((DI,nu)=>{var ey=qt();function ry(r){var e=ey(this,r).delete(r);return this.size-=e?1:0,e}nu.exports=ry});var ou=g((FI,au)=>{var ty=qt();function iy(r){return ty(this,r).get(r)}au.exports=iy});var fu=g((BI,uu)=>{var ny=qt();function sy(r){return ny(this,r).has(r)}uu.exports=sy});var lu=g((kI,cu)=>{var ay=qt();function oy(r,e){var t=ay(this,r),i=t.size;return t.set(r,e),this.size+=t.size==i?0:1,this}cu.exports=oy});var oi=g(($I,hu)=>{var uy=eu(),fy=su(),cy=ou(),ly=fu(),hy=lu();function Xr(r){var e=-1,t=r==null?0:r.length;for(this.clear();++e<t;){var i=r[e];this.set(i[0],i[1])}}Xr.prototype.clear=uy;Xr.prototype.delete=fy;Xr.prototype.get=cy;Xr.prototype.has=ly;Xr.prototype.set=hy;hu.exports=Xr});var mu=g((zI,du)=>{var pu=oi(),py="Expected a function";function yn(r,e){if(typeof r!="function"||e!=null&&typeof e!="function")throw new TypeError(py);var t=function(){var i=arguments,n=e?e.apply(this,i):i[0],s=t.cache;if(s.has(n))return s.get(n);var a=r.apply(this,i);return t.cache=s.set(n,a)||s,a};return t.cache=new(yn.Cache||pu),t}yn.Cache=pu;du.exports=yn});var vu=g((WI,gu)=>{var dy=mu(),my=500;function gy(r){var e=dy(r,function(i){return t.size===my&&t.clear(),i}),t=e.cache;return e}gu.exports=gy});var _u=g((HI,yu)=>{var vy=vu(),yy=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,_y=/\\(\\)?/g,wy=vy(function(r){var e=[];return r.charCodeAt(0)===46&&e.push(""),r.replace(yy,function(t,i,n,s){e.push(n?s.replace(_y,"$1"):i||t)}),e});yu.exports=wy});var Ct=g((GI,wu)=>{function by(r,e){for(var t=-1,i=r==null?0:r.length,n=Array(i);++t<i;)n[t]=e(r[t],t,r);return n}wu.exports=by});var qu=g((KI,Ou)=>{var bu=Mr(),xy=Ct(),Sy=ke(),Ay=ni(),Oy=1/0,xu=bu?bu.prototype:void 0,Su=xu?xu.toString:void 0;function Au(r){if(typeof r=="string")return r;if(Sy(r))return xy(r,Au)+"";if(Ay(r))return Su?Su.call(r):"";var e=r+"";return e=="0"&&1/r==-Oy?"-0":e}Ou.exports=Au});var Eu=g((JI,Cu)=>{var qy=qu();function Cy(r){return r==null?"":qy(r)}Cu.exports=Cy});var Et=g((VI,Iu)=>{var Ey=ke(),Iy=fo(),Ty=_u(),Py=Eu();function My(r,e){return Ey(r)?r:Iy(r,e)?[r]:Ty(Py(r))}Iu.exports=My});var ui=g((YI,Tu)=>{var Ry=ni(),Ly=1/0;function jy(r){if(typeof r=="string"||Ry(r))return r;var e=r+"";return e=="0"&&1/r==-Ly?"-0":e}Tu.exports=jy});var _n=g((XI,Pu)=>{var Ny=Et(),Uy=ui();function Dy(r,e){e=Ny(e,r);for(var t=0,i=e.length;r!=null&&t<i;)r=r[Uy(e[t++])];return t&&t==i?r:void 0}Pu.exports=Dy});var Ru=g((ZI,Mu)=>{var Fy=_n();function By(r,e,t){var i=r==null?void 0:Fy(r,e);return i===void 0?t:i}Mu.exports=By});var wn=g((QI,Lu)=>{var ky=mr(),$y=function(){try{var r=ky(Object,"defineProperty");return r({},"",{}),r}catch(e){}}();Lu.exports=$y});var fi=g((eT,Nu)=>{var ju=wn();function zy(r,e,t){e=="__proto__"&&ju?ju(r,e,{configurable:!0,enumerable:!0,value:t,writable:!0}):r[e]=t}Nu.exports=zy});var ci=g((rT,Uu)=>{var Wy=fi(),Hy=Vr(),Gy=Object.prototype,Ky=Gy.hasOwnProperty;function Jy(r,e,t){var i=r[e];(!(Ky.call(r,e)&&Hy(i,t))||t===void 0&&!(e in r))&&Wy(r,e,t)}Uu.exports=Jy});var li=g((tT,Du)=>{var Vy=9007199254740991,Yy=/^(?:0|[1-9]\d*)$/;function Xy(r,e){var t=typeof r;return e=e==null?Vy:e,!!e&&(t=="number"||t!="symbol"&&Yy.test(r))&&r>-1&&r%1==0&&r<e}Du.exports=Xy});var ku=g((iT,Bu)=>{var Zy=ci(),Qy=Et(),e_=li(),Fu=Xe(),r_=ui();function t_(r,e,t,i){if(!Fu(r))return r;e=Qy(e,r);for(var n=-1,s=e.length,a=s-1,u=r;u!=null&&++n<s;){var o=r_(e[n]),l=t;if(o==="__proto__"||o==="constructor"||o==="prototype")return r;if(n!=a){var p=u[o];l=i?i(p,o,u):void 0,l===void 0&&(l=Fu(p)?p:e_(e[n+1])?[]:{})}Zy(u,o,l),u=u[o]}return r}Bu.exports=t_});var zu=g((nT,$u)=>{var i_=ku();function n_(r,e,t){return r==null?r:i_(r,e,t)}$u.exports=n_});var Hu=g((sT,Wu)=>{var s_="__lodash_hash_undefined__";function a_(r){return this.__data__.set(r,s_),this}Wu.exports=a_});var Ku=g((aT,Gu)=>{function o_(r){return this.__data__.has(r)}Gu.exports=o_});var pi=g((oT,Ju)=>{var u_=oi(),f_=Hu(),c_=Ku();function hi(r){var e=-1,t=r==null?0:r.length;for(this.__data__=new u_;++e<t;)this.add(r[e])}hi.prototype.add=hi.prototype.push=f_;hi.prototype.has=c_;Ju.exports=hi});var Yu=g((uT,Vu)=>{function l_(r,e,t,i){for(var n=r.length,s=t+(i?1:-1);i?s--:++s<n;)if(e(r[s],s,r))return s;return-1}Vu.exports=l_});var Zu=g((fT,Xu)=>{function h_(r){return r!==r}Xu.exports=h_});var ef=g((cT,Qu)=>{function p_(r,e,t){for(var i=t-1,n=r.length;++i<n;)if(r[i]===e)return i;return-1}Qu.exports=p_});var tf=g((lT,rf)=>{var d_=Yu(),m_=Zu(),g_=ef();function v_(r,e,t){return e===e?g_(r,e,t):d_(r,m_,t)}rf.exports=v_});var bn=g((hT,nf)=>{var y_=tf();function __(r,e){var t=r==null?0:r.length;return!!t&&y_(r,e,0)>-1}nf.exports=__});var xn=g((pT,sf)=>{function w_(r,e,t){for(var i=-1,n=r==null?0:r.length;++i<n;)if(t(e,r[i]))return!0;return!1}sf.exports=w_});var di=g((dT,af)=>{function b_(r,e){return r.has(e)}af.exports=b_});var Sn=g((mT,of)=>{var x_=mr(),S_=Ve(),A_=x_(S_,"Set");of.exports=A_});var ff=g((gT,uf)=>{function O_(){}uf.exports=O_});var mi=g((vT,cf)=>{function q_(r){var e=-1,t=Array(r.size);return r.forEach(function(i){t[++e]=i}),t}cf.exports=q_});var hf=g((yT,lf)=>{var An=Sn(),C_=ff(),E_=mi(),I_=1/0,T_=An&&1/E_(new An([,-0]))[1]==I_?function(r){return new An(r)}:C_;lf.exports=T_});var On=g((_T,pf)=>{var P_=pi(),M_=bn(),R_=xn(),L_=di(),j_=hf(),N_=mi(),U_=200;function D_(r,e,t){var i=-1,n=M_,s=r.length,a=!0,u=[],o=u;if(t)a=!1,n=R_;else if(s>=U_){var l=e?null:j_(r);if(l)return N_(l);a=!1,n=L_,o=new P_}else o=e?[]:u;e:for(;++i<s;){var p=r[i],w=e?e(p):p;if(p=t||p!==0?p:0,a&&w===w){for(var b=o.length;b--;)if(o[b]===w)continue e;e&&o.push(w),u.push(p)}else n(o,w,t)||(o!==u&&o.push(w),u.push(p))}return u}pf.exports=D_});var mf=g((wT,df)=>{var F_=On();function B_(r){return r&&r.length?F_(r):[]}df.exports=B_});var It=g((bT,gf)=>{function k_(r){return function(e){return r(e)}}gf.exports=k_});var _f=g((xT,yf)=>{var $_=pi(),z_=bn(),W_=xn(),H_=Ct(),G_=It(),vf=di(),K_=Math.min;function J_(r,e,t){for(var i=t?W_:z_,n=r[0].length,s=r.length,a=s,u=Array(s),o=1/0,l=[];a--;){var p=r[a];a&&e&&(p=H_(p,G_(e))),o=K_(p.length,o),u[a]=!t&&(e||n>=120&&p.length>=120)?new $_(a&&p):void 0}p=r[0];var w=-1,b=u[0];e:for(;++w<n&&l.length<o;){var q=p[w],y=e?e(q):q;if(q=t||q!==0?q:0,!(b?vf(b,y):i(l,y,t))){for(a=s;--a;){var P=u[a];if(!(P?vf(P,y):i(r[a],y,t)))continue e}b&&b.push(y),l.push(q)}}return l}yf.exports=J_});var gi=g((ST,wf)=>{function V_(r){return r}wf.exports=V_});var xf=g((AT,bf)=>{function Y_(r,e,t){switch(t.length){case 0:return r.call(e);case 1:return r.call(e,t[0]);case 2:return r.call(e,t[0],t[1]);case 3:return r.call(e,t[0],t[1],t[2])}return r.apply(e,t)}bf.exports=Y_});var qn=g((OT,Af)=>{var X_=xf(),Sf=Math.max;function Z_(r,e,t){return e=Sf(e===void 0?r.length-1:e,0),function(){for(var i=arguments,n=-1,s=Sf(i.length-e,0),a=Array(s);++n<s;)a[n]=i[e+n];n=-1;for(var u=Array(e+1);++n<e;)u[n]=i[n];return u[e]=t(a),X_(r,this,u)}}Af.exports=Z_});var qf=g((qT,Of)=>{function Q_(r){return function(){return r}}Of.exports=Q_});var If=g((CT,Ef)=>{var ew=qf(),Cf=wn(),rw=gi(),tw=Cf?function(r,e){return Cf(r,"toString",{configurable:!0,enumerable:!1,value:ew(e),writable:!0})}:rw;Ef.exports=tw});var Pf=g((ET,Tf)=>{var iw=800,nw=16,sw=Date.now;function aw(r){var e=0,t=0;return function(){var i=sw(),n=nw-(i-t);if(t=i,n>0){if(++e>=iw)return arguments[0]}else e=0;return r.apply(void 0,arguments)}}Tf.exports=aw});var Cn=g((IT,Mf)=>{var ow=If(),uw=Pf(),fw=uw(ow);Mf.exports=fw});var vi=g((TT,Rf)=>{var cw=gi(),lw=qn(),hw=Cn();function pw(r,e){return hw(lw(r,e,cw),r+"")}Rf.exports=pw});var En=g((PT,Lf)=>{var dw=9007199254740991;function mw(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=dw}Lf.exports=mw});var Zr=g((MT,jf)=>{var gw=si(),vw=En();function yw(r){return r!=null&&vw(r.length)&&!gw(r)}jf.exports=yw});var yi=g((RT,Nf)=>{var _w=Zr(),ww=Ye();function bw(r){return ww(r)&&_w(r)}Nf.exports=bw});var Df=g((LT,Uf)=>{var xw=yi();function Sw(r){return xw(r)?r:[]}Uf.exports=Sw});var Bf=g((jT,Ff)=>{var Aw=Ct(),Ow=_f(),qw=vi(),Cw=Df(),Ew=qw(function(r){var e=Aw(r,Cw);return e.length&&e[0]===r[0]?Ow(e):[]});Ff.exports=Ew});var Tt=g((NT,kf)=>{function Iw(r,e){for(var t=-1,i=e.length,n=r.length;++t<i;)r[n+t]=e[t];return r}kf.exports=Iw});var zf=g((UT,$f)=>{var Tw=dr(),Pw=Ye(),Mw="[object Arguments]";function Rw(r){return Pw(r)&&Tw(r)==Mw}$f.exports=Rw});var Pt=g((DT,Gf)=>{var Wf=zf(),Lw=Ye(),Hf=Object.prototype,jw=Hf.hasOwnProperty,Nw=Hf.propertyIsEnumerable,Uw=Wf(function(){return arguments}())?Wf:function(r){return Lw(r)&&jw.call(r,"callee")&&!Nw.call(r,"callee")};Gf.exports=Uw});var Yf=g((FT,Vf)=>{var Kf=Mr(),Dw=Pt(),Fw=ke(),Jf=Kf?Kf.isConcatSpreadable:void 0;function Bw(r){return Fw(r)||Dw(r)||!!(Jf&&r&&r[Jf])}Vf.exports=Bw});var _i=g((BT,Zf)=>{var kw=Tt(),$w=Yf();function Xf(r,e,t,i,n){var s=-1,a=r.length;for(t||(t=$w),n||(n=[]);++s<a;){var u=r[s];e>0&&t(u)?e>1?Xf(u,e-1,t,i,n):kw(n,u):i||(n[n.length]=u)}return n}Zf.exports=Xf});var ec=g((kT,Qf)=>{var zw=_i(),Ww=vi(),Hw=On(),Gw=yi(),Kw=Ww(function(r){return Hw(zw(r,1,Gw,!0))});Qf.exports=Kw});var tc=g(($T,rc)=>{function Jw(r){return function(e,t,i){for(var n=-1,s=Object(e),a=i(e),u=a.length;u--;){var o=a[r?u:++n];if(t(s[o],o,s)===!1)break}return e}}rc.exports=Jw});var In=g((zT,ic)=>{var Vw=tc(),Yw=Vw();ic.exports=Yw});var sc=g((WT,nc)=>{function Xw(r,e){for(var t=-1,i=Array(r);++t<r;)i[t]=e(t);return i}nc.exports=Xw});var oc=g((HT,ac)=>{function Zw(){return!1}ac.exports=Zw});var et=g((Mt,Qr)=>{var Qw=Ve(),eb=oc(),cc=typeof Mt=="object"&&Mt&&!Mt.nodeType&&Mt,uc=cc&&typeof Qr=="object"&&Qr&&!Qr.nodeType&&Qr,rb=uc&&uc.exports===cc,fc=rb?Qw.Buffer:void 0,tb=fc?fc.isBuffer:void 0,ib=tb||eb;Qr.exports=ib});var hc=g((GT,lc)=>{var nb=dr(),sb=En(),ab=Ye(),ob="[object Arguments]",ub="[object Array]",fb="[object Boolean]",cb="[object Date]",lb="[object Error]",hb="[object Function]",pb="[object Map]",db="[object Number]",mb="[object Object]",gb="[object RegExp]",vb="[object Set]",yb="[object String]",_b="[object WeakMap]",wb="[object ArrayBuffer]",bb="[object DataView]",xb="[object Float32Array]",Sb="[object Float64Array]",Ab="[object Int8Array]",Ob="[object Int16Array]",qb="[object Int32Array]",Cb="[object Uint8Array]",Eb="[object Uint8ClampedArray]",Ib="[object Uint16Array]",Tb="[object Uint32Array]",we={};we[xb]=we[Sb]=we[Ab]=we[Ob]=we[qb]=we[Cb]=we[Eb]=we[Ib]=we[Tb]=!0;we[ob]=we[ub]=we[wb]=we[fb]=we[bb]=we[cb]=we[lb]=we[hb]=we[pb]=we[db]=we[mb]=we[gb]=we[vb]=we[yb]=we[_b]=!1;function Pb(r){return ab(r)&&sb(r.length)&&!!we[nb(r)]}lc.exports=Pb});var wi=g((Rt,rt)=>{var Mb=mn(),pc=typeof Rt=="object"&&Rt&&!Rt.nodeType&&Rt,Lt=pc&&typeof rt=="object"&&rt&&!rt.nodeType&&rt,Rb=Lt&&Lt.exports===pc,Tn=Rb&&Mb.process,Lb=function(){try{var r=Lt&&Lt.require&&Lt.require("util").types;return r||Tn&&Tn.binding&&Tn.binding("util")}catch(e){}}();rt.exports=Lb});var jt=g((KT,gc)=>{var jb=hc(),Nb=It(),dc=wi(),mc=dc&&dc.isTypedArray,Ub=mc?Nb(mc):jb;gc.exports=Ub});var Pn=g((JT,vc)=>{var Db=sc(),Fb=Pt(),Bb=ke(),kb=et(),$b=li(),zb=jt(),Wb=Object.prototype,Hb=Wb.hasOwnProperty;function Gb(r,e){var t=Bb(r),i=!t&&Fb(r),n=!t&&!i&&kb(r),s=!t&&!i&&!n&&zb(r),a=t||i||n||s,u=a?Db(r.length,String):[],o=u.length;for(var l in r)(e||Hb.call(r,l))&&!(a&&(l=="length"||n&&(l=="offset"||l=="parent")||s&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||$b(l,o)))&&u.push(l);return u}vc.exports=Gb});var Nt=g((VT,yc)=>{var Kb=Object.prototype;function Jb(r){var e=r&&r.constructor,t=typeof e=="function"&&e.prototype||Kb;return r===t}yc.exports=Jb});var Mn=g((YT,_c)=>{function Vb(r,e){return function(t){return r(e(t))}}_c.exports=Vb});var bc=g((XT,wc)=>{var Yb=Mn(),Xb=Yb(Object.keys,Object);wc.exports=Xb});var Rn=g((ZT,xc)=>{var Zb=Nt(),Qb=bc(),e0=Object.prototype,r0=e0.hasOwnProperty;function t0(r){if(!Zb(r))return Qb(r);var e=[];for(var t in Object(r))r0.call(r,t)&&t!="constructor"&&e.push(t);return e}xc.exports=t0});var Ut=g((QT,Sc)=>{var i0=Pn(),n0=Rn(),s0=Zr();function a0(r){return s0(r)?i0(r):n0(r)}Sc.exports=a0});var Oc=g((e1,Ac)=>{var o0=In(),u0=Ut();function f0(r,e){return r&&o0(r,e,u0)}Ac.exports=f0});var Cc=g((r1,qc)=>{var c0=gi();function l0(r){return typeof r=="function"?r:c0}qc.exports=l0});var Ic=g((t1,Ec)=>{var h0=Oc(),p0=Cc();function d0(r,e){return r&&h0(r,p0(e))}Ec.exports=d0});var Pc=g((i1,Tc)=>{var m0=dr(),g0=ke(),v0=Ye(),y0="[object String]";function _0(r){return typeof r=="string"||!g0(r)&&v0(r)&&m0(r)==y0}Tc.exports=_0});var Rc=g((n1,Mc)=>{var w0=mr(),b0=Ve(),x0=w0(b0,"DataView");Mc.exports=x0});var jc=g((s1,Lc)=>{var S0=mr(),A0=Ve(),O0=S0(A0,"Promise");Lc.exports=O0});var Uc=g((a1,Nc)=>{var q0=mr(),C0=Ve(),E0=q0(C0,"WeakMap");Nc.exports=E0});var it=g((o1,Wc)=>{var Ln=Rc(),jn=ai(),Nn=jc(),Un=Sn(),Dn=Uc(),zc=dr(),tt=vn(),Dc="[object Map]",I0="[object Object]",Fc="[object Promise]",Bc="[object Set]",kc="[object WeakMap]",$c="[object DataView]",T0=tt(Ln),P0=tt(jn),M0=tt(Nn),R0=tt(Un),L0=tt(Dn),Rr=zc;(Ln&&Rr(new Ln(new ArrayBuffer(1)))!=$c||jn&&Rr(new jn)!=Dc||Nn&&Rr(Nn.resolve())!=Fc||Un&&Rr(new Un)!=Bc||Dn&&Rr(new Dn)!=kc)&&(Rr=function(r){var e=zc(r),t=e==I0?r.constructor:void 0,i=t?tt(t):"";if(i)switch(i){case T0:return $c;case P0:return Dc;case M0:return Fc;case R0:return Bc;case L0:return kc}return e});Wc.exports=Rr});var Gc=g((u1,Hc)=>{var j0=Rn(),N0=it(),U0=Pt(),D0=ke(),F0=Zr(),B0=et(),k0=Nt(),$0=jt(),z0="[object Map]",W0="[object Set]",H0=Object.prototype,G0=H0.hasOwnProperty;function K0(r){if(r==null)return!0;if(F0(r)&&(D0(r)||typeof r=="string"||typeof r.splice=="function"||B0(r)||$0(r)||U0(r)))return!r.length;var e=N0(r);if(e==z0||e==W0)return!r.size;if(k0(r))return!j0(r).length;for(var t in r)if(G0.call(r,t))return!1;return!0}Hc.exports=K0});var Jc=g((f1,Kc)=>{var J0=Ot();function V0(){this.__data__=new J0,this.size=0}Kc.exports=V0});var Yc=g((c1,Vc)=>{function Y0(r){var e=this.__data__,t=e.delete(r);return this.size=e.size,t}Vc.exports=Y0});var Zc=g((l1,Xc)=>{function X0(r){return this.__data__.get(r)}Xc.exports=X0});var el=g((h1,Qc)=>{function Z0(r){return this.__data__.has(r)}Qc.exports=Z0});var tl=g((p1,rl)=>{var Q0=Ot(),ex=ai(),rx=oi(),tx=200;function ix(r,e){var t=this.__data__;if(t instanceof Q0){var i=t.__data__;if(!ex||i.length<tx-1)return i.push([r,e]),this.size=++t.size,this;t=this.__data__=new rx(i)}return t.set(r,e),this.size=t.size,this}rl.exports=ix});var bi=g((d1,il)=>{var nx=Ot(),sx=Jc(),ax=Yc(),ox=Zc(),ux=el(),fx=tl();function nt(r){var e=this.__data__=new nx(r);this.size=e.size}nt.prototype.clear=sx;nt.prototype.delete=ax;nt.prototype.get=ox;nt.prototype.has=ux;nt.prototype.set=fx;il.exports=nt});var sl=g((m1,nl)=>{function cx(r,e){for(var t=-1,i=r==null?0:r.length;++t<i;)if(e(r[t],t,r))return!0;return!1}nl.exports=cx});var Fn=g((g1,al)=>{var lx=pi(),hx=sl(),px=di(),dx=1,mx=2;function gx(r,e,t,i,n,s){var a=t&dx,u=r.length,o=e.length;if(u!=o&&!(a&&o>u))return!1;var l=s.get(r),p=s.get(e);if(l&&p)return l==e&&p==r;var w=-1,b=!0,q=t&mx?new lx:void 0;for(s.set(r,e),s.set(e,r);++w<u;){var y=r[w],P=e[w];if(i)var H=a?i(P,y,w,e,r,s):i(y,P,w,r,e,s);if(H!==void 0){if(H)continue;b=!1;break}if(q){if(!hx(e,function(K,Q){if(!px(q,Q)&&(y===K||n(y,K,t,i,s)))return q.push(Q)})){b=!1;break}}else if(!(y===P||n(y,P,t,i,s))){b=!1;break}}return s.delete(r),s.delete(e),b}al.exports=gx});var Bn=g((v1,ol)=>{var vx=Ve(),yx=vx.Uint8Array;ol.exports=yx});var fl=g((y1,ul)=>{function _x(r){var e=-1,t=Array(r.size);return r.forEach(function(i,n){t[++e]=[n,i]}),t}ul.exports=_x});var dl=g((_1,pl)=>{var cl=Mr(),ll=Bn(),wx=Vr(),bx=Fn(),xx=fl(),Sx=mi(),Ax=1,Ox=2,qx="[object Boolean]",Cx="[object Date]",Ex="[object Error]",Ix="[object Map]",Tx="[object Number]",Px="[object RegExp]",Mx="[object Set]",Rx="[object String]",Lx="[object Symbol]",jx="[object ArrayBuffer]",Nx="[object DataView]",hl=cl?cl.prototype:void 0,kn=hl?hl.valueOf:void 0;function Ux(r,e,t,i,n,s,a){switch(t){case Nx:if(r.byteLength!=e.byteLength||r.byteOffset!=e.byteOffset)return!1;r=r.buffer,e=e.buffer;case jx:return!(r.byteLength!=e.byteLength||!s(new ll(r),new ll(e)));case qx:case Cx:case Tx:return wx(+r,+e);case Ex:return r.name==e.name&&r.message==e.message;case Px:case Rx:return r==e+"";case Ix:var u=xx;case Mx:var o=i&Ax;if(u||(u=Sx),r.size!=e.size&&!o)return!1;var l=a.get(r);if(l)return l==e;i|=Ox,a.set(r,e);var p=bx(u(r),u(e),i,n,s,a);return a.delete(r),p;case Lx:if(kn)return kn.call(r)==kn.call(e)}return!1}pl.exports=Ux});var $n=g((w1,ml)=>{var Dx=Tt(),Fx=ke();function Bx(r,e,t){var i=e(r);return Fx(r)?i:Dx(i,t(r))}ml.exports=Bx});var vl=g((b1,gl)=>{function kx(r,e){for(var t=-1,i=r==null?0:r.length,n=0,s=[];++t<i;){var a=r[t];e(a,t,r)&&(s[n++]=a)}return s}gl.exports=kx});var zn=g((x1,yl)=>{function $x(){return[]}yl.exports=$x});var xi=g((S1,wl)=>{var zx=vl(),Wx=zn(),Hx=Object.prototype,Gx=Hx.propertyIsEnumerable,_l=Object.getOwnPropertySymbols,Kx=_l?function(r){return r==null?[]:(r=Object(r),zx(_l(r),function(e){return Gx.call(r,e)}))}:Wx;wl.exports=Kx});var Wn=g((A1,bl)=>{var Jx=$n(),Vx=xi(),Yx=Ut();function Xx(r){return Jx(r,Yx,Vx)}bl.exports=Xx});var Al=g((O1,Sl)=>{var xl=Wn(),Zx=1,Qx=Object.prototype,eS=Qx.hasOwnProperty;function rS(r,e,t,i,n,s){var a=t&Zx,u=xl(r),o=u.length,l=xl(e),p=l.length;if(o!=p&&!a)return!1;for(var w=o;w--;){var b=u[w];if(!(a?b in e:eS.call(e,b)))return!1}var q=s.get(r),y=s.get(e);if(q&&y)return q==e&&y==r;var P=!0;s.set(r,e),s.set(e,r);for(var H=a;++w<o;){b=u[w];var K=r[b],Q=e[b];if(i)var F=a?i(Q,K,b,e,r,s):i(K,Q,b,r,e,s);if(!(F===void 0?K===Q||n(K,Q,t,i,s):F)){P=!1;break}H||(H=b=="constructor")}if(P&&!H){var Z=r.constructor,te=e.constructor;Z!=te&&"constructor"in r&&"constructor"in e&&!(typeof Z=="function"&&Z instanceof Z&&typeof te=="function"&&te instanceof te)&&(P=!1)}return s.delete(r),s.delete(e),P}Sl.exports=rS});var Ml=g((q1,Pl)=>{var Hn=bi(),tS=Fn(),iS=dl(),nS=Al(),Ol=it(),ql=ke(),Cl=et(),sS=jt(),aS=1,El="[object Arguments]",Il="[object Array]",Si="[object Object]",oS=Object.prototype,Tl=oS.hasOwnProperty;function uS(r,e,t,i,n,s){var a=ql(r),u=ql(e),o=a?Il:Ol(r),l=u?Il:Ol(e);o=o==El?Si:o,l=l==El?Si:l;var p=o==Si,w=l==Si,b=o==l;if(b&&Cl(r)){if(!Cl(e))return!1;a=!0,p=!1}if(b&&!p)return s||(s=new Hn),a||sS(r)?tS(r,e,t,i,n,s):iS(r,e,o,t,i,n,s);if(!(t&aS)){var q=p&&Tl.call(r,"__wrapped__"),y=w&&Tl.call(e,"__wrapped__");if(q||y){var P=q?r.value():r,H=y?e.value():e;return s||(s=new Hn),n(P,H,t,i,s)}}return b?(s||(s=new Hn),nS(r,e,t,i,n,s)):!1}Pl.exports=uS});var Nl=g((C1,jl)=>{var fS=Ml(),Rl=Ye();function Ll(r,e,t,i,n){return r===e?!0:r==null||e==null||!Rl(r)&&!Rl(e)?r!==r&&e!==e:fS(r,e,t,i,Ll,n)}jl.exports=Ll});var Dl=g((E1,Ul)=>{var cS=Nl();function lS(r,e){return cS(r,e)}Ul.exports=lS});var Gn=g((I1,Fl)=>{var hS=fi(),pS=Vr();function dS(r,e,t){(t!==void 0&&!pS(r[e],t)||t===void 0&&!(e in r))&&hS(r,e,t)}Fl.exports=dS});var Kn=g((Dt,st)=>{var mS=Ve(),zl=typeof Dt=="object"&&Dt&&!Dt.nodeType&&Dt,Bl=zl&&typeof st=="object"&&st&&!st.nodeType&&st,gS=Bl&&Bl.exports===zl,kl=gS?mS.Buffer:void 0,$l=kl?kl.allocUnsafe:void 0;function vS(r,e){if(e)return r.slice();var t=r.length,i=$l?$l(t):new r.constructor(t);return r.copy(i),i}st.exports=vS});var Ai=g((T1,Hl)=>{var Wl=Bn();function yS(r){var e=new r.constructor(r.byteLength);return new Wl(e).set(new Wl(r)),e}Hl.exports=yS});var Jn=g((P1,Gl)=>{var _S=Ai();function wS(r,e){var t=e?_S(r.buffer):r.buffer;return new r.constructor(t,r.byteOffset,r.length)}Gl.exports=wS});var Oi=g((M1,Kl)=>{function bS(r,e){var t=-1,i=r.length;for(e||(e=Array(i));++t<i;)e[t]=r[t];return e}Kl.exports=bS});var Yl=g((R1,Vl)=>{var xS=Xe(),Jl=Object.create,SS=function(){function r(){}return function(e){if(!xS(e))return{};if(Jl)return Jl(e);r.prototype=e;var t=new r;return r.prototype=void 0,t}}();Vl.exports=SS});var qi=g((L1,Xl)=>{var AS=Mn(),OS=AS(Object.getPrototypeOf,Object);Xl.exports=OS});var Vn=g((j1,Zl)=>{var qS=Yl(),CS=qi(),ES=Nt();function IS(r){return typeof r.constructor=="function"&&!ES(r)?qS(CS(r)):{}}Zl.exports=IS});var Yn=g((N1,eh)=>{var TS=dr(),PS=qi(),MS=Ye(),RS="[object Object]",LS=Function.prototype,jS=Object.prototype,Ql=LS.toString,NS=jS.hasOwnProperty,US=Ql.call(Object);function DS(r){if(!MS(r)||TS(r)!=RS)return!1;var e=PS(r);if(e===null)return!0;var t=NS.call(e,"constructor")&&e.constructor;return typeof t=="function"&&t instanceof t&&Ql.call(t)==US}eh.exports=DS});var Xn=g((U1,rh)=>{function FS(r,e){if(!(e==="constructor"&&typeof r[e]=="function")&&e!="__proto__")return r[e]}rh.exports=FS});var Lr=g((D1,th)=>{var BS=ci(),kS=fi();function $S(r,e,t,i){var n=!t;t||(t={});for(var s=-1,a=e.length;++s<a;){var u=e[s],o=i?i(t[u],r[u],u,t,r):void 0;o===void 0&&(o=r[u]),n?kS(t,u,o):BS(t,u,o)}return t}th.exports=$S});var nh=g((F1,ih)=>{function zS(r){var e=[];if(r!=null)for(var t in Object(r))e.push(t);return e}ih.exports=zS});var ah=g((B1,sh)=>{var WS=Xe(),HS=Nt(),GS=nh(),KS=Object.prototype,JS=KS.hasOwnProperty;function VS(r){if(!WS(r))return GS(r);var e=HS(r),t=[];for(var i in r)i=="constructor"&&(e||!JS.call(r,i))||t.push(i);return t}sh.exports=VS});var at=g((k1,oh)=>{var YS=Pn(),XS=ah(),ZS=Zr();function QS(r){return ZS(r)?YS(r,!0):XS(r)}oh.exports=QS});var fh=g(($1,uh)=>{var eA=Lr(),rA=at();function tA(r){return eA(r,rA(r))}uh.exports=tA});var mh=g((z1,dh)=>{var ch=Gn(),iA=Kn(),nA=Jn(),sA=Oi(),aA=Vn(),lh=Pt(),hh=ke(),oA=yi(),uA=et(),fA=si(),cA=Xe(),lA=Yn(),hA=jt(),ph=Xn(),pA=fh();function dA(r,e,t,i,n,s,a){var u=ph(r,t),o=ph(e,t),l=a.get(o);if(l){ch(r,t,l);return}var p=s?s(u,o,t+"",r,e,a):void 0,w=p===void 0;if(w){var b=hh(o),q=!b&&uA(o),y=!b&&!q&&hA(o);p=o,b||q||y?hh(u)?p=u:oA(u)?p=sA(u):q?(w=!1,p=iA(o,!0)):y?(w=!1,p=nA(o,!0)):p=[]:lA(o)||lh(o)?(p=u,lh(u)?p=pA(u):(!cA(u)||fA(u))&&(p=aA(o))):w=!1}w&&(a.set(o,p),n(p,o,i,s,a),a.delete(o)),ch(r,t,p)}dh.exports=dA});var yh=g((W1,vh)=>{var mA=bi(),gA=Gn(),vA=In(),yA=mh(),_A=Xe(),wA=at(),bA=Xn();function gh(r,e,t,i,n){r!==e&&vA(e,function(s,a){if(n||(n=new mA),_A(s))yA(r,e,a,t,gh,i,n);else{var u=i?i(bA(r,a),s,a+"",r,e,n):void 0;u===void 0&&(u=s),gA(r,a,u)}},wA)}vh.exports=gh});var wh=g((H1,_h)=>{var xA=Vr(),SA=Zr(),AA=li(),OA=Xe();function qA(r,e,t){if(!OA(t))return!1;var i=typeof e;return(i=="number"?SA(t)&&AA(e,t.length):i=="string"&&e in t)?xA(t[e],r):!1}_h.exports=qA});var xh=g((G1,bh)=>{var CA=vi(),EA=wh();function IA(r){return CA(function(e,t){var i=-1,n=t.length,s=n>1?t[n-1]:void 0,a=n>2?t[2]:void 0;for(s=r.length>3&&typeof s=="function"?(n--,s):void 0,a&&EA(t[0],t[1],a)&&(s=n<3?void 0:s,n=1),e=Object(e);++i<n;){var u=t[i];u&&r(e,u,i,s)}return e})}bh.exports=IA});var Ah=g((K1,Sh)=>{var TA=yh(),PA=xh(),MA=PA(function(r,e,t){TA(r,e,t)});Sh.exports=MA});var Zn=g((J1,Oh)=>{function RA(r){var e=r==null?0:r.length;return e?r[e-1]:void 0}Oh.exports=RA});var Ch=g((V1,qh)=>{function LA(r,e){for(var t=-1,i=r==null?0:r.length;++t<i&&e(r[t],t,r)!==!1;);return r}qh.exports=LA});var Ih=g((Y1,Eh)=>{var jA=Lr(),NA=Ut();function UA(r,e){return r&&jA(e,NA(e),r)}Eh.exports=UA});var Ph=g((X1,Th)=>{var DA=Lr(),FA=at();function BA(r,e){return r&&DA(e,FA(e),r)}Th.exports=BA});var Rh=g((Z1,Mh)=>{var kA=Lr(),$A=xi();function zA(r,e){return kA(r,$A(r),e)}Mh.exports=zA});var Qn=g((Q1,Lh)=>{var WA=Tt(),HA=qi(),GA=xi(),KA=zn(),JA=Object.getOwnPropertySymbols,VA=JA?function(r){for(var e=[];r;)WA(e,GA(r)),r=HA(r);return e}:KA;Lh.exports=VA});var Nh=g((eP,jh)=>{var YA=Lr(),XA=Qn();function ZA(r,e){return YA(r,XA(r),e)}jh.exports=ZA});var es=g((rP,Uh)=>{var QA=$n(),eO=Qn(),rO=at();function tO(r){return QA(r,rO,eO)}Uh.exports=tO});var Fh=g((tP,Dh)=>{var iO=Object.prototype,nO=iO.hasOwnProperty;function sO(r){var e=r.length,t=new r.constructor(e);return e&&typeof r[0]=="string"&&nO.call(r,"index")&&(t.index=r.index,t.input=r.input),t}Dh.exports=sO});var kh=g((iP,Bh)=>{var aO=Ai();function oO(r,e){var t=e?aO(r.buffer):r.buffer;return new r.constructor(t,r.byteOffset,r.byteLength)}Bh.exports=oO});var zh=g((nP,$h)=>{var uO=/\w*$/;function fO(r){var e=new r.constructor(r.source,uO.exec(r));return e.lastIndex=r.lastIndex,e}$h.exports=fO});var Jh=g((sP,Kh)=>{var Wh=Mr(),Hh=Wh?Wh.prototype:void 0,Gh=Hh?Hh.valueOf:void 0;function cO(r){return Gh?Object(Gh.call(r)):{}}Kh.exports=cO});var Yh=g((aP,Vh)=>{var lO=Ai(),hO=kh(),pO=zh(),dO=Jh(),mO=Jn(),gO="[object Boolean]",vO="[object Date]",yO="[object Map]",_O="[object Number]",wO="[object RegExp]",bO="[object Set]",xO="[object String]",SO="[object Symbol]",AO="[object ArrayBuffer]",OO="[object DataView]",qO="[object Float32Array]",CO="[object Float64Array]",EO="[object Int8Array]",IO="[object Int16Array]",TO="[object Int32Array]",PO="[object Uint8Array]",MO="[object Uint8ClampedArray]",RO="[object Uint16Array]",LO="[object Uint32Array]";function jO(r,e,t){var i=r.constructor;switch(e){case AO:return lO(r);case gO:case vO:return new i(+r);case OO:return hO(r,t);case qO:case CO:case EO:case IO:case TO:case PO:case MO:case RO:case LO:return mO(r,t);case yO:return new i;case _O:case xO:return new i(r);case wO:return pO(r);case bO:return new i;case SO:return dO(r)}}Vh.exports=jO});var Zh=g((oP,Xh)=>{var NO=it(),UO=Ye(),DO="[object Map]";function FO(r){return UO(r)&&NO(r)==DO}Xh.exports=FO});var tp=g((uP,rp)=>{var BO=Zh(),kO=It(),Qh=wi(),ep=Qh&&Qh.isMap,$O=ep?kO(ep):BO;rp.exports=$O});var np=g((fP,ip)=>{var zO=it(),WO=Ye(),HO="[object Set]";function GO(r){return WO(r)&&zO(r)==HO}ip.exports=GO});var up=g((cP,op)=>{var KO=np(),JO=It(),sp=wi(),ap=sp&&sp.isSet,VO=ap?JO(ap):KO;op.exports=VO});var pp=g((lP,hp)=>{var YO=bi(),XO=Ch(),ZO=ci(),QO=Ih(),eq=Ph(),rq=Kn(),tq=Oi(),iq=Rh(),nq=Nh(),sq=Wn(),aq=es(),oq=it(),uq=Fh(),fq=Yh(),cq=Vn(),lq=ke(),hq=et(),pq=tp(),dq=Xe(),mq=up(),gq=Ut(),vq=at(),yq=1,_q=2,wq=4,fp="[object Arguments]",bq="[object Array]",xq="[object Boolean]",Sq="[object Date]",Aq="[object Error]",cp="[object Function]",Oq="[object GeneratorFunction]",qq="[object Map]",Cq="[object Number]",lp="[object Object]",Eq="[object RegExp]",Iq="[object Set]",Tq="[object String]",Pq="[object Symbol]",Mq="[object WeakMap]",Rq="[object ArrayBuffer]",Lq="[object DataView]",jq="[object Float32Array]",Nq="[object Float64Array]",Uq="[object Int8Array]",Dq="[object Int16Array]",Fq="[object Int32Array]",Bq="[object Uint8Array]",kq="[object Uint8ClampedArray]",$q="[object Uint16Array]",zq="[object Uint32Array]",_e={};_e[fp]=_e[bq]=_e[Rq]=_e[Lq]=_e[xq]=_e[Sq]=_e[jq]=_e[Nq]=_e[Uq]=_e[Dq]=_e[Fq]=_e[qq]=_e[Cq]=_e[lp]=_e[Eq]=_e[Iq]=_e[Tq]=_e[Pq]=_e[Bq]=_e[kq]=_e[$q]=_e[zq]=!0;_e[Aq]=_e[cp]=_e[Mq]=!1;function Ci(r,e,t,i,n,s){var a,u=e&yq,o=e&_q,l=e&wq;if(t&&(a=n?t(r,i,n,s):t(r)),a!==void 0)return a;if(!dq(r))return r;var p=lq(r);if(p){if(a=uq(r),!u)return tq(r,a)}else{var w=oq(r),b=w==cp||w==Oq;if(hq(r))return rq(r,u);if(w==lp||w==fp||b&&!n){if(a=o||b?{}:cq(r),!u)return o?nq(r,eq(a,r)):iq(r,QO(a,r))}else{if(!_e[w])return n?r:{};a=fq(r,w,u)}}s||(s=new YO);var q=s.get(r);if(q)return q;s.set(r,a),mq(r)?r.forEach(function(H){a.add(Ci(H,e,t,H,r,s))}):pq(r)&&r.forEach(function(H,K){a.set(K,Ci(H,e,t,K,r,s))});var y=l?o?aq:sq:o?vq:gq,P=p?void 0:y(r);return XO(P||r,function(H,K){P&&(K=H,H=r[K]),ZO(a,K,Ci(H,e,t,K,r,s))}),a}hp.exports=Ci});var mp=g((hP,dp)=>{function Wq(r,e,t){var i=-1,n=r.length;e<0&&(e=-e>n?0:n+e),t=t>n?n:t,t<0&&(t+=n),n=e>t?0:t-e>>>0,e>>>=0;for(var s=Array(n);++i<n;)s[i]=r[i+e];return s}dp.exports=Wq});var vp=g((pP,gp)=>{var Hq=_n(),Gq=mp();function Kq(r,e){return e.length<2?r:Hq(r,Gq(e,0,-1))}gp.exports=Kq});var _p=g((dP,yp)=>{var Jq=Et(),Vq=Zn(),Yq=vp(),Xq=ui();function Zq(r,e){return e=Jq(e,r),r=Yq(r,e),r==null||delete r[Xq(Vq(e))]}yp.exports=Zq});var bp=g((mP,wp)=>{var Qq=Yn();function eC(r){return Qq(r)?void 0:r}wp.exports=eC});var Sp=g((gP,xp)=>{var rC=_i();function tC(r){var e=r==null?0:r.length;return e?rC(r,1):[]}xp.exports=tC});var Op=g((vP,Ap)=>{var iC=Sp(),nC=qn(),sC=Cn();function aC(r){return sC(nC(r,void 0,iC),r+"")}Ap.exports=aC});var Cp=g((yP,qp)=>{var oC=Ct(),uC=pp(),fC=_p(),cC=Et(),lC=Lr(),hC=bp(),pC=Op(),dC=es(),mC=1,gC=2,vC=4,yC=pC(function(r,e){var t={};if(r==null)return t;var i=!1;e=oC(e,function(s){return s=cC(s,r),i||(i=s.length>1),s}),lC(r,dC(r),t),i&&(t=uC(t,mC|gC|vC,hC));for(var n=e.length;n--;)fC(t,e[n]);return t});qp.exports=yC});var Ip=g((_P,Ep)=>{var _C=Tt(),wC=_i(),bC=Oi(),xC=ke();function SC(){var r=arguments.length;if(!r)return[];for(var e=Array(r-1),t=arguments[0],i=r;i--;)e[i-1]=arguments[i];return _C(xC(t)?bC(t):[t],wC(e,1))}Ep.exports=SC});var Pp=g((wP,Tp)=>{Tp.exports=function(e){var t=function(te,O){var ee=te<<O|te>>>32-O;return ee},i=function(te){var O="",ee,G;for(ee=7;ee>=0;ee--)G=te>>>ee*4&15,O+=G.toString(16);return O},n,s,a,u=new Array(80),o=1732584193,l=4023233417,p=2562383102,w=271733878,b=3285377520,q,y,P,H,K,Q;e=unescape(encodeURIComponent(e));var F=e.length,Z=[];for(s=0;s<F-3;s+=4)a=e.charCodeAt(s)<<24|e.charCodeAt(s+1)<<16|e.charCodeAt(s+2)<<8|e.charCodeAt(s+3),Z.push(a);switch(F%4){case 0:s=2147483648;break;case 1:s=e.charCodeAt(F-1)<<24|8388608;break;case 2:s=e.charCodeAt(F-2)<<24|e.charCodeAt(F-1)<<16|32768;break;case 3:s=e.charCodeAt(F-3)<<24|e.charCodeAt(F-2)<<16|e.charCodeAt(F-1)<<8|128;break}for(Z.push(s);Z.length%16!==14;)Z.push(0);for(Z.push(F>>>29),Z.push(F<<3&4294967295),n=0;n<Z.length;n+=16){for(s=0;s<16;s++)u[s]=Z[n+s];for(s=16;s<=79;s++)u[s]=t(u[s-3]^u[s-8]^u[s-14]^u[s-16],1);for(q=o,y=l,P=p,H=w,K=b,s=0;s<=19;s++)Q=t(q,5)+(y&P|~y&H)+K+u[s]+1518500249&4294967295,K=H,H=P,P=t(y,30),y=q,q=Q;for(s=20;s<=39;s++)Q=t(q,5)+(y^P^H)+K+u[s]+1859775393&4294967295,K=H,H=P,P=t(y,30),y=q,q=Q;for(s=40;s<=59;s++)Q=t(q,5)+(y&P|y&H|P&H)+K+u[s]+2400959708&4294967295,K=H,H=P,P=t(y,30),y=q,q=Q;for(s=60;s<=79;s++)Q=t(q,5)+(y^P^H)+K+u[s]+3395469782&4294967295,K=H,H=P,P=t(y,30),y=q,q=Q;o=o+q&4294967295,l=l+y&4294967295,p=p+P&4294967295,w=w+H&4294967295,b=b+K&4294967295}return Q=i(o)+i(l)+i(p)+i(w)+i(b),Q.toLowerCase()}});var $p=g((bP,kp)=>{var Rp=Pp();function Lp(r){return r.map(e=>e&&e.uri).filter(Boolean)}function os(r){return["memberSet","memberList","memberChoice"].find(e=>r[e])}function Mp(r){let e=os(r),t=r[e]?Lp(r[e]):[];return{[t.length>1?e:"memberSet"]:t.map(i=>({uri:i}))}}function jp(r){let{from:e,to:t,type:i}=r,n={from:Mp(e||{}),to:Mp(t||{}),type:[i&&i[0]||"http://www.w3.org/2004/02/skos/core#mappingRelation"]};for(let s of["from","to"])if((n[s][os(n[s])]||[]).length==0){let a=r[s+"Scheme"];a&&a.uri&&(n[s+"Scheme"]={uri:a.uri})}return n}function Np(r){let{from:e,to:t}=r,i=[e,t].filter(Boolean).map(n=>Lp(n[os(n)]||[]));return[].concat(...i).sort()}function Up(r){let e=JSON.stringify(jp(r),["from","fromScheme","to","toScheme","type","memberSet","memberList","memberChoice","uri"]);return"urn:jskos:mapping:content:"+Rp(e+`
|
|
10
|
-
`)}function
|
|
11
|
-
`)}function as(r){let e=(r.identifier||[]).filter(t=>t&&!t.startsWith("urn:jskos:mapping:")).concat([Dp(r),Up(r)]).sort();return Object.assign({},r,{identifier:e})}function Fp(r,e,t){r=r&&as(r),e=e&&as(e);let i=r&&r.identifier?r.identifier.find(s=>s.startsWith(t)):null,n=e&&e.identifier?e.identifier.find(s=>s.startsWith(t)):null;return i==n}function Bp(r,e){return Fp(r,e,"urn:jskos:mapping:content:")}var OC=Bp;function qC(r,e){return Fp(r,e,"urn:jskos:mapping:members:")}kp.exports={mappingContent:jp,mappingMembers:Np,mappingContentIdentifier:Up,mappingMembersIdentifier:Dp,addMappingIdentifiers:as,compareMappings:Bp,compareMappingContent:OC,compareMappingMembers:qC}});var us=g((xP,Wp)=>{function zp(r,e,t){var i=Array.prototype.slice,n=typeof Object.keys=="function"?Object.keys:function(l){var p=[];for(var w in l)p.push(w);return p},s=function(l,p){return l===p?!0:l instanceof Date&&p instanceof Date?l.getTime()===p.getTime():typeof l!="object"&&typeof p!="object"?l==p:o(l,p)};function a(l){return l==null}function u(l){return Object.prototype.toString.call(l)=="[object Arguments]"}function o(l,p){if(a(l)||a(p)||l.prototype!==p.prototype)return!1;if(u(l))return u(p)?(l=i.call(l),p=i.call(p),s(l,p)):!1;try{var w=n(l),b=n(p),q,y}catch(P){return!1}if(w.length!=b.length)return!1;for(w.sort(),b.sort(),y=w.length-1;y>=0;y--)if(w[y]!=b[y])return!1;for(y=w.length-1;y>=0;y--)if(q=w[y],t){let P=t(l[q],p[q],q);if(P===void 0&&(P=zp(l[q],p[q])),!P)return!1}else if(!s(l[q],p[q]))return!1;return!0}return s(r,e)}Wp.exports={get:(r,e,t=void 0)=>{let i=s=>String.prototype.split.call(e,s).filter(Boolean).reduce((a,u)=>a!=null?a[u]:a,r),n=i(/[,[\]]+?/)||i(/[,[\].]+?/);return n===void 0||n===r?t:n},pick:(r,e)=>e.reduce((t,i)=>(r&&r.hasOwnProperty(i)&&(t[i]=r[i]),t),{}),forOwn:(r,e)=>{for(let t in r)r.hasOwnProperty(t)&&e(r[t],t)},isEqualWith:zp,intersection:(...r)=>r.reduce((e,t)=>e.filter(i=>t.includes(i))),isObject:r=>typeof r=="object"&&r!==null,isString:r=>!!(r&&typeof r.valueOf()=="string"),union:(r,e)=>[...new Set([...r,...e])],unionWith:(r,e,t)=>[...r,...e].reduce((i,n)=>(i.findIndex(s=>t(s,n))!==-1||i.push(n),i),[]),omitMod:(r,e)=>{for(let t of e){typeof t=="string"&&(t=t.split("."));for(let i=0;i<t.length-1;i++)r=r[t[i]];delete r[t.pop()]}}}});var fs=g((SP,CC)=>{CC.exports=[{RELEVANCE:"very high",broader:[{uri:"http://www.w3.org/2004/02/skos/core#closeMatch"}],definition:{de:["gleiche Bedeutung"],en:["same meaning"]},notation:["="],prefLabel:{ar:"\u062A\u0637\u0627\u0628\u0642 \u062A\u0627\u0645",be:"\u0434\u0430\u043A\u043B\u0430\u0434\u043D\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u0446\u044C","be-tarask":"\u0434\u0430\u043A\u043B\u0430\u0434\u043D\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",bn:"\u09B9\u09C1\u09AC\u09C1\u09B9\u09C1 \u09AE\u09BF\u09B2",ca:"equival\xE8ncia exacta",cs:"p\u0159esn\xE1 shoda",da:"exact match",de:"exakte \xDCbereinstimmung",en:"exact match",eo:"ekzakta ekvivalento",es:"equivalencia exacta",fi:"vastaava k\xE4site",fr:"\xE9quivalence exacte",gl:"correspondencia exacta",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05DE\u05D3\u05D5\u05D9\u05E7\u05EA",hu:"pontos egyez\xE9s",id:"sama persis",it:"corrispondenza esatta",ja:"\u5B8C\u5168\u4E00\u81F4",lv:"tie\u0161a sakrit\u012Bba",mk:"\u0442\u043E\u0447\u043D\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",ms:"padanan tepat","ms-arab":"\u06A4\u0627\u062F\u0646\u0646 \u062A\u06A4\u062A",nb:"eksakt samsvar",nl:"exacte match",nn:"eksakt samsvar",pl:"dok\u0142adne dopasowanie",pt:"correspond\xEAncia exata",ro:"echivalentul exact",ru:"\u0442\u043E\u0447\u043D\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sq:"p\xEBrputhje e p\xEBrpikt\xEB",sr:"\u0442\u0430\u0447\u043D\u043E \u043F\u043E\u0434\u0443\u0434\u0430\u0440\u0430\u045A\u0435",sv:"exakt tr\xE4ff",tr:"tam e\u015Fle\u015Fme",uk:"\u0442\u043E\u0447\u043D\u0430 \u0432\u0456\u0434\u043F\u043E\u0432\u0456\u0434\u043D\u0456\u0441\u0442\u044C",zh:"\u7CBE\u78BA\u5339\u914D","zh-hans":"\u7CBE\u786E\u5339\u914D","zh-hant":"\u7CBE\u78BA\u5339\u914D"},SHORT:"exact",uri:"http://www.w3.org/2004/02/skos/core#exactMatch"},{RELEVANCE:"high",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{de:["in etwa gleiche Bedeutung"],en:["same general idea but not fully identical meaning"]},notation:["\u2248"],prefLabel:{ar:"\u062A\u0637\u0627\u0628\u0642 \u0642\u0631\u064A\u0628","be-tarask":"\u0431\u043B\u0456\u0437\u043A\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"equival\xE8ncia inexacta",de:"hohe \xDCbereinstimmung",en:"close match",eo:"proksima kongrua\u0135o",es:"equivalencia inexacta",fi:"l\xE4hes vastaava k\xE4site",fr:"quasi-\xE9quivalence",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E7\u05E8\u05D5\u05D1\u05D4",it:"corrispondenza parziale",mk:"\u0431\u043B\u0438\u0441\u043A\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",ms:"padanan dekat","ms-arab":"\u06A4\u0627\u062F\u0646\u0646 \u062F\u06A9\u062A",nb:"n\xE6rt samsvar",nl:"nabije match",nn:"n\xE6rt samsvar",pl:"cz\u0119\u015Bciowe dopasowanie",pt:"correspond\xEAncia pr\xF3xima",ru:"\u0431\u043B\u0438\u0437\u043A\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sr:"\u0431\u043B\u0438\u0441\u043A\u043E \u043F\u043E\u043A\u043B\u0430\u043F\u0430\u045A\u0435",sv:"n\xE4ra matchning",tr:"yak\u0131n e\u015Fle\u015Fme","zh-hans":"\u9AD8\u5EA6\u5339\u914D"},SHORT:"close",uri:"http://www.w3.org/2004/02/skos/core#closeMatch"},{RELEVANCE:"medium",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{de:["umfassendere Bedeutung"],en:["broader meaning"]},notation:[">"],prefLabel:{"be-tarask":"\u0448\u044B\u0440\u043E\u043A\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"relaci\xF3 llunyana",de:"allgemeinere Bedeutung",en:"broad match",eo:"malstrikta kongruo",fi:"vastaava laajempi k\xE4site",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E8\u05D7\u05D1\u05D4",it:"corrispondenza generica",ja:"\u90E8\u5206\u4E00\u81F4",mk:"\u043F\u043E\u0448\u0438\u0440\u043E\u043A\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",nb:"bredere samsvar",nl:"brede match",nn:"breitt samsvar",pl:"dopasowanie poj\u0119cia o szerszym znaczeniu","pt-br":"correspond\xEAncia gen\xE9rica",ru:"\u0431\u043E\u043B\u0435\u0435 \u0448\u0438\u0440\u043E\u043A\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sr:"\u0443 \u0448\u0438\u0440\u0435\u043C \u0441\u043C\u0438\u0441\u043B\u0443",sv:"bred tr\xE4ff","zh-hans":"\u5E7F\u6CDB\u5339\u914D"},related:[{uri:"http://www.w3.org/2004/02/skos/core#narrowMatch"}],SHORT:"broad",uri:"http://www.w3.org/2004/02/skos/core#broadMatch"},{RELEVANCE:"medium",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{en:["more specific meaning"]},notation:["<"],prefLabel:{"be-tarask":"\u0432\u0443\u0437\u043A\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"relaci\xF3 estreta",de:"spezifischere Bedeutung",en:"narrow match",eo:"strikta kongruo",fi:"vastaava suppeampi k\xE4site",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E6\u05E8\u05D4",it:"corrispondenza con termine pi\xF9 specifico",mk:"\u043F\u043E\u0442\u0435\u0441\u043D\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",nb:"smalere samsvar",nl:"nauwe match",nn:"snevert samsvar",pl:"dopasowanie poj\u0119cia o w\u0119\u017Cszym znaczeniu","pt-br":"correspond\xEAncia aproximada",ru:"\u0431\u043E\u043B\u0435\u0435 \u0443\u0437\u043A\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sr:"\u0443 \u0443\u0436\u0435\u043C \u0441\u043C\u0438\u0441\u043B\u0443",sv:"smal tr\xE4ff",ur:"\u0646\u06CC\u0631\u0648 \u0645\u06CC\u0686","zh-hans":"\u6709\u9650\u5339\u914D"},related:[{uri:"http://www.w3.org/2004/02/skos/core#broadMatch"}],SHORT:"narrow",uri:"http://www.w3.org/2004/02/skos/core#narrowMatch"},{RELEVANCE:"low",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{de:["assoziative Verkn\xFCpfung unterschiedlicher Bedeutungen"],en:["associative link between meanings"]},notation:["~"],prefLabel:{"be-tarask":"\u0437\u044C\u0432\u044F\u0437\u0430\u043D\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"parella relacionada",de:"verwandte Bedeutung",en:"related match",eo:"rilata kongruo",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E7\u05E9\u05D5\u05E8\u05D4",it:"corrispondenza correlata",lv:"saist\u012Bta sakrit\u012Bba",mk:"\u043F\u043E\u0432\u0440\u0437\u0430\u043D\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",ms:"padanan berkaitan","ms-arab":"\u06A4\u0627\u062F\u0646\u0646 \u0628\u0631\u06A9\u0627\u0621\u064A\u062A\u0646",nb:"relatert samsvar",nl:"gerelateerde match",pl:"dopasowanie poj\u0119cia o powi\u0105zanym znaczeniu",ru:"\u0430\u0441\u0441\u043E\u0446\u0438\u0430\u0442\u0438\u0432\u043D\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",tr:"ili\u015Fkili benze\u015Fme",ur:"\u0645\u062A\u0639\u0644\u0642\u06C1 \u0645\u06CC\u0686",vec:"parente\u0142a re\u0142asionada","zh-hans":"\u5173\u8054\u5339\u914D"},SHORT:"related",uri:"http://www.w3.org/2004/02/skos/core#relatedMatch"},{RELEVANCE:"generic",definition:{de:["unbekannter Bedeutungszusammenhang"],en:["unknown type of link between meanings"]},notation:["\u2192"],prefLabel:{ar:"\u0646\u0648\u0639 \u0639\u0644\u0627\u0642\u0629 \u0627\u0644\u062A\u0637\u0628\u064A\u0642",be:"\u0445\u0430\u0440\u0430\u043A\u0442\u044D\u0440\u043D\u0430\u044F \u0430\u0434\u043D\u043E\u0441\u0456\u043D\u0430 \u0430\u0434\u043B\u044E\u0441\u0442\u0440\u0430\u0432\u0430\u043D\u043D\u044F","be-tarask":"\u0445\u0430\u0440\u0430\u043A\u0442\u044D\u0440\u043D\u0430\u044F \u0430\u0434\u043D\u043E\u0441\u0456\u043D\u0430 \u0430\u0434\u043B\u044E\u0441\u0442\u0440\u0430\u0432\u0430\u043D\u044C\u043D\u044F",ca:"relaci\xF3 de mapatge",de:"allgemeine Mapping-Relation",en:"SKOS generic mapping relation",fr:"lien de correspondance SKOS",he:"\u05D9\u05D7\u05E1 \u05DE\u05D9\u05E4\u05D5\u05D9 \u05DB\u05DC\u05DC\u05D9",id:"relasi pemetaan",mk:"\u043F\u0440\u0435\u0441\u043B\u0438\u043A\u0443\u0432\u0430\u0447\u043A\u0438 \u043E\u0434\u043D\u043E\u0441",nb:"generell mappingrelasjon","pt-br":"rela\xE7\xE3o gen\xE9rica de mapeamento",sr:"\u0440\u0435\u043B\u0430\u0446\u0438\u0458\u0430 \u043C\u0430\u043F\u0438\u0440\u0430\u045A\u0430",sv:"mappnings relation",zh:"\u6620\u5C04\u95DC\u4FC2","zh-hant":"\u6620\u5C04\u95DC\u4FC2"},SHORT:"",uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}]});var Gp=g((AP,Hp)=>{var EC=fs(),Ii={Concept:{type:["http://www.w3.org/2004/02/skos/core#Concept"]},ConceptScheme:{type:["http://www.w3.org/2004/02/skos/core#ConceptScheme"]},ConceptMapping:{type:EC.map(r=>r.uri)},ConceptOccurrence:{type:["http://purl.org/cld/cdtype/CatalogueOrIndex"]},Registry:{type:["http://www.w3.org/ns/dcat#Catalog"]},Distribution:{type:["http://www.w3.org/ns/dcat#Distribution"]},Concordance:{type:["http://rdfs.org/ns/void#Linkset","http://rdf-vocabulary.ddialliance.org/xkos#Correspondence"]},Resource:{},Item:{},ConceptBundle:{},Annotation:{type:["Annotation","http://www.w3.org/ns/oa#Annotation"]}},Ei=Object.keys(Ii).reduce((r,e)=>{for(let t of Ii[e].type||[])r[t]=e;return r},{});function IC(r,e=!1){var t;if(typeof r=="string"&&r)r in Ei?t=Ei[r]:(r=r.toLowerCase().replace(/s$/,""),t=Object.keys(Ii).find(i=>{let n=i.toLowerCase();if(n===r||n==="concept"+r)return!0}));else if(typeof r=="object"&&r.type){let i=Array.isArray(r.type)?r.type:[r.type];for(let n of i)if(n in Ei){t=Ei[n];break}}return e&&t?t.toLowerCase().replace(/^concept(.+)/,"$1"):t}Hp.exports={objectTypes:Ii,guessObjectType:IC}});var ls=g((OP,Kp)=>{var TC=/[\\^$.*+?()[\]{}|]/g,PC=r=>r.replace(TC,"\\$&"),MC=/[%ÄÖÜäöü ]/g,cs=class{constructor(e={}){if(Object.assign(this,e),this.notationPattern||(this.notationPattern=".+"),!this.uriPattern&&this.namespace){this.uriPattern="^"+PC(this.namespace);let t=this.notationPattern.replace(MC,encodeURI);this.uriPattern+="("+t+")$"}this.NOTATION_REGEX=RegExp("^"+this.notationPattern+"$"),this.uriPattern&&(this.URI_REGEX=RegExp(this.uriPattern))}isValidNotation(e){return this.NOTATION_REGEX.exec(e)}notationFromUri(e){if(this.URI_REGEX){let t=this.URI_REGEX.exec(e);if(t)return decodeURI(t[1])}}uriFromNotation(e){if(this.uriPattern)return e=encodeURI(e),this.uriPattern.replace(/^\^|\$$/g,"").replace(/\\/g,"").replace(/\(.*\)/,e)}conceptFromUri(e,t={}){let i=this.notationFromUri(e);if(i===void 0)return;let n={uri:e,notation:[i]};return t.inScheme&&(n.inScheme=[{uri:this.uri}]),t.topConcept&&(n.topConceptOf=[{uri:this.uri}]),n}conceptFromNotation(e,t){if(this.isValidNotation(e))return this.conceptFromUri(this.uriFromNotation(e),t)}};Kp.exports=cs});var hs=g((qP,Vp)=>{var RC=us(),Ti={store:null,path:"",defaults:["en"],getLanguages:Jp,selectLanguage:LC};function Jp(){return RC.get(Ti.store,Ti.path)||Ti.defaults}function LC(r){if(!r)return null;for(let e of Jp())if(r[e])return e;for(let e of Object.keys(r))if(e!="-")return e;return null}Vp.exports=Ti});var nd=g((CP,id)=>{var ie=us(),jC=r=>/^[A-Z]*$/.test(r),ot=(r,e)=>e.split(".").reduce((t,i)=>t&&t[i]?t[i]:null,r),NC=r=>((r instanceof Array?r:[r]).forEach(t=>{t["@context"]="https://gbv.github.io/jskos/context.json"}),r),gs=r=>(Object.keys(r).forEach(e=>{jC(e)||e.startsWith("_")?delete r[e]:r[e]!=null&&typeof r[e]=="object"&&(r[e]=gs(r[e]))}),r),UC=gs,Pi=(r,e=[],t=!0)=>{e=e.concat(["ancestors","narrower","broader","mappings","memberList","TOPCONCEPTS","MAPPINGS","PROVIDER"]);let i=Array.isArray(r)?[]:{};for(let n in r)if(!(t&&n[0]=="_")){if(e.includes(n))if(r[n]&&Array.isArray(r[n])){r[n].length>0?i[n]=[null]:i[n]=[];continue}else{i[n]=null;continue}if(n=="inScheme"){let s=[];for(let a of r.inScheme){let u={uri:a.uri};a.notation&&(u.notation=a.notation),a.prefLabel&&(u.prefLabel=a.prefLabel),s.push(u)}i.inScheme=s;continue}r[n]!=null&&typeof r[n]=="object"?i[n]=Pi(r[n]):i[n]=r[n]}return i},DC=Pi,ps=r=>r?(r.uri?[r.uri]:[]).concat(r.identifier||[]):[],vr=(r,e)=>{if(r==null&&e==null)return!0;let t=s=>s.replace("http://").replace("https://"),i=ps(r).map(t),n=ps(e).map(t);return ie.intersection(i,n).length>0},FC=vr,BC=vr,kC=vr,$C=r=>ie.get(r,"type",[]).includes("http://www.w3.org/2004/02/skos/core#Concept")||ie.get(r,"inScheme")!=null||ie.get(r,"topConceptOf")!=null,Yp=r=>ie.get(r,"type",[]).includes("http://www.w3.org/2004/02/skos/core#ConceptScheme"),Xp=(r,e)=>{if(!r||!e)return!1;for(let t of e)if(vr(r,t))return!0;return!1},zC=Xp,WC=(r,e=!1)=>r.sort((t,i)=>{let n=ie.get(t,"notation[0]"),s=ie.get(i,"notation[0]");if(n&&s&&(n=n.toLowerCase(),s=s.toLowerCase()),e&&(n=parseFloat(n)||n,s=parseFloat(s)||s),(!n||!s||n==s)&&(n=t.uri,s=i.uri),n&&s){if(n>s)return 1;if(n<s)return-1}return 0}),HC=r=>{let e=["notation[0]",["prefLabel.de","prefLabel.en"],"uri"];return r.sort((t,i)=>{for(let n of e){let s,a;if(Array.isArray(n))for(let u of n)s=s||ie.get(t,u),a=a||ie.get(i,u);else s=ie.get(t,n),a=ie.get(i,n);if(s!=null&&a!=null){if(s=s.toLowerCase(),a=a.toLowerCase(),s>a)return 1;if(s<a)return-1}}return 0})},GC=r=>{let e=ie.pick(Pi(r),["from","to","fromScheme","toScheme","creator","contributor","type","created","modified","note","identifier","uri","partOf"]);for(let t of[e.from,e.to])ie.forOwn(t,(i,n)=>{let s=[];for(let a of i)s.push(ie.pick(a,["uri","notation"]));t[n]=s});return e.fromScheme&&(e.fromScheme=ie.pick(e.fromScheme,["uri","notation"])),e.toScheme&&(e.toScheme=ie.pick(e.toScheme,["uri","notation"])),e.partOf&&(e.partOf=e.partOf.map(t=>ie.pick(t,["uri"]))),e},Zp=fs(),kt=function(r){for(let e of Zp)if(r==e.uri)return e;return null},Qp=kt("http://www.w3.org/2004/02/skos/core#mappingRelation"),KC=function(r,e=Qp){let t;return Array.isArray(r)&&r.length>0?t=r[0]:t=r,kt(t)||e},JC=(r,e={})=>{let{language:t}=e,i=ot(r,"from.memberSet.0.notation.0"),n=ot(r,"to.memberSet.0.notation.0");i=i!==null?i:"",n=n!==null?n:"";let s=kt(ot(r,"type.0"));s=s?s.SHORT:"";let a="",u="",o="";return t&&(a=ot(r,`from.memberSet.0.prefLabel.${t}`),u=ot(r,`to.memberSet.0.prefLabel.${t}`),o=ot(r,`creator.0.prefLabel.${t}`)),{fromNotation:i,toNotation:n,fromLabel:a,toLabel:u,type:s,creator:o}},VC=(r={})=>{let e=r.delimiter||",",t=r.quoteChar||'"',i=r.lineTerminator||`
|
|
12
|
-
`,n=t+t,s=a=>t+(a==null?"":a.split(t).join(n))+t;return a=>a.map(s).join(e)+i},jr=(r,e)=>{let t=[];for(let i of["from","to"])(e==null||i===e)&&(t=t.concat(ie.get(r,`${i}.memberSet`)||ie.get(r,`${i}.memberChoice`)||ie.get(r,`${i}.memberList`)||[]));return t.filter(i=>i!=null)},YC=(r={})=>{let e=VC(r),t=r.language||"en";r.type==null&&(r.type=!0);let i=a=>{a=a||[];let u=[];for(let o of["from","to"]){r.schemes&&u.push(`${o}Scheme`);let l=Math.max(...a.map(p=>jr(p,o).length),1);for(let p=0;p<l;p+=1)u.push(`${o}Notation${p?p+1:""}`),r.labels&&u.push(`${o}Label${p?p+1:""}`)}return r.type&&u.push("type"),r.creator&&u.push("creator"),e(u)},n=(a,u={})=>{let o=[];for(let l of["from","to"]){r.schemes&&o.push(ie.get(a,`${l}Scheme.notation[0]`,""));let p=jr(a,l),w=u[`${l}Count`];w==null&&(w=p.length),w=Math.max(w,1);for(let b=0;b<w;b+=1)o.push(ie.get(p[b],"notation[0]","")),r.labels&&o.push(ie.get(p[b],`prefLabel.${t}`,""))}return r.type&&o.push(ie.get(kt(ie.get(a,"type[0]")),"SHORT","")),r.creator&&o.push(ie.get(a,`creator[0].prefLabel.${t}`)),e(o)};return{header:i,fromMapping:n,fromMappings:(a,u={header:!0})=>{let o="";u.header&&(o+=i(a));let l={fromCount:Math.max(...a.map(p=>jr(p,"from").length)),toCount:Math.max(...a.map(p=>jr(p,"to").length))};for(let p of a)o+=n(p,l);return o}}};function XC(r,e){return ie.isEqualWith(r,e,(t,i,n)=>{let s={[n]:t},a={[n]:i};if(n=="from"||n=="to")return ie.isEqualWith(Object.getOwnPropertyNames(ie.get(t,n,{})),Object.getOwnPropertyNames(ie.get(i,n,{})))?ie.isEqualWith(jr(s,n),jr(a,n),(u,o,l)=>{if(l!=null)return vr(u,o)}):!1;if(n=="fromScheme"||n=="toScheme")return vr(t,i)})}var{objectTypes:ZC,guessObjectType:ds}=Gp(),QC=(r,e)=>{let t=ds(r),i=ds(e);return!(t&&i&&t!=i)},ed=r=>{Array.isArray(r)&&r.sort((e,t)=>e===null?1:t===null?-1:0)},rd=(r,e)=>(!r||!e||((Array.isArray(r.identifier)||Array.isArray(e.identifier))&&(r.identifier=ie.union(r.identifier||[],e.identifier||[])),!r.uri&&e.uri&&(r.uri=e.uri),r.uri&&e.uri&&r.uri!=e.uri&&!(r.identifier||[]).includes(e.uri)&&(r.identifier=(r.identifier||[]).concat([e.uri])),Array.isArray(r.identifier)&&r.uri&&(r.identifier=r.identifier.filter(t=>t!==r.uri)),(r.identifier||[]).length==0&&delete r.identifier,ed(r.identifier)),r),td=(r,e,t)=>{if(!r||!e)return r||e;t=t||{};let i=t._path||"",n=t.detectMismatch||[],s=t.skipPaths||[],a={};return ie.forOwn(r,(u,o)=>{if(!s.includes(i+o))if(Array.isArray(u)&&Array.isArray(e[o]))a[o]=ie.unionWith(u,e[o],(l,p)=>ie.isObject(l)&&ie.isObject(p)?vr(l,p):l===p),ed(a[o]);else if(ie.isObject(u)&&ie.isObject(e[o]))a[o]=td(u,e[o],Object.assign({_path:`${i}${o}.`},t));else{if(u&&e[o]&&n.includes(i+o)&&!ie.isEqualWith(u,e[o]))throw new Error("Property mismatch in "+i+o);a[o]=u}}),ie.forOwn(e,(u,o)=>{r[o]||(a[o]=u)}),i==""&&ie.omitMod(a,s),t.mergeUris&&rd(a,e),a},ms=r=>Array.isArray(r)?r.map(e=>ms(e)):ie.isObject(r)?(ie.forOwn(r,(e,t)=>{r[t]=ms(e)}),r):ie.isString(r)?r.normalize():r,eE=r=>{var e=/^[A-Za-z][A-Za-z0-9+\-.]*:(?:\/\/(?:(?:[A-Za-z0-9\-._~!$&'()*+,;=:]|%[0-9A-Fa-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9A-Fa-f]{1,4}:){6}|::(?:[0-9A-Fa-f]{1,4}:){5}|(?:[0-9A-Fa-f]{1,4})?::(?:[0-9A-Fa-f]{1,4}:){4}|(?:(?:[0-9A-Fa-f]{1,4}:){0,1}[0-9A-Fa-f]{1,4})?::(?:[0-9A-Fa-f]{1,4}:){3}|(?:(?:[0-9A-Fa-f]{1,4}:){0,2}[0-9A-Fa-f]{1,4})?::(?:[0-9A-Fa-f]{1,4}:){2}|(?:(?:[0-9A-Fa-f]{1,4}:){0,3}[0-9A-Fa-f]{1,4})?::[0-9A-Fa-f]{1,4}:|(?:(?:[0-9A-Fa-f]{1,4}:){0,4}[0-9A-Fa-f]{1,4})?::)(?:[0-9A-Fa-f]{1,4}:[0-9A-Fa-f]{1,4}|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))|(?:(?:[0-9A-Fa-f]{1,4}:){0,5}[0-9A-Fa-f]{1,4})?::[0-9A-Fa-f]{1,4}|(?:(?:[0-9A-Fa-f]{1,4}:){0,6}[0-9A-Fa-f]{1,4})?::)|[Vv][0-9A-Fa-f]+\.[A-Za-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)|(?:[A-Za-z0-9\-._~!$&'()*+,;=]|%[0-9A-Fa-f]{2})*)(?::[0-9]*)?(?:\/(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})*)*|\/(?:(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})+(?:\/(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})*)*)?|(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})+(?:\/(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})*)*|)(?:\?(?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})*)?(?:#(?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})*)?$/;return r.match(e)!==null},rE={mappingsByConcepts:(r,e,t)=>{let i=["memberSet","memberList","memberChoice"],n,s;for(let a of i)n=n||ie.get(r,t+"."+a+"[0].notation[0]"),s=s||ie.get(e,t+"."+a+"[0].notation[0]");return n==null||n<s?-1:s==null||n>s?1:0}},tE=(r,e)=>!r||!e?!1:[r.uri].concat(Object.values(r.identities||{}).map(t=>t.uri)).filter(t=>t!=null).includes(ie.get(e,"creator[0].uri")),iE=ls(),nE=hs();function sE(r,e){let t;if(r&&r.notation&&r.notation.length)t=r.notation[0],(Yp(r)||e=="scheme")&&(t=t.toUpperCase());else if(r&&r.inScheme&&r.inScheme[0]&&r.uri)try{t=new iE(r&&r.inScheme&&r.inScheme[0]).notationFromUri(r.uri)}catch(i){}return t||""}function vs(r,e,{language:t}={}){let i=r&&e?r[e]:r;return i&&(i[t]||(t=nE.selectLanguage(i),t))?i[t]:null}function aE(r,e={}){e=e||{};let t=e.fallbackToUri==null?!0:e.fallbackToUri;return ie.get(r,`prefLabel.${e.language}`)||vs(r,"prefLabel",e)||(t&&r&&r.uri?r.uri:"")}function oE(r,e={}){e=e||{};let t=ie.get(r,`definition.${e.language}`)||vs(r,"definition",e)||[];return ie.isString(t)&&(t=[t]),t}function uE(r){return ie.get(r,"stored",ie.get(r,"constructor.stored",ie.get(r,"provider.constructor.stored",!1)))}function fE(r){return ie.isString(r.creator)?r.creator:r.creator&&r.creator.id}function cE(r){return ie.get(r,"creator.name")||""}function lE(r,e){return!!(r&&ie.isString(r.creator)?e&&e.includes(r.creator):e&&r.creator&&e.includes(r.creator.id))}id.exports={addContext:NC,clean:gs,cleanJSKOS:UC,copyDeep:Pi,deepCopy:DC,getAllUris:ps,compare:vr,compareObjects:FC,compareSchemes:BC,compareConcepts:kC,isConcept:$C,isScheme:Yp,isContainedIn:Xp,isSchemeInList:zC,sortConcepts:WC,sortSchemes:HC,minifyMapping:GC,mappingTypes:Zp,mappingTypeByUri:kt,mappingTypeByType:KC,flattenMapping:JC,mappingCSV:YC,defaultMappingType:Qp,conceptsOfMapping:jr,compareMappingsDeep:XC,objectTypes:ZC,guessObjectType:ds,matchObjectTypes:QC,mergeUris:rd,merge:td,normalize:ms,isValidUri:eE,compareFunctions:rE,userOwnsMapping:tE,notation:sE,languageMapContent:vs,prefLabel:aE,definition:oE,mappingRegistryIsStored:uE,annotationCreatorUri:fE,annotationCreatorName:cE,annotationCreatorMatches:lE}});var He=g((EP,sd)=>{var hE=$p(),pE=nd(),dE=ls(),mE=hs();sd.exports=Object.assign({ConceptScheme:dE,languagePreference:mE},hE,pE)});var od=g((ad,_s)=>{(function(r){if(typeof ad=="object"&&typeof _s!="undefined")_s.exports=r();else if(typeof define=="function"&&define.amd)define([],r);else{var e;typeof window!="undefined"?e=window:typeof global!="undefined"?e=global:typeof self!="undefined"?e=self:e=this,e.localforage=r()}})(function(){var r,e,t;return function i(n,s,a){function u(p,w){if(!s[p]){if(!n[p]){var b=typeof mt=="function"&&mt;if(!w&&b)return b(p,!0);if(o)return o(p,!0);var q=new Error("Cannot find module '"+p+"'");throw q.code="MODULE_NOT_FOUND",q}var y=s[p]={exports:{}};n[p][0].call(y.exports,function(P){var H=n[p][1][P];return u(H||P)},y,y.exports,i,n,s,a)}return s[p].exports}for(var o=typeof mt=="function"&&mt,l=0;l<a.length;l++)u(a[l]);return u}({1:[function(i,n,s){(function(a){"use strict";var u=a.MutationObserver||a.WebKitMutationObserver,o;if(u){var l=0,p=new u(P),w=a.document.createTextNode("");p.observe(w,{characterData:!0}),o=function(){w.data=l=++l%2}}else if(!a.setImmediate&&typeof a.MessageChannel!="undefined"){var b=new a.MessageChannel;b.port1.onmessage=P,o=function(){b.port2.postMessage(0)}}else"document"in a&&"onreadystatechange"in a.document.createElement("script")?o=function(){var K=a.document.createElement("script");K.onreadystatechange=function(){P(),K.onreadystatechange=null,K.parentNode.removeChild(K),K=null},a.document.documentElement.appendChild(K)}:o=function(){setTimeout(P,0)};var q,y=[];function P(){q=!0;for(var K,Q,F=y.length;F;){for(Q=y,y=[],K=-1;++K<F;)Q[K]();F=y.length}q=!1}n.exports=H;function H(K){y.push(K)===1&&!q&&o()}}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],2:[function(i,n,s){"use strict";var a=i(1);function u(){}var o={},l=["REJECTED"],p=["FULFILLED"],w=["PENDING"];n.exports=b;function b(O){if(typeof O!="function")throw new TypeError("resolver must be a function");this.state=w,this.queue=[],this.outcome=void 0,O!==u&&H(this,O)}b.prototype.catch=function(O){return this.then(null,O)},b.prototype.then=function(O,ee){if(typeof O!="function"&&this.state===p||typeof ee!="function"&&this.state===l)return this;var G=new this.constructor(u);if(this.state!==w){var de=this.state===p?O:ee;y(G,de,this.outcome)}else this.queue.push(new q(G,O,ee));return G};function q(O,ee,G){this.promise=O,typeof ee=="function"&&(this.onFulfilled=ee,this.callFulfilled=this.otherCallFulfilled),typeof G=="function"&&(this.onRejected=G,this.callRejected=this.otherCallRejected)}q.prototype.callFulfilled=function(O){o.resolve(this.promise,O)},q.prototype.otherCallFulfilled=function(O){y(this.promise,this.onFulfilled,O)},q.prototype.callRejected=function(O){o.reject(this.promise,O)},q.prototype.otherCallRejected=function(O){y(this.promise,this.onRejected,O)};function y(O,ee,G){a(function(){var de;try{de=ee(G)}catch(qe){return o.reject(O,qe)}de===O?o.reject(O,new TypeError("Cannot resolve promise with itself")):o.resolve(O,de)})}o.resolve=function(O,ee){var G=K(P,ee);if(G.status==="error")return o.reject(O,G.value);var de=G.value;if(de)H(O,de);else{O.state=p,O.outcome=ee;for(var qe=-1,ve=O.queue.length;++qe<ve;)O.queue[qe].callFulfilled(ee)}return O},o.reject=function(O,ee){O.state=l,O.outcome=ee;for(var G=-1,de=O.queue.length;++G<de;)O.queue[G].callRejected(ee);return O};function P(O){var ee=O&&O.then;if(O&&(typeof O=="object"||typeof O=="function")&&typeof ee=="function")return function(){ee.apply(O,arguments)}}function H(O,ee){var G=!1;function de(Te){G||(G=!0,o.reject(O,Te))}function qe(Te){G||(G=!0,o.resolve(O,Te))}function ve(){ee(qe,de)}var Ne=K(ve);Ne.status==="error"&&de(Ne.value)}function K(O,ee){var G={};try{G.value=O(ee),G.status="success"}catch(de){G.status="error",G.value=de}return G}b.resolve=Q;function Q(O){return O instanceof this?O:o.resolve(new this(u),O)}b.reject=F;function F(O){var ee=new this(u);return o.reject(ee,O)}b.all=Z;function Z(O){var ee=this;if(Object.prototype.toString.call(O)!=="[object Array]")return this.reject(new TypeError("must be an array"));var G=O.length,de=!1;if(!G)return this.resolve([]);for(var qe=new Array(G),ve=0,Ne=-1,Te=new this(u);++Ne<G;)Ke(O[Ne],Ne);return Te;function Ke(cr,Er){ee.resolve(cr).then(ze,function(lr){de||(de=!0,o.reject(Te,lr))});function ze(lr){qe[Er]=lr,++ve===G&&!de&&(de=!0,o.resolve(Te,qe))}}}b.race=te;function te(O){var ee=this;if(Object.prototype.toString.call(O)!=="[object Array]")return this.reject(new TypeError("must be an array"));var G=O.length,de=!1;if(!G)return this.resolve([]);for(var qe=-1,ve=new this(u);++qe<G;)Ne(O[qe]);return ve;function Ne(Te){ee.resolve(Te).then(function(Ke){de||(de=!0,o.resolve(ve,Ke))},function(Ke){de||(de=!0,o.reject(ve,Ke))})}}},{1:1}],3:[function(i,n,s){(function(a){"use strict";typeof a.Promise!="function"&&(a.Promise=i(2))}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{2:2}],4:[function(i,n,s){"use strict";var a=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(f){return typeof f}:function(f){return f&&typeof Symbol=="function"&&f.constructor===Symbol&&f!==Symbol.prototype?"symbol":typeof f};function u(f,v){if(!(f instanceof v))throw new TypeError("Cannot call a class as a function")}function o(){try{if(typeof indexedDB!="undefined")return indexedDB;if(typeof webkitIndexedDB!="undefined")return webkitIndexedDB;if(typeof mozIndexedDB!="undefined")return mozIndexedDB;if(typeof OIndexedDB!="undefined")return OIndexedDB;if(typeof msIndexedDB!="undefined")return msIndexedDB}catch(f){return}}var l=o();function p(){try{if(!l||!l.open)return!1;var f=typeof openDatabase!="undefined"&&/(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent)&&!/Chrome/.test(navigator.userAgent)&&!/BlackBerry/.test(navigator.platform),v=typeof fetch=="function"&&fetch.toString().indexOf("[native code")!==-1;return(!f||v)&&typeof indexedDB!="undefined"&&typeof IDBKeyRange!="undefined"}catch(c){return!1}}function w(f,v){f=f||[],v=v||{};try{return new Blob(f,v)}catch(_){if(_.name!=="TypeError")throw _;for(var c=typeof BlobBuilder!="undefined"?BlobBuilder:typeof MSBlobBuilder!="undefined"?MSBlobBuilder:typeof MozBlobBuilder!="undefined"?MozBlobBuilder:WebKitBlobBuilder,x=new c,S=0;S<f.length;S+=1)x.append(f[S]);return x.getBlob(v.type)}}typeof Promise=="undefined"&&i(3);var b=Promise;function q(f,v){v&&f.then(function(c){v(null,c)},function(c){v(c)})}function y(f,v,c){typeof v=="function"&&f.then(v),typeof c=="function"&&f.catch(c)}function P(f){return typeof f!="string"&&(console.warn(f+" used as a key, but it is not a string."),f=String(f)),f}function H(){if(arguments.length&&typeof arguments[arguments.length-1]=="function")return arguments[arguments.length-1]}var K="local-forage-detect-blob-support",Q=void 0,F={},Z=Object.prototype.toString,te="readonly",O="readwrite";function ee(f){for(var v=f.length,c=new ArrayBuffer(v),x=new Uint8Array(c),S=0;S<v;S++)x[S]=f.charCodeAt(S);return c}function G(f){return new b(function(v){var c=f.transaction(K,O),x=w([""]);c.objectStore(K).put(x,"key"),c.onabort=function(S){S.preventDefault(),S.stopPropagation(),v(!1)},c.oncomplete=function(){var S=navigator.userAgent.match(/Chrome\/(\d+)/),_=navigator.userAgent.match(/Edge\//);v(_||!S||parseInt(S[1],10)>=43)}}).catch(function(){return!1})}function de(f){return typeof Q=="boolean"?b.resolve(Q):G(f).then(function(v){return Q=v,Q})}function qe(f){var v=F[f.name],c={};c.promise=new b(function(x,S){c.resolve=x,c.reject=S}),v.deferredOperations.push(c),v.dbReady?v.dbReady=v.dbReady.then(function(){return c.promise}):v.dbReady=c.promise}function ve(f){var v=F[f.name],c=v.deferredOperations.pop();if(c)return c.resolve(),c.promise}function Ne(f,v){var c=F[f.name],x=c.deferredOperations.pop();if(x)return x.reject(v),x.promise}function Te(f,v){return new b(function(c,x){if(F[f.name]=F[f.name]||m(),f.db)if(v)qe(f),f.db.close();else return c(f.db);var S=[f.name];v&&S.push(f.version);var _=l.open.apply(l,S);v&&(_.onupgradeneeded=function(E){var L=_.result;try{L.createObjectStore(f.storeName),E.oldVersion<=1&&L.createObjectStore(K)}catch(U){if(U.name==="ConstraintError")console.warn('The database "'+f.name+'" has been upgraded from version '+E.oldVersion+" to version "+E.newVersion+', but the storage "'+f.storeName+'" already exists.');else throw U}}),_.onerror=function(E){E.preventDefault(),x(_.error)},_.onsuccess=function(){var E=_.result;E.onversionchange=function(L){L.target.close()},c(E),ve(f)}})}function Ke(f){return Te(f,!1)}function cr(f){return Te(f,!0)}function Er(f,v){if(!f.db)return!0;var c=!f.db.objectStoreNames.contains(f.storeName),x=f.version<f.db.version,S=f.version>f.db.version;if(x&&(f.version!==v&&console.warn('The database "'+f.name+`" can't be downgraded from version `+f.db.version+" to version "+f.version+"."),f.version=f.db.version),S||c){if(c){var _=f.db.version+1;_>f.version&&(f.version=_)}return!0}return!1}function ze(f){return new b(function(v,c){var x=new FileReader;x.onerror=c,x.onloadend=function(S){var _=btoa(S.target.result||"");v({__local_forage_encoded_blob:!0,data:_,type:f.type})},x.readAsBinaryString(f)})}function lr(f){var v=ee(atob(f.data));return w([v],{type:f.type})}function sr(f){return f&&f.__local_forage_encoded_blob}function Bi(f){var v=this,c=v._initReady().then(function(){var x=F[v._dbInfo.name];if(x&&x.dbReady)return x.dbReady});return y(c,f,f),c}function h(f){qe(f);for(var v=F[f.name],c=v.forages,x=0;x<c.length;x++){var S=c[x];S._dbInfo.db&&(S._dbInfo.db.close(),S._dbInfo.db=null)}return f.db=null,Ke(f).then(function(_){return f.db=_,Er(f)?cr(f):_}).then(function(_){f.db=v.db=_;for(var E=0;E<c.length;E++)c[E]._dbInfo.db=_}).catch(function(_){throw Ne(f,_),_})}function d(f,v,c,x){x===void 0&&(x=1);try{var S=f.db.transaction(f.storeName,v);c(null,S)}catch(_){if(x>0&&(!f.db||_.name==="InvalidStateError"||_.name==="NotFoundError"))return b.resolve().then(function(){if(!f.db||_.name==="NotFoundError"&&!f.db.objectStoreNames.contains(f.storeName)&&f.version<=f.db.version)return f.db&&(f.version=f.db.version+1),cr(f)}).then(function(){return h(f).then(function(){d(f,v,c,x-1)})}).catch(c);c(_)}}function m(){return{forages:[],db:null,dbReady:null,deferredOperations:[]}}function A(f){var v=this,c={db:null};if(f)for(var x in f)c[x]=f[x];var S=F[c.name];S||(S=m(),F[c.name]=S),S.forages.push(v),v._initReady||(v._initReady=v.ready,v.ready=Bi);var _=[];function E(){return b.resolve()}for(var L=0;L<S.forages.length;L++){var U=S.forages[L];U!==v&&_.push(U._initReady().catch(E))}var D=S.forages.slice(0);return b.all(_).then(function(){return c.db=S.db,Ke(c)}).then(function(k){return c.db=k,Er(c,v._defaultConfig.version)?cr(c):k}).then(function(k){c.db=S.db=k,v._dbInfo=c;for(var X=0;X<D.length;X++){var ue=D[X];ue!==v&&(ue._dbInfo.db=c.db,ue._dbInfo.version=c.version)}})}function C(f,v){var c=this;f=P(f);var x=new b(function(S,_){c.ready().then(function(){d(c._dbInfo,te,function(E,L){if(E)return _(E);try{var U=L.objectStore(c._dbInfo.storeName),D=U.get(f);D.onsuccess=function(){var k=D.result;k===void 0&&(k=null),sr(k)&&(k=lr(k)),S(k)},D.onerror=function(){_(D.error)}}catch(k){_(k)}})}).catch(_)});return q(x,v),x}function I(f,v){var c=this,x=new b(function(S,_){c.ready().then(function(){d(c._dbInfo,te,function(E,L){if(E)return _(E);try{var U=L.objectStore(c._dbInfo.storeName),D=U.openCursor(),k=1;D.onsuccess=function(){var X=D.result;if(X){var ue=X.value;sr(ue)&&(ue=lr(ue));var pe=f(ue,X.key,k++);pe!==void 0?S(pe):X.continue()}else S()},D.onerror=function(){_(D.error)}}catch(X){_(X)}})}).catch(_)});return q(x,v),x}function M(f,v,c){var x=this;f=P(f);var S=new b(function(_,E){var L;x.ready().then(function(){return L=x._dbInfo,Z.call(v)==="[object Blob]"?de(L.db).then(function(U){return U?v:ze(v)}):v}).then(function(U){d(x._dbInfo,O,function(D,k){if(D)return E(D);try{var X=k.objectStore(x._dbInfo.storeName);U===null&&(U=void 0);var ue=X.put(U,f);k.oncomplete=function(){U===void 0&&(U=null),_(U)},k.onabort=k.onerror=function(){var pe=ue.error?ue.error:ue.transaction.error;E(pe)}}catch(pe){E(pe)}})}).catch(E)});return q(S,c),S}function T(f,v){var c=this;f=P(f);var x=new b(function(S,_){c.ready().then(function(){d(c._dbInfo,O,function(E,L){if(E)return _(E);try{var U=L.objectStore(c._dbInfo.storeName),D=U.delete(f);L.oncomplete=function(){S()},L.onerror=function(){_(D.error)},L.onabort=function(){var k=D.error?D.error:D.transaction.error;_(k)}}catch(k){_(k)}})}).catch(_)});return q(x,v),x}function N(f){var v=this,c=new b(function(x,S){v.ready().then(function(){d(v._dbInfo,O,function(_,E){if(_)return S(_);try{var L=E.objectStore(v._dbInfo.storeName),U=L.clear();E.oncomplete=function(){x()},E.onabort=E.onerror=function(){var D=U.error?U.error:U.transaction.error;S(D)}}catch(D){S(D)}})}).catch(S)});return q(c,f),c}function B(f){var v=this,c=new b(function(x,S){v.ready().then(function(){d(v._dbInfo,te,function(_,E){if(_)return S(_);try{var L=E.objectStore(v._dbInfo.storeName),U=L.count();U.onsuccess=function(){x(U.result)},U.onerror=function(){S(U.error)}}catch(D){S(D)}})}).catch(S)});return q(c,f),c}function Y(f,v){var c=this,x=new b(function(S,_){if(f<0){S(null);return}c.ready().then(function(){d(c._dbInfo,te,function(E,L){if(E)return _(E);try{var U=L.objectStore(c._dbInfo.storeName),D=!1,k=U.openKeyCursor();k.onsuccess=function(){var X=k.result;if(!X){S(null);return}f===0||D?S(X.key):(D=!0,X.advance(f))},k.onerror=function(){_(k.error)}}catch(X){_(X)}})}).catch(_)});return q(x,v),x}function V(f){var v=this,c=new b(function(x,S){v.ready().then(function(){d(v._dbInfo,te,function(_,E){if(_)return S(_);try{var L=E.objectStore(v._dbInfo.storeName),U=L.openKeyCursor(),D=[];U.onsuccess=function(){var k=U.result;if(!k){x(D);return}D.push(k.key),k.continue()},U.onerror=function(){S(U.error)}}catch(k){S(k)}})}).catch(S)});return q(c,f),c}function z(f,v){v=H.apply(this,arguments);var c=this.config();f=typeof f!="function"&&f||{},f.name||(f.name=f.name||c.name,f.storeName=f.storeName||c.storeName);var x=this,S;if(!f.name)S=b.reject("Invalid arguments");else{var _=f.name===c.name&&x._dbInfo.db,E=_?b.resolve(x._dbInfo.db):Ke(f).then(function(L){var U=F[f.name],D=U.forages;U.db=L;for(var k=0;k<D.length;k++)D[k]._dbInfo.db=L;return L});f.storeName?S=E.then(function(L){if(!!L.objectStoreNames.contains(f.storeName)){var U=L.version+1;qe(f);var D=F[f.name],k=D.forages;L.close();for(var X=0;X<k.length;X++){var ue=k[X];ue._dbInfo.db=null,ue._dbInfo.version=U}var pe=new b(function(me,Oe){var Se=l.open(f.name,U);Se.onerror=function(Ge){var pt=Se.result;pt.close(),Oe(Ge)},Se.onupgradeneeded=function(){var Ge=Se.result;Ge.deleteObjectStore(f.storeName)},Se.onsuccess=function(){var Ge=Se.result;Ge.close(),me(Ge)}});return pe.then(function(me){D.db=me;for(var Oe=0;Oe<k.length;Oe++){var Se=k[Oe];Se._dbInfo.db=me,ve(Se._dbInfo)}}).catch(function(me){throw(Ne(f,me)||b.resolve()).catch(function(){}),me})}}):S=E.then(function(L){qe(f);var U=F[f.name],D=U.forages;L.close();for(var k=0;k<D.length;k++){var X=D[k];X._dbInfo.db=null}var ue=new b(function(pe,me){var Oe=l.deleteDatabase(f.name);Oe.onerror=function(){var Se=Oe.result;Se&&Se.close(),me(Oe.error)},Oe.onblocked=function(){console.warn('dropInstance blocked for database "'+f.name+'" until all open connections are closed')},Oe.onsuccess=function(){var Se=Oe.result;Se&&Se.close(),pe(Se)}});return ue.then(function(pe){U.db=pe;for(var me=0;me<D.length;me++){var Oe=D[me];ve(Oe._dbInfo)}}).catch(function(pe){throw(Ne(f,pe)||b.resolve()).catch(function(){}),pe})})}return q(S,v),S}var ae={_driver:"asyncStorage",_initStorage:A,_support:p(),iterate:I,getItem:C,setItem:M,removeItem:T,clear:N,length:B,key:Y,keys:V,dropInstance:z};function se(){return typeof openDatabase=="function"}var ce="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ye="~~local_forage_type~",ge=/^~~local_forage_type~([^~]+)~/,ne="__lfsc__:",oe=ne.length,he="arbf",Ue="blob",Ce="si08",Pe="ui08",Je="uic8",kr="si16",Ir="si32",$r="ur16",Tr="ui32",Ht="fl32",Pr="fl64",Es=oe+he.length,Is=Object.prototype.toString;function Ts(f){var v=f.length*.75,c=f.length,x,S=0,_,E,L,U;f[f.length-1]==="="&&(v--,f[f.length-2]==="="&&v--);var D=new ArrayBuffer(v),k=new Uint8Array(D);for(x=0;x<c;x+=4)_=ce.indexOf(f[x]),E=ce.indexOf(f[x+1]),L=ce.indexOf(f[x+2]),U=ce.indexOf(f[x+3]),k[S++]=_<<2|E>>4,k[S++]=(E&15)<<4|L>>2,k[S++]=(L&3)<<6|U&63;return D}function ki(f){var v=new Uint8Array(f),c="",x;for(x=0;x<v.length;x+=3)c+=ce[v[x]>>2],c+=ce[(v[x]&3)<<4|v[x+1]>>4],c+=ce[(v[x+1]&15)<<2|v[x+2]>>6],c+=ce[v[x+2]&63];return v.length%3===2?c=c.substring(0,c.length-1)+"=":v.length%3===1&&(c=c.substring(0,c.length-2)+"=="),c}function gd(f,v){var c="";if(f&&(c=Is.call(f)),f&&(c==="[object ArrayBuffer]"||f.buffer&&Is.call(f.buffer)==="[object ArrayBuffer]")){var x,S=ne;f instanceof ArrayBuffer?(x=f,S+=he):(x=f.buffer,c==="[object Int8Array]"?S+=Ce:c==="[object Uint8Array]"?S+=Pe:c==="[object Uint8ClampedArray]"?S+=Je:c==="[object Int16Array]"?S+=kr:c==="[object Uint16Array]"?S+=$r:c==="[object Int32Array]"?S+=Ir:c==="[object Uint32Array]"?S+=Tr:c==="[object Float32Array]"?S+=Ht:c==="[object Float64Array]"?S+=Pr:v(new Error("Failed to get type for BinaryArray"))),v(S+ki(x))}else if(c==="[object Blob]"){var _=new FileReader;_.onload=function(){var E=ye+f.type+"~"+ki(this.result);v(ne+Ue+E)},_.readAsArrayBuffer(f)}else try{v(JSON.stringify(f))}catch(E){console.error("Couldn't convert value into a JSON string: ",f),v(null,E)}}function vd(f){if(f.substring(0,oe)!==ne)return JSON.parse(f);var v=f.substring(Es),c=f.substring(oe,Es),x;if(c===Ue&&ge.test(v)){var S=v.match(ge);x=S[1],v=v.substring(S[0].length)}var _=Ts(v);switch(c){case he:return _;case Ue:return w([_],{type:x});case Ce:return new Int8Array(_);case Pe:return new Uint8Array(_);case Je:return new Uint8ClampedArray(_);case kr:return new Int16Array(_);case $r:return new Uint16Array(_);case Ir:return new Int32Array(_);case Tr:return new Uint32Array(_);case Ht:return new Float32Array(_);case Pr:return new Float64Array(_);default:throw new Error("Unkown type: "+c)}}var $i={serialize:gd,deserialize:vd,stringToBuffer:Ts,bufferToString:ki};function Ps(f,v,c,x){f.executeSql("CREATE TABLE IF NOT EXISTS "+v.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],c,x)}function yd(f){var v=this,c={db:null};if(f)for(var x in f)c[x]=typeof f[x]!="string"?f[x].toString():f[x];var S=new b(function(_,E){try{c.db=openDatabase(c.name,String(c.version),c.description,c.size)}catch(L){return E(L)}c.db.transaction(function(L){Ps(L,c,function(){v._dbInfo=c,_()},function(U,D){E(D)})},E)});return c.serializer=$i,S}function hr(f,v,c,x,S,_){f.executeSql(c,x,S,function(E,L){L.code===L.SYNTAX_ERR?E.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[v.storeName],function(U,D){D.rows.length?_(U,L):Ps(U,v,function(){U.executeSql(c,x,S,_)},_)},_):_(E,L)},_)}function _d(f,v){var c=this;f=P(f);var x=new b(function(S,_){c.ready().then(function(){var E=c._dbInfo;E.db.transaction(function(L){hr(L,E,"SELECT * FROM "+E.storeName+" WHERE key = ? LIMIT 1",[f],function(U,D){var k=D.rows.length?D.rows.item(0).value:null;k&&(k=E.serializer.deserialize(k)),S(k)},function(U,D){_(D)})})}).catch(_)});return q(x,v),x}function wd(f,v){var c=this,x=new b(function(S,_){c.ready().then(function(){var E=c._dbInfo;E.db.transaction(function(L){hr(L,E,"SELECT * FROM "+E.storeName,[],function(U,D){for(var k=D.rows,X=k.length,ue=0;ue<X;ue++){var pe=k.item(ue),me=pe.value;if(me&&(me=E.serializer.deserialize(me)),me=f(me,pe.key,ue+1),me!==void 0){S(me);return}}S()},function(U,D){_(D)})})}).catch(_)});return q(x,v),x}function Ms(f,v,c,x){var S=this;f=P(f);var _=new b(function(E,L){S.ready().then(function(){v===void 0&&(v=null);var U=v,D=S._dbInfo;D.serializer.serialize(v,function(k,X){X?L(X):D.db.transaction(function(ue){hr(ue,D,"INSERT OR REPLACE INTO "+D.storeName+" (key, value) VALUES (?, ?)",[f,k],function(){E(U)},function(pe,me){L(me)})},function(ue){if(ue.code===ue.QUOTA_ERR){if(x>0){E(Ms.apply(S,[f,U,c,x-1]));return}L(ue)}})})}).catch(L)});return q(_,c),_}function bd(f,v,c){return Ms.apply(this,[f,v,c,1])}function xd(f,v){var c=this;f=P(f);var x=new b(function(S,_){c.ready().then(function(){var E=c._dbInfo;E.db.transaction(function(L){hr(L,E,"DELETE FROM "+E.storeName+" WHERE key = ?",[f],function(){S()},function(U,D){_(D)})})}).catch(_)});return q(x,v),x}function Sd(f){var v=this,c=new b(function(x,S){v.ready().then(function(){var _=v._dbInfo;_.db.transaction(function(E){hr(E,_,"DELETE FROM "+_.storeName,[],function(){x()},function(L,U){S(U)})})}).catch(S)});return q(c,f),c}function Ad(f){var v=this,c=new b(function(x,S){v.ready().then(function(){var _=v._dbInfo;_.db.transaction(function(E){hr(E,_,"SELECT COUNT(key) as c FROM "+_.storeName,[],function(L,U){var D=U.rows.item(0).c;x(D)},function(L,U){S(U)})})}).catch(S)});return q(c,f),c}function Od(f,v){var c=this,x=new b(function(S,_){c.ready().then(function(){var E=c._dbInfo;E.db.transaction(function(L){hr(L,E,"SELECT key FROM "+E.storeName+" WHERE id = ? LIMIT 1",[f+1],function(U,D){var k=D.rows.length?D.rows.item(0).key:null;S(k)},function(U,D){_(D)})})}).catch(_)});return q(x,v),x}function qd(f){var v=this,c=new b(function(x,S){v.ready().then(function(){var _=v._dbInfo;_.db.transaction(function(E){hr(E,_,"SELECT key FROM "+_.storeName,[],function(L,U){for(var D=[],k=0;k<U.rows.length;k++)D.push(U.rows.item(k).key);x(D)},function(L,U){S(U)})})}).catch(S)});return q(c,f),c}function Cd(f){return new b(function(v,c){f.transaction(function(x){x.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name <> '__WebKitDatabaseInfoTable__'",[],function(S,_){for(var E=[],L=0;L<_.rows.length;L++)E.push(_.rows.item(L).name);v({db:f,storeNames:E})},function(S,_){c(_)})},function(x){c(x)})})}function Ed(f,v){v=H.apply(this,arguments);var c=this.config();f=typeof f!="function"&&f||{},f.name||(f.name=f.name||c.name,f.storeName=f.storeName||c.storeName);var x=this,S;return f.name?S=new b(function(_){var E;f.name===c.name?E=x._dbInfo.db:E=openDatabase(f.name,"","",0),f.storeName?_({db:E,storeNames:[f.storeName]}):_(Cd(E))}).then(function(_){return new b(function(E,L){_.db.transaction(function(U){function D(pe){return new b(function(me,Oe){U.executeSql("DROP TABLE IF EXISTS "+pe,[],function(){me()},function(Se,Ge){Oe(Ge)})})}for(var k=[],X=0,ue=_.storeNames.length;X<ue;X++)k.push(D(_.storeNames[X]));b.all(k).then(function(){E()}).catch(function(pe){L(pe)})},function(U){L(U)})})}):S=b.reject("Invalid arguments"),q(S,v),S}var Id={_driver:"webSQLStorage",_initStorage:yd,_support:se(),iterate:wd,getItem:_d,setItem:bd,removeItem:xd,clear:Sd,length:Ad,key:Od,keys:qd,dropInstance:Ed};function Td(){try{return typeof localStorage!="undefined"&&"setItem"in localStorage&&!!localStorage.setItem}catch(f){return!1}}function Rs(f,v){var c=f.name+"/";return f.storeName!==v.storeName&&(c+=f.storeName+"/"),c}function Pd(){var f="_localforage_support_test";try{return localStorage.setItem(f,!0),localStorage.removeItem(f),!1}catch(v){return!0}}function Md(){return!Pd()||localStorage.length>0}function Rd(f){var v=this,c={};if(f)for(var x in f)c[x]=f[x];return c.keyPrefix=Rs(f,v._defaultConfig),Md()?(v._dbInfo=c,c.serializer=$i,b.resolve()):b.reject()}function Ld(f){var v=this,c=v.ready().then(function(){for(var x=v._dbInfo.keyPrefix,S=localStorage.length-1;S>=0;S--){var _=localStorage.key(S);_.indexOf(x)===0&&localStorage.removeItem(_)}});return q(c,f),c}function jd(f,v){var c=this;f=P(f);var x=c.ready().then(function(){var S=c._dbInfo,_=localStorage.getItem(S.keyPrefix+f);return _&&(_=S.serializer.deserialize(_)),_});return q(x,v),x}function Nd(f,v){var c=this,x=c.ready().then(function(){for(var S=c._dbInfo,_=S.keyPrefix,E=_.length,L=localStorage.length,U=1,D=0;D<L;D++){var k=localStorage.key(D);if(k.indexOf(_)===0){var X=localStorage.getItem(k);if(X&&(X=S.serializer.deserialize(X)),X=f(X,k.substring(E),U++),X!==void 0)return X}}});return q(x,v),x}function Ud(f,v){var c=this,x=c.ready().then(function(){var S=c._dbInfo,_;try{_=localStorage.key(f)}catch(E){_=null}return _&&(_=_.substring(S.keyPrefix.length)),_});return q(x,v),x}function Dd(f){var v=this,c=v.ready().then(function(){for(var x=v._dbInfo,S=localStorage.length,_=[],E=0;E<S;E++){var L=localStorage.key(E);L.indexOf(x.keyPrefix)===0&&_.push(L.substring(x.keyPrefix.length))}return _});return q(c,f),c}function Fd(f){var v=this,c=v.keys().then(function(x){return x.length});return q(c,f),c}function Bd(f,v){var c=this;f=P(f);var x=c.ready().then(function(){var S=c._dbInfo;localStorage.removeItem(S.keyPrefix+f)});return q(x,v),x}function kd(f,v,c){var x=this;f=P(f);var S=x.ready().then(function(){v===void 0&&(v=null);var _=v;return new b(function(E,L){var U=x._dbInfo;U.serializer.serialize(v,function(D,k){if(k)L(k);else try{localStorage.setItem(U.keyPrefix+f,D),E(_)}catch(X){(X.name==="QuotaExceededError"||X.name==="NS_ERROR_DOM_QUOTA_REACHED")&&L(X),L(X)}})})});return q(S,c),S}function $d(f,v){if(v=H.apply(this,arguments),f=typeof f!="function"&&f||{},!f.name){var c=this.config();f.name=f.name||c.name,f.storeName=f.storeName||c.storeName}var x=this,S;return f.name?S=new b(function(_){f.storeName?_(Rs(f,x._defaultConfig)):_(f.name+"/")}).then(function(_){for(var E=localStorage.length-1;E>=0;E--){var L=localStorage.key(E);L.indexOf(_)===0&&localStorage.removeItem(L)}}):S=b.reject("Invalid arguments"),q(S,v),S}var zd={_driver:"localStorageWrapper",_initStorage:Rd,_support:Td(),iterate:Nd,getItem:jd,setItem:kd,removeItem:Bd,clear:Ld,length:Fd,key:Ud,keys:Dd,dropInstance:$d},Wd=function(v,c){return v===c||typeof v=="number"&&typeof c=="number"&&isNaN(v)&&isNaN(c)},Hd=function(v,c){for(var x=v.length,S=0;S<x;){if(Wd(v[S],c))return!0;S++}return!1},Ls=Array.isArray||function(f){return Object.prototype.toString.call(f)==="[object Array]"},ht={},js={},zr={INDEXEDDB:ae,WEBSQL:Id,LOCALSTORAGE:zd},Gd=[zr.INDEXEDDB._driver,zr.WEBSQL._driver,zr.LOCALSTORAGE._driver],Gt=["dropInstance"],zi=["clear","getItem","iterate","key","keys","length","removeItem","setItem"].concat(Gt),Kd={description:"",driver:Gd.slice(),name:"localforage",size:4980736,storeName:"keyvaluepairs",version:1};function Jd(f,v){f[v]=function(){var c=arguments;return f.ready().then(function(){return f[v].apply(f,c)})}}function Wi(){for(var f=1;f<arguments.length;f++){var v=arguments[f];if(v)for(var c in v)v.hasOwnProperty(c)&&(Ls(v[c])?arguments[0][c]=v[c].slice():arguments[0][c]=v[c])}return arguments[0]}var Vd=function(){function f(v){u(this,f);for(var c in zr)if(zr.hasOwnProperty(c)){var x=zr[c],S=x._driver;this[c]=S,ht[S]||this.defineDriver(x)}this._defaultConfig=Wi({},Kd),this._config=Wi({},this._defaultConfig,v),this._driverSet=null,this._initDriver=null,this._ready=!1,this._dbInfo=null,this._wrapLibraryMethodsWithReady(),this.setDriver(this._config.driver).catch(function(){})}return f.prototype.config=function(c){if((typeof c=="undefined"?"undefined":a(c))==="object"){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var x in c){if(x==="storeName"&&(c[x]=c[x].replace(/\W/g,"_")),x==="version"&&typeof c[x]!="number")return new Error("Database version must be a number.");this._config[x]=c[x]}return"driver"in c&&c.driver?this.setDriver(this._config.driver):!0}else return typeof c=="string"?this._config[c]:this._config},f.prototype.defineDriver=function(c,x,S){var _=new b(function(E,L){try{var U=c._driver,D=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!c._driver){L(D);return}for(var k=zi.concat("_initStorage"),X=0,ue=k.length;X<ue;X++){var pe=k[X],me=!Hd(Gt,pe);if((me||c[pe])&&typeof c[pe]!="function"){L(D);return}}var Oe=function(){for(var pt=function(Zd){return function(){var Qd=new Error("Method "+Zd+" is not implemented by the current driver"),Ns=b.reject(Qd);return q(Ns,arguments[arguments.length-1]),Ns}},Hi=0,Xd=Gt.length;Hi<Xd;Hi++){var Gi=Gt[Hi];c[Gi]||(c[Gi]=pt(Gi))}};Oe();var Se=function(pt){ht[U]&&console.info("Redefining LocalForage driver: "+U),ht[U]=c,js[U]=pt,E()};"_support"in c?c._support&&typeof c._support=="function"?c._support().then(Se,L):Se(!!c._support):Se(!0)}catch(Ge){L(Ge)}});return y(_,x,S),_},f.prototype.driver=function(){return this._driver||null},f.prototype.getDriver=function(c,x,S){var _=ht[c]?b.resolve(ht[c]):b.reject(new Error("Driver not found."));return y(_,x,S),_},f.prototype.getSerializer=function(c){var x=b.resolve($i);return y(x,c),x},f.prototype.ready=function(c){var x=this,S=x._driverSet.then(function(){return x._ready===null&&(x._ready=x._initDriver()),x._ready});return y(S,c,c),S},f.prototype.setDriver=function(c,x,S){var _=this;Ls(c)||(c=[c]);var E=this._getSupportedDrivers(c);function L(){_._config.driver=_.driver()}function U(X){return _._extend(X),L(),_._ready=_._initStorage(_._config),_._ready}function D(X){return function(){var ue=0;function pe(){for(;ue<X.length;){var me=X[ue];return ue++,_._dbInfo=null,_._ready=null,_.getDriver(me).then(U).catch(pe)}L();var Oe=new Error("No available storage method found.");return _._driverSet=b.reject(Oe),_._driverSet}return pe()}}var k=this._driverSet!==null?this._driverSet.catch(function(){return b.resolve()}):b.resolve();return this._driverSet=k.then(function(){var X=E[0];return _._dbInfo=null,_._ready=null,_.getDriver(X).then(function(ue){_._driver=ue._driver,L(),_._wrapLibraryMethodsWithReady(),_._initDriver=D(E)})}).catch(function(){L();var X=new Error("No available storage method found.");return _._driverSet=b.reject(X),_._driverSet}),y(this._driverSet,x,S),this._driverSet},f.prototype.supports=function(c){return!!js[c]},f.prototype._extend=function(c){Wi(this,c)},f.prototype._getSupportedDrivers=function(c){for(var x=[],S=0,_=c.length;S<_;S++){var E=c[S];this.supports(E)&&x.push(E)}return x},f.prototype._wrapLibraryMethodsWithReady=function(){for(var c=0,x=zi.length;c<x;c++)Jd(this,zi[c])},f.prototype.createInstance=function(c){return new f(c)},f}(),Yd=new Vd;n.exports=Yd},{3:3}]},{},[4])(4)})});var qs=g((Os,ld)=>{"use strict";(function(r,e,t){let i;(i=t.define)&&i.amd?i([],function(){return e}):(i=t.modules)?i[r.toLowerCase()]=e:typeof Os=="object"?ld.exports=e:t[r]=e})("FlexSearch",function r(e){function t(h,d){let m=d?d.id:h&&h.id;this.id=m||m===0?m:Ke++,this.init(h,d),u(this,"index",function(){return this.a?Object.keys(this.a.index[this.a.keys[0]].c):Object.keys(this.c)}),u(this,"length",function(){return this.index.length})}function i(h,d,m,A){return this.u!==this.g&&(this.o=this.o.concat(m),this.u++,A&&this.o.length>=A&&(this.u=this.g),this.u===this.g&&(this.cache&&this.j.set(d,this.o),this.F&&this.F(this.o))),this}function n(h){let d=G();for(let m in h)if(h.hasOwnProperty(m)){let A=h[m];F(A)?d[m]=A.slice(0):te(A)?d[m]=n(A):d[m]=A}return d}function s(h,d){let m=h.length,A=Z(d),C=[];for(let I=0,M=0;I<m;I++){let T=h[I];(A&&d(T)||!A&&!d[T])&&(C[M++]=T)}return C}function a(h,d,m,A,C,I,M,T,N,B){m=K(m,M?0:C,T,I,d,N,B);let Y;if(T&&(T=m.page,Y=m.next,m=m.result),M)d=this.where(M,null,C,m);else{for(d=m,m=this.l,C=d.length,I=Array(C),M=0;M<C;M++)I[M]=m[d[M]];d=I}return m=d,A&&(Z(A)||(ze=A.split(":"),1<ze.length?A=P:(ze=ze[0],A=y)),m.sort(A)),m=H(T,Y,m),this.cache&&this.j.set(h,m),m}function u(h,d,m){Object.defineProperty(h,d,{get:m})}function o(h){return new RegExp(h,"g")}function l(h,d){for(let m=0;m<d.length;m+=2)h=h.replace(d[m],d[m+1]);return h}function p(h,d,m,A,C,I,M,T){return d[m]?d[m]:(C=C?(T-(M||T/1.5))*I+(M||T/1.5)*C:I,d[m]=C,C>=M&&(h=h[T-(C+.5>>0)],h=h[m]||(h[m]=[]),h[h.length]=A),C)}function w(h,d){if(h){let m=Object.keys(h);for(let A=0,C=m.length;A<C;A++){let I=m[A],M=h[I];if(M)for(let T=0,N=M.length;T<N;T++)if(M[T]===d){N===1?delete h[I]:M.splice(T,1);break}else te(M[T])&&w(M[T],d)}}}function b(h){let d="",m="";var A="";for(let C=0;C<h.length;C++){let I=h[C];I!==m&&(C&&I==="h"?(A=A==="a"||A==="e"||A==="i"||A==="o"||A==="u"||A==="y",((m==="a"||m==="e"||m==="i"||m==="o"||m==="u"||m==="y")&&A||m===" ")&&(d+=I)):d+=I),A=C===h.length-1?"":h[C+1],m=I}return d}function q(h,d){return h=h.length-d.length,0>h?1:h?-1:0}function y(h,d){return h=h[ze],d=d[ze],h<d?-1:h>d?1:0}function P(h,d){let m=ze.length;for(let A=0;A<m;A++)h=h[ze[A]],d=d[ze[A]];return h<d?-1:h>d?1:0}function H(h,d,m){return h?{page:h,next:d?""+d:null,result:m}:m}function K(h,d,m,A,C,I,M){let T,N=[];if(m===!0){m="0";var B=""}else B=m&&m.split(":");let Y=h.length;if(1<Y){let ge=G(),ne=[],oe,he;var V=0,z;let Ue;var ae=!0;let Ce,Pe=0,Je,kr,Ir,$r;if(B&&(B.length===2?(Ir=B,B=!1):B=$r=parseInt(B[0],10)),M){for(oe=G();V<Y;V++)if(C[V]==="not")for(he=h[V],Ue=he.length,z=0;z<Ue;z++)oe["@"+he[z]]=1;else kr=V+1;if(O(kr))return H(m,T,N);V=0}else Je=Q(C)&&C;let Tr;for(;V<Y;V++){let Ht=V===(kr||Y)-1;if(!Je||!V)if((z=Je||C&&C[V])&&z!=="and")if(z==="or")Tr=!1;else continue;else Tr=I=!0;if(he=h[V],Ue=he.length){if(ae)if(Ce){var se=Ce.length;for(z=0;z<se;z++){ae=Ce[z];var ce="@"+ae;M&&oe[ce]||(ge[ce]=1,I||(N[Pe++]=ae))}Ce=null,ae=!1}else{Ce=he;continue}for(ce=!1,z=0;z<Ue;z++){se=he[z];var ye="@"+se;let Pr=I?ge[ye]||0:V;if(!(!Pr&&!A||M&&oe[ye]||!I&&ge[ye]))if(Pr===V){if(Ht){if((!$r||--$r<Pe)&&(N[Pe++]=se,d&&Pe===d))return H(m,Pe+(B||0),N)}else ge[ye]=V+1;ce=!0}else A&&(ye=ne[Pr]||(ne[Pr]=[]),ye[ye.length]=se)}if(Tr&&!ce&&!A)break}else if(Tr&&!A)return H(m,T,he)}if(Ce)if(V=Ce.length,M)for(z=B?parseInt(B,10):0;z<V;z++)h=Ce[z],oe["@"+h]||(N[Pe++]=h);else N=Ce;if(A){for(Pe=N.length,Ir?(V=parseInt(Ir[0],10)+1,z=parseInt(Ir[1],10)+1):(V=ne.length,z=0);V--;)if(se=ne[V]){for(Ue=se.length;z<Ue;z++)if(A=se[z],(!M||!oe["@"+A])&&(N[Pe++]=A,d&&Pe===d))return H(m,V+":"+z,N);z=0}}}else!Y||C&&C[0]==="not"||(N=h[0],B&&(B=parseInt(B[0],10)));return d&&(M=N.length,B&&B>M&&(B=0),B=B||0,T=B+d,T<M?N=N.slice(B,T):(T=0,B&&(N=N.slice(B)))),H(m,T,N)}function Q(h){return typeof h=="string"}function F(h){return h.constructor===Array}function Z(h){return typeof h=="function"}function te(h){return typeof h=="object"}function O(h){return typeof h=="undefined"}function ee(h){let d=Array(h);for(let m=0;m<h;m++)d[m]=G();return d}function G(){return Object.create(null)}function de(){let h,d;self.onmessage=function(m){if(m=m.data)if(m.search){let A=d.search(m.content,m.threshold?{limit:m.limit,threshold:m.threshold,where:m.where}:m.limit);self.postMessage({id:h,content:m.content,limit:m.limit,result:A})}else m.add?d.add(m.id,m.content):m.update?d.update(m.id,m.content):m.remove?d.remove(m.id):m.clear?d.clear():m.info?(m=d.info(),m.worker=h,console.log(m)):m.register&&(h=m.id,m.options.cache=!1,m.options.async=!1,m.options.worker=!1,d=new Function(m.register.substring(m.register.indexOf("{")+1,m.register.lastIndexOf("}")))(),d=new d(m.options))}}function qe(h,d,m,A){h=e("flexsearch","id"+h,de,function(I){(I=I.data)&&I.result&&A(I.id,I.content,I.result,I.limit,I.where,I.cursor,I.suggest)},d);let C=r.toString();return m.id=d,h.postMessage({register:C,options:m,id:d}),h}let ve={encode:"icase",f:"forward",split:/\W+/,cache:!1,async:!1,g:!1,D:!1,a:!1,b:9,threshold:0,depth:0},Ne={memory:{encode:"extra",f:"strict",threshold:0,b:1},speed:{encode:"icase",f:"strict",threshold:1,b:3,depth:2},match:{encode:"extra",f:"full",threshold:1,b:3},score:{encode:"extra",f:"strict",threshold:1,b:9,depth:4},balance:{encode:"balance",f:"strict",threshold:0,b:3,depth:3},fast:{encode:"icase",f:"strict",threshold:8,b:9,depth:1}},Te=[],Ke=0,cr={},Er={};t.create=function(h,d){return new t(h,d)},t.registerMatcher=function(h){for(let d in h)h.hasOwnProperty(d)&&Te.push(o(d),h[d]);return this},t.registerEncoder=function(h,d){return sr[h]=d.bind(sr),this},t.registerLanguage=function(h,d){return cr[h]=d.filter,Er[h]=d.stemmer,this},t.encode=function(h,d){return sr[h](d)},t.prototype.init=function(h,d){if(this.v=[],d){var m=d.preset;h=d}else h||(h=ve),m=h.preset;if(d={},Q(h)?(d=Ne[h],h={}):m&&(d=Ne[m]),m=h.worker)if(typeof Worker=="undefined")h.worker=!1,this.m=null;else{var A=parseInt(m,10)||4;this.C=-1,this.u=0,this.o=[],this.F=null,this.m=Array(A);for(var C=0;C<A;C++)this.m[C]=qe(this.id,C,h,i.bind(this))}if(this.f=h.tokenize||d.f||this.f||ve.f,this.split=O(m=h.split)?this.split||ve.split:Q(m)?o(m):m,this.D=h.rtl||this.D||ve.D,this.async=typeof Promise=="undefined"||O(m=h.async)?this.async||ve.async:m,this.g=O(m=h.worker)?this.g||ve.g:m,this.threshold=O(m=h.threshold)?d.threshold||this.threshold||ve.threshold:m,this.b=O(m=h.resolution)?m=d.b||this.b||ve.b:m,m<=this.threshold&&(this.b=this.threshold+1),this.depth=this.f!=="strict"||O(m=h.depth)?d.depth||this.depth||ve.depth:m,this.w=(m=O(m=h.encode)?d.encode||ve.encode:m)&&sr[m]&&sr[m].bind(sr)||(Z(m)?m:this.w||!1),(m=h.matcher)&&this.addMatcher(m),m=(d=h.lang)||h.filter){if(Q(m)&&(m=cr[m]),F(m)){A=this.w,C=G();for(var I=0;I<m.length;I++){var M=A?A(m[I]):m[I];C[M]=1}m=C}this.filter=m}if(m=d||h.stemmer){var T;d=Q(m)?Er[m]:m,A=this.w,C=[];for(T in d)d.hasOwnProperty(T)&&(I=A?A(T):T,C.push(o(I+"($|\\W)"),A?A(d[T]):d[T]));this.stemmer=T=C}if(this.a=C=(m=h.doc)?n(m):this.a||ve.a,this.i=ee(this.b-(this.threshold||0)),this.h=G(),this.c=G(),C){if(this.l=G(),h.doc=null,T=C.index={},d=C.keys=[],A=C.field,I=C.tag,M=C.store,F(C.id)||(C.id=C.id.split(":")),M){var N=G();if(Q(M))N[M]=1;else if(F(M))for(let B=0;B<M.length;B++)N[M[B]]=1;else te(M)&&(N=M);C.store=N}if(I){if(this.G=G(),M=G(),A)if(Q(A))M[A]=h;else if(F(A))for(N=0;N<A.length;N++)M[A[N]]=h;else te(A)&&(M=A);for(F(I)||(C.tag=I=[I]),A=0;A<I.length;A++)this.G[I[A]]=G();this.I=I,A=M}if(A){let B;for(F(A)||(te(A)?(B=A,C.field=A=Object.keys(A)):C.field=A=[A]),C=0;C<A.length;C++)I=A[C],F(I)||(B&&(h=B[I]),d[C]=I,A[C]=I.split(":")),T[I]=new t(h)}h.doc=m}return this.B=!0,this.j=(this.cache=m=O(m=h.cache)?this.cache||ve.cache:m)?new Bi(m):!1,this},t.prototype.encode=function(h){return h&&(Te.length&&(h=l(h,Te)),this.v.length&&(h=l(h,this.v)),this.w&&(h=this.w(h)),this.stemmer&&(h=l(h,this.stemmer))),h},t.prototype.addMatcher=function(h){let d=this.v;for(let m in h)h.hasOwnProperty(m)&&d.push(o(m),h[m]);return this},t.prototype.add=function(h,d,m,A,C){if(this.a&&te(h))return this.A("add",h,d);if(d&&Q(d)&&(h||h===0)){var I="@"+h;if(this.c[I]&&!A)return this.update(h,d);if(this.g)return++this.C>=this.m.length&&(this.C=0),this.m[this.C].postMessage({add:!0,id:h,content:d}),this.c[I]=""+this.C,m&&m(),this;if(!C){if(this.async&&typeof importScripts!="function"){let ne=this;if(I=new Promise(function(oe){setTimeout(function(){ne.add(h,d,null,A,!0),ne=null,oe()})}),m)I.then(m);else return I;return this}if(m)return this.add(h,d,null,A,!0),m(),this}if(d=this.encode(d),!d.length)return this;m=this.f,C=Z(m)?m(d):d.split(this.split),this.filter&&(C=s(C,this.filter));let V=G();V._ctx=G();let z=C.length,ae=this.threshold,se=this.depth,ce=this.b,ye=this.i,ge=this.D;for(let ne=0;ne<z;ne++){var M=C[ne];if(M){var T=M.length,N=(ge?ne+1:z-ne)/z,B="";switch(m){case"reverse":case"both":for(var Y=T;--Y;)B=M[Y]+B,p(ye,V,B,h,ge?1:(T-Y)/T,N,ae,ce-1);B="";case"forward":for(Y=0;Y<T;Y++)B+=M[Y],p(ye,V,B,h,ge?(Y+1)/T:1,N,ae,ce-1);break;case"full":for(Y=0;Y<T;Y++){let oe=(ge?Y+1:T-Y)/T;for(let he=T;he>Y;he--)B=M.substring(Y,he),p(ye,V,B,h,oe,N,ae,ce-1)}break;default:if(T=p(ye,V,M,h,1,N,ae,ce-1),se&&1<z&&T>=ae)for(T=V._ctx[M]||(V._ctx[M]=G()),M=this.h[M]||(this.h[M]=ee(ce-(ae||0))),N=ne-se,B=ne+se+1,0>N&&(N=0),B>z&&(B=z);N<B;N++)N!==ne&&p(M,T,C[N],h,0,ce-(N<ne?ne-N:N-ne),ae,ce-1)}}}this.c[I]=1,this.B=!1}return this},t.prototype.A=function(h,d,m){if(F(d)){var A=d.length;if(A--){for(var C=0;C<A;C++)this.A(h,d[C]);return this.A(h,d[A],m)}}else{var I=this.a.index,M=this.a.keys,T=this.a.tag;C=this.a.store;var N,B=this.a.id;A=d;for(var Y=0;Y<B.length;Y++)A=A[B[Y]];if(h==="remove"&&(delete this.l[A],B=M.length,B--)){for(d=0;d<B;d++)I[M[d]].remove(A);return I[M[B]].remove(A,m)}if(T){for(N=0;N<T.length;N++){var V=T[N],z=d;for(B=V.split(":"),Y=0;Y<B.length;Y++)z=z[B[Y]];z="@"+z}N=this.G[V],N=N[z]||(N[z]=[])}B=this.a.field;for(let ae=0,se=B.length;ae<se;ae++){for(V=B[ae],T=d,z=0;z<V.length;z++)T=T[V[z]];V=I[M[ae]],z=h==="add"?V.add:V.update,ae===se-1?z.call(V,A,T,m):z.call(V,A,T)}if(C){for(m=Object.keys(C),h=G(),I=0;I<m.length;I++)if(M=m[I],C[M]){M=M.split(":");let ae,se;for(B=0;B<M.length;B++)T=M[B],ae=(ae||d)[T],se=(se||h)[T]=ae}d=h}N&&(N[N.length]=d),this.l[A]=d}return this},t.prototype.update=function(h,d,m){return this.a&&te(h)?this.A("update",h,d):(this.c["@"+h]&&Q(d)&&(this.remove(h),this.add(h,d,m,!0)),this)},t.prototype.remove=function(h,d,m){if(this.a&&te(h))return this.A("remove",h,d);var A="@"+h;if(this.c[A]){if(this.g)return this.m[this.c[A]].postMessage({remove:!0,id:h}),delete this.c[A],d&&d(),this;if(!m){if(this.async&&typeof importScripts!="function"){let C=this;if(A=new Promise(function(I){setTimeout(function(){C.remove(h,null,!0),C=null,I()})}),d)A.then(d);else return A;return this}if(d)return this.remove(h,null,!0),d(),this}for(d=0;d<this.b-(this.threshold||0);d++)w(this.i[d],h);this.depth&&w(this.h,h),delete this.c[A],this.B=!1}return this};let ze;t.prototype.search=function(h,d,m,A){if(te(d)){if(F(d))for(var C=0;C<d.length;C++)d[C].query=h;else d.query=h;h=d,d=1e3}else d&&Z(d)?(m=d,d=1e3):d||d===0||(d=1e3);if(this.g){this.F=m,this.u=0,this.o=[];for(var I=0;I<this.g;I++)this.m[I].postMessage({search:!0,limit:d,content:h})}else{var M=[],T=h;if(te(h)&&!F(h)){m||(m=h.callback)&&(T.callback=null);var N=h.sort,B=h.page;d=h.limit,I=h.threshold;var Y=h.suggest;h=h.query}if(this.a){I=this.a.index;let ge=T.where;var V=T.bool||"or",z=T.field;let ne=V,oe,he;if(z)F(z)||(z=[z]);else if(F(T)){var ae=T;z=[],ne=[];for(var se=0;se<T.length;se++)A=T[se],C=A.bool||V,z[se]=A.field,ne[se]=C,C==="not"?oe=!0:C==="and"&&(he=!0)}else z=this.a.keys;for(V=z.length,se=0;se<V;se++)ae&&(T=ae[se]),B&&!Q(T)&&(T.page=null,T.limit=0),M[se]=I[z[se]].search(T,0);if(m)return m(a.call(this,h,ne,M,N,d,Y,ge,B,he,oe));if(this.async){let Ue=this;return new Promise(function(Ce){Promise.all(M).then(function(Pe){Ce(a.call(Ue,h,ne,Pe,N,d,Y,ge,B,he,oe))})})}return a.call(this,h,ne,M,N,d,Y,ge,B,he,oe)}if(I||(I=this.threshold||0),!A){if(this.async&&typeof importScripts!="function"){let ge=this;if(I=new Promise(function(ne){setTimeout(function(){ne(ge.search(T,d,null,!0)),ge=null})}),m)I.then(m);else return I;return this}if(m)return m(this.search(T,d,null,!0)),this}if(!h||!Q(h))return M;if(T=h,this.cache)if(this.B){if(m=this.j.get(h))return m}else this.j.clear(),this.B=!0;if(T=this.encode(T),!T.length)return M;m=this.f,m=Z(m)?m(T):T.split(this.split),this.filter&&(m=s(m,this.filter)),ae=m.length,A=!0,C=[];var ce=G(),ye=0;if(1<ae&&(this.depth&&this.f==="strict"?V=!0:m.sort(q)),!V||(se=this.h)){let ge=this.b;for(;ye<ae;ye++){let ne=m[ye];if(ne){if(V){if(!z){if(se[ne])z=ne,ce[ne]=1;else if(!Y)return M}if(Y&&ye===ae-1&&!C.length)V=!1,ne=z||ne,ce[ne]=0;else if(!z)continue}if(!ce[ne]){let oe=[],he=!1,Ue=0,Ce=V?se[z]:this.i;if(Ce){let Pe;for(let Je=0;Je<ge-I;Je++)(Pe=Ce[Je]&&Ce[Je][ne])&&(oe[Ue++]=Pe,he=!0)}if(he)z=ne,C[C.length]=1<Ue?oe.concat.apply([],oe):oe[0];else if(!Y){A=!1;break}ce[ne]=1}}}}else A=!1;return A&&(M=K(C,d,B,Y)),this.cache&&this.j.set(h,M),M}},t.prototype.find=function(h,d){return this.where(h,d,1)[0]||null},t.prototype.where=function(h,d,m,A){let C=this.l,I=[],M=0,T;var N;let B;if(te(h)){m||(m=d);var Y=Object.keys(h),V=Y.length;if(T=!1,V===1&&Y[0]==="id")return[C[h.id]];if((N=this.I)&&!A)for(var z=0;z<N.length;z++){var ae=N[z],se=h[ae];if(!O(se)){if(B=this.G[ae]["@"+se],--V===0)return B;Y.splice(Y.indexOf(ae),1),delete h[ae];break}}for(N=Array(V),z=0;z<V;z++)N[z]=Y[z].split(":")}else{if(Z(h)){for(d=A||Object.keys(C),m=d.length,Y=0;Y<m;Y++)V=C[d[Y]],h(V)&&(I[M++]=V);return I}if(O(d))return[C[h]];if(h==="id")return[C[d]];Y=[h],V=1,N=[h.split(":")],T=!0}for(A=B||A||Object.keys(C),z=A.length,ae=0;ae<z;ae++){se=B?A[ae]:C[A[ae]];let ce=!0;for(let ye=0;ye<V;ye++){T||(d=h[Y[ye]]);let ge=N[ye],ne=ge.length,oe=se;if(1<ne)for(let he=0;he<ne;he++)oe=oe[ge[he]];else oe=oe[ge[0]];if(oe!==d){ce=!1;break}}if(ce&&(I[M++]=se,m&&M===m))break}return I},t.prototype.info=function(){if(this.g)for(let h=0;h<this.g;h++)this.m[h].postMessage({info:!0,id:this.id});else return{id:this.id,items:this.length,cache:this.cache&&this.cache.s?this.cache.s.length:!1,matcher:Te.length+(this.v?this.v.length:0),worker:this.g,threshold:this.threshold,depth:this.depth,resolution:this.b,contextual:this.depth&&this.f==="strict"}},t.prototype.clear=function(){return this.destroy().init()},t.prototype.destroy=function(){if(this.cache&&(this.j.clear(),this.j=null),this.i=this.h=this.c=null,this.a){let h=this.a.keys;for(let d=0;d<h.length;d++)this.a.index[h[d]].destroy();this.a=this.l=null}return this},t.prototype.export=function(h){let d=!h||O(h.serialize)||h.serialize;if(this.a){let A=!h||O(h.doc)||h.doc;var m=!h||O(h.index)||h.index;h=[];let C=0;if(m)for(m=this.a.keys;C<m.length;C++){let I=this.a.index[m[C]];h[C]=[I.i,I.h,Object.keys(I.c)]}A&&(h[C]=this.l)}else h=[this.i,this.h,Object.keys(this.c)];return d&&(h=JSON.stringify(h)),h},t.prototype.import=function(h,d){(!d||O(d.serialize)||d.serialize)&&(h=JSON.parse(h));let m=G();if(this.a){var A=!d||O(d.doc)||d.doc,C=0;if(!d||O(d.index)||d.index){d=this.a.keys;let M=d.length;for(var I=h[0][2];C<I.length;C++)m[I[C]]=1;for(C=0;C<M;C++){I=this.a.index[d[C]];let T=h[C];T&&(I.i=T[0],I.h=T[1],I.c=m)}}A&&(this.l=te(A)?A:h[C])}else{for(A=h[2],C=0;C<A.length;C++)m[A[C]]=1;this.i=h[0],this.h=h[1],this.c=m}};let lr=function(){let h=o("\\s+"),d=o("[^a-z0-9 ]"),m=[o("[-/]")," ",d,"",h," "];return function(A){return b(l(A.toLowerCase(),m))}}(),sr={icase:function(h){return h.toLowerCase()},simple:function(){let h=o("\\s+"),d=o("[^a-z0-9 ]"),m=o("[-/]"),A=o("[\xE0\xE1\xE2\xE3\xE4\xE5]"),C=o("[\xE8\xE9\xEA\xEB]"),I=o("[\xEC\xED\xEE\xEF]"),M=o("[\xF2\xF3\xF4\xF5\xF6\u0151]"),T=o("[\xF9\xFA\xFB\xFC\u0171]"),N=o("[\xFD\u0177\xFF]"),B=o("\xF1"),Y=o("[\xE7c]"),V=o("\xDF"),z=o(" & "),ae=[A,"a",C,"e",I,"i",M,"o",T,"u",N,"y",B,"n",Y,"k",V,"s",z," and ",m," ",d,"",h," "];return function(se){return se=l(se.toLowerCase(),ae),se===" "?"":se}}(),advanced:function(){let h=o("ae"),d=o("ai"),m=o("ay"),A=o("ey"),C=o("oe"),I=o("ue"),M=o("ie"),T=o("sz"),N=o("zs"),B=o("ck"),Y=o("cc"),V=o("sh"),z=o("th"),ae=o("dt"),se=o("ph"),ce=o("pf"),ye=o("ou"),ge=o("uo"),ne=[h,"a",d,"ei",m,"ei",A,"ei",C,"o",I,"u",M,"i",T,"s",N,"s",V,"s",B,"k",Y,"k",z,"t",ae,"t",se,"f",ce,"f",ye,"o",ge,"u"];return function(oe,he){return oe&&(oe=this.simple(oe),2<oe.length&&(oe=l(oe,ne)),he||1<oe.length&&(oe=b(oe)),oe)}}(),extra:function(){let h=o("p"),d=o("z"),m=o("[cgq]"),A=o("n"),C=o("d"),I=o("[vw]"),M=o("[aeiouy]"),T=[h,"b",d,"s",m,"k",A,"m",C,"t",I,"f",M,""];return function(N){if(!N)return N;if(N=this.advanced(N,!0),1<N.length){N=N.split(" ");for(let B=0;B<N.length;B++){let Y=N[B];1<Y.length&&(N[B]=Y[0]+l(Y.substring(1),T))}N=N.join(" "),N=b(N)}return N}}(),balance:lr},Bi=function(){function h(d){this.clear(),this.H=d!==!0&&d}return h.prototype.clear=function(){this.cache=G(),this.count=G(),this.index=G(),this.s=[]},h.prototype.set=function(d,m){if(this.H&&O(this.cache[d])){let A=this.s.length;if(A===this.H){A--;let C=this.s[A];delete this.cache[C],delete this.count[C],delete this.index[C]}this.index[d]=A,this.s[A]=d,this.count[d]=-1,this.cache[d]=m,this.get(d)}else this.cache[d]=m},h.prototype.get=function(d){let m=this.cache[d];if(this.H&&m){var A=++this.count[d];let I=this.index,M=I[d];if(0<M){let T=this.s;for(var C=M;this.count[T[--M]]<=A&&M!==-1;);if(M++,M!==C){for(A=C;A>M;A--)C=T[A-1],T[A]=C,I[C]=A;T[M]=d,I[d]=M}}}return m},h}();return t}(function(){let r={},e=typeof Blob!="undefined"&&typeof URL!="undefined"&&URL.createObjectURL;return function(t,i,n,s,a){return n=e?URL.createObjectURL(new Blob(["("+n.toString()+")()"],{type:"text/javascript"})):t+".min.js",t+="-"+i,r[t]||(r[t]=[]),r[t][a]=new Worker(n),r[t][a].onmessage=s,r[t][a]}}()),Os)});var xE={};Jt(xE,{BaseProvider:()=>le,CocodaSDK:()=>Cr,ConceptApiProvider:()=>ir,LabelSearchSuggestionProvider:()=>br,LocApiProvider:()=>Sr,LocalMappingsProvider:()=>yr,MappingsApiProvider:()=>tr,MyCoReProvider:()=>Or,OccurrencesApiProvider:()=>_r,ReconciliationApiProvider:()=>wr,SkohubProvider:()=>Ar,SkosmosApiProvider:()=>xr,addAllProviders:()=>bE,cdk:()=>md,errors:()=>Fe,utils:()=>Ur});var Fe={};Jt(Fe,{BackendError:()=>vt,BackendUnavailableError:()=>yt,CDKError:()=>Ee,InvalidOrMissingParameterError:()=>W,InvalidProviderError:()=>Wr,InvalidRequestError:()=>Qe,MethodNotImplementedError:()=>gt,MissingApiUrlError:()=>De,NetworkError:()=>_t});var Ee=class extends Error{constructor({message:e="",relatedError:t=null,code:i=null}={}){!e&&t&&t.message&&(e=t.message),super(e),this.name=this.constructor.name,this.relatedError=t,this.code=i}},gt=class extends Ee{constructor(n){var s=n,{method:e,message:t=""}=s,i=J(s,["method","message"]);i.message=`Method not implemented: ${e} (${t})`,super(i)}},W=class extends Ee{constructor(n){var s=n,{parameter:e,message:t=""}=s,i=J(s,["parameter","message"]);i.message=`Invalid or missing parameter: ${e} (${t})`,super(i)}},Qe=class extends Ee{},vt=class extends Ee{},yt=class extends Ee{},_t=class extends Ee{},De=class extends Ee{},Wr=class extends Ee{};var dd=fe(ii(),1);var re=fe(Ru(),1),xe=fe(zu(),1),gr=fe(mf(),1),Ft=fe(Bf(),1),rs=fe(ec(),1),ts=fe(Ic(),1),Ie=fe(ke(),1),Bt=fe(Xe(),1),be=fe(Pc(),1),is=fe(Gc(),1),rr=fe(Dl(),1),AC=fe(Ah(),1),ns=fe(Zn(),1),ar=fe(Cp(),1),ss=fe(Ip(),1);var qr=fe(He(),1);var Wt={};Jt(Wt,{BaseProvider:()=>le,ConceptApiProvider:()=>ir,LabelSearchSuggestionProvider:()=>br,LocApiProvider:()=>Sr,LocalMappingsProvider:()=>yr,MappingsApiProvider:()=>tr,MyCoReProvider:()=>Or,OccurrencesApiProvider:()=>_r,ReconciliationApiProvider:()=>wr,SkohubProvider:()=>Ar,SkosmosApiProvider:()=>xr});var ut=fe(He(),1);var Mi=fe(ii(),1);var Ur={};Jt(Ur,{concatUrl:()=>or,listOfCapabilities:()=>Ae,requestMethods:()=>ys,withCustomProps:()=>Nr});var ys=[{method:"getRegistries",fallback:[],type:"Registries"},{method:"getSchemes",fallback:[],type:"Schemes"},{method:"vocSearch",fallback:[],type:"Schemes"},{method:"getTypes",fallback:[],type:"Types"},{method:"suggest",fallback:["",[],[],[]]},{method:"vocSuggest",fallback:["",[],[],[]]},{method:"getConcordances",fallback:[],type:"Concordances"},{method:"getOccurrences",fallback:[],type:"Occurrences"},{method:"getTop",fallback:[],type:"Concepts"},{method:"getConcepts",fallback:[],type:"Concepts"},{method:"getNarrower",fallback:[],type:"Concepts"},{method:"getAncestors",fallback:[],type:"Concepts"},{method:"search",fallback:[],type:"Concepts"},{method:"getMapping",fallback:null,type:"Mapping"},{method:"getMappings",fallback:[],type:"Mappings"},{method:"postMapping",fallback:null,type:"Mapping"},{method:"postMappings",fallback:[],type:"Mapping"},{method:"putMapping",fallback:null,type:"Mapping"},{method:"patchMapping",fallback:null,type:"Mapping"},{method:"deleteMapping",fallback:!1},{method:"deleteMappings",fallback:[]},{method:"getAnnotations",fallback:[],type:"Annotations"},{method:"postAnnotation",fallback:null,type:"Annotation"},{method:"putAnnotation",fallback:null,type:"Annotation"},{method:"patchAnnotation",fallback:null,type:"Annotation"},{method:"deleteAnnotation",fallback:!1}];function or(...r){let[e,...t]=r;for(let i of t)e.endsWith("/")||(e+="/"),i.startsWith("/")&&(i=i.slice(1)),e+=i;return e}function Nr(r,e){return r._totalCount=e._totalCount,r._url=e._url,r}var Ae=["schemes","top","data","concepts","narrower","ancestors","types","suggest","search","auth","mappings","concordances","annotations","occurrences"];var le=class{constructor(e={}){this._jskos=e,this.axios=Mi.default.create({timeout:2e4}),this._path=typeof window!="undefined"&&window.location.pathname,this.has={},this._defaultLanguages="en,de,fr,es,nl,it,fi,pl,ru,cs,jp".split(","),this.languages=[],this._auth={key:null,bearerToken:null},this._repeating=[],this._api={status:e.status,schemes:Array.isArray(e.schemes)?void 0:e.schemes,top:e.top,data:e.data,concepts:e.concepts,narrower:e.narrower,ancestors:e.ancestors,types:e.types,suggest:e.suggest,search:e.search,"voc-suggest":e["voc-suggest"],"voc-search":e["voc-search"],mappings:e.mappings,concordances:e.concordances,annotations:e.annotations,occurrences:e.occurrences,reconcile:e.reconcile,api:e.api},this._config={},this.setRetryConfig(),this.axios.interceptors.request.use(i=>{if(!i._skipAdditionalParameters){let n=gr.default([].concat(re.default(i,"params.language","").split(","),this.languages,this._defaultLanguages).filter(s=>s!="")).join(",");xe.default(i,"params.language",n),this.has.auth&&this._auth.bearerToken&&!re.default(i,"headers.Authorization")&&xe.default(i,"headers.Authorization",`Bearer ${this._auth.bearerToken}`)}if(i.url.startsWith("http:")&&typeof window!="undefined"&&window.location.protocol=="https:")throw new Mi.default.Cancel("Can't call http API from https.");return i}),this.axios.interceptors.response.use(({data:i,headers:n={},config:s={}})=>{i=ut.default.normalize(i);let a=s.url;if(a.endsWith("?")||(a+="?"),ts.default(s.params||{},(u,o)=>{a+=`${o}=${encodeURIComponent(u)}&`}),Ie.default(i)||Bt.default(i)){let u=parseInt(n["x-total-count"]);isNaN(u)||(i._totalCount=u),i._url=a}return i},i=>{let n=re.default(i,"config._retryCount",0),s=re.default(i,"config.method"),a=re.default(i,"response.status");return this._retryConfig.methods.includes(s)&&this._retryConfig.statusCodes.includes(a)&&n<this._retryConfig.count?(i.config._retryCount=n+1,i.config.data&&(i.config.data=JSON.parse(i.config.data)),new Promise((u,o)=>{setTimeout(()=>{this.axios(i.config).then(u).catch(o)},(()=>{let l=this._retryConfig.delay;return typeof l=="function"?l(n):l})())})):Promise.reject(i)});let t=[];for(let{method:i,type:n}of ys){let s=this[i]&&this[i].bind(this);if(!s){this[i]=()=>{throw new gt({method:i})};continue}this[i]=(a={})=>{if(a._raw)return delete a._raw,s(a);let u=t.find(w=>w.method==i&&rr.default(w.options,a));if(u)return u.promise;let o;a.cancelToken||(o=this.getCancelTokenSource(),a.cancelToken=o.token);let l=this.init().then(()=>s(a)).then(w=>(Ie.default(w)&&w._totalCount===void 0?w._totalCount=w.length:Bt.default(w)&&w._totalCount===void 0&&(w._totalCount=1),w&&n&&this[`adjust${n}`]&&(w=this[`adjust${n}`](w)),w)).catch(w=>{throw w instanceof Ee?w:w.response?w.response.status.toString().startsWith(4)?new Qe({relatedError:w,code:w.response.status}):new vt({relatedError:w,code:w.response.status}):w.request?typeof navigator!="undefined"&&(navigator.connection||navigator.mozConnection||navigator.webkitConnection)?new yt({relatedError:w}):new _t({relatedError:w}):new Ee({relatedError:w})});o&&(l.cancel=(...w)=>o.cancel(...w));let p={method:i,options:ar.default(a,["cancelToken"]),promise:l};return t.push(p),l.catch(()=>{}).then(()=>t.splice(t.indexOf(p),1)),l}}}get uri(){return this._jskos.uri}get notation(){return this._jskos.notation}get prefLabel(){return this._jskos.prefLabel}get definition(){return this._jskos.definition}get schemes(){return this._jskos.schemes}get excludedSchemes(){return this._jskos.excludedSchemes}get stored(){return this._jskos.stored!==void 0?this._jskos.stored:this.constructor.stored}init(){return j(this,null,function*(){return this._init?this._init:(this._init=(()=>j(this,null,function*(){this._prepare();let e;if(be.default(this._api.status))try{e=yield this.axios({method:"get",url:this._api.status})}catch(t){re.default(t,"response.status")===404&&(this._api.status=null)}else e=this._api.status;if(Bt.default(e)&&!is.default(e)){this._config=e.config||{};for(let t of Object.keys(this._api))this._api[t]===void 0&&(this._api[t]=e[t]||null)}this._setup()}))(),this._init)})}_prepare(){}_setup(){}getCancelTokenSource(){return Mi.default.CancelToken.source()}setAuth({key:e=this._auth.key,bearerToken:t=this._auth.bearerToken}){this._auth.key=e,this._auth.bearerToken=t}setRetryConfig(e={}){this._retryConfig=Object.assign({methods:["get","head","options"],statusCodes:[401,403],count:3,delay:t=>300*t},e)}isAuthorizedFor({type:e,action:t,user:i,crossUser:n}){if(t=="read"&&this.has[e]===!0)return!0;if(!this.has[e])return!1;let s=re.default(this._config,`${e}.${t}`);if(!s)return!!this.has[e][t];if(s.auth&&(!i||!this._auth.key)||s.auth&&this._auth.key!=re.default(this._config,"auth.key"))return!1;let a=[i.uri].concat(Object.values(i.identities||{}).map(u=>u.uri)).filter(u=>u!=null);if(s.auth&&s.identities&&Ft.default(a,s.identities).length==0)return!1;if(s.auth&&s.identityProviders){let u=Object.keys(i&&i.identities||{});if(Ft.default(u,s.identityProviders).length==0)return!1}return n?s.crossUser===!0||Ft.default(s.crossUser||[],a).length>0:!!this.has[e][t]}supportsScheme(e){if(!e)return!1;let t=Ie.default(this.schemes)?this.schemes:null;return t==null&&!ut.default.isContainedIn(e,this.excludedSchemes||[])?!0:ut.default.isContainedIn(e,t)}adjustConcept(e){if(!e||e.__SAVED__)return e;e._getNarrower=t=>this.getNarrower($(R({},t),{concept:e})),e._getAncestors=t=>this.getAncestors($(R({},t),{concept:e})),e._getDetails=t=>j(this,null,function*(){return(yield this.getConcepts($(R({},t),{concepts:[e]})))[0]});for(let t of["broader","narrower","ancestors"])Array.isArray(e[t])&&e[t].length&&!e[t].includes(null)&&(e[t]=this.adjustConcepts(e[t]));return e._registry=this,e}adjustConcepts(e){return Nr(e.map(t=>this.adjustConcept(t)),e)}adjustRegistries(e){return e}adjustScheme(e){if(!e||e.__SAVED__)return e;let t=e._registry;return e._registry=this.cdk&&this.cdk.registryForScheme(e),!e._registry||t===e._registry||e._registry._api.api===this._api.api?e._registry=t||this:["concepts","topConcepts"].forEach(i=>{Array.isArray(e[i])&&(e[i].length===0||e[i][0]===null)&&delete e[i]}),e._registry&&(e._getTop=i=>e._registry.getTop($(R({},i),{scheme:e})),e._getTypes=i=>e._registry.getTypes($(R({},i),{scheme:e})),e._suggest=s=>{var a=s,{search:i}=a,n=J(a,["search"]);return e._registry.suggest($(R({},n),{search:i,scheme:e}))}),e}adjustSchemes(e){return Nr(e.map(t=>this.adjustScheme(t)),e)}adjustConcordances(e){for(let t of e)t._registry=this;return e}adjustMapping(e){for(let t of["from","to"]){let i=`${t}Scheme`;e[i]||(e[i]=re.default(ut.default.conceptsOfMapping(e,t),"[0].inScheme[0]",null))}if(e._registry=this,!e.identifier){let t=re.default(ut.default.addMappingIdentifiers(e),"identifier");t&&(e.identifier=t)}return e}adjustMappings(e){return Nr(e.map(t=>this.adjustMapping(t)),e)}postMappings(){return j(this,arguments,function*(i={}){var n=i,{mappings:e}=n,t=J(n,["mappings"]);if(!e||!e.length)throw new W({parameter:"mappings"});return this._callHelperForArrayWrappers({method:"postMapping",items:e,itemProperty:"mapping",config:t})})}deleteMappings(){return j(this,arguments,function*(i={}){var n=i,{mappings:e}=n,t=J(n,["mappings"]);if(!e||!e.length)throw new W({parameter:"mappings"});return this._callHelperForArrayWrappers({method:"deleteMapping",items:e,itemProperty:"mapping",config:t})})}_callHelperForArrayWrappers(s){return j(this,arguments,function*({method:e,items:t,itemProperty:i,config:n}){let a=[],u=yield Promise.all(t.map(o=>j(this,null,function*(){try{return yield this[e]($(R({[i]:o},n),{_raw:!0}))}catch(l){return a[t.indexOf(o)]=l,null}})));return u._errors=a,u})}};le.providerName="Base";var Le=fe(He(),1);var ur=fe(od(),1);var Ri,gE=new Uint8Array(16);function ws(){if(!Ri&&(Ri=typeof crypto!="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Ri))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ri(gE)}var Re=[];for(let r=0;r<256;++r)Re.push((r+256).toString(16).slice(1));function ud(r,e=0){return(Re[r[e+0]]+Re[r[e+1]]+Re[r[e+2]]+Re[r[e+3]]+"-"+Re[r[e+4]]+Re[r[e+5]]+"-"+Re[r[e+6]]+Re[r[e+7]]+"-"+Re[r[e+8]]+Re[r[e+9]]+"-"+Re[r[e+10]]+Re[r[e+11]]+Re[r[e+12]]+Re[r[e+13]]+Re[r[e+14]]+Re[r[e+15]]).toLowerCase()}var vE=typeof crypto!="undefined"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),bs={randomUUID:vE};function yE(r,e,t){if(bs.randomUUID&&!e&&!r)return bs.randomUUID();r=r||{};let i=r.random||(r.rng||ws)();if(i[6]=i[6]&15|64,i[8]=i[8]&63|128,e){t=t||0;for(let n=0;n<16;++n)e[t+n]=i[n];return e}return ud(i)}var Li=yE;var ji="urn:uuid:",yr=class extends le{_prepare(){this.has.mappings={read:!0,create:!0,update:!0,delete:!0},Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){this.queue=[],this.localStorageKey="cocoda-mappings--"+this._path;let e="mappings",t=()=>ur.default.getItem(this.localStorageKey).then(i=>{i=i||[];let n=0;for(let s of i.filter(a=>!a.uri||!a.uri.startsWith(ji)))s.uri&&(s.identifier||(s.identifier=[]),s.identifier.push(s.uri)),s.uri=`${ji}${Li()}`,n+=1;return n&&console.warn(`URIs added to ${n} local mappings.`),ur.default.setItem(this.localStorageKey,i)});ur.default.getItem(e).then(i=>{i&&console.warn(`Warning: There is old data in local storage (or IndexedDB, depending on the ) with the key "${e}". This data will not be used anymore. A manual export is necessary to get this data back.`)}),this.queue.push(t().catch(i=>{console.warn("Error when adding URIs to local mappings:",i)}))}isAuthorizedFor({type:e,action:t}){return e=="mappings"&&t!="anonymous"}_getMappingsQueue(){let e=ns.default(this.queue)||Promise.resolve();return new Promise(t=>{function i(){var a,u,o=new Promise((l,p)=>{a=l,u=p});return o.resolve=a,o.reject=u,o}let n=i(),s=()=>{n.resolve()};this.queue.push(n),e.then(()=>ur.default.getItem(this.localStorageKey)).then(a=>{t({mappings:a,done:s})})})}getMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(t._raw=!0,!e||!e.uri)throw new W({parameter:"mapping"});return(yield this.getMappings($(R({},t),{uri:e.uri})))[0]})}getMappings(){return j(this,arguments,function*({from:e,fromScheme:t,to:i,toScheme:n,creator:s,type:a,partOf:u,offset:o,limit:l,direction:p,mode:w,identifier:b,uri:q}={}){let y={};return e&&(y.from=be.default(e)?e:e.uri),t&&(y.fromScheme=be.default(t)?{uri:t}:t),i&&(y.to=be.default(i)?i:i.uri),n&&(y.toScheme=be.default(n)?{uri:n}:n),s&&(y.creator=be.default(s)?s:Le.default.prefLabel(s)),a&&(y.type=be.default(a)?a:a.uri),u&&(y.partOf=be.default(u)?u:u.uri),o&&(y.offset=o),l&&(y.limit=l),p&&(y.direction=p),w&&(y.mode=w),b&&(y.identifier=b),q&&(y.uri=q),this._getMappingsQueue().catch(P=>{throw new Ee({message:"Could not get mappings from local storage",relatedError:P})}).then(({mappings:P,done:H})=>{H();let K=(F,Z)=>F.uri==Z||Z&&F.notation&&F.notation[0].toLowerCase()==Z.toLowerCase();if((y.from||y.to)&&(P=P.filter(F=>{let Z=Le.default.conceptsOfMapping(F,"from").find(G=>K(G,y.from))!=null,te=Le.default.conceptsOfMapping(F,"to").find(G=>K(G,y.from))!=null,O=Le.default.conceptsOfMapping(F,"from").find(G=>K(G,y.to))!=null,ee=Le.default.conceptsOfMapping(F,"to").find(G=>K(G,y.to))!=null;return y.direction=="backward"?y.mode=="or"?y.from&&te||y.to&&O:(!y.from||te)&&(!y.to||O):y.direction=="both"?y.mode=="or"?y.from&&(Z||te)||y.to&&(O||ee):(!y.from||Z)&&(!y.to||ee)||(!y.from||te)&&(!y.to||O):y.mode=="or"?y.from&&Z||y.to&&ee:(!y.from||Z)&&(!y.to||ee)})),(y.fromScheme||y.toScheme)&&(P=P.filter(F=>{let Z=Le.default.compare(F.fromScheme,y.fromScheme),te=Le.default.compare(F.toScheme,y.fromScheme),O=Le.default.compare(F.fromScheme,y.toScheme),ee=Le.default.compare(F.toScheme,y.toScheme);return y.direction=="backward"?y.mode=="or"?y.fromScheme&&te||y.toScheme&&O:(!y.fromScheme||te)&&(!y.toScheme||O):y.direction=="both"?y.mode=="or"?y.fromScheme&&(Z||te)||y.toScheme&&(O||ee):(!y.fromScheme||Z)&&(!y.toScheme||ee)||(!y.fromScheme||te)&&(!y.toScheme||O):y.mode=="or"?y.fromScheme&&Z||y.toScheme&&ee:(!y.fromScheme||Z)&&(!y.toScheme||ee)})),y.creator){let F=y.creator.split("|");P=P.filter(Z=>(Z.creator&&Z.creator.find(te=>F.includes(Le.default.prefLabel(te))||F.includes(te.uri)))!=null)}y.type&&(P=P.filter(F=>(F.type||[Le.default.defaultMappingType.uri]).includes(y.type))),y.partOf&&(P=P.filter(F=>F.partOf!=null&&F.partOf.find(Z=>Le.default.compare(Z,{uri:y.partOf}))!=null)),y.identifier&&(P=P.filter(F=>y.identifier.split("|").map(Z=>(F.identifier||[]).includes(Z)||F.uri==Z).reduce((Z,te)=>Z||te))),y.uri&&(P=P.filter(F=>F.uri==y.uri));let Q=P.length;return P=P.sort((F,Z)=>{let te=F.modified||F.created,O=Z.modified||Z.created;return O==null?-1:te==null?1:te>O?-1:1}),P=P.slice(y.offset||0),P=P.slice(0,y.limit),P._totalCount=Q,P})})}postMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue();if((!e.uri||!e.uri.startsWith(ji))&&(e.uri&&(e.identifier||(e.identifier=[]),e.identifier.push(e.uri)),e.uri=`${ji}${Li()}`),i.find(s=>s.uri==e.uri))throw n(),new W({parameter:"mapping",message:"Duplicate URI"});e.created||(e.created=new Date().toISOString()),e.modified||(e.modified=e.created),i.push(e),i=i.map(s=>Le.default.minifyMapping(s));try{return yield ur.default.setItem(this.localStorageKey,i),n(),e}catch(s){throw n(),s}})}putMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue(),s=i.findIndex(a=>a.uri==e.uri);if(s==-1)throw n(),new W({parameter:"mapping",message:"Mapping not found"});e.created||(e.created=i[s].created),e.modified=new Date().toISOString(),i[s]=e,i=i.map(a=>Le.default.minifyMapping(a));try{return yield ur.default.setItem(this.localStorageKey,i),n(),e}catch(a){throw n(),a}})}patchMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue(),s=i.findIndex(a=>a.uri==e.uri);if(s==-1)throw n(),new W({parameter:"mapping",message:"Mapping not found"});e.created||(e.created=i[s].created),e.modified=new Date().toISOString(),i[s]=Object.assign(i[s],e),i=i.map(a=>Le.default.minifyMapping(a));try{return yield ur.default.setItem(this.localStorageKey,i),n(),e}catch(a){throw n(),a}})}deleteMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue();try{return i=i.filter(s=>s.uri!=e.uri),i=i.map(s=>Le.default.minifyMapping(s)),yield ur.default.setItem(this.localStorageKey,i),n(),!0}catch(s){throw n(),s}})}};yr.providerName="LocalMappings";yr.stored=!0;var ft=fe(He(),1);var tr=class extends le{_prepare(){this._api.api&&this._api.status===void 0&&(this._api.status=or(this._api.api,"/status")),this.has.mappings=!0,this.has.concordances=!0,this.has.annotations=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){if(this._api.api){let e={mappings:"/mappings",concordances:"/concordances",annotations:"/annotations"};for(let t of Object.keys(e))this._api[t]===void 0&&(this._api[t]=or(this._api.api,e[t]))}this.has.mappings=this._api.mappings?{}:!1,this.has.mappings&&(this.has.mappings.read=!!re.default(this._config,"mappings.read",!0),this.has.mappings.create=!!re.default(this._config,"mappings.create"),this.has.mappings.update=!!re.default(this._config,"mappings.update"),this.has.mappings.delete=!!re.default(this._config,"mappings.delete"),this.has.mappings.anonymous=!!re.default(this._config,"mappings.anonymous")),this.has.concordances=this._api.concordances?{}:!1,this.has.concordances&&(this.has.concordances.read=!!re.default(this._config,"concordances.read"),this.has.concordances.create=!!re.default(this._config,"concordances.create"),this.has.concordances.update=!!re.default(this._config,"concordances.update"),this.has.concordances.delete=!!re.default(this._config,"concordances.delete")),this.has.annotations=this._api.annotations?{}:!1,this.has.annotations&&(this.has.annotations.read=!!re.default(this._config,"annotations.read"),this.has.annotations.create=!!re.default(this._config,"annotations.create"),this.has.annotations.update=!!re.default(this._config,"annotations.update"),this.has.annotations.delete=!!re.default(this._config,"annotations.delete")),this.has.auth=re.default(this._config,"auth.key")!=null,this._defaultParams={properties:"annotations"}}getMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});if(!e.uri||!e.uri.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});try{return yield this.axios($(R({},t),{url:e.uri,params:R(R({},this._defaultParams),t.params||{})}))}catch(s){if(re.default(s,"response.status")==404)return null;throw s}})}getMappings(Z){return j(this,null,function*(){var te=Z,{from:e,fromScheme:t,to:i,toScheme:n,creator:s,type:a,partOf:u,offset:o,limit:l,direction:p,mode:w,identifier:b,cardinality:q,annotatedBy:y,annotatedFor:P,annotatedWith:H,sort:K,order:Q}=te,F=J(te,["from","fromScheme","to","toScheme","creator","type","partOf","offset","limit","direction","mode","identifier","cardinality","annotatedBy","annotatedFor","annotatedWith","sort","order"]);let O={},ee=this._api.mappings;return e&&(O.from=be.default(e)?e:e.uri),t&&(O.fromScheme=be.default(t)?t:t.uri),i&&(O.to=be.default(i)?i:i.uri),n&&(O.toScheme=be.default(n)?n:n.uri),s&&(O.creator=be.default(s)?s:ft.default.prefLabel(s)),a&&(O.type=be.default(a)?a:a.uri),u&&(O.partOf=be.default(u)?u:u.uri),o&&(O.offset=o),l&&(O.limit=l),p&&(O.direction=p),q&&(O.cardinality=q),y&&(O.annotatedBy=y),P&&(O.annotatedFor=P),H&&(O.annotatedWith=H),w&&(O.mode=w),b&&(O.identifier=b),K&&(O.sort=K),Q&&(O.order=Q),this.axios($(R({},F),{method:"get",url:ee,params:R(R(R({},this._defaultParams),F.params||{}),O)}))})}postMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});return e=ft.default.minifyMapping(e),e=ft.default.addMappingIdentifiers(e),this.axios($(R({},t),{method:"post",url:this._api.mappings,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}putMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});e=ft.default.minifyMapping(e),e=ft.default.addMappingIdentifiers(e);let s=e.uri;if(!s||!s.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"put",url:s,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}patchMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});let s=e.uri;if(!s||!s.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"patch",url:s,data:ar.default(e,"uri"),params:R(R({},this._defaultParams),t.params||{})}))})}deleteMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});let s=e.uri;if(!s||!s.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});return yield this.axios($(R({},t),{method:"delete",url:s})),!0})}getAnnotations(i){return j(this,null,function*(){var n=i,{target:e}=n,t=J(n,["target"]);return e&&xe.default(t,"params.target",e),this.axios($(R({},t),{method:"get",url:this._api.annotations}))})}postAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);return this.axios($(R({},t),{method:"post",url:this._api.annotations,data:e}))})}putAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);let s=e.id;if(!s||!s.startsWith(this._api.annotations))throw new W({parameter:"annotation",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"put",url:s,data:e}))})}patchAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);let s=e.id;if(!s||!s.startsWith(this._api.annotations))throw new W({parameter:"annotation",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"patch",url:s,data:e}))})}deleteAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);let s=e.id;if(!s||!s.startsWith(this._api.annotations))throw new W({parameter:"annotation",message:"URI doesn't seem to be part of this registry."});return yield this.axios($(R({},t),{method:"delete",url:s})),!0})}getConcordances(e){return j(this,null,function*(){return this.axios($(R({},e),{method:"get",url:this._api.concordances}))})}postConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});return this.axios($(R({},t),{method:"post",url:this._api.concordances,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}putConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});let s=e.uri;if(!s||!s.startsWith(this._api.concordances))throw new W({parameter:"concordance",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"put",url:s,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}patchConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});let s=e.uri;if(!s||!s.startsWith(this._api.concordances))throw new W({parameter:"concordance",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"patch",url:s,data:ar.default(e,"uri"),params:R(R({},this._defaultParams),t.params||{})}))})}deleteConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});let s=e.uri;if(!s||!s.startsWith(this._api.concordances))throw new W({parameter:"concordance",message:"URI doesn't seem to be part of this registry."});return yield this.axios($(R({},t),{method:"delete",url:s})),!0})}};tr.providerName="MappingsApi";tr.stored=!0;var ct=fe(He(),1);var xs={},_r=class extends le{get _cache(){return xs[this.uri]}_prepare(){xs[this.uri]=[],this._occurrencesSupportedSchemes=[],this.has.occurrences=!0,this.has.mappings=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_occurrencesIsSupported(e){return j(this,null,function*(){if(!(this._occurrencesSupportedSchemes&&this._occurrencesSupportedSchemes.length))try{let i=or(this._api.api,"voc"),n=yield this.axios({method:"get",url:i});this._occurrencesSupportedSchemes=n||[]}catch(i){}let t=!1;for(let i of this._occurrencesSupportedSchemes)ct.default.compare(e,i)&&(t=!0);return t})}getMappings(e){return j(this,null,function*(){let t=yield this.getOccurrences(e),i=e.from,n=re.default(i,"inScheme[0]")||e.fromScheme,s=e.to,a=re.default(s,"inScheme[0]")||e.toScheme,u=[];for(let o of t){if(!o)continue;let l={};l.from=re.default(o,"memberSet[0]"),l.from?l.from={memberSet:[l.from]}:l.from=null,l.fromScheme=re.default(o,"memberSet[0].inScheme[0]"),l.to=re.default(o,"memberSet[1]"),l.to?l.to={memberSet:[l.to]}:l.to={memberSet:[]},l.toScheme=re.default(o,"memberSet[1].inScheme[0]"),(i&&ct.default.compare(i,re.default(l,"to.memberSet[0]"))||s&&ct.default.compare(s,re.default(l,"from.memberSet[0]")))&&([l.from,l.fromScheme,l.to,l.toScheme]=[l.to,l.toScheme,l.from,l.fromScheme]),!l.fromScheme&&n&&(l.fromScheme=n),!l.toScheme&&a&&(l.toScheme=a),l.type=[ct.default.defaultMappingType.uri],l._occurrence=o,l=ct.default.addMappingIdentifiers(l),u.push(l)}return u._url=t._url,u})}getOccurrences(a){return j(this,null,function*(){var u=a,{from:e,to:t,concepts:i,threshold:n=0}=u,s=J(u,["from","to","concepts","threshold"]);let o=[];i=(i||[]).concat([e,t]).filter(y=>!!y);for(let y of i)o.push(this._occurrencesIsSupported(re.default(y,"inScheme[0]")).then(P=>P&&y.uri?y.uri:null));let l=yield Promise.all(o);if(l=l.filter(y=>y!=null),l.length==0)throw new W({parameter:"concepts"});o=[];for(let y of l)o.push(this._getOccurrences($(R({},s),{params:{member:y,scheme:"*",threshold:n}})));let p=yield Promise.all(o),w=ss.default([],...p),b=[],q=[];for(let y=0;y<w.length;y+=1){let P=w[y];if(!P)continue;let H=P.memberSet.reduce((K,Q)=>K.concat(Q.uri),[]).sort().join(" ");b.includes(H)?q.push(y):b.push(H)}return q.forEach(y=>{delete w[y]}),w=w.filter(y=>y!=null),w=w.sort((y,P)=>parseInt(P.count||0)-parseInt(y.count||0)),w._url=p.map(y=>y._url),w})}_getOccurrences(e){return j(this,null,function*(){let t=this._cache.find(n=>rr.default(n.config.params,e.params));if(t)return t.data;let i=yield this.axios($(R({},e),{method:"get",url:this._api.api}));return this._cache.push({config:e,data:i}),this._cache.length>20&&(xs[this.uri]=this._cache.slice(this._cache.length-20)),i})}};_r.providerName="OccurrencesApi";_r.stored=!1;var Dr=fe(He(),1);var ir=class extends le{_prepare(){this._api.api&&this._api.status===void 0&&(this._api.status=or(this._api.api,"/status")),this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.types=!0,this.has.suggest=!0,this.has.search=!0,this.has.auth=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){if(this._api.api){let e={schemes:"/voc",top:"/voc/top",concepts:"/voc/concepts",data:"/data",narrower:"/narrower",ancestors:"/ancestors",types:"/types",suggest:"/suggest",search:"/search"};for(let t of Object.keys(e))this._api[t]===void 0&&(this._api[t]=or(this._api.api,e[t]))}this.has.schemes=!!this._api.schemes,!this.has.schemes&&Array.isArray(this.schemes)&&(this.has.schemes=!0),this.has.top=!!this._api.top,this.has.data=!!this._api.data,this.has.concepts=!!this._api.concepts||this.has.data,this.has.narrower=!!this._api.narrower,this.has.ancestors=!!this._api.ancestors,this.has.types=!!this._api.types,this.has.suggest=!!this._api.suggest,this.has.search=!!this._api.search,this.has.auth=re.default(this._config,"auth.key")!=null,this._defaultParams={properties:"+created,issued,modified,editorialNote,scopeNote"}}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){return!e||!t?null:{api:e,schemes:[t]}}_getSchemeUri(e){return j(this,null,function*(){this._approvedSchemes=this._approvedSchemes||[],this._rejectedSchemes=this._rejectedSchemes||[];let t=this._approvedSchemes.find(s=>Dr.default.compare(e,s));if(t)return t.uri;if(this._rejectedSchemes.find(s=>Dr.default.compare(e,s)))return null;let n=(yield this.getSchemes({params:{uri:Dr.default.getAllUris(e).join("|")}})).find(s=>Dr.default.compare(s,e));return n?(this._approvedSchemes.push({uri:n.uri,identifier:Dr.default.getAllUris(e)}),n.uri):(this._rejectedSchemes.push({uri:e.uri,identifier:e.identifier}),null)})}getSchemes(e){return j(this,null,function*(){if(!this._api.schemes){if(Array.isArray(this.schemes))return this.schemes;throw new De}let t=yield this.axios($(R({},e),{method:"get",url:this._api.schemes,params:R($(R({},this._defaultParams),{limit:500}),e.params||{})}));return Array.isArray(this.schemes)?Nr(t.filter(i=>Dr.default.isContainedIn(i,this.schemes)),t):t})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!this._api.top)throw new De;if(!e)throw new W({parameter:"scheme"});let s=yield this._getSchemeUri(e);if(!s)throw new W({parameter:"scheme",message:"Requested vocabulary seems to be unsupported by this API."});return Array.isArray(this._api.top)?this._api.top:this.axios($(R({},t),{method:"get",url:this._api.top,params:$(R($(R({},this._defaultParams),{limit:1e4}),t.params||{}),{uri:s})}))})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);if(this.has.data===!1)throw new De;if(!e)throw new W({parameter:"concepts"});Array.isArray(e)||(e=[e]);let s=e.map(a=>a.uri).filter(a=>a!=null);return this.axios($(R({},t),{method:"get",url:this._api.data,params:$(R($(R({},this._defaultParams),{limit:500}),t.params||{}),{uri:s.join("|")})}))})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!this._api.narrower)throw new De;if(!e||!e.uri)throw new W({parameter:"concept"});return this.axios($(R({},t),{method:"get",url:this._api.narrower,params:$(R($(R({},this._defaultParams),{limit:1e4}),t.params||{}),{uri:e.uri})}))})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!this._api.ancestors)throw new De;if(!e||!e.uri)throw new W({parameter:"concept"});return this.axios($(R({},t),{method:"get",url:this._api.ancestors,params:$(R($(R({},this._defaultParams),{limit:1e4}),t.params||{}),{uri:e.uri})}))})}suggest(a){return j(this,null,function*(){var u=a,{use:e="notation,label",types:t=[],sort:i="score",params:n={}}=u,s=J(u,["use","types","sort","params"]);return this._search($(R({},s),{endpoint:"suggest",params:$(R({},n),{type:t.join("|"),use:e,sort:i})}))})}search(n){return j(this,null,function*(){var s=n,{types:e=[],params:t={}}=s,i=J(s,["types","params"]);return this._search($(R({},i),{endpoint:"search",params:$(R({},t),{type:e.join("|")})}))})}vocSuggest(s){return j(this,null,function*(){var a=s,{use:e="notation,label",sort:t="score",params:i={}}=a,n=J(a,["use","sort","params"]);return this._search($(R({},n),{endpoint:"voc-suggest",params:$(R({},i),{use:e,sort:t})}))})}vocSearch(e){return j(this,null,function*(){return this._search($(R({},e),{endpoint:"voc-search"}))})}_search(l){return j(this,null,function*(){var p=l,{endpoint:e,scheme:t,search:i,limit:n,offset:s,params:a,url:u}=p,o=J(p,["endpoint","scheme","search","limit","offset","params","url"]);if(u=u!=null?u:this._api[e],!u)throw new De;if(!i)throw new W({parameter:"search"});n=n||this._jskos.suggestResultLimit||100,s=s||0;let w=t&&(yield this._getSchemeUri(t));return u=u.replace("{searchTerms}",i),this.axios($(R({},o),{params:$(R(R({},this._defaultParams),a),{limit:n,count:n,offset:s,search:i,query:i,voc:w}),method:"get",url:u}))})}getTypes(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!this._api.types)throw new De;if(Array.isArray(this._api.types))return this._api.types;let s=e&&(yield this._getSchemeUri(e));return s&&xe.default(t,"params.uri",s),this.axios($(R({},t),{method:"get",url:this._api.types}))})}};ir.providerName="ConceptApi";ir.providerType="http://bartoc.org/api-type/jskos";var $t=fe(He(),1);var Ss={},wr=class extends le{get _cache(){return Ss[this.uri]}_prepare(){Ss[this.uri]=[],this.has.mappings=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}getMappings(s){return j(this,null,function*(){var a=s,{from:e,to:t,mode:i}=a,n=J(a,["from","to","mode"]);let u=[];Ie.default(this.schemes)&&(u=this.schemes);let o,l,p=re.default(e,"inScheme[0]"),w=re.default(t,"inScheme[0]"),b,q;if(!e||$t.default.isContainedIn(p,u)?(o=!0,l=t,b=w,q=u.find(O=>$t.default.compare(O,p))||u[0]):(o=!1,l=e,b=p,q=u.find(O=>$t.default.compare(O,w))||u[0]),i!="or")return[];if(!this._api.api)throw new De;if(!l)throw new W({parameter:o?"to":"from"});let y=$t.default.languagePreference.selectLanguage(l.prefLabel);if(!y)throw new W({parameter:o?"to":"from",message:"Missing language"});let P=re.default(l,`altLabel.${y}`,[]);be.default(P)&&(P=[P]);let H=re.default(l,`prefLabel.${y}`),K=P.concat([H]);K=[H];let{url:Q,data:F}=yield this._getReconciliationResults($(R({},n),{labels:K,language:y}));F=[].concat(...Object.values(F).map(O=>O.result)).filter(O=>O),F=F.sort((O,ee)=>O.score!=ee.score?ee.score-O.score:O.match!=ee.match?O.match?-1:1:O.id.length-ee.id.length);let Z=re.default(q,"namespace",""),te=F.map(O=>({fromScheme:b,from:{memberSet:[l]},toScheme:q,to:{memberSet:[{uri:Z+O.id}]},type:[O.match?"http://www.w3.org/2004/02/skos/core#exactMatch":O.score>=80?"http://www.w3.org/2004/02/skos/core#closeMatch":"http://www.w3.org/2004/02/skos/core#mappingRelation"]}));return o&&(te=te.map(O=>Object.assign(O,{fromScheme:O.toScheme,from:O.to,toScheme:O.fromScheme,to:O.from}))),te._url=Q,te})}_getReconciliationResults(n){return j(this,null,function*(){var s=n,{labels:e,language:t}=s,i=J(s,["labels","language"]);e=e.sort();let a=this._cache.find(q=>rr.default(q.labels,e)&&q.language==t);if(a)return a;let u={},o=0;for(let q of e)u[`q${o}`]={query:q},o+=1;let l=this._api.api;t&&(l=l.replace("{language}",t));let p=`queries=${encodeURIComponent(JSON.stringify(u))}`;xe.default(i,["headers","Content-Type"],"application/x-www-form-urlencoded");let w=yield this.axios($(R({},i),{method:"post",url:l,data:p}));w=w||{};let b={labels:e,language:t,data:w,url:`${l}${l.includes("?")?"&":"?"}${p}`};return this._cache.push(b),this._cache.length>20&&(Ss[this.uri]=this._cache.slice(this._cache.length-20)),b})}};wr.providerName="ReconciliationApi";wr.stored=!1;var lt=fe(He(),1);var br=class extends le{_prepare(){this._cache=[],this.has.mappings=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}supportsScheme(e){return super.supportsScheme(e)&&re.default(e,"_registry.has.search",!1)}getMappings(u){return j(this,null,function*(){var o=u,{from:e,to:t,mode:i,selected:n,limit:s=10}=o,a=J(o,["from","to","mode","selected","limit"]);if(i!="or")return[];if(!n)throw new W({parameter:"selected"});let l=[];e&&this.supportsScheme(n.scheme[!1])?l.push(this._getMappings($(R({},a),{concept:e,sourceScheme:n.scheme[!0],targetScheme:n.scheme[!1],limit:s}))):l.push(Promise.resolve([])),t&&this.supportsScheme(n.scheme[!0])?l.push(this._getMappings($(R({},a),{concept:t,sourceScheme:n.scheme[!1],targetScheme:n.scheme[!0],limit:s,swap:!0}))):l.push(Promise.resolve([]));let[p,w]=yield Promise.all(l);for(w=w.filter(b=>!p.find(q=>lt.default.compareMappingMembers(b,q)));p.length+w.length>s;)w.length>=p.length?w=w.slice(0,-1):p=p.slice(0,-1);return rs.default(p,w)})}_getMappings(u){return j(this,null,function*(){var o=u,{concept:e,sourceScheme:t,targetScheme:i,limit:n,swap:s=!1}=o,a=J(o,["concept","sourceScheme","targetScheme","limit","swap"]);if(!e||!t||!i)return[];if(lt.default.compare(t,i))return[];let l=lt.default.languagePreference.selectLanguage(e.prefLabel)||this._defaultLanguages[0],p=lt.default.prefLabel(e,{fallbackToUri:!1,language:l});if(!p)return[];let w=/^[\s\wäüöÄÜÖß]*\w/.exec(p);p=w?w[0]:p;let q=(yield this._getResults($(R({},a),{label:p,targetScheme:i,limit:n}))).map(y=>({fromScheme:t,from:{memberSet:[e]},toScheme:i,to:{memberSet:[y]},type:["http://www.w3.org/2004/02/skos/core#mappingRelation"]}));return s&&(q=q.map(y=>Object.assign(y,{fromScheme:y.toScheme,from:y.to,toScheme:y.fromScheme,to:y.from}))),q})}_getResults(s){return j(this,null,function*(){var a=s,{label:e,targetScheme:t,limit:i}=a,n=J(a,["label","targetScheme","limit"]);var w;let u=(this._cache[t.uri]||{})[e];if(u&&u._limit>=i)return u;let o=re.default(t,"_registry");if(!o||o.has.search===!1)return[];let l=(w=this._jskos.overrides.find(b=>lt.default.compare(b,t)))==null?void 0:w.search,p=yield o.search($(R({},n),{url:l,search:e,scheme:t,limit:i}));return this._cache[t.uri]||(this._cache[t.uri]={}),this._cache[t.uri][e]=p,this._cache[t.uri][e]._limit=i,p})}};br.providerName="LabelSearchSuggestion";br.stored=!1;var je=fe(He(),1);var xr=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.types=!0,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){if(!e||!t)return null;let i={},n=e.match(/(.+\/)([^/]+)\/$/);return n?(i.api=n[1]+"rest/v1/",t.VOCID=n[2],i.schemes=[t],i):null}get _language(){return this.languages[0]||this._defaultLanguages[0]||"en"}_getApiUrl(e,t,i){let n=e&&e.VOCID||re.default(this.schemes.find(a=>je.default.compare(a,e)),"VOCID");if(!n)throw new W({parameter:"scheme",message:"Missing scheme or VOCID property on scheme"});t=t||"",i=i||{},i.lang||(i.lang=this._language);let s=Object.keys(i).map(a=>`${a}=${encodeURIComponent(i[a])}`).join("&");return`${this._api.api}${n}${t}${s?"?"+s:""}`}_getDataUrl(e,{addFormatParameter:t=!0}={}){let i=re.default(e,"inScheme[0]");if(!e||!e.uri)throw new W({parameter:"concept",message:"Missing concept URI"});return this._getApiUrl(i,"/data",t?{format:"application/json"}:{})}_getSchemeUri(e){return j(this,null,function*(){this._approvedSchemes=this._approvedSchemes||[],this._rejectedSchemes=this._rejectedSchemes||[];let t=this._approvedSchemes.find(a=>je.default.compare(e,a));if(t)return t.uri;if(this._rejectedSchemes.find(a=>je.default.compare(e,a)))return null;let i=this._getApiUrl(e,"/"),s=(yield this.axios({method:"get",url:i})).conceptschemes.find(a=>je.default.compare(a,e));return s?(this._approvedSchemes.push({uri:s.uri,identifier:je.default.getAllUris(e)}),s.uri):(this._rejectedSchemes.push({uri:e.uri,identifier:e.identifier}),null)})}_toJskosConcept(e,{concept:t,scheme:i,result:n,language:s}={}){if(!e)return null;t=je.default.deepCopy(t||{}),s=s||e.lang||"en",t.uri=e.uri,i&&(t.inScheme=[i]);let a=e.matchedPrefLabel||e.prefLabel||e.label;if(be.default(a))xe.default(t,`prefLabel.${s}`,a);else{a&&!Ie.default(a)&&(a=[a]);for(let l of a||[])xe.default(t,`prefLabel.${l.lang}`,l.value)}let u=e.altLabel;if(be.default(u))xe.default(t,`altLabel.${s}`,[u]);else{u&&!Ie.default(u)&&(u=[u]);for(let l of u||[])re.default(t,`altLabel.${l.lang}`)?(t.altLabel[l.lang].push(l.value),t.altLabel[l.lang]=gr.default(t.altLabel[l.lang])):xe.default(t,`altLabel.${l.lang}`,[l.value])}let o=e.notation||e["skos:notation"]||je.default.notation(t);o&&(t.notation=[o.value||o]),e.broader&&(Ie.default(e.broader)||(e.broader=[e.broader]),t.broader=e.broader.map(l=>be.default(l)?{uri:l}:l)),e.hasChildren===!0?t.narrower=[null]:e.hasChildren===!1&&(t.narrower=[]),e.type&&!Ie.default(e.type)&&(e.type=[e.type]),t.type=t.type||[];for(let l of e.type||[]){if(!je.default.isValidUri(l))continue;let p=l.slice(0,l.indexOf(":"));n&&n["@context"]&&n["@context"][p]&&(l=l.replace(p+":",n["@context"][p])),t.type.push(l)}return t.type=gr.default(t.type),t.type.length||(t.type=["http://www.w3.org/2004/02/skos/core#Concept"]),t}getSchemes(t){return j(this,null,function*(){var e=J(t,[]);let i=[];for(let n of this.schemes||[]){let s=this._getApiUrl(n,"/"),u=(yield this.axios($(R({},e),{method:"get",url:s}))).conceptschemes.find(l=>je.default.compare(l,n)),o=u&&(u.prefLabel||u.label||u.title);o&&xe.default(n,`prefLabel.${this._language}`,o),i.push(n),this._approvedSchemes=this._approvedSchemes||[],this._approvedSchemes.find(l=>je.default.compare(n,l))||this._approvedSchemes.push({uri:u.uri,identifier:je.default.getAllUris(n)})}return i})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);let s=this._getApiUrl(e,"/topConcepts"),a=yield this._getSchemeUri(e);if(!a)throw new W({parameter:"scheme",message:"Missing or unsupported scheme or VOCID property on scheme"});xe.default(t,"params.scheme",a);let u=yield this.axios($(R({},t),{method:"get",url:s})),o=[];for(let l of u.topconcepts||[]){let p=this._toJskosConcept(l,{scheme:e,language:this._language});p.topConceptOf=[e],o.push(p)}return o})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);Ie.default(e)||(e=[e]),e=e.map(a=>({uri:a.uri,inScheme:a.inScheme}));let s=[];for(let a of e){let u=this._getDataUrl(a,{addFormatParameter:!1});if(!u)continue;let o=yield this.axios($(R({},t),{method:"get",url:u,params:{uri:a.uri,format:"application/json"}})),l=o&&o.graph&&o.graph.find(p=>je.default.compare(p,a));if(l){let p=this._toJskosConcept(l,{concept:a,result:o});for(let w of["broader","narrower"]){let b=l[w]||p[w];b&&!Ie.default(b)&&(b=[b]),b||(b=[]),p[w]=b.map(q=>this._toJskosConcept(o.graph.find(y=>je.default.compare(y,q)),{scheme:a.inScheme[0],result:o}))}p.ancestors=[],s.push(p)}}return s})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});let s=e.inScheme[0],a=this._getApiUrl(s,"/children");return xe.default(t,"params.uri",e.uri),((yield this.axios($(R({},t),{method:"get",url:a}))).narrower||[]).map(l=>this._toJskosConcept(l,{scheme:s}))})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});let s=e.inScheme[0],a=this._getApiUrl(s,"/broaderTransitive");xe.default(t,"params.uri",e.uri);let u=yield this.axios($(R({},t),{method:"get",url:a})),o=[],l=e.uri;for(;l;){if(l!=e.uri){let w=re.default(u,`broaderTransitive["${l}"]`);o=o.concat([w])}l=re.default(u,`broaderTransitive["${l}"].broader[0]`)}return o.map(w=>this._toJskosConcept(w,{scheme:s})).filter(w=>w.uri!=e.uri)})}suggest(e){return j(this,null,function*(){e._raw=!0;let t=yield this.search(e),i=[e.search,[],[],[]];for(let n of t){let s=je.default.notation(n),a=je.default.prefLabel(n);i[1].push((s?s+" ":"")+a),i[2].push(""),i[3].push(n.uri)}return t._totalCount!=null?i._totalCount=t._totalCount:i._totalCount=t.length,i})}search(a){return j(this,null,function*(){var u=a,{search:e,scheme:t,limit:i,types:n=[]}=u,s=J(u,["search","scheme","limit","types"]);let o=this._getApiUrl(t,"/search");return xe.default(s,"params.query",`${e}*`),xe.default(s,"params.unique",1),xe.default(s,"params.maxhits",i||100),xe.default(s,"params.type",n.join(" ")),((yield this.axios($(R({},s),{method:"get",url:o}))).results||[]).map(w=>this._toJskosConcept(w,{scheme:t}))})}getTypes(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);let s=this._getApiUrl(e,"/types"),a=[],u=yield this.axios($(R({},t),{method:"get",url:s}));for(let o of u&&u.types||[])o.uri!="http://www.w3.org/2004/02/skos/core#Concept"&&(o.label&&(o.prefLabel={[u["@context"]["@language"]]:o.label},delete o.label),a.push(o));return a._url=s,a})}};xr.providerName="SkosmosApi";xr.providerType="http://bartoc.org/api-type/skosmos";var fr=fe(He(),1),Ni=fe(ii(),1);var Di="http://id.loc.gov/authorities/",Ui=[{uri:`${Di}subjects`,identifier:["http://bartoc.org/en/node/454"],notation:["LCSH"],concepts:[null],topConcepts:[]},{uri:`${Di}names`,identifier:["http://bartoc.org/en/node/18536"],notation:["LCNAF"],concepts:[null],topConcepts:[]}],fd=`${Di}classification`;function cd(r){let e={};e.uri=r["@id"],e.notation=(r["http://www.loc.gov/mads/rdf/v1#code"]||[]).map(n=>n["@value"]);let t=r["http://www.loc.gov/mads/rdf/v1#authoritativeLabel"]||r["http://www.w3.org/2000/01/rdf-schema#label"]||[];t.length&&(e.prefLabel={},e.prefLabel[t[0]["@language"]||"en"]=t[0]["@value"]);let i=r["http://www.w3.org/2004/02/skos/core#altLabel"]||[];i.length&&(e.altLabel={en:i.map(n=>n["@value"])});for(let n of r["http://www.w3.org/2000/01/rdf-schema#comment"]||[])e.definition=e.definition||{},e.definition.en=e.definition.en||[],e.definition.en.push(n["@value"]);return e}function _E(r){let e=cd(r);return e.namespace=e.uri+"/",e.type=["http://www.w3.org/2004/02/skos/core#ConceptScheme"],e}var As=r=>e=>!e||!r||!r.namespace?!0:e.uri.startsWith(r.namespace);function wE(r,{scheme:e}){let t=cd(r);t.type=["http://www.w3.org/2004/02/skos/core#Concept"],t.inScheme=e?[e]:(r["http://www.loc.gov/mads/rdf/v1#isMemberOfMADSScheme"]||[]).map(s=>Ui.find(a=>a.uri===s["@id"])),(!t.inScheme.length||!t.inScheme[0])&&delete t.inScheme;let i=r["http://www.loc.gov/mads/rdf/v1#hasNarrowerAuthority"]||fr.default.compare(t.inScheme[0],{uri:fd})&&r["http://www.loc.gov/mads/rdf/v1#hasMADSCollectionMember"]||[];t.narrower=i.map(s=>({uri:s["@id"]})).filter(As(t.inScheme&&t.inScheme[0]));let n=r["http://www.loc.gov/mads/rdf/v1#hasBroaderAuthority"]||fr.default.compare(t.inScheme[0],{uri:fd})&&r["http://www.loc.gov/mads/rdf/v1#isMemberOfMADSCollection"]||[];return t.broader=n.map(s=>({uri:s["@id"]})).filter(As(t.inScheme&&t.inScheme[0])),t}var Sr=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!1,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!1,this.has.ancestors=!1,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}static _registryConfigForBartocApiConfig({scheme:e}={}){return!e||!Ui.find(t=>fr.default.compare(t,e))?null:{schemes:[e]}}getSchemes(){return j(this,null,function*(){let e=[];for(let t of yield Promise.all(Ui.filter(i=>!this.schemes||!this.schemes.length||this.schemes.find(n=>fr.default.compare(i,n))).map(i=>(0,Ni.default)({method:"get",url:`${i.uri.replace("http:","https:")}.json`}).then(({status:n,data:s})=>{if(n===200){let a=s.find(u=>i.uri===u["@id"]);if(a)return a=fr.default.merge(_E(a),i),a.topConcepts=(a.topConcepts||[]).filter(u=>u),a}return null}))))t&&e.push(t);return e})}getConcepts(t){return j(this,arguments,function*({concepts:e}){Array.isArray(e)||(e=[e]);let i=[];for(let n of yield Promise.all(e.map(s=>(0,Ni.default)({method:"get",url:`${s.uri.replace("http:","https:")}.json`}).then(({status:a,data:u})=>{if(a===200){let o=u.find(l=>s.uri===l["@id"]);return o?wE(o,{scheme:s.inScheme&&s.inScheme[0]}):null}}))))n&&i.push(n);return i})}suggest(e){return j(this,null,function*(){let t=yield this.search(e);return[e.search,t.map(i=>fr.default.prefLabel(i,{fallbackToUri:!0})),[],t.map(i=>i.uri)]})}search(s){return j(this,arguments,function*({search:e,scheme:t,limit:i,offset:n}){let a=fr.default.getAllUris(t).find(o=>o.startsWith(Di));if(!a||!Ui.find(o=>fr.default.compare(o,{uri:a})))throw new W({parameter:"scheme",message:"provided scheme is not supported (yet)"});if(!e)throw new W({parameter:"search",message:"parameter is empty or missing"});i=i||this._jskos.suggestResultLimit||100,n=n||0;let{data:u}=yield(0,Ni.default)({method:"get",url:`${a}/suggest2`.replace("http:","https:"),params:{q:e,count:i||100,offset:n,searchtype:"keyword"}});return(u.hits||[]).map(o=>({uri:o.uri,notation:[o.token],prefLabel:{en:o.aLabel},inScheme:[t]})).filter(As(t))})}};Sr.providerName="LocApi";Sr.providerType="http://bartoc.org/api-type/loc";var Br=fe(He(),1),hd=fe(qs(),1);function Fi(r){return r.replace(/\\u[\dA-F]{4}/gi,function(e){return String.fromCharCode(parseInt(e.replace(/\\u/g,""),16))})}var Fr={},Ar=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1}),Fr[this.uri]={index:{},conceptCache:{},schemeCache:{}}}get _index(){return Fr[this.uri]&&Fr[this.uri].index}get _conceptCache(){return Fr[this.uri]&&Fr[this.uri].conceptCache}get _schemeCache(){return Fr[this.uri]&&Fr[this.uri].schemeCache}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){return!e||!t?null:{schemes:[{uri:e,identifier:Br.default.getAllUris(t).filter(n=>n!==e)}]}}_loadScheme(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);let s=Br.default.getAllUris(e);for(let y of s)if(this._schemeCache[y])return this._schemeCache[y];let a=this.schemes.find(y=>Br.default.compare(y,e));if(!a||!a.uri)throw new Qe({message:`Tried to load unsupported scheme (${e&&e.uri})`});let u=a.uri;s=gr.default(s.concat(Br.default.getAllUris(a)));let o=".json";u.endsWith("/")&&(o="index.json");let l=yield this.axios($(R({},t),{url:`${u}${o}`,_skipAdditionalParameters:!0}));if(l.id!==u)throw new Qe({message:"Skohub URL did not return expected concept scheme"});let{title:p,preferredNamespaceUri:w,hasTopConcept:b,description:q}=l;e={uri:u,identifier:s.filter(y=>y!==u)},e.prefLabel=p,Object.keys(e.prefLabel||{}).forEach(y=>{e.prefLabel[y]=Fi(e.prefLabel[y])}),e.namespace=w,e.topConcepts=(b||[]).map(y=>this._toJskosConcept(y)),e.concepts=[null],q&&(e.definition=q,Object.keys(e.definition).forEach(y=>{e.definition[y]=[Fi(e.definition[y])]}));for(let y of Object.keys(e).filter(P=>!e[P]))delete e[y];for(let y of s)this._schemeCache[y]=e;return e})}_loadConcept(i){return j(this,null,function*(){var n=i,{uri:e}=n,t=J(n,["uri"]);if(this._conceptCache[e])return this._conceptCache[e];try{let s=yield this.axios($(R({},t),{url:`${e}.json`,_skipAdditionalParameters:!0}));if(s.id!==e)throw new Qe({message:"Skohub URL did not return expected concept URI"});let a=this._toJskosConcept(s);return this._conceptCache[e]=a,a}catch(s){return null}})}_toJskosConcept(e){let t={uri:e.id};return t.prefLabel=e.prefLabel,Object.keys(t.prefLabel||{}).forEach(i=>{t.prefLabel[i]=Fi(t.prefLabel[i])}),t.narrower=(e.narrower||[]).map(i=>this._toJskosConcept(i)),t.notation=e.notation||[],e.broader&&e.broader.id&&(t.broader=[{uri:e.broader.id}]),e.inScheme&&e.inScheme.id&&(t.inScheme=[{uri:e.inScheme.id}]),e.scopeNote&&(t.scopeNote=e.scopeNote,Object.keys(t.scopeNote).forEach(i=>{t.scopeNote[i]=[Fi(t.scopeNote[i])]})),t}getSchemes(t){return j(this,null,function*(){var e=J(t,[]);return Promise.all(this.schemes.map(i=>this._loadScheme($(R({},e),{scheme:i}))))})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!e||!e.uri)throw new W({parameter:"scheme",message:"Missing scheme URI"});return e=yield this._loadScheme(R({scheme:e},t)),e.topConcepts||[]})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);return Ie.default(e)||(e=[e]),(yield Promise.all(e.map(({uri:s})=>this._loadConcept($(R({},t),{uri:s}))))).filter(Boolean)})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});if(e.ancestors&&e.ancestors[0]!==null)return e.ancestors;if(e=yield this._loadConcept($(R({},t),{uri:e.uri})),!e||!e.broader||!e.broader.length)return[];let s=e.broader[0];return[s].concat(yield this.getAncestors(R({concept:s},t))).map(a=>({uri:a.uri}))})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});return e.narrower&&e.narrower[0]!==null||(e=yield this._loadConcept($(R({},t),{uri:e.uri}))),e.narrower})}search(n){return j(this,arguments,function*({search:e,scheme:t,limit:i=100}){if(t=yield this._loadScheme({scheme:t}),!t||!t.uri)throw new W({parameter:"scheme"});if(!e)throw new W({parameter:"search"});let s;this._index[t.uri]||(this._index[t.uri]={});for(let o of[""].concat(this.languages)){if(this._index[t.uri][o]){s=this._index[t.uri][o];break}if(this._index[t.uri][o]!==null)try{let l=o?`.${o}.index`:".index";t.uri.endsWith("/")&&(l=`index${l}`);let p=yield this.axios({url:`${t.uri}${l}`,_skipAdditionalParameters:!0});if(p.length<100){this._index[t.uri][o]=null;continue}s=hd.default.create(),s.import(p),this._index[t.uri][o]=s;break}catch(l){this._index[t.uri][o]=null}}if(!s)throw new Qe({message:"Could not find search index for any of the available languages "+this.languages.join(",")});let a=s.search(e);return(yield this.getConcepts({concepts:a.map(o=>({uri:o}))})).slice(0,i)})}suggest(e){return j(this,null,function*(){e._raw=!0;let t=yield this.search(e),i=[e.search,[],[],[]];for(let n of t){let s=Br.default.notation(n),a=Br.default.prefLabel(n);i[1].push((s?s+" ":"")+a),i[2].push(""),i[3].push(n.uri)}return t._totalCount!=null?i._totalCount=t._totalCount:i._totalCount=t.length,i})}};Ar.providerName="Skohub";Ar.providerType="http://bartoc.org/api-type/skohub";var zt=fe(He(),1),pd=fe(qs(),1);var $e={},Or=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){this._scheme=null}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){return!e||!t?null:{api:e}}_schemeInfoToJSKOS(e){let t=e.labels.find(s=>s.lang==="x-uri").text,i={};e.labels.filter(s=>!s.lang.startsWith("x-")).forEach(s=>{i[s.lang]=s.text});let n={uri:t,prefLabel:i};return e.categories&&e.categories.length&&(n.topConcepts=[null]),e.category&&e.category.length&&(n.concepts=[null]),n}_categoryToJSKOS(e,{scheme:t,broader:i=[]}){if(!e||!t)return null;let n=e.ID,s=`${t.uri}/${n}`;if($e[t.uri].concepts[s])return $e[t.uri].concepts[s];let a={};e.labels.filter(o=>!o.lang.startsWith("x-")&&o.text).forEach(o=>{a[o.lang]=o.text.replace(`${n} `,""),$e[t.uri].searchIndex.add(s,a[o.lang])});let u={};return e.labels.filter(o=>!o.lang.startsWith("x-")&&o.description).forEach(o=>{u[o.lang]||(u[o.lang]=[]),u[o.lang].push(o.description)}),$e[t.uri].concepts[s]={uri:s,notation:[n],prefLabel:a,scopeNote:u,inScheme:[{uri:t.uri}],narrower:(e.categories||[]).map(o=>({uri:`${t.uri}/${o.ID}`})),broader:i},$e[t.uri].concepts[s]}_removeNarrower(e){return e&&Object.assign({},e,{narrower:e.narrower&&e.narrower.length?[null]:[]})}_loadSchemeData(e){return j(this,null,function*(){let t=yield this.axios($(R({},e),{method:"get",url:this._api.api,_skipAdditionalParameters:!0}));this._scheme=this._schemeInfoToJSKOS(t);let i=this._scheme.uri;$e[i]={schemeInfo:t,searchIndex:pd.default.create({tokenize:"full"}),concepts:{}};let n=(s,{broader:a=[]}={})=>{let u=this._categoryToJSKOS(s,{scheme:this._scheme,broader:a});(s.categories||[]).forEach(o=>n(o,{broader:[{uri:u.uri}]}))};t.categories.forEach(s=>n(s)),$e[i].topConcepts=t.categories.map(s=>this._categoryToJSKOS(s,{scheme:this._scheme}))})}getSchemes(){return j(this,arguments,function*(e={}){if(!this._api.api)throw new De;return this._scheme||(this._loadSchemeDataPromise||(this._loadSchemeDataPromise=this._loadSchemeData(e)),yield this._loadSchemeDataPromise),[this._scheme]})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!e||!e.uri)throw new W({parameter:"scheme",message:"Missing scheme URI"});if(this._scheme||(yield this.getSchemes(t)),!zt.default.compare(e,this._scheme))throw new W({parameter:"scheme",message:"Requested vocabulary seems to be unsupported by this API."});return $e[this._scheme.uri].topConcepts.map(this._removeNarrower)})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);return Ie.default(e)||(e=[e]),this._scheme||(yield this.getSchemes(t)),e.map(s=>$e[this._scheme.uri].concepts[s.uri]).map(this._removeNarrower)})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});if(e.ancestors&&e.ancestors[0]!==null)return e.ancestors;this._scheme||(yield this.getSchemes(t)),e=$e[this._scheme.uri].concepts[e.uri];let s=e&&e.broader&&e.broader[0];return s?[s].concat(yield this.getAncestors(R({concept:s},t))):[]})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});return e.narrower&&e.narrower[0]!==null?e.narrower:(this._scheme||(yield this.getSchemes(t)),e=$e[this._scheme.uri].concepts[e.uri],(e&&e.narrower||[]).map(s=>$e[this._scheme.uri].concepts[s.uri]).map(this._removeNarrower))})}search(n){return j(this,arguments,function*({search:e,scheme:t,limit:i=100}){if(!t||!t.uri)throw new W({parameter:"scheme"});if(!e)throw new W({parameter:"search"});if(!t||!t.uri)throw new W({parameter:"scheme",message:"Missing scheme URI"});if(this._scheme||(yield this.getSchemes()),!zt.default.compare(t,this._scheme))throw new W({parameter:"scheme",message:"Requested vocabulary seems to be unsupported by this API."});return(yield $e[this._scheme.uri].searchIndex.search(e)).map(a=>$e[this._scheme.uri].concepts[a]).map(this._removeNarrower).slice(0,i)})}suggest(e){return j(this,null,function*(){e._raw=!0;let t=yield this.search(e),i=[e.search,[],[],[]];for(let n of t){let s=zt.default.notation(n),a=zt.default.prefLabel(n);i[1].push((s?s+" ":"")+a),i[2].push(""),i[3].push(n.uri)}return t._totalCount!=null?i._totalCount=t._totalCount:i._totalCount=t.length,i})}};Or.providerName="MyCoRe";Or.providerType="http://bartoc.org/api-type/mycore";var nr={[le.providerName]:le,init(r){if(this[r.provider])return new this[r.provider](r);throw new Wr},addProvider(r){if(r.prototype instanceof le||r===le)this[r.providerName]=r;else throw new Wr}};nr.addProvider(ir);nr.addProvider(tr);Object.values(Wt).forEach(r=>{nr.addProvider(r)});var Cs={},Cr=class{constructor(e){this.config=e,this.axios=dd.default.create()}setConfig(e){this.config=e}get config(){return this._config}set config(e){e=e||{},e.registries=e.registries||[],e.registries=e.registries.map(t=>nr.init(t)).filter(t=>t),e.registries.forEach(t=>{t.cdk=this}),this._config=e}get providers(){return nr}createInstance(e){return new Cr(e)}loadConfig(e){return j(this,null,function*(){let t=yield this.axios.get(e);this.config=t.data})}loadBuildInfo(a){var u=a,{url:e,buildInfo:t=null,interval:i=6e4,callback:n}=u,s=J(u,["url","buildInfo","interval","callback"]);if(!e&&!this.config.cocodaBaseUrl)throw new Ee({message:"Could not determine URL to load build config."});return e||(e=`${this.config.cocodaBaseUrl}build-info.json`),this.repeat($(R({},s),{function:()=>j(this,null,function*(){return(yield this.axios.get(e,{headers:{"Cache-Control":"no-cache"}})).data}),interval:i,callback:(o,l,p)=>{o?n(o):(p||!p&&t&&!rr.default(l,t))&&n(null,l,p||t)}}))}getRegistryForUri(e){return this.config.registries.find(t=>t.uri==e)}initializeRegistry(e){return e=nr.init(e),e.cdk=this,e}addProvider(e){nr.addProvider(e)}static addProvider(e){nr.addProvider(e)}repeat({function:e,interval:t=15e3,callback:i,callImmediately:n=!0}={}){if(!e)throw new W({parameter:"function"});if(typeof e!="function")throw new W({parameter:"function",message:"function needs to be a function"});let s=()=>j(this,null,function*(){return e()});if(t=parseInt(t),isNaN(t))throw new W({parameter:"interval"});if(!i)throw new W({parameter:"callback"});if(typeof i!="function")throw new W({parameter:"callback",message:"callback needs to be a function"});let a={timer:null,result:null,error:null,isPaused:!1,interval:t},u=b=>{let q=a.result;rr.default(q,b)||(a.result=b,a.error=null,i(null,b,q))},o=b=>{a.error=b,i(b)},l=b=>{a.isPaused||(a.timer=setTimeout(()=>{b()},a.interval))},p=()=>s().then(u).catch(o).then(()=>l(p)),w=(b=n)=>{b?p():l(p)};return w(),{start:(...b)=>{a.isPaused=!1,w(...b)},stop:()=>{a.isPaused=!0,a.timer?clearTimeout(a.timer):setTimeout(()=>{a.timer&&clearTimeout(a.timer)},a.interval)},get isPaused(){return a.isPaused},get lastResult(){return a.result},get hasErrored(){return!!a.error},get interval(){return a.interval},set interval(b){a.interval=b}}}getSchemes(){return j(this,arguments,function*(e={}){let t=[],i=[];for(let n of this.config.registries)if(n.has.schemes!==!1){let s=n.getSchemes(e).then(a=>{for(let u of a){u._registry=n,u.__DETAILSLOADED__=1,u.type=u.type||["http://www.w3.org/2004/02/skos/core#ConceptScheme"];let o=t.find(b=>qr.default.compare(b,u)),l,p,w=!1;if(o){l=this.config.registries.indexOf(n),l!=-1&&(l=this.config.registries.length-l),p=this.config.registries.indexOf(re.default(o,"_registry")),p!=-1&&(p=this.config.registries.length-p);let b=u.concepts?u.concepts.length==0?-1:1:0,q=o.concepts?o.concepts.length==0?-1:1:0;b>q?w=!0:b<q?w=!1:w=p<l}if(!o||w){if(w){let b=t.findIndex(q=>qr.default.compare(q,o));b!=-1&&t.splice(b,1),u=qr.default.merge(u,ar.default(o,["concepts","topConcepts"]),{mergeUris:!0,skipPaths:["_registry"]})}u._registry=n,t.push(u)}else{let b=t.findIndex(q=>qr.default.compare(q,u));if(b!=-1){let q=t[b]._registry;t[b]=qr.default.merge(t[b],ar.default(u,["concepts","topConcepts"]),{mergeUris:!0,skipPaths:["_registry"]}),t[b]._registry=q}}}}).catch(a=>{console.warn("Couldn't load schemes for registry",n.uri,a)});i.push(s)}return yield Promise.all(i),t.forEach(n=>{let s=n._registry;delete n._registry;let a=this.registryForScheme(n);!a||a._api.api===s._api.api?n._registry=s:n._registry=a}),qr.default.sortSchemes(t.filter(Boolean))})}registryForScheme(e){let t=e._registry;if(t)return t;for(let i of e.API||[]){let n=i,{type:s}=n,a=J(n,["type"]);let u=a.url;if(Cs[u]){let o=Cs[u];return Array.isArray(o._jskos.schemes)&&!qr.default.isContainedIn(e,o._jskos.schemes)&&o._jskos.schemes.push(e),o}else{let o=Object.values(nr).find(p=>p.providerType===s);if(!o||!o._registryConfigForBartocApiConfig)continue;let l=o.providerName;if(a.scheme=e,a=nr[l]._registryConfigForBartocApiConfig(a),!a)continue;a.provider=l;try{if(t=this.initializeRegistry(a),t)return Cs[u]=t,t}catch(p){continue}}}return null}};var md=new Cr;function bE(r){Object.values(Wt).forEach(e=>(r||md).addProvider(e))}return am(xE);})();
|
|
8
|
+
var CDK=(()=>{var rm=Object.create;var mt=Object.defineProperty,tm=Object.defineProperties,im=Object.getOwnPropertyDescriptor,nm=Object.getOwnPropertyDescriptors,sm=Object.getOwnPropertyNames,Jt=Object.getOwnPropertySymbols,am=Object.getPrototypeOf,Ji=Object.prototype.hasOwnProperty,Fs=Object.prototype.propertyIsEnumerable;var Ds=(r,e,t)=>e in r?mt(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,R=(r,e)=>{for(var t in e||(e={}))Ji.call(e,t)&&Ds(r,t,e[t]);if(Jt)for(var t of Jt(e))Fs.call(e,t)&&Ds(r,t,e[t]);return r},$=(r,e)=>tm(r,nm(e));var gt=(r=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(r,{get:(e,t)=>(typeof require!="undefined"?require:e)[t]}):r)(function(r){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+r+'" is not supported')});var J=(r,e)=>{var t={};for(var i in r)Ji.call(r,i)&&e.indexOf(i)<0&&(t[i]=r[i]);if(r!=null&&Jt)for(var i of Jt(r))e.indexOf(i)<0&&Fs.call(r,i)&&(t[i]=r[i]);return t};var g=(r,e)=>()=>(e||r((e={exports:{}}).exports,e),e.exports),Vt=(r,e)=>{for(var t in e)mt(r,t,{get:e[t],enumerable:!0})},Bs=(r,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of sm(e))!Ji.call(r,n)&&n!==t&&mt(r,n,{get:()=>e[n],enumerable:!(i=im(e,n))||i.enumerable});return r};var fe=(r,e,t)=>(t=r!=null?rm(am(r)):{},Bs(e||!r||!r.__esModule?mt(t,"default",{value:r,enumerable:!0}):t,r)),om=r=>Bs(mt({},"__esModule",{value:!0}),r);var j=(r,e,t)=>new Promise((i,n)=>{var s=o=>{try{u(t.next(o))}catch(l){n(l)}},a=o=>{try{u(t.throw(o))}catch(l){n(l)}},u=o=>o.done?i(o.value):Promise.resolve(o.value).then(s,a);u((t=t.apply(r,e)).next())});var Vi=g((OE,ks)=>{"use strict";ks.exports=function(e,t){return function(){for(var n=new Array(arguments.length),s=0;s<n.length;s++)n[s]=arguments[s];return e.apply(t,n)}}});var Be=g((qE,Hs)=>{"use strict";var um=Vi(),pr=Object.prototype.toString;function Zi(r){return Array.isArray(r)}function Yi(r){return typeof r=="undefined"}function fm(r){return r!==null&&!Yi(r)&&r.constructor!==null&&!Yi(r.constructor)&&typeof r.constructor.isBuffer=="function"&&r.constructor.isBuffer(r)}function $s(r){return pr.call(r)==="[object ArrayBuffer]"}function cm(r){return pr.call(r)==="[object FormData]"}function lm(r){var e;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?e=ArrayBuffer.isView(r):e=r&&r.buffer&&$s(r.buffer),e}function hm(r){return typeof r=="string"}function pm(r){return typeof r=="number"}function zs(r){return r!==null&&typeof r=="object"}function Yt(r){if(pr.call(r)!=="[object Object]")return!1;var e=Object.getPrototypeOf(r);return e===null||e===Object.prototype}function dm(r){return pr.call(r)==="[object Date]"}function mm(r){return pr.call(r)==="[object File]"}function gm(r){return pr.call(r)==="[object Blob]"}function Ws(r){return pr.call(r)==="[object Function]"}function vm(r){return zs(r)&&Ws(r.pipe)}function ym(r){return pr.call(r)==="[object URLSearchParams]"}function _m(r){return r.trim?r.trim():r.replace(/^\s+|\s+$/g,"")}function wm(){return typeof navigator!="undefined"&&(navigator.product==="ReactNative"||navigator.product==="NativeScript"||navigator.product==="NS")?!1:typeof window!="undefined"&&typeof document!="undefined"}function Qi(r,e){if(!(r===null||typeof r=="undefined"))if(typeof r!="object"&&(r=[r]),Zi(r))for(var t=0,i=r.length;t<i;t++)e.call(null,r[t],t,r);else for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&e.call(null,r[n],n,r)}function Xi(){var r={};function e(n,s){Yt(r[s])&&Yt(n)?r[s]=Xi(r[s],n):Yt(n)?r[s]=Xi({},n):Zi(n)?r[s]=n.slice():r[s]=n}for(var t=0,i=arguments.length;t<i;t++)Qi(arguments[t],e);return r}function bm(r,e,t){return Qi(e,function(n,s){t&&typeof n=="function"?r[s]=um(n,t):r[s]=n}),r}function xm(r){return r.charCodeAt(0)===65279&&(r=r.slice(1)),r}Hs.exports={isArray:Zi,isArrayBuffer:$s,isBuffer:fm,isFormData:cm,isArrayBufferView:lm,isString:hm,isNumber:pm,isObject:zs,isPlainObject:Yt,isUndefined:Yi,isDate:dm,isFile:mm,isBlob:gm,isFunction:Ws,isStream:vm,isURLSearchParams:ym,isStandardBrowserEnv:wm,forEach:Qi,merge:Xi,extend:bm,trim:_m,stripBOM:xm}});var en=g((CE,Ks)=>{"use strict";var Gr=Be();function Gs(r){return encodeURIComponent(r).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}Ks.exports=function(e,t,i){if(!t)return e;var n;if(i)n=i(t);else if(Gr.isURLSearchParams(t))n=t.toString();else{var s=[];Gr.forEach(t,function(o,l){o===null||typeof o=="undefined"||(Gr.isArray(o)?l=l+"[]":o=[o],Gr.forEach(o,function(b){Gr.isDate(b)?b=b.toISOString():Gr.isObject(b)&&(b=JSON.stringify(b)),s.push(Gs(l)+"="+Gs(b))}))}),n=s.join("&")}if(n){var a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+n}return e}});var Vs=g((EE,Js)=>{"use strict";var Sm=Be();function Xt(){this.handlers=[]}Xt.prototype.use=function(e,t,i){return this.handlers.push({fulfilled:e,rejected:t,synchronous:i?i.synchronous:!1,runWhen:i?i.runWhen:null}),this.handlers.length-1};Xt.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)};Xt.prototype.forEach=function(e){Sm.forEach(this.handlers,function(i){i!==null&&e(i)})};Js.exports=Xt});var Xs=g((IE,Ys)=>{"use strict";var Am=Be();Ys.exports=function(e,t){Am.forEach(e,function(n,s){s!==t&&s.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[s])})}});var rn=g((TE,Zs)=>{"use strict";Zs.exports=function(e,t,i,n,s){return e.config=t,i&&(e.code=i),e.request=n,e.response=s,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}},e}});var tn=g((PE,Qs)=>{"use strict";Qs.exports={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1}});var nn=g((ME,ea)=>{"use strict";var Om=rn();ea.exports=function(e,t,i,n,s){var a=new Error(e);return Om(a,t,i,n,s)}});var ta=g((RE,ra)=>{"use strict";var qm=nn();ra.exports=function(e,t,i){var n=i.config.validateStatus;!i.status||!n||n(i.status)?e(i):t(qm("Request failed with status code "+i.status,i.config,null,i.request,i))}});var na=g((LE,ia)=>{"use strict";var Zt=Be();ia.exports=Zt.isStandardBrowserEnv()?function(){return{write:function(t,i,n,s,a,u){var o=[];o.push(t+"="+encodeURIComponent(i)),Zt.isNumber(n)&&o.push("expires="+new Date(n).toGMTString()),Zt.isString(s)&&o.push("path="+s),Zt.isString(a)&&o.push("domain="+a),u===!0&&o.push("secure"),document.cookie=o.join("; ")},read:function(t){var i=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return i?decodeURIComponent(i[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()});var aa=g((jE,sa)=>{"use strict";sa.exports=function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}});var ua=g((NE,oa)=>{"use strict";oa.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}});var ca=g((UE,fa)=>{"use strict";var Cm=aa(),Em=ua();fa.exports=function(e,t){return e&&!Cm(t)?Em(e,t):t}});var ha=g((DE,la)=>{"use strict";var sn=Be(),Im=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];la.exports=function(e){var t={},i,n,s;return e&&sn.forEach(e.split(`
|
|
9
|
+
`),function(u){if(s=u.indexOf(":"),i=sn.trim(u.substr(0,s)).toLowerCase(),n=sn.trim(u.substr(s+1)),i){if(t[i]&&Im.indexOf(i)>=0)return;i==="set-cookie"?t[i]=(t[i]?t[i]:[]).concat([n]):t[i]=t[i]?t[i]+", "+n:n}}),t}});var ma=g((FE,da)=>{"use strict";var pa=Be();da.exports=pa.isStandardBrowserEnv()?function(){var e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a"),i;function n(s){var a=s;return e&&(t.setAttribute("href",a),a=t.href),t.setAttribute("href",a),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:t.pathname.charAt(0)==="/"?t.pathname:"/"+t.pathname}}return i=n(window.location.href),function(a){var u=pa.isString(a)?n(a):a;return u.protocol===i.protocol&&u.host===i.host}}():function(){return function(){return!0}}()});var bt=g((BE,ga)=>{"use strict";function an(r){this.message=r}an.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")};an.prototype.__CANCEL__=!0;ga.exports=an});var un=g((kE,va)=>{"use strict";var Qt=Be(),Tm=ta(),Pm=na(),Mm=en(),Rm=ca(),Lm=ha(),jm=ma(),on=nn(),Nm=tn(),Um=bt();va.exports=function(e){return new Promise(function(i,n){var s=e.data,a=e.headers,u=e.responseType,o;function l(){e.cancelToken&&e.cancelToken.unsubscribe(o),e.signal&&e.signal.removeEventListener("abort",o)}Qt.isFormData(s)&&delete a["Content-Type"];var p=new XMLHttpRequest;if(e.auth){var b=e.auth.username||"",_=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";a.Authorization="Basic "+btoa(b+":"+_)}var q=Rm(e.baseURL,e.url);p.open(e.method.toUpperCase(),Mm(q,e.params,e.paramsSerializer),!0),p.timeout=e.timeout;function y(){if(!!p){var H="getAllResponseHeaders"in p?Lm(p.getAllResponseHeaders()):null,K=!u||u==="text"||u==="json"?p.responseText:p.response,Q={data:K,status:p.status,statusText:p.statusText,headers:H,config:e,request:p};Tm(function(Z){i(Z),l()},function(Z){n(Z),l()},Q),p=null}}if("onloadend"in p?p.onloadend=y:p.onreadystatechange=function(){!p||p.readyState!==4||p.status===0&&!(p.responseURL&&p.responseURL.indexOf("file:")===0)||setTimeout(y)},p.onabort=function(){!p||(n(on("Request aborted",e,"ECONNABORTED",p)),p=null)},p.onerror=function(){n(on("Network Error",e,null,p)),p=null},p.ontimeout=function(){var K=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded",Q=e.transitional||Nm;e.timeoutErrorMessage&&(K=e.timeoutErrorMessage),n(on(K,e,Q.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",p)),p=null},Qt.isStandardBrowserEnv()){var E=(e.withCredentials||jm(q))&&e.xsrfCookieName?Pm.read(e.xsrfCookieName):void 0;E&&(a[e.xsrfHeaderName]=E)}"setRequestHeader"in p&&Qt.forEach(a,function(K,Q){typeof s=="undefined"&&Q.toLowerCase()==="content-type"?delete a[Q]:p.setRequestHeader(Q,K)}),Qt.isUndefined(e.withCredentials)||(p.withCredentials=!!e.withCredentials),u&&u!=="json"&&(p.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&p.addEventListener("progress",e.onDownloadProgress),typeof e.onUploadProgress=="function"&&p.upload&&p.upload.addEventListener("progress",e.onUploadProgress),(e.cancelToken||e.signal)&&(o=function(H){!p||(n(!H||H&&H.type?new Um("canceled"):H),p.abort(),p=null)},e.cancelToken&&e.cancelToken.subscribe(o),e.signal&&(e.signal.aborted?o():e.signal.addEventListener("abort",o))),s||(s=null),p.send(s)})}});var ri=g(($E,wa)=>{"use strict";var Me=Be(),ya=Xs(),Dm=rn(),Fm=tn(),Bm={"Content-Type":"application/x-www-form-urlencoded"};function _a(r,e){!Me.isUndefined(r)&&Me.isUndefined(r["Content-Type"])&&(r["Content-Type"]=e)}function km(){var r;return typeof XMLHttpRequest!="undefined"?r=un():typeof process!="undefined"&&Object.prototype.toString.call(process)==="[object process]"&&(r=un()),r}function $m(r,e,t){if(Me.isString(r))try{return(e||JSON.parse)(r),Me.trim(r)}catch(i){if(i.name!=="SyntaxError")throw i}return(t||JSON.stringify)(r)}var ei={transitional:Fm,adapter:km(),transformRequest:[function(e,t){return ya(t,"Accept"),ya(t,"Content-Type"),Me.isFormData(e)||Me.isArrayBuffer(e)||Me.isBuffer(e)||Me.isStream(e)||Me.isFile(e)||Me.isBlob(e)?e:Me.isArrayBufferView(e)?e.buffer:Me.isURLSearchParams(e)?(_a(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):Me.isObject(e)||t&&t["Content-Type"]==="application/json"?(_a(t,"application/json"),$m(e)):e}],transformResponse:[function(e){var t=this.transitional||ei.transitional,i=t&&t.silentJSONParsing,n=t&&t.forcedJSONParsing,s=!i&&this.responseType==="json";if(s||n&&Me.isString(e)&&e.length)try{return JSON.parse(e)}catch(a){if(s)throw a.name==="SyntaxError"?Dm(a,this,"E_JSON_PARSE"):a}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Me.forEach(["delete","get","head"],function(e){ei.headers[e]={}});Me.forEach(["post","put","patch"],function(e){ei.headers[e]=Me.merge(Bm)});wa.exports=ei});var xa=g((zE,ba)=>{"use strict";var zm=Be(),Wm=ri();ba.exports=function(e,t,i){var n=this||Wm;return zm.forEach(i,function(a){e=a.call(n,e,t)}),e}});var fn=g((WE,Sa)=>{"use strict";Sa.exports=function(e){return!!(e&&e.__CANCEL__)}});var qa=g((HE,Oa)=>{"use strict";var Aa=Be(),cn=xa(),Hm=fn(),Gm=ri(),Km=bt();function ln(r){if(r.cancelToken&&r.cancelToken.throwIfRequested(),r.signal&&r.signal.aborted)throw new Km("canceled")}Oa.exports=function(e){ln(e),e.headers=e.headers||{},e.data=cn.call(e,e.data,e.headers,e.transformRequest),e.headers=Aa.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),Aa.forEach(["delete","get","head","post","put","patch","common"],function(n){delete e.headers[n]});var t=e.adapter||Gm.adapter;return t(e).then(function(n){return ln(e),n.data=cn.call(e,n.data,n.headers,e.transformResponse),n},function(n){return Hm(n)||(ln(e),n&&n.response&&(n.response.data=cn.call(e,n.response.data,n.response.headers,e.transformResponse))),Promise.reject(n)})}});var hn=g((GE,Ca)=>{"use strict";var We=Be();Ca.exports=function(e,t){t=t||{};var i={};function n(p,b){return We.isPlainObject(p)&&We.isPlainObject(b)?We.merge(p,b):We.isPlainObject(b)?We.merge({},b):We.isArray(b)?b.slice():b}function s(p){if(We.isUndefined(t[p])){if(!We.isUndefined(e[p]))return n(void 0,e[p])}else return n(e[p],t[p])}function a(p){if(!We.isUndefined(t[p]))return n(void 0,t[p])}function u(p){if(We.isUndefined(t[p])){if(!We.isUndefined(e[p]))return n(void 0,e[p])}else return n(void 0,t[p])}function o(p){if(p in t)return n(e[p],t[p]);if(p in e)return n(void 0,e[p])}var l={url:a,method:a,data:a,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,responseEncoding:u,validateStatus:o};return We.forEach(Object.keys(e).concat(Object.keys(t)),function(b){var _=l[b]||s,q=_(b);We.isUndefined(q)&&_!==o||(i[b]=q)}),i}});var pn=g((KE,Ea)=>{Ea.exports={version:"0.26.1"}});var Pa=g((JE,Ta)=>{"use strict";var Jm=pn().version,dn={};["object","boolean","number","function","string","symbol"].forEach(function(r,e){dn[r]=function(i){return typeof i===r||"a"+(e<1?"n ":" ")+r}});var Ia={};dn.transitional=function(e,t,i){function n(s,a){return"[Axios v"+Jm+"] Transitional option '"+s+"'"+a+(i?". "+i:"")}return function(s,a,u){if(e===!1)throw new Error(n(a," has been removed"+(t?" in "+t:"")));return t&&!Ia[a]&&(Ia[a]=!0,console.warn(n(a," has been deprecated since v"+t+" and will be removed in the near future"))),e?e(s,a,u):!0}};function Vm(r,e,t){if(typeof r!="object")throw new TypeError("options must be an object");for(var i=Object.keys(r),n=i.length;n-- >0;){var s=i[n],a=e[s];if(a){var u=r[s],o=u===void 0||a(u,s,r);if(o!==!0)throw new TypeError("option "+s+" must be "+o);continue}if(t!==!0)throw Error("Unknown option "+s)}}Ta.exports={assertOptions:Vm,validators:dn}});var Ua=g((VE,Na)=>{"use strict";var La=Be(),Ym=en(),Ma=Vs(),Ra=qa(),ti=hn(),ja=Pa(),Kr=ja.validators;function xt(r){this.defaults=r,this.interceptors={request:new Ma,response:new Ma}}xt.prototype.request=function(e,t){typeof e=="string"?(t=t||{},t.url=e):t=e||{},t=ti(this.defaults,t),t.method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var i=t.transitional;i!==void 0&&ja.assertOptions(i,{silentJSONParsing:Kr.transitional(Kr.boolean),forcedJSONParsing:Kr.transitional(Kr.boolean),clarifyTimeoutError:Kr.transitional(Kr.boolean)},!1);var n=[],s=!0;this.interceptors.request.forEach(function(q){typeof q.runWhen=="function"&&q.runWhen(t)===!1||(s=s&&q.synchronous,n.unshift(q.fulfilled,q.rejected))});var a=[];this.interceptors.response.forEach(function(q){a.push(q.fulfilled,q.rejected)});var u;if(!s){var o=[Ra,void 0];for(Array.prototype.unshift.apply(o,n),o=o.concat(a),u=Promise.resolve(t);o.length;)u=u.then(o.shift(),o.shift());return u}for(var l=t;n.length;){var p=n.shift(),b=n.shift();try{l=p(l)}catch(_){b(_);break}}try{u=Ra(l)}catch(_){return Promise.reject(_)}for(;a.length;)u=u.then(a.shift(),a.shift());return u};xt.prototype.getUri=function(e){return e=ti(this.defaults,e),Ym(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")};La.forEach(["delete","get","head","options"],function(e){xt.prototype[e]=function(t,i){return this.request(ti(i||{},{method:e,url:t,data:(i||{}).data}))}});La.forEach(["post","put","patch"],function(e){xt.prototype[e]=function(t,i,n){return this.request(ti(n||{},{method:e,url:t,data:i}))}});Na.exports=xt});var Fa=g((YE,Da)=>{"use strict";var Xm=bt();function Jr(r){if(typeof r!="function")throw new TypeError("executor must be a function.");var e;this.promise=new Promise(function(n){e=n});var t=this;this.promise.then(function(i){if(!!t._listeners){var n,s=t._listeners.length;for(n=0;n<s;n++)t._listeners[n](i);t._listeners=null}}),this.promise.then=function(i){var n,s=new Promise(function(a){t.subscribe(a),n=a}).then(i);return s.cancel=function(){t.unsubscribe(n)},s},r(function(n){t.reason||(t.reason=new Xm(n),e(t.reason))})}Jr.prototype.throwIfRequested=function(){if(this.reason)throw this.reason};Jr.prototype.subscribe=function(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]};Jr.prototype.unsubscribe=function(e){if(!!this._listeners){var t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}};Jr.source=function(){var e,t=new Jr(function(n){e=n});return{token:t,cancel:e}};Da.exports=Jr});var ka=g((XE,Ba)=>{"use strict";Ba.exports=function(e){return function(i){return e.apply(null,i)}}});var za=g((ZE,$a)=>{"use strict";var Zm=Be();$a.exports=function(e){return Zm.isObject(e)&&e.isAxiosError===!0}});var Ga=g((QE,mn)=>{"use strict";var Wa=Be(),Qm=Vi(),ii=Ua(),eg=hn(),rg=ri();function Ha(r){var e=new ii(r),t=Qm(ii.prototype.request,e);return Wa.extend(t,ii.prototype,e),Wa.extend(t,e),t.create=function(n){return Ha(eg(r,n))},t}var er=Ha(rg);er.Axios=ii;er.Cancel=bt();er.CancelToken=Fa();er.isCancel=fn();er.VERSION=pn().version;er.all=function(e){return Promise.all(e)};er.spread=ka();er.isAxiosError=za();mn.exports=er;mn.exports.default=er});var ni=g((eI,Ka)=>{Ka.exports=Ga()});var ke=g((rI,Ja)=>{var tg=Array.isArray;Ja.exports=tg});var gn=g((tI,Va)=>{var ig=typeof global=="object"&&global&&global.Object===Object&&global;Va.exports=ig});var Ve=g((iI,Ya)=>{var ng=gn(),sg=typeof self=="object"&&self&&self.Object===Object&&self,ag=ng||sg||Function("return this")();Ya.exports=ag});var Mr=g((nI,Xa)=>{var og=Ve(),ug=og.Symbol;Xa.exports=ug});var ro=g((sI,eo)=>{var Za=Mr(),Qa=Object.prototype,fg=Qa.hasOwnProperty,cg=Qa.toString,St=Za?Za.toStringTag:void 0;function lg(r){var e=fg.call(r,St),t=r[St];try{r[St]=void 0;var i=!0}catch(s){}var n=cg.call(r);return i&&(e?r[St]=t:delete r[St]),n}eo.exports=lg});var io=g((aI,to)=>{var hg=Object.prototype,pg=hg.toString;function dg(r){return pg.call(r)}to.exports=dg});var dr=g((oI,ao)=>{var no=Mr(),mg=ro(),gg=io(),vg="[object Null]",yg="[object Undefined]",so=no?no.toStringTag:void 0;function _g(r){return r==null?r===void 0?yg:vg:so&&so in Object(r)?mg(r):gg(r)}ao.exports=_g});var Ye=g((uI,oo)=>{function wg(r){return r!=null&&typeof r=="object"}oo.exports=wg});var si=g((fI,uo)=>{var bg=dr(),xg=Ye(),Sg="[object Symbol]";function Ag(r){return typeof r=="symbol"||xg(r)&&bg(r)==Sg}uo.exports=Ag});var co=g((cI,fo)=>{var Og=ke(),qg=si(),Cg=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Eg=/^\w*$/;function Ig(r,e){if(Og(r))return!1;var t=typeof r;return t=="number"||t=="symbol"||t=="boolean"||r==null||qg(r)?!0:Eg.test(r)||!Cg.test(r)||e!=null&&r in Object(e)}fo.exports=Ig});var Xe=g((lI,lo)=>{function Tg(r){var e=typeof r;return r!=null&&(e=="object"||e=="function")}lo.exports=Tg});var ai=g((hI,ho)=>{var Pg=dr(),Mg=Xe(),Rg="[object AsyncFunction]",Lg="[object Function]",jg="[object GeneratorFunction]",Ng="[object Proxy]";function Ug(r){if(!Mg(r))return!1;var e=Pg(r);return e==Lg||e==jg||e==Rg||e==Ng}ho.exports=Ug});var mo=g((pI,po)=>{var Dg=Ve(),Fg=Dg["__core-js_shared__"];po.exports=Fg});var yo=g((dI,vo)=>{var vn=mo(),go=function(){var r=/[^.]+$/.exec(vn&&vn.keys&&vn.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""}();function Bg(r){return!!go&&go in r}vo.exports=Bg});var yn=g((mI,_o)=>{var kg=Function.prototype,$g=kg.toString;function zg(r){if(r!=null){try{return $g.call(r)}catch(e){}try{return r+""}catch(e){}}return""}_o.exports=zg});var bo=g((gI,wo)=>{var Wg=ai(),Hg=yo(),Gg=Xe(),Kg=yn(),Jg=/[\\^$.*+?()[\]{}|]/g,Vg=/^\[object .+?Constructor\]$/,Yg=Function.prototype,Xg=Object.prototype,Zg=Yg.toString,Qg=Xg.hasOwnProperty,ev=RegExp("^"+Zg.call(Qg).replace(Jg,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function rv(r){if(!Gg(r)||Hg(r))return!1;var e=Wg(r)?ev:Vg;return e.test(Kg(r))}wo.exports=rv});var So=g((vI,xo)=>{function tv(r,e){return r==null?void 0:r[e]}xo.exports=tv});var mr=g((yI,Ao)=>{var iv=bo(),nv=So();function sv(r,e){var t=nv(r,e);return iv(t)?t:void 0}Ao.exports=sv});var At=g((_I,Oo)=>{var av=mr(),ov=av(Object,"create");Oo.exports=ov});var Eo=g((wI,Co)=>{var qo=At();function uv(){this.__data__=qo?qo(null):{},this.size=0}Co.exports=uv});var To=g((bI,Io)=>{function fv(r){var e=this.has(r)&&delete this.__data__[r];return this.size-=e?1:0,e}Io.exports=fv});var Mo=g((xI,Po)=>{var cv=At(),lv="__lodash_hash_undefined__",hv=Object.prototype,pv=hv.hasOwnProperty;function dv(r){var e=this.__data__;if(cv){var t=e[r];return t===lv?void 0:t}return pv.call(e,r)?e[r]:void 0}Po.exports=dv});var Lo=g((SI,Ro)=>{var mv=At(),gv=Object.prototype,vv=gv.hasOwnProperty;function yv(r){var e=this.__data__;return mv?e[r]!==void 0:vv.call(e,r)}Ro.exports=yv});var No=g((AI,jo)=>{var _v=At(),wv="__lodash_hash_undefined__";function bv(r,e){var t=this.__data__;return this.size+=this.has(r)?0:1,t[r]=_v&&e===void 0?wv:e,this}jo.exports=bv});var Do=g((OI,Uo)=>{var xv=Eo(),Sv=To(),Av=Mo(),Ov=Lo(),qv=No();function Vr(r){var e=-1,t=r==null?0:r.length;for(this.clear();++e<t;){var i=r[e];this.set(i[0],i[1])}}Vr.prototype.clear=xv;Vr.prototype.delete=Sv;Vr.prototype.get=Av;Vr.prototype.has=Ov;Vr.prototype.set=qv;Uo.exports=Vr});var Bo=g((qI,Fo)=>{function Cv(){this.__data__=[],this.size=0}Fo.exports=Cv});var Yr=g((CI,ko)=>{function Ev(r,e){return r===e||r!==r&&e!==e}ko.exports=Ev});var Ot=g((EI,$o)=>{var Iv=Yr();function Tv(r,e){for(var t=r.length;t--;)if(Iv(r[t][0],e))return t;return-1}$o.exports=Tv});var Wo=g((II,zo)=>{var Pv=Ot(),Mv=Array.prototype,Rv=Mv.splice;function Lv(r){var e=this.__data__,t=Pv(e,r);if(t<0)return!1;var i=e.length-1;return t==i?e.pop():Rv.call(e,t,1),--this.size,!0}zo.exports=Lv});var Go=g((TI,Ho)=>{var jv=Ot();function Nv(r){var e=this.__data__,t=jv(e,r);return t<0?void 0:e[t][1]}Ho.exports=Nv});var Jo=g((PI,Ko)=>{var Uv=Ot();function Dv(r){return Uv(this.__data__,r)>-1}Ko.exports=Dv});var Yo=g((MI,Vo)=>{var Fv=Ot();function Bv(r,e){var t=this.__data__,i=Fv(t,r);return i<0?(++this.size,t.push([r,e])):t[i][1]=e,this}Vo.exports=Bv});var qt=g((RI,Xo)=>{var kv=Bo(),$v=Wo(),zv=Go(),Wv=Jo(),Hv=Yo();function Xr(r){var e=-1,t=r==null?0:r.length;for(this.clear();++e<t;){var i=r[e];this.set(i[0],i[1])}}Xr.prototype.clear=kv;Xr.prototype.delete=$v;Xr.prototype.get=zv;Xr.prototype.has=Wv;Xr.prototype.set=Hv;Xo.exports=Xr});var oi=g((LI,Zo)=>{var Gv=mr(),Kv=Ve(),Jv=Gv(Kv,"Map");Zo.exports=Jv});var ru=g((jI,eu)=>{var Qo=Do(),Vv=qt(),Yv=oi();function Xv(){this.size=0,this.__data__={hash:new Qo,map:new(Yv||Vv),string:new Qo}}eu.exports=Xv});var iu=g((NI,tu)=>{function Zv(r){var e=typeof r;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?r!=="__proto__":r===null}tu.exports=Zv});var Ct=g((UI,nu)=>{var Qv=iu();function ey(r,e){var t=r.__data__;return Qv(e)?t[typeof e=="string"?"string":"hash"]:t.map}nu.exports=ey});var au=g((DI,su)=>{var ry=Ct();function ty(r){var e=ry(this,r).delete(r);return this.size-=e?1:0,e}su.exports=ty});var uu=g((FI,ou)=>{var iy=Ct();function ny(r){return iy(this,r).get(r)}ou.exports=ny});var cu=g((BI,fu)=>{var sy=Ct();function ay(r){return sy(this,r).has(r)}fu.exports=ay});var hu=g((kI,lu)=>{var oy=Ct();function uy(r,e){var t=oy(this,r),i=t.size;return t.set(r,e),this.size+=t.size==i?0:1,this}lu.exports=uy});var ui=g(($I,pu)=>{var fy=ru(),cy=au(),ly=uu(),hy=cu(),py=hu();function Zr(r){var e=-1,t=r==null?0:r.length;for(this.clear();++e<t;){var i=r[e];this.set(i[0],i[1])}}Zr.prototype.clear=fy;Zr.prototype.delete=cy;Zr.prototype.get=ly;Zr.prototype.has=hy;Zr.prototype.set=py;pu.exports=Zr});var gu=g((zI,mu)=>{var du=ui(),dy="Expected a function";function _n(r,e){if(typeof r!="function"||e!=null&&typeof e!="function")throw new TypeError(dy);var t=function(){var i=arguments,n=e?e.apply(this,i):i[0],s=t.cache;if(s.has(n))return s.get(n);var a=r.apply(this,i);return t.cache=s.set(n,a)||s,a};return t.cache=new(_n.Cache||du),t}_n.Cache=du;mu.exports=_n});var yu=g((WI,vu)=>{var my=gu(),gy=500;function vy(r){var e=my(r,function(i){return t.size===gy&&t.clear(),i}),t=e.cache;return e}vu.exports=vy});var wu=g((HI,_u)=>{var yy=yu(),_y=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,wy=/\\(\\)?/g,by=yy(function(r){var e=[];return r.charCodeAt(0)===46&&e.push(""),r.replace(_y,function(t,i,n,s){e.push(n?s.replace(wy,"$1"):i||t)}),e});_u.exports=by});var Et=g((GI,bu)=>{function xy(r,e){for(var t=-1,i=r==null?0:r.length,n=Array(i);++t<i;)n[t]=e(r[t],t,r);return n}bu.exports=xy});var Cu=g((KI,qu)=>{var xu=Mr(),Sy=Et(),Ay=ke(),Oy=si(),qy=1/0,Su=xu?xu.prototype:void 0,Au=Su?Su.toString:void 0;function Ou(r){if(typeof r=="string")return r;if(Ay(r))return Sy(r,Ou)+"";if(Oy(r))return Au?Au.call(r):"";var e=r+"";return e=="0"&&1/r==-qy?"-0":e}qu.exports=Ou});var Iu=g((JI,Eu)=>{var Cy=Cu();function Ey(r){return r==null?"":Cy(r)}Eu.exports=Ey});var It=g((VI,Tu)=>{var Iy=ke(),Ty=co(),Py=wu(),My=Iu();function Ry(r,e){return Iy(r)?r:Ty(r,e)?[r]:Py(My(r))}Tu.exports=Ry});var fi=g((YI,Pu)=>{var Ly=si(),jy=1/0;function Ny(r){if(typeof r=="string"||Ly(r))return r;var e=r+"";return e=="0"&&1/r==-jy?"-0":e}Pu.exports=Ny});var wn=g((XI,Mu)=>{var Uy=It(),Dy=fi();function Fy(r,e){e=Uy(e,r);for(var t=0,i=e.length;r!=null&&t<i;)r=r[Dy(e[t++])];return t&&t==i?r:void 0}Mu.exports=Fy});var Lu=g((ZI,Ru)=>{var By=wn();function ky(r,e,t){var i=r==null?void 0:By(r,e);return i===void 0?t:i}Ru.exports=ky});var bn=g((QI,ju)=>{var $y=mr(),zy=function(){try{var r=$y(Object,"defineProperty");return r({},"",{}),r}catch(e){}}();ju.exports=zy});var ci=g((eT,Uu)=>{var Nu=bn();function Wy(r,e,t){e=="__proto__"&&Nu?Nu(r,e,{configurable:!0,enumerable:!0,value:t,writable:!0}):r[e]=t}Uu.exports=Wy});var li=g((rT,Du)=>{var Hy=ci(),Gy=Yr(),Ky=Object.prototype,Jy=Ky.hasOwnProperty;function Vy(r,e,t){var i=r[e];(!(Jy.call(r,e)&&Gy(i,t))||t===void 0&&!(e in r))&&Hy(r,e,t)}Du.exports=Vy});var hi=g((tT,Fu)=>{var Yy=9007199254740991,Xy=/^(?:0|[1-9]\d*)$/;function Zy(r,e){var t=typeof r;return e=e==null?Yy:e,!!e&&(t=="number"||t!="symbol"&&Xy.test(r))&&r>-1&&r%1==0&&r<e}Fu.exports=Zy});var $u=g((iT,ku)=>{var Qy=li(),e_=It(),r_=hi(),Bu=Xe(),t_=fi();function i_(r,e,t,i){if(!Bu(r))return r;e=e_(e,r);for(var n=-1,s=e.length,a=s-1,u=r;u!=null&&++n<s;){var o=t_(e[n]),l=t;if(o==="__proto__"||o==="constructor"||o==="prototype")return r;if(n!=a){var p=u[o];l=i?i(p,o,u):void 0,l===void 0&&(l=Bu(p)?p:r_(e[n+1])?[]:{})}Qy(u,o,l),u=u[o]}return r}ku.exports=i_});var Wu=g((nT,zu)=>{var n_=$u();function s_(r,e,t){return r==null?r:n_(r,e,t)}zu.exports=s_});var Gu=g((sT,Hu)=>{var a_="__lodash_hash_undefined__";function o_(r){return this.__data__.set(r,a_),this}Hu.exports=o_});var Ju=g((aT,Ku)=>{function u_(r){return this.__data__.has(r)}Ku.exports=u_});var di=g((oT,Vu)=>{var f_=ui(),c_=Gu(),l_=Ju();function pi(r){var e=-1,t=r==null?0:r.length;for(this.__data__=new f_;++e<t;)this.add(r[e])}pi.prototype.add=pi.prototype.push=c_;pi.prototype.has=l_;Vu.exports=pi});var Xu=g((uT,Yu)=>{function h_(r,e,t,i){for(var n=r.length,s=t+(i?1:-1);i?s--:++s<n;)if(e(r[s],s,r))return s;return-1}Yu.exports=h_});var Qu=g((fT,Zu)=>{function p_(r){return r!==r}Zu.exports=p_});var rf=g((cT,ef)=>{function d_(r,e,t){for(var i=t-1,n=r.length;++i<n;)if(r[i]===e)return i;return-1}ef.exports=d_});var nf=g((lT,tf)=>{var m_=Xu(),g_=Qu(),v_=rf();function y_(r,e,t){return e===e?v_(r,e,t):m_(r,g_,t)}tf.exports=y_});var xn=g((hT,sf)=>{var __=nf();function w_(r,e){var t=r==null?0:r.length;return!!t&&__(r,e,0)>-1}sf.exports=w_});var Sn=g((pT,af)=>{function b_(r,e,t){for(var i=-1,n=r==null?0:r.length;++i<n;)if(t(e,r[i]))return!0;return!1}af.exports=b_});var mi=g((dT,of)=>{function x_(r,e){return r.has(e)}of.exports=x_});var An=g((mT,uf)=>{var S_=mr(),A_=Ve(),O_=S_(A_,"Set");uf.exports=O_});var cf=g((gT,ff)=>{function q_(){}ff.exports=q_});var gi=g((vT,lf)=>{function C_(r){var e=-1,t=Array(r.size);return r.forEach(function(i){t[++e]=i}),t}lf.exports=C_});var pf=g((yT,hf)=>{var On=An(),E_=cf(),I_=gi(),T_=1/0,P_=On&&1/I_(new On([,-0]))[1]==T_?function(r){return new On(r)}:E_;hf.exports=P_});var qn=g((_T,df)=>{var M_=di(),R_=xn(),L_=Sn(),j_=mi(),N_=pf(),U_=gi(),D_=200;function F_(r,e,t){var i=-1,n=R_,s=r.length,a=!0,u=[],o=u;if(t)a=!1,n=L_;else if(s>=D_){var l=e?null:N_(r);if(l)return U_(l);a=!1,n=j_,o=new M_}else o=e?[]:u;e:for(;++i<s;){var p=r[i],b=e?e(p):p;if(p=t||p!==0?p:0,a&&b===b){for(var _=o.length;_--;)if(o[_]===b)continue e;e&&o.push(b),u.push(p)}else n(o,b,t)||(o!==u&&o.push(b),u.push(p))}return u}df.exports=F_});var gf=g((wT,mf)=>{var B_=qn();function k_(r){return r&&r.length?B_(r):[]}mf.exports=k_});var Tt=g((bT,vf)=>{function $_(r){return function(e){return r(e)}}vf.exports=$_});var wf=g((xT,_f)=>{var z_=di(),W_=xn(),H_=Sn(),G_=Et(),K_=Tt(),yf=mi(),J_=Math.min;function V_(r,e,t){for(var i=t?H_:W_,n=r[0].length,s=r.length,a=s,u=Array(s),o=1/0,l=[];a--;){var p=r[a];a&&e&&(p=G_(p,K_(e))),o=J_(p.length,o),u[a]=!t&&(e||n>=120&&p.length>=120)?new z_(a&&p):void 0}p=r[0];var b=-1,_=u[0];e:for(;++b<n&&l.length<o;){var q=p[b],y=e?e(q):q;if(q=t||q!==0?q:0,!(_?yf(_,y):i(l,y,t))){for(a=s;--a;){var E=u[a];if(!(E?yf(E,y):i(r[a],y,t)))continue e}_&&_.push(y),l.push(q)}}return l}_f.exports=V_});var vi=g((ST,bf)=>{function Y_(r){return r}bf.exports=Y_});var Sf=g((AT,xf)=>{function X_(r,e,t){switch(t.length){case 0:return r.call(e);case 1:return r.call(e,t[0]);case 2:return r.call(e,t[0],t[1]);case 3:return r.call(e,t[0],t[1],t[2])}return r.apply(e,t)}xf.exports=X_});var Cn=g((OT,Of)=>{var Z_=Sf(),Af=Math.max;function Q_(r,e,t){return e=Af(e===void 0?r.length-1:e,0),function(){for(var i=arguments,n=-1,s=Af(i.length-e,0),a=Array(s);++n<s;)a[n]=i[e+n];n=-1;for(var u=Array(e+1);++n<e;)u[n]=i[n];return u[e]=t(a),Z_(r,this,u)}}Of.exports=Q_});var Cf=g((qT,qf)=>{function ew(r){return function(){return r}}qf.exports=ew});var Tf=g((CT,If)=>{var rw=Cf(),Ef=bn(),tw=vi(),iw=Ef?function(r,e){return Ef(r,"toString",{configurable:!0,enumerable:!1,value:rw(e),writable:!0})}:tw;If.exports=iw});var Mf=g((ET,Pf)=>{var nw=800,sw=16,aw=Date.now;function ow(r){var e=0,t=0;return function(){var i=aw(),n=sw-(i-t);if(t=i,n>0){if(++e>=nw)return arguments[0]}else e=0;return r.apply(void 0,arguments)}}Pf.exports=ow});var En=g((IT,Rf)=>{var uw=Tf(),fw=Mf(),cw=fw(uw);Rf.exports=cw});var yi=g((TT,Lf)=>{var lw=vi(),hw=Cn(),pw=En();function dw(r,e){return pw(hw(r,e,lw),r+"")}Lf.exports=dw});var In=g((PT,jf)=>{var mw=9007199254740991;function gw(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=mw}jf.exports=gw});var Qr=g((MT,Nf)=>{var vw=ai(),yw=In();function _w(r){return r!=null&&yw(r.length)&&!vw(r)}Nf.exports=_w});var _i=g((RT,Uf)=>{var ww=Qr(),bw=Ye();function xw(r){return bw(r)&&ww(r)}Uf.exports=xw});var Ff=g((LT,Df)=>{var Sw=_i();function Aw(r){return Sw(r)?r:[]}Df.exports=Aw});var kf=g((jT,Bf)=>{var Ow=Et(),qw=wf(),Cw=yi(),Ew=Ff(),Iw=Cw(function(r){var e=Ow(r,Ew);return e.length&&e[0]===r[0]?qw(e):[]});Bf.exports=Iw});var Pt=g((NT,$f)=>{function Tw(r,e){for(var t=-1,i=e.length,n=r.length;++t<i;)r[n+t]=e[t];return r}$f.exports=Tw});var Wf=g((UT,zf)=>{var Pw=dr(),Mw=Ye(),Rw="[object Arguments]";function Lw(r){return Mw(r)&&Pw(r)==Rw}zf.exports=Lw});var Mt=g((DT,Kf)=>{var Hf=Wf(),jw=Ye(),Gf=Object.prototype,Nw=Gf.hasOwnProperty,Uw=Gf.propertyIsEnumerable,Dw=Hf(function(){return arguments}())?Hf:function(r){return jw(r)&&Nw.call(r,"callee")&&!Uw.call(r,"callee")};Kf.exports=Dw});var Xf=g((FT,Yf)=>{var Jf=Mr(),Fw=Mt(),Bw=ke(),Vf=Jf?Jf.isConcatSpreadable:void 0;function kw(r){return Bw(r)||Fw(r)||!!(Vf&&r&&r[Vf])}Yf.exports=kw});var wi=g((BT,Qf)=>{var $w=Pt(),zw=Xf();function Zf(r,e,t,i,n){var s=-1,a=r.length;for(t||(t=zw),n||(n=[]);++s<a;){var u=r[s];e>0&&t(u)?e>1?Zf(u,e-1,t,i,n):$w(n,u):i||(n[n.length]=u)}return n}Qf.exports=Zf});var rc=g((kT,ec)=>{var Ww=wi(),Hw=yi(),Gw=qn(),Kw=_i(),Jw=Hw(function(r){return Gw(Ww(r,1,Kw,!0))});ec.exports=Jw});var ic=g(($T,tc)=>{function Vw(r){return function(e,t,i){for(var n=-1,s=Object(e),a=i(e),u=a.length;u--;){var o=a[r?u:++n];if(t(s[o],o,s)===!1)break}return e}}tc.exports=Vw});var Tn=g((zT,nc)=>{var Yw=ic(),Xw=Yw();nc.exports=Xw});var ac=g((WT,sc)=>{function Zw(r,e){for(var t=-1,i=Array(r);++t<r;)i[t]=e(t);return i}sc.exports=Zw});var uc=g((HT,oc)=>{function Qw(){return!1}oc.exports=Qw});var rt=g((Rt,et)=>{var eb=Ve(),rb=uc(),lc=typeof Rt=="object"&&Rt&&!Rt.nodeType&&Rt,fc=lc&&typeof et=="object"&&et&&!et.nodeType&&et,tb=fc&&fc.exports===lc,cc=tb?eb.Buffer:void 0,ib=cc?cc.isBuffer:void 0,nb=ib||rb;et.exports=nb});var pc=g((GT,hc)=>{var sb=dr(),ab=In(),ob=Ye(),ub="[object Arguments]",fb="[object Array]",cb="[object Boolean]",lb="[object Date]",hb="[object Error]",pb="[object Function]",db="[object Map]",mb="[object Number]",gb="[object Object]",vb="[object RegExp]",yb="[object Set]",_b="[object String]",wb="[object WeakMap]",bb="[object ArrayBuffer]",xb="[object DataView]",Sb="[object Float32Array]",Ab="[object Float64Array]",Ob="[object Int8Array]",qb="[object Int16Array]",Cb="[object Int32Array]",Eb="[object Uint8Array]",Ib="[object Uint8ClampedArray]",Tb="[object Uint16Array]",Pb="[object Uint32Array]",we={};we[Sb]=we[Ab]=we[Ob]=we[qb]=we[Cb]=we[Eb]=we[Ib]=we[Tb]=we[Pb]=!0;we[ub]=we[fb]=we[bb]=we[cb]=we[xb]=we[lb]=we[hb]=we[pb]=we[db]=we[mb]=we[gb]=we[vb]=we[yb]=we[_b]=we[wb]=!1;function Mb(r){return ob(r)&&ab(r.length)&&!!we[sb(r)]}hc.exports=Mb});var bi=g((Lt,tt)=>{var Rb=gn(),dc=typeof Lt=="object"&&Lt&&!Lt.nodeType&&Lt,jt=dc&&typeof tt=="object"&&tt&&!tt.nodeType&&tt,Lb=jt&&jt.exports===dc,Pn=Lb&&Rb.process,jb=function(){try{var r=jt&&jt.require&&jt.require("util").types;return r||Pn&&Pn.binding&&Pn.binding("util")}catch(e){}}();tt.exports=jb});var Nt=g((KT,vc)=>{var Nb=pc(),Ub=Tt(),mc=bi(),gc=mc&&mc.isTypedArray,Db=gc?Ub(gc):Nb;vc.exports=Db});var Mn=g((JT,yc)=>{var Fb=ac(),Bb=Mt(),kb=ke(),$b=rt(),zb=hi(),Wb=Nt(),Hb=Object.prototype,Gb=Hb.hasOwnProperty;function Kb(r,e){var t=kb(r),i=!t&&Bb(r),n=!t&&!i&&$b(r),s=!t&&!i&&!n&&Wb(r),a=t||i||n||s,u=a?Fb(r.length,String):[],o=u.length;for(var l in r)(e||Gb.call(r,l))&&!(a&&(l=="length"||n&&(l=="offset"||l=="parent")||s&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||zb(l,o)))&&u.push(l);return u}yc.exports=Kb});var Ut=g((VT,_c)=>{var Jb=Object.prototype;function Vb(r){var e=r&&r.constructor,t=typeof e=="function"&&e.prototype||Jb;return r===t}_c.exports=Vb});var Rn=g((YT,wc)=>{function Yb(r,e){return function(t){return r(e(t))}}wc.exports=Yb});var xc=g((XT,bc)=>{var Xb=Rn(),Zb=Xb(Object.keys,Object);bc.exports=Zb});var Ln=g((ZT,Sc)=>{var Qb=Ut(),e0=xc(),r0=Object.prototype,t0=r0.hasOwnProperty;function i0(r){if(!Qb(r))return e0(r);var e=[];for(var t in Object(r))t0.call(r,t)&&t!="constructor"&&e.push(t);return e}Sc.exports=i0});var Dt=g((QT,Ac)=>{var n0=Mn(),s0=Ln(),a0=Qr();function o0(r){return a0(r)?n0(r):s0(r)}Ac.exports=o0});var qc=g((e1,Oc)=>{var u0=Tn(),f0=Dt();function c0(r,e){return r&&u0(r,e,f0)}Oc.exports=c0});var Ec=g((r1,Cc)=>{var l0=vi();function h0(r){return typeof r=="function"?r:l0}Cc.exports=h0});var Tc=g((t1,Ic)=>{var p0=qc(),d0=Ec();function m0(r,e){return r&&p0(r,d0(e))}Ic.exports=m0});var Mc=g((i1,Pc)=>{var g0=dr(),v0=ke(),y0=Ye(),_0="[object String]";function w0(r){return typeof r=="string"||!v0(r)&&y0(r)&&g0(r)==_0}Pc.exports=w0});var Lc=g((n1,Rc)=>{var b0=mr(),x0=Ve(),S0=b0(x0,"DataView");Rc.exports=S0});var Nc=g((s1,jc)=>{var A0=mr(),O0=Ve(),q0=A0(O0,"Promise");jc.exports=q0});var Dc=g((a1,Uc)=>{var C0=mr(),E0=Ve(),I0=C0(E0,"WeakMap");Uc.exports=I0});var nt=g((o1,Hc)=>{var jn=Lc(),Nn=oi(),Un=Nc(),Dn=An(),Fn=Dc(),Wc=dr(),it=yn(),Fc="[object Map]",T0="[object Object]",Bc="[object Promise]",kc="[object Set]",$c="[object WeakMap]",zc="[object DataView]",P0=it(jn),M0=it(Nn),R0=it(Un),L0=it(Dn),j0=it(Fn),Rr=Wc;(jn&&Rr(new jn(new ArrayBuffer(1)))!=zc||Nn&&Rr(new Nn)!=Fc||Un&&Rr(Un.resolve())!=Bc||Dn&&Rr(new Dn)!=kc||Fn&&Rr(new Fn)!=$c)&&(Rr=function(r){var e=Wc(r),t=e==T0?r.constructor:void 0,i=t?it(t):"";if(i)switch(i){case P0:return zc;case M0:return Fc;case R0:return Bc;case L0:return kc;case j0:return $c}return e});Hc.exports=Rr});var Kc=g((u1,Gc)=>{var N0=Ln(),U0=nt(),D0=Mt(),F0=ke(),B0=Qr(),k0=rt(),$0=Ut(),z0=Nt(),W0="[object Map]",H0="[object Set]",G0=Object.prototype,K0=G0.hasOwnProperty;function J0(r){if(r==null)return!0;if(B0(r)&&(F0(r)||typeof r=="string"||typeof r.splice=="function"||k0(r)||z0(r)||D0(r)))return!r.length;var e=U0(r);if(e==W0||e==H0)return!r.size;if($0(r))return!N0(r).length;for(var t in r)if(K0.call(r,t))return!1;return!0}Gc.exports=J0});var Vc=g((f1,Jc)=>{var V0=qt();function Y0(){this.__data__=new V0,this.size=0}Jc.exports=Y0});var Xc=g((c1,Yc)=>{function X0(r){var e=this.__data__,t=e.delete(r);return this.size=e.size,t}Yc.exports=X0});var Qc=g((l1,Zc)=>{function Z0(r){return this.__data__.get(r)}Zc.exports=Z0});var rl=g((h1,el)=>{function Q0(r){return this.__data__.has(r)}el.exports=Q0});var il=g((p1,tl)=>{var ex=qt(),rx=oi(),tx=ui(),ix=200;function nx(r,e){var t=this.__data__;if(t instanceof ex){var i=t.__data__;if(!rx||i.length<ix-1)return i.push([r,e]),this.size=++t.size,this;t=this.__data__=new tx(i)}return t.set(r,e),this.size=t.size,this}tl.exports=nx});var xi=g((d1,nl)=>{var sx=qt(),ax=Vc(),ox=Xc(),ux=Qc(),fx=rl(),cx=il();function st(r){var e=this.__data__=new sx(r);this.size=e.size}st.prototype.clear=ax;st.prototype.delete=ox;st.prototype.get=ux;st.prototype.has=fx;st.prototype.set=cx;nl.exports=st});var al=g((m1,sl)=>{function lx(r,e){for(var t=-1,i=r==null?0:r.length;++t<i;)if(e(r[t],t,r))return!0;return!1}sl.exports=lx});var Bn=g((g1,ol)=>{var hx=di(),px=al(),dx=mi(),mx=1,gx=2;function vx(r,e,t,i,n,s){var a=t&mx,u=r.length,o=e.length;if(u!=o&&!(a&&o>u))return!1;var l=s.get(r),p=s.get(e);if(l&&p)return l==e&&p==r;var b=-1,_=!0,q=t&gx?new hx:void 0;for(s.set(r,e),s.set(e,r);++b<u;){var y=r[b],E=e[b];if(i)var H=a?i(E,y,b,e,r,s):i(y,E,b,r,e,s);if(H!==void 0){if(H)continue;_=!1;break}if(q){if(!px(e,function(K,Q){if(!dx(q,Q)&&(y===K||n(y,K,t,i,s)))return q.push(Q)})){_=!1;break}}else if(!(y===E||n(y,E,t,i,s))){_=!1;break}}return s.delete(r),s.delete(e),_}ol.exports=vx});var kn=g((v1,ul)=>{var yx=Ve(),_x=yx.Uint8Array;ul.exports=_x});var cl=g((y1,fl)=>{function wx(r){var e=-1,t=Array(r.size);return r.forEach(function(i,n){t[++e]=[n,i]}),t}fl.exports=wx});var ml=g((_1,dl)=>{var ll=Mr(),hl=kn(),bx=Yr(),xx=Bn(),Sx=cl(),Ax=gi(),Ox=1,qx=2,Cx="[object Boolean]",Ex="[object Date]",Ix="[object Error]",Tx="[object Map]",Px="[object Number]",Mx="[object RegExp]",Rx="[object Set]",Lx="[object String]",jx="[object Symbol]",Nx="[object ArrayBuffer]",Ux="[object DataView]",pl=ll?ll.prototype:void 0,$n=pl?pl.valueOf:void 0;function Dx(r,e,t,i,n,s,a){switch(t){case Ux:if(r.byteLength!=e.byteLength||r.byteOffset!=e.byteOffset)return!1;r=r.buffer,e=e.buffer;case Nx:return!(r.byteLength!=e.byteLength||!s(new hl(r),new hl(e)));case Cx:case Ex:case Px:return bx(+r,+e);case Ix:return r.name==e.name&&r.message==e.message;case Mx:case Lx:return r==e+"";case Tx:var u=Sx;case Rx:var o=i&Ox;if(u||(u=Ax),r.size!=e.size&&!o)return!1;var l=a.get(r);if(l)return l==e;i|=qx,a.set(r,e);var p=xx(u(r),u(e),i,n,s,a);return a.delete(r),p;case jx:if($n)return $n.call(r)==$n.call(e)}return!1}dl.exports=Dx});var zn=g((w1,gl)=>{var Fx=Pt(),Bx=ke();function kx(r,e,t){var i=e(r);return Bx(r)?i:Fx(i,t(r))}gl.exports=kx});var yl=g((b1,vl)=>{function $x(r,e){for(var t=-1,i=r==null?0:r.length,n=0,s=[];++t<i;){var a=r[t];e(a,t,r)&&(s[n++]=a)}return s}vl.exports=$x});var Wn=g((x1,_l)=>{function zx(){return[]}_l.exports=zx});var Si=g((S1,bl)=>{var Wx=yl(),Hx=Wn(),Gx=Object.prototype,Kx=Gx.propertyIsEnumerable,wl=Object.getOwnPropertySymbols,Jx=wl?function(r){return r==null?[]:(r=Object(r),Wx(wl(r),function(e){return Kx.call(r,e)}))}:Hx;bl.exports=Jx});var Hn=g((A1,xl)=>{var Vx=zn(),Yx=Si(),Xx=Dt();function Zx(r){return Vx(r,Xx,Yx)}xl.exports=Zx});var Ol=g((O1,Al)=>{var Sl=Hn(),Qx=1,eS=Object.prototype,rS=eS.hasOwnProperty;function tS(r,e,t,i,n,s){var a=t&Qx,u=Sl(r),o=u.length,l=Sl(e),p=l.length;if(o!=p&&!a)return!1;for(var b=o;b--;){var _=u[b];if(!(a?_ in e:rS.call(e,_)))return!1}var q=s.get(r),y=s.get(e);if(q&&y)return q==e&&y==r;var E=!0;s.set(r,e),s.set(e,r);for(var H=a;++b<o;){_=u[b];var K=r[_],Q=e[_];if(i)var F=a?i(Q,K,_,e,r,s):i(K,Q,_,r,e,s);if(!(F===void 0?K===Q||n(K,Q,t,i,s):F)){E=!1;break}H||(H=_=="constructor")}if(E&&!H){var Z=r.constructor,te=e.constructor;Z!=te&&"constructor"in r&&"constructor"in e&&!(typeof Z=="function"&&Z instanceof Z&&typeof te=="function"&&te instanceof te)&&(E=!1)}return s.delete(r),s.delete(e),E}Al.exports=tS});var Rl=g((q1,Ml)=>{var Gn=xi(),iS=Bn(),nS=ml(),sS=Ol(),ql=nt(),Cl=ke(),El=rt(),aS=Nt(),oS=1,Il="[object Arguments]",Tl="[object Array]",Ai="[object Object]",uS=Object.prototype,Pl=uS.hasOwnProperty;function fS(r,e,t,i,n,s){var a=Cl(r),u=Cl(e),o=a?Tl:ql(r),l=u?Tl:ql(e);o=o==Il?Ai:o,l=l==Il?Ai:l;var p=o==Ai,b=l==Ai,_=o==l;if(_&&El(r)){if(!El(e))return!1;a=!0,p=!1}if(_&&!p)return s||(s=new Gn),a||aS(r)?iS(r,e,t,i,n,s):nS(r,e,o,t,i,n,s);if(!(t&oS)){var q=p&&Pl.call(r,"__wrapped__"),y=b&&Pl.call(e,"__wrapped__");if(q||y){var E=q?r.value():r,H=y?e.value():e;return s||(s=new Gn),n(E,H,t,i,s)}}return _?(s||(s=new Gn),sS(r,e,t,i,n,s)):!1}Ml.exports=fS});var Ul=g((C1,Nl)=>{var cS=Rl(),Ll=Ye();function jl(r,e,t,i,n){return r===e?!0:r==null||e==null||!Ll(r)&&!Ll(e)?r!==r&&e!==e:cS(r,e,t,i,jl,n)}Nl.exports=jl});var Fl=g((E1,Dl)=>{var lS=Ul();function hS(r,e){return lS(r,e)}Dl.exports=hS});var Kn=g((I1,Bl)=>{var pS=ci(),dS=Yr();function mS(r,e,t){(t!==void 0&&!dS(r[e],t)||t===void 0&&!(e in r))&&pS(r,e,t)}Bl.exports=mS});var Jn=g((Ft,at)=>{var gS=Ve(),Wl=typeof Ft=="object"&&Ft&&!Ft.nodeType&&Ft,kl=Wl&&typeof at=="object"&&at&&!at.nodeType&&at,vS=kl&&kl.exports===Wl,$l=vS?gS.Buffer:void 0,zl=$l?$l.allocUnsafe:void 0;function yS(r,e){if(e)return r.slice();var t=r.length,i=zl?zl(t):new r.constructor(t);return r.copy(i),i}at.exports=yS});var Oi=g((T1,Gl)=>{var Hl=kn();function _S(r){var e=new r.constructor(r.byteLength);return new Hl(e).set(new Hl(r)),e}Gl.exports=_S});var Vn=g((P1,Kl)=>{var wS=Oi();function bS(r,e){var t=e?wS(r.buffer):r.buffer;return new r.constructor(t,r.byteOffset,r.length)}Kl.exports=bS});var qi=g((M1,Jl)=>{function xS(r,e){var t=-1,i=r.length;for(e||(e=Array(i));++t<i;)e[t]=r[t];return e}Jl.exports=xS});var Xl=g((R1,Yl)=>{var SS=Xe(),Vl=Object.create,AS=function(){function r(){}return function(e){if(!SS(e))return{};if(Vl)return Vl(e);r.prototype=e;var t=new r;return r.prototype=void 0,t}}();Yl.exports=AS});var Ci=g((L1,Zl)=>{var OS=Rn(),qS=OS(Object.getPrototypeOf,Object);Zl.exports=qS});var Yn=g((j1,Ql)=>{var CS=Xl(),ES=Ci(),IS=Ut();function TS(r){return typeof r.constructor=="function"&&!IS(r)?CS(ES(r)):{}}Ql.exports=TS});var Xn=g((N1,rh)=>{var PS=dr(),MS=Ci(),RS=Ye(),LS="[object Object]",jS=Function.prototype,NS=Object.prototype,eh=jS.toString,US=NS.hasOwnProperty,DS=eh.call(Object);function FS(r){if(!RS(r)||PS(r)!=LS)return!1;var e=MS(r);if(e===null)return!0;var t=US.call(e,"constructor")&&e.constructor;return typeof t=="function"&&t instanceof t&&eh.call(t)==DS}rh.exports=FS});var Zn=g((U1,th)=>{function BS(r,e){if(!(e==="constructor"&&typeof r[e]=="function")&&e!="__proto__")return r[e]}th.exports=BS});var Lr=g((D1,ih)=>{var kS=li(),$S=ci();function zS(r,e,t,i){var n=!t;t||(t={});for(var s=-1,a=e.length;++s<a;){var u=e[s],o=i?i(t[u],r[u],u,t,r):void 0;o===void 0&&(o=r[u]),n?$S(t,u,o):kS(t,u,o)}return t}ih.exports=zS});var sh=g((F1,nh)=>{function WS(r){var e=[];if(r!=null)for(var t in Object(r))e.push(t);return e}nh.exports=WS});var oh=g((B1,ah)=>{var HS=Xe(),GS=Ut(),KS=sh(),JS=Object.prototype,VS=JS.hasOwnProperty;function YS(r){if(!HS(r))return KS(r);var e=GS(r),t=[];for(var i in r)i=="constructor"&&(e||!VS.call(r,i))||t.push(i);return t}ah.exports=YS});var ot=g((k1,uh)=>{var XS=Mn(),ZS=oh(),QS=Qr();function eA(r){return QS(r)?XS(r,!0):ZS(r)}uh.exports=eA});var ch=g(($1,fh)=>{var rA=Lr(),tA=ot();function iA(r){return rA(r,tA(r))}fh.exports=iA});var gh=g((z1,mh)=>{var lh=Kn(),nA=Jn(),sA=Vn(),aA=qi(),oA=Yn(),hh=Mt(),ph=ke(),uA=_i(),fA=rt(),cA=ai(),lA=Xe(),hA=Xn(),pA=Nt(),dh=Zn(),dA=ch();function mA(r,e,t,i,n,s,a){var u=dh(r,t),o=dh(e,t),l=a.get(o);if(l){lh(r,t,l);return}var p=s?s(u,o,t+"",r,e,a):void 0,b=p===void 0;if(b){var _=ph(o),q=!_&&fA(o),y=!_&&!q&&pA(o);p=o,_||q||y?ph(u)?p=u:uA(u)?p=aA(u):q?(b=!1,p=nA(o,!0)):y?(b=!1,p=sA(o,!0)):p=[]:hA(o)||hh(o)?(p=u,hh(u)?p=dA(u):(!lA(u)||cA(u))&&(p=oA(o))):b=!1}b&&(a.set(o,p),n(p,o,i,s,a),a.delete(o)),lh(r,t,p)}mh.exports=mA});var _h=g((W1,yh)=>{var gA=xi(),vA=Kn(),yA=Tn(),_A=gh(),wA=Xe(),bA=ot(),xA=Zn();function vh(r,e,t,i,n){r!==e&&yA(e,function(s,a){if(n||(n=new gA),wA(s))_A(r,e,a,t,vh,i,n);else{var u=i?i(xA(r,a),s,a+"",r,e,n):void 0;u===void 0&&(u=s),vA(r,a,u)}},bA)}yh.exports=vh});var bh=g((H1,wh)=>{var SA=Yr(),AA=Qr(),OA=hi(),qA=Xe();function CA(r,e,t){if(!qA(t))return!1;var i=typeof e;return(i=="number"?AA(t)&&OA(e,t.length):i=="string"&&e in t)?SA(t[e],r):!1}wh.exports=CA});var Sh=g((G1,xh)=>{var EA=yi(),IA=bh();function TA(r){return EA(function(e,t){var i=-1,n=t.length,s=n>1?t[n-1]:void 0,a=n>2?t[2]:void 0;for(s=r.length>3&&typeof s=="function"?(n--,s):void 0,a&&IA(t[0],t[1],a)&&(s=n<3?void 0:s,n=1),e=Object(e);++i<n;){var u=t[i];u&&r(e,u,i,s)}return e})}xh.exports=TA});var Oh=g((K1,Ah)=>{var PA=_h(),MA=Sh(),RA=MA(function(r,e,t){PA(r,e,t)});Ah.exports=RA});var Qn=g((J1,qh)=>{function LA(r){var e=r==null?0:r.length;return e?r[e-1]:void 0}qh.exports=LA});var Eh=g((V1,Ch)=>{function jA(r,e){for(var t=-1,i=r==null?0:r.length;++t<i&&e(r[t],t,r)!==!1;);return r}Ch.exports=jA});var Th=g((Y1,Ih)=>{var NA=Lr(),UA=Dt();function DA(r,e){return r&&NA(e,UA(e),r)}Ih.exports=DA});var Mh=g((X1,Ph)=>{var FA=Lr(),BA=ot();function kA(r,e){return r&&FA(e,BA(e),r)}Ph.exports=kA});var Lh=g((Z1,Rh)=>{var $A=Lr(),zA=Si();function WA(r,e){return $A(r,zA(r),e)}Rh.exports=WA});var es=g((Q1,jh)=>{var HA=Pt(),GA=Ci(),KA=Si(),JA=Wn(),VA=Object.getOwnPropertySymbols,YA=VA?function(r){for(var e=[];r;)HA(e,KA(r)),r=GA(r);return e}:JA;jh.exports=YA});var Uh=g((eP,Nh)=>{var XA=Lr(),ZA=es();function QA(r,e){return XA(r,ZA(r),e)}Nh.exports=QA});var rs=g((rP,Dh)=>{var eO=zn(),rO=es(),tO=ot();function iO(r){return eO(r,tO,rO)}Dh.exports=iO});var Bh=g((tP,Fh)=>{var nO=Object.prototype,sO=nO.hasOwnProperty;function aO(r){var e=r.length,t=new r.constructor(e);return e&&typeof r[0]=="string"&&sO.call(r,"index")&&(t.index=r.index,t.input=r.input),t}Fh.exports=aO});var $h=g((iP,kh)=>{var oO=Oi();function uO(r,e){var t=e?oO(r.buffer):r.buffer;return new r.constructor(t,r.byteOffset,r.byteLength)}kh.exports=uO});var Wh=g((nP,zh)=>{var fO=/\w*$/;function cO(r){var e=new r.constructor(r.source,fO.exec(r));return e.lastIndex=r.lastIndex,e}zh.exports=cO});var Vh=g((sP,Jh)=>{var Hh=Mr(),Gh=Hh?Hh.prototype:void 0,Kh=Gh?Gh.valueOf:void 0;function lO(r){return Kh?Object(Kh.call(r)):{}}Jh.exports=lO});var Xh=g((aP,Yh)=>{var hO=Oi(),pO=$h(),dO=Wh(),mO=Vh(),gO=Vn(),vO="[object Boolean]",yO="[object Date]",_O="[object Map]",wO="[object Number]",bO="[object RegExp]",xO="[object Set]",SO="[object String]",AO="[object Symbol]",OO="[object ArrayBuffer]",qO="[object DataView]",CO="[object Float32Array]",EO="[object Float64Array]",IO="[object Int8Array]",TO="[object Int16Array]",PO="[object Int32Array]",MO="[object Uint8Array]",RO="[object Uint8ClampedArray]",LO="[object Uint16Array]",jO="[object Uint32Array]";function NO(r,e,t){var i=r.constructor;switch(e){case OO:return hO(r);case vO:case yO:return new i(+r);case qO:return pO(r,t);case CO:case EO:case IO:case TO:case PO:case MO:case RO:case LO:case jO:return gO(r,t);case _O:return new i;case wO:case SO:return new i(r);case bO:return dO(r);case xO:return new i;case AO:return mO(r)}}Yh.exports=NO});var Qh=g((oP,Zh)=>{var UO=nt(),DO=Ye(),FO="[object Map]";function BO(r){return DO(r)&&UO(r)==FO}Zh.exports=BO});var ip=g((uP,tp)=>{var kO=Qh(),$O=Tt(),ep=bi(),rp=ep&&ep.isMap,zO=rp?$O(rp):kO;tp.exports=zO});var sp=g((fP,np)=>{var WO=nt(),HO=Ye(),GO="[object Set]";function KO(r){return HO(r)&&WO(r)==GO}np.exports=KO});var fp=g((cP,up)=>{var JO=sp(),VO=Tt(),ap=bi(),op=ap&&ap.isSet,YO=op?VO(op):JO;up.exports=YO});var dp=g((lP,pp)=>{var XO=xi(),ZO=Eh(),QO=li(),eq=Th(),rq=Mh(),tq=Jn(),iq=qi(),nq=Lh(),sq=Uh(),aq=Hn(),oq=rs(),uq=nt(),fq=Bh(),cq=Xh(),lq=Yn(),hq=ke(),pq=rt(),dq=ip(),mq=Xe(),gq=fp(),vq=Dt(),yq=ot(),_q=1,wq=2,bq=4,cp="[object Arguments]",xq="[object Array]",Sq="[object Boolean]",Aq="[object Date]",Oq="[object Error]",lp="[object Function]",qq="[object GeneratorFunction]",Cq="[object Map]",Eq="[object Number]",hp="[object Object]",Iq="[object RegExp]",Tq="[object Set]",Pq="[object String]",Mq="[object Symbol]",Rq="[object WeakMap]",Lq="[object ArrayBuffer]",jq="[object DataView]",Nq="[object Float32Array]",Uq="[object Float64Array]",Dq="[object Int8Array]",Fq="[object Int16Array]",Bq="[object Int32Array]",kq="[object Uint8Array]",$q="[object Uint8ClampedArray]",zq="[object Uint16Array]",Wq="[object Uint32Array]",_e={};_e[cp]=_e[xq]=_e[Lq]=_e[jq]=_e[Sq]=_e[Aq]=_e[Nq]=_e[Uq]=_e[Dq]=_e[Fq]=_e[Bq]=_e[Cq]=_e[Eq]=_e[hp]=_e[Iq]=_e[Tq]=_e[Pq]=_e[Mq]=_e[kq]=_e[$q]=_e[zq]=_e[Wq]=!0;_e[Oq]=_e[lp]=_e[Rq]=!1;function Ei(r,e,t,i,n,s){var a,u=e&_q,o=e&wq,l=e&bq;if(t&&(a=n?t(r,i,n,s):t(r)),a!==void 0)return a;if(!mq(r))return r;var p=hq(r);if(p){if(a=fq(r),!u)return iq(r,a)}else{var b=uq(r),_=b==lp||b==qq;if(pq(r))return tq(r,u);if(b==hp||b==cp||_&&!n){if(a=o||_?{}:lq(r),!u)return o?sq(r,rq(a,r)):nq(r,eq(a,r))}else{if(!_e[b])return n?r:{};a=cq(r,b,u)}}s||(s=new XO);var q=s.get(r);if(q)return q;s.set(r,a),gq(r)?r.forEach(function(H){a.add(Ei(H,e,t,H,r,s))}):dq(r)&&r.forEach(function(H,K){a.set(K,Ei(H,e,t,K,r,s))});var y=l?o?oq:aq:o?yq:vq,E=p?void 0:y(r);return ZO(E||r,function(H,K){E&&(K=H,H=r[K]),QO(a,K,Ei(H,e,t,K,r,s))}),a}pp.exports=Ei});var gp=g((hP,mp)=>{function Hq(r,e,t){var i=-1,n=r.length;e<0&&(e=-e>n?0:n+e),t=t>n?n:t,t<0&&(t+=n),n=e>t?0:t-e>>>0,e>>>=0;for(var s=Array(n);++i<n;)s[i]=r[i+e];return s}mp.exports=Hq});var yp=g((pP,vp)=>{var Gq=wn(),Kq=gp();function Jq(r,e){return e.length<2?r:Gq(r,Kq(e,0,-1))}vp.exports=Jq});var wp=g((dP,_p)=>{var Vq=It(),Yq=Qn(),Xq=yp(),Zq=fi();function Qq(r,e){return e=Vq(e,r),r=Xq(r,e),r==null||delete r[Zq(Yq(e))]}_p.exports=Qq});var xp=g((mP,bp)=>{var eC=Xn();function rC(r){return eC(r)?void 0:r}bp.exports=rC});var Ap=g((gP,Sp)=>{var tC=wi();function iC(r){var e=r==null?0:r.length;return e?tC(r,1):[]}Sp.exports=iC});var qp=g((vP,Op)=>{var nC=Ap(),sC=Cn(),aC=En();function oC(r){return aC(sC(r,void 0,nC),r+"")}Op.exports=oC});var Ep=g((yP,Cp)=>{var uC=Et(),fC=dp(),cC=wp(),lC=It(),hC=Lr(),pC=xp(),dC=qp(),mC=rs(),gC=1,vC=2,yC=4,_C=dC(function(r,e){var t={};if(r==null)return t;var i=!1;e=uC(e,function(s){return s=lC(s,r),i||(i=s.length>1),s}),hC(r,mC(r),t),i&&(t=fC(t,gC|vC|yC,pC));for(var n=e.length;n--;)cC(t,e[n]);return t});Cp.exports=_C});var Tp=g((_P,Ip)=>{var wC=Pt(),bC=wi(),xC=qi(),SC=ke();function AC(){var r=arguments.length;if(!r)return[];for(var e=Array(r-1),t=arguments[0],i=r;i--;)e[i-1]=arguments[i];return wC(SC(t)?xC(t):[t],bC(e,1))}Ip.exports=AC});var Mp=g((wP,Pp)=>{Pp.exports=function(e){var t=function(te,O){var ee=te<<O|te>>>32-O;return ee},i=function(te){var O="",ee,G;for(ee=7;ee>=0;ee--)G=te>>>ee*4&15,O+=G.toString(16);return O},n,s,a,u=new Array(80),o=1732584193,l=4023233417,p=2562383102,b=271733878,_=3285377520,q,y,E,H,K,Q;e=unescape(encodeURIComponent(e));var F=e.length,Z=[];for(s=0;s<F-3;s+=4)a=e.charCodeAt(s)<<24|e.charCodeAt(s+1)<<16|e.charCodeAt(s+2)<<8|e.charCodeAt(s+3),Z.push(a);switch(F%4){case 0:s=2147483648;break;case 1:s=e.charCodeAt(F-1)<<24|8388608;break;case 2:s=e.charCodeAt(F-2)<<24|e.charCodeAt(F-1)<<16|32768;break;case 3:s=e.charCodeAt(F-3)<<24|e.charCodeAt(F-2)<<16|e.charCodeAt(F-1)<<8|128;break}for(Z.push(s);Z.length%16!==14;)Z.push(0);for(Z.push(F>>>29),Z.push(F<<3&4294967295),n=0;n<Z.length;n+=16){for(s=0;s<16;s++)u[s]=Z[n+s];for(s=16;s<=79;s++)u[s]=t(u[s-3]^u[s-8]^u[s-14]^u[s-16],1);for(q=o,y=l,E=p,H=b,K=_,s=0;s<=19;s++)Q=t(q,5)+(y&E|~y&H)+K+u[s]+1518500249&4294967295,K=H,H=E,E=t(y,30),y=q,q=Q;for(s=20;s<=39;s++)Q=t(q,5)+(y^E^H)+K+u[s]+1859775393&4294967295,K=H,H=E,E=t(y,30),y=q,q=Q;for(s=40;s<=59;s++)Q=t(q,5)+(y&E|y&H|E&H)+K+u[s]+2400959708&4294967295,K=H,H=E,E=t(y,30),y=q,q=Q;for(s=60;s<=79;s++)Q=t(q,5)+(y^E^H)+K+u[s]+3395469782&4294967295,K=H,H=E,E=t(y,30),y=q,q=Q;o=o+q&4294967295,l=l+y&4294967295,p=p+E&4294967295,b=b+H&4294967295,_=_+K&4294967295}return Q=i(o)+i(l)+i(p)+i(b)+i(_),Q.toLowerCase()}});var zp=g((bP,$p)=>{var Lp=Mp();function jp(r){return r.map(e=>e&&e.uri).filter(Boolean)}function us(r){return["memberSet","memberList","memberChoice"].find(e=>r[e])}function Rp(r){let e=us(r),t=r[e]?jp(r[e]):[];return{[t.length>1?e:"memberSet"]:t.map(i=>({uri:i}))}}function Np(r){let{from:e,to:t,type:i}=r,n={from:Rp(e||{}),to:Rp(t||{}),type:[i&&i[0]||"http://www.w3.org/2004/02/skos/core#mappingRelation"]};for(let s of["from","to"])if((n[s][us(n[s])]||[]).length==0){let a=r[s+"Scheme"];a&&a.uri&&(n[s+"Scheme"]={uri:a.uri})}return n}function Up(r){let{from:e,to:t}=r,i=[e,t].filter(Boolean).map(n=>jp(n[us(n)]||[]));return[].concat(...i).sort()}function Dp(r){let e=JSON.stringify(Np(r),["from","fromScheme","to","toScheme","type","memberSet","memberList","memberChoice","uri"]);return"urn:jskos:mapping:content:"+Lp(e+`
|
|
10
|
+
`)}function Fp(r){let e=JSON.stringify(Up(r));return"urn:jskos:mapping:members:"+Lp(e+`
|
|
11
|
+
`)}function os(r){let e=(r.identifier||[]).filter(t=>t&&!t.startsWith("urn:jskos:mapping:")).concat([Fp(r),Dp(r)]).sort();return Object.assign({},r,{identifier:e})}function Bp(r,e,t){r=r&&os(r),e=e&&os(e);let i=r&&r.identifier?r.identifier.find(s=>s.startsWith(t)):null,n=e&&e.identifier?e.identifier.find(s=>s.startsWith(t)):null;return i==n}function kp(r,e){return Bp(r,e,"urn:jskos:mapping:content:")}var qC=kp;function CC(r,e){return Bp(r,e,"urn:jskos:mapping:members:")}$p.exports={mappingContent:Np,mappingMembers:Up,mappingContentIdentifier:Dp,mappingMembersIdentifier:Fp,addMappingIdentifiers:os,compareMappings:kp,compareMappingContent:qC,compareMappingMembers:CC}});var fs=g((xP,Hp)=>{function Wp(r,e,t){var i=Array.prototype.slice,n=typeof Object.keys=="function"?Object.keys:function(l){var p=[];for(var b in l)p.push(b);return p},s=function(l,p){return l===p?!0:l instanceof Date&&p instanceof Date?l.getTime()===p.getTime():typeof l!="object"&&typeof p!="object"?l==p:o(l,p)};function a(l){return l==null}function u(l){return Object.prototype.toString.call(l)=="[object Arguments]"}function o(l,p){if(a(l)||a(p)||l.prototype!==p.prototype)return!1;if(u(l))return u(p)?(l=i.call(l),p=i.call(p),s(l,p)):!1;try{var b=n(l),_=n(p),q,y}catch(E){return!1}if(b.length!=_.length)return!1;for(b.sort(),_.sort(),y=b.length-1;y>=0;y--)if(b[y]!=_[y])return!1;for(y=b.length-1;y>=0;y--)if(q=b[y],t){let E=t(l[q],p[q],q);if(E===void 0&&(E=Wp(l[q],p[q])),!E)return!1}else if(!s(l[q],p[q]))return!1;return!0}return s(r,e)}Hp.exports={get:(r,e,t=void 0)=>{let i=s=>String.prototype.split.call(e,s).filter(Boolean).reduce((a,u)=>a!=null?a[u]:a,r),n=i(/[,[\]]+?/)||i(/[,[\].]+?/);return n===void 0||n===r?t:n},pick:(r,e)=>e.reduce((t,i)=>(r&&r.hasOwnProperty(i)&&(t[i]=r[i]),t),{}),forOwn:(r,e)=>{for(let t in r)r.hasOwnProperty(t)&&e(r[t],t)},isEqualWith:Wp,intersection:(...r)=>r.reduce((e,t)=>e.filter(i=>t.includes(i))),isObject:r=>typeof r=="object"&&r!==null,isString:r=>!!(r&&typeof r.valueOf()=="string"),union:(r,e)=>[...new Set([...r,...e])],unionWith:(r,e,t)=>[...r,...e].reduce((i,n)=>(i.findIndex(s=>t(s,n))!==-1||i.push(n),i),[]),omitMod:(r,e)=>{for(let t of e){typeof t=="string"&&(t=t.split("."));for(let i=0;i<t.length-1;i++)r=r[t[i]];delete r[t.pop()]}}}});var cs=g((SP,EC)=>{EC.exports=[{RELEVANCE:"very high",broader:[{uri:"http://www.w3.org/2004/02/skos/core#closeMatch"}],definition:{de:["gleiche Bedeutung"],en:["same meaning"]},notation:["="],prefLabel:{ar:"\u062A\u0637\u0627\u0628\u0642 \u062A\u0627\u0645",be:"\u0434\u0430\u043A\u043B\u0430\u0434\u043D\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u0446\u044C","be-tarask":"\u0434\u0430\u043A\u043B\u0430\u0434\u043D\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",bn:"\u09B9\u09C1\u09AC\u09C1\u09B9\u09C1 \u09AE\u09BF\u09B2",ca:"equival\xE8ncia exacta",cs:"p\u0159esn\xE1 shoda",da:"exact match",de:"exakte \xDCbereinstimmung",en:"exact match",eo:"ekzakta ekvivalento",es:"equivalencia exacta",fi:"vastaava k\xE4site",fr:"\xE9quivalence exacte",gl:"correspondencia exacta",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05DE\u05D3\u05D5\u05D9\u05E7\u05EA",hu:"pontos egyez\xE9s",id:"sama persis",it:"corrispondenza esatta",ja:"\u5B8C\u5168\u4E00\u81F4",lv:"tie\u0161a sakrit\u012Bba",mk:"\u0442\u043E\u0447\u043D\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",ms:"padanan tepat","ms-arab":"\u06A4\u0627\u062F\u0646\u0646 \u062A\u06A4\u062A",nb:"eksakt samsvar",nl:"exacte match",nn:"eksakt samsvar",pl:"dok\u0142adne dopasowanie",pt:"correspond\xEAncia exata",ro:"echivalentul exact",ru:"\u0442\u043E\u0447\u043D\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sq:"p\xEBrputhje e p\xEBrpikt\xEB",sr:"\u0442\u0430\u0447\u043D\u043E \u043F\u043E\u0434\u0443\u0434\u0430\u0440\u0430\u045A\u0435",sv:"exakt tr\xE4ff",tr:"tam e\u015Fle\u015Fme",uk:"\u0442\u043E\u0447\u043D\u0430 \u0432\u0456\u0434\u043F\u043E\u0432\u0456\u0434\u043D\u0456\u0441\u0442\u044C",zh:"\u7CBE\u78BA\u5339\u914D","zh-hans":"\u7CBE\u786E\u5339\u914D","zh-hant":"\u7CBE\u78BA\u5339\u914D"},SHORT:"exact",uri:"http://www.w3.org/2004/02/skos/core#exactMatch"},{RELEVANCE:"high",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{de:["in etwa gleiche Bedeutung"],en:["same general idea but not fully identical meaning"]},notation:["\u2248"],prefLabel:{ar:"\u062A\u0637\u0627\u0628\u0642 \u0642\u0631\u064A\u0628","be-tarask":"\u0431\u043B\u0456\u0437\u043A\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"equival\xE8ncia inexacta",de:"hohe \xDCbereinstimmung",en:"close match",eo:"proksima kongrua\u0135o",es:"equivalencia inexacta",fi:"l\xE4hes vastaava k\xE4site",fr:"quasi-\xE9quivalence",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E7\u05E8\u05D5\u05D1\u05D4",it:"corrispondenza parziale",mk:"\u0431\u043B\u0438\u0441\u043A\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",ms:"padanan dekat","ms-arab":"\u06A4\u0627\u062F\u0646\u0646 \u062F\u06A9\u062A",nb:"n\xE6rt samsvar",nl:"nabije match",nn:"n\xE6rt samsvar",pl:"cz\u0119\u015Bciowe dopasowanie",pt:"correspond\xEAncia pr\xF3xima",ru:"\u0431\u043B\u0438\u0437\u043A\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sr:"\u0431\u043B\u0438\u0441\u043A\u043E \u043F\u043E\u043A\u043B\u0430\u043F\u0430\u045A\u0435",sv:"n\xE4ra matchning",tr:"yak\u0131n e\u015Fle\u015Fme","zh-hans":"\u9AD8\u5EA6\u5339\u914D"},SHORT:"close",uri:"http://www.w3.org/2004/02/skos/core#closeMatch"},{RELEVANCE:"medium",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{de:["umfassendere Bedeutung"],en:["broader meaning"]},notation:[">"],prefLabel:{"be-tarask":"\u0448\u044B\u0440\u043E\u043A\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"relaci\xF3 llunyana",de:"allgemeinere Bedeutung",en:"broad match",eo:"malstrikta kongruo",fi:"vastaava laajempi k\xE4site",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E8\u05D7\u05D1\u05D4",it:"corrispondenza generica",ja:"\u90E8\u5206\u4E00\u81F4",mk:"\u043F\u043E\u0448\u0438\u0440\u043E\u043A\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",nb:"bredere samsvar",nl:"brede match",nn:"breitt samsvar",pl:"dopasowanie poj\u0119cia o szerszym znaczeniu","pt-br":"correspond\xEAncia gen\xE9rica",ru:"\u0431\u043E\u043B\u0435\u0435 \u0448\u0438\u0440\u043E\u043A\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sr:"\u0443 \u0448\u0438\u0440\u0435\u043C \u0441\u043C\u0438\u0441\u043B\u0443",sv:"bred tr\xE4ff","zh-hans":"\u5E7F\u6CDB\u5339\u914D"},related:[{uri:"http://www.w3.org/2004/02/skos/core#narrowMatch"}],SHORT:"broad",uri:"http://www.w3.org/2004/02/skos/core#broadMatch"},{RELEVANCE:"medium",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{en:["more specific meaning"]},notation:["<"],prefLabel:{"be-tarask":"\u0432\u0443\u0437\u043A\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"relaci\xF3 estreta",de:"spezifischere Bedeutung",en:"narrow match",eo:"strikta kongruo",fi:"vastaava suppeampi k\xE4site",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E6\u05E8\u05D4",it:"corrispondenza con termine pi\xF9 specifico",mk:"\u043F\u043E\u0442\u0435\u0441\u043D\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",nb:"smalere samsvar",nl:"nauwe match",nn:"snevert samsvar",pl:"dopasowanie poj\u0119cia o w\u0119\u017Cszym znaczeniu","pt-br":"correspond\xEAncia aproximada",ru:"\u0431\u043E\u043B\u0435\u0435 \u0443\u0437\u043A\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",sr:"\u0443 \u0443\u0436\u0435\u043C \u0441\u043C\u0438\u0441\u043B\u0443",sv:"smal tr\xE4ff",ur:"\u0646\u06CC\u0631\u0648 \u0645\u06CC\u0686","zh-hans":"\u6709\u9650\u5339\u914D"},related:[{uri:"http://www.w3.org/2004/02/skos/core#broadMatch"}],SHORT:"narrow",uri:"http://www.w3.org/2004/02/skos/core#narrowMatch"},{RELEVANCE:"low",broader:[{uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}],definition:{de:["assoziative Verkn\xFCpfung unterschiedlicher Bedeutungen"],en:["associative link between meanings"]},notation:["~"],prefLabel:{"be-tarask":"\u0437\u044C\u0432\u044F\u0437\u0430\u043D\u0430\u044F \u0430\u0434\u043F\u0430\u0432\u0435\u0434\u043D\u0430\u0441\u044C\u0446\u044C",ca:"parella relacionada",de:"verwandte Bedeutung",en:"related match",eo:"rilata kongruo",he:"\u05D4\u05EA\u05D0\u05DE\u05D4 \u05E7\u05E9\u05D5\u05E8\u05D4",it:"corrispondenza correlata",lv:"saist\u012Bta sakrit\u012Bba",mk:"\u043F\u043E\u0432\u0440\u0437\u0430\u043D\u043E \u0441\u043E\u0432\u043F\u0430\u0453\u0430\u045A\u0435",ms:"padanan berkaitan","ms-arab":"\u06A4\u0627\u062F\u0646\u0646 \u0628\u0631\u06A9\u0627\u0621\u064A\u062A\u0646",nb:"relatert samsvar",nl:"gerelateerde match",pl:"dopasowanie poj\u0119cia o powi\u0105zanym znaczeniu",ru:"\u0430\u0441\u0441\u043E\u0446\u0438\u0430\u0442\u0438\u0432\u043D\u043E\u0435 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0438\u0435",tr:"ili\u015Fkili benze\u015Fme",ur:"\u0645\u062A\u0639\u0644\u0642\u06C1 \u0645\u06CC\u0686",vec:"parente\u0142a re\u0142asionada","zh-hans":"\u5173\u8054\u5339\u914D"},SHORT:"related",uri:"http://www.w3.org/2004/02/skos/core#relatedMatch"},{RELEVANCE:"generic",definition:{de:["unbekannter Bedeutungszusammenhang"],en:["unknown type of link between meanings"]},notation:["\u2192"],prefLabel:{ar:"\u0646\u0648\u0639 \u0639\u0644\u0627\u0642\u0629 \u0627\u0644\u062A\u0637\u0628\u064A\u0642",be:"\u0445\u0430\u0440\u0430\u043A\u0442\u044D\u0440\u043D\u0430\u044F \u0430\u0434\u043D\u043E\u0441\u0456\u043D\u0430 \u0430\u0434\u043B\u044E\u0441\u0442\u0440\u0430\u0432\u0430\u043D\u043D\u044F","be-tarask":"\u0445\u0430\u0440\u0430\u043A\u0442\u044D\u0440\u043D\u0430\u044F \u0430\u0434\u043D\u043E\u0441\u0456\u043D\u0430 \u0430\u0434\u043B\u044E\u0441\u0442\u0440\u0430\u0432\u0430\u043D\u044C\u043D\u044F",ca:"relaci\xF3 de mapatge",de:"allgemeine Mapping-Relation",en:"SKOS generic mapping relation",fr:"lien de correspondance SKOS",he:"\u05D9\u05D7\u05E1 \u05DE\u05D9\u05E4\u05D5\u05D9 \u05DB\u05DC\u05DC\u05D9",id:"relasi pemetaan",mk:"\u043F\u0440\u0435\u0441\u043B\u0438\u043A\u0443\u0432\u0430\u0447\u043A\u0438 \u043E\u0434\u043D\u043E\u0441",nb:"generell mappingrelasjon","pt-br":"rela\xE7\xE3o gen\xE9rica de mapeamento",sr:"\u0440\u0435\u043B\u0430\u0446\u0438\u0458\u0430 \u043C\u0430\u043F\u0438\u0440\u0430\u045A\u0430",sv:"mappnings relation",zh:"\u6620\u5C04\u95DC\u4FC2","zh-hant":"\u6620\u5C04\u95DC\u4FC2"},SHORT:"",uri:"http://www.w3.org/2004/02/skos/core#mappingRelation"}]});var Kp=g((AP,Gp)=>{var IC=cs(),Ti={Concept:{type:["http://www.w3.org/2004/02/skos/core#Concept"]},ConceptScheme:{type:["http://www.w3.org/2004/02/skos/core#ConceptScheme"]},ConceptMapping:{type:IC.map(r=>r.uri)},ConceptOccurrence:{type:["http://purl.org/cld/cdtype/CatalogueOrIndex"]},Registry:{type:["http://www.w3.org/ns/dcat#Catalog"]},Distribution:{type:["http://www.w3.org/ns/dcat#Distribution"]},Concordance:{type:["http://rdfs.org/ns/void#Linkset","http://rdf-vocabulary.ddialliance.org/xkos#Correspondence"]},Resource:{},Item:{},ConceptBundle:{},Annotation:{type:["Annotation","http://www.w3.org/ns/oa#Annotation"]}},Ii=Object.keys(Ti).reduce((r,e)=>{for(let t of Ti[e].type||[])r[t]=e;return r},{});function TC(r,e=!1){var t;if(typeof r=="string"&&r)r in Ii?t=Ii[r]:(r=r.toLowerCase().replace(/s$/,""),t=Object.keys(Ti).find(i=>{let n=i.toLowerCase();if(n===r||n==="concept"+r)return!0}));else if(typeof r=="object"&&r.type){let i=Array.isArray(r.type)?r.type:[r.type];for(let n of i)if(n in Ii){t=Ii[n];break}}return e&&t?t.toLowerCase().replace(/^concept(.+)/,"$1"):t}Gp.exports={objectTypes:Ti,guessObjectType:TC}});var hs=g((OP,Jp)=>{var PC=/[\\^$.*+?()[\]{}|]/g,MC=r=>r.replace(PC,"\\$&"),RC=/[%ÄÖÜäöü ]/g,ls=class{constructor(e={}){if(Object.assign(this,e),this.notationPattern||(this.notationPattern=".+"),!this.uriPattern&&this.namespace){this.uriPattern="^"+MC(this.namespace);let t=this.notationPattern.replace(RC,encodeURI);this.uriPattern+="("+t+")$"}this.NOTATION_REGEX=RegExp("^"+this.notationPattern+"$"),this.uriPattern&&(this.URI_REGEX=RegExp(this.uriPattern))}isValidNotation(e){return this.NOTATION_REGEX.exec(e)}notationFromUri(e){if(this.URI_REGEX){let t=this.URI_REGEX.exec(e);if(t)return decodeURI(t[1])}}uriFromNotation(e){if(this.uriPattern)return e=encodeURI(e),this.uriPattern.replace(/^\^|\$$/g,"").replace(/\\/g,"").replace(/\(.*\)/,e)}conceptFromUri(e,t={}){let i=this.notationFromUri(e);if(i===void 0)return;let n={uri:e,notation:[i]};return t.inScheme&&(n.inScheme=[{uri:this.uri}]),t.topConcept&&(n.topConceptOf=[{uri:this.uri}]),n}conceptFromNotation(e,t){if(this.isValidNotation(e))return this.conceptFromUri(this.uriFromNotation(e),t)}};Jp.exports=ls});var ps=g((qP,Yp)=>{var LC=fs(),Pi={store:null,path:"",defaults:["en"],getLanguages:Vp,selectLanguage:jC};function Vp(){return LC.get(Pi.store,Pi.path)||Pi.defaults}function jC(r){if(!r)return null;for(let e of Vp())if(r[e])return e;for(let e of Object.keys(r))if(e!="-")return e;return null}Yp.exports=Pi});var sd=g((CP,nd)=>{var ie=fs(),NC=r=>/^[A-Z]*$/.test(r),ut=(r,e)=>e.split(".").reduce((t,i)=>t&&t[i]?t[i]:null,r),UC=r=>((r instanceof Array?r:[r]).forEach(t=>{t["@context"]="https://gbv.github.io/jskos/context.json"}),r),vs=r=>(Object.keys(r).forEach(e=>{NC(e)||e.startsWith("_")?delete r[e]:r[e]!=null&&typeof r[e]=="object"&&(r[e]=vs(r[e]))}),r),DC=vs,Mi=(r,e=[],t=!0)=>{e=e.concat(["ancestors","narrower","broader","mappings","memberList","TOPCONCEPTS","MAPPINGS","PROVIDER"]);let i=Array.isArray(r)?[]:{};for(let n in r)if(!(t&&n[0]=="_")){if(e.includes(n))if(r[n]&&Array.isArray(r[n])){r[n].length>0?i[n]=[null]:i[n]=[];continue}else{i[n]=null;continue}if(n=="inScheme"){let s=[];for(let a of r.inScheme){let u={uri:a.uri};a.notation&&(u.notation=a.notation),a.prefLabel&&(u.prefLabel=a.prefLabel),s.push(u)}i.inScheme=s;continue}r[n]!=null&&typeof r[n]=="object"?i[n]=Mi(r[n]):i[n]=r[n]}return i},FC=Mi,ds=r=>r?(r.uri?[r.uri]:[]).concat(r.identifier||[]):[],vr=(r,e)=>{if(r==null&&e==null)return!0;let t=s=>s.replace("http://").replace("https://"),i=ds(r).map(t),n=ds(e).map(t);return ie.intersection(i,n).length>0},BC=vr,kC=vr,$C=vr,zC=r=>ie.get(r,"type",[]).includes("http://www.w3.org/2004/02/skos/core#Concept")||ie.get(r,"inScheme")!=null||ie.get(r,"topConceptOf")!=null,Xp=r=>ie.get(r,"type",[]).includes("http://www.w3.org/2004/02/skos/core#ConceptScheme"),Zp=(r,e)=>{if(!r||!e)return!1;for(let t of e)if(vr(r,t))return!0;return!1},WC=Zp,HC=(r,e=!1)=>r.sort((t,i)=>{let n=ie.get(t,"notation[0]"),s=ie.get(i,"notation[0]");if(n&&s&&(n=n.toLowerCase(),s=s.toLowerCase()),e&&(n=parseFloat(n)||n,s=parseFloat(s)||s),(!n||!s||n==s)&&(n=t.uri,s=i.uri),n&&s){if(n>s)return 1;if(n<s)return-1}return 0}),GC=r=>{let e=["notation[0]",["prefLabel.de","prefLabel.en"],"uri"];return r.sort((t,i)=>{for(let n of e){let s,a;if(Array.isArray(n))for(let u of n)s=s||ie.get(t,u),a=a||ie.get(i,u);else s=ie.get(t,n),a=ie.get(i,n);if(s!=null&&a!=null){if(s=s.toLowerCase(),a=a.toLowerCase(),s>a)return 1;if(s<a)return-1}}return 0})},KC=r=>{let e=ie.pick(Mi(r),["from","to","fromScheme","toScheme","creator","contributor","type","created","modified","note","identifier","uri","partOf","mappingRelevance"]);for(let t of[e.from,e.to])ie.forOwn(t,(i,n)=>{let s=[];for(let a of i)s.push(ie.pick(a,["uri","notation"]));t[n]=s});return e.fromScheme&&(e.fromScheme=ie.pick(e.fromScheme,["uri","notation"])),e.toScheme&&(e.toScheme=ie.pick(e.toScheme,["uri","notation"])),e.partOf&&(e.partOf=e.partOf.map(t=>ie.pick(t,["uri"]))),e},Qp=cs(),$t=function(r){for(let e of Qp)if(r==e.uri)return e;return null},ed=$t("http://www.w3.org/2004/02/skos/core#mappingRelation"),JC=function(r,e=ed){let t;return Array.isArray(r)&&r.length>0?t=r[0]:t=r,$t(t)||e},VC=(r,e={})=>{let{language:t}=e,i=ut(r,"from.memberSet.0.notation.0"),n=ut(r,"to.memberSet.0.notation.0");i=i!==null?i:"",n=n!==null?n:"";let s=$t(ut(r,"type.0"));s=s?s.SHORT:"";let a=ft(ut(r,"from.memberSet.0"),{language:t,fallbackToUri:!1})||"",u=ft(ut(r,"to.memberSet.0"),{language:t,fallbackToUri:!1})||"",o=ft(ut(r,"creator.0"),{language:t,fallbackToUri:!1})||"";return{fromNotation:i,toNotation:n,fromLabel:a,toLabel:u,type:s,creator:o}},YC=(r={})=>{let e=r.delimiter||",",t=r.quoteChar||'"',i=r.lineTerminator||`
|
|
12
|
+
`,n=t+t,s=a=>t+(a==null?"":a.split(t).join(n))+t;return a=>a.map(s).join(e)+i},jr=(r,e)=>{let t=[];for(let i of["from","to"])(e==null||i===e)&&(t=t.concat(ie.get(r,`${i}.memberSet`)||ie.get(r,`${i}.memberChoice`)||ie.get(r,`${i}.memberList`)||[]));return t.filter(i=>i!=null)},XC=(r={})=>{let e=YC(r),t=r.language||"en";r.type==null&&(r.type=!0);let i=a=>{a=a||[];let u=[];for(let o of["from","to"]){r.schemes&&u.push(`${o}Scheme`);let l=Math.max(...a.map(p=>jr(p,o).length),1);for(let p=0;p<l;p+=1)u.push(`${o}Notation${p?p+1:""}`),r.labels&&u.push(`${o}Label${p?p+1:""}`)}return r.type&&u.push("type"),r.creator&&u.push("creator"),e(u)},n=(a,u={})=>{let o=[];for(let l of["from","to"]){r.schemes&&o.push(ie.get(a,`${l}Scheme.notation[0]`,""));let p=jr(a,l),b=u[`${l}Count`];b==null&&(b=p.length),b=Math.max(b,1);for(let _=0;_<b;_+=1)o.push(ie.get(p[_],"notation[0]","")),r.labels&&o.push(ft(p[_],{language:t,fallbackToUri:!1}))}return r.type&&o.push(ie.get($t(ie.get(a,"type[0]")),"SHORT","")),r.creator&&o.push(ft(ie.get(a,"creator[0]"),{language:t,fallbackToUri:!1})),e(o)};return{header:i,fromMapping:n,fromMappings:(a,u={header:!0})=>{let o="";u.header&&(o+=i(a));let l={fromCount:Math.max(...a.map(p=>jr(p,"from").length)),toCount:Math.max(...a.map(p=>jr(p,"to").length))};for(let p of a)o+=n(p,l);return o}}};function ZC(r,e){return ie.isEqualWith(r,e,(t,i,n)=>{let s={[n]:t},a={[n]:i};if(n=="from"||n=="to")return ie.isEqualWith(Object.getOwnPropertyNames(ie.get(t,n,{})),Object.getOwnPropertyNames(ie.get(i,n,{})))?ie.isEqualWith(jr(s,n),jr(a,n),(u,o,l)=>{if(l!=null)return vr(u,o)}):!1;if(n=="fromScheme"||n=="toScheme")return vr(t,i)})}var{objectTypes:QC,guessObjectType:ms}=Kp(),eE=(r,e)=>{let t=ms(r),i=ms(e);return!(t&&i&&t!=i)},rd=r=>{Array.isArray(r)&&r.sort((e,t)=>e===null?1:t===null?-1:0)},td=(r,e)=>(!r||!e||((Array.isArray(r.identifier)||Array.isArray(e.identifier))&&(r.identifier=ie.union(r.identifier||[],e.identifier||[])),!r.uri&&e.uri&&(r.uri=e.uri),r.uri&&e.uri&&r.uri!=e.uri&&!(r.identifier||[]).includes(e.uri)&&(r.identifier=(r.identifier||[]).concat([e.uri])),Array.isArray(r.identifier)&&r.uri&&(r.identifier=r.identifier.filter(t=>t!==r.uri)),(r.identifier||[]).length==0&&delete r.identifier,rd(r.identifier)),r),id=(r,e,t)=>{if(!r||!e)return r||e;t=t||{};let i=t._path||"",n=t.detectMismatch||[],s=t.skipPaths||[],a={};return ie.forOwn(r,(u,o)=>{if(!s.includes(i+o))if(Array.isArray(u)&&Array.isArray(e[o]))a[o]=ie.unionWith(u,e[o],(l,p)=>ie.isObject(l)&&ie.isObject(p)?vr(l,p):l===p),rd(a[o]);else if(ie.isObject(u)&&ie.isObject(e[o]))a[o]=id(u,e[o],Object.assign({_path:`${i}${o}.`},t));else{if(u&&e[o]&&n.includes(i+o)&&!ie.isEqualWith(u,e[o]))throw new Error("Property mismatch in "+i+o);a[o]=u}}),ie.forOwn(e,(u,o)=>{r[o]||(a[o]=u)}),i==""&&ie.omitMod(a,s),t.mergeUris&&td(a,e),a},gs=r=>Array.isArray(r)?r.map(e=>gs(e)):ie.isObject(r)?(ie.forOwn(r,(e,t)=>{r[t]=gs(e)}),r):ie.isString(r)?r.normalize():r,rE=r=>{var e=/^[A-Za-z][A-Za-z0-9+\-.]*:(?:\/\/(?:(?:[A-Za-z0-9\-._~!$&'()*+,;=:]|%[0-9A-Fa-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9A-Fa-f]{1,4}:){6}|::(?:[0-9A-Fa-f]{1,4}:){5}|(?:[0-9A-Fa-f]{1,4})?::(?:[0-9A-Fa-f]{1,4}:){4}|(?:(?:[0-9A-Fa-f]{1,4}:){0,1}[0-9A-Fa-f]{1,4})?::(?:[0-9A-Fa-f]{1,4}:){3}|(?:(?:[0-9A-Fa-f]{1,4}:){0,2}[0-9A-Fa-f]{1,4})?::(?:[0-9A-Fa-f]{1,4}:){2}|(?:(?:[0-9A-Fa-f]{1,4}:){0,3}[0-9A-Fa-f]{1,4})?::[0-9A-Fa-f]{1,4}:|(?:(?:[0-9A-Fa-f]{1,4}:){0,4}[0-9A-Fa-f]{1,4})?::)(?:[0-9A-Fa-f]{1,4}:[0-9A-Fa-f]{1,4}|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))|(?:(?:[0-9A-Fa-f]{1,4}:){0,5}[0-9A-Fa-f]{1,4})?::[0-9A-Fa-f]{1,4}|(?:(?:[0-9A-Fa-f]{1,4}:){0,6}[0-9A-Fa-f]{1,4})?::)|[Vv][0-9A-Fa-f]+\.[A-Za-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)|(?:[A-Za-z0-9\-._~!$&'()*+,;=]|%[0-9A-Fa-f]{2})*)(?::[0-9]*)?(?:\/(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})*)*|\/(?:(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})+(?:\/(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})*)*)?|(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})+(?:\/(?:[A-Za-z0-9\-._~!$&'()*+,;=:@]|%[0-9A-Fa-f]{2})*)*|)(?:\?(?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})*)?(?:#(?:[A-Za-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9A-Fa-f]{2})*)?$/;return r.match(e)!==null},tE={mappingsByConcepts:(r,e,t)=>{let i=["memberSet","memberList","memberChoice"],n,s;for(let a of i)n=n||ie.get(r,t+"."+a+"[0].notation[0]"),s=s||ie.get(e,t+"."+a+"[0].notation[0]");return n==null||n<s?-1:s==null||n>s?1:0}},iE=(r,e)=>!r||!e?!1:[r.uri].concat(Object.values(r.identities||{}).map(t=>t.uri)).filter(t=>t!=null).includes(ie.get(e,"creator[0].uri")),nE=hs(),sE=ps();function aE(r,e){let t;if(r&&r.notation&&r.notation.length)t=r.notation[0],(Xp(r)||e=="scheme")&&(t=t.toUpperCase());else if(r&&r.inScheme&&r.inScheme[0]&&r.uri)try{t=new nE(r&&r.inScheme&&r.inScheme[0]).notationFromUri(r.uri)}catch(i){}return t||""}function ys(r,e,{language:t}={}){let i=r&&e?r[e]:r;return i&&(i[t]||(t=sE.selectLanguage(i),t))?i[t]:null}function ft(r,e={}){e=e||{};let t=e.fallbackToUri==null?!0:e.fallbackToUri;return ie.get(r,`prefLabel.${e.language}`)||ys(r,"prefLabel",e)||(t&&r&&r.uri?r.uri:"")}function oE(r,e={}){e=e||{};let t=ie.get(r,`definition.${e.language}`)||ys(r,"definition",e)||[];return ie.isString(t)&&(t=[t]),t}function uE(r){return ie.get(r,"stored",ie.get(r,"constructor.stored",ie.get(r,"provider.constructor.stored",!1)))}function fE(r){return ie.isString(r.creator)?r.creator:r.creator&&r.creator.id}function cE(r){return ie.get(r,"creator.name")||""}function lE(r,e){return!!(r&&ie.isString(r.creator)?e&&e.includes(r.creator):e&&r.creator&&e.includes(r.creator.id))}nd.exports={addContext:UC,clean:vs,cleanJSKOS:DC,copyDeep:Mi,deepCopy:FC,getAllUris:ds,compare:vr,compareObjects:BC,compareSchemes:kC,compareConcepts:$C,isConcept:zC,isScheme:Xp,isContainedIn:Zp,isSchemeInList:WC,sortConcepts:HC,sortSchemes:GC,minifyMapping:KC,mappingTypes:Qp,mappingTypeByUri:$t,mappingTypeByType:JC,flattenMapping:VC,mappingCSV:XC,defaultMappingType:ed,conceptsOfMapping:jr,compareMappingsDeep:ZC,objectTypes:QC,guessObjectType:ms,matchObjectTypes:eE,mergeUris:td,merge:id,normalize:gs,isValidUri:rE,compareFunctions:tE,userOwnsMapping:iE,notation:aE,languageMapContent:ys,prefLabel:ft,definition:oE,mappingRegistryIsStored:uE,annotationCreatorUri:fE,annotationCreatorName:cE,annotationCreatorMatches:lE}});var He=g((EP,ad)=>{var hE=zp(),pE=sd(),dE=hs(),mE=ps();ad.exports=Object.assign({ConceptScheme:dE,languagePreference:mE},hE,pE)});var ud=g((od,ws)=>{(function(r){if(typeof od=="object"&&typeof ws!="undefined")ws.exports=r();else if(typeof define=="function"&&define.amd)define([],r);else{var e;typeof window!="undefined"?e=window:typeof global!="undefined"?e=global:typeof self!="undefined"?e=self:e=this,e.localforage=r()}})(function(){var r,e,t;return function i(n,s,a){function u(p,b){if(!s[p]){if(!n[p]){var _=typeof gt=="function"&>if(!b&&_)return _(p,!0);if(o)return o(p,!0);var q=new Error("Cannot find module '"+p+"'");throw q.code="MODULE_NOT_FOUND",q}var y=s[p]={exports:{}};n[p][0].call(y.exports,function(E){var H=n[p][1][E];return u(H||E)},y,y.exports,i,n,s,a)}return s[p].exports}for(var o=typeof gt=="function"&>,l=0;l<a.length;l++)u(a[l]);return u}({1:[function(i,n,s){(function(a){"use strict";var u=a.MutationObserver||a.WebKitMutationObserver,o;if(u){var l=0,p=new u(E),b=a.document.createTextNode("");p.observe(b,{characterData:!0}),o=function(){b.data=l=++l%2}}else if(!a.setImmediate&&typeof a.MessageChannel!="undefined"){var _=new a.MessageChannel;_.port1.onmessage=E,o=function(){_.port2.postMessage(0)}}else"document"in a&&"onreadystatechange"in a.document.createElement("script")?o=function(){var K=a.document.createElement("script");K.onreadystatechange=function(){E(),K.onreadystatechange=null,K.parentNode.removeChild(K),K=null},a.document.documentElement.appendChild(K)}:o=function(){setTimeout(E,0)};var q,y=[];function E(){q=!0;for(var K,Q,F=y.length;F;){for(Q=y,y=[],K=-1;++K<F;)Q[K]();F=y.length}q=!1}n.exports=H;function H(K){y.push(K)===1&&!q&&o()}}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],2:[function(i,n,s){"use strict";var a=i(1);function u(){}var o={},l=["REJECTED"],p=["FULFILLED"],b=["PENDING"];n.exports=_;function _(O){if(typeof O!="function")throw new TypeError("resolver must be a function");this.state=b,this.queue=[],this.outcome=void 0,O!==u&&H(this,O)}_.prototype.catch=function(O){return this.then(null,O)},_.prototype.then=function(O,ee){if(typeof O!="function"&&this.state===p||typeof ee!="function"&&this.state===l)return this;var G=new this.constructor(u);if(this.state!==b){var de=this.state===p?O:ee;y(G,de,this.outcome)}else this.queue.push(new q(G,O,ee));return G};function q(O,ee,G){this.promise=O,typeof ee=="function"&&(this.onFulfilled=ee,this.callFulfilled=this.otherCallFulfilled),typeof G=="function"&&(this.onRejected=G,this.callRejected=this.otherCallRejected)}q.prototype.callFulfilled=function(O){o.resolve(this.promise,O)},q.prototype.otherCallFulfilled=function(O){y(this.promise,this.onFulfilled,O)},q.prototype.callRejected=function(O){o.reject(this.promise,O)},q.prototype.otherCallRejected=function(O){y(this.promise,this.onRejected,O)};function y(O,ee,G){a(function(){var de;try{de=ee(G)}catch(qe){return o.reject(O,qe)}de===O?o.reject(O,new TypeError("Cannot resolve promise with itself")):o.resolve(O,de)})}o.resolve=function(O,ee){var G=K(E,ee);if(G.status==="error")return o.reject(O,G.value);var de=G.value;if(de)H(O,de);else{O.state=p,O.outcome=ee;for(var qe=-1,ve=O.queue.length;++qe<ve;)O.queue[qe].callFulfilled(ee)}return O},o.reject=function(O,ee){O.state=l,O.outcome=ee;for(var G=-1,de=O.queue.length;++G<de;)O.queue[G].callRejected(ee);return O};function E(O){var ee=O&&O.then;if(O&&(typeof O=="object"||typeof O=="function")&&typeof ee=="function")return function(){ee.apply(O,arguments)}}function H(O,ee){var G=!1;function de(Te){G||(G=!0,o.reject(O,Te))}function qe(Te){G||(G=!0,o.resolve(O,Te))}function ve(){ee(qe,de)}var Ne=K(ve);Ne.status==="error"&&de(Ne.value)}function K(O,ee){var G={};try{G.value=O(ee),G.status="success"}catch(de){G.status="error",G.value=de}return G}_.resolve=Q;function Q(O){return O instanceof this?O:o.resolve(new this(u),O)}_.reject=F;function F(O){var ee=new this(u);return o.reject(ee,O)}_.all=Z;function Z(O){var ee=this;if(Object.prototype.toString.call(O)!=="[object Array]")return this.reject(new TypeError("must be an array"));var G=O.length,de=!1;if(!G)return this.resolve([]);for(var qe=new Array(G),ve=0,Ne=-1,Te=new this(u);++Ne<G;)Ke(O[Ne],Ne);return Te;function Ke(cr,Er){ee.resolve(cr).then(ze,function(lr){de||(de=!0,o.reject(Te,lr))});function ze(lr){qe[Er]=lr,++ve===G&&!de&&(de=!0,o.resolve(Te,qe))}}}_.race=te;function te(O){var ee=this;if(Object.prototype.toString.call(O)!=="[object Array]")return this.reject(new TypeError("must be an array"));var G=O.length,de=!1;if(!G)return this.resolve([]);for(var qe=-1,ve=new this(u);++qe<G;)Ne(O[qe]);return ve;function Ne(Te){ee.resolve(Te).then(function(Ke){de||(de=!0,o.resolve(ve,Ke))},function(Ke){de||(de=!0,o.reject(ve,Ke))})}}},{1:1}],3:[function(i,n,s){(function(a){"use strict";typeof a.Promise!="function"&&(a.Promise=i(2))}).call(this,typeof global!="undefined"?global:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{2:2}],4:[function(i,n,s){"use strict";var a=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(f){return typeof f}:function(f){return f&&typeof Symbol=="function"&&f.constructor===Symbol&&f!==Symbol.prototype?"symbol":typeof f};function u(f,v){if(!(f instanceof v))throw new TypeError("Cannot call a class as a function")}function o(){try{if(typeof indexedDB!="undefined")return indexedDB;if(typeof webkitIndexedDB!="undefined")return webkitIndexedDB;if(typeof mozIndexedDB!="undefined")return mozIndexedDB;if(typeof OIndexedDB!="undefined")return OIndexedDB;if(typeof msIndexedDB!="undefined")return msIndexedDB}catch(f){return}}var l=o();function p(){try{if(!l||!l.open)return!1;var f=typeof openDatabase!="undefined"&&/(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent)&&!/Chrome/.test(navigator.userAgent)&&!/BlackBerry/.test(navigator.platform),v=typeof fetch=="function"&&fetch.toString().indexOf("[native code")!==-1;return(!f||v)&&typeof indexedDB!="undefined"&&typeof IDBKeyRange!="undefined"}catch(c){return!1}}function b(f,v){f=f||[],v=v||{};try{return new Blob(f,v)}catch(w){if(w.name!=="TypeError")throw w;for(var c=typeof BlobBuilder!="undefined"?BlobBuilder:typeof MSBlobBuilder!="undefined"?MSBlobBuilder:typeof MozBlobBuilder!="undefined"?MozBlobBuilder:WebKitBlobBuilder,x=new c,S=0;S<f.length;S+=1)x.append(f[S]);return x.getBlob(v.type)}}typeof Promise=="undefined"&&i(3);var _=Promise;function q(f,v){v&&f.then(function(c){v(null,c)},function(c){v(c)})}function y(f,v,c){typeof v=="function"&&f.then(v),typeof c=="function"&&f.catch(c)}function E(f){return typeof f!="string"&&(console.warn(f+" used as a key, but it is not a string."),f=String(f)),f}function H(){if(arguments.length&&typeof arguments[arguments.length-1]=="function")return arguments[arguments.length-1]}var K="local-forage-detect-blob-support",Q=void 0,F={},Z=Object.prototype.toString,te="readonly",O="readwrite";function ee(f){for(var v=f.length,c=new ArrayBuffer(v),x=new Uint8Array(c),S=0;S<v;S++)x[S]=f.charCodeAt(S);return c}function G(f){return new _(function(v){var c=f.transaction(K,O),x=b([""]);c.objectStore(K).put(x,"key"),c.onabort=function(S){S.preventDefault(),S.stopPropagation(),v(!1)},c.oncomplete=function(){var S=navigator.userAgent.match(/Chrome\/(\d+)/),w=navigator.userAgent.match(/Edge\//);v(w||!S||parseInt(S[1],10)>=43)}}).catch(function(){return!1})}function de(f){return typeof Q=="boolean"?_.resolve(Q):G(f).then(function(v){return Q=v,Q})}function qe(f){var v=F[f.name],c={};c.promise=new _(function(x,S){c.resolve=x,c.reject=S}),v.deferredOperations.push(c),v.dbReady?v.dbReady=v.dbReady.then(function(){return c.promise}):v.dbReady=c.promise}function ve(f){var v=F[f.name],c=v.deferredOperations.pop();if(c)return c.resolve(),c.promise}function Ne(f,v){var c=F[f.name],x=c.deferredOperations.pop();if(x)return x.reject(v),x.promise}function Te(f,v){return new _(function(c,x){if(F[f.name]=F[f.name]||m(),f.db)if(v)qe(f),f.db.close();else return c(f.db);var S=[f.name];v&&S.push(f.version);var w=l.open.apply(l,S);v&&(w.onupgradeneeded=function(I){var L=w.result;try{L.createObjectStore(f.storeName),I.oldVersion<=1&&L.createObjectStore(K)}catch(U){if(U.name==="ConstraintError")console.warn('The database "'+f.name+'" has been upgraded from version '+I.oldVersion+" to version "+I.newVersion+', but the storage "'+f.storeName+'" already exists.');else throw U}}),w.onerror=function(I){I.preventDefault(),x(w.error)},w.onsuccess=function(){var I=w.result;I.onversionchange=function(L){L.target.close()},c(I),ve(f)}})}function Ke(f){return Te(f,!1)}function cr(f){return Te(f,!0)}function Er(f,v){if(!f.db)return!0;var c=!f.db.objectStoreNames.contains(f.storeName),x=f.version<f.db.version,S=f.version>f.db.version;if(x&&(f.version!==v&&console.warn('The database "'+f.name+`" can't be downgraded from version `+f.db.version+" to version "+f.version+"."),f.version=f.db.version),S||c){if(c){var w=f.db.version+1;w>f.version&&(f.version=w)}return!0}return!1}function ze(f){return new _(function(v,c){var x=new FileReader;x.onerror=c,x.onloadend=function(S){var w=btoa(S.target.result||"");v({__local_forage_encoded_blob:!0,data:w,type:f.type})},x.readAsBinaryString(f)})}function lr(f){var v=ee(atob(f.data));return b([v],{type:f.type})}function sr(f){return f&&f.__local_forage_encoded_blob}function ki(f){var v=this,c=v._initReady().then(function(){var x=F[v._dbInfo.name];if(x&&x.dbReady)return x.dbReady});return y(c,f,f),c}function h(f){qe(f);for(var v=F[f.name],c=v.forages,x=0;x<c.length;x++){var S=c[x];S._dbInfo.db&&(S._dbInfo.db.close(),S._dbInfo.db=null)}return f.db=null,Ke(f).then(function(w){return f.db=w,Er(f)?cr(f):w}).then(function(w){f.db=v.db=w;for(var I=0;I<c.length;I++)c[I]._dbInfo.db=w}).catch(function(w){throw Ne(f,w),w})}function d(f,v,c,x){x===void 0&&(x=1);try{var S=f.db.transaction(f.storeName,v);c(null,S)}catch(w){if(x>0&&(!f.db||w.name==="InvalidStateError"||w.name==="NotFoundError"))return _.resolve().then(function(){if(!f.db||w.name==="NotFoundError"&&!f.db.objectStoreNames.contains(f.storeName)&&f.version<=f.db.version)return f.db&&(f.version=f.db.version+1),cr(f)}).then(function(){return h(f).then(function(){d(f,v,c,x-1)})}).catch(c);c(w)}}function m(){return{forages:[],db:null,dbReady:null,deferredOperations:[]}}function A(f){var v=this,c={db:null};if(f)for(var x in f)c[x]=f[x];var S=F[c.name];S||(S=m(),F[c.name]=S),S.forages.push(v),v._initReady||(v._initReady=v.ready,v.ready=ki);var w=[];function I(){return _.resolve()}for(var L=0;L<S.forages.length;L++){var U=S.forages[L];U!==v&&w.push(U._initReady().catch(I))}var D=S.forages.slice(0);return _.all(w).then(function(){return c.db=S.db,Ke(c)}).then(function(k){return c.db=k,Er(c,v._defaultConfig.version)?cr(c):k}).then(function(k){c.db=S.db=k,v._dbInfo=c;for(var X=0;X<D.length;X++){var ue=D[X];ue!==v&&(ue._dbInfo.db=c.db,ue._dbInfo.version=c.version)}})}function C(f,v){var c=this;f=E(f);var x=new _(function(S,w){c.ready().then(function(){d(c._dbInfo,te,function(I,L){if(I)return w(I);try{var U=L.objectStore(c._dbInfo.storeName),D=U.get(f);D.onsuccess=function(){var k=D.result;k===void 0&&(k=null),sr(k)&&(k=lr(k)),S(k)},D.onerror=function(){w(D.error)}}catch(k){w(k)}})}).catch(w)});return q(x,v),x}function T(f,v){var c=this,x=new _(function(S,w){c.ready().then(function(){d(c._dbInfo,te,function(I,L){if(I)return w(I);try{var U=L.objectStore(c._dbInfo.storeName),D=U.openCursor(),k=1;D.onsuccess=function(){var X=D.result;if(X){var ue=X.value;sr(ue)&&(ue=lr(ue));var pe=f(ue,X.key,k++);pe!==void 0?S(pe):X.continue()}else S()},D.onerror=function(){w(D.error)}}catch(X){w(X)}})}).catch(w)});return q(x,v),x}function M(f,v,c){var x=this;f=E(f);var S=new _(function(w,I){var L;x.ready().then(function(){return L=x._dbInfo,Z.call(v)==="[object Blob]"?de(L.db).then(function(U){return U?v:ze(v)}):v}).then(function(U){d(x._dbInfo,O,function(D,k){if(D)return I(D);try{var X=k.objectStore(x._dbInfo.storeName);U===null&&(U=void 0);var ue=X.put(U,f);k.oncomplete=function(){U===void 0&&(U=null),w(U)},k.onabort=k.onerror=function(){var pe=ue.error?ue.error:ue.transaction.error;I(pe)}}catch(pe){I(pe)}})}).catch(I)});return q(S,c),S}function P(f,v){var c=this;f=E(f);var x=new _(function(S,w){c.ready().then(function(){d(c._dbInfo,O,function(I,L){if(I)return w(I);try{var U=L.objectStore(c._dbInfo.storeName),D=U.delete(f);L.oncomplete=function(){S()},L.onerror=function(){w(D.error)},L.onabort=function(){var k=D.error?D.error:D.transaction.error;w(k)}}catch(k){w(k)}})}).catch(w)});return q(x,v),x}function N(f){var v=this,c=new _(function(x,S){v.ready().then(function(){d(v._dbInfo,O,function(w,I){if(w)return S(w);try{var L=I.objectStore(v._dbInfo.storeName),U=L.clear();I.oncomplete=function(){x()},I.onabort=I.onerror=function(){var D=U.error?U.error:U.transaction.error;S(D)}}catch(D){S(D)}})}).catch(S)});return q(c,f),c}function B(f){var v=this,c=new _(function(x,S){v.ready().then(function(){d(v._dbInfo,te,function(w,I){if(w)return S(w);try{var L=I.objectStore(v._dbInfo.storeName),U=L.count();U.onsuccess=function(){x(U.result)},U.onerror=function(){S(U.error)}}catch(D){S(D)}})}).catch(S)});return q(c,f),c}function Y(f,v){var c=this,x=new _(function(S,w){if(f<0){S(null);return}c.ready().then(function(){d(c._dbInfo,te,function(I,L){if(I)return w(I);try{var U=L.objectStore(c._dbInfo.storeName),D=!1,k=U.openKeyCursor();k.onsuccess=function(){var X=k.result;if(!X){S(null);return}f===0||D?S(X.key):(D=!0,X.advance(f))},k.onerror=function(){w(k.error)}}catch(X){w(X)}})}).catch(w)});return q(x,v),x}function V(f){var v=this,c=new _(function(x,S){v.ready().then(function(){d(v._dbInfo,te,function(w,I){if(w)return S(w);try{var L=I.objectStore(v._dbInfo.storeName),U=L.openKeyCursor(),D=[];U.onsuccess=function(){var k=U.result;if(!k){x(D);return}D.push(k.key),k.continue()},U.onerror=function(){S(U.error)}}catch(k){S(k)}})}).catch(S)});return q(c,f),c}function z(f,v){v=H.apply(this,arguments);var c=this.config();f=typeof f!="function"&&f||{},f.name||(f.name=f.name||c.name,f.storeName=f.storeName||c.storeName);var x=this,S;if(!f.name)S=_.reject("Invalid arguments");else{var w=f.name===c.name&&x._dbInfo.db,I=w?_.resolve(x._dbInfo.db):Ke(f).then(function(L){var U=F[f.name],D=U.forages;U.db=L;for(var k=0;k<D.length;k++)D[k]._dbInfo.db=L;return L});f.storeName?S=I.then(function(L){if(!!L.objectStoreNames.contains(f.storeName)){var U=L.version+1;qe(f);var D=F[f.name],k=D.forages;L.close();for(var X=0;X<k.length;X++){var ue=k[X];ue._dbInfo.db=null,ue._dbInfo.version=U}var pe=new _(function(me,Oe){var Se=l.open(f.name,U);Se.onerror=function(Ge){var dt=Se.result;dt.close(),Oe(Ge)},Se.onupgradeneeded=function(){var Ge=Se.result;Ge.deleteObjectStore(f.storeName)},Se.onsuccess=function(){var Ge=Se.result;Ge.close(),me(Ge)}});return pe.then(function(me){D.db=me;for(var Oe=0;Oe<k.length;Oe++){var Se=k[Oe];Se._dbInfo.db=me,ve(Se._dbInfo)}}).catch(function(me){throw(Ne(f,me)||_.resolve()).catch(function(){}),me})}}):S=I.then(function(L){qe(f);var U=F[f.name],D=U.forages;L.close();for(var k=0;k<D.length;k++){var X=D[k];X._dbInfo.db=null}var ue=new _(function(pe,me){var Oe=l.deleteDatabase(f.name);Oe.onerror=function(){var Se=Oe.result;Se&&Se.close(),me(Oe.error)},Oe.onblocked=function(){console.warn('dropInstance blocked for database "'+f.name+'" until all open connections are closed')},Oe.onsuccess=function(){var Se=Oe.result;Se&&Se.close(),pe(Se)}});return ue.then(function(pe){U.db=pe;for(var me=0;me<D.length;me++){var Oe=D[me];ve(Oe._dbInfo)}}).catch(function(pe){throw(Ne(f,pe)||_.resolve()).catch(function(){}),pe})})}return q(S,v),S}var ae={_driver:"asyncStorage",_initStorage:A,_support:p(),iterate:T,getItem:C,setItem:M,removeItem:P,clear:N,length:B,key:Y,keys:V,dropInstance:z};function se(){return typeof openDatabase=="function"}var ce="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ye="~~local_forage_type~",ge=/^~~local_forage_type~([^~]+)~/,ne="__lfsc__:",oe=ne.length,he="arbf",Ue="blob",Ce="si08",Pe="ui08",Je="uic8",$r="si16",Ir="si32",zr="ur16",Tr="ui32",Gt="fl32",Pr="fl64",Is=oe+he.length,Ts=Object.prototype.toString;function Ps(f){var v=f.length*.75,c=f.length,x,S=0,w,I,L,U;f[f.length-1]==="="&&(v--,f[f.length-2]==="="&&v--);var D=new ArrayBuffer(v),k=new Uint8Array(D);for(x=0;x<c;x+=4)w=ce.indexOf(f[x]),I=ce.indexOf(f[x+1]),L=ce.indexOf(f[x+2]),U=ce.indexOf(f[x+3]),k[S++]=w<<2|I>>4,k[S++]=(I&15)<<4|L>>2,k[S++]=(L&3)<<6|U&63;return D}function $i(f){var v=new Uint8Array(f),c="",x;for(x=0;x<v.length;x+=3)c+=ce[v[x]>>2],c+=ce[(v[x]&3)<<4|v[x+1]>>4],c+=ce[(v[x+1]&15)<<2|v[x+2]>>6],c+=ce[v[x+2]&63];return v.length%3===2?c=c.substring(0,c.length-1)+"=":v.length%3===1&&(c=c.substring(0,c.length-2)+"=="),c}function vd(f,v){var c="";if(f&&(c=Ts.call(f)),f&&(c==="[object ArrayBuffer]"||f.buffer&&Ts.call(f.buffer)==="[object ArrayBuffer]")){var x,S=ne;f instanceof ArrayBuffer?(x=f,S+=he):(x=f.buffer,c==="[object Int8Array]"?S+=Ce:c==="[object Uint8Array]"?S+=Pe:c==="[object Uint8ClampedArray]"?S+=Je:c==="[object Int16Array]"?S+=$r:c==="[object Uint16Array]"?S+=zr:c==="[object Int32Array]"?S+=Ir:c==="[object Uint32Array]"?S+=Tr:c==="[object Float32Array]"?S+=Gt:c==="[object Float64Array]"?S+=Pr:v(new Error("Failed to get type for BinaryArray"))),v(S+$i(x))}else if(c==="[object Blob]"){var w=new FileReader;w.onload=function(){var I=ye+f.type+"~"+$i(this.result);v(ne+Ue+I)},w.readAsArrayBuffer(f)}else try{v(JSON.stringify(f))}catch(I){console.error("Couldn't convert value into a JSON string: ",f),v(null,I)}}function yd(f){if(f.substring(0,oe)!==ne)return JSON.parse(f);var v=f.substring(Is),c=f.substring(oe,Is),x;if(c===Ue&&ge.test(v)){var S=v.match(ge);x=S[1],v=v.substring(S[0].length)}var w=Ps(v);switch(c){case he:return w;case Ue:return b([w],{type:x});case Ce:return new Int8Array(w);case Pe:return new Uint8Array(w);case Je:return new Uint8ClampedArray(w);case $r:return new Int16Array(w);case zr:return new Uint16Array(w);case Ir:return new Int32Array(w);case Tr:return new Uint32Array(w);case Gt:return new Float32Array(w);case Pr:return new Float64Array(w);default:throw new Error("Unkown type: "+c)}}var zi={serialize:vd,deserialize:yd,stringToBuffer:Ps,bufferToString:$i};function Ms(f,v,c,x){f.executeSql("CREATE TABLE IF NOT EXISTS "+v.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],c,x)}function _d(f){var v=this,c={db:null};if(f)for(var x in f)c[x]=typeof f[x]!="string"?f[x].toString():f[x];var S=new _(function(w,I){try{c.db=openDatabase(c.name,String(c.version),c.description,c.size)}catch(L){return I(L)}c.db.transaction(function(L){Ms(L,c,function(){v._dbInfo=c,w()},function(U,D){I(D)})},I)});return c.serializer=zi,S}function hr(f,v,c,x,S,w){f.executeSql(c,x,S,function(I,L){L.code===L.SYNTAX_ERR?I.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[v.storeName],function(U,D){D.rows.length?w(U,L):Ms(U,v,function(){U.executeSql(c,x,S,w)},w)},w):w(I,L)},w)}function wd(f,v){var c=this;f=E(f);var x=new _(function(S,w){c.ready().then(function(){var I=c._dbInfo;I.db.transaction(function(L){hr(L,I,"SELECT * FROM "+I.storeName+" WHERE key = ? LIMIT 1",[f],function(U,D){var k=D.rows.length?D.rows.item(0).value:null;k&&(k=I.serializer.deserialize(k)),S(k)},function(U,D){w(D)})})}).catch(w)});return q(x,v),x}function bd(f,v){var c=this,x=new _(function(S,w){c.ready().then(function(){var I=c._dbInfo;I.db.transaction(function(L){hr(L,I,"SELECT * FROM "+I.storeName,[],function(U,D){for(var k=D.rows,X=k.length,ue=0;ue<X;ue++){var pe=k.item(ue),me=pe.value;if(me&&(me=I.serializer.deserialize(me)),me=f(me,pe.key,ue+1),me!==void 0){S(me);return}}S()},function(U,D){w(D)})})}).catch(w)});return q(x,v),x}function Rs(f,v,c,x){var S=this;f=E(f);var w=new _(function(I,L){S.ready().then(function(){v===void 0&&(v=null);var U=v,D=S._dbInfo;D.serializer.serialize(v,function(k,X){X?L(X):D.db.transaction(function(ue){hr(ue,D,"INSERT OR REPLACE INTO "+D.storeName+" (key, value) VALUES (?, ?)",[f,k],function(){I(U)},function(pe,me){L(me)})},function(ue){if(ue.code===ue.QUOTA_ERR){if(x>0){I(Rs.apply(S,[f,U,c,x-1]));return}L(ue)}})})}).catch(L)});return q(w,c),w}function xd(f,v,c){return Rs.apply(this,[f,v,c,1])}function Sd(f,v){var c=this;f=E(f);var x=new _(function(S,w){c.ready().then(function(){var I=c._dbInfo;I.db.transaction(function(L){hr(L,I,"DELETE FROM "+I.storeName+" WHERE key = ?",[f],function(){S()},function(U,D){w(D)})})}).catch(w)});return q(x,v),x}function Ad(f){var v=this,c=new _(function(x,S){v.ready().then(function(){var w=v._dbInfo;w.db.transaction(function(I){hr(I,w,"DELETE FROM "+w.storeName,[],function(){x()},function(L,U){S(U)})})}).catch(S)});return q(c,f),c}function Od(f){var v=this,c=new _(function(x,S){v.ready().then(function(){var w=v._dbInfo;w.db.transaction(function(I){hr(I,w,"SELECT COUNT(key) as c FROM "+w.storeName,[],function(L,U){var D=U.rows.item(0).c;x(D)},function(L,U){S(U)})})}).catch(S)});return q(c,f),c}function qd(f,v){var c=this,x=new _(function(S,w){c.ready().then(function(){var I=c._dbInfo;I.db.transaction(function(L){hr(L,I,"SELECT key FROM "+I.storeName+" WHERE id = ? LIMIT 1",[f+1],function(U,D){var k=D.rows.length?D.rows.item(0).key:null;S(k)},function(U,D){w(D)})})}).catch(w)});return q(x,v),x}function Cd(f){var v=this,c=new _(function(x,S){v.ready().then(function(){var w=v._dbInfo;w.db.transaction(function(I){hr(I,w,"SELECT key FROM "+w.storeName,[],function(L,U){for(var D=[],k=0;k<U.rows.length;k++)D.push(U.rows.item(k).key);x(D)},function(L,U){S(U)})})}).catch(S)});return q(c,f),c}function Ed(f){return new _(function(v,c){f.transaction(function(x){x.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name <> '__WebKitDatabaseInfoTable__'",[],function(S,w){for(var I=[],L=0;L<w.rows.length;L++)I.push(w.rows.item(L).name);v({db:f,storeNames:I})},function(S,w){c(w)})},function(x){c(x)})})}function Id(f,v){v=H.apply(this,arguments);var c=this.config();f=typeof f!="function"&&f||{},f.name||(f.name=f.name||c.name,f.storeName=f.storeName||c.storeName);var x=this,S;return f.name?S=new _(function(w){var I;f.name===c.name?I=x._dbInfo.db:I=openDatabase(f.name,"","",0),f.storeName?w({db:I,storeNames:[f.storeName]}):w(Ed(I))}).then(function(w){return new _(function(I,L){w.db.transaction(function(U){function D(pe){return new _(function(me,Oe){U.executeSql("DROP TABLE IF EXISTS "+pe,[],function(){me()},function(Se,Ge){Oe(Ge)})})}for(var k=[],X=0,ue=w.storeNames.length;X<ue;X++)k.push(D(w.storeNames[X]));_.all(k).then(function(){I()}).catch(function(pe){L(pe)})},function(U){L(U)})})}):S=_.reject("Invalid arguments"),q(S,v),S}var Td={_driver:"webSQLStorage",_initStorage:_d,_support:se(),iterate:bd,getItem:wd,setItem:xd,removeItem:Sd,clear:Ad,length:Od,key:qd,keys:Cd,dropInstance:Id};function Pd(){try{return typeof localStorage!="undefined"&&"setItem"in localStorage&&!!localStorage.setItem}catch(f){return!1}}function Ls(f,v){var c=f.name+"/";return f.storeName!==v.storeName&&(c+=f.storeName+"/"),c}function Md(){var f="_localforage_support_test";try{return localStorage.setItem(f,!0),localStorage.removeItem(f),!1}catch(v){return!0}}function Rd(){return!Md()||localStorage.length>0}function Ld(f){var v=this,c={};if(f)for(var x in f)c[x]=f[x];return c.keyPrefix=Ls(f,v._defaultConfig),Rd()?(v._dbInfo=c,c.serializer=zi,_.resolve()):_.reject()}function jd(f){var v=this,c=v.ready().then(function(){for(var x=v._dbInfo.keyPrefix,S=localStorage.length-1;S>=0;S--){var w=localStorage.key(S);w.indexOf(x)===0&&localStorage.removeItem(w)}});return q(c,f),c}function Nd(f,v){var c=this;f=E(f);var x=c.ready().then(function(){var S=c._dbInfo,w=localStorage.getItem(S.keyPrefix+f);return w&&(w=S.serializer.deserialize(w)),w});return q(x,v),x}function Ud(f,v){var c=this,x=c.ready().then(function(){for(var S=c._dbInfo,w=S.keyPrefix,I=w.length,L=localStorage.length,U=1,D=0;D<L;D++){var k=localStorage.key(D);if(k.indexOf(w)===0){var X=localStorage.getItem(k);if(X&&(X=S.serializer.deserialize(X)),X=f(X,k.substring(I),U++),X!==void 0)return X}}});return q(x,v),x}function Dd(f,v){var c=this,x=c.ready().then(function(){var S=c._dbInfo,w;try{w=localStorage.key(f)}catch(I){w=null}return w&&(w=w.substring(S.keyPrefix.length)),w});return q(x,v),x}function Fd(f){var v=this,c=v.ready().then(function(){for(var x=v._dbInfo,S=localStorage.length,w=[],I=0;I<S;I++){var L=localStorage.key(I);L.indexOf(x.keyPrefix)===0&&w.push(L.substring(x.keyPrefix.length))}return w});return q(c,f),c}function Bd(f){var v=this,c=v.keys().then(function(x){return x.length});return q(c,f),c}function kd(f,v){var c=this;f=E(f);var x=c.ready().then(function(){var S=c._dbInfo;localStorage.removeItem(S.keyPrefix+f)});return q(x,v),x}function $d(f,v,c){var x=this;f=E(f);var S=x.ready().then(function(){v===void 0&&(v=null);var w=v;return new _(function(I,L){var U=x._dbInfo;U.serializer.serialize(v,function(D,k){if(k)L(k);else try{localStorage.setItem(U.keyPrefix+f,D),I(w)}catch(X){(X.name==="QuotaExceededError"||X.name==="NS_ERROR_DOM_QUOTA_REACHED")&&L(X),L(X)}})})});return q(S,c),S}function zd(f,v){if(v=H.apply(this,arguments),f=typeof f!="function"&&f||{},!f.name){var c=this.config();f.name=f.name||c.name,f.storeName=f.storeName||c.storeName}var x=this,S;return f.name?S=new _(function(w){f.storeName?w(Ls(f,x._defaultConfig)):w(f.name+"/")}).then(function(w){for(var I=localStorage.length-1;I>=0;I--){var L=localStorage.key(I);L.indexOf(w)===0&&localStorage.removeItem(L)}}):S=_.reject("Invalid arguments"),q(S,v),S}var Wd={_driver:"localStorageWrapper",_initStorage:Ld,_support:Pd(),iterate:Ud,getItem:Nd,setItem:$d,removeItem:kd,clear:jd,length:Bd,key:Dd,keys:Fd,dropInstance:zd},Hd=function(v,c){return v===c||typeof v=="number"&&typeof c=="number"&&isNaN(v)&&isNaN(c)},Gd=function(v,c){for(var x=v.length,S=0;S<x;){if(Hd(v[S],c))return!0;S++}return!1},js=Array.isArray||function(f){return Object.prototype.toString.call(f)==="[object Array]"},pt={},Ns={},Wr={INDEXEDDB:ae,WEBSQL:Td,LOCALSTORAGE:Wd},Kd=[Wr.INDEXEDDB._driver,Wr.WEBSQL._driver,Wr.LOCALSTORAGE._driver],Kt=["dropInstance"],Wi=["clear","getItem","iterate","key","keys","length","removeItem","setItem"].concat(Kt),Jd={description:"",driver:Kd.slice(),name:"localforage",size:4980736,storeName:"keyvaluepairs",version:1};function Vd(f,v){f[v]=function(){var c=arguments;return f.ready().then(function(){return f[v].apply(f,c)})}}function Hi(){for(var f=1;f<arguments.length;f++){var v=arguments[f];if(v)for(var c in v)v.hasOwnProperty(c)&&(js(v[c])?arguments[0][c]=v[c].slice():arguments[0][c]=v[c])}return arguments[0]}var Yd=function(){function f(v){u(this,f);for(var c in Wr)if(Wr.hasOwnProperty(c)){var x=Wr[c],S=x._driver;this[c]=S,pt[S]||this.defineDriver(x)}this._defaultConfig=Hi({},Jd),this._config=Hi({},this._defaultConfig,v),this._driverSet=null,this._initDriver=null,this._ready=!1,this._dbInfo=null,this._wrapLibraryMethodsWithReady(),this.setDriver(this._config.driver).catch(function(){})}return f.prototype.config=function(c){if((typeof c=="undefined"?"undefined":a(c))==="object"){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var x in c){if(x==="storeName"&&(c[x]=c[x].replace(/\W/g,"_")),x==="version"&&typeof c[x]!="number")return new Error("Database version must be a number.");this._config[x]=c[x]}return"driver"in c&&c.driver?this.setDriver(this._config.driver):!0}else return typeof c=="string"?this._config[c]:this._config},f.prototype.defineDriver=function(c,x,S){var w=new _(function(I,L){try{var U=c._driver,D=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!c._driver){L(D);return}for(var k=Wi.concat("_initStorage"),X=0,ue=k.length;X<ue;X++){var pe=k[X],me=!Gd(Kt,pe);if((me||c[pe])&&typeof c[pe]!="function"){L(D);return}}var Oe=function(){for(var dt=function(Qd){return function(){var em=new Error("Method "+Qd+" is not implemented by the current driver"),Us=_.reject(em);return q(Us,arguments[arguments.length-1]),Us}},Gi=0,Zd=Kt.length;Gi<Zd;Gi++){var Ki=Kt[Gi];c[Ki]||(c[Ki]=dt(Ki))}};Oe();var Se=function(dt){pt[U]&&console.info("Redefining LocalForage driver: "+U),pt[U]=c,Ns[U]=dt,I()};"_support"in c?c._support&&typeof c._support=="function"?c._support().then(Se,L):Se(!!c._support):Se(!0)}catch(Ge){L(Ge)}});return y(w,x,S),w},f.prototype.driver=function(){return this._driver||null},f.prototype.getDriver=function(c,x,S){var w=pt[c]?_.resolve(pt[c]):_.reject(new Error("Driver not found."));return y(w,x,S),w},f.prototype.getSerializer=function(c){var x=_.resolve(zi);return y(x,c),x},f.prototype.ready=function(c){var x=this,S=x._driverSet.then(function(){return x._ready===null&&(x._ready=x._initDriver()),x._ready});return y(S,c,c),S},f.prototype.setDriver=function(c,x,S){var w=this;js(c)||(c=[c]);var I=this._getSupportedDrivers(c);function L(){w._config.driver=w.driver()}function U(X){return w._extend(X),L(),w._ready=w._initStorage(w._config),w._ready}function D(X){return function(){var ue=0;function pe(){for(;ue<X.length;){var me=X[ue];return ue++,w._dbInfo=null,w._ready=null,w.getDriver(me).then(U).catch(pe)}L();var Oe=new Error("No available storage method found.");return w._driverSet=_.reject(Oe),w._driverSet}return pe()}}var k=this._driverSet!==null?this._driverSet.catch(function(){return _.resolve()}):_.resolve();return this._driverSet=k.then(function(){var X=I[0];return w._dbInfo=null,w._ready=null,w.getDriver(X).then(function(ue){w._driver=ue._driver,L(),w._wrapLibraryMethodsWithReady(),w._initDriver=D(I)})}).catch(function(){L();var X=new Error("No available storage method found.");return w._driverSet=_.reject(X),w._driverSet}),y(this._driverSet,x,S),this._driverSet},f.prototype.supports=function(c){return!!Ns[c]},f.prototype._extend=function(c){Hi(this,c)},f.prototype._getSupportedDrivers=function(c){for(var x=[],S=0,w=c.length;S<w;S++){var I=c[S];this.supports(I)&&x.push(I)}return x},f.prototype._wrapLibraryMethodsWithReady=function(){for(var c=0,x=Wi.length;c<x;c++)Vd(this,Wi[c])},f.prototype.createInstance=function(c){return new f(c)},f}(),Xd=new Yd;n.exports=Xd},{3:3}]},{},[4])(4)})});var Cs=g((qs,hd)=>{"use strict";(function(r,e,t){let i;(i=t.define)&&i.amd?i([],function(){return e}):(i=t.modules)?i[r.toLowerCase()]=e:typeof qs=="object"?hd.exports=e:t[r]=e})("FlexSearch",function r(e){function t(h,d){let m=d?d.id:h&&h.id;this.id=m||m===0?m:Ke++,this.init(h,d),u(this,"index",function(){return this.a?Object.keys(this.a.index[this.a.keys[0]].c):Object.keys(this.c)}),u(this,"length",function(){return this.index.length})}function i(h,d,m,A){return this.u!==this.g&&(this.o=this.o.concat(m),this.u++,A&&this.o.length>=A&&(this.u=this.g),this.u===this.g&&(this.cache&&this.j.set(d,this.o),this.F&&this.F(this.o))),this}function n(h){let d=G();for(let m in h)if(h.hasOwnProperty(m)){let A=h[m];F(A)?d[m]=A.slice(0):te(A)?d[m]=n(A):d[m]=A}return d}function s(h,d){let m=h.length,A=Z(d),C=[];for(let T=0,M=0;T<m;T++){let P=h[T];(A&&d(P)||!A&&!d[P])&&(C[M++]=P)}return C}function a(h,d,m,A,C,T,M,P,N,B){m=K(m,M?0:C,P,T,d,N,B);let Y;if(P&&(P=m.page,Y=m.next,m=m.result),M)d=this.where(M,null,C,m);else{for(d=m,m=this.l,C=d.length,T=Array(C),M=0;M<C;M++)T[M]=m[d[M]];d=T}return m=d,A&&(Z(A)||(ze=A.split(":"),1<ze.length?A=E:(ze=ze[0],A=y)),m.sort(A)),m=H(P,Y,m),this.cache&&this.j.set(h,m),m}function u(h,d,m){Object.defineProperty(h,d,{get:m})}function o(h){return new RegExp(h,"g")}function l(h,d){for(let m=0;m<d.length;m+=2)h=h.replace(d[m],d[m+1]);return h}function p(h,d,m,A,C,T,M,P){return d[m]?d[m]:(C=C?(P-(M||P/1.5))*T+(M||P/1.5)*C:T,d[m]=C,C>=M&&(h=h[P-(C+.5>>0)],h=h[m]||(h[m]=[]),h[h.length]=A),C)}function b(h,d){if(h){let m=Object.keys(h);for(let A=0,C=m.length;A<C;A++){let T=m[A],M=h[T];if(M)for(let P=0,N=M.length;P<N;P++)if(M[P]===d){N===1?delete h[T]:M.splice(P,1);break}else te(M[P])&&b(M[P],d)}}}function _(h){let d="",m="";var A="";for(let C=0;C<h.length;C++){let T=h[C];T!==m&&(C&&T==="h"?(A=A==="a"||A==="e"||A==="i"||A==="o"||A==="u"||A==="y",((m==="a"||m==="e"||m==="i"||m==="o"||m==="u"||m==="y")&&A||m===" ")&&(d+=T)):d+=T),A=C===h.length-1?"":h[C+1],m=T}return d}function q(h,d){return h=h.length-d.length,0>h?1:h?-1:0}function y(h,d){return h=h[ze],d=d[ze],h<d?-1:h>d?1:0}function E(h,d){let m=ze.length;for(let A=0;A<m;A++)h=h[ze[A]],d=d[ze[A]];return h<d?-1:h>d?1:0}function H(h,d,m){return h?{page:h,next:d?""+d:null,result:m}:m}function K(h,d,m,A,C,T,M){let P,N=[];if(m===!0){m="0";var B=""}else B=m&&m.split(":");let Y=h.length;if(1<Y){let ge=G(),ne=[],oe,he;var V=0,z;let Ue;var ae=!0;let Ce,Pe=0,Je,$r,Ir,zr;if(B&&(B.length===2?(Ir=B,B=!1):B=zr=parseInt(B[0],10)),M){for(oe=G();V<Y;V++)if(C[V]==="not")for(he=h[V],Ue=he.length,z=0;z<Ue;z++)oe["@"+he[z]]=1;else $r=V+1;if(O($r))return H(m,P,N);V=0}else Je=Q(C)&&C;let Tr;for(;V<Y;V++){let Gt=V===($r||Y)-1;if(!Je||!V)if((z=Je||C&&C[V])&&z!=="and")if(z==="or")Tr=!1;else continue;else Tr=T=!0;if(he=h[V],Ue=he.length){if(ae)if(Ce){var se=Ce.length;for(z=0;z<se;z++){ae=Ce[z];var ce="@"+ae;M&&oe[ce]||(ge[ce]=1,T||(N[Pe++]=ae))}Ce=null,ae=!1}else{Ce=he;continue}for(ce=!1,z=0;z<Ue;z++){se=he[z];var ye="@"+se;let Pr=T?ge[ye]||0:V;if(!(!Pr&&!A||M&&oe[ye]||!T&&ge[ye]))if(Pr===V){if(Gt){if((!zr||--zr<Pe)&&(N[Pe++]=se,d&&Pe===d))return H(m,Pe+(B||0),N)}else ge[ye]=V+1;ce=!0}else A&&(ye=ne[Pr]||(ne[Pr]=[]),ye[ye.length]=se)}if(Tr&&!ce&&!A)break}else if(Tr&&!A)return H(m,P,he)}if(Ce)if(V=Ce.length,M)for(z=B?parseInt(B,10):0;z<V;z++)h=Ce[z],oe["@"+h]||(N[Pe++]=h);else N=Ce;if(A){for(Pe=N.length,Ir?(V=parseInt(Ir[0],10)+1,z=parseInt(Ir[1],10)+1):(V=ne.length,z=0);V--;)if(se=ne[V]){for(Ue=se.length;z<Ue;z++)if(A=se[z],(!M||!oe["@"+A])&&(N[Pe++]=A,d&&Pe===d))return H(m,V+":"+z,N);z=0}}}else!Y||C&&C[0]==="not"||(N=h[0],B&&(B=parseInt(B[0],10)));return d&&(M=N.length,B&&B>M&&(B=0),B=B||0,P=B+d,P<M?N=N.slice(B,P):(P=0,B&&(N=N.slice(B)))),H(m,P,N)}function Q(h){return typeof h=="string"}function F(h){return h.constructor===Array}function Z(h){return typeof h=="function"}function te(h){return typeof h=="object"}function O(h){return typeof h=="undefined"}function ee(h){let d=Array(h);for(let m=0;m<h;m++)d[m]=G();return d}function G(){return Object.create(null)}function de(){let h,d;self.onmessage=function(m){if(m=m.data)if(m.search){let A=d.search(m.content,m.threshold?{limit:m.limit,threshold:m.threshold,where:m.where}:m.limit);self.postMessage({id:h,content:m.content,limit:m.limit,result:A})}else m.add?d.add(m.id,m.content):m.update?d.update(m.id,m.content):m.remove?d.remove(m.id):m.clear?d.clear():m.info?(m=d.info(),m.worker=h,console.log(m)):m.register&&(h=m.id,m.options.cache=!1,m.options.async=!1,m.options.worker=!1,d=new Function(m.register.substring(m.register.indexOf("{")+1,m.register.lastIndexOf("}")))(),d=new d(m.options))}}function qe(h,d,m,A){h=e("flexsearch","id"+h,de,function(T){(T=T.data)&&T.result&&A(T.id,T.content,T.result,T.limit,T.where,T.cursor,T.suggest)},d);let C=r.toString();return m.id=d,h.postMessage({register:C,options:m,id:d}),h}let ve={encode:"icase",f:"forward",split:/\W+/,cache:!1,async:!1,g:!1,D:!1,a:!1,b:9,threshold:0,depth:0},Ne={memory:{encode:"extra",f:"strict",threshold:0,b:1},speed:{encode:"icase",f:"strict",threshold:1,b:3,depth:2},match:{encode:"extra",f:"full",threshold:1,b:3},score:{encode:"extra",f:"strict",threshold:1,b:9,depth:4},balance:{encode:"balance",f:"strict",threshold:0,b:3,depth:3},fast:{encode:"icase",f:"strict",threshold:8,b:9,depth:1}},Te=[],Ke=0,cr={},Er={};t.create=function(h,d){return new t(h,d)},t.registerMatcher=function(h){for(let d in h)h.hasOwnProperty(d)&&Te.push(o(d),h[d]);return this},t.registerEncoder=function(h,d){return sr[h]=d.bind(sr),this},t.registerLanguage=function(h,d){return cr[h]=d.filter,Er[h]=d.stemmer,this},t.encode=function(h,d){return sr[h](d)},t.prototype.init=function(h,d){if(this.v=[],d){var m=d.preset;h=d}else h||(h=ve),m=h.preset;if(d={},Q(h)?(d=Ne[h],h={}):m&&(d=Ne[m]),m=h.worker)if(typeof Worker=="undefined")h.worker=!1,this.m=null;else{var A=parseInt(m,10)||4;this.C=-1,this.u=0,this.o=[],this.F=null,this.m=Array(A);for(var C=0;C<A;C++)this.m[C]=qe(this.id,C,h,i.bind(this))}if(this.f=h.tokenize||d.f||this.f||ve.f,this.split=O(m=h.split)?this.split||ve.split:Q(m)?o(m):m,this.D=h.rtl||this.D||ve.D,this.async=typeof Promise=="undefined"||O(m=h.async)?this.async||ve.async:m,this.g=O(m=h.worker)?this.g||ve.g:m,this.threshold=O(m=h.threshold)?d.threshold||this.threshold||ve.threshold:m,this.b=O(m=h.resolution)?m=d.b||this.b||ve.b:m,m<=this.threshold&&(this.b=this.threshold+1),this.depth=this.f!=="strict"||O(m=h.depth)?d.depth||this.depth||ve.depth:m,this.w=(m=O(m=h.encode)?d.encode||ve.encode:m)&&sr[m]&&sr[m].bind(sr)||(Z(m)?m:this.w||!1),(m=h.matcher)&&this.addMatcher(m),m=(d=h.lang)||h.filter){if(Q(m)&&(m=cr[m]),F(m)){A=this.w,C=G();for(var T=0;T<m.length;T++){var M=A?A(m[T]):m[T];C[M]=1}m=C}this.filter=m}if(m=d||h.stemmer){var P;d=Q(m)?Er[m]:m,A=this.w,C=[];for(P in d)d.hasOwnProperty(P)&&(T=A?A(P):P,C.push(o(T+"($|\\W)"),A?A(d[P]):d[P]));this.stemmer=P=C}if(this.a=C=(m=h.doc)?n(m):this.a||ve.a,this.i=ee(this.b-(this.threshold||0)),this.h=G(),this.c=G(),C){if(this.l=G(),h.doc=null,P=C.index={},d=C.keys=[],A=C.field,T=C.tag,M=C.store,F(C.id)||(C.id=C.id.split(":")),M){var N=G();if(Q(M))N[M]=1;else if(F(M))for(let B=0;B<M.length;B++)N[M[B]]=1;else te(M)&&(N=M);C.store=N}if(T){if(this.G=G(),M=G(),A)if(Q(A))M[A]=h;else if(F(A))for(N=0;N<A.length;N++)M[A[N]]=h;else te(A)&&(M=A);for(F(T)||(C.tag=T=[T]),A=0;A<T.length;A++)this.G[T[A]]=G();this.I=T,A=M}if(A){let B;for(F(A)||(te(A)?(B=A,C.field=A=Object.keys(A)):C.field=A=[A]),C=0;C<A.length;C++)T=A[C],F(T)||(B&&(h=B[T]),d[C]=T,A[C]=T.split(":")),P[T]=new t(h)}h.doc=m}return this.B=!0,this.j=(this.cache=m=O(m=h.cache)?this.cache||ve.cache:m)?new ki(m):!1,this},t.prototype.encode=function(h){return h&&(Te.length&&(h=l(h,Te)),this.v.length&&(h=l(h,this.v)),this.w&&(h=this.w(h)),this.stemmer&&(h=l(h,this.stemmer))),h},t.prototype.addMatcher=function(h){let d=this.v;for(let m in h)h.hasOwnProperty(m)&&d.push(o(m),h[m]);return this},t.prototype.add=function(h,d,m,A,C){if(this.a&&te(h))return this.A("add",h,d);if(d&&Q(d)&&(h||h===0)){var T="@"+h;if(this.c[T]&&!A)return this.update(h,d);if(this.g)return++this.C>=this.m.length&&(this.C=0),this.m[this.C].postMessage({add:!0,id:h,content:d}),this.c[T]=""+this.C,m&&m(),this;if(!C){if(this.async&&typeof importScripts!="function"){let ne=this;if(T=new Promise(function(oe){setTimeout(function(){ne.add(h,d,null,A,!0),ne=null,oe()})}),m)T.then(m);else return T;return this}if(m)return this.add(h,d,null,A,!0),m(),this}if(d=this.encode(d),!d.length)return this;m=this.f,C=Z(m)?m(d):d.split(this.split),this.filter&&(C=s(C,this.filter));let V=G();V._ctx=G();let z=C.length,ae=this.threshold,se=this.depth,ce=this.b,ye=this.i,ge=this.D;for(let ne=0;ne<z;ne++){var M=C[ne];if(M){var P=M.length,N=(ge?ne+1:z-ne)/z,B="";switch(m){case"reverse":case"both":for(var Y=P;--Y;)B=M[Y]+B,p(ye,V,B,h,ge?1:(P-Y)/P,N,ae,ce-1);B="";case"forward":for(Y=0;Y<P;Y++)B+=M[Y],p(ye,V,B,h,ge?(Y+1)/P:1,N,ae,ce-1);break;case"full":for(Y=0;Y<P;Y++){let oe=(ge?Y+1:P-Y)/P;for(let he=P;he>Y;he--)B=M.substring(Y,he),p(ye,V,B,h,oe,N,ae,ce-1)}break;default:if(P=p(ye,V,M,h,1,N,ae,ce-1),se&&1<z&&P>=ae)for(P=V._ctx[M]||(V._ctx[M]=G()),M=this.h[M]||(this.h[M]=ee(ce-(ae||0))),N=ne-se,B=ne+se+1,0>N&&(N=0),B>z&&(B=z);N<B;N++)N!==ne&&p(M,P,C[N],h,0,ce-(N<ne?ne-N:N-ne),ae,ce-1)}}}this.c[T]=1,this.B=!1}return this},t.prototype.A=function(h,d,m){if(F(d)){var A=d.length;if(A--){for(var C=0;C<A;C++)this.A(h,d[C]);return this.A(h,d[A],m)}}else{var T=this.a.index,M=this.a.keys,P=this.a.tag;C=this.a.store;var N,B=this.a.id;A=d;for(var Y=0;Y<B.length;Y++)A=A[B[Y]];if(h==="remove"&&(delete this.l[A],B=M.length,B--)){for(d=0;d<B;d++)T[M[d]].remove(A);return T[M[B]].remove(A,m)}if(P){for(N=0;N<P.length;N++){var V=P[N],z=d;for(B=V.split(":"),Y=0;Y<B.length;Y++)z=z[B[Y]];z="@"+z}N=this.G[V],N=N[z]||(N[z]=[])}B=this.a.field;for(let ae=0,se=B.length;ae<se;ae++){for(V=B[ae],P=d,z=0;z<V.length;z++)P=P[V[z]];V=T[M[ae]],z=h==="add"?V.add:V.update,ae===se-1?z.call(V,A,P,m):z.call(V,A,P)}if(C){for(m=Object.keys(C),h=G(),T=0;T<m.length;T++)if(M=m[T],C[M]){M=M.split(":");let ae,se;for(B=0;B<M.length;B++)P=M[B],ae=(ae||d)[P],se=(se||h)[P]=ae}d=h}N&&(N[N.length]=d),this.l[A]=d}return this},t.prototype.update=function(h,d,m){return this.a&&te(h)?this.A("update",h,d):(this.c["@"+h]&&Q(d)&&(this.remove(h),this.add(h,d,m,!0)),this)},t.prototype.remove=function(h,d,m){if(this.a&&te(h))return this.A("remove",h,d);var A="@"+h;if(this.c[A]){if(this.g)return this.m[this.c[A]].postMessage({remove:!0,id:h}),delete this.c[A],d&&d(),this;if(!m){if(this.async&&typeof importScripts!="function"){let C=this;if(A=new Promise(function(T){setTimeout(function(){C.remove(h,null,!0),C=null,T()})}),d)A.then(d);else return A;return this}if(d)return this.remove(h,null,!0),d(),this}for(d=0;d<this.b-(this.threshold||0);d++)b(this.i[d],h);this.depth&&b(this.h,h),delete this.c[A],this.B=!1}return this};let ze;t.prototype.search=function(h,d,m,A){if(te(d)){if(F(d))for(var C=0;C<d.length;C++)d[C].query=h;else d.query=h;h=d,d=1e3}else d&&Z(d)?(m=d,d=1e3):d||d===0||(d=1e3);if(this.g){this.F=m,this.u=0,this.o=[];for(var T=0;T<this.g;T++)this.m[T].postMessage({search:!0,limit:d,content:h})}else{var M=[],P=h;if(te(h)&&!F(h)){m||(m=h.callback)&&(P.callback=null);var N=h.sort,B=h.page;d=h.limit,T=h.threshold;var Y=h.suggest;h=h.query}if(this.a){T=this.a.index;let ge=P.where;var V=P.bool||"or",z=P.field;let ne=V,oe,he;if(z)F(z)||(z=[z]);else if(F(P)){var ae=P;z=[],ne=[];for(var se=0;se<P.length;se++)A=P[se],C=A.bool||V,z[se]=A.field,ne[se]=C,C==="not"?oe=!0:C==="and"&&(he=!0)}else z=this.a.keys;for(V=z.length,se=0;se<V;se++)ae&&(P=ae[se]),B&&!Q(P)&&(P.page=null,P.limit=0),M[se]=T[z[se]].search(P,0);if(m)return m(a.call(this,h,ne,M,N,d,Y,ge,B,he,oe));if(this.async){let Ue=this;return new Promise(function(Ce){Promise.all(M).then(function(Pe){Ce(a.call(Ue,h,ne,Pe,N,d,Y,ge,B,he,oe))})})}return a.call(this,h,ne,M,N,d,Y,ge,B,he,oe)}if(T||(T=this.threshold||0),!A){if(this.async&&typeof importScripts!="function"){let ge=this;if(T=new Promise(function(ne){setTimeout(function(){ne(ge.search(P,d,null,!0)),ge=null})}),m)T.then(m);else return T;return this}if(m)return m(this.search(P,d,null,!0)),this}if(!h||!Q(h))return M;if(P=h,this.cache)if(this.B){if(m=this.j.get(h))return m}else this.j.clear(),this.B=!0;if(P=this.encode(P),!P.length)return M;m=this.f,m=Z(m)?m(P):P.split(this.split),this.filter&&(m=s(m,this.filter)),ae=m.length,A=!0,C=[];var ce=G(),ye=0;if(1<ae&&(this.depth&&this.f==="strict"?V=!0:m.sort(q)),!V||(se=this.h)){let ge=this.b;for(;ye<ae;ye++){let ne=m[ye];if(ne){if(V){if(!z){if(se[ne])z=ne,ce[ne]=1;else if(!Y)return M}if(Y&&ye===ae-1&&!C.length)V=!1,ne=z||ne,ce[ne]=0;else if(!z)continue}if(!ce[ne]){let oe=[],he=!1,Ue=0,Ce=V?se[z]:this.i;if(Ce){let Pe;for(let Je=0;Je<ge-T;Je++)(Pe=Ce[Je]&&Ce[Je][ne])&&(oe[Ue++]=Pe,he=!0)}if(he)z=ne,C[C.length]=1<Ue?oe.concat.apply([],oe):oe[0];else if(!Y){A=!1;break}ce[ne]=1}}}}else A=!1;return A&&(M=K(C,d,B,Y)),this.cache&&this.j.set(h,M),M}},t.prototype.find=function(h,d){return this.where(h,d,1)[0]||null},t.prototype.where=function(h,d,m,A){let C=this.l,T=[],M=0,P;var N;let B;if(te(h)){m||(m=d);var Y=Object.keys(h),V=Y.length;if(P=!1,V===1&&Y[0]==="id")return[C[h.id]];if((N=this.I)&&!A)for(var z=0;z<N.length;z++){var ae=N[z],se=h[ae];if(!O(se)){if(B=this.G[ae]["@"+se],--V===0)return B;Y.splice(Y.indexOf(ae),1),delete h[ae];break}}for(N=Array(V),z=0;z<V;z++)N[z]=Y[z].split(":")}else{if(Z(h)){for(d=A||Object.keys(C),m=d.length,Y=0;Y<m;Y++)V=C[d[Y]],h(V)&&(T[M++]=V);return T}if(O(d))return[C[h]];if(h==="id")return[C[d]];Y=[h],V=1,N=[h.split(":")],P=!0}for(A=B||A||Object.keys(C),z=A.length,ae=0;ae<z;ae++){se=B?A[ae]:C[A[ae]];let ce=!0;for(let ye=0;ye<V;ye++){P||(d=h[Y[ye]]);let ge=N[ye],ne=ge.length,oe=se;if(1<ne)for(let he=0;he<ne;he++)oe=oe[ge[he]];else oe=oe[ge[0]];if(oe!==d){ce=!1;break}}if(ce&&(T[M++]=se,m&&M===m))break}return T},t.prototype.info=function(){if(this.g)for(let h=0;h<this.g;h++)this.m[h].postMessage({info:!0,id:this.id});else return{id:this.id,items:this.length,cache:this.cache&&this.cache.s?this.cache.s.length:!1,matcher:Te.length+(this.v?this.v.length:0),worker:this.g,threshold:this.threshold,depth:this.depth,resolution:this.b,contextual:this.depth&&this.f==="strict"}},t.prototype.clear=function(){return this.destroy().init()},t.prototype.destroy=function(){if(this.cache&&(this.j.clear(),this.j=null),this.i=this.h=this.c=null,this.a){let h=this.a.keys;for(let d=0;d<h.length;d++)this.a.index[h[d]].destroy();this.a=this.l=null}return this},t.prototype.export=function(h){let d=!h||O(h.serialize)||h.serialize;if(this.a){let A=!h||O(h.doc)||h.doc;var m=!h||O(h.index)||h.index;h=[];let C=0;if(m)for(m=this.a.keys;C<m.length;C++){let T=this.a.index[m[C]];h[C]=[T.i,T.h,Object.keys(T.c)]}A&&(h[C]=this.l)}else h=[this.i,this.h,Object.keys(this.c)];return d&&(h=JSON.stringify(h)),h},t.prototype.import=function(h,d){(!d||O(d.serialize)||d.serialize)&&(h=JSON.parse(h));let m=G();if(this.a){var A=!d||O(d.doc)||d.doc,C=0;if(!d||O(d.index)||d.index){d=this.a.keys;let M=d.length;for(var T=h[0][2];C<T.length;C++)m[T[C]]=1;for(C=0;C<M;C++){T=this.a.index[d[C]];let P=h[C];P&&(T.i=P[0],T.h=P[1],T.c=m)}}A&&(this.l=te(A)?A:h[C])}else{for(A=h[2],C=0;C<A.length;C++)m[A[C]]=1;this.i=h[0],this.h=h[1],this.c=m}};let lr=function(){let h=o("\\s+"),d=o("[^a-z0-9 ]"),m=[o("[-/]")," ",d,"",h," "];return function(A){return _(l(A.toLowerCase(),m))}}(),sr={icase:function(h){return h.toLowerCase()},simple:function(){let h=o("\\s+"),d=o("[^a-z0-9 ]"),m=o("[-/]"),A=o("[\xE0\xE1\xE2\xE3\xE4\xE5]"),C=o("[\xE8\xE9\xEA\xEB]"),T=o("[\xEC\xED\xEE\xEF]"),M=o("[\xF2\xF3\xF4\xF5\xF6\u0151]"),P=o("[\xF9\xFA\xFB\xFC\u0171]"),N=o("[\xFD\u0177\xFF]"),B=o("\xF1"),Y=o("[\xE7c]"),V=o("\xDF"),z=o(" & "),ae=[A,"a",C,"e",T,"i",M,"o",P,"u",N,"y",B,"n",Y,"k",V,"s",z," and ",m," ",d,"",h," "];return function(se){return se=l(se.toLowerCase(),ae),se===" "?"":se}}(),advanced:function(){let h=o("ae"),d=o("ai"),m=o("ay"),A=o("ey"),C=o("oe"),T=o("ue"),M=o("ie"),P=o("sz"),N=o("zs"),B=o("ck"),Y=o("cc"),V=o("sh"),z=o("th"),ae=o("dt"),se=o("ph"),ce=o("pf"),ye=o("ou"),ge=o("uo"),ne=[h,"a",d,"ei",m,"ei",A,"ei",C,"o",T,"u",M,"i",P,"s",N,"s",V,"s",B,"k",Y,"k",z,"t",ae,"t",se,"f",ce,"f",ye,"o",ge,"u"];return function(oe,he){return oe&&(oe=this.simple(oe),2<oe.length&&(oe=l(oe,ne)),he||1<oe.length&&(oe=_(oe)),oe)}}(),extra:function(){let h=o("p"),d=o("z"),m=o("[cgq]"),A=o("n"),C=o("d"),T=o("[vw]"),M=o("[aeiouy]"),P=[h,"b",d,"s",m,"k",A,"m",C,"t",T,"f",M,""];return function(N){if(!N)return N;if(N=this.advanced(N,!0),1<N.length){N=N.split(" ");for(let B=0;B<N.length;B++){let Y=N[B];1<Y.length&&(N[B]=Y[0]+l(Y.substring(1),P))}N=N.join(" "),N=_(N)}return N}}(),balance:lr},ki=function(){function h(d){this.clear(),this.H=d!==!0&&d}return h.prototype.clear=function(){this.cache=G(),this.count=G(),this.index=G(),this.s=[]},h.prototype.set=function(d,m){if(this.H&&O(this.cache[d])){let A=this.s.length;if(A===this.H){A--;let C=this.s[A];delete this.cache[C],delete this.count[C],delete this.index[C]}this.index[d]=A,this.s[A]=d,this.count[d]=-1,this.cache[d]=m,this.get(d)}else this.cache[d]=m},h.prototype.get=function(d){let m=this.cache[d];if(this.H&&m){var A=++this.count[d];let T=this.index,M=T[d];if(0<M){let P=this.s;for(var C=M;this.count[P[--M]]<=A&&M!==-1;);if(M++,M!==C){for(A=C;A>M;A--)C=P[A-1],P[A]=C,T[C]=A;P[M]=d,T[d]=M}}}return m},h}();return t}(function(){let r={},e=typeof Blob!="undefined"&&typeof URL!="undefined"&&URL.createObjectURL;return function(t,i,n,s,a){return n=e?URL.createObjectURL(new Blob(["("+n.toString()+")()"],{type:"text/javascript"})):t+".min.js",t+="-"+i,r[t]||(r[t]=[]),r[t][a]=new Worker(n),r[t][a].onmessage=s,r[t][a]}}()),qs)});var xE={};Vt(xE,{BaseProvider:()=>le,CocodaSDK:()=>Cr,ConceptApiProvider:()=>ir,LabelSearchSuggestionProvider:()=>br,LocApiProvider:()=>Sr,LocalMappingsProvider:()=>yr,MappingsApiProvider:()=>tr,MyCoReProvider:()=>Or,OccurrencesApiProvider:()=>_r,ReconciliationApiProvider:()=>wr,SkohubProvider:()=>Ar,SkosmosApiProvider:()=>xr,addAllProviders:()=>bE,cdk:()=>gd,errors:()=>Fe,utils:()=>Ur});var Fe={};Vt(Fe,{BackendError:()=>yt,BackendUnavailableError:()=>_t,CDKError:()=>Ee,InvalidOrMissingParameterError:()=>W,InvalidProviderError:()=>Hr,InvalidRequestError:()=>Qe,MethodNotImplementedError:()=>vt,MissingApiUrlError:()=>De,NetworkError:()=>wt});var Ee=class extends Error{constructor({message:e="",relatedError:t=null,code:i=null}={}){!e&&t&&t.message&&(e=t.message),super(e),this.name=this.constructor.name,this.relatedError=t,this.code=i}},vt=class extends Ee{constructor(n){var s=n,{method:e,message:t=""}=s,i=J(s,["method","message"]);i.message=`Method not implemented: ${e} (${t})`,super(i)}},W=class extends Ee{constructor(n){var s=n,{parameter:e,message:t=""}=s,i=J(s,["parameter","message"]);i.message=`Invalid or missing parameter: ${e} (${t})`,super(i)}},Qe=class extends Ee{},yt=class extends Ee{},_t=class extends Ee{},wt=class extends Ee{},De=class extends Ee{},Hr=class extends Ee{};var md=fe(ni(),1);var re=fe(Lu(),1),xe=fe(Wu(),1),gr=fe(gf(),1),Bt=fe(kf(),1),ts=fe(rc(),1),is=fe(Tc(),1),Ie=fe(ke(),1),kt=fe(Xe(),1),be=fe(Mc(),1),ns=fe(Kc(),1),rr=fe(Fl(),1),OC=fe(Oh(),1),ss=fe(Qn(),1),ar=fe(Ep(),1),as=fe(Tp(),1);var qr=fe(He(),1);var Ht={};Vt(Ht,{BaseProvider:()=>le,ConceptApiProvider:()=>ir,LabelSearchSuggestionProvider:()=>br,LocApiProvider:()=>Sr,LocalMappingsProvider:()=>yr,MappingsApiProvider:()=>tr,MyCoReProvider:()=>Or,OccurrencesApiProvider:()=>_r,ReconciliationApiProvider:()=>wr,SkohubProvider:()=>Ar,SkosmosApiProvider:()=>xr});var ct=fe(He(),1);var Ri=fe(ni(),1);var Ur={};Vt(Ur,{concatUrl:()=>or,listOfCapabilities:()=>Ae,requestMethods:()=>_s,withCustomProps:()=>Nr});var _s=[{method:"getRegistries",fallback:[],type:"Registries"},{method:"getSchemes",fallback:[],type:"Schemes"},{method:"vocSearch",fallback:[],type:"Schemes"},{method:"getTypes",fallback:[],type:"Types"},{method:"suggest",fallback:["",[],[],[]]},{method:"vocSuggest",fallback:["",[],[],[]]},{method:"getConcordances",fallback:[],type:"Concordances"},{method:"getOccurrences",fallback:[],type:"Occurrences"},{method:"getTop",fallback:[],type:"Concepts"},{method:"getConcepts",fallback:[],type:"Concepts"},{method:"getNarrower",fallback:[],type:"Concepts"},{method:"getAncestors",fallback:[],type:"Concepts"},{method:"search",fallback:[],type:"Concepts"},{method:"getMapping",fallback:null,type:"Mapping"},{method:"getMappings",fallback:[],type:"Mappings"},{method:"postMapping",fallback:null,type:"Mapping"},{method:"postMappings",fallback:[],type:"Mapping"},{method:"putMapping",fallback:null,type:"Mapping"},{method:"patchMapping",fallback:null,type:"Mapping"},{method:"deleteMapping",fallback:!1},{method:"deleteMappings",fallback:[]},{method:"getAnnotations",fallback:[],type:"Annotations"},{method:"postAnnotation",fallback:null,type:"Annotation"},{method:"putAnnotation",fallback:null,type:"Annotation"},{method:"patchAnnotation",fallback:null,type:"Annotation"},{method:"deleteAnnotation",fallback:!1}];function or(...r){let[e,...t]=r;for(let i of t)e.endsWith("/")||(e+="/"),i.startsWith("/")&&(i=i.slice(1)),e+=i;return e}function Nr(r,e){return r._totalCount=e._totalCount,r._url=e._url,r}var Ae=["schemes","top","data","concepts","narrower","ancestors","types","suggest","search","auth","mappings","concordances","annotations","occurrences"];var le=class{constructor(e={}){this._jskos=e,this.axios=Ri.default.create({timeout:2e4}),this._path=typeof window!="undefined"&&window.location.pathname,this.has={},this._defaultLanguages="en,de,fr,es,nl,it,fi,pl,ru,cs,jp".split(","),this.languages=[],this._auth={key:null,bearerToken:null},this._repeating=[],this._api={status:e.status,schemes:Array.isArray(e.schemes)?void 0:e.schemes,top:e.top,data:e.data,concepts:e.concepts,narrower:e.narrower,ancestors:e.ancestors,types:e.types,suggest:e.suggest,search:e.search,"voc-suggest":e["voc-suggest"],"voc-search":e["voc-search"],mappings:e.mappings,concordances:e.concordances,annotations:e.annotations,occurrences:e.occurrences,reconcile:e.reconcile,api:e.api},this._config={},this.setRetryConfig(),this.axios.interceptors.request.use(i=>{if(!i._skipAdditionalParameters){let n=gr.default([].concat(re.default(i,"params.language","").split(","),this.languages,this._defaultLanguages).filter(s=>s!="")).join(",");xe.default(i,"params.language",n),this.has.auth&&this._auth.bearerToken&&!re.default(i,"headers.Authorization")&&xe.default(i,"headers.Authorization",`Bearer ${this._auth.bearerToken}`)}if(i.url.startsWith("http:")&&typeof window!="undefined"&&window.location.protocol=="https:")throw new Ri.default.Cancel("Can't call http API from https.");return i}),this.axios.interceptors.response.use(({data:i,headers:n={},config:s={}})=>{i=ct.default.normalize(i);let a=s.url;if(a.endsWith("?")||(a+="?"),is.default(s.params||{},(u,o)=>{a+=`${o}=${encodeURIComponent(u)}&`}),Ie.default(i)||kt.default(i)){let u=parseInt(n["x-total-count"]);isNaN(u)||(i._totalCount=u),i._url=a}return i},i=>{let n=re.default(i,"config._retryCount",0),s=re.default(i,"config.method"),a=re.default(i,"response.status");return this._retryConfig.methods.includes(s)&&this._retryConfig.statusCodes.includes(a)&&n<this._retryConfig.count?(i.config._retryCount=n+1,i.config.data&&(i.config.data=JSON.parse(i.config.data)),new Promise((u,o)=>{setTimeout(()=>{this.axios(i.config).then(u).catch(o)},(()=>{let l=this._retryConfig.delay;return typeof l=="function"?l(n):l})())})):Promise.reject(i)});let t=[];for(let{method:i,type:n}of _s){let s=this[i]&&this[i].bind(this);if(!s){this[i]=()=>{throw new vt({method:i})};continue}this[i]=(a={})=>{if(a._raw)return delete a._raw,s(a);let u=t.find(b=>b.method==i&&rr.default(b.options,a));if(u)return u.promise;let o;a.cancelToken||(o=this.getCancelTokenSource(),a.cancelToken=o.token);let l=this.init().then(()=>s(a)).then(b=>(Ie.default(b)&&b._totalCount===void 0?b._totalCount=b.length:kt.default(b)&&b._totalCount===void 0&&(b._totalCount=1),b&&n&&this[`adjust${n}`]&&(b=this[`adjust${n}`](b)),b)).catch(b=>{throw b instanceof Ee?b:b.response?b.response.status.toString().startsWith(4)?new Qe({relatedError:b,code:b.response.status}):new yt({relatedError:b,code:b.response.status}):b.request?typeof navigator!="undefined"&&(navigator.connection||navigator.mozConnection||navigator.webkitConnection)?new _t({relatedError:b}):new wt({relatedError:b}):new Ee({relatedError:b})});o&&(l.cancel=(...b)=>o.cancel(...b));let p={method:i,options:ar.default(a,["cancelToken"]),promise:l};return t.push(p),l.catch(()=>{}).then(()=>t.splice(t.indexOf(p),1)),l}}}get uri(){return this._jskos.uri}get notation(){return this._jskos.notation}get prefLabel(){return this._jskos.prefLabel}get definition(){return this._jskos.definition}get schemes(){return this._jskos.schemes}get excludedSchemes(){return this._jskos.excludedSchemes}get stored(){return this._jskos.stored!==void 0?this._jskos.stored:this.constructor.stored}init(){return j(this,null,function*(){return this._init?this._init:(this._init=(()=>j(this,null,function*(){this._prepare();let e;if(be.default(this._api.status))try{e=yield this.axios({method:"get",url:this._api.status})}catch(t){re.default(t,"response.status")===404&&(this._api.status=null)}else e=this._api.status;if(kt.default(e)&&!ns.default(e)){this._config=e.config||{};for(let t of Object.keys(this._api))this._api[t]===void 0&&(this._api[t]=e[t]||null)}this._setup()}))(),this._init)})}_prepare(){}_setup(){}getCancelTokenSource(){return Ri.default.CancelToken.source()}setAuth({key:e=this._auth.key,bearerToken:t=this._auth.bearerToken}){this._auth.key=e,this._auth.bearerToken=t}setRetryConfig(e={}){this._retryConfig=Object.assign({methods:["get","head","options"],statusCodes:[401,403],count:3,delay:t=>300*t},e)}isAuthorizedFor({type:e,action:t,user:i,crossUser:n}){if(t=="read"&&this.has[e]===!0)return!0;if(!this.has[e])return!1;let s=re.default(this._config,`${e}.${t}`);if(!s)return!!this.has[e][t];if(s.auth&&(!i||!this._auth.key)||s.auth&&this._auth.key!=re.default(this._config,"auth.key"))return!1;let a=[i.uri].concat(Object.values(i.identities||{}).map(u=>u.uri)).filter(u=>u!=null);if(s.auth&&s.identities&&Bt.default(a,s.identities).length==0)return!1;if(s.auth&&s.identityProviders){let u=Object.keys(i&&i.identities||{});if(Bt.default(u,s.identityProviders).length==0)return!1}return n?s.crossUser===!0||Bt.default(s.crossUser||[],a).length>0:!!this.has[e][t]}supportsScheme(e){if(!e)return!1;let t=Ie.default(this.schemes)?this.schemes:null;return t==null&&!ct.default.isContainedIn(e,this.excludedSchemes||[])?!0:ct.default.isContainedIn(e,t)}adjustConcept(e){if(!e||e.__SAVED__)return e;e._getNarrower=t=>this.getNarrower($(R({},t),{concept:e})),e._getAncestors=t=>this.getAncestors($(R({},t),{concept:e})),e._getDetails=t=>j(this,null,function*(){return(yield this.getConcepts($(R({},t),{concepts:[e]})))[0]});for(let t of["broader","narrower","ancestors"])Array.isArray(e[t])&&e[t].length&&!e[t].includes(null)&&(e[t]=this.adjustConcepts(e[t]));return e._registry=this,e}adjustConcepts(e){return Nr(e.map(t=>this.adjustConcept(t)),e)}adjustRegistries(e){return e}adjustScheme(e){if(!e||e.__SAVED__)return e;let t=e._registry;return e._registry=this.cdk&&this.cdk.registryForScheme(e),!e._registry||t===e._registry||e._registry._api.api===this._api.api?e._registry=t||this:["concepts","topConcepts"].forEach(i=>{Array.isArray(e[i])&&(e[i].length===0||e[i][0]===null)&&delete e[i]}),e._registry&&(e._getTop=i=>e._registry.getTop($(R({},i),{scheme:e})),e._getTypes=i=>e._registry.getTypes($(R({},i),{scheme:e})),e._suggest=s=>{var a=s,{search:i}=a,n=J(a,["search"]);return e._registry.suggest($(R({},n),{search:i,scheme:e}))}),e}adjustSchemes(e){return Nr(e.map(t=>this.adjustScheme(t)),e)}adjustConcordances(e){for(let t of e)t._registry=this;return e}adjustMapping(e){for(let t of["from","to"]){let i=`${t}Scheme`;e[i]||(e[i]=re.default(ct.default.conceptsOfMapping(e,t),"[0].inScheme[0]",null))}if(e._registry=this,!e.identifier){let t=re.default(ct.default.addMappingIdentifiers(e),"identifier");t&&(e.identifier=t)}return e}adjustMappings(e){return Nr(e.map(t=>this.adjustMapping(t)),e)}postMappings(){return j(this,arguments,function*(i={}){var n=i,{mappings:e}=n,t=J(n,["mappings"]);if(!e||!e.length)throw new W({parameter:"mappings"});return this._callHelperForArrayWrappers({method:"postMapping",items:e,itemProperty:"mapping",config:t})})}deleteMappings(){return j(this,arguments,function*(i={}){var n=i,{mappings:e}=n,t=J(n,["mappings"]);if(!e||!e.length)throw new W({parameter:"mappings"});return this._callHelperForArrayWrappers({method:"deleteMapping",items:e,itemProperty:"mapping",config:t})})}_callHelperForArrayWrappers(s){return j(this,arguments,function*({method:e,items:t,itemProperty:i,config:n}){let a=[],u=yield Promise.all(t.map(o=>j(this,null,function*(){try{return yield this[e]($(R({[i]:o},n),{_raw:!0}))}catch(l){return a[t.indexOf(o)]=l,null}})));return u._errors=a,u})}};le.providerName="Base";var Le=fe(He(),1);var ur=fe(ud(),1);var Li,gE=new Uint8Array(16);function bs(){if(!Li&&(Li=typeof crypto!="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Li))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Li(gE)}var Re=[];for(let r=0;r<256;++r)Re.push((r+256).toString(16).slice(1));function fd(r,e=0){return(Re[r[e+0]]+Re[r[e+1]]+Re[r[e+2]]+Re[r[e+3]]+"-"+Re[r[e+4]]+Re[r[e+5]]+"-"+Re[r[e+6]]+Re[r[e+7]]+"-"+Re[r[e+8]]+Re[r[e+9]]+"-"+Re[r[e+10]]+Re[r[e+11]]+Re[r[e+12]]+Re[r[e+13]]+Re[r[e+14]]+Re[r[e+15]]).toLowerCase()}var vE=typeof crypto!="undefined"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto),xs={randomUUID:vE};function yE(r,e,t){if(xs.randomUUID&&!e&&!r)return xs.randomUUID();r=r||{};let i=r.random||(r.rng||bs)();if(i[6]=i[6]&15|64,i[8]=i[8]&63|128,e){t=t||0;for(let n=0;n<16;++n)e[t+n]=i[n];return e}return fd(i)}var ji=yE;var Ni="urn:uuid:",yr=class extends le{_prepare(){this.has.mappings={read:!0,create:!0,update:!0,delete:!0},Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){this.queue=[],this.localStorageKey="cocoda-mappings--"+this._path;let e="mappings",t=()=>ur.default.getItem(this.localStorageKey).then(i=>{i=i||[];let n=0;for(let s of i.filter(a=>!a.uri||!a.uri.startsWith(Ni)))s.uri&&(s.identifier||(s.identifier=[]),s.identifier.push(s.uri)),s.uri=`${Ni}${ji()}`,n+=1;return n&&console.warn(`URIs added to ${n} local mappings.`),ur.default.setItem(this.localStorageKey,i)});ur.default.getItem(e).then(i=>{i&&console.warn(`Warning: There is old data in local storage (or IndexedDB, depending on the ) with the key "${e}". This data will not be used anymore. A manual export is necessary to get this data back.`)}),this.queue.push(t().catch(i=>{console.warn("Error when adding URIs to local mappings:",i)}))}isAuthorizedFor({type:e,action:t}){return e=="mappings"&&t!="anonymous"}_getMappingsQueue(){let e=ss.default(this.queue)||Promise.resolve();return new Promise(t=>{function i(){var a,u,o=new Promise((l,p)=>{a=l,u=p});return o.resolve=a,o.reject=u,o}let n=i(),s=()=>{n.resolve()};this.queue.push(n),e.then(()=>ur.default.getItem(this.localStorageKey)).then(a=>{t({mappings:a,done:s})})})}getMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(t._raw=!0,!e||!e.uri)throw new W({parameter:"mapping"});return(yield this.getMappings($(R({},t),{uri:e.uri})))[0]})}getMappings(){return j(this,arguments,function*({from:e,fromScheme:t,to:i,toScheme:n,creator:s,type:a,partOf:u,offset:o,limit:l,direction:p,mode:b,identifier:_,uri:q}={}){let y={};return e&&(y.from=be.default(e)?e:e.uri),t&&(y.fromScheme=be.default(t)?{uri:t}:t),i&&(y.to=be.default(i)?i:i.uri),n&&(y.toScheme=be.default(n)?{uri:n}:n),s&&(y.creator=be.default(s)?s:Le.default.prefLabel(s)),a&&(y.type=be.default(a)?a:a.uri),u&&(y.partOf=be.default(u)?u:u.uri),o&&(y.offset=o),l&&(y.limit=l),p&&(y.direction=p),b&&(y.mode=b),_&&(y.identifier=_),q&&(y.uri=q),this._getMappingsQueue().catch(E=>{throw new Ee({message:"Could not get mappings from local storage",relatedError:E})}).then(({mappings:E,done:H})=>{H();let K=(F,Z)=>F.uri==Z||Z&&F.notation&&F.notation[0].toLowerCase()==Z.toLowerCase();if((y.from||y.to)&&(E=E.filter(F=>{let Z=Le.default.conceptsOfMapping(F,"from").find(G=>K(G,y.from))!=null,te=Le.default.conceptsOfMapping(F,"to").find(G=>K(G,y.from))!=null,O=Le.default.conceptsOfMapping(F,"from").find(G=>K(G,y.to))!=null,ee=Le.default.conceptsOfMapping(F,"to").find(G=>K(G,y.to))!=null;return y.direction=="backward"?y.mode=="or"?y.from&&te||y.to&&O:(!y.from||te)&&(!y.to||O):y.direction=="both"?y.mode=="or"?y.from&&(Z||te)||y.to&&(O||ee):(!y.from||Z)&&(!y.to||ee)||(!y.from||te)&&(!y.to||O):y.mode=="or"?y.from&&Z||y.to&&ee:(!y.from||Z)&&(!y.to||ee)})),(y.fromScheme||y.toScheme)&&(E=E.filter(F=>{let Z=Le.default.compare(F.fromScheme,y.fromScheme),te=Le.default.compare(F.toScheme,y.fromScheme),O=Le.default.compare(F.fromScheme,y.toScheme),ee=Le.default.compare(F.toScheme,y.toScheme);return y.direction=="backward"?y.mode=="or"?y.fromScheme&&te||y.toScheme&&O:(!y.fromScheme||te)&&(!y.toScheme||O):y.direction=="both"?y.mode=="or"?y.fromScheme&&(Z||te)||y.toScheme&&(O||ee):(!y.fromScheme||Z)&&(!y.toScheme||ee)||(!y.fromScheme||te)&&(!y.toScheme||O):y.mode=="or"?y.fromScheme&&Z||y.toScheme&&ee:(!y.fromScheme||Z)&&(!y.toScheme||ee)})),y.creator){let F=y.creator.split("|");E=E.filter(Z=>(Z.creator&&Z.creator.find(te=>F.includes(Le.default.prefLabel(te))||F.includes(te.uri)))!=null)}y.type&&(E=E.filter(F=>(F.type||[Le.default.defaultMappingType.uri]).includes(y.type))),y.partOf&&(E=E.filter(F=>F.partOf!=null&&F.partOf.find(Z=>Le.default.compare(Z,{uri:y.partOf}))!=null)),y.identifier&&(E=E.filter(F=>y.identifier.split("|").map(Z=>(F.identifier||[]).includes(Z)||F.uri==Z).reduce((Z,te)=>Z||te))),y.uri&&(E=E.filter(F=>F.uri==y.uri));let Q=E.length;return E=E.sort((F,Z)=>{let te=F.modified||F.created,O=Z.modified||Z.created;return O==null?-1:te==null?1:te>O?-1:1}),E=E.slice(y.offset||0),E=E.slice(0,y.limit),E._totalCount=Q,E})})}postMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue();if((!e.uri||!e.uri.startsWith(Ni))&&(e.uri&&(e.identifier||(e.identifier=[]),e.identifier.push(e.uri)),e.uri=`${Ni}${ji()}`),i.find(s=>s.uri==e.uri))throw n(),new W({parameter:"mapping",message:"Duplicate URI"});e.created||(e.created=new Date().toISOString()),e.modified||(e.modified=e.created),i.push(e),i=i.map(s=>Le.default.minifyMapping(s));try{return yield ur.default.setItem(this.localStorageKey,i),n(),e}catch(s){throw n(),s}})}putMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue(),s=i.findIndex(a=>a.uri==e.uri);if(s==-1)throw n(),new W({parameter:"mapping",message:"Mapping not found"});e.created||(e.created=i[s].created),e.modified=new Date().toISOString(),i[s]=e,i=i.map(a=>Le.default.minifyMapping(a));try{return yield ur.default.setItem(this.localStorageKey,i),n(),e}catch(a){throw n(),a}})}patchMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue(),s=i.findIndex(a=>a.uri==e.uri);if(s==-1)throw n(),new W({parameter:"mapping",message:"Mapping not found"});e.created||(e.created=i[s].created),e.modified=new Date().toISOString(),i[s]=Object.assign(i[s],e),i=i.map(a=>Le.default.minifyMapping(a));try{return yield ur.default.setItem(this.localStorageKey,i),n(),e}catch(a){throw n(),a}})}deleteMapping(t){return j(this,arguments,function*({mapping:e}){if(!e)throw new W({parameter:"mapping"});let{mappings:i,done:n}=yield this._getMappingsQueue();try{return i=i.filter(s=>s.uri!=e.uri),i=i.map(s=>Le.default.minifyMapping(s)),yield ur.default.setItem(this.localStorageKey,i),n(),!0}catch(s){throw n(),s}})}};yr.providerName="LocalMappings";yr.stored=!0;var lt=fe(He(),1);var tr=class extends le{_prepare(){this._api.api&&this._api.status===void 0&&(this._api.status=or(this._api.api,"/status")),this.has.mappings=!0,this.has.concordances=!0,this.has.annotations=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){if(this._api.api){let e={mappings:"/mappings",concordances:"/concordances",annotations:"/annotations"};for(let t of Object.keys(e))this._api[t]===void 0&&(this._api[t]=or(this._api.api,e[t]))}this.has.mappings=this._api.mappings?{}:!1,this.has.mappings&&(this.has.mappings.read=!!re.default(this._config,"mappings.read",!0),this.has.mappings.create=!!re.default(this._config,"mappings.create"),this.has.mappings.update=!!re.default(this._config,"mappings.update"),this.has.mappings.delete=!!re.default(this._config,"mappings.delete"),this.has.mappings.anonymous=!!re.default(this._config,"mappings.anonymous")),this.has.concordances=this._api.concordances?{}:!1,this.has.concordances&&(this.has.concordances.read=!!re.default(this._config,"concordances.read"),this.has.concordances.create=!!re.default(this._config,"concordances.create"),this.has.concordances.update=!!re.default(this._config,"concordances.update"),this.has.concordances.delete=!!re.default(this._config,"concordances.delete")),this.has.annotations=this._api.annotations?{}:!1,this.has.annotations&&(this.has.annotations.read=!!re.default(this._config,"annotations.read"),this.has.annotations.create=!!re.default(this._config,"annotations.create"),this.has.annotations.update=!!re.default(this._config,"annotations.update"),this.has.annotations.delete=!!re.default(this._config,"annotations.delete")),this.has.auth=re.default(this._config,"auth.key")!=null,this._defaultParams={properties:"annotations"}}getMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});if(!e.uri||!e.uri.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});try{return yield this.axios($(R({},t),{url:e.uri,params:R(R({},this._defaultParams),t.params||{})}))}catch(s){if(re.default(s,"response.status")==404)return null;throw s}})}getMappings(Z){return j(this,null,function*(){var te=Z,{from:e,fromScheme:t,to:i,toScheme:n,creator:s,type:a,partOf:u,offset:o,limit:l,direction:p,mode:b,identifier:_,cardinality:q,annotatedBy:y,annotatedFor:E,annotatedWith:H,sort:K,order:Q}=te,F=J(te,["from","fromScheme","to","toScheme","creator","type","partOf","offset","limit","direction","mode","identifier","cardinality","annotatedBy","annotatedFor","annotatedWith","sort","order"]);let O={},ee=this._api.mappings;return e&&(O.from=be.default(e)?e:e.uri),t&&(O.fromScheme=be.default(t)?t:t.uri),i&&(O.to=be.default(i)?i:i.uri),n&&(O.toScheme=be.default(n)?n:n.uri),s&&(O.creator=be.default(s)?s:lt.default.prefLabel(s)),a&&(O.type=be.default(a)?a:a.uri),u&&(O.partOf=be.default(u)?u:u.uri),o&&(O.offset=o),l&&(O.limit=l),p&&(O.direction=p),q&&(O.cardinality=q),y&&(O.annotatedBy=y),E&&(O.annotatedFor=E),H&&(O.annotatedWith=H),b&&(O.mode=b),_&&(O.identifier=_),K&&(O.sort=K),Q&&(O.order=Q),this.axios($(R({},F),{method:"get",url:ee,params:R(R(R({},this._defaultParams),F.params||{}),O)}))})}postMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});return e=lt.default.minifyMapping(e),e=lt.default.addMappingIdentifiers(e),this.axios($(R({},t),{method:"post",url:this._api.mappings,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}putMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});e=lt.default.minifyMapping(e),e=lt.default.addMappingIdentifiers(e);let s=e.uri;if(!s||!s.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"put",url:s,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}patchMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});let s=e.uri;if(!s||!s.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"patch",url:s,data:ar.default(e,"uri"),params:R(R({},this._defaultParams),t.params||{})}))})}deleteMapping(i){return j(this,null,function*(){var n=i,{mapping:e}=n,t=J(n,["mapping"]);if(!e)throw new W({parameter:"mapping"});let s=e.uri;if(!s||!s.startsWith(this._api.mappings))throw new W({parameter:"mapping",message:"URI doesn't seem to be part of this registry."});return yield this.axios($(R({},t),{method:"delete",url:s})),!0})}getAnnotations(i){return j(this,null,function*(){var n=i,{target:e}=n,t=J(n,["target"]);return e&&xe.default(t,"params.target",e),this.axios($(R({},t),{method:"get",url:this._api.annotations}))})}postAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);return this.axios($(R({},t),{method:"post",url:this._api.annotations,data:e}))})}putAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);let s=e.id;if(!s||!s.startsWith(this._api.annotations))throw new W({parameter:"annotation",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"put",url:s,data:e}))})}patchAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);let s=e.id;if(!s||!s.startsWith(this._api.annotations))throw new W({parameter:"annotation",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"patch",url:s,data:e}))})}deleteAnnotation(i){return j(this,null,function*(){var n=i,{annotation:e}=n,t=J(n,["annotation"]);let s=e.id;if(!s||!s.startsWith(this._api.annotations))throw new W({parameter:"annotation",message:"URI doesn't seem to be part of this registry."});return yield this.axios($(R({},t),{method:"delete",url:s})),!0})}getConcordances(e){return j(this,null,function*(){return this.axios($(R({},e),{method:"get",url:this._api.concordances}))})}postConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});return this.axios($(R({},t),{method:"post",url:this._api.concordances,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}putConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});let s=e.uri;if(!s||!s.startsWith(this._api.concordances))throw new W({parameter:"concordance",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"put",url:s,data:e,params:R(R({},this._defaultParams),t.params||{})}))})}patchConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});let s=e.uri;if(!s||!s.startsWith(this._api.concordances))throw new W({parameter:"concordance",message:"URI doesn't seem to be part of this registry."});return this.axios($(R({},t),{method:"patch",url:s,data:ar.default(e,"uri"),params:R(R({},this._defaultParams),t.params||{})}))})}deleteConcordance(i){return j(this,null,function*(){var n=i,{concordance:e}=n,t=J(n,["concordance"]);if(!e)throw new W({parameter:"concordance"});let s=e.uri;if(!s||!s.startsWith(this._api.concordances))throw new W({parameter:"concordance",message:"URI doesn't seem to be part of this registry."});return yield this.axios($(R({},t),{method:"delete",url:s})),!0})}};tr.providerName="MappingsApi";tr.stored=!0;var ht=fe(He(),1);var Ss={},_r=class extends le{get _cache(){return Ss[this.uri]}_prepare(){Ss[this.uri]=[],this._occurrencesSupportedSchemes=[],this.has.occurrences=!0,this.has.mappings=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_occurrencesIsSupported(e){return j(this,null,function*(){if(!(this._occurrencesSupportedSchemes&&this._occurrencesSupportedSchemes.length))try{let i=or(this._api.api,"voc"),n=yield this.axios({method:"get",url:i});this._occurrencesSupportedSchemes=n||[]}catch(i){}let t=!1;for(let i of this._occurrencesSupportedSchemes)ht.default.compare(e,i)&&(t=!0);return t})}getMappings(e){return j(this,null,function*(){let t=yield this.getOccurrences(e),i=e.from,n=re.default(i,"inScheme[0]")||e.fromScheme,s=e.to,a=re.default(s,"inScheme[0]")||e.toScheme,u=[];for(let o of t){if(!o)continue;let l={};l.from=re.default(o,"memberSet[0]"),l.from?l.from={memberSet:[l.from]}:l.from=null,l.fromScheme=re.default(o,"memberSet[0].inScheme[0]"),l.to=re.default(o,"memberSet[1]"),l.to?l.to={memberSet:[l.to]}:l.to={memberSet:[]},l.toScheme=re.default(o,"memberSet[1].inScheme[0]"),(i&&ht.default.compare(i,re.default(l,"to.memberSet[0]"))||s&&ht.default.compare(s,re.default(l,"from.memberSet[0]")))&&([l.from,l.fromScheme,l.to,l.toScheme]=[l.to,l.toScheme,l.from,l.fromScheme]),!l.fromScheme&&n&&(l.fromScheme=n),!l.toScheme&&a&&(l.toScheme=a),l.type=[ht.default.defaultMappingType.uri],l._occurrence=o,l=ht.default.addMappingIdentifiers(l),u.push(l)}return u._url=t._url,u})}getOccurrences(a){return j(this,null,function*(){var u=a,{from:e,to:t,concepts:i,threshold:n=0}=u,s=J(u,["from","to","concepts","threshold"]);let o=[];i=(i||[]).concat([e,t]).filter(y=>!!y);for(let y of i)o.push(this._occurrencesIsSupported(re.default(y,"inScheme[0]")).then(E=>E&&y.uri?y.uri:null));let l=yield Promise.all(o);if(l=l.filter(y=>y!=null),l.length==0)throw new W({parameter:"concepts"});o=[];for(let y of l)o.push(this._getOccurrences($(R({},s),{params:{member:y,scheme:"*",threshold:n}})));let p=yield Promise.all(o),b=as.default([],...p),_=[],q=[];for(let y=0;y<b.length;y+=1){let E=b[y];if(!E)continue;let H=E.memberSet.reduce((K,Q)=>K.concat(Q.uri),[]).sort().join(" ");_.includes(H)?q.push(y):_.push(H)}return q.forEach(y=>{delete b[y]}),b=b.filter(y=>y!=null),b=b.sort((y,E)=>parseInt(E.count||0)-parseInt(y.count||0)),b._url=p.map(y=>y._url),b})}_getOccurrences(e){return j(this,null,function*(){let t=this._cache.find(n=>rr.default(n.config.params,e.params));if(t)return t.data;let i=yield this.axios($(R({},e),{method:"get",url:this._api.api}));return this._cache.push({config:e,data:i}),this._cache.length>20&&(Ss[this.uri]=this._cache.slice(this._cache.length-20)),i})}};_r.providerName="OccurrencesApi";_r.stored=!1;var Dr=fe(He(),1);var ir=class extends le{_prepare(){this._api.api&&this._api.status===void 0&&(this._api.status=or(this._api.api,"/status")),this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.types=!0,this.has.suggest=!0,this.has.search=!0,this.has.auth=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){if(this._api.api){let e={schemes:"/voc",top:"/voc/top",concepts:"/voc/concepts",data:"/data",narrower:"/narrower",ancestors:"/ancestors",types:"/types",suggest:"/suggest",search:"/search"};for(let t of Object.keys(e))this._api[t]===void 0&&(this._api[t]=or(this._api.api,e[t]))}this.has.schemes=!!this._api.schemes,!this.has.schemes&&Array.isArray(this.schemes)&&(this.has.schemes=!0),this.has.top=!!this._api.top,this.has.data=!!this._api.data,this.has.concepts=!!this._api.concepts||this.has.data,this.has.narrower=!!this._api.narrower,this.has.ancestors=!!this._api.ancestors,this.has.types=!!this._api.types,this.has.suggest=!!this._api.suggest,this.has.search=!!this._api.search,this.has.auth=re.default(this._config,"auth.key")!=null,this._defaultParams={properties:"+created,issued,modified,editorialNote,scopeNote"}}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){return!e||!t?null:{api:e,schemes:[t]}}_getSchemeUri(e){return j(this,null,function*(){this._approvedSchemes=this._approvedSchemes||[],this._rejectedSchemes=this._rejectedSchemes||[];let t=this._approvedSchemes.find(s=>Dr.default.compare(e,s));if(t)return t.uri;if(this._rejectedSchemes.find(s=>Dr.default.compare(e,s)))return null;let n=(yield this.getSchemes({params:{uri:Dr.default.getAllUris(e).join("|")}})).find(s=>Dr.default.compare(s,e));return n?(this._approvedSchemes.push({uri:n.uri,identifier:Dr.default.getAllUris(e)}),n.uri):(this._rejectedSchemes.push({uri:e.uri,identifier:e.identifier}),null)})}getSchemes(e){return j(this,null,function*(){if(!this._api.schemes){if(Array.isArray(this.schemes))return this.schemes;throw new De}let t=yield this.axios($(R({},e),{method:"get",url:this._api.schemes,params:R($(R({},this._defaultParams),{limit:500}),e.params||{})}));return Array.isArray(this.schemes)?Nr(t.filter(i=>Dr.default.isContainedIn(i,this.schemes)),t):t})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!this._api.top)throw new De;if(!e)throw new W({parameter:"scheme"});let s=yield this._getSchemeUri(e);if(!s)throw new W({parameter:"scheme",message:"Requested vocabulary seems to be unsupported by this API."});return Array.isArray(this._api.top)?this._api.top:this.axios($(R({},t),{method:"get",url:this._api.top,params:$(R($(R({},this._defaultParams),{limit:1e4}),t.params||{}),{uri:s})}))})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);if(this.has.data===!1)throw new De;if(!e)throw new W({parameter:"concepts"});Array.isArray(e)||(e=[e]);let s=e.map(a=>a.uri).filter(a=>a!=null);return this.axios($(R({},t),{method:"get",url:this._api.data,params:$(R($(R({},this._defaultParams),{limit:500}),t.params||{}),{uri:s.join("|")})}))})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!this._api.narrower)throw new De;if(!e||!e.uri)throw new W({parameter:"concept"});return this.axios($(R({},t),{method:"get",url:this._api.narrower,params:$(R($(R({},this._defaultParams),{limit:1e4}),t.params||{}),{uri:e.uri})}))})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!this._api.ancestors)throw new De;if(!e||!e.uri)throw new W({parameter:"concept"});return this.axios($(R({},t),{method:"get",url:this._api.ancestors,params:$(R($(R({},this._defaultParams),{limit:1e4}),t.params||{}),{uri:e.uri})}))})}suggest(a){return j(this,null,function*(){var u=a,{use:e="notation,label",types:t=[],sort:i="score",params:n={}}=u,s=J(u,["use","types","sort","params"]);return this._search($(R({},s),{endpoint:"suggest",params:$(R({},n),{type:t.join("|"),use:e,sort:i})}))})}search(n){return j(this,null,function*(){var s=n,{types:e=[],params:t={}}=s,i=J(s,["types","params"]);return this._search($(R({},i),{endpoint:"search",params:$(R({},t),{type:e.join("|")})}))})}vocSuggest(s){return j(this,null,function*(){var a=s,{use:e="notation,label",sort:t="score",params:i={}}=a,n=J(a,["use","sort","params"]);return this._search($(R({},n),{endpoint:"voc-suggest",params:$(R({},i),{use:e,sort:t})}))})}vocSearch(e){return j(this,null,function*(){return this._search($(R({},e),{endpoint:"voc-search"}))})}_search(l){return j(this,null,function*(){var p=l,{endpoint:e,scheme:t,search:i,limit:n,offset:s,params:a,url:u}=p,o=J(p,["endpoint","scheme","search","limit","offset","params","url"]);if(u=u!=null?u:this._api[e],!u)throw new De;if(!i)throw new W({parameter:"search"});n=n||this._jskos.suggestResultLimit||100,s=s||0;let b=t&&(yield this._getSchemeUri(t));return u=u.replace("{searchTerms}",i),this.axios($(R({},o),{params:$(R(R({},this._defaultParams),a),{limit:n,count:n,offset:s,search:i,query:i,voc:b}),method:"get",url:u}))})}getTypes(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!this._api.types)throw new De;if(Array.isArray(this._api.types))return this._api.types;let s=e&&(yield this._getSchemeUri(e));return s&&xe.default(t,"params.uri",s),this.axios($(R({},t),{method:"get",url:this._api.types}))})}};ir.providerName="ConceptApi";ir.providerType="http://bartoc.org/api-type/jskos";var zt=fe(He(),1);var As={},wr=class extends le{get _cache(){return As[this.uri]}_prepare(){As[this.uri]=[],this.has.mappings=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}getMappings(s){return j(this,null,function*(){var a=s,{from:e,to:t,mode:i}=a,n=J(a,["from","to","mode"]);let u=[];Ie.default(this.schemes)&&(u=this.schemes);let o,l,p=re.default(e,"inScheme[0]"),b=re.default(t,"inScheme[0]"),_,q;if(!e||zt.default.isContainedIn(p,u)?(o=!0,l=t,_=b,q=u.find(O=>zt.default.compare(O,p))||u[0]):(o=!1,l=e,_=p,q=u.find(O=>zt.default.compare(O,b))||u[0]),i!="or")return[];if(!this._api.api)throw new De;if(!l)throw new W({parameter:o?"to":"from"});let y=zt.default.languagePreference.selectLanguage(l.prefLabel);if(!y)throw new W({parameter:o?"to":"from",message:"Missing language"});let E=re.default(l,`altLabel.${y}`,[]);be.default(E)&&(E=[E]);let H=re.default(l,`prefLabel.${y}`),K=E.concat([H]);K=[H];let{url:Q,data:F}=yield this._getReconciliationResults($(R({},n),{labels:K,language:y}));F=[].concat(...Object.values(F).map(O=>O.result)).filter(O=>O),F=F.sort((O,ee)=>O.score!=ee.score?ee.score-O.score:O.match!=ee.match?O.match?-1:1:O.id.length-ee.id.length);let Z=re.default(q,"namespace",""),te=F.map(O=>({fromScheme:_,from:{memberSet:[l]},toScheme:q,to:{memberSet:[{uri:Z+O.id}]},type:[O.match?"http://www.w3.org/2004/02/skos/core#exactMatch":O.score>=80?"http://www.w3.org/2004/02/skos/core#closeMatch":"http://www.w3.org/2004/02/skos/core#mappingRelation"]}));return o&&(te=te.map(O=>Object.assign(O,{fromScheme:O.toScheme,from:O.to,toScheme:O.fromScheme,to:O.from}))),te._url=Q,te})}_getReconciliationResults(n){return j(this,null,function*(){var s=n,{labels:e,language:t}=s,i=J(s,["labels","language"]);e=e.sort();let a=this._cache.find(q=>rr.default(q.labels,e)&&q.language==t);if(a)return a;let u={},o=0;for(let q of e)u[`q${o}`]={query:q},o+=1;let l=this._api.api;t&&(l=l.replace("{language}",t));let p=`queries=${encodeURIComponent(JSON.stringify(u))}`;xe.default(i,["headers","Content-Type"],"application/x-www-form-urlencoded");let b=yield this.axios($(R({},i),{method:"post",url:l,data:p}));b=b||{};let _={labels:e,language:t,data:b,url:`${l}${l.includes("?")?"&":"?"}${p}`};return this._cache.push(_),this._cache.length>20&&(As[this.uri]=this._cache.slice(this._cache.length-20)),_})}};wr.providerName="ReconciliationApi";wr.stored=!1;var Fr=fe(He(),1);var br=class extends le{_prepare(){this._cache=[],this.has.mappings=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}supportsScheme(e){return super.supportsScheme(e)&&re.default(e,"_registry.has.search",!1)}getMappings(u){return j(this,null,function*(){var o=u,{from:e,to:t,mode:i,selected:n,limit:s=10}=o,a=J(o,["from","to","mode","selected","limit"]);if(i!="or")return[];if(!n)throw new W({parameter:"selected"});let l=[];e&&this.supportsScheme(n.scheme[!1])?l.push(this._getMappings($(R({},a),{concept:e,sourceScheme:n.scheme[!0],targetScheme:n.scheme[!1],limit:s}))):l.push(Promise.resolve([])),t&&this.supportsScheme(n.scheme[!0])?l.push(this._getMappings($(R({},a),{concept:t,sourceScheme:n.scheme[!1],targetScheme:n.scheme[!0],limit:s,swap:!0}))):l.push(Promise.resolve([]));let[p,b]=yield Promise.all(l);for(b=b.filter(_=>!p.find(q=>Fr.default.compareMappingMembers(_,q)));p.length+b.length>s;)b.length>=p.length?b=b.slice(0,-1):p=p.slice(0,-1);return ts.default(p,b)})}_getMappings(u){return j(this,null,function*(){var o=u,{concept:e,sourceScheme:t,targetScheme:i,limit:n,swap:s=!1}=o,a=J(o,["concept","sourceScheme","targetScheme","limit","swap"]);var y;if(!e||!t||!i)return[];if(Fr.default.compare(t,i))return[];let l=Fr.default.languagePreference.selectLanguage(e.prefLabel)||this._defaultLanguages[0],p=Fr.default.prefLabel(e,{fallbackToUri:!1,language:l});if(!p)return[];let b=/^[\s\wäüöÄÜÖß]*\w/.exec(p);p=b?b[0]:p;let _=yield this._getResults($(R({},a),{label:p,targetScheme:i,limit:n}));if(!_.length&&((y=e.broader)==null?void 0:y.length))for(let E of e.broader){let H=Fr.default.prefLabel(E,{fallbackToUri:!1,language:l});if(!!H&&(_=yield this._getResults($(R({},a),{label:H,targetScheme:i,limit:n})),_.length))break}let q=_.map(E=>({fromScheme:t,from:{memberSet:[e]},toScheme:i,to:{memberSet:[E]},type:["http://www.w3.org/2004/02/skos/core#mappingRelation"]}));return s&&(q=q.map(E=>Object.assign(E,{fromScheme:E.toScheme,from:E.to,toScheme:E.fromScheme,to:E.from}))),q})}_getResults(s){return j(this,null,function*(){var a=s,{label:e,targetScheme:t,limit:i}=a,n=J(a,["label","targetScheme","limit"]);var b;let u=(this._cache[t.uri]||{})[e];if(u&&u._limit>=i)return u;let o=re.default(t,"_registry");if(!o||o.has.search===!1)return[];let l=(b=(this._jskos.overrides||[]).find(_=>Fr.default.compare(_,t)))==null?void 0:b.search,p=yield o.search($(R({},n),{url:l,search:e,scheme:t,limit:i}));return this._cache[t.uri]||(this._cache[t.uri]={}),this._cache[t.uri][e]=p,this._cache[t.uri][e]._limit=i,p})}};br.providerName="LabelSearchSuggestion";br.stored=!1;var je=fe(He(),1);var xr=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.types=!0,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){if(!e||!t)return null;let i={},n=e.match(/(.+\/)([^/]+)\/$/);return n?(i.api=n[1]+"rest/v1/",t.VOCID=n[2],i.schemes=[t],i):null}get _language(){return this.languages[0]||this._defaultLanguages[0]||"en"}_getApiUrl(e,t,i){let n=e&&e.VOCID||re.default(this.schemes.find(a=>je.default.compare(a,e)),"VOCID");if(!n)throw new W({parameter:"scheme",message:"Missing scheme or VOCID property on scheme"});t=t||"",i=i||{},i.lang||(i.lang=this._language);let s=Object.keys(i).map(a=>`${a}=${encodeURIComponent(i[a])}`).join("&");return`${this._api.api}${n}${t}${s?"?"+s:""}`}_getDataUrl(e,{addFormatParameter:t=!0}={}){let i=re.default(e,"inScheme[0]");if(!e||!e.uri)throw new W({parameter:"concept",message:"Missing concept URI"});return this._getApiUrl(i,"/data",t?{format:"application/json"}:{})}_getSchemeUri(e){return j(this,null,function*(){this._approvedSchemes=this._approvedSchemes||[],this._rejectedSchemes=this._rejectedSchemes||[];let t=this._approvedSchemes.find(a=>je.default.compare(e,a));if(t)return t.uri;if(this._rejectedSchemes.find(a=>je.default.compare(e,a)))return null;let i=this._getApiUrl(e,"/"),s=(yield this.axios({method:"get",url:i})).conceptschemes.find(a=>je.default.compare(a,e));return s?(this._approvedSchemes.push({uri:s.uri,identifier:je.default.getAllUris(e)}),s.uri):(this._rejectedSchemes.push({uri:e.uri,identifier:e.identifier}),null)})}_toJskosConcept(e,{concept:t,scheme:i,result:n,language:s}={}){if(!e)return null;t=je.default.deepCopy(t||{}),s=s||e.lang||"en",t.uri=e.uri,i&&(t.inScheme=[i]);let a=e.matchedPrefLabel||e.prefLabel||e.label;if(be.default(a))xe.default(t,`prefLabel.${s}`,a);else{a&&!Ie.default(a)&&(a=[a]);for(let l of a||[])xe.default(t,`prefLabel.${l.lang}`,l.value)}let u=e.altLabel;if(be.default(u))xe.default(t,`altLabel.${s}`,[u]);else{u&&!Ie.default(u)&&(u=[u]);for(let l of u||[])re.default(t,`altLabel.${l.lang}`)?(t.altLabel[l.lang].push(l.value),t.altLabel[l.lang]=gr.default(t.altLabel[l.lang])):xe.default(t,`altLabel.${l.lang}`,[l.value])}let o=e.notation||e["skos:notation"]||je.default.notation(t);o&&(t.notation=[o.value||o]),e.broader&&(Ie.default(e.broader)||(e.broader=[e.broader]),t.broader=e.broader.map(l=>be.default(l)?{uri:l}:l)),e.hasChildren===!0?t.narrower=[null]:e.hasChildren===!1&&(t.narrower=[]),e.type&&!Ie.default(e.type)&&(e.type=[e.type]),t.type=t.type||[];for(let l of e.type||[]){if(!je.default.isValidUri(l))continue;let p=l.slice(0,l.indexOf(":"));n&&n["@context"]&&n["@context"][p]&&(l=l.replace(p+":",n["@context"][p])),t.type.push(l)}return t.type=gr.default(t.type),t.type.length||(t.type=["http://www.w3.org/2004/02/skos/core#Concept"]),t}getSchemes(t){return j(this,null,function*(){var e=J(t,[]);let i=[];for(let n of this.schemes||[]){let s=this._getApiUrl(n,"/"),u=(yield this.axios($(R({},e),{method:"get",url:s}))).conceptschemes.find(l=>je.default.compare(l,n)),o=u&&(u.prefLabel||u.label||u.title);o&&xe.default(n,`prefLabel.${this._language}`,o),i.push(n),this._approvedSchemes=this._approvedSchemes||[],this._approvedSchemes.find(l=>je.default.compare(n,l))||this._approvedSchemes.push({uri:u.uri,identifier:je.default.getAllUris(n)})}return i})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);let s=this._getApiUrl(e,"/topConcepts"),a=yield this._getSchemeUri(e);if(!a)throw new W({parameter:"scheme",message:"Missing or unsupported scheme or VOCID property on scheme"});xe.default(t,"params.scheme",a);let u=yield this.axios($(R({},t),{method:"get",url:s})),o=[];for(let l of u.topconcepts||[]){let p=this._toJskosConcept(l,{scheme:e,language:this._language});p.topConceptOf=[e],o.push(p)}return o})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);Ie.default(e)||(e=[e]),e=e.map(a=>({uri:a.uri,inScheme:a.inScheme}));let s=[];for(let a of e){let u=this._getDataUrl(a,{addFormatParameter:!1});if(!u)continue;let o=yield this.axios($(R({},t),{method:"get",url:u,params:{uri:a.uri,format:"application/json"}})),l=o&&o.graph&&o.graph.find(p=>je.default.compare(p,a));if(l){let p=this._toJskosConcept(l,{concept:a,result:o});for(let b of["broader","narrower"]){let _=l[b]||p[b];_&&!Ie.default(_)&&(_=[_]),_||(_=[]),p[b]=_.map(q=>this._toJskosConcept(o.graph.find(y=>je.default.compare(y,q)),{scheme:a.inScheme[0],result:o}))}p.ancestors=[],s.push(p)}}return s})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});let s=e.inScheme[0],a=this._getApiUrl(s,"/children");return xe.default(t,"params.uri",e.uri),((yield this.axios($(R({},t),{method:"get",url:a}))).narrower||[]).map(l=>this._toJskosConcept(l,{scheme:s}))})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});let s=e.inScheme[0],a=this._getApiUrl(s,"/broaderTransitive");xe.default(t,"params.uri",e.uri);let u=yield this.axios($(R({},t),{method:"get",url:a})),o=[],l=e.uri;for(;l;){if(l!=e.uri){let b=re.default(u,`broaderTransitive["${l}"]`);o=o.concat([b])}l=re.default(u,`broaderTransitive["${l}"].broader[0]`)}return o.map(b=>this._toJskosConcept(b,{scheme:s})).filter(b=>b.uri!=e.uri)})}suggest(e){return j(this,null,function*(){e._raw=!0;let t=yield this.search(e),i=[e.search,[],[],[]];for(let n of t){let s=je.default.notation(n),a=je.default.prefLabel(n);i[1].push((s?s+" ":"")+a),i[2].push(""),i[3].push(n.uri)}return t._totalCount!=null?i._totalCount=t._totalCount:i._totalCount=t.length,i})}search(a){return j(this,null,function*(){var u=a,{search:e,scheme:t,limit:i,types:n=[]}=u,s=J(u,["search","scheme","limit","types"]);let o=this._getApiUrl(t,"/search");return xe.default(s,"params.query",`${e}*`),xe.default(s,"params.unique",1),xe.default(s,"params.maxhits",i||100),xe.default(s,"params.type",n.join(" ")),((yield this.axios($(R({},s),{method:"get",url:o}))).results||[]).map(b=>this._toJskosConcept(b,{scheme:t}))})}getTypes(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);let s=this._getApiUrl(e,"/types"),a=[],u=yield this.axios($(R({},t),{method:"get",url:s}));for(let o of u&&u.types||[])o.uri!="http://www.w3.org/2004/02/skos/core#Concept"&&(o.label&&(o.prefLabel={[u["@context"]["@language"]]:o.label},delete o.label),a.push(o));return a._url=s,a})}};xr.providerName="SkosmosApi";xr.providerType="http://bartoc.org/api-type/skosmos";var fr=fe(He(),1),Ui=fe(ni(),1);var Fi="http://id.loc.gov/authorities/",Di=[{uri:`${Fi}subjects`,identifier:["http://bartoc.org/en/node/454"],notation:["LCSH"],concepts:[null],topConcepts:[]},{uri:`${Fi}names`,identifier:["http://bartoc.org/en/node/18536"],notation:["LCNAF"],concepts:[null],topConcepts:[]}],cd=`${Fi}classification`;function ld(r){let e={};e.uri=r["@id"],e.notation=(r["http://www.loc.gov/mads/rdf/v1#code"]||[]).map(n=>n["@value"]);let t=r["http://www.loc.gov/mads/rdf/v1#authoritativeLabel"]||r["http://www.w3.org/2000/01/rdf-schema#label"]||[];t.length&&(e.prefLabel={},e.prefLabel[t[0]["@language"]||"en"]=t[0]["@value"]);let i=r["http://www.w3.org/2004/02/skos/core#altLabel"]||[];i.length&&(e.altLabel={en:i.map(n=>n["@value"])});for(let n of r["http://www.w3.org/2000/01/rdf-schema#comment"]||[])e.definition=e.definition||{},e.definition.en=e.definition.en||[],e.definition.en.push(n["@value"]);return e}function _E(r){let e=ld(r);return e.namespace=e.uri+"/",e.type=["http://www.w3.org/2004/02/skos/core#ConceptScheme"],e}var Os=r=>e=>!e||!r||!r.namespace?!0:e.uri.startsWith(r.namespace);function wE(r,{scheme:e}){let t=ld(r);t.type=["http://www.w3.org/2004/02/skos/core#Concept"],t.inScheme=e?[e]:(r["http://www.loc.gov/mads/rdf/v1#isMemberOfMADSScheme"]||[]).map(s=>Di.find(a=>a.uri===s["@id"])),(!t.inScheme.length||!t.inScheme[0])&&delete t.inScheme;let i=r["http://www.loc.gov/mads/rdf/v1#hasNarrowerAuthority"]||fr.default.compare(t.inScheme[0],{uri:cd})&&r["http://www.loc.gov/mads/rdf/v1#hasMADSCollectionMember"]||[];t.narrower=i.map(s=>({uri:s["@id"]})).filter(Os(t.inScheme&&t.inScheme[0]));let n=r["http://www.loc.gov/mads/rdf/v1#hasBroaderAuthority"]||fr.default.compare(t.inScheme[0],{uri:cd})&&r["http://www.loc.gov/mads/rdf/v1#isMemberOfMADSCollection"]||[];return t.broader=n.map(s=>({uri:s["@id"]})).filter(Os(t.inScheme&&t.inScheme[0])),t}var Sr=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!1,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!1,this.has.ancestors=!1,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}static _registryConfigForBartocApiConfig({scheme:e}={}){return!e||!Di.find(t=>fr.default.compare(t,e))?null:{schemes:[e]}}getSchemes(){return j(this,null,function*(){let e=[];for(let t of yield Promise.all(Di.filter(i=>!this.schemes||!this.schemes.length||this.schemes.find(n=>fr.default.compare(i,n))).map(i=>(0,Ui.default)({method:"get",url:`${i.uri.replace("http:","https:")}.json`}).then(({status:n,data:s})=>{if(n===200){let a=s.find(u=>i.uri===u["@id"]);if(a)return a=fr.default.merge(_E(a),i),a.topConcepts=(a.topConcepts||[]).filter(u=>u),a}return null}))))t&&e.push(t);return e})}getConcepts(t){return j(this,arguments,function*({concepts:e}){Array.isArray(e)||(e=[e]);let i=[];for(let n of yield Promise.all(e.map(s=>(0,Ui.default)({method:"get",url:`${s.uri.replace("http:","https:")}.json`}).then(({status:a,data:u})=>{if(a===200){let o=u.find(l=>s.uri===l["@id"]);return o?wE(o,{scheme:s.inScheme&&s.inScheme[0]}):null}}))))n&&i.push(n);return i})}suggest(e){return j(this,null,function*(){let t=yield this.search(e);return[e.search,t.map(i=>fr.default.prefLabel(i,{fallbackToUri:!0})),[],t.map(i=>i.uri)]})}search(s){return j(this,arguments,function*({search:e,scheme:t,limit:i,offset:n}){let a=fr.default.getAllUris(t).find(o=>o.startsWith(Fi));if(!a||!Di.find(o=>fr.default.compare(o,{uri:a})))throw new W({parameter:"scheme",message:"provided scheme is not supported (yet)"});if(!e)throw new W({parameter:"search",message:"parameter is empty or missing"});i=i||this._jskos.suggestResultLimit||100,n=n||0;let{data:u}=yield(0,Ui.default)({method:"get",url:`${a}/suggest2`.replace("http:","https:"),params:{q:e,count:i||100,offset:n,searchtype:"keyword"}});return(u.hits||[]).map(o=>({uri:o.uri,notation:[o.token],prefLabel:{en:o.aLabel},inScheme:[t]})).filter(Os(t))})}};Sr.providerName="LocApi";Sr.providerType="http://bartoc.org/api-type/loc";var kr=fe(He(),1),pd=fe(Cs(),1);function Bi(r){return r.replace(/\\u[\dA-F]{4}/gi,function(e){return String.fromCharCode(parseInt(e.replace(/\\u/g,""),16))})}var Br={},Ar=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1}),Br[this.uri]={index:{},conceptCache:{},schemeCache:{}}}get _index(){return Br[this.uri]&&Br[this.uri].index}get _conceptCache(){return Br[this.uri]&&Br[this.uri].conceptCache}get _schemeCache(){return Br[this.uri]&&Br[this.uri].schemeCache}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){return!e||!t?null:{schemes:[{uri:e,identifier:kr.default.getAllUris(t).filter(n=>n!==e)}]}}_loadScheme(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);let s=kr.default.getAllUris(e);for(let y of s)if(this._schemeCache[y])return this._schemeCache[y];let a=this.schemes.find(y=>kr.default.compare(y,e));if(!a||!a.uri)throw new Qe({message:`Tried to load unsupported scheme (${e&&e.uri})`});let u=a.uri;s=gr.default(s.concat(kr.default.getAllUris(a)));let o=".json";u.endsWith("/")&&(o="index.json");let l=yield this.axios($(R({},t),{url:`${u}${o}`,_skipAdditionalParameters:!0}));if(l.id!==u)throw new Qe({message:"Skohub URL did not return expected concept scheme"});let{title:p,preferredNamespaceUri:b,hasTopConcept:_,description:q}=l;e={uri:u,identifier:s.filter(y=>y!==u)},e.prefLabel=p,Object.keys(e.prefLabel||{}).forEach(y=>{e.prefLabel[y]=Bi(e.prefLabel[y])}),e.namespace=b,e.topConcepts=(_||[]).map(y=>this._toJskosConcept(y)),e.concepts=[null],q&&(e.definition=q,Object.keys(e.definition).forEach(y=>{e.definition[y]=[Bi(e.definition[y])]}));for(let y of Object.keys(e).filter(E=>!e[E]))delete e[y];for(let y of s)this._schemeCache[y]=e;return e})}_loadConcept(i){return j(this,null,function*(){var n=i,{uri:e}=n,t=J(n,["uri"]);if(this._conceptCache[e])return this._conceptCache[e];try{let s=yield this.axios($(R({},t),{url:`${e}.json`,_skipAdditionalParameters:!0}));if(s.id!==e)throw new Qe({message:"Skohub URL did not return expected concept URI"});let a=this._toJskosConcept(s);return this._conceptCache[e]=a,a}catch(s){return null}})}_toJskosConcept(e){let t={uri:e.id};return t.prefLabel=e.prefLabel,Object.keys(t.prefLabel||{}).forEach(i=>{t.prefLabel[i]=Bi(t.prefLabel[i])}),t.narrower=(e.narrower||[]).map(i=>this._toJskosConcept(i)),t.notation=e.notation||[],e.broader&&e.broader.id&&(t.broader=[{uri:e.broader.id}]),e.inScheme&&e.inScheme.id&&(t.inScheme=[{uri:e.inScheme.id}]),e.scopeNote&&(t.scopeNote=e.scopeNote,Object.keys(t.scopeNote).forEach(i=>{t.scopeNote[i]=[Bi(t.scopeNote[i])]})),t}getSchemes(t){return j(this,null,function*(){var e=J(t,[]);return Promise.all(this.schemes.map(i=>this._loadScheme($(R({},e),{scheme:i}))))})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!e||!e.uri)throw new W({parameter:"scheme",message:"Missing scheme URI"});return e=yield this._loadScheme(R({scheme:e},t)),e.topConcepts||[]})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);return Ie.default(e)||(e=[e]),(yield Promise.all(e.map(({uri:s})=>this._loadConcept($(R({},t),{uri:s}))))).filter(Boolean)})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});if(e.ancestors&&e.ancestors[0]!==null)return e.ancestors;if(e=yield this._loadConcept($(R({},t),{uri:e.uri})),!e||!e.broader||!e.broader.length)return[];let s=e.broader[0];return[s].concat(yield this.getAncestors(R({concept:s},t))).map(a=>({uri:a.uri}))})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});return e.narrower&&e.narrower[0]!==null||(e=yield this._loadConcept($(R({},t),{uri:e.uri}))),e.narrower})}search(n){return j(this,arguments,function*({search:e,scheme:t,limit:i=100}){if(t=yield this._loadScheme({scheme:t}),!t||!t.uri)throw new W({parameter:"scheme"});if(!e)throw new W({parameter:"search"});let s;this._index[t.uri]||(this._index[t.uri]={});for(let o of[""].concat(this.languages)){if(this._index[t.uri][o]){s=this._index[t.uri][o];break}if(this._index[t.uri][o]!==null)try{let l=o?`.${o}.index`:".index";t.uri.endsWith("/")&&(l=`index${l}`);let p=yield this.axios({url:`${t.uri}${l}`,_skipAdditionalParameters:!0});if(p.length<100){this._index[t.uri][o]=null;continue}s=pd.default.create(),s.import(p),this._index[t.uri][o]=s;break}catch(l){this._index[t.uri][o]=null}}if(!s)throw new Qe({message:"Could not find search index for any of the available languages "+this.languages.join(",")});let a=s.search(e);return(yield this.getConcepts({concepts:a.map(o=>({uri:o}))})).slice(0,i)})}suggest(e){return j(this,null,function*(){e._raw=!0;let t=yield this.search(e),i=[e.search,[],[],[]];for(let n of t){let s=kr.default.notation(n),a=kr.default.prefLabel(n);i[1].push((s?s+" ":"")+a),i[2].push(""),i[3].push(n.uri)}return t._totalCount!=null?i._totalCount=t._totalCount:i._totalCount=t.length,i})}};Ar.providerName="Skohub";Ar.providerType="http://bartoc.org/api-type/skohub";var Wt=fe(He(),1),dd=fe(Cs(),1);var $e={},Or=class extends le{_prepare(){this.has.schemes=!0,this.has.top=!0,this.has.data=!0,this.has.concepts=!0,this.has.narrower=!0,this.has.ancestors=!0,this.has.suggest=!0,this.has.search=!0,Ae.filter(e=>!this.has[e]).forEach(e=>{this.has[e]=!1})}_setup(){this._scheme=null}static _registryConfigForBartocApiConfig({url:e,scheme:t}={}){return!e||!t?null:{api:e}}_schemeInfoToJSKOS(e){let t=e.labels.find(s=>s.lang==="x-uri").text,i={};e.labels.filter(s=>!s.lang.startsWith("x-")).forEach(s=>{i[s.lang]=s.text});let n={uri:t,prefLabel:i};return e.categories&&e.categories.length&&(n.topConcepts=[null]),e.category&&e.category.length&&(n.concepts=[null]),n}_categoryToJSKOS(e,{scheme:t,broader:i=[]}){if(!e||!t)return null;let n=e.ID,s=`${t.uri}/${n}`;if($e[t.uri].concepts[s])return $e[t.uri].concepts[s];let a={};e.labels.filter(o=>!o.lang.startsWith("x-")&&o.text).forEach(o=>{a[o.lang]=o.text.replace(`${n} `,""),$e[t.uri].searchIndex.add(s,a[o.lang])});let u={};return e.labels.filter(o=>!o.lang.startsWith("x-")&&o.description).forEach(o=>{u[o.lang]||(u[o.lang]=[]),u[o.lang].push(o.description)}),$e[t.uri].concepts[s]={uri:s,notation:[n],prefLabel:a,scopeNote:u,inScheme:[{uri:t.uri}],narrower:(e.categories||[]).map(o=>({uri:`${t.uri}/${o.ID}`})),broader:i},$e[t.uri].concepts[s]}_removeNarrower(e){return e&&Object.assign({},e,{narrower:e.narrower&&e.narrower.length?[null]:[]})}_loadSchemeData(e){return j(this,null,function*(){let t=yield this.axios($(R({},e),{method:"get",url:this._api.api,_skipAdditionalParameters:!0}));this._scheme=this._schemeInfoToJSKOS(t);let i=this._scheme.uri;$e[i]={schemeInfo:t,searchIndex:dd.default.create({tokenize:"full"}),concepts:{}};let n=(s,{broader:a=[]}={})=>{let u=this._categoryToJSKOS(s,{scheme:this._scheme,broader:a});(s.categories||[]).forEach(o=>n(o,{broader:[{uri:u.uri}]}))};t.categories.forEach(s=>n(s)),$e[i].topConcepts=t.categories.map(s=>this._categoryToJSKOS(s,{scheme:this._scheme}))})}getSchemes(){return j(this,arguments,function*(e={}){if(!this._api.api)throw new De;return this._scheme||(this._loadSchemeDataPromise||(this._loadSchemeDataPromise=this._loadSchemeData(e)),yield this._loadSchemeDataPromise),[this._scheme]})}getTop(i){return j(this,null,function*(){var n=i,{scheme:e}=n,t=J(n,["scheme"]);if(!e||!e.uri)throw new W({parameter:"scheme",message:"Missing scheme URI"});if(this._scheme||(yield this.getSchemes(t)),!Wt.default.compare(e,this._scheme))throw new W({parameter:"scheme",message:"Requested vocabulary seems to be unsupported by this API."});return $e[this._scheme.uri].topConcepts.map(this._removeNarrower)})}getConcepts(i){return j(this,null,function*(){var n=i,{concepts:e}=n,t=J(n,["concepts"]);return Ie.default(e)||(e=[e]),this._scheme||(yield this.getSchemes(t)),e.map(s=>$e[this._scheme.uri].concepts[s.uri]).map(this._removeNarrower)})}getAncestors(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});if(e.ancestors&&e.ancestors[0]!==null)return e.ancestors;this._scheme||(yield this.getSchemes(t)),e=$e[this._scheme.uri].concepts[e.uri];let s=e&&e.broader&&e.broader[0];return s?[s].concat(yield this.getAncestors(R({concept:s},t))):[]})}getNarrower(i){return j(this,null,function*(){var n=i,{concept:e}=n,t=J(n,["concept"]);if(!e||!e.uri)throw new W({parameter:"concept"});return e.narrower&&e.narrower[0]!==null?e.narrower:(this._scheme||(yield this.getSchemes(t)),e=$e[this._scheme.uri].concepts[e.uri],(e&&e.narrower||[]).map(s=>$e[this._scheme.uri].concepts[s.uri]).map(this._removeNarrower))})}search(n){return j(this,arguments,function*({search:e,scheme:t,limit:i=100}){if(!t||!t.uri)throw new W({parameter:"scheme"});if(!e)throw new W({parameter:"search"});if(!t||!t.uri)throw new W({parameter:"scheme",message:"Missing scheme URI"});if(this._scheme||(yield this.getSchemes()),!Wt.default.compare(t,this._scheme))throw new W({parameter:"scheme",message:"Requested vocabulary seems to be unsupported by this API."});return(yield $e[this._scheme.uri].searchIndex.search(e)).map(a=>$e[this._scheme.uri].concepts[a]).map(this._removeNarrower).slice(0,i)})}suggest(e){return j(this,null,function*(){e._raw=!0;let t=yield this.search(e),i=[e.search,[],[],[]];for(let n of t){let s=Wt.default.notation(n),a=Wt.default.prefLabel(n);i[1].push((s?s+" ":"")+a),i[2].push(""),i[3].push(n.uri)}return t._totalCount!=null?i._totalCount=t._totalCount:i._totalCount=t.length,i})}};Or.providerName="MyCoRe";Or.providerType="http://bartoc.org/api-type/mycore";var nr={[le.providerName]:le,init(r){if(this[r.provider])return new this[r.provider](r);throw new Hr},addProvider(r){if(r.prototype instanceof le||r===le)this[r.providerName]=r;else throw new Hr}};nr.addProvider(ir);nr.addProvider(tr);Object.values(Ht).forEach(r=>{nr.addProvider(r)});var Es={},Cr=class{constructor(e){this.config=e,this.axios=md.default.create()}setConfig(e){this.config=e}get config(){return this._config}set config(e){e=e||{},e.registries=e.registries||[],e.registries=e.registries.map(t=>nr.init(t)).filter(t=>t),e.registries.forEach(t=>{t.cdk=this}),this._config=e}get providers(){return nr}createInstance(e){return new Cr(e)}loadConfig(e){return j(this,null,function*(){let t=yield this.axios.get(e);this.config=t.data})}loadBuildInfo(a){var u=a,{url:e,buildInfo:t=null,interval:i=6e4,callback:n}=u,s=J(u,["url","buildInfo","interval","callback"]);if(!e&&!this.config.cocodaBaseUrl)throw new Ee({message:"Could not determine URL to load build config."});return e||(e=`${this.config.cocodaBaseUrl}build-info.json`),this.repeat($(R({},s),{function:()=>j(this,null,function*(){return(yield this.axios.get(e,{headers:{"Cache-Control":"no-cache"}})).data}),interval:i,callback:(o,l,p)=>{o?n(o):(p||!p&&t&&!rr.default(l,t))&&n(null,l,p||t)}}))}getRegistryForUri(e){return this.config.registries.find(t=>t.uri==e)}initializeRegistry(e){return e=nr.init(e),e.cdk=this,e}addProvider(e){nr.addProvider(e)}static addProvider(e){nr.addProvider(e)}repeat({function:e,interval:t=15e3,callback:i,callImmediately:n=!0}={}){if(!e)throw new W({parameter:"function"});if(typeof e!="function")throw new W({parameter:"function",message:"function needs to be a function"});let s=()=>j(this,null,function*(){return e()});if(t=parseInt(t),isNaN(t))throw new W({parameter:"interval"});if(!i)throw new W({parameter:"callback"});if(typeof i!="function")throw new W({parameter:"callback",message:"callback needs to be a function"});let a={timer:null,result:null,error:null,isPaused:!1,interval:t},u=_=>{let q=a.result;rr.default(q,_)||(a.result=_,a.error=null,i(null,_,q))},o=_=>{a.error=_,i(_)},l=_=>{a.isPaused||(a.timer=setTimeout(()=>{_()},a.interval))},p=()=>s().then(u).catch(o).then(()=>l(p)),b=(_=n)=>{_?p():l(p)};return b(),{start:(..._)=>{a.isPaused=!1,b(..._)},stop:()=>{a.isPaused=!0,a.timer?clearTimeout(a.timer):setTimeout(()=>{a.timer&&clearTimeout(a.timer)},a.interval)},get isPaused(){return a.isPaused},get lastResult(){return a.result},get hasErrored(){return!!a.error},get interval(){return a.interval},set interval(_){a.interval=_}}}getSchemes(){return j(this,arguments,function*(e={}){let t=[],i=[];for(let n of this.config.registries)if(n.has.schemes!==!1){let s=n.getSchemes(e).then(a=>{for(let u of a){u._registry=n,u.__DETAILSLOADED__=1,u.type=u.type||["http://www.w3.org/2004/02/skos/core#ConceptScheme"];let o=t.find(_=>qr.default.compare(_,u)),l,p,b=!1;if(o){l=this.config.registries.indexOf(n),l!=-1&&(l=this.config.registries.length-l),p=this.config.registries.indexOf(re.default(o,"_registry")),p!=-1&&(p=this.config.registries.length-p);let _=u.concepts?u.concepts.length==0?-1:1:0,q=o.concepts?o.concepts.length==0?-1:1:0;_>q?b=!0:_<q?b=!1:b=p<l}if(!o||b){if(b){let _=t.findIndex(q=>qr.default.compare(q,o));_!=-1&&t.splice(_,1),u=qr.default.merge(u,ar.default(o,["concepts","topConcepts"]),{mergeUris:!0,skipPaths:["_registry"]})}u._registry=n,t.push(u)}else{let _=t.findIndex(q=>qr.default.compare(q,u));if(_!=-1){let q=t[_]._registry;t[_]=qr.default.merge(t[_],ar.default(u,["concepts","topConcepts"]),{mergeUris:!0,skipPaths:["_registry"]}),t[_]._registry=q}}}}).catch(a=>{console.warn("Couldn't load schemes for registry",n.uri,a)});i.push(s)}return yield Promise.all(i),t.forEach(n=>{let s=n._registry;delete n._registry;let a=this.registryForScheme(n);!a||a._api.api===s._api.api?n._registry=s:n._registry=a}),qr.default.sortSchemes(t.filter(Boolean))})}registryForScheme(e){let t=e._registry;if(t)return t;for(let i of e.API||[]){let n=i,{type:s}=n,a=J(n,["type"]);let u=a.url;if(Es[u]){let o=Es[u];return Array.isArray(o._jskos.schemes)&&!qr.default.isContainedIn(e,o._jskos.schemes)&&o._jskos.schemes.push(e),o}else{let o=Object.values(nr).find(p=>p.providerType===s);if(!o||!o._registryConfigForBartocApiConfig)continue;let l=o.providerName;if(a.scheme=e,a=nr[l]._registryConfigForBartocApiConfig(a),!a)continue;a.provider=l;try{if(t=this.initializeRegistry(a),t)return Es[u]=t,t}catch(p){continue}}}return null}};var gd=new Cr;function bE(r){Object.values(Ht).forEach(e=>(r||gd).addProvider(e))}return om(xE);})();
|
|
13
13
|
/*!
|
|
14
14
|
localForage -- Offline Storage, Improved
|
|
15
15
|
Version 1.10.0
|